[Python-announce] ANN: A new version (0.5.2) of python-gnupg has been released.
What Changed?= This is an enhancement and bug-fix release, and all users are encouraged to upgrade. Brief summary: * Fix #228: Clarify documentation for encryption/decryption. * Make I/O buffer size configurable via buffer_size attribute on a GPG instance. This release [2] has been signed with my code signing key: Vinay Sajip (CODE SIGNING KEY) Fingerprint: CA74 9061 914E AC13 8E66 EADB 9147 B477 339A 9B86 Recent changes to PyPI don't show the GPG signature with the download links. An alternative download source where the signatures are available is at [4]. The source code repository is at [1]. Documentation is available at [5]. As always, your feedback is most welcome (especially bug reports [3], patches and suggestions for improvement, or any other points via this group). Enjoy! Cheers Vinay Sajip [1] https://github.com/vsajip/python-gnupg [2] https://pypi.org/project/python-gnupg/0.5.2 [3] https://github.com/vsajip/python-gnupg/issues [4] https://github.com/vsajip/python-gnupg/releases/ [5] https://docs.red-dove.com/python-gnupg/ ___ Python-announce-list mailing list -- python-announce-list@python.org To unsubscribe send an email to python-announce-list-le...@python.org https://mail.python.org/mailman3/lists/python-announce-list.python.org/ Member address: arch...@mail-archive.com
[Python-announce] Announcement: distlib 0.3.8 released on PyPI
Version 0.3.8 of distlib has recently been released on PyPI [1]. For newcomers, distlib is a library of packaging functionality which is intended to be usable as the basis for third-party packaging tools. The main changes in this release are as follows: * Fix #204: use symlinks in venv creation during test. * Fix #208: handle deprecation removals in Python 3.13. * Fix #209: use legacy version implementation for Python versions. A more detailed change log is available at [2]. Please try it out, and if you find any problems or have any suggestions for improvements, please give some feedback using the issue tracker at [3]. Regards, Vinay Sajip [1] https://pypi.org/project/distlib/0.3.8/ [2] https://distlib.readthedocs.io/en/latest/overview.html#change-log-for-distlib [3] https://github.com/pypa/distlib/issues/new/choose ___ Python-announce-list mailing list -- python-announce-list@python.org To unsubscribe send an email to python-announce-list-le...@python.org https://mail.python.org/mailman3/lists/python-announce-list.python.org/ Member address: arch...@mail-archive.com
ANN: A new version (0.5.2) of python-gnupg has been released.
What Changed?= This is an enhancement and bug-fix release, and all users are encouraged to upgrade. Brief summary: * Fix #228: Clarify documentation for encryption/decryption. * Make I/O buffer size configurable via buffer_size attribute on a GPG instance. This release [2] has been signed with my code signing key: Vinay Sajip (CODE SIGNING KEY) Fingerprint: CA74 9061 914E AC13 8E66 EADB 9147 B477 339A 9B86 Recent changes to PyPI don't show the GPG signature with the download links. An alternative download source where the signatures are available is at [4]. The source code repository is at [1]. Documentation is available at [5]. As always, your feedback is most welcome (especially bug reports [3], patches and suggestions for improvement, or any other points via this group). Enjoy! Cheers Vinay Sajip [1] https://github.com/vsajip/python-gnupg [2] https://pypi.org/project/python-gnupg/0.5.2 [3] https://github.com/vsajip/python-gnupg/issues [4] https://github.com/vsajip/python-gnupg/releases/ [5] https://docs.red-dove.com/python-gnupg/ -- https://mail.python.org/mailman/listinfo/python-list
Announcement: distlib 0.3.8 released on PyPI
Version 0.3.8 of distlib has recently been released on PyPI [1]. For newcomers, distlib is a library of packaging functionality which is intended to be usable as the basis for third-party packaging tools. The main changes in this release are as follows: * Fix #204: use symlinks in venv creation during test. * Fix #208: handle deprecation removals in Python 3.13. * Fix #209: use legacy version implementation for Python versions. A more detailed change log is available at [2]. Please try it out, and if you find any problems or have any suggestions for improvements, please give some feedback using the issue tracker at [3]. Regards, Vinay Sajip [1] https://pypi.org/project/distlib/0.3.8/ [2] https://distlib.readthedocs.io/en/latest/overview.html#change-log-for-distlib [3] https://github.com/pypa/distlib/issues/new/choose -- https://mail.python.org/mailman/listinfo/python-list
[Python-announce] ANN: A new version (0.5.1) of python-gnupg has been released.
What Changed? = This is an enhancement and bug-fix release, and all users are encouraged to upgrade. Brief summary: * Added TRUST_EXPIRED to trust_keys. * Fix #206: Remove deprecated --always-trust in favour of --trust-model always * Fix #208: Add status_detail attribute to result objects which is populated when the status is 'invalid recipient' (encryption/decryption) or 'invalid signer' (signing). This attribute will be set when the result object's status attribute is set to 'invalid recipient' and will contain more information about the failure in the form of reason:ident where reason is a text description of the reason, and ident identifies the recipient key. * Add scan_keys_mem() function to scan keys in a string. * Fix #214: Handle multiple signatures when one of them is invalid or unverified. * A problems attribute was added which holds problems reported by gpg during verification. This is a list of dictionaries, one for each reported problem. Each dictionary will have status and keyid keys indicating the problem and the corresponding key; other information in the dictionaries will be error specific. * Fix #217: Use machine-readable interface to query the gpg version. * Added the ability to export keys to a file. This release [2] has been signed with my code signing key: Vinay Sajip (CODE SIGNING KEY) Fingerprint: CA74 9061 914E AC13 8E66 EADB 9147 B477 339A 9B86 Recent changes to PyPI don't show the GPG signature with the download links. An alternative download source where the signatures are available is at [4]. The source code repository is at [1]. Documentation is available at [5]. As always, your feedback is most welcome (especially bug reports [3], patches and suggestions for improvement, or any other points via this group). Enjoy! Cheers Vinay Sajip [1] https://github.com/vsajip/python-gnupg [2] https://pypi.org/project/python-gnupg/0.5.1 [3] https://github.com/vsajip/python-gnupg/issues [4] https://github.com/vsajip/python-gnupg/releases/ [5] https://docs.red-dove.com/python-gnupg/ ___ Python-announce-list mailing list -- python-announce-list@python.org To unsubscribe send an email to python-announce-list-le...@python.org https://mail.python.org/mailman3/lists/python-announce-list.python.org/ Member address: arch...@mail-archive.com
ANN: A new version (0.5.1) of python-gnupg has been released.
What Changed? = This is an enhancement and bug-fix release, and all users are encouraged to upgrade. Brief summary: * Added TRUST_EXPIRED to trust_keys. * Fix #206: Remove deprecated --always-trust in favour of --trust-model always * Fix #208: Add status_detail attribute to result objects which is populated when the status is 'invalid recipient' (encryption/decryption) or 'invalid signer' (signing). This attribute will be set when the result object's status attribute is set to 'invalid recipient' and will contain more information about the failure in the form of reason:ident where reason is a text description of the reason, and ident identifies the recipient key. * Add scan_keys_mem() function to scan keys in a string. * Fix #214: Handle multiple signatures when one of them is invalid or unverified. * A problems attribute was added which holds problems reported by gpg during verification. This is a list of dictionaries, one for each reported problem. Each dictionary will have status and keyid keys indicating the problem and the corresponding key; other information in the dictionaries will be error specific. * Fix #217: Use machine-readable interface to query the gpg version. * Added the ability to export keys to a file. This release [2] has been signed with my code signing key: Vinay Sajip (CODE SIGNING KEY) Fingerprint: CA74 9061 914E AC13 8E66 EADB 9147 B477 339A 9B86 Recent changes to PyPI don't show the GPG signature with the download links. An alternative download source where the signatures are available is at [4]. The source code repository is at [1]. Documentation is available at [5]. As always, your feedback is most welcome (especially bug reports [3], patches and suggestions for improvement, or any other points via this group). Enjoy! Cheers Vinay Sajip [1] https://github.com/vsajip/python-gnupg [2] https://pypi.org/project/python-gnupg/0.5.1 [3] https://github.com/vsajip/python-gnupg/issues [4] https://github.com/vsajip/python-gnupg/releases/ [5] https://docs.red-dove.com/python-gnupg/ -- https://mail.python.org/mailman/listinfo/python-list
[Python-announce] Announcement: distlib 0.3.7 released on PyPI
Version 0.3.7 of distlib has recently been released on PyPI [1]. For newcomers, distlib is a library of packaging functionality which is intended to be usable as the basis for third-party packaging tools. The main changes in this release are as follows: * Handle bare newlines when parsing metadata. * Use version comparison logic for python_full_version. * Fix shebang computation for source builds of Python. * Extract tarfiles more safely by incorporating tarfile filters. * Check for 'has_cert' attribute before using it. * Fix #200: Improve conformance to PEP440. * Fix #203: Handle parsing of export entries to allow script names such as "," or ",foo". A more detailed change log is available at [2]. Please try it out, and if you find any problems or have any suggestions for improvements, please give some feedback using the issue tracker at [3]. Regards, Vinay Sajip [1] https://pypi.org/project/distlib/0.3.7/ [2] https://distlib.readthedocs.io/en/0.3.7/overview.html#change-log-for-distlib [3] https://github.com/pypa/distlib/issues/new/choose ___ Python-announce-list mailing list -- python-announce-list@python.org To unsubscribe send an email to python-announce-list-le...@python.org https://mail.python.org/mailman3/lists/python-announce-list.python.org/ Member address: arch...@mail-archive.com
Announcement: distlib 0.3.7 released on PyPI
Version 0.3.7 of distlib has recently been released on PyPI [1]. For newcomers, distlib is a library of packaging functionality which is intended to be usable as the basis for third-party packaging tools. The main changes in this release are as follows: * Handle bare newlines when parsing metadata. * Use version comparison logic for python_full_version. * Fix shebang computation for source builds of Python. * Extract tarfiles more safely by incorporating tarfile filters. * Check for 'has_cert' attribute before using it. * Fix #200: Improve conformance to PEP440. * Fix #203: Handle parsing of export entries to allow script names such as "," or ",foo". A more detailed change log is available at [2]. Please try it out, and if you find any problems or have any suggestions for improvements, please give some feedback using the issue tracker at [3]. Regards, Vinay Sajip [1] https://pypi.org/project/distlib/0.3.7/ [2] https://distlib.readthedocs.io/en/0.3.7/overview.html#change-log-for-distlib [3] https://github.com/pypa/distlib/issues/new/choose -- https://mail.python.org/mailman/listinfo/python-list
[Python-announce] ANN: A new version (0.5.0) of python-gnupg has been released.
What Changed? = This is an enhancement and bug-fix release, and all users are encouraged to upgrade. Brief summary: * Fixed #181: Added the ability to pass file paths to encrypt_file, decrypt_file, sign_file, verify_file, get_recipients_file and added import_keys_file. * Fixed #183: Handle FAILURE and UNEXPECTED conditions correctly. Thanks to sebbASF for the patch. * Fixed #185: Handle VALIDSIG arguments more robustly. * Fixed #188: Remove handling of DECRYPTION_FAILED from Verify code, as not required there. Thanks to sebbASF for the patch. * Fixed #190: Handle KEY_CREATED more robustly. * Fixed #191: Handle NODATA messages during verification. * Fixed #196: Don't log chunk data by default, as it could contain sensitive information (during decryption, for example). * Added the ability to pass an environment to the gpg executable. Thanks to Edvard Rejthar for the patch. This release [2] has been signed with my code signing key: Vinay Sajip (CODE SIGNING KEY) Fingerprint: CA74 9061 914E AC13 8E66 EADB 9147 B477 339A 9B86 Recent changes to PyPI don't show the GPG signature with the download links. The source code repository is at [1]. An alternative download source where the signatures are available is at [4]. Documentation is available at [5]. As always, your feedback is most welcome (especially bug reports [3], patches and suggestions for improvement, or any other points via this group). Enjoy! Cheers Vinay Sajip [1] https://github.com/vsajip/python-gnupg [2] https://pypi.org/project/python-gnupg/0.5.0 [3] https://github.com/vsajip/python-gnupg/issues [4] https://github.com/vsajip/python-gnupg/releases/ [5] https://docs.red-dove.com/python-gnupg/ ___ Python-announce-list mailing list -- python-announce-list@python.org To unsubscribe send an email to python-announce-list-le...@python.org https://mail.python.org/mailman3/lists/python-announce-list.python.org/ Member address: arch...@mail-archive.com
ANN: A new version (0.5.0) of python-gnupg has been released.
What Changed? = This is an enhancement and bug-fix release, and all users are encouraged to upgrade. Brief summary: * Fixed #181: Added the ability to pass file paths to encrypt_file, decrypt_file, sign_file, verify_file, get_recipients_file and added import_keys_file. * Fixed #183: Handle FAILURE and UNEXPECTED conditions correctly. Thanks to sebbASF for the patch. * Fixed #185: Handle VALIDSIG arguments more robustly. * Fixed #188: Remove handling of DECRYPTION_FAILED from Verify code, as not required there. Thanks to sebbASF for the patch. * Fixed #190: Handle KEY_CREATED more robustly. * Fixed #191: Handle NODATA messages during verification. * Fixed #196: Don't log chunk data by default, as it could contain sensitive information (during decryption, for example). * Added the ability to pass an environment to the gpg executable. Thanks to Edvard Rejthar for the patch. This release [2] has been signed with my code signing key: Vinay Sajip (CODE SIGNING KEY) Fingerprint: CA74 9061 914E AC13 8E66 EADB 9147 B477 339A 9B86 Recent changes to PyPI don't show the GPG signature with the download links. The source code repository is at [1]. An alternative download source where the signatures are available is at [4]. Documentation is available at [5]. As always, your feedback is most welcome (especially bug reports [3], patches and suggestions for improvement, or any other points via this group). Enjoy! Cheers Vinay Sajip [1] https://github.com/vsajip/python-gnupg [2] https://pypi.org/project/python-gnupg/0.5.0 [3] https://github.com/vsajip/python-gnupg/issues [4] https://github.com/vsajip/python-gnupg/releases/ [5] https://docs.red-dove.com/python-gnupg/ -- https://mail.python.org/mailman/listinfo/python-list
[Python-announce] ANN: distlib 0.3.5 released on PyPI
I've recently released version 0.3.5 of distlib on PyPI [1]. For newcomers, distlib is a library of packaging functionality which is intended to be usable as the basis for third-party packaging tools. The main changes in this release are as follows: * Fixed #161: Updated test case. * Fixed #164: Improved support for reproducible builds by allowing a fixed date/time to be inserted into created .exe files. Thanks to Somber Night for the patch. * Fixed #169: Removed usage of deprecated imp module in favour of importlib. * Fixed #170: Corrected implementation of ``get_required_dists()``. * Fixed #172: Compute ABI correctly for Python < 3.8. * Changed the default locator configuration. * Made updates in support of PEP 643 / Metadata 2.2. * Updated launcher executables. Thanks to Michael Bikovitsky for his help with the launcher changes. * Updated to write archive path of RECORD to RECORD instead of staging path. Thanks to Pieter Pas for the patch. A more detailed change log is available at [2]. Please try it out, and if you find any problems or have any suggestions for improvements, please give some feedback using the issue tracker! [3] Regards, Vinay Sajip [1] https://pypi.org/project/distlib/0.3.5/ [2] https://distlib.readthedocs.io/en/0.3.5/ [3] https://github.com/pypa/distlib/issues/new/choose ___ Python-announce-list mailing list -- python-announce-list@python.org To unsubscribe send an email to python-announce-list-le...@python.org https://mail.python.org/mailman3/lists/python-announce-list.python.org/ Member address: arch...@mail-archive.com
ANN: distlib 0.3.5 released on PyPI
I've recently released version 0.3.5 of distlib on PyPI [1]. For newcomers, distlib is a library of packaging functionality which is intended to be usable as the basis for third-party packaging tools. The main changes in this release are as follows: * Fixed #161: Updated test case. * Fixed #164: Improved support for reproducible builds by allowing a fixed date/time to be inserted into created .exe files. Thanks to Somber Night for the patch. * Fixed #169: Removed usage of deprecated imp module in favour of importlib. * Fixed #170: Corrected implementation of ``get_required_dists()``. * Fixed #172: Compute ABI correctly for Python < 3.8. * Changed the default locator configuration. * Made updates in support of PEP 643 / Metadata 2.2. * Updated launcher executables. Thanks to Michael Bikovitsky for his help with the launcher changes. * Updated to write archive path of RECORD to RECORD instead of staging path. Thanks to Pieter Pas for the patch. A more detailed change log is available at [2]. Please try it out, and if you find any problems or have any suggestions for improvements, please give some feedback using the issue tracker! [3] Regards, Vinay Sajip [1] https://pypi.org/project/distlib/0.3.5/ [2] https://distlib.readthedocs.io/en/0.3.5/ [3] https://github.com/pypa/distlib/issues/new/choose -- https://mail.python.org/mailman/listinfo/python-list
[Python-announce] ANN: A new version (0.4.9) of python-gnupg has been released.
What Changed? = This is an enhancement and bug-fix release, and all users are encouraged to upgrade. Brief summary: * Fixed #161: Added a status attribute to the returned object from gen_key() which is set to 'ok' if a key was successfully created, or 'key not created' if that was reported by gpg, or None in any other case. * Fixed #164: Provided the ability to add subkeys. Thanks to Daniel Kilimnik for the feature request and patch. * Fixed #166: Added keygrip values to the information collected when keys are listed. Thanks to Daniel Kilimnik for the feature request and patch. * Fixed #173: Added extra_args to send_keys(), recv_keys() and search_keys() to allow passing options relating to key servers. This release [2] has been signed with my code signing key: Vinay Sajip (CODE SIGNING KEY) Fingerprint: CA74 9061 914E AC13 8E66 EADB 9147 B477 339A 9B86 Recent changes to PyPI don't show the GPG signature with the download links. The source code repository is at [1]. An alternative download source where the signatures are available is at [4]. Documentation is available at [5]. As always, your feedback is most welcome (especially bug reports [3], patches and suggestions for improvement, or any other points via this group). Enjoy! Cheers Vinay Sajip [1] https://github.com/vsajip/python-gnupg [2] https://pypi.org/project/python-gnupg/0.4.9 [3] https://github.com/vsajip/python-gnupg/issues [4] https://github.com/vsajip/python-gnupg/releases/ [5] https://docs.red-dove.com/python-gnupg/ ___ Python-announce-list mailing list -- python-announce-list@python.org To unsubscribe send an email to python-announce-list-le...@python.org https://mail.python.org/mailman3/lists/python-announce-list.python.org/ Member address: arch...@mail-archive.com
ANN: A new version (0.4.9) of python-gnupg has been released.
What Changed? = This is an enhancement and bug-fix release, and all users are encouraged to upgrade. Brief summary: * Fixed #161: Added a status attribute to the returned object from gen_key() which is set to 'ok' if a key was successfully created, or 'key not created' if that was reported by gpg, or None in any other case. * Fixed #164: Provided the ability to add subkeys. Thanks to Daniel Kilimnik for the feature request and patch. * Fixed #166: Added keygrip values to the information collected when keys are listed. Thanks to Daniel Kilimnik for the feature request and patch. * Fixed #173: Added extra_args to send_keys(), recv_keys() and search_keys() to allow passing options relating to key servers. This release [2] has been signed with my code signing key: Vinay Sajip (CODE SIGNING KEY) Fingerprint: CA74 9061 914E AC13 8E66 EADB 9147 B477 339A 9B86 Recent changes to PyPI don't show the GPG signature with the download links. The source code repository is at [1]. An alternative download source where the signatures are available is at [4]. Documentation is available at [5]. As always, your feedback is most welcome (especially bug reports [3], patches and suggestions for improvement, or any other points via this group). Enjoy! Cheers Vinay Sajip [1] https://github.com/vsajip/python-gnupg [2] https://pypi.org/project/python-gnupg/0.4.9 [3] https://github.com/vsajip/python-gnupg/issues [4] https://github.com/vsajip/python-gnupg/releases/ [5] https://docs.red-dove.com/python-gnupg/ -- https://mail.python.org/mailman/listinfo/python-list
[issue47158] logging.handlers.SysLogHandler doesn't get cleaned up properly on exit if it throws an exception
Vinay Sajip added the comment: The 3.8 branch is security-fix-only now, I'm afraid. And I'm not sure it's worth backporting this. -- versions: -Python 3.8 ___ Python tracker <https://bugs.python.org/issue47158> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue45171] stacklevel handling in logging module is inconsistent
Vinay Sajip added the comment: New changeset c12ba6b2ff7908c8970b978f149d51ecd3fb195c by Jouke Witteveen in branch 'main': bpo-45171: Remove tests of deprecated logger.warn(). (GH-32139) https://github.com/python/cpython/commit/c12ba6b2ff7908c8970b978f149d51ecd3fb195c -- ___ Python tracker <https://bugs.python.org/issue45171> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue45171] stacklevel handling in logging module is inconsistent
Vinay Sajip added the comment: New changeset 5ca6d7469be53960843df39bb900e9c3359f127f by Jouke Witteveen in branch 'main': bpo-45171: Fix stacklevel handling in logging. (GH-28287) https://github.com/python/cpython/commit/5ca6d7469be53960843df39bb900e9c3359f127f -- nosy: +vinay.sajip ___ Python tracker <https://bugs.python.org/issue45171> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46557] Logging captured warnings with a format string unnecessarily groups warnings together
Vinay Sajip added the comment: New changeset d8066b420b888591f485d132e62979d07abfc3f4 by Michael P. Nitowski in branch 'main': bpo-46557: Log captured warnings without format string (GH-30975) https://github.com/python/cpython/commit/d8066b420b888591f485d132e62979d07abfc3f4 -- nosy: +vinay.sajip ___ Python tracker <https://bugs.python.org/issue46557> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46914] On Osx Monterey(12.x), Logging.handlers.SysLogHandler does not work
Vinay Sajip added the comment: > If so, then it probably good to adjust ... since it still talks about it > being expected. Do you mean just adding a note to the effect that SysLogHandler won't work on macOS 12.2 because of changes to the syslog daemon on that platform? IIRC using the syslog module was not an option at the time SysLogHandler was added, I think because of both thread-safety and lack-of-functionality issues. -- ___ Python tracker <https://bugs.python.org/issue46914> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46557] Logging captured warnings with a format string unnecessarily groups warnings together
Change by Vinay Sajip : -- type: behavior -> enhancement versions: -Python 3.10, Python 3.7, Python 3.8, Python 3.9 ___ Python tracker <https://bugs.python.org/issue46557> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue41906] logging.config.dictConfig does not work with callable filters
Change by Vinay Sajip : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed versions: +Python 3.11 -Python 3.10 ___ Python tracker <https://bugs.python.org/issue41906> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue41906] logging.config.dictConfig does not work with callable filters
Vinay Sajip added the comment: > If you have any preference about the implementation or any pointer Nothing particular, just try to fit in with the existing code conventions even where they don't follow modern idioms (e.g. a lot of the code in this package predates PEP 8 and new styles of string formatting). -- ___ Python tracker <https://bugs.python.org/issue41906> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue41906] logging.config.dictConfig does not work with callable filters
Vinay Sajip added the comment: > Vinay would you consider a patch for logging where dictConfig allows taking > objects directly in addition to the reference id? Sorry I didn't respond to this; it dropped off my radar. Certainly, I would consider such a patch. -- ___ Python tracker <https://bugs.python.org/issue41906> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46377] TimedRotatingFileHandler "midnight" misleading when interval > 1
Vinay Sajip added the comment: Unfortunately, you can't rely on people always doing "the sensible thing", for any number of good reasons. If a particular set of parameter values didn't cause failure, it is probably used somewhere. Anyway, your problem goes away if interval == 1, right? If we were to tighten things up (e.g. disallowing interval > 1 with "midnight"), then it would have to be done on a deprecation cycle at the very least, ISTM. -- ___ Python tracker <https://bugs.python.org/issue46377> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46377] TimedRotatingFileHandler "midnight" misleading when interval > 1
Vinay Sajip added the comment: Making a change without considering backward compatibility is premature. I've closed the PR as there appears to be something wrong with it - it references hundreds of changed files. Did you look at the 'atTime' keyword parameter of TimedRotatingFileHandler? -- ___ Python tracker <https://bugs.python.org/issue46377> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue42378] logging reopens file with same mode, possibly truncating
Vinay Sajip added the comment: New changeset e35430bec528dfb1a653cd457ea58b5a08543632 by Miss Islington (bot) in branch '3.10': [3.10] bpo-42378: fixed log truncation on logging shutdown (GH-27310) (GH-30468) https://github.com/python/cpython/commit/e35430bec528dfb1a653cd457ea58b5a08543632 -- ___ Python tracker <https://bugs.python.org/issue42378> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue42378] logging reopens file with same mode, possibly truncating
Vinay Sajip added the comment: I guess it got missed during the 3.10 beta cycle by not being backported - it might have needed to be cherry-picked. I'll see about getting it backported to 3.10. -- ___ Python tracker <https://bugs.python.org/issue42378> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46292] Add microseconds to logging.LogRecord
Vinay Sajip added the comment: Thanks for the patch. We're need to get contributors to sign a Contributor License Agreement (CLA) before we can accept their patches. Would you be willing to do this? The process could be smoother, but it's not too bad, and here's where you get started: https://www.python.org/psf/contrib/contrib-form/ -- ___ Python tracker <https://bugs.python.org/issue46292> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46292] Add microseconds to logging.LogRecord
Change by Vinay Sajip : -- versions: +Python 3.11 ___ Python tracker <https://bugs.python.org/issue46292> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue41011] [venv] record which executable and command were used to create a virtual environment
Vinay Sajip added the comment: New changeset f4e325c21d6d9c2bf70224dc69d707b226f87872 by andrei kulakov in branch 'main': bpo-41011: venv -- add more variables to pyvenv.cfg (GH-30382) https://github.com/python/cpython/commit/f4e325c21d6d9c2bf70224dc69d707b226f87872 -- ___ Python tracker <https://bugs.python.org/issue41011> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46251] logger.config.configure_formatter executes arbitrary code
Vinay Sajip added the comment: I'm closing with the assumption that the addition to the documentation covers this. If that needs to be improved, this can be reopened with specific suggestions. -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.org/issue46251> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46251] logger.config.configure_formatter executes arbitrary code
Vinay Sajip added the comment: New changeset 188fbdee0d6721a948eabb81cdcacac371614793 by Miss Islington (bot) in branch '3.9': [3.9] bpo-46251: Add 'Security Considerations' section to logging configura… (GH-30411) (GH-30448) https://github.com/python/cpython/commit/188fbdee0d6721a948eabb81cdcacac371614793 -- ___ Python tracker <https://bugs.python.org/issue46251> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46251] logger.config.configure_formatter executes arbitrary code
Vinay Sajip added the comment: New changeset db60ed1170a02189a4fd4b7574e0722dd22c658b by Miss Islington (bot) in branch '3.10': [3.10] bpo-46251: Add 'Security Considerations' section to logging configura… (GH-30411) (GH-30447) https://github.com/python/cpython/commit/db60ed1170a02189a4fd4b7574e0722dd22c658b -- ___ Python tracker <https://bugs.python.org/issue46251> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46251] logger.config.configure_formatter executes arbitrary code
Vinay Sajip added the comment: New changeset 46c7a6566bca2e974a89c90c35ed1c498d9d3b02 by Vinay Sajip in branch 'main': bpo-46251: Add 'Security Considerations' section to logging configura… (GH-30411) https://github.com/python/cpython/commit/46c7a6566bca2e974a89c90c35ed1c498d9d3b02 -- ___ Python tracker <https://bugs.python.org/issue46251> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46251] logger.config.configure_formatter executes arbitrary code
Vinay Sajip added the comment: I've created a PR to add a "Security Considerations" section in the configuration documentation. Comments on the PR are welcome. -- stage: patch review -> ___ Python tracker <https://bugs.python.org/issue46251> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46251] logger.config.configure_formatter executes arbitrary code
Change by Vinay Sajip : -- keywords: +patch pull_requests: +28617 stage: -> patch review pull_request: https://github.com/python/cpython/pull/30411 ___ Python tracker <https://bugs.python.org/issue46251> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46251] logger.config.configure_formatter executes arbitrary code
Vinay Sajip added the comment: > "Dont load untrusted config files" is the answer I expected. Yes. It's the usual convenience vs. security trade-off. To make configuration convenient, configurable factories with configurable parameters are provided. Can this be misused? Of course. Digital signing has its place where auditability and accountability are important, but it would normally only be used in production where configuration changes are subject to a strict process with signoffs. There could definitely be stronger warnings in the documentation about trust and configurations. > Is it reasonable to say that all classes by _resolve() and resolve() should > have "logger." at the top of them? If not perhaps the object could have a > permitted list of top level packages that defaults to just "logger." but > could be extended to others by the developer. I would think that's going too far, and perhaps it only moves the problem. In any case, dictConfig has a mechanism using the "()" key which allows any callable, not just a class. This is for a not uncommon use case where the callable is a function that returns a logging object (handler/formatter/filter) that has been tweaked in some way. But that feature can of course also be used with untrusted inputs to produce surprises. -- ___ Python tracker <https://bugs.python.org/issue46251> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46200] Discourage logging f-strings due to security considerations
Vinay Sajip added the comment: Another (minor) point against using f-strings or .format is that formatting prematurely might be doing unnecessary work - by default, logging formats messages lazily, waiting until a message actually needs to be output. This could perhaps be more prominently emphasized in the docs where formatting is first introduced. -- ___ Python tracker <https://bugs.python.org/issue46200> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46063] TimedRotatingFileHandler deletes wrong files
Vinay Sajip added the comment: New changeset 17260e44b5ed3508e3c15f1b7ded761879e91d3e by Miss Islington (bot) in branch '3.9': [3.9] bpo-46063: Add 'delay=True' to file handler initialization. (GH-30103) (GH-30105) https://github.com/python/cpython/commit/17260e44b5ed3508e3c15f1b7ded761879e91d3e -- ___ Python tracker <https://bugs.python.org/issue46063> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46063] TimedRotatingFileHandler deletes wrong files
Vinay Sajip added the comment: New changeset 908fd691f96403a3c30d85c17dd74ed1f26a60fd by Miss Islington (bot) in branch '3.10': [3.10] bpo-46063: Add 'delay=True' to file handler initialization. (GH-30103) (GH-30104) https://github.com/python/cpython/commit/908fd691f96403a3c30d85c17dd74ed1f26a60fd -- ___ Python tracker <https://bugs.python.org/issue46063> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46063] TimedRotatingFileHandler deletes wrong files
Vinay Sajip added the comment: New changeset 850aefc2c651110a784cd5478af9774b1f6287a3 by Vinay Sajip in branch 'main': bpo-46063: Add 'delay=True' to file handler initialization. (GH-30103) https://github.com/python/cpython/commit/850aefc2c651110a784cd5478af9774b1f6287a3 -- ___ Python tracker <https://bugs.python.org/issue46063> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46063] TimedRotatingFileHandler deletes wrong files
Change by Vinay Sajip : -- pull_requests: +28326 pull_request: https://github.com/python/cpython/pull/30103 ___ Python tracker <https://bugs.python.org/issue46063> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46063] TimedRotatingFileHandler deletes wrong files
Vinay Sajip added the comment: Ah ... forgot to set delay=True for the handlers. Will look at this soon. -- ___ Python tracker <https://bugs.python.org/issue46063> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46028] 3.11.0a3: sys._base_executable is wrong, breaks venv - it wasn't under 3.11.0a2
Change by Vinay Sajip : -- title: 3.11.0a3: under tox, sys._base_executable is wrong -> 3.11.0a3: sys._base_executable is wrong, breaks venv - it wasn't under 3.11.0a2 ___ Python tracker <https://bugs.python.org/issue46028> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue23010] "unclosed file" warning when defining unused logging FileHandler in dictConfig
Change by Vinay Sajip : -- resolution: -> not a bug stage: -> resolved status: open -> closed ___ Python tracker <https://bugs.python.org/issue23010> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46063] TimedRotatingFileHandler deletes wrong files
Change by Vinay Sajip : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.org/issue46063> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46063] TimedRotatingFileHandler deletes wrong files
Vinay Sajip added the comment: New changeset 94234228abbb84945a48049a7515dea960bc9834 by Miss Islington (bot) in branch '3.9': [3.9] bpo-46063: Improve algorithm for computing which rolled-over log file… (GH-30093) (GH-30095) https://github.com/python/cpython/commit/94234228abbb84945a48049a7515dea960bc9834 -- ___ Python tracker <https://bugs.python.org/issue46063> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46063] TimedRotatingFileHandler deletes wrong files
Vinay Sajip added the comment: New changeset f84e2f6c0aca97c59ec8ce21715ae9bd89893307 by Miss Islington (bot) in branch '3.10': [3.10] bpo-46063: Improve algorithm for computing which rolled-over log file… (GH-30093) (GH-30094) https://github.com/python/cpython/commit/f84e2f6c0aca97c59ec8ce21715ae9bd89893307 -- ___ Python tracker <https://bugs.python.org/issue46063> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46063] TimedRotatingFileHandler deletes wrong files
Vinay Sajip added the comment: New changeset cb589d1b6bad4b75852c2e2a471a3800d5efdca7 by Vinay Sajip in branch 'main': bpo-46063: Improve algorithm for computing which rolled-over log file… (GH-30093) https://github.com/python/cpython/commit/cb589d1b6bad4b75852c2e2a471a3800d5efdca7 -- ___ Python tracker <https://bugs.python.org/issue46063> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46028] 3.11.0a3: under tox, sys._base_executable is wrong
Vinay Sajip added the comment: > This is the intended behaviour, and yes it's changed from previous versions > ... The previous value was incorrect, hence it was marked as an internal > field. But the value as it's calculated now seems to give a file that doesn't exist - how can that be correct? -- ___ Python tracker <https://bugs.python.org/issue46028> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46063] TimedRotatingFileHandler deletes wrong files
Change by Vinay Sajip : -- keywords: +patch pull_requests: +28316 stage: -> patch review pull_request: https://github.com/python/cpython/pull/30093 ___ Python tracker <https://bugs.python.org/issue46063> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue43749] venv module does not copy the correct python exe
Vinay Sajip added the comment: New changeset bad16f0cf71a6b11ef62f86be6b3d3567cd70a16 by Miss Islington (bot) in branch '3.9': [3.9] bpo-43749: Ensure current exe is copied when using venv on windows (GH-25216) (GH-30033) https://github.com/python/cpython/commit/bad16f0cf71a6b11ef62f86be6b3d3567cd70a16 -- ___ Python tracker <https://bugs.python.org/issue43749> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue43749] venv module does not copy the correct python exe
Vinay Sajip added the comment: New changeset bb8d645f3a09645686cf8f66bd46dcfa4efac713 by Miss Islington (bot) in branch '3.10': [3.10] bpo-43749: Ensure current exe is copied when using venv on windows (GH-25216) (GH-30034) https://github.com/python/cpython/commit/bb8d645f3a09645686cf8f66bd46dcfa4efac713 -- ___ Python tracker <https://bugs.python.org/issue43749> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue43749] venv module does not copy the correct python exe
Vinay Sajip added the comment: *3.8, I meant. -- ___ Python tracker <https://bugs.python.org/issue43749> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue43749] venv module does not copy the correct python exe
Vinay Sajip added the comment: 3.10 and 3.9 - OK, but 3. is security fixes only, I'm afraid. -- ___ Python tracker <https://bugs.python.org/issue43749> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[Python-announce] ANN: distlib 0.3.4 released on PyPI
I've recently released version 0.3.4 of distlib on PyPI [1]. For newcomers, distlib is a library of packaging functionality which is intended to be usable as the basis for third-party packaging tools. The main changes in this release are as follows: * Fixed #153: Raise warnings in get_distributions() if bad metadata seen, but keep going. * Fixed #154: Determine Python versions correctly for Python >= 3.10. * Updated launcher executables with changes to handle duplication logic. Code relating to support for Python 2.6 was also removed (support for Python 2.6 was dropped in an earlier release, but supporting code wasn't removed until now). A more detailed change log is available at [2]. Please try it out, and if you find any problems or have any suggestions for improvements, please give some feedback using the issue tracker! [3] Regards, Vinay Sajip [1] https://pypi.org/project/distlib/0.3.4/ [2] https://distlib.readthedocs.io/en/0.3.4/ [3] https://bitbucket.org/pypa/distlib/issues/new ___ Python-announce-list mailing list -- python-announce-list@python.org To unsubscribe send an email to python-announce-list-le...@python.org https://mail.python.org/mailman3/lists/python-announce-list.python.org/ Member address: arch...@mail-archive.com
ANN: distlib 0.3.4 released on PyPI
I've recently released version 0.3.4 of distlib on PyPI [1]. For newcomers, distlib is a library of packaging functionality which is intended to be usable as the basis for third-party packaging tools. The main changes in this release are as follows: * Fixed #153: Raise warnings in get_distributions() if bad metadata seen, but keep going. * Fixed #154: Determine Python versions correctly for Python >= 3.10. * Updated launcher executables with changes to handle duplication logic. Code relating to support for Python 2.6 was also removed (support for Python 2.6 was dropped in an earlier release, but supporting code wasn't removed until now). A more detailed change log is available at [2]. Please try it out, and if you find any problems or have any suggestions for improvements, please give some feedback using the issue tracker! [3] Regards, Vinay Sajip [1] https://pypi.org/project/distlib/0.3.4/ [2] https://distlib.readthedocs.io/en/0.3.4/ [3] https://bitbucket.org/pypa/distlib/issues/new -- https://mail.python.org/mailman/listinfo/python-list
[issue35821] Clarify when logging events are propagated when propagate is true
Change by Vinay Sajip : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.org/issue35821> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue35821] Clarify when logging events are propagated when propagate is true
Vinay Sajip added the comment: New changeset e688568cdfe758a2316ecaf0c8df868d5dde0d83 by Miss Islington (bot) in branch '3.9': [3.9] bpo-35821: Add an example to Logger.propagate documentation. (GH-29841) (GH-29958) https://github.com/python/cpython/commit/e688568cdfe758a2316ecaf0c8df868d5dde0d83 -- ___ Python tracker <https://bugs.python.org/issue35821> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue35821] Clarify when logging events are propagated when propagate is true
Vinay Sajip added the comment: New changeset f78c229b4ec8621a9b15c6396b6c91518e8975d6 by Miss Islington (bot) in branch '3.10': [3.10] bpo-35821: Add an example to Logger.propagate documentation. (GH-29841) (GH-29957) https://github.com/python/cpython/commit/f78c229b4ec8621a9b15c6396b6c91518e8975d6 -- ___ Python tracker <https://bugs.python.org/issue35821> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue35821] Clarify when logging events are propagated when propagate is true
Vinay Sajip added the comment: New changeset 2bf551757e0a7e3cc6ce2ebed2178b82438ac6b5 by Vinay Sajip in branch 'main': bpo-35821: Add an example to Logger.propagate documentation. (GH-29841) https://github.com/python/cpython/commit/2bf551757e0a7e3cc6ce2ebed2178b82438ac6b5 -- ___ Python tracker <https://bugs.python.org/issue35821> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[Python-announce] ANN: A new library for encryption and signing has been released.
A new library called pagesign (Python-age-sign) has been released on PyPI [1]. It covers similar functionality to python-gnupg, but uses the modern encryption tool age [2] and the modern signing tool minisign [3]. The initial release allows you to: * Create and manage identities (which are containers for the keys used for encryption/decryption and signing/verification). * Encrypt and decrypt files to multiple recipients. * Sign files and verify signatures. This release has been signed with my code signing key: Vinay Sajip (CODE SIGNING KEY) Fingerprint: CA74 9061 914E AC13 8E66 EADB 9147 B477 339A 9B86 Recent changes to PyPI don't show the GPG signature with the download links. An alternative download source where the signatures are available is at [4]. Documentation is available at [5]. As always, your feedback is most welcome (especially bug reports [6], patches and suggestions for improvement, or any other points). Enjoy! Cheers Vinay Sajip [1] https://pypi.org/project/pagesign/0.1.0/ [2] https://age-encryption.org/ [3] https://jedisct1.github.io/minisign/ [4] https://bitbucket.org/vinay.sajip/pagesign/downloads/ [5] https://docs.red-dove.com/pagesign/ [6] https://github.com/vsajip/pagesign/issues/new/choose ___ Python-announce-list mailing list -- python-announce-list@python.org To unsubscribe send an email to python-announce-list-le...@python.org https://mail.python.org/mailman3/lists/python-announce-list.python.org/ Member address: arch...@mail-archive.com
ANN: A new library for encryption and signing has been released.
A new library called pagesign (Python-age-sign) has been released on PyPI [1]. It covers similar functionality to python-gnupg, but uses the modern encryption tool age [2] and the modern signing tool minisign [3]. The initial release allows you to: * Create and manage identities (which are containers for the keys used for encryption/decryption and signing/verification). * Encrypt and decrypt files to multiple recipients. * Sign files and verify signatures. This release has been signed with my code signing key: Vinay Sajip (CODE SIGNING KEY) Fingerprint: CA74 9061 914E AC13 8E66 EADB 9147 B477 339A 9B86 Recent changes to PyPI don't show the GPG signature with the download links. An alternative download source where the signatures are available is at [4]. Documentation is available at [5]. As always, your feedback is most welcome (especially bug reports [6], patches and suggestions for improvement, or any other points). Enjoy! Cheers Vinay Sajip [1] https://pypi.org/project/pagesign/0.1.0/ [2] https://age-encryption.org/ [3] https://jedisct1.github.io/minisign/ [4] https://bitbucket.org/vinay.sajip/pagesign/downloads/ [5] https://docs.red-dove.com/pagesign/ [6] https://github.com/vsajip/pagesign/issues/new/choose -- https://mail.python.org/mailman/listinfo/python-list
[issue44391] PC/launcher.c,one more argument than required
Change by Vinay Sajip : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed versions: +Python 3.9 ___ Python tracker <https://bugs.python.org/issue44391> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue44391] PC/launcher.c,one more argument than required
Vinay Sajip added the comment: New changeset af39cfa6ca1e5dc4e5d28c1f09a875a14354e4ae by Miss Islington (bot) in branch '3.10': [3.10] bpo-44391: Remove unused argument from a varargs call. (GH-29843) (GH-29849) https://github.com/python/cpython/commit/af39cfa6ca1e5dc4e5d28c1f09a875a14354e4ae -- ___ Python tracker <https://bugs.python.org/issue44391> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue44391] PC/launcher.c,one more argument than required
Vinay Sajip added the comment: New changeset 40a57532a5ad5dfd81ab6c72c5fb2e2dc4509199 by Miss Islington (bot) in branch '3.9': [3.9] bpo-44391: Remove unused argument from a varargs call. (GH-29843) (GH-29850) https://github.com/python/cpython/commit/40a57532a5ad5dfd81ab6c72c5fb2e2dc4509199 -- ___ Python tracker <https://bugs.python.org/issue44391> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue44391] PC/launcher.c,one more argument than required
Vinay Sajip added the comment: New changeset 4141d94fa608cdf5c8cd3e62f7ea1c27fd41eb8d by Vinay Sajip in branch 'main': bpo-44391: Remove unused argument from a varargs call. (GH-29843) https://github.com/python/cpython/commit/4141d94fa608cdf5c8cd3e62f7ea1c27fd41eb8d -- ___ Python tracker <https://bugs.python.org/issue44391> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue44391] PC/launcher.c,one more argument than required
Change by Vinay Sajip : -- keywords: +patch pull_requests: +28072 stage: -> patch review pull_request: https://github.com/python/cpython/pull/29843 ___ Python tracker <https://bugs.python.org/issue44391> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue35821] Clarify when logging events are propagated when propagate is true
Change by Vinay Sajip : -- keywords: +patch pull_requests: +28070 stage: needs patch -> patch review pull_request: https://github.com/python/cpython/pull/29841 ___ Python tracker <https://bugs.python.org/issue35821> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue28499] Logging module documentation needs a rework.
Vinay Sajip added the comment: Closing, as no objections raised. -- resolution: -> not a bug stage: needs patch -> resolved status: open -> closed ___ Python tracker <https://bugs.python.org/issue28499> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue23010] "unclosed file" warning when defining unused logging FileHandler in dictConfig
Vinay Sajip added the comment: This had dropped off my radar completely, but I still can't see where there's an actual bug here. This simplified script: import logging import sys LOGGING = { 'version': 1, 'handlers': { 'logfile': { 'level': 'DEBUG', 'class': 'logging.FileHandler', 'filename': '/tmp/debug.log', }, }, } print('Starting: %s' % sys.version) from logging.config import dictConfig dictConfig(LOGGING) print('After dictconfig') print('_handlerList 1, initial:', logging._handlerList, len(logging._handlers)) import importlib print('_handlerList 2, about to import shutil:', logging._handlerList, len(logging._handlers)) import shutil print('_handlerList 3, just imported shutil:', logging._handlerList, len(logging._handlers)) print('') when run with Python 3.10, produces Starting: 3.10.0+ (heads/3.10:7203ecd332, Oct 29 2021, 10:04:19) [GCC 7.5.0] After dictconfig _handlerList 1, initial: [] 1 _handlerList 2, about to import shutil: [] 1 /home/vinay/.local/lib/python3.10/_compression.py:33: ResourceWarning: unclosed file <_io.FileIO name='/tmp/debug.log' mode='ab' closefd=True> class DecompressReader(io.RawIOBase): ResourceWarning: Enable tracemalloc to get the object allocation traceback _handlerList 3, just imported shutil: [] 0 But ... there are no loggers that use this handler, so the only reference would be the weak reference in _handlerList - it gets freed up at some point (in this case, when shutil is imported, but I don't believe that's necessarily relevant) and that causes the ResourceWarning, but where's the problem? If you either add a reference to the handler (by adding it to a logger) or adding "delay: True" to the handler configuration dict to delay opening the file, the ResourceWarning is no longer seen. I tested with Python 3.4 - 3.10 and all versions behave the same way - it could just be down to where weak references get dumped, which is down to the vagaries of GC. I don't see this as a "leak" - the ResourceWarning is showing the developer that they opened a file for no particular reason and didn't use it. -- ___ Python tracker <https://bugs.python.org/issue23010> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue45682] Nicer default logging format
Vinay Sajip added the comment: > They too could pass a format argument themselves rather then relying on the > default format never changing. Changes to the stdlib shouldn't require changing previously working code (sometimes months or years old) to fix breakage caused by new stdlib changes. -- ___ Python tracker <https://bugs.python.org/issue45682> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue45682] Nicer default logging format
Vinay Sajip added the comment: > However in the case of logging, an argument could be made that changing the > default would have less impact. Except that people may have used the current basic format in, for example, unit tests, and that code could break after a change like the one proposed. The default has been intentionally kept minimal for the very simplest of needs and it is easy to override this default using e.g. basicConfig() for simple needs or e.g. dictConfig() for more elaborate needs. For those reasons, I don't think this default should be changed. -- resolution: -> rejected stage: -> resolved status: open -> closed ___ Python tracker <https://bugs.python.org/issue45682> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue45628] TimedRotatingFileHandler backupCount not working
Vinay Sajip added the comment: It's possible this crept in during the fix for bpo-44753. -- ___ Python tracker <https://bugs.python.org/issue45628> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue45628] TimedRotatingFileHandler backupCount not working
Vinay Sajip added the comment: N.B. I was able to reproduce this on recent 3.9 versions as well. -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.org/issue45628> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue45628] TimedRotatingFileHandler backupCount not working
Vinay Sajip added the comment: New changeset 191a93905a84f272b2232701dc5dcc69987330f5 by Miss Islington (bot) in branch '3.10': [3.10] bpo-45628: Check all parts of the suffix for an extension match. (GH-29310) (GH-29314) https://github.com/python/cpython/commit/191a93905a84f272b2232701dc5dcc69987330f5 -- ___ Python tracker <https://bugs.python.org/issue45628> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue45628] TimedRotatingFileHandler backupCount not working
Vinay Sajip added the comment: New changeset 317e0c99e3804310f4bee23e497d9d84b717d7f7 by Miss Islington (bot) in branch '3.9': [3.9] bpo-45628: Check all parts of the suffix for an extension match. (GH-29310) (GH-29313) https://github.com/python/cpython/commit/317e0c99e3804310f4bee23e497d9d84b717d7f7 -- ___ Python tracker <https://bugs.python.org/issue45628> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue45628] TimedRotatingFileHandler backupCount not working
Vinay Sajip added the comment: New changeset 8a77f59de51f1fd6062f0fefe73ee3059d714144 by Vinay Sajip in branch 'main': bpo-45628: Check all parts of the suffix for an extension match. (GH-29310) https://github.com/python/cpython/commit/8a77f59de51f1fd6062f0fefe73ee3059d714144 -- ___ Python tracker <https://bugs.python.org/issue45628> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue45628] TimedRotatingFileHandler backupCount not working
Change by Vinay Sajip : -- keywords: +patch pull_requests: +27578 stage: -> patch review pull_request: https://github.com/python/cpython/pull/29310 ___ Python tracker <https://bugs.python.org/issue45628> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue45465] logging messages are needlessly reformatted for every handler
Vinay Sajip added the comment: Oh, I see what you mean now - I was thinking of the overall message formatted using a formatter. However, filters can still change a record's attributes and getMessage() could behave differently on different calls because of this. Changing things in this area could break existing code. -- ___ Python tracker <https://bugs.python.org/issue45465> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue45465] logging messages are needlessly reformatted for every handler
Vinay Sajip added the comment: A developer may wish to format messages differently for different audiences (i.e. different handlers) - for example, omit stack traces. This behaviour is by design. -- resolution: -> not a bug stage: -> resolved status: open -> closed ___ Python tracker <https://bugs.python.org/issue45465> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue45401] logging TimedRotatingFileHandler must not rename devices like /dev/null
Vinay Sajip added the comment: Where did you see the warnings? I didn't spot anything in the GitHub Actions logs. -- ___ Python tracker <https://bugs.python.org/issue45401> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue45401] logging TimedRotatingFileHandler must not rename devices like /dev/null
Change by Vinay Sajip : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.org/issue45401> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue45401] logging TimedRotatingFileHandler must not rename devices like /dev/null
Change by Vinay Sajip : -- keywords: +patch pull_requests: +27140 stage: -> patch review pull_request: https://github.com/python/cpython/pull/28822 ___ Python tracker <https://bugs.python.org/issue45401> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue45401] logging TimedRotatingFileHandler must not rename devices like /dev/null
Vinay Sajip added the comment: RotatingFileHandler is also affected by the same issue. Both RotatingFileHandler and TimedRotatingFileHandler have a shouldRollover method which, if it returns False, should prevent rollover. I would think that putting something like if not os.path.isfile(self.baseFilename): return False at the top of each of these methods should avoid rolling over any thing that isn't a regular file - devices, pipes etc. Would you agree? Can you see any drawbacks? I'm not sure this would cover sockets, but there are separate handlers for using sockets so there would be no reason for people to use sockets with file handlers. And of course sockets are a completely different sort of beast on Windows. -- ___ Python tracker <https://bugs.python.org/issue45401> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[Python-announce] ANN: distlib 0.3.3 released on PyPI
I've recently released version 0.3.3 of distlib on PyPI [1]. For newcomers, distlib is a library of packaging functionality which is intended to be usable as the basis for third-party packaging tools. The main changes in this release are as follows: * Fixed #152: Removed splituser() function which wasn't used and is deprecated. * Fixed #149: Handle version comparisons correctly in environment markers. * Add ARM-64 launchers and support code to use them. Thanks to Niyas Sait and Adrian Vladu for their contributions. * Fixed #148: Handle a single trailing comma following a version. Thanks to Blazej Floch for the report and suggested fix. * Fixed #150: Fix incorrect handling of epochs. * Reverted handling of tags for Python >= 3.10 (use 310 rather than 3_10). This is because PEP 641 was rejected. * Added a GitHub Actions workflow to perform tests. A more detailed change log is available at [2]. Please try it out, and if you find any problems or have any suggestions for improvements, please give some feedback using the issue tracker! [3] Regards, Vinay Sajip [1] https://pypi.org/project/distlib/0.3.3/ [2] https://distlib.readthedocs.io/en/0.3.3/ [3] https://bitbucket.org/pypa/distlib/issues/new ___ Python-announce-list mailing list -- python-announce-list@python.org To unsubscribe send an email to python-announce-list-le...@python.org https://mail.python.org/mailman3/lists/python-announce-list.python.org/ Member address: arch...@mail-archive.com
ANN: distlib 0.3.3 released on PyPI
I've recently released version 0.3.3 of distlib on PyPI [1]. For newcomers, distlib is a library of packaging functionality which is intended to be usable as the basis for third-party packaging tools. The main changes in this release are as follows: * Fixed #152: Removed splituser() function which wasn't used and is deprecated. * Fixed #149: Handle version comparisons correctly in environment markers. * Add ARM-64 launchers and support code to use them. Thanks to Niyas Sait and Adrian Vladu for their contributions. * Fixed #148: Handle a single trailing comma following a version. Thanks to Blazej Floch for the report and suggested fix. * Fixed #150: Fix incorrect handling of epochs. * Reverted handling of tags for Python >= 3.10 (use 310 rather than 3_10). This is because PEP 641 was rejected. * Added a GitHub Actions workflow to perform tests. A more detailed change log is available at [2]. Please try it out, and if you find any problems or have any suggestions for improvements, please give some feedback using the issue tracker! [3] Regards, Vinay Sajip [1] https://pypi.org/project/distlib/0.3.3/ [2] https://distlib.readthedocs.io/en/0.3.3/ [3] https://bitbucket.org/pypa/distlib/issues/new -- https://mail.python.org/mailman/listinfo/python-list
[issue45027] Allow basicConfig to configure any logger, not just root
Vinay Sajip added the comment: > This selectively _disables_ a logger. That isn't the same thing as > selectively _enabling_ only the loggers you want to enable. Your earlier comment referred to getting unwanted messages from third-party loggers. Suppressing the messages implies disabling them in some way. > That's fair enough, but why make people do the above (which is somewhat > unintuitive) That's your opinion, but it doesn't seem that this view is widespread. We provide basicConfig() for simple configuration and dictConfig() for more elaborate requirements; dictConfig() was reviewed by Python developers in PEP 391 and accepted. > I could also publish this as a separate package on PyPI By all means, do that. As I've already said, I've no wish to add yet another way of configuring logging. If your PyPI package gains wide adoption, we can always revisit this. -- resolution: -> rejected stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.org/issue45027> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue45027] Allow basicConfig to configure any logger, not just root
Vinay Sajip added the comment: > This change serves the purpose of making it easier to configure non-root > loggers. My point was, they don't need to configure non-root loggers (in terms of adding handlers) because the root logger's handlers will normally be used for all loggers. > However, if you configure the root logger in your application, you will see > those [other libraries'] log messages. Users certainly don't need an API change to prevent that, should they wish to. The following simple call will suffice (using 'gnupg' just as an example): logging.getLogger('gnupg').setLevel(logging.CRITICAL + 1) > I would frame this proposal as a third configuration option As you can see, it's not needed for the purpose you described (avoiding messages from third-party loggers). > it would be nice to adjust the type stubs for dictConfig() to use a TypedDict > ... I'm happy to make a PR to Typeshed for it, though! Sure, sounds like a good idea. > I also think there should be a note about dictConfig() in the docs for > basicConfig() ... Again, I'm happy to make a separate PR for that change. By all means. You could also look at updating the cookbook content, if you feel that parts relating to the concerns expressed in this issue could be expanded on. -- ___ Python tracker <https://bugs.python.org/issue45027> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
Re: ANN: Version 0.5.1 of the Python config module has been released.
Many of those 4.8K "users" might be using indirectly via some other dependency - I'm not sure how GitHub calculates "used by", but even if it were a direct dependency, one has no idea if it's actually being used or not. so I tend not to worry about such things. My distlib library has only 2 stars, and is used by pip and therefore by many developers every day, and yet it doesn't merit a "used by" according to GitHub. I've had a few users contact me about the config library and they're happy with it and they find it useful, and that's good enough for me :-) On Sunday, 12 September 2021, 18:11:21 BST, Abdur-Rahmaan Janhangeer wrote: Used by 4.8k but only ... 4 stars -- https://mail.python.org/mailman/listinfo/python-list
[Python-announce] ANN: Version 0.5.1 of the Python config module has been released.
What Does It Do? The CFG configuration format is a text format for configuration files which is similar to, and a superset of, the JSON format.It has the following aims: * Allow a hierarchical configuration scheme with support for key-value mappings and lists. * Support cross-references between one part of the configuration and another. * Provide a string interpolation facility to easily build up configuration values from other configuration values. * Provide the ability to compose configurations (using include and merge facilities). * Provide the ability to access real application objects safely. * Be completely declarative. It overcomes a number of drawbacks of JSON when used as a configuration format: * JSON is more verbose than necessary. * JSON doesn’t allow comments. * JSON doesn’t provide first-class support for dates and multi-line strings. * JSON doesn’t allow trailing commas in lists and mappings. * JSON doesn’t provide easy cross-referencing, interpolation, or composition. The Python config module provides an interface to work with configuration files written in the CFG format. Comprehensive documentation is available at https://docs.red-dove.com/cfg/index.html and you can report issues / enhancement requests at https://github.com/vsajip/py-cfg-lib/issues As always, your feedback is most welcome (especially bug reports, patches and suggestions for improvement). Enjoy! Cheers, Vinay Sajip ___ Python-announce-list mailing list -- python-announce-list@python.org To unsubscribe send an email to python-announce-list-le...@python.org https://mail.python.org/mailman3/lists/python-announce-list.python.org/ Member address: arch...@mail-archive.com
ANN: Version 0.5.1 of the Python config module has been released.
What Does It Do? The CFG configuration format is a text format for configuration files which is similar to, and a superset of, the JSON format.It has the following aims: * Allow a hierarchical configuration scheme with support for key-value mappings and lists. * Support cross-references between one part of the configuration and another. * Provide a string interpolation facility to easily build up configuration values from other configuration values. * Provide the ability to compose configurations (using include and merge facilities). * Provide the ability to access real application objects safely. * Be completely declarative. It overcomes a number of drawbacks of JSON when used as a configuration format: * JSON is more verbose than necessary. * JSON doesn’t allow comments. * JSON doesn’t provide first-class support for dates and multi-line strings. * JSON doesn’t allow trailing commas in lists and mappings. * JSON doesn’t provide easy cross-referencing, interpolation, or composition. The Python config module provides an interface to work with configuration files written in the CFG format. Comprehensive documentation is available at https://docs.red-dove.com/cfg/index.html and you can report issues / enhancement requests at https://github.com/vsajip/py-cfg-lib/issues As always, your feedback is most welcome (especially bug reports, patches and suggestions for improvement). Enjoy! Cheers, Vinay Sajip -- https://mail.python.org/mailman/listinfo/python-list
[issue44489] _handle_existing_loggers should respect loggers that were manually disabled
Vinay Sajip added the comment: Closing, as no further feedback received on this issue. You can reopen if you have an answer to my question. -- resolution: -> not a bug stage: -> resolved status: open -> closed ___ Python tracker <https://bugs.python.org/issue44489> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue45027] Allow basicConfig to configure any logger, not just root
Vinay Sajip added the comment: Thanks, but ... > I observe that many Python users tend to use basicConfig() even when they > would be better served by configuring only the logger(s) needed for their own > app/library. First of all, library developers should not be configuring loggers at all, other than adding a NullHandler to their top-level logger. Secondly, it is fine to configure the root logger and then log to any other logger. The default mechanisms mean that handlers added to the root logger are used by loggers which are anywhere in the logger hierarchy. So users that are using basicConfig() but other loggers than the root logger may be using the system as designed. Thirdly, logging.config.dictConfig() allows usage of a dictionary to configure multiple loggers, handlers etc. all at once, for use cases which are more demanding than basicConfig(). It doesn't make sense to do what you're proposing, since it appears to offer a different way of configuring other loggers than the root logger, when dictConfig() already offers that. So, I am minded to not agree to this change, and would prefer that the PR and this issue be closed. -- nosy: +vinay.sajip ___ Python tracker <https://bugs.python.org/issue45027> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue44924] logging.handlers.QueueHandler does not maintain the exc_text
Vinay Sajip added the comment: It might be inadvisable to make your suggested change because of backward compatibility and breakage of existing code. However, I don't mind updating the logging cookbook to mention your suggested method of resolving the issue for this use case. I'll leave the issue open until I've done that. -- ___ Python tracker <https://bugs.python.org/issue44924> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue44924] logging.handlers.QueueHandler does not maintain the exc_text
Vinay Sajip added the comment: Why can you not subclass QueueHandler and override the prepare method to do what you want/need? -- ___ Python tracker <https://bugs.python.org/issue44924> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue40469] TimedRotatingFileHandler rotating on use not time
Vinay Sajip added the comment: > You are far better and more experienced in maintaining widely used opensource > codebases so I wouldn't argue with you, but... :) Well, if a change introduces a problem, it will be my lookout, won't it? Just as the original patch for bpo-8117 is proving to be :-) OK, how about this? We update the PR to add a new use_ctime=False keyword argument to TimedRotatingHandler.__init__(). If nothing else changes, the behaviour is as it is currently. If use_ctime=True is passed in the instantiation, then the constructor will use CTIME rather than MTIME. Will that work for you? I'd be OK with that approach. -- ___ Python tracker <https://bugs.python.org/issue40469> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue40469] TimedRotatingFileHandler rotating on use not time
Vinay Sajip added the comment: I just checked - the relevant code (using MTIME) was added in 2010, as a fix for bpo-8117 - around the time that Python 2.6 was released. -- ___ Python tracker <https://bugs.python.org/issue40469> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue40469] TimedRotatingFileHandler rotating on use not time
Vinay Sajip added the comment: > Well, there is nothing in the documentation that would say the logrotation > can be only performed by continously running scripts, thats why. :) Well, what's the need to rotate based on time when you just run scripts sporadically or they're very short-lived? Not trying to argue, just trying to understand. > There are scripts or even daemons written in Python that need to be restarted > from time to time. If the logrotate period is greater than restart period the > log files will never be rotated, however they could be. Yes, but generally daemons are long-lived relative to the rotation interval, aren't they? "From time to time" certainly implies that to me. > What is the logic behind checking the MTIME instead of CTIME when one is > calculating the age of a file when tries to calculate whether it has to be > rotated or not? I can't remember, that code is over 12 years old and that specific decision wasn't documented :-( > From the code I have to assume that the original author also tried to prepare > for the cases where the execution is interrupted and/or restarted and (s)he > wanted the TimedLogrotateHandler to be resumed where it was during the > previous execution. Dnn't you agree? I take it you mean TimedRotatingFileHandler. Certainly it assumes that the script might be restarted, which is why it opens the file in append mode. If the computation using MTIME were changed to use CTIME, that would be a behaviour change, which could conceivably break someone's code that relied on current behaviour (unlikely, but you just never know). I've no other objection to using CTIME rather than MTIME - perhaps I'm just being hyper-cautious about breakage? -- ___ Python tracker <https://bugs.python.org/issue40469> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue40469] TimedRotatingFileHandler rotating on use not time
Vinay Sajip added the comment: > The assumed behaviour of TimedRotatingFileHandler is to rotate log files > older than configured. Even when the script is executed multiple times. Ah, but is it? The purpose of TimedRotatingFileHandler is to rotate files based on time intervals, and is normally assumed to be for long-running processes (where the rotation allows one to focus on logs output during a period of interest). What's the practical, real-world use-case for the example scripts you added? -- ___ Python tracker <https://bugs.python.org/issue40469> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com