[issue42378] logging reopens file with same mode, possibly truncating

2021-07-23 Thread Andrei Kulakov
Change by Andrei Kulakov : -- keywords: +patch nosy: +andrei.avk nosy_count: 1.0 -> 2.0 pull_requests: +25855 stage: -> patch review pull_request: https://github.com/python/cpython/pull/27310 ___ Python tracker <https://bugs.python.org/i

[issue42378] logging reopens file with same mode, possibly truncating

2021-07-23 Thread Andrei Kulakov
Andrei Kulakov added the comment: I've put up a PR here: https://github.com/python/cpython/pull/27310/files If this looks good, I will update the docs and add news entry. -- ___ Python tracker <https://bugs.python.org/is

[issue42414] unable to document fields of dataclass

2021-07-23 Thread Andrei Kulakov
Andrei Kulakov added the comment: I was thinking about adding this to named tuple as well, but it's less useful than with dataclasses because named tuples are simpler and smaller. However if this feature is added to dataclasses and is widely used, it would make a lot of sense to expa

[issue42357] Wrong Availability for signal.SIGCHLD

2021-07-23 Thread Andrei Kulakov
Andrei Kulakov added the comment: This can be closed (fixed). -- nosy: +andrei.avk ___ Python tracker <https://bugs.python.org/issue42357> ___ ___ Python-bug

[issue26153] PyImport_GetModuleDict: no module dictionary! when `__del__` triggers a warning

2021-07-25 Thread Andrei Kulakov
Andrei Kulakov added the comment: 3.6 no longer gets bugfixes, so I think this can be closed. -- nosy: +andrei.avk ___ Python tracker <https://bugs.python.org/issue26

[issue32937] Multiprocessing worker functions not terminating with a large number of processes and a manager

2021-07-26 Thread Andrei Kulakov
Andrei Kulakov added the comment: I have confirmed the reproducer posted by Ronald also works for me, on 3.11 compiled from dev branch, also with cpu count == 8; on the new M1 silicon (that shouldn't matter though). I agree this can be closed. -- nosy: +andrei.avk status: pe

[issue44682] Pdb commands allows to add commands to invalid breakpoint

2021-07-26 Thread Andrei Kulakov
Andrei Kulakov added the comment: I agree not backporting is most likely fine; just want to add that the issue here is that it allows you to enter command for an invalid breakpoint, creating a strong impression both that bpoint is valid and that command will be active

[issue42182] 3.10 Documentation Not Hyperlinking Some Methods

2021-07-26 Thread Andrei Kulakov
Andrei Kulakov added the comment: The same thing happens in 3.11. I've also confirmed the markup is exactly the same. -- nosy: +andrei.avk ___ Python tracker <https://bugs.python.org/is

[issue42182] 3.10 Documentation Not Hyperlinking Some Methods

2021-07-26 Thread Andrei Kulakov
Andrei Kulakov added the comment: In this case, it appears that ref with tilde and object makes it work in both 3.10 and 3.11, but with just bare method specified, it doesn't create link in both -- so it may be good to try updating it to have tilde and a ref to obj: Once an itera

[issue42182] 3.10 Documentation Not Hyperlinking Some Methods

2021-07-26 Thread Andrei Kulakov
Andrei Kulakov added the comment: Something changed between 3.8 and 3.9 so that "bare" references to methods on `object` no longer get linked. So for example, :meth:`__bool__` would get link to object.__bool__ anchor, but in 3.9+, it should be :meth:`~object.__bool__` for the

[issue42182] 3.10 Documentation Not Hyperlinking Some Methods

2021-07-26 Thread Andrei Kulakov
Change by Andrei Kulakov : -- type: -> behavior versions: +Python 3.11, Python 3.9 ___ Python tracker <https://bugs.python.org/issue42182> ___ ___ Python-

[issue42128] Structural Pattern Matching (PEP 634)

2021-07-26 Thread Andrei Kulakov
Change by Andrei Kulakov : -- nosy: +andrei.avk nosy_count: 13.0 -> 14.0 pull_requests: +25916 pull_request: https://github.com/python/cpython/pull/27384 ___ Python tracker <https://bugs.python.org/issu

[issue42182] 3.10 Documentation Not Hyperlinking Some Methods

2021-07-26 Thread Andrei Kulakov
Andrei Kulakov added the comment: I put the PR up here: https://github.com/python/cpython/pull/27384/files -- ___ Python tracker <https://bugs.python.org/issue42

[issue42182] 3.10 Documentation Not Hyperlinking Some Methods

2021-07-26 Thread Andrei Kulakov
Change by Andrei Kulakov : -- keywords: +patch pull_requests: +25917 stage: -> patch review pull_request: https://github.com/python/cpython/pull/27384 ___ Python tracker <https://bugs.python.org/issu

[issue33896] Document what components make up the filecmp.cmp os.stat signature.

2021-07-27 Thread Andrei Kulakov
Andrei Kulakov added the comment: Can be closed as a dupe of https://bugs.python.org/issue42958, which has a PR ready for review. -- nosy: +andrei.avk ___ Python tracker <https://bugs.python.org/issue33

[issue42167] Documentation for SETUP_WITH opcode is wrong

2021-07-27 Thread Andrei Kulakov
Andrei Kulakov added the comment: Note that SETUP_WITH doc was completely removed. Not sure if that was intentional (since the opcode itself still exists). -- nosy: +andrei.avk ___ Python tracker <https://bugs.python.org/issue42

[issue40001] ignore errors in SimpleCookie

2021-07-28 Thread Andrei Kulakov
Andrei Kulakov added the comment: Aviram: see issue https://bugs.python.org/issue17340 , there is a lot of old discussions along the same lines. -- nosy: +andrei.avk ___ Python tracker <https://bugs.python.org/issue40

[issue42119] Error when debugging logging.FileHandler subclass __init__ method

2021-07-28 Thread Andrei Kulakov
Andrei Kulakov added the comment: Françoise: You can simply set the two attrs required by __repr__ in the pdb session: ./python.exe ~/temp/a.py --INS-- > /Users/ak/opensource/cpython/Lib/logging/__init__.py(1152)__ini

[issue42626] readline history, vi-editingmode and ANSI color codes bug

2021-07-29 Thread Andrei Kulakov
Andrei Kulakov added the comment: I was able to reproduce something very similar, and I believe essentially the same issue perhaps varying due to config. I think I've actually seen similar glitches with python command line readline handling of k. So, entering 1234 always works fine

[issue42626] readline history, vi-editingmode and ANSI color codes bug

2021-07-29 Thread Andrei Kulakov
Andrei Kulakov added the comment: Also this bug happens on both iterm2 and terminal on MacOS, but note that on 'terminal', it's impossible to ctrl-c or ctrl-z out of the test script, so if you test it, you will need to close the window or the tab, and lose shell history and

[issue42626] readline history, vi-editingmode and ANSI color codes bug

2021-07-29 Thread Andrei Kulakov
Andrei Kulakov added the comment: Joakim: by the way, what I was able to reproduce is just a visual bug. IOW, the text is still the same and all there in the buffer, but it shows up only after a combination of rightward movement and 'a', and a copy of it shows up on the left sid

[issue41911] Language reference for expressions incorrectly specifies what type of object(s) are expected

2021-07-29 Thread Andrei Kulakov
Change by Andrei Kulakov : -- keywords: +patch nosy: +andrei.avk nosy_count: 3.0 -> 4.0 pull_requests: +25989 stage: -> patch review pull_request: https://github.com/python/cpython/pull/27470 ___ Python tracker <https://bugs.python.org/i

[issue41911] Language reference for expressions incorrectly specifies what type of object(s) are expected

2021-07-29 Thread Andrei Kulakov
Andrei Kulakov added the comment: I've put up a PR here: https://github.com/python/cpython/pull/27470/files -- ___ Python tracker <https://bugs.python.org/is

[issue41737] Improper NotADirectoryError when opening a file in a fake directory

2021-07-29 Thread Andrei Kulakov
Change by Andrei Kulakov : -- nosy: +andrei.avk nosy_count: 3.0 -> 4.0 pull_requests: +25990 pull_request: https://github.com/python/cpython/pull/27471 ___ Python tracker <https://bugs.python.org/issu

[issue41737] Improper NotADirectoryError when opening a file in a fake directory

2021-07-29 Thread Andrei Kulakov
Andrei Kulakov added the comment: I've put up a PR that expands the docs for NotADirectoryError here: https://github.com/python/cpython/pull/27471/files -- ___ Python tracker <https://bugs.python.org/is

[issue41737] Improper NotADirectoryError when opening a file in a fake directory

2021-07-30 Thread Andrei Kulakov
Andrei Kulakov added the comment: Danny: that would be inconsistent with the rest of the doc, it's written as a reference list for exceptions and none of them have examples currently.. It also seems fairly clear without an example. -- ___ P

[issue41737] Improper NotADirectoryError when opening a file in a fake directory

2021-07-30 Thread Andrei Kulakov
Andrei Kulakov added the comment: (in fact, there is one example (for f-string exception) but the overall pattern is to just have reference type descriptions) -- ___ Python tracker <https://bugs.python.org/issue41

[issue41737] Improper NotADirectoryError when opening a file in a fake directory

2021-07-30 Thread Andrei Kulakov
Andrei Kulakov added the comment: Danny: then it would be probably more useful to say "On POSIX systems, it will be raised when ...". I'm ambivalent on whether this is needed. Eryk: wdyt? -- ___ Python tracker <https

[issue43625] CSV has_headers heuristic could be improved

2021-07-30 Thread Andrei Kulakov
Andrei Kulakov added the comment: Łukasz: I agree. -- ___ Python tracker <https://bugs.python.org/issue43625> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue41737] Improper NotADirectoryError when opening a file in a fake directory

2021-07-30 Thread Andrei Kulakov
Andrei Kulakov added the comment: Eryk: sounds good, updated the PR. -- ___ Python tracker <https://bugs.python.org/issue41737> ___ ___ Python-bugs-list mailin

[issue41737] Improper NotADirectoryError when opening a file in a fake directory

2021-07-30 Thread Andrei Kulakov
Andrei Kulakov added the comment: Eryk: On MacOS, I get Not a directory error on all 3: NotADirectoryError: [Errno 20] Not a directory: 'spam' NotADirectoryError: [Errno 20] Not a directory: 'spam/' NotADirectoryError: [Errno 20] Not a d

[issue19270] Document that sched.cancel() doesn't distinguish equal events and can break order

2021-07-30 Thread Andrei Kulakov
Andrei Kulakov added the comment: This can be closed as fixed. -- nosy: +andrei.avk ___ Python tracker <https://bugs.python.org/issue19270> ___ ___ Python-bug

[issue42026] index function return first index for same element if repetitive in a list

2021-07-30 Thread Andrei Kulakov
Andrei Kulakov added the comment: this can be closed I believe. -- nosy: +andrei.avk ___ Python tracker <https://bugs.python.org/issue42026> ___ ___ Python-bug

[issue41983] Missing Documentation AF_PACKET

2021-07-31 Thread Andrei Kulakov
Change by Andrei Kulakov : -- keywords: +patch nosy: +andrei.avk nosy_count: 3.0 -> 4.0 pull_requests: +26034 stage: -> patch review pull_request: https://github.com/python/cpython/pull/27519 ___ Python tracker <https://bugs.python.org/i

[issue41983] Missing Documentation AF_PACKET

2021-07-31 Thread Andrei Kulakov
Andrei Kulakov added the comment: I've put up the PR here that makes availability clearer in the docs: https://github.com/python/cpython/pull/27519/files -- ___ Python tracker <https://bugs.python.org/is

[issue41983] Missing Documentation AF_PACKET

2021-07-31 Thread Andrei Kulakov
Change by Andrei Kulakov : -- type: -> behavior versions: +Python 3.10, Python 3.11, Python 3.9 ___ Python tracker <https://bugs.python.org/issue41983> ___ _

[issue42028] Regression in mimetypes for image/bmp

2021-07-31 Thread Andrei Kulakov
Andrei Kulakov added the comment: This was fixed in https://github.com/python/cpython/pull/26300 so the issue can be closed as fixed, and the PR can also be closed. -- nosy: +andrei.avk ___ Python tracker <https://bugs.python.org/issue42

[issue42053] fwalk: incorrect boolean test for non-fd arguments

2021-07-31 Thread Andrei Kulakov
Andrei Kulakov added the comment: dubiousjim: I agree, it should be `and` or have the form `not (isinstance(..) or hasattr(..))`. If you would like to make the patch, I can review. -- nosy: +andrei.avk ___ Python tracker <https://bugs.python.

[issue42053] fwalk: incorrect boolean test for non-fd arguments

2021-07-31 Thread Andrei Kulakov
Andrei Kulakov added the comment: By the way I confirmed that fixing this doesn't break any tests (perhaps unsurprising ;) ) -- ___ Python tracker <https://bugs.python.org/is

[issue41973] Docs: TypedDict is now of type function instead of class

2021-08-01 Thread Andrei Kulakov
Andrei Kulakov added the comment: I haven't looked too much into typing module, so take this with a grain of salt, but my understanding is that TypedDict is a special construct (as the first sentence in the docs defines it), which can be used as a base. I think most users would con

[issue42019] Override MagicMock special methods

2021-08-01 Thread Andrei Kulakov
Andrei Kulakov added the comment: I think this can be closed. -- nosy: +andrei.avk ___ Python tracker <https://bugs.python.org/issue42019> ___ ___ Python-bug

[issue42038] Tracemalloc's format() doc contradictory

2021-08-01 Thread Andrei Kulakov
Change by Andrei Kulakov : -- keywords: +patch nosy: +andrei.avk nosy_count: 2.0 -> 3.0 pull_requests: +26044 stage: -> patch review pull_request: https://github.com/python/cpython/pull/27529 ___ Python tracker <https://bugs.python.org/i

[issue42038] Tracemalloc's format() doc contradictory

2021-08-01 Thread Andrei Kulakov
Andrei Kulakov added the comment: I agree that the doc is wrong; I've put up the tiny PR here: https://github.com/python/cpython/pull/27529/files Note that linecache.getline() returns line with \n but is then .strip()'ed. -- ___ Pyth

[issue41980] Argparse documentation is slightly misleading

2021-08-01 Thread Andrei Kulakov
Andrei Kulakov added the comment: Yannick: the PRs are submitted via github; you can find more detail on contributions workflow / process here: https://devguide.python.org/ -- nosy: +andrei.avk ___ Python tracker <https://bugs.python.

[issue32397] textwrap output may change if you wrap a paragraph twice

2021-08-01 Thread Andrei Kulakov
Andrei Kulakov added the comment: This issue is due to *drop_whitespace* arg being True by default. Documentation states that *drop_whitespace* applies after wrapping, so the fix in the PR would break that promise because, as far as I understand, it applies the wrapping after

[issue44808] test_inspect fails in refleak mode

2021-08-02 Thread Andrei Kulakov
Andrei Kulakov added the comment: Pablo: thanks for investigating and fixing this, I will look for examples of changing or patching sys.modules in the testsuite to see how to avoid global effects. I think we can keep this issue open for the follow-up discussion / fix? -- nosy

[issue44808] test_inspect fails in refleak mode

2021-08-02 Thread Andrei Kulakov
Andrei Kulakov added the comment: I've been looking into avoiding global modification of modules['__main__'], the options are: 1. remove the test and leave it at that 2. remove the test and open a new issue for re-adding a test ; and look for a way to do it safely 3

[issue44808] test_inspect fails in refleak mode

2021-08-02 Thread Andrei Kulakov
Change by Andrei Kulakov : -- pull_requests: +26078 pull_request: https://github.com/python/cpython/pull/27571 ___ Python tracker <https://bugs.python.org/issue44

[issue44808] test_inspect fails in refleak mode

2021-08-02 Thread Andrei Kulakov
Andrei Kulakov added the comment: Please disregard my last comment, I think I found a good way to fix it, the PR is up here: https://github.com/python/cpython/pull/27571/files -- ___ Python tracker <https://bugs.python.org/issue44

[issue32397] textwrap output may change if you wrap a paragraph twice

2021-08-03 Thread Andrei Kulakov
Andrei Kulakov added the comment: I think fix to make `drop_whitespace=False` stable, can be as simple as adding two lines in `_munge_whitespace()`: +text = re.sub(r' \n', ' ', text) +text = re.sub(r'\n ', ' ',

[issue32397] textwrap output may change if you wrap a paragraph twice

2021-08-03 Thread Andrei Kulakov
Andrei Kulakov added the comment: Irit: I assume you mean r' \r?\n', that's a great idea, it's much faster than adding a separate replacement step. Latest version I came up with is this: if re.search(r' \r?\n', text): text

[issue32397] textwrap output may change if you wrap a paragraph twice

2021-08-03 Thread Andrei Kulakov
Andrei Kulakov added the comment: Note that I'm not handling a single '\r' because that was before Mac OS X; but it is handled by the following line (i.e. by the old logic): text = text.translate(self.unicode_w

[issue32397] textwrap output may change if you wrap a paragraph twice

2021-08-03 Thread Andrei Kulakov
Change by Andrei Kulakov : -- pull_requests: +26089 pull_request: https://github.com/python/cpython/pull/27587 ___ Python tracker <https://bugs.python.org/issue32

[issue32397] textwrap output may change if you wrap a paragraph twice

2021-08-03 Thread Andrei Kulakov
Andrei Kulakov added the comment: I've added an initial draft PR: https://github.com/python/cpython/pull/27587/files I will add docs and news if this looks good in general. -- ___ Python tracker <https://bugs.python.org/is

[issue41946] Add concrete examples to os.path documentation

2021-08-04 Thread Andrei Kulakov
Andrei Kulakov added the comment: Some examples were added since this issue was created, but more can be added. Stargirl: feel free to open a PR, I can review it. -- nosy: +andrei.avk ___ Python tracker <https://bugs.python.org/issue41

[issue36424] Pickle fails on frozen dataclass that has slots

2021-08-05 Thread Andrei Kulakov
Andrei Kulakov added the comment: This was fixed in https://github.com/python/cpython/pull/25786 , and so can be closed. -- nosy: +andrei.avk ___ Python tracker <https://bugs.python.org/issue36

[issue33140] shutil.chown should not be defined in Windows

2021-08-05 Thread Andrei Kulakov
Andrei Kulakov added the comment: Jack: I'm not sure if this eventual fix is worth doing.. it might cause issues for users to leave it as is, but can also cause issues to remove it even after deprecation period; I don't have a good feeling if one is more likely than the other,

[issue40935] Links to Python3 docs for some libs return 404

2021-08-05 Thread Andrei Kulakov
Andrei Kulakov added the comment: It looks like all the pages listed were updated with working links to current stable release docs, so this can be closed and if somebody finds more broken links, this issue can be reopened later. -- nosy: +andrei.avk

[issue37529] Mimetype module duplicates

2021-08-06 Thread Andrei Kulakov
Andrei Kulakov added the comment: This was fixed in https://github.com/python/cpython/pull/26300 but wasn't backported. -- nosy: +andrei.avk ___ Python tracker <https://bugs.python.org/is

[issue41779] add BLOB photo to sqlite3 python

2021-08-06 Thread Andrei Kulakov
Andrei Kulakov added the comment: I believe this can be closed now.. -- nosy: +andrei.avk ___ Python tracker <https://bugs.python.org/issue41779> ___ ___ Pytho

[issue25963] strptime not parsing some timezones

2021-08-06 Thread Andrei Kulakov
Andrei Kulakov added the comment: This was fixed so can be closed. Current datetime docs have a footnote for %Z: ... strptime() only accepts certain values for %Z: any value in time.tzname for your machine’s locale the hard-coded values UTC and GMT -- nosy: +andrei.avk

[issue41645] Typo First Page of Documentation

2021-08-07 Thread Andrei Kulakov
Andrei Kulakov added the comment: +1 for '... and uses a simple but effective approach ..' -- nosy: +andrei.avk ___ Python tracker <https://bugs.python.o

[issue44868] misleading error about fd / follow_symlinks from os.stat()

2021-08-08 Thread Andrei Kulakov
New submission from Andrei Kulakov : (note the actual relevant code is in posixmodule.c) os.stat() error can be confusing and misleading when given an fd and with follow_symlinks=False: ValueError: stat: cannot use fd and follow_symlinks together It's less bad when os.stat() is

[issue44868] misleading error about fd / follow_symlinks from os.stat()

2021-08-08 Thread Andrei Kulakov
Andrei Kulakov added the comment: > In addition, fwalk() can probably check that `top` arg is a string and raise > an error stating that it should be a string if it's not. I should clarify that fwalk() cannot accept an fd as the `top` arg, see https://bugs.python.org

[issue44544] Add full list of possible args to textwrap: wrap, fill, shorten

2021-08-08 Thread Andrei Kulakov
Change by Andrei Kulakov : -- pull_requests: +26159 pull_request: https://github.com/python/cpython/pull/27671 ___ Python tracker <https://bugs.python.org/issue44

[issue44873] base64 RFC4648 test cases

2021-08-09 Thread Andrei Kulakov
New submission from Andrei Kulakov : RFC 4648 [1] has added a list of encoding test cases -- see section 10 of the RFC. It might be nice to add a test function that is a direct copy of these test cases. This will make conformance to this RFC clearer (actually right now we don't

[issue36700] base64 has old references that should be updated

2021-08-09 Thread Andrei Kulakov
Change by Andrei Kulakov : -- keywords: +patch nosy: +andrei.avk nosy_count: 4.0 -> 5.0 pull_requests: +26186 stage: -> patch review pull_request: https://github.com/python/cpython/pull/27700 ___ Python tracker <https://bugs.python.org/i

[issue32884] Adding the ability for getpass to print asterisks when password is typed

2021-08-09 Thread Andrei Kulakov
Andrei Kulakov added the comment: Unfortunately modern laptop keyboards have almost no key travel and barely any tactile feedback [*]. Users on such keyboards really do need feedback for each key pressed. Not providing an option for such feedback is in effect forcing users to choose

[issue24955] webbrowser broken on Mac OS X when using the BROWSER variable

2021-08-11 Thread Andrei Kulakov
Andrei Kulakov added the comment: Also see https://bugs.python.org/issue42255 Hugo: can you convert the patch to a PR? -- nosy: +andrei.avk ___ Python tracker <https://bugs.python.org/issue24

[issue44873] base64 RFC4648 test cases

2021-08-12 Thread Andrei Kulakov
Change by Andrei Kulakov : -- keywords: +patch pull_requests: +26225 stage: -> patch review pull_request: https://github.com/python/cpython/pull/27747 ___ Python tracker <https://bugs.python.org/issu

[issue41322] unittest: deprecate test methods returning non-None values

2021-08-12 Thread Andrei Kulakov
Change by Andrei Kulakov : -- keywords: +patch nosy: +andrei.avk nosy_count: 8.0 -> 9.0 pull_requests: +26226 stage: -> patch review pull_request: https://github.com/python/cpython/pull/27748 ___ Python tracker <https://bugs.python.org/i

[issue38656] mimetypes for python 3.7.5 fails to detect matroska video

2021-08-12 Thread Andrei Kulakov
Change by Andrei Kulakov : -- keywords: +patch nosy: +andrei.avk nosy_count: 8.0 -> 9.0 pull_requests: +26227 stage: -> patch review pull_request: https://github.com/python/cpython/pull/27750 ___ Python tracker <https://bugs.python.org/i

[issue41234] Remove symbol.sym_name

2021-08-12 Thread Andrei Kulakov
Andrei Kulakov added the comment: This can be closed; from the PR note: Resolved in PR #21624, can close. -- nosy: +andrei.avk ___ Python tracker <https://bugs.python.org/issue41

[issue34938] Fix mimetype.init() to account for from import

2021-08-12 Thread Andrei Kulakov
Andrei Kulakov added the comment: How about returning the updated dicts from init() and showing an example in the docs of such usage? -- nosy: +andrei.avk ___ Python tracker <https://bugs.python.org/issue34

[issue41234] Remove symbol.sym_name

2021-08-13 Thread Andrei Kulakov
Andrei Kulakov added the comment: Terry: thanks! - that's good to know. -- ___ Python tracker <https://bugs.python.org/issue41234> ___ ___ Python-bugs-l

[issue35105] Document that CPython accepts "invalid" identifiers

2021-08-13 Thread Andrei Kulakov
Andrei Kulakov added the comment: It seems like the documentation is lacking and perhaps misleading in regard to attributes. - anything hashable can be used as a key in an obj.__dict__: an int, a tuple, etc. According to __dict__ docs, all of those are attributes. There's no warning

[issue35105] Document that CPython accepts "invalid" identifiers

2021-08-13 Thread Andrei Kulakov
Andrei Kulakov added the comment: In the last message I've said that according to __dict__ docs, anything in __dict__ is an attribute of respective obj. That's a bit too-strongly worded, the docs can be understood in the sense that anything that ends up in __dict__ via other

[issue41102] ZipFile.namelist() does not match the actual files in .zip file

2021-08-14 Thread Andrei Kulakov
Andrei Kulakov added the comment: Xiaolong: The file no longer exists on the google drive. How big was the file? -- nosy: +andrei.avk ___ Python tracker <https://bugs.python.org/issue41

[issue41082] Error handling and documentation of Path.home()

2021-08-14 Thread Andrei Kulakov
Andrei Kulakov added the comment: In current dev version (3.11), _PosixFlavor doesn't have gethomedir(), and instead os.path.expanduser() is used via _NormalAccessor(). So at least for the current dev version, the docs are accurate. -- nosy: +andre

[issue41010] email.message.EmailMessage.get_body

2021-08-14 Thread Andrei Kulakov
Andrei Kulakov added the comment: This issue was fixed by https://github.com/python/cpython/pull/26903 (I confirmed that the error no longer happens with attached file). This can be closed as fixed. -- nosy: +andrei.avk ___ Python tracker <ht

[issue41322] unittest: deprecate test methods returning non-None values

2021-08-19 Thread Andrei Kulakov
Andrei Kulakov added the comment: I will add the test in the next 1-2 days, I should have asked if it's needed in this case.. -- ___ Python tracker <https://bugs.python.org/is

[issue41322] unittest: deprecate test methods returning non-None values

2021-08-19 Thread Andrei Kulakov
Change by Andrei Kulakov : -- pull_requests: +26308 stage: test needed -> patch review pull_request: https://github.com/python/cpython/pull/27846 ___ Python tracker <https://bugs.python.org/issu

[issue39827] setting a locale that uses comma as decimal separator breaks tkinter.DoubleVar

2021-08-20 Thread Andrei Kulakov
Andrei Kulakov added the comment: I wrote a longer explanation but BPO and Chrome ate it. The issue is that DoubleVar is not locale aware. I don't know what should be the actual fix but the following may be a useful workaround (It works on my system): import tkinter import locale i

[issue41322] unittest: deprecate test methods returning non-None values

2021-08-20 Thread Andrei Kulakov
Andrei Kulakov added the comment: That test does have a yield statement in it, and does cause the deprecation warning to fire off. I'm looking into it.. -- ___ Python tracker <https://bugs.python.org/is

[issue41322] unittest: deprecate test methods returning non-None values

2021-08-20 Thread Andrei Kulakov
Andrei Kulakov added the comment: Yes, it seems like this deprecation detected a broken test that wasn't running. If I add a `raise` statement to it and rerun the test, it still passes on my local system: ./python.exe -m unitte

[issue41322] unittest: deprecate test methods returning non-None values

2021-08-20 Thread Andrei Kulakov
Andrei Kulakov added the comment: The test was refactored in this commit: https://github.com/python/cpython/commit/658103f84ea860888f8dab9615281ea64fee31b9 the refactoring moved yield statement from inner func into the test. That was 8 years ago so it hasn't worked since then, and

[issue44968] Fix/remove test_subprocess_wait_no_same_group from test_asyncio tests

2021-08-20 Thread Andrei Kulakov
Change by Andrei Kulakov : -- nosy: +andrei.avk ___ Python tracker <https://bugs.python.org/issue44968> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue41322] unittest: deprecate test methods returning non-None values

2021-08-21 Thread Andrei Kulakov
Andrei Kulakov added the comment: Karthikeyan: I was looking into them yesterday, and: - distutils ones can probably be left as is because distutils are set for removal in 3.12 - test_constructor should be fixed, I can do that today. - test_null_strings in test_capi I'm not su

[issue41322] unittest: deprecate test methods returning non-None values

2021-08-21 Thread Andrei Kulakov
Andrei Kulakov added the comment: I should just add that none of the these tests are actually a problem, i.e. they all do run properly and not running duplicate times (except that I'm not sure about the 2 distutils tests, but that shouldn't matter much as distutils is deprecated

[issue44980] Clean up a few tests that return a value!=None

2021-08-22 Thread Andrei Kulakov
New submission from Andrei Kulakov : In #41322 the behavior of returning a value!=None from test methods was deprecated, there are currently a few tests in Python that do that; it would be good to fix them to be consistent with our deprecation requirement and to avoid deprecation warnings in

[issue44980] Clean up a few tests that return a value!=None

2021-08-22 Thread Andrei Kulakov
Change by Andrei Kulakov : -- keywords: +patch pull_requests: +26353 stage: -> patch review pull_request: https://github.com/python/cpython/pull/27898 ___ Python tracker <https://bugs.python.org/issu

[issue41102] ZipFile.namelist() does not match the actual files in .zip file

2021-08-22 Thread Andrei Kulakov
Andrei Kulakov added the comment: Liu: Thanks! Google zip also shows 674 files in this archive, so it appears that it's not a Python-only issue. Can you test it with a few zip programs, ideally on a 2 or more platforms, and check which of them report more than 674 files? (I simply o

[issue41102] ZipFile.namelist() does not match the actual files in .zip file

2021-08-22 Thread Andrei Kulakov
Andrei Kulakov added the comment: Liu: also please delete the quoted text when replying via email, otherwise it's hard to read on the issue page; much thanks! -- ___ Python tracker <https://bugs.python.org/is

[issue41102] ZipFile.namelist() does not match the actual files in .zip file

2021-08-22 Thread Andrei Kulakov
Andrei Kulakov added the comment: Liu: builtin MacOS archive tool also reports 674. since Google archiver, and built-in tools on all major platforms report 674 files; it looks like 7zip might be the outlier here [note also that 7zip have their own format]. Unless it can be shown that

[issue40951] csv skipinitialspace no longer working

2021-08-23 Thread Andrei Kulakov
Andrei Kulakov added the comment: I cannot reproduce with 3.7.7, when run with the linked example, the output looks fine: ['country_id', 'country_name', 'region_id'] ['AR', 'Argentina', '2'] ['AU', 'Australia',

[issue41102] ZipFile.namelist() does not match the actual files in .zip file

2021-08-23 Thread Andrei Kulakov
Andrei Kulakov added the comment: Liu: apologies for the confusion, I missed that when coming back to the thread for the 2nd time. I took a look at the code and one potential issue I see is that you are opening the file in 'w' mode if stat size is 0 (or if file isn't va

[issue41102] ZipFile.namelist() does not match the actual files in .zip file

2021-08-23 Thread Andrei Kulakov
Andrei Kulakov added the comment: Liu: Thanks for the report! By the way on re-reading my message, of course by opening and closing archive on each file using the `with` block, you take care of the first issue I mentioned (although it's not very efficient). And I assume there w

[issue40772] module 'resource' has no attribute 'RLIMIT_VMEM'

2021-08-25 Thread Andrei Kulakov
Andrei Kulakov added the comment: The docs for resource module state: This module does not attempt to mask platform differences — symbols not defined for a platform will not be available from this module on that platform. Therefore I think this can be closed. -- nosy: +andrei.avk

[issue40772] module 'resource' has no attribute 'RLIMIT_VMEM'

2021-08-25 Thread Andrei Kulakov
Andrei Kulakov added the comment: Also note that according to https://edwards.sdsu.edu/research/memory-and-core-usage-on-sge/, Linux systems use RLIMIT_AS instead of RLMIMIT_VMEM. My system (MacOS), also has RLIMIT_AS defined but not RLIMIT_VMEM

[issue40635] Documentation for socket.getfqdn incorrect?

2021-08-26 Thread Andrei Kulakov
Change by Andrei Kulakov : -- keywords: +patch nosy: +andrei.avk nosy_count: 3.0 -> 4.0 pull_requests: +26418 stage: -> patch review pull_request: https://github.com/python/cpython/pull/27971 ___ Python tracker <https://bugs.python.org/i

<    1   2   3   4   5   >