)]}'
{"id":"openstack%2Foslo.log~1010489","triplet_id":"openstack%2Foslo.log~master~Ieb6fcbbd55ca407555f0d9fa8a32989755817cdf","project":"openstack/oslo.log","branch":"master","topic":"fix-default-log_file","attention_set":{"6476":{"account":{"_account_id":6476,"name":"Thomas Goirand","email":"thomas@goirand.fr","username":"thomas-goirand"},"last_update":"2026-10-16 08:17:53.000000000","reason":"A robot voted negatively on a label"}},"removed_from_attention_set":{"9816":{"account":{"_account_id":9816,"name":"Takashi Kajinami","email":"kajinamit@oss.nttdata.com","username":"kajinamit"},"last_update":"2026-10-16 07:34:43.000000000","reason":"\u003cGERRIT_ACCOUNT_9816\u003e replied on the change","reason_account":{"_account_id":9816,"name":"Takashi Kajinami","email":"kajinamit@oss.nttdata.com","username":"kajinamit"}}},"hashtags":[],"change_id":"Ieb6fcbbd55ca407555f0d9fa8a32989755817cdf","subject":"Get the binary name from sys.argv[0]","status":"NEW","created":"2026-10-14 17:04:52.000000000","updated":"2026-10-16 10:15:56.000000000","submit_type":"MERGE_IF_NECESSARY","mergeable":true,"submittable":false,"total_comment_count":11,"unresolved_comment_count":2,"has_review_started":true,"meta_rev_id":"2034a616d796291c6bdb177d4d90df4855482b14","_number":1010489,"virtual_id_number":1010489,"owner":{"_account_id":6476,"name":"Thomas Goirand","email":"thomas@goirand.fr","username":"thomas-goirand"},"actions":{},"labels":{"Verified":{"disliked":{"_account_id":22348,"name":"Zuul","username":"zuul","tags":["SERVICE_USER"]},"all":[{"_account_id":9816,"name":"Takashi Kajinami","email":"kajinamit@oss.nttdata.com","username":"kajinamit"},{"tag":"autogenerated:zuul:check","value":-1,"date":"2026-10-16 08:17:53.000000000","permitted_voting_range":{"min":-2,"max":2},"_account_id":22348,"name":"Zuul","username":"zuul","tags":["SERVICE_USER"]}],"values":{"-2":"Fails","-1":"Doesn\u0027t seem to work"," 0":"No score","+1":"Works for me","+2":"Verified"},"description":"","value":-1,"default_value":0,"optional":true},"Code-Review":{"all":[{"value":0,"permitted_voting_range":{"min":-2,"max":2},"_account_id":9816,"name":"Takashi Kajinami","email":"kajinamit@oss.nttdata.com","username":"kajinamit"},{"value":0,"permitted_voting_range":{"min":-1,"max":1},"_account_id":22348,"name":"Zuul","username":"zuul","tags":["SERVICE_USER"]}],"values":{"-2":"Do not merge","-1":"This patch needs further work before it can be merged"," 0":"No score","+1":"Looks good to me, but someone else must approve","+2":"Looks good to me (core reviewer)"},"description":"","default_value":0,"optional":true},"Workflow":{"all":[{"value":0,"permitted_voting_range":{"min":-1,"max":1},"_account_id":9816,"name":"Takashi Kajinami","email":"kajinamit@oss.nttdata.com","username":"kajinamit"},{"_account_id":22348,"name":"Zuul","username":"zuul","tags":["SERVICE_USER"]}],"values":{"-1":"Work in progress"," 0":"Ready for reviews","+1":"Approved"},"description":"","default_value":0,"optional":true},"Backport-Candidate":{"all":[{"value":0,"permitted_voting_range":{"min":-2,"max":2},"_account_id":9816,"name":"Takashi Kajinami","email":"kajinamit@oss.nttdata.com","username":"kajinamit"},{"value":0,"permitted_voting_range":{"min":-1,"max":1},"_account_id":22348,"name":"Zuul","username":"zuul","tags":["SERVICE_USER"]}],"values":{"-2":"Do Not Backport","-1":"Not A Backport Candidate"," 0":"Backport Review Needed","+1":"Proposed Backport","+2":"Should Backport"},"description":"","default_value":0,"optional":true}},"removable_reviewers":[],"reviewers":{"REVIEWER":[{"_account_id":9816,"name":"Takashi Kajinami","email":"kajinamit@oss.nttdata.com","username":"kajinamit"},{"_account_id":22348,"name":"Zuul","username":"zuul","tags":["SERVICE_USER"]}]},"pending_reviewers":{},"reviewer_updates":[{"updated":"2026-10-14 20:16:17.000000000","updated_by":{"_account_id":22348,"name":"Zuul","username":"zuul","tags":["SERVICE_USER"]},"reviewer":{"_account_id":22348,"name":"Zuul","username":"zuul","tags":["SERVICE_USER"]},"state":"REVIEWER"},{"updated":"2026-10-15 12:24:59.000000000","updated_by":{"_account_id":9816,"name":"Takashi Kajinami","email":"kajinamit@oss.nttdata.com","username":"kajinamit"},"reviewer":{"_account_id":9816,"name":"Takashi Kajinami","email":"kajinamit@oss.nttdata.com","username":"kajinamit"},"state":"REVIEWER"}],"messages":[{"id":"5bf2088adf0ecfcd8b31eb27b8137bd807e3d864","tag":"autogenerated:gerrit:newPatchSet","author":{"_account_id":6476,"name":"Thomas Goirand","email":"thomas@goirand.fr","username":"thomas-goirand"},"date":"2026-10-14 17:04:52.000000000","message":"Uploaded patch set 1.","accounts_in_message":[],"_revision_number":1},{"id":"f56d331370a37a72d94e06327533b1dc793e2eb8","tag":"autogenerated:gerrit:newPatchSet","author":{"_account_id":6476,"name":"Thomas Goirand","email":"thomas@goirand.fr","username":"thomas-goirand"},"date":"2026-10-14 18:28:27.000000000","message":"Uploaded patch set 2.","accounts_in_message":[],"_revision_number":2},{"id":"9601e5163f434bcb90b3ac51c4e686110ace4190","tag":"autogenerated:zuul:check","author":{"_account_id":22348,"name":"Zuul","username":"zuul","tags":["SERVICE_USER"]},"date":"2026-10-14 20:16:17.000000000","message":"Patch Set 2: Verified-1\n\nBuild failed (check pipeline).  For information on how to proceed, see\nhttps://docs.opendev.org/opendev/infra-manual/latest/developers.html#automated-testing\nand https://docs.openstack.org/project-team-guide/testing.html#how-to-handle-test-failures\n\nhttps://zuul.opendev.org/t/openstack/buildset/baf6bbe5d32d4d9c994d6fd79da53d4b\n\n- tempest-full-py3 https://zuul.opendev.org/t/openstack/build/7e811452fb2b44c7ad1f10039546b4b2 : SUCCESS in 1h 40m 21s\n- openstack-tox-pep8 https://zuul.opendev.org/t/openstack/build/13859aaa983c429ca8972a0057440a8e : FAILURE in 3m 32s\n- openstack-tox-py311 https://zuul.opendev.org/t/openstack/build/e65885590faf476f8451e08d14ceb1f2 : SUCCESS in 2m 51s\n- openstack-tox-py314 https://zuul.opendev.org/t/openstack/build/ebc5b79905e84b34bb02a89d11848613 : SUCCESS in 6m 03s\n- openstack-tox-py315 https://zuul.opendev.org/t/openstack/build/ead71fa8ed8548e6985f5f2aea670463 : SUCCESS in 5m 51s\n- openstack-tox-docs https://zuul.opendev.org/t/openstack/build/9e2df59709eb4665b759815322408b36 : SUCCESS in 2m 09s\n- build-openstack-releasenotes https://zuul.opendev.org/t/openstack/build/6c0682cbb11e4f5995fcb1c8d82265ac : SUCCESS in 5m 48s\n- oslo.log-src-grenade https://zuul.opendev.org/t/openstack/build/3c3755009cc747d1889cbffb9bae0c39 : SUCCESS in 1h 04m 10s (non-voting)\n- oslo.log-jsonformatter https://zuul.opendev.org/t/openstack/build/43d490ef620d4c0991137c9726595293 : SUCCESS in 35m 49s\n- oslo.log-tox-py314-eventlet-patched https://zuul.opendev.org/t/openstack/build/4c0f739ab303458b8a9221b337037b84 : SUCCESS in 5m 47s\n- oslo.log-tox-py314-eventlet-patched-asyncio https://zuul.opendev.org/t/openstack/build/f5bbd64181d4453698bf8da1c04610f1 : SUCCESS in 6m 01s","accounts_in_message":[],"_revision_number":2},{"id":"9fb5e70cfd23de1a861ba7663f2b2d6d76a30bf4","tag":"autogenerated:gerrit:newPatchSet","author":{"_account_id":6476,"name":"Thomas Goirand","email":"thomas@goirand.fr","username":"thomas-goirand"},"date":"2026-10-15 06:33:35.000000000","message":"Uploaded patch set 3.\n\nOutdated Votes:\n* Verified-1 (copy condition: \"NEVER\")\n","accounts_in_message":[],"_revision_number":3},{"id":"6602f068e2956bab33989e761cb0754abbb0a941","tag":"autogenerated:zuul:check","author":{"_account_id":22348,"name":"Zuul","username":"zuul","tags":["SERVICE_USER"]},"date":"2026-10-15 08:10:33.000000000","message":"Patch Set 3: Verified-1\n\nBuild failed (check pipeline).  For information on how to proceed, see\nhttps://docs.opendev.org/opendev/infra-manual/latest/developers.html#automated-testing\nand https://docs.openstack.org/project-team-guide/testing.html#how-to-handle-test-failures\n\nhttps://zuul.opendev.org/t/openstack/buildset/5a722639cf954917849c485000cb00fa\n\n- test-release-openstack https://zuul.opendev.org/t/openstack/build/f34c4bc6dcd94b61b354cd8dc9e34bf4 : SUCCESS in 1m 44s\n- requirements-check https://zuul.opendev.org/t/openstack/build/63745181c54843d2b5f271dc5d928f02 : SUCCESS in 2m 21s\n- tempest-full-py3 https://zuul.opendev.org/t/openstack/build/55f9612bfab74dff9cb576b2c26f54e6 : SUCCESS in 1h 30m 40s\n- openstack-tox-pep8 https://zuul.opendev.org/t/openstack/build/129a0444539146eb94eac474a9d7d21b : SUCCESS in 4m 16s\n- openstack-tox-py311 https://zuul.opendev.org/t/openstack/build/8d666cbdce4f41a3b25d28691ec36105 : FAILURE in 3m 50s\n- openstack-tox-py314 https://zuul.opendev.org/t/openstack/build/656c9c602fe14a6da1103a332abbab1f : FAILURE in 7m 44s\n- openstack-tox-py315 https://zuul.opendev.org/t/openstack/build/3204f7100b234ca58c2442bc1b018c05 : FAILURE in 6m 26s\n- openstack-tox-docs https://zuul.opendev.org/t/openstack/build/b68897bc17d74341934ef95b5b118aa3 : SUCCESS in 4m 34s\n- build-openstack-releasenotes https://zuul.opendev.org/t/openstack/build/409d562d4b3a4dd9bf1896b419b8cc68 : SUCCESS in 2m 55s\n- oslo.log-src-grenade https://zuul.opendev.org/t/openstack/build/d2abfd9e408848d28d37925fa27d0088 : SUCCESS in 1h 08m 26s (non-voting)\n- oslo.log-jsonformatter https://zuul.opendev.org/t/openstack/build/f598a67f6d5a46d0b49557962245d5b8 : SUCCESS in 19m 01s\n- oslo.log-tox-py314-eventlet-patched https://zuul.opendev.org/t/openstack/build/c360471ace2f423ca442ea5140734c21 : FAILURE in 5m 04s\n- oslo.log-tox-py314-eventlet-patched-asyncio https://zuul.opendev.org/t/openstack/build/ff269c2ccd4049c5afc2a2f681319a47 : FAILURE in 5m 52s","accounts_in_message":[],"_revision_number":3},{"id":"87784f286309f70eff94571a71cf71840253f1fd","author":{"_account_id":9816,"name":"Takashi Kajinami","email":"kajinamit@oss.nttdata.com","username":"kajinamit"},"date":"2026-10-15 12:24:59.000000000","message":"Patch Set 3: Code-Review-1\n\n(3 comments)","accounts_in_message":[],"_revision_number":3},{"id":"8706d232529fec3e23019dcdbe9813c97f7deddf","author":{"_account_id":6476,"name":"Thomas Goirand","email":"thomas@goirand.fr","username":"thomas-goirand"},"date":"2026-10-16 06:20:32.000000000","message":"Patch Set 3:\n\n(3 comments)","accounts_in_message":[],"_revision_number":3},{"id":"3fd1f8ec37f7d00a749ba83e177aadec21c8d337","author":{"_account_id":6476,"name":"Thomas Goirand","email":"thomas@goirand.fr","username":"thomas-goirand"},"date":"2026-10-16 06:20:49.000000000","message":"Patch Set 3:\n\n(2 comments)","accounts_in_message":[],"_revision_number":3},{"id":"12e375d4753849c1252152c090ade401a499f06a","tag":"autogenerated:gerrit:newPatchSet","author":{"_account_id":6476,"name":"Thomas Goirand","email":"thomas@goirand.fr","username":"thomas-goirand"},"date":"2026-10-16 06:55:46.000000000","message":"Uploaded patch set 4.\n\nOutdated Votes:\n* Code-Review-1 (copy condition: \"changekind:TRIVIAL_REBASE OR is:MIN\")\n* Verified-1 (copy condition: \"NEVER\")\n","accounts_in_message":[],"_revision_number":4},{"id":"864ef3324300d0bf6d021447b11b692081396e29","author":{"_account_id":9816,"name":"Takashi Kajinami","email":"kajinamit@oss.nttdata.com","username":"kajinamit"},"date":"2026-10-16 07:34:43.000000000","message":"Patch Set 4:\n\n(2 comments)","accounts_in_message":[],"_revision_number":4},{"id":"07fe1bcc173499b0d1632528c32bbe3f71ec59e8","tag":"autogenerated:zuul:check","author":{"_account_id":22348,"name":"Zuul","username":"zuul","tags":["SERVICE_USER"]},"date":"2026-10-16 08:17:53.000000000","message":"Patch Set 4: Verified-1\n\nBuild failed (check pipeline).  For information on how to proceed, see\nhttps://docs.opendev.org/opendev/infra-manual/latest/developers.html#automated-testing\nand https://docs.openstack.org/project-team-guide/testing.html#how-to-handle-test-failures\n\nhttps://zuul.opendev.org/t/openstack/buildset/2eb651750e3f4a78aab0d9805ce99e28\n\n- test-release-openstack https://zuul.opendev.org/t/openstack/build/a677d68e38f94070999609842fb01fdc : SUCCESS in 2m 18s\n- requirements-check https://zuul.opendev.org/t/openstack/build/fd2e2366112d4cc8822b6527c25cf688 : SUCCESS in 2m 14s\n- tempest-full-py3 https://zuul.opendev.org/t/openstack/build/9a4d8bae5e9b4eb992b7eca8fa022e78 : SUCCESS in 48m 24s\n- openstack-tox-pep8 https://zuul.opendev.org/t/openstack/build/fc096b788a2940af947e41716463a1a3 : FAILURE in 2m 24s\n- openstack-tox-py311 https://zuul.opendev.org/t/openstack/build/3668132819fa450eb224ee65a9ccd8dc : SUCCESS in 3m 22s\n- openstack-tox-py314 https://zuul.opendev.org/t/openstack/build/ed69efa5275144a18d4300f795b43238 : SUCCESS in 5m 35s\n- openstack-tox-py315 https://zuul.opendev.org/t/openstack/build/4f70f0b014e74d04a7718f107e4c2388 : SUCCESS in 5m 57s\n- openstack-tox-docs https://zuul.opendev.org/t/openstack/build/13917e2f849b47c09f2f7082c426d16c : SUCCESS in 4m 12s\n- build-openstack-releasenotes https://zuul.opendev.org/t/openstack/build/df510c06f88a448da0a9ee6d9ce1c32c : SUCCESS in 2m 54s\n- oslo.log-src-grenade https://zuul.opendev.org/t/openstack/build/379ba307cef047cebe32e4701a65b6ce : SUCCESS in 1h 16m 17s (non-voting)\n- oslo.log-jsonformatter https://zuul.opendev.org/t/openstack/build/0db6c507626942d9bf0f67c86b18745a : SUCCESS in 16m 39s\n- oslo.log-tox-py314-eventlet-patched https://zuul.opendev.org/t/openstack/build/54ccfa1aca164d5ab4aae96001515fc2 : SUCCESS in 4m 23s\n- oslo.log-tox-py314-eventlet-patched-asyncio https://zuul.opendev.org/t/openstack/build/1b71a1cd998e45b7be106a9b29afdc4e : SUCCESS in 5m 48s","accounts_in_message":[],"_revision_number":4},{"id":"2034a616d796291c6bdb177d4d90df4855482b14","author":{"_account_id":9816,"name":"Takashi Kajinami","email":"kajinamit@oss.nttdata.com","username":"kajinamit"},"date":"2026-10-16 10:15:56.000000000","message":"Patch Set 4:\n\n(1 comment)","accounts_in_message":[],"_revision_number":4}],"current_revision_number":4,"current_revision":"c987d6f84a57ba9735fd7dfa3c55415257900770","revisions":{"3e6612a1247723886886a985a5ed2ad58132d23a":{"kind":"REWORK","_number":1,"created":"2026-10-14 17:04:52.000000000","uploader":{"_account_id":6476,"name":"Thomas Goirand","email":"thomas@goirand.fr","username":"thomas-goirand"},"ref":"refs/changes/89/1010489/1","fetch":{"anonymous http":{"url":"https://review.opendev.org/openstack/oslo.log","ref":"refs/changes/89/1010489/1","commands":{"Checkout":"git fetch https://review.opendev.org/openstack/oslo.log refs/changes/89/1010489/1 \u0026\u0026 git checkout FETCH_HEAD","Cherry Pick":"git fetch https://review.opendev.org/openstack/oslo.log refs/changes/89/1010489/1 \u0026\u0026 git cherry-pick FETCH_HEAD","Format Patch":"git fetch https://review.opendev.org/openstack/oslo.log refs/changes/89/1010489/1 \u0026\u0026 git format-patch -1 --stdout FETCH_HEAD","Pull":"git pull https://review.opendev.org/openstack/oslo.log refs/changes/89/1010489/1"}}},"commit":{"parents":[{"commit":"d25b970a96aec1c485a408d73e0f6b71c58a5711","subject":"Drop version check for eventlet \u003c 0.38.2","web_links":[{"name":"gitea","tooltip":"Open in GitWeb","url":"https://opendev.org/openstack/oslo.log/commit/d25b970a96aec1c485a408d73e0f6b71c58a5711"}]}],"author":{"name":"Thomas Goirand","email":"zigo@debian.org","date":"2026-10-14 16:43:37.000000000","tz":120},"committer":{"name":"Thomas Goirand","email":"zigo@debian.org","date":"2026-10-14 17:04:29.000000000","tz":120},"subject":"Get the binary name from sys.argv[0]","message":"Get the binary name from sys.argv[0]\n\nWhen log_dir is set but log_file isn\u0027t, oslo.log names the log file\nafter the running program. To find that name, _get_binary_name()\nwalked the call stack up to its outermost frame and used that frame\u0027s\nfile name.\n\nThis only works when the program is a plain Python script. uwsgi\n(module + lazy-apps) imports the WSGI application itself, and the\noutermost frame then belongs to the frozen importlib machinery, so the\nderived name is \u0027\u003cfrozen importlib._bootstrap\u003e\u0027. Services then log\ninto a file literally named \u0027\u003cfrozen importlib._bootstrap\u003e.log\u0027, and\nthe syslog and journald handlers use the same garbage as their ident.\n\nsys.argv[0] is the name of the program that was actually started: for\ndaemons started from a script, it\u0027s the same value the outermost frame\nused to give. Under uwsgi it becomes \u0027uwsgi\u0027, so in that case use the\nWSGI application module that uwsgi was told to load: strip the\n\":application\" suffix, replace the \".wsgi.\" sequence with a dash and\nthe remaining dots with dashes too, falling back to \u0027uwsgi\u0027 if there\nis no module option. For example, the /etc/heat/heat-api-cfn-uwsgi.ini\nfile shipped by the Debian heat package has:\n\n    module \u003d heat.wsgi.cfn:application\n\nwhich derives the name \u0027heat-cfn\u0027, so with log_dir\u003d/var/log/heat, the\nWSGI application logs into /var/log/heat/heat-cfn.log. Similarly,\n\u0027nova.wsgi.osapi_compute:application\u0027 derives \u0027nova-osapi_compute\u0027.\n\nChange-Id: Ieb6fcbbd55ca407555f0d9fa8a32989755817cdf\nSigned-off-by: Thomas Goirand \u003czigo@debian.org\u003e\nAssisted-By: Infomaniak Euria-Code\n","web_links":[{"name":"gitea","tooltip":"Open in GitWeb","url":"https://opendev.org/openstack/oslo.log/commit/3e6612a1247723886886a985a5ed2ad58132d23a"}],"resolve_conflicts_web_links":[{"name":"gitea","tooltip":"Open in GitWeb","url":"https://opendev.org/openstack/oslo.log/commit/3e6612a1247723886886a985a5ed2ad58132d23a"}]},"branch":"refs/heads/master"},"8fc48a6e6bf9f5e069926f3396c1bbe3325b27c4":{"kind":"REWORK","_number":2,"created":"2026-10-14 18:28:27.000000000","uploader":{"_account_id":6476,"name":"Thomas Goirand","email":"thomas@goirand.fr","username":"thomas-goirand"},"ref":"refs/changes/89/1010489/2","fetch":{"anonymous http":{"url":"https://review.opendev.org/openstack/oslo.log","ref":"refs/changes/89/1010489/2","commands":{"Checkout":"git fetch https://review.opendev.org/openstack/oslo.log refs/changes/89/1010489/2 \u0026\u0026 git checkout FETCH_HEAD","Cherry Pick":"git fetch https://review.opendev.org/openstack/oslo.log refs/changes/89/1010489/2 \u0026\u0026 git cherry-pick FETCH_HEAD","Format Patch":"git fetch https://review.opendev.org/openstack/oslo.log refs/changes/89/1010489/2 \u0026\u0026 git format-patch -1 --stdout FETCH_HEAD","Pull":"git pull https://review.opendev.org/openstack/oslo.log refs/changes/89/1010489/2"}}},"commit":{"parents":[{"commit":"d25b970a96aec1c485a408d73e0f6b71c58a5711","subject":"Drop version check for eventlet \u003c 0.38.2","web_links":[{"name":"gitea","tooltip":"Open in GitWeb","url":"https://opendev.org/openstack/oslo.log/commit/d25b970a96aec1c485a408d73e0f6b71c58a5711"}]}],"author":{"name":"Thomas Goirand","email":"zigo@debian.org","date":"2026-10-14 16:43:37.000000000","tz":120},"committer":{"name":"Thomas Goirand","email":"zigo@debian.org","date":"2026-10-14 18:27:39.000000000","tz":120},"subject":"Get the binary name from sys.argv[0]","message":"Get the binary name from sys.argv[0]\n\nWhen log_dir is set but log_file isn\u0027t, oslo.log names the log file\nafter the running program. To find that name, _get_binary_name()\nwalked the call stack up to its outermost frame and used that frame\u0027s\nfile name.\n\nThis only works when the program is a plain Python script. uwsgi\n(module + lazy-apps) imports the WSGI application itself, and the\noutermost frame then belongs to the frozen importlib machinery, so the\nderived name is \u0027\u003cfrozen importlib._bootstrap\u003e\u0027. Services then log\ninto a file literally named \u0027\u003cfrozen importlib._bootstrap\u003e.log\u0027, and\nthe syslog and journald handlers use the same garbage as their ident.\n\nsys.argv[0] is the name of the program that was actually started: for\ndaemons started from a script, it\u0027s the same value the outermost frame\nused to give. Under uwsgi it is the uwsgi binary, for example \u0027uwsgi\u0027\nor \u0027uwsgi_python3\u0027 in Debian, so in that case use the WSGI application\nmodule that uwsgi was told to load: strip the \":application\" suffix,\nreplace the \".wsgi.\" sequence with a dash and the remaining dots with\ndashes too, falling back to the uwsgi binary name if there is no\nmodule option. For example, the /etc/heat/heat-api-cfn-uwsgi.ini file\nshipped by the Debian heat package has:\n\n    module \u003d heat.wsgi.cfn:application\n\nwhich derives the name \u0027heat-cfn\u0027, so with log_dir\u003d/var/log/heat, the\nWSGI application logs into /var/log/heat/heat-cfn.log. Similarly,\n\u0027nova.wsgi.osapi_compute:application\u0027 derives \u0027nova-osapi_compute\u0027.\n\nThe whole name guessing is wrapped in a try / except block: should it\nfail for any reason, the name becomes \u0027log-file-not-set\u0027, so that the\nservice logs into a \u0027log-file-not-set.log\u0027 file, making it obvious\nthat log_file must be set.\n\nChange-Id: Ieb6fcbbd55ca407555f0d9fa8a32989755817cdf\nSigned-off-by: Thomas Goirand \u003czigo@debian.org\u003e\n","web_links":[{"name":"gitea","tooltip":"Open in GitWeb","url":"https://opendev.org/openstack/oslo.log/commit/8fc48a6e6bf9f5e069926f3396c1bbe3325b27c4"}],"resolve_conflicts_web_links":[{"name":"gitea","tooltip":"Open in GitWeb","url":"https://opendev.org/openstack/oslo.log/commit/8fc48a6e6bf9f5e069926f3396c1bbe3325b27c4"}]},"branch":"refs/heads/master"},"570a7d9e09fe3e7b01cbe03b6da8c11f563fbfa7":{"kind":"REWORK","_number":3,"created":"2026-10-15 06:33:35.000000000","uploader":{"_account_id":6476,"name":"Thomas Goirand","email":"thomas@goirand.fr","username":"thomas-goirand"},"ref":"refs/changes/89/1010489/3","fetch":{"anonymous http":{"url":"https://review.opendev.org/openstack/oslo.log","ref":"refs/changes/89/1010489/3","commands":{"Checkout":"git fetch https://review.opendev.org/openstack/oslo.log refs/changes/89/1010489/3 \u0026\u0026 git checkout FETCH_HEAD","Cherry Pick":"git fetch https://review.opendev.org/openstack/oslo.log refs/changes/89/1010489/3 \u0026\u0026 git cherry-pick FETCH_HEAD","Format Patch":"git fetch https://review.opendev.org/openstack/oslo.log refs/changes/89/1010489/3 \u0026\u0026 git format-patch -1 --stdout FETCH_HEAD","Pull":"git pull https://review.opendev.org/openstack/oslo.log refs/changes/89/1010489/3"}}},"commit":{"parents":[{"commit":"d25b970a96aec1c485a408d73e0f6b71c58a5711","subject":"Drop version check for eventlet \u003c 0.38.2","web_links":[{"name":"gitea","tooltip":"Open in GitWeb","url":"https://opendev.org/openstack/oslo.log/commit/d25b970a96aec1c485a408d73e0f6b71c58a5711"}]}],"author":{"name":"Thomas Goirand","email":"zigo@debian.org","date":"2026-10-14 16:43:37.000000000","tz":120},"committer":{"name":"Thomas Goirand","email":"zigo@debian.org","date":"2026-10-15 06:24:46.000000000","tz":120},"subject":"Get the binary name from sys.argv[0]","message":"Get the binary name from sys.argv[0]\n\nWhen log_dir is set but log_file isn\u0027t, oslo.log names the log file\nafter the running program. To find that name, _get_binary_name()\nwalked the call stack up to its outermost frame and used that frame\u0027s\nfile name.\n\nThis only works when the program is a plain Python script. uwsgi\n(module + lazy-apps) imports the WSGI application itself, and the\noutermost frame then belongs to the frozen importlib machinery, so the\nderived name is \u0027\u003cfrozen importlib._bootstrap\u003e\u0027. Services then log\ninto a file literally named \u0027\u003cfrozen importlib._bootstrap\u003e.log\u0027, and\nthe syslog and journald handlers use the same garbage as program name.\n\nsys.argv[0] is the name of the program that was actually started: for\ndaemons started from a script, it\u0027s the same value as the basename()\nof argv[0]. Under uwsgi it is the uwsgi binary, for example \u0027uwsgi\u0027\nor \u0027uwsgi_python3\u0027 in Debian, so in that case, we need to do something\nto avoid that all API daemon use the same name. So we strip the\n\":application\" suffix, replace the \".wsgi.\" sequence with a dash and,\nthe remaining dots with dashes too, falling back to the uwsgi binary\nname if there is no module option. For example, for heat-api-cfn, we\nget something like this in the default entry point:\n\n    module \u003d heat.wsgi.cfn:application\n\nwhich derives the name \u0027heat-cfn\u0027, so with log_dir\u003d/var/log/heat, the\nWSGI application logs into /var/log/heat/heat-cfn.log, which is exactly\nwhat we want. Similarly, \u0027nova.wsgi.osapi_compute:application\u0027 derives\n\u0027nova-osapi_compute\u0027. As all OpenStack has standardized the WSGI\napplication module path since Gazpacho at least, this works for all of\nour APIs.\n\nThe whole name guessing is wrapped in a try / except block just to be\nsafer: if fails for any reason, the name becomes \u0027log-file-not-set\u0027, so\nthat the service logs into a \u0027log-file-not-set.log\u0027 file, making it\nobvious for our users that log_file (or --log-file) must be set.\n\nNote about pyproject.toml ignore_missing_imports:\nuwsgi is only importable while running under the uwsgi application\nserver, and importing uwsgi only when we detect is usage really is\nwhat we want here. Which is why I relaxed this check.\n\nChange-Id: Ieb6fcbbd55ca407555f0d9fa8a32989755817cdf\nSigned-off-by: Thomas Goirand \u003czigo@debian.org\u003e\n","web_links":[{"name":"gitea","tooltip":"Open in GitWeb","url":"https://opendev.org/openstack/oslo.log/commit/570a7d9e09fe3e7b01cbe03b6da8c11f563fbfa7"}],"resolve_conflicts_web_links":[{"name":"gitea","tooltip":"Open in GitWeb","url":"https://opendev.org/openstack/oslo.log/commit/570a7d9e09fe3e7b01cbe03b6da8c11f563fbfa7"}]},"branch":"refs/heads/master"},"c987d6f84a57ba9735fd7dfa3c55415257900770":{"kind":"REWORK","_number":4,"created":"2026-10-16 06:55:46.000000000","uploader":{"_account_id":6476,"name":"Thomas Goirand","email":"thomas@goirand.fr","username":"thomas-goirand"},"ref":"refs/changes/89/1010489/4","fetch":{"anonymous http":{"url":"https://review.opendev.org/openstack/oslo.log","ref":"refs/changes/89/1010489/4","commands":{"Checkout":"git fetch https://review.opendev.org/openstack/oslo.log refs/changes/89/1010489/4 \u0026\u0026 git checkout FETCH_HEAD","Cherry Pick":"git fetch https://review.opendev.org/openstack/oslo.log refs/changes/89/1010489/4 \u0026\u0026 git cherry-pick FETCH_HEAD","Format Patch":"git fetch https://review.opendev.org/openstack/oslo.log refs/changes/89/1010489/4 \u0026\u0026 git format-patch -1 --stdout FETCH_HEAD","Pull":"git pull https://review.opendev.org/openstack/oslo.log refs/changes/89/1010489/4"}}},"commit":{"parents":[{"commit":"d25b970a96aec1c485a408d73e0f6b71c58a5711","subject":"Drop version check for eventlet \u003c 0.38.2","web_links":[{"name":"gitea","tooltip":"Open in GitWeb","url":"https://opendev.org/openstack/oslo.log/commit/d25b970a96aec1c485a408d73e0f6b71c58a5711"}]}],"author":{"name":"Thomas Goirand","email":"zigo@debian.org","date":"2026-10-14 16:43:37.000000000","tz":120},"committer":{"name":"Thomas Goirand","email":"zigo@debian.org","date":"2026-10-16 06:52:01.000000000","tz":120},"subject":"Get the binary name from sys.argv[0]","message":"Get the binary name from sys.argv[0]\n\nWhen log_dir is set but log_file isn\u0027t, oslo.log names the log file\nafter the running program. To find that name, _get_binary_name()\nused the basename() of the file found at the bottom of the call stack\n(inspect.stack()[-1]), which is the file that started the Python\ninterpreter.\n\nThis only works when the program is a plain Python script. uwsgi\n(module + lazy-apps) imports the WSGI application itself, and the\nbottom of the call stack then belongs to the frozen importlib\nmachinery, so the derived name is \u0027\u003cfrozen importlib._bootstrap\u003e\u0027.\nServices then log into a file literally named \u0027\u003cfrozen\nimportlib._bootstrap\u003e.log\u0027, and the syslog and journald handlers use\nthe same garbage as program name.\n\nThis cannot be left as is. The name is the same for every service\nhosted by uwsgi, so it carries no information at all about which\ndaemon actually wrote the log, and it defeats any filtering or routing\nby program name, like \u0027journalctl -t\u0027 or rsyslog programname rules.\nThe angle brackets also make the file name hostile to the shell: an\nunquoted \u0027tail \u003cfrozen importlib._bootstrap\u003e.log\u0027 gets parsed as an\ninput redirection and fails, and so does anything embedding the name\nin a script or in a logrotate definition.\n\nsys.argv[0] is the name of the program that was actually started: for\ndaemons started from a script, it\u0027s the same value as the basename()\nof argv[0]. Under uwsgi it is the uwsgi binary, for example \u0027uwsgi\u0027\nor \u0027uwsgi_python3\u0027 in Debian, so in that case, we need to do something\nto avoid that all API daemon use the same name. So we use the module\npath as is, only stripping the \":application\" suffix, and falling back\nto the uwsgi binary name if there is no module option. For example,\nfor heat-api-cfn, we get something like this in the default entry\npoint:\n\n    module \u003d heat.wsgi.cfn:application\n\nwhich derives the name \u0027heat.wsgi.cfn\u0027, so with log_dir\u003d/var/log/heat,\nthe WSGI application logs into /var/log/heat/heat.wsgi.cfn.log.\nSimilarly, \u0027nova.wsgi.osapi_compute:application\u0027 derives\n\u0027nova.wsgi.osapi_compute\u0027. As all OpenStack has standardized the WSGI\napplication module path since Gazpacho at least, this works for all of\nour APIs. The module path is kept unmodified on purpose: we don\u0027t\nenforce any naming pattern on it, and maintaining transformation logic\nspecific to a given pattern could easily break things for anything\nunexpected.\n\nThe whole name guessing is wrapped in a try / except block just to be\nsafer: if fails for any reason, the name becomes \u0027log-file-not-set\u0027, so\nthat the service logs into a \u0027log-file-not-set.log\u0027 file, making it\nobvious for our users that log_file (or --log-file) must be set.\nReturning None instead wouldn\u0027t work: _get_log_file_path() would then\ncall os.path.join(log_dir, None), which raises a TypeError and makes\nthe service crash at logging setup. An obviously wrong, ugly name is\ndeliberate: it is loud, and it tells the operator exactly which\nconfiguration knob is missing, without preventing the service from\nrunning.\n\nNote about pyproject.toml ignore_missing_imports:\nuwsgi is only importable while running under the uwsgi application\nserver, and importing uwsgi only when we detect is usage really is\nwhat we want here. Which is why I relaxed this check.\n\nChange-Id: Ieb6fcbbd55ca407555f0d9fa8a32989755817cdf\nSigned-off-by: Thomas Goirand \u003czigo@debian.org\u003e\n","web_links":[{"name":"gitea","tooltip":"Open in GitWeb","url":"https://opendev.org/openstack/oslo.log/commit/c987d6f84a57ba9735fd7dfa3c55415257900770"}],"resolve_conflicts_web_links":[{"name":"gitea","tooltip":"Open in GitWeb","url":"https://opendev.org/openstack/oslo.log/commit/c987d6f84a57ba9735fd7dfa3c55415257900770"}]},"branch":"refs/heads/master"}},"requirements":[],"submit_records":[{"rule_name":"gerrit~DefaultSubmitRule","status":"OK","labels":[{"label":"Verified","status":"MAY","applied_by":{"_account_id":22348,"name":"Zuul","username":"zuul","tags":["SERVICE_USER"]}},{"label":"Code-Review","status":"MAY"},{"label":"Workflow","status":"MAY"},{"label":"Backport-Candidate","status":"MAY"}]}],"submit_requirements":[{"name":"Verified","description":"Verified in gate by CI","status":"UNSATISFIED","is_legacy":false,"submittability_expression_result":{"expression":"label:Verified\u003dMAX AND -label:Verified\u003dMIN","fulfilled":false,"status":"FAIL","passing_atoms":[],"failing_atoms":["label:Verified\u003dMAX","label:Verified\u003dMIN"],"atom_explanations":{"label:Verified\u003dMAX":"","label:Verified\u003dMIN":""}}},{"name":"Backport-Candidate","description":"Backport candidate status","status":"NOT_APPLICABLE","is_legacy":false,"applicability_expression_result":{"fulfilled":false,"status":"FAIL"},"submittability_expression_result":{"expression":"is:true","fulfilled":true,"status":"NOT_EVALUATED","passing_atoms":[],"failing_atoms":[],"atom_explanations":{}}},{"name":"Code-Review","description":"Code reviewed by core reviewer","status":"UNSATISFIED","is_legacy":false,"submittability_expression_result":{"expression":"label:Code-Review\u003dMAX AND -label:Code-Review\u003dMIN","fulfilled":false,"status":"FAIL","passing_atoms":[],"failing_atoms":["label:Code-Review\u003dMAX","label:Code-Review\u003dMIN"],"atom_explanations":{"label:Code-Review\u003dMAX":"","label:Code-Review\u003dMIN":""}}},{"name":"Workflow","description":"Approved for gate by core reviewer","status":"UNSATISFIED","is_legacy":false,"submittability_expression_result":{"expression":"label:Workflow\u003dMAX AND -label:Workflow\u003dMIN","fulfilled":false,"status":"FAIL","passing_atoms":[],"failing_atoms":["label:Workflow\u003dMAX","label:Workflow\u003dMIN"],"atom_explanations":{"label:Workflow\u003dMAX":"","label:Workflow\u003dMIN":""}}}]}
