[issue45390] asyncio.Task doesn't propagate CancelledError() exception correctly.

2021-10-09 Thread Chris Jerdonek
Chris Jerdonek added the comment: > 2) Now: if I re-raise the asyncio.CancelledError as-is, I lose the message, if I call the `asyncio.Task.exception()` function. Re-raise asyncio.CancelledError where? (And what do you mean by "re-raise"?) Call asyncio.Task.exception() where? Th

[issue45390] asyncio.Task doesn't propagate CancelledError() exception correctly.

2021-10-09 Thread Chris Jerdonek
Chris Jerdonek added the comment: I still don't see you calling asyncio.Task.exception() in your new attachment... -- ___ Python tracker <https://bugs.python.org/is

[issue45390] asyncio.Task doesn't propagate CancelledError() exception correctly.

2021-10-09 Thread Chris Jerdonek
Chris Jerdonek added the comment: Here's a simplification of Marco's snippet to focus the discussion. import asyncio async def job(): # raise RuntimeError('error!') await asyncio.sleep(5) async def main(): task = asyncio.create_task(job()) a

[issue45454] Unable to explicitly subclass protocol when subclass has mixin requiring init

2021-10-12 Thread Chris Meyer
New submission from Chris Meyer : If I make a explicit subclass of a protocol that also inherits from a mixin and calls super() in order to initialize the mixin, I get the "Protocols cannot be instantiated" exception. This case arises when having a hierarchy of both protocols an

[issue45454] Unable to explicitly subclass protocol when subclass has mixin requiring init

2021-10-12 Thread Chris Meyer
Chris Meyer added the comment: This looks like it a regression specific to Python 3.9.7 and has been fixed. https://bugs.python.org/issue45081 https://github.com/python/cpython/pull/28132. -- resolution: -> duplicate stage: -> resolved status: open -&g

[issue44665] asyncio.create_task() documentation should mention user needs to keep reference to the task

2021-10-22 Thread Chris Meyer
Chris Meyer added the comment: Is there a way to reproduce this issue? I run the following code in Python 3.9 and it works as expected (prints "xyz" twice). import asyncio import gc async def xyz(): print("xyz") event_loop = asyncio.get_event_loop() event_loop.c

[issue45644] Make json.tool soak up input before opening output for writing

2021-10-28 Thread Chris Wesseling
New submission from Chris Wesseling : json.tool is very cute and handy for making json readable. But rewriting a file in place requires tools like sponge (on POSIX) or a tmpfile, because $ python -m json.tool foo.json foo.json results in an empty foo.json. I propose soaking up the infile

[issue45644] Make json.tool soak up input before opening output for writing

2021-10-28 Thread Chris Wesseling
Change by Chris Wesseling : -- keywords: +patch pull_requests: +27532 stage: -> patch review pull_request: https://github.com/python/cpython/pull/29269 ___ Python tracker <https://bugs.python.org/issu

[issue45644] Make json.tool soak up input before opening output for writing

2021-10-28 Thread Chris Wesseling
Change by Chris Wesseling : -- pull_requests: +27537 pull_request: https://github.com/python/cpython/pull/29273 ___ Python tracker <https://bugs.python.org/issue45

[issue45664] resolve_bases() and new_class() do not work with type alias of a built-in type

2021-10-28 Thread Chris Wesseling
Change by Chris Wesseling : -- nosy: +CharString nosy_count: 4.0 -> 5.0 pull_requests: +27569 pull_request: https://github.com/python/cpython/pull/29273 ___ Python tracker <https://bugs.python.org/issu

[issue45664] resolve_bases() and new_class() do not work with type alias of a built-in type

2021-10-28 Thread Chris Wesseling
Change by Chris Wesseling : -- nosy: +CharString, CharString nosy_count: 4.0 -> 5.0 pull_requests: +27569, 27570 pull_request: https://github.com/python/cpython/pull/29273 ___ Python tracker <https://bugs.python.org/issu

[issue45664] resolve_bases() and new_class() do not work with type alias of a built-in type

2021-10-29 Thread Chris Wesseling
Change by Chris Wesseling : -- pull_requests: +27577 pull_request: https://github.com/python/cpython/pull/29273 ___ Python tracker <https://bugs.python.org/issue45

[issue45718] asyncio: MultiLoopWatcher has a race condition (Proposed work-around)

2021-11-05 Thread Chris Jerdonek
Chris Jerdonek added the comment: Since issue 38323 is still open, I think you should just comment on that instead of creating a new issue. -- nosy: +chris.jerdonek ___ Python tracker <https://bugs.python.org/issue45

[issue45644] Make json.tool soak up input before opening output for writing

2021-11-08 Thread Chris Wesseling
Chris Wesseling added the comment: @Remi I left the current behaviour for --json-lines untouched, on purpose. My reasoning was that the json-lines format is often seen in JSON streaming, and I didn't want to break the case where the input is an endless stream from stdin or a named pipe

[issue45644] Make json.tool soak up input before opening output for writing

2021-11-08 Thread Chris Wesseling
Change by Chris Wesseling : -- pull_requests: +27729 pull_request: https://github.com/python/cpython/pull/29478 ___ Python tracker <https://bugs.python.org/issue45

[issue33927] Allow json.tool to have identical infile and outfile

2021-11-08 Thread Chris Wesseling
Change by Chris Wesseling : -- nosy: +CharString nosy_count: 6.0 -> 7.0 pull_requests: +27728 pull_request: https://github.com/python/cpython/pull/29478 ___ Python tracker <https://bugs.python.org/issu

[issue45796] Using tab to cycle through tkinter widgets breaks foreground styling

2021-11-12 Thread Chris Eykamp
Chris Eykamp added the comment: I'll add that when the red text incorrectly turns black, on my display, I can see a very subtle red halo, as if the text is being printed first as red, then as black in a second pass. -- ___ Python tracker &

[issue45796] Using tab to cycle through tkinter widgets breaks foreground styling

2021-11-12 Thread Chris Eykamp
New submission from Chris Eykamp : Attached is a slightly modifed example of the code sample in Bryan Oakley's response to: https://stackoverflow.com/questions/30337351/how-can-i-ensure-my-ttk-entrys-invalid-state-isnt-cleared-when-it-loses-focus I have modified it by changing the styl

[issue45796] Using tab to cycle through tkinter widgets breaks foreground styling

2021-11-16 Thread Chris Eykamp
Chris Eykamp added the comment: The behavior I described is definitely a bug, though it may be (and I suspect is) Windows specific. You may also be right that the problem is upstream, but please don't declare this "not a bug" until you've tested it on Windows. -

[issue45796] Using tab to cycle through tkinter widgets breaks foreground styling

2021-11-16 Thread Chris Eykamp
Chris Eykamp added the comment: Thanks for the clarification. I don't want to belabor the point, but if you observe what happens as you hit tab and cycle through the widgets, the way the color changes cannot be intended behavior, and makes no sense from any rational UI perspective.

[issue45796] Using tab to cycle through tkinter widgets breaks foreground styling

2021-11-26 Thread Chris Eykamp
Chris Eykamp added the comment: If we decide that this is a tkinter bug (and that the Python part is working properly), does that mean that we close this ticket and rely on the upstream provider to fix the problem? I don't know how jurisdiction works with core libraries shipped with P

[issue45664] resolve_bases() and new_class() do not work with type alias of a built-in type

2021-12-06 Thread Chris Wesseling
Change by Chris Wesseling : -- nosy: -CharString, CharString ___ Python tracker <https://bugs.python.org/issue45664> ___ ___ Python-bugs-list mailing list Unsub

[issue1653457] Python misbehaves when installed in / (patch attached)

2021-12-07 Thread Chris Webb
Chris Webb added the comment: Irit Katriel added the comment: > getpath.c has been rewritten (see Issue45582). reduce is no longer there. Gosh, this is one I originally reported back in the late 1990s and then again mid-2000s! I've carried a patch in my distribution to make pytho

[issue1653457] Python misbehaves when installed in / (patch attached)

2021-12-08 Thread Chris Webb
Change by Chris Webb : Removed file: https://bugs.python.org/file17945/paths.patch ___ Python tracker <https://bugs.python.org/issue1653457> ___ ___ Python-bugs-list m

[issue38757] mocking an exception, arguments do not seem to be passed to the mock

2019-11-09 Thread Chris Withers
Chris Withers added the comment: Not sure this is correct, if an effect is an exception and requires args, then it should be passed as an instance, not a class: Mock(side_effect=MyException(‘foo’)) > On 10 Nov 2019, at 04:49, Karthikeyan Singaravelan > wrote: > > &

[issue38757] mocking an exception, arguments do not seem to be passed to the mock

2019-11-11 Thread Chris Withers
Chris Withers added the comment: Agreed. -- resolution: -> not a bug stage: -> resolved status: open -> closed ___ Python tracker <https://bugs.python.or

[issue38763] mock with side effect : assert_called_once returns None while call_count returns 1

2019-11-12 Thread Chris Withers
Change by Chris Withers : -- resolution: -> not a bug stage: -> resolved status: open -> closed ___ Python tracker <https://bugs.python.org/issue38763> ___ ___

[issue30463] Add __slots__ to ABC convenience class

2019-11-15 Thread Chris Withers
Chris Withers added the comment: I will note that this means with: class BaseClass(ABC): pass class MyDerivedClass(BaseClass): def __init__(self, thing): self.thing = thing thing = MyDerivedClass() thing now has both __slots__ and, evidently, a dict. That's a bit

[issue38937] NameError in list comprehension within .pth file

2019-11-28 Thread Chris Billington
New submission from Chris Billington : The following one-liner works fine in a regular Python interpreter: $ python -c 'import sys; x = 5; [print(x + i) for i in range(5)]' 5 6 7 8 9 But in a .pth file, it raises a NameError: $ echo 'import sys; x = 5; [print(x + i) f

[issue38937] NameError in list comprehension within .pth file

2019-11-28 Thread Chris Billington
Chris Billington added the comment: I see. site.py calls exec() from within a function, and therefore the code is executed in the context of that function's locals and the site module globals. This means the code in .pth files can access (but not add new) local names from

[issue38937] NameError in list comprehension within .pth file

2019-11-29 Thread Chris Billington
Chris Billington added the comment: Sorry for the spamming, realised I misunderstood further. The original behaviour isn't because the exec'd code can't create new local variables - it can - it's because of the documented behaviour of exec when it gets different dicts fo

[issue38669] patch.object should raise another error when first argument is a str

2019-12-08 Thread Chris Withers
Chris Withers added the comment: New changeset cd90a52983db34896a6335a572d55bdda274778f by Chris Withers (Elena Oat) in branch 'master': bpo-38669: patch.object now raises a helpful error (GH17034) https://github.com/python/cpython/commit/cd90a52983db34896a6335a572d55b

[issue38669] patch.object should raise another error when first argument is a str

2019-12-08 Thread Chris Withers
Chris Withers added the comment: New changeset 4594565b56e9c99d2d3fb7549041bbca5ecba8e2 by Chris Withers (Miss Islington (bot)) in branch '3.8': bpo-38669: patch.object now raises a helpful error (GH17510) https://github.com/python/cpython/commit/4594565b56e9c99d2d3fb7549041bb

[issue38669] patch.object should raise another error when first argument is a str

2019-12-08 Thread Chris Withers
Chris Withers added the comment: New changeset 41973c99fdfdc78315e819661e279bdcc2f058b1 by Chris Withers (Miss Islington (bot)) in branch '3.7': bpo-38669: patch.object now raises a helpful error (GH17511) https://github.com/python/cpython/commit/41973c99fdfdc78315e819661e279b

[issue38669] patch.object should raise another error when first argument is a str

2019-12-08 Thread Chris Withers
Change by Chris Withers : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.or

[issue39090] Document various options for getting the absolute path from pathlib.Path objects

2019-12-24 Thread Chris Barker
Chris Barker added the comment: Yes Please! I'd offer to help, but I really don't get the intricacies involved. I will offer to proofread and copy-edit though, if that's helpful. And I note that coincidentally, just in the last week, I needed to make an absolute path from

[issue39222] unittest.mock.Mock.parent is broken or undocumented

2020-01-10 Thread Chris Withers
Chris Withers added the comment: I thought we'd already changed this to _mock_parent in the last year or so? -- ___ Python tracker <https://bugs.python.org/is

[issue18233] SSLSocket.getpeercertchain()

2020-01-10 Thread Chris Burr
Change by Chris Burr : -- pull_requests: +17346 pull_request: https://github.com/python/cpython/pull/17938 ___ Python tracker <https://bugs.python.org/issue18

[issue39222] unittest.mock.Mock.parent is broken or undocumented

2020-01-12 Thread Chris Withers
Chris Withers added the comment: Ah right. Well, it's called `parent` in the __init__ as that's what the attribute used to be called. My suggestion would be to add `parent` to the docs @xtreak links to as a way to resolve

[issue18233] SSLSocket.getpeercertchain()

2020-01-13 Thread Chris Burr
Change by Chris Burr : -- nosy: +chrisburr ___ Python tracker <https://bugs.python.org/issue18233> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue39342] Expose X509_V_FLAG_ALLOW_PROXY_CERTS in ssl

2020-01-15 Thread Chris Burr
Change by Chris Burr : -- assignee: -> christian.heimes components: +SSL -Library (Lib) nosy: +christian.heimes ___ Python tracker <https://bugs.python.org/issu

[issue39342] Expose X509_V_FLAG_ALLOW_PROXY_CERTS in ssl

2020-01-15 Thread Chris Burr
New submission from Chris Burr : Enabling proxy certificate validation requires X509_V_FLAG_ALLOW_PROXY_CERTS to be included in the verify flags.[1] This should be exposed as ssl.VERIFY_ALLOW_PROXY_CERTS to match with the other X509_V_FLAG_* variables. https://www.openssl.org/docs/man1.1.1

[issue39342] Expose X509_V_FLAG_ALLOW_PROXY_CERTS in ssl

2020-01-15 Thread Chris Burr
Change by Chris Burr : -- keywords: +patch pull_requests: +17410 stage: -> patch review pull_request: https://github.com/python/cpython/pull/18011 ___ Python tracker <https://bugs.python.org/issu

[issue27657] urlparse fails if the path is numeric

2020-01-17 Thread Chris Dent
Chris Dent added the comment: Just to add to the list of places this is causing a regression. This has broken the target host determination routines in gabbi: https://github.com/cdent/gabbi/issues/277 While the original fix may have been strictly correct in some ways, it results in a

[issue24928] mock.patch.dict spoils order of items in collections.OrderedDict

2020-01-24 Thread Chris Withers
Chris Withers added the comment: As I said before, I can't see an additional test like this hurting, especially if it highlights problems with earlier python versions when it's backported. -- ___ Python tracker <https://bugs.python.o

[issue24928] mock.patch.dict spoils order of items in collections.OrderedDict

2020-01-24 Thread Chris Withers
Chris Withers added the comment: New changeset 1d0c5e16eab29d55773cc4196bb90d2bf12e09dd by Chris Withers (Emmanuel Arias) in branch 'master': bpo-24928: Add test case for patch.dict using OrderedDict (GH -11437) https://github.com/python/cpyt

[issue37669] Make mock_open return per-file content

2020-01-24 Thread Chris Withers
Chris Withers added the comment: I'm not sure I like the API feel after this change: two parameters that can't be used at the same time. As Karthikeyan points out, this can be achieved using side_effect. Personally, I'd prefer a PR that adds a unit test showing that this appr

[issue37669] Make mock_open return per-file content

2020-01-24 Thread Chris Withers
Chris Withers added the comment: Closing in favour of issue38157. -- resolution: -> duplicate stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.or

[issue21600] mock.patch.stopall doesn't work with patch.dict

2020-01-24 Thread Chris Withers
Change by Chris Withers : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.or

[issue38473] AttributeError on asserting autospecced mock object added using attach_mock

2020-01-24 Thread Chris Withers
Chris Withers added the comment: New changeset 66b00a9d3aacf6ed49412f48743e4913104a2bb3 by Chris Withers (Karthikeyan Singaravelan) in branch 'master': bpo-38473: Handle autospecced functions and methods used with attach_mock (GH-16784) https://github.com/python/cpyt

[issue39082] AsyncMock is unable to correctly patch static or class methods

2020-01-25 Thread Chris Withers
Chris Withers added the comment: New changeset 62865f4532094017a9b780b704686ca9734bc329 by Chris Withers (Matthew Kokotovich) in branch 'master': bpo-39082: Allow AsyncMock to correctly patch static/class methods (GH-18116) https://github.com/python/cpyt

[issue39082] AsyncMock is unable to correctly patch static or class methods

2020-01-25 Thread Chris Withers
Change by Chris Withers : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.or

[issue37955] mock.patch incorrect reference to Mock

2020-01-25 Thread Chris Withers
Chris Withers added the comment: New changeset 40c080934b3d49311209b1cb690c2ea1e04df7e7 by Chris Withers (Paulo Henrique Silva) in branch 'master': bpo-37955: correct mock.patch docs with respect to the returned type (GH-15521) https://github.com/python/cpyt

[issue37955] mock.patch incorrect reference to Mock

2020-01-25 Thread Chris Withers
Change by Chris Withers : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.or

[issue38932] unittest.mock.Mock.reset_mocks does not pass all arguments to its children

2020-01-25 Thread Chris Withers
Chris Withers added the comment: New changeset aef7dc89879d099dc704bd8037b8a7686fb72838 by Chris Withers (Vegard Stikbakke) in branch 'master': bpo-38932: Mock fully resets child objects on reset_mock(). (GH-17409) https://github.com/python/cpyt

[issue38932] unittest.mock.Mock.reset_mocks does not pass all arguments to its children

2020-01-25 Thread Chris Withers
Change by Chris Withers : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.or

[issue39082] AsyncMock is unable to correctly patch static or class methods

2020-01-26 Thread Chris Withers
Chris Withers added the comment: New changeset 19be85c76503535c101b38194d282187de0ff631 by Chris Withers (Matthew Kokotovich) in branch '3.8': [3.8] bpo-39082: Allow AsyncMock to correctly patch static/class methods (GH-18190) https://github.com/python/cpyt

[issue38971] codecs.open leaks file descriptor when invalid encoding is passed

2020-01-26 Thread Chris Aporta
Chris Aporta added the comment: Just quickly pinging the thread as a friendly reminder that PR 17666 is open and potentially close to mergeable, as it's been through two review cycles already (thanks Serhiy). If someone has the bandwidth to take another look, it would be greatly apprec

[issue25597] unittest.mock does not wrap dunder methods (__getitem__ etc)

2020-01-26 Thread Chris Withers
Chris Withers added the comment: New changeset 72b1004657e60c900e4cd031b2635b587f4b280e by Chris Withers (Karthikeyan Singaravelan) in branch 'master': bpo-25597: Ensure wraps' return value is used for magic methods in MagicMock (#16029) https://github.com/python

[issue39485] Bug in mock running on PyPy3

2020-01-29 Thread Chris Withers
Change by Chris Withers : -- assignee: -> cjw296 ___ Python tracker <https://bugs.python.org/issue39485> ___ ___ Python-bugs-list mailing list Unsubscrib

[issue39485] Bug in mock running on PyPy3

2020-01-29 Thread Chris Withers
Chris Withers added the comment: New changeset a327677905956ae0b239ff430a1346dfe265709e by Carl Friedrich Bolz-Tereick in branch 'master': bpo-39485: fix corner-case in method-detection of mock (GH-18252) https://github.com/python/cpython/commit/a327677905956ae0b239ff430a1346

[issue39485] Bug in mock running on PyPy3

2020-01-29 Thread Chris Withers
Chris Withers added the comment: New changeset cf0645a17acbc0c4dbbf82434e37637965748bbb by Miss Islington (bot) in branch '3.7': bpo-39485: fix corner-case in method-detection of mock (GH-18256) https://github.com/python/cpython/commit/cf0645a17acbc0c4dbbf82434e3763

[issue39485] Bug in mock running on PyPy3

2020-01-29 Thread Chris Withers
Chris Withers added the comment: New changeset 696d2324cf2a54e20e8d6a6739fa97ba815a8be9 by Miss Islington (bot) in branch '3.8': bpo-39485: fix corner-case in method-detection of mock (GH-18255) https://github.com/python/cpython/commit/696d2324cf2a54e20e8d6a6739fa97

[issue39485] Bug in mock running on PyPy3

2020-01-29 Thread Chris Withers
Chris Withers added the comment: Thank you very much for this, that was a really good catch! -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.or

[issue37972] unittest.mock.call does not chain __getitem__ to another _Call object

2020-01-29 Thread Chris Withers
Chris Withers added the comment: New changeset db5e86adbce12350c26e7ffc2c6673369971a2dc by Chris Withers in branch 'master': Get mock coverage back to 100% (GH-18228) https://github.com/python/cpython/commit/db5e86adbce12350c26e7ffc2c6673

[issue39450] unittest TestCase shortDescription does not strip whitespace

2020-02-02 Thread Chris Withers
Chris Withers added the comment: New changeset 032de7324e30c6b44ef272cea3be205a3d768759 by Steve Cirelli in branch 'master': bpo-39450 Stripped whitespace before parsing the docstring in TestCase.shortDescription (GH-18175) https://github.com/python/cpyt

[issue39450] unittest TestCase shortDescription does not strip whitespace

2020-02-02 Thread Chris Withers
Chris Withers added the comment: New changeset 7561e7a83f5118fda6c62fe9c8c3458f8cfd by Miss Islington (bot) in branch '3.7': bpo-39450 Stripped whitespace before parsing the docstring in TestCase.shortDescription (GH-18321) https://github.com/python/cpyt

[issue39450] unittest TestCase shortDescription does not strip whitespace

2020-02-03 Thread Chris Withers
Chris Withers added the comment: New changeset 02395fad8e3a35ef00fa31c308693844013a1dd4 by Miss Islington (bot) in branch '3.8': bpo-39450 Stripped whitespace before parsing the docstring in TestCase.shortDescription (GH-18175) (#18323) https://github.com/python/cpyt

[issue31826] Misleading __version__ attribute of modules in standard library

2020-02-04 Thread Chris Withers
Change by Chris Withers : -- keywords: +patch pull_requests: +17717 stage: -> patch review pull_request: https://github.com/python/cpython/pull/17977 ___ Python tracker <https://bugs.python.org/issu

[issue39551] mock patch should match behavior of import from when module isn't present in sys.modules

2020-02-04 Thread Chris Withers
Chris Withers added the comment: What's the real world use case for this? -- nosy: +cjw296 ___ Python tracker <https://bugs.python.org/issue39551> ___ ___

[issue39551] mock patch should match behavior of import from when module isn't present in sys.modules

2020-02-04 Thread Chris Withers
Chris Withers added the comment: I'm afraid I don't understand "immutable package which doesn't allow it's children to be published on it", can you give an example? -- ___ Python tracker <h

[issue39551] mock patch should match behavior of import from when module isn't present in sys.modules

2020-02-06 Thread Chris Withers
Chris Withers added the comment: Apologies, but I'm still not sure what "the modules are published" means? "publish "x" as a child onto the package" also doesn't mean much to me, I'm afraid. Are you aware of any importlib docs or some such which mi

[issue39551] mock patch should match behavior of import from when module isn't present in sys.modules

2020-02-09 Thread Chris Withers
Chris Withers added the comment: Hmm, the more we get into this, the less comfortable I am of the patch in the PR. Instead of copying and pasting more code that's likely to get out of sync, could you change the PR to just replace _importer with the correct parts of importlib to su

[issue39601] brace escapes are not working in formatted string literal format specifications

2020-02-10 Thread Chris Wilcox
Chris Wilcox added the comment: The attached code implements `__format__` on the `Collections` class. In case 1, the template passed to `__format__` is "{v.name}: {v.email}|". In case 2, a name error will occur while processing the f string and v will not be found as no object &#x

[issue14678] Update zipimport to support importlib.invalidate_caches()

2020-02-10 Thread Chris Wilcox
Chris Wilcox added the comment: What work remains to be done for this issue? -- nosy: +crwilcox ___ Python tracker <https://bugs.python.org/issue14678> ___ ___

[issue9305] Don't use east/west of UTC in date/time documentation

2020-02-10 Thread Chris Wilcox
Chris Wilcox added the comment: Are you still working on this Ajay Mahato? -- nosy: +crwilcox ___ Python tracker <https://bugs.python.org/issue9305> ___ ___

[issue39601] brace escapes are not working in formatted string literal format specifications

2020-02-10 Thread Chris Wilcox
Chris Wilcox added the comment: Double curly braces do not indicate to not process the inner content. They indicate to include a literal curly brace. That said, I think there may be something not quite correct. I came up with an example based on the example in the format specifiers section

[issue39607] Add a parameter to strip, lstrip, and rstrip that treats the first parameter as a full string

2020-02-11 Thread Chris Rogers
New submission from Chris Rogers : Consider this string: 'mailto:mailto:mailto:m...@example.com' If you try to remove the mailtos with lstrip('mailto:'), you'll be left with this: 'n...@example.com' That's because the three strip functions look at e

[issue39601] brace escapes are not working in formatted string literal format specifications

2020-02-11 Thread Chris Wilcox
Chris Wilcox added the comment: Thanks Eric. That is very handy. I had made a test case earlier on a branch. Attached as a patch here if helpful. I haven't tried to fix this yet, but would be interested if it is something that makes sense to address. -- keywords: +patch Added

[issue39753] inspecting a partial with bound keywods gives incorrect signature

2020-02-25 Thread Chris Withers
Change by Chris Withers : -- components: +Library (Lib) versions: +Python 3.8 ___ Python tracker <https://bugs.python.org/issue39753> ___ ___ Python-bugs-list m

[issue39753] inspecting a partial with bound keywods gives incorrect signature

2020-02-25 Thread Chris Withers
New submission from Chris Withers : $ python Python 3.8.1 (v3.8.1:1b293b6006, Dec 18 2019, 14:08:53) [Clang 6.0 (clang-600.0.57)] on darwin Type "help", "copyright", "credits" or "license" for more information. >>> from functools import part

[issue39753] inspecting a partial with bound keywods gives incorrect signature

2020-02-25 Thread Chris Withers
Chris Withers added the comment: Surprised partials have no explicit signature: >>> p.__signature__ Traceback (most recent call last): File "", line 1, in AttributeError: 'functools.partial' object has no attribute '__signature__' -- ___

[issue14678] Update zipimport to support importlib.invalidate_caches()

2020-02-28 Thread Chris Wilcox
Chris Wilcox added the comment: That is my thinking as well after rooting around a bit. I unfortunately am not knowledgable enough here to be 100% sure it is complete. -- ___ Python tracker <https://bugs.python.org/issue14

[issue39753] inspecting a partial with bound keywords gives incorrect signature

2020-03-01 Thread Chris Withers
Chris Withers added the comment: Not sure I understand your comment. The results of calling inpsect on a partial with bound keyword parameters are incorrect. Furthermore, it is surprisingly that partial objects don't maintain their own __signature__. What is it you're

[issue39915] await_args_list in AsyncMock always refers to the last awaited call object

2020-03-11 Thread Chris Withers
Chris Withers added the comment: New changeset e553f204bf0e39b1d701a364bc71b286acb9433f by Karthikeyan Singaravelan in branch 'master': bpo-39915: Ensure await_args_list is updated according to the order in which coroutines were awaited (GH-18924) https://github.com/python/cpyt

[issue39915] await_args_list in AsyncMock always refers to the last awaited call object

2020-03-14 Thread Chris Withers
Chris Withers added the comment: New changeset f6bdac1bf718eab0cc5b6554f363f21252d245ce by Miss Islington (bot) in branch '3.8': bpo-39915: Ensure await_args_list is updated according to the order in which coroutines were awaited (GH-18927) https://github.com/python/cpyt

[issue33493] dataclasses: allow keyword-only arguments

2020-04-01 Thread Chris Barker
Chris Barker added the comment: This does not actually appear to be a Duplicate of #33129. That one was asking to add **kwargs (I think) to the __init__. And was discussed and I think rejected on gitHub: https://github.com/python/cpython/pull/19206 But this calls for having keyword-only

[issue40158] MSBuild Extensions in CPython NuGet Package has Bad Expression

2020-04-02 Thread Chris Martinez
New submission from Chris Martinez : CPython provides a NuGet package as a mechanism to support non-installed Python distributions. The package includes MSBuild support to integrate with its build process. The expressions on lines 32 and 33 in the file: https://github.com/python/cpython

[issue40158] MSBuild Extensions in CPython NuGet Package has Bad Expression

2020-04-02 Thread Chris Martinez
Chris Martinez added the comment: In testing the fix, another issue has arisen. It appears the specified expression will never yield a usable path. Expression 1: $([msbuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory), "python_d.exe")) Expression 2:

[issue40158] MSBuild Extensions in CPython NuGet Package has Bad Expression

2020-04-03 Thread Chris Martinez
Change by Chris Martinez : -- keywords: +patch pull_requests: +18707 stage: -> patch review pull_request: https://github.com/python/cpython/pull/19343 ___ Python tracker <https://bugs.python.org/issu

[issue40133] Provide additional matchers for unittest.mock

2020-04-16 Thread Chris Withers
Chris Withers added the comment: Agreed, this would be better placed in a third party library. There's examples out there already, for example, I maintain a library [0] that has tools for asserting about complex data structures, including flexible type matching [1] and regex string mat

[issue39651] Exceptions raised by EventLoop.call_soon_threadsafe

2020-04-20 Thread Chris Meyer
Chris Meyer added the comment: Is this related to bpo-39010 too? -- nosy: +cmeyer ___ Python tracker <https://bugs.python.org/issue39651> ___ ___ Python-bug

[issue39010] ProactorEventLoop raises unhandled ConnectionResetError

2020-04-20 Thread Chris Meyer
Change by Chris Meyer : -- nosy: +cmeyer ___ Python tracker <https://bugs.python.org/issue39010> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue37373] Configuration of windows event loop for libraries

2020-04-20 Thread Chris Meyer
Change by Chris Meyer : -- nosy: +cmeyer ___ Python tracker <https://bugs.python.org/issue37373> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue34037] asyncio: BaseEventLoop.close() shutdowns the executor without waiting causing leak of dangling threads

2020-04-20 Thread Chris Meyer
Change by Chris Meyer : -- nosy: +cmeyer ___ Python tracker <https://bugs.python.org/issue34037> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue40357] asyncio: will shutdown_default_executor work in single step (stop, run_forever) mode?

2020-04-21 Thread Chris Meyer
New submission from Chris Meyer : Is the new asyncio.loop.shutdown_default_executor() suitable for event loops that are run in single-step mode? event_loop.create_task(event_loop.shutdown_default_executor()) event_loop.stop() event_loop.run_forever() I don't see how it will work

[issue39966] mock 3.9 bug: Wrapped objects without __bool__ raise exception

2020-04-26 Thread Chris Withers
Chris Withers added the comment: I'd go with your instincts on what to do next, I'd have a slight preference to keeping behaviour the same as it was in 3.8 if the changes for 3.9 cause more problems. That leaves us no worse off than we were before, and with the opportunity to im

[issue25597] unittest.mock does not wrap dunder methods (__getitem__ etc)

2020-04-28 Thread Chris Withers
Chris Withers added the comment: New changeset 521c8d6806adf0305c158d280ec00cca48e8ab22 by Karthikeyan Singaravelan in branch 'master': bpo-39966: Revert "bpo-25597: Ensure wraps' return value is used for magic methods in MagicMock" (GH-19734) https://github.

[issue39966] mock 3.9 bug: Wrapped objects without __bool__ raise exception

2020-04-28 Thread Chris Withers
Chris Withers added the comment: New changeset 521c8d6806adf0305c158d280ec00cca48e8ab22 by Karthikeyan Singaravelan in branch 'master': bpo-39966: Revert "bpo-25597: Ensure wraps' return value is used for magic methods in MagicMock" (GH-19734) https://github.

[issue29587] Generator/coroutine 'throw' discards exc_info state, which is bad

2020-04-30 Thread Chris Jerdonek
Change by Chris Jerdonek : -- keywords: +patch pull_requests: +19131 stage: -> patch review pull_request: https://github.com/python/cpython/pull/19811 ___ Python tracker <https://bugs.python.org/issu

<    1   2   3   4   5   6   7   8   9   10   >