GeezerVison is showing github.com — GH-120097: Make FrameLocalsProxy a mapping by markshannon · Pull Request #120101 · python/cpython
Conversation
markshannon
commented
Jun 5, 2024
•
edited by bedevere-app
Bot
Loading
Uh oh!
There was an error while loading. Please reload this page.
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
markshannon
changed the title
GH-120097: Make locals proxy mapping
GH-120097: Make FrameLocalsProxy a mapping
Jun 5, 2024
Uh oh!
There was an error while loading. Please reload this page.
|
|
copy.deepcopy(d)
|
|
|
|
|
|
def test_is_mapping(self):
|
|
|
x = 1
|
sobolevn
Jun 5, 2024
•
edited
Loading
Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why do you need x? To fill f_locals? In this case I propose to use a inner function. Or maybe two: with and without locals.
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The contents are irrelevant, but we want something just to make sure we are testing the right thing.
Without x = 1, the locals would just be {} and it would be too easy to mistakenly test the wrong mapping.
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
|
Is the test failure related?
|
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
|
Thanks @markshannon for the PR 🌮🎉.. I'm working now to backport this PR to: 3.13.
🐍🍒⛏🤖
|
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
miss-islington
pushed a commit
to miss-islington/cpython
that referenced
this pull request
Jun 19, 2024
* Register FrameLocalsProxy as a subclass of collections.abc.Mapping
* Allow FrameLocalsProxy to matching mapping patterns
(cherry picked from commit d1c673b)
Co-authored-by: Mark Shannon <[email protected]>
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
mrahtz
pushed a commit
to mrahtz/cpython
that referenced
this pull request
Jun 30, 2024
* Register FrameLocalsProxy as a subclass of collections.abc.Mapping
* Allow FrameLocalsProxy to matching mapping patterns
estyxx
pushed a commit
to estyxx/cpython
that referenced
this pull request
Jul 17, 2024
* Register FrameLocalsProxy as a subclass of collections.abc.Mapping
* Allow FrameLocalsProxy to matching mapping patterns
⚠️⚠️⚠️ Buildbot failure ⚠️⚠️⚠️
Hi! The buildbot iOS ARM64 Simulator 3.13 has failed when building commit 95b4f9c.
What do you need to do:
- Don't panic.
- Check the buildbot page in the devguide if you don't know what the buildbots are or how they work.
- Go to the page of the buildbot that failed (https://buildbot.python.org/#/builders/1386/builds/503) and take a look at the build logs.
- Check if the failure is related to this commit (95b4f9c) or if it is a false positive.
- If the failure is related to this commit, please, reflect that on the issue and make a new Pull Request with a fix.
You can take a look at the buildbot page here:
https://buildbot.python.org/#/builders/1386/builds/503
Failed tests:
Failed subtests:
- test_UnixDatagramServer - test.test_socketserver.SocketServerTest.test_UnixDatagramServer
- test_ThreadingUnixDatagramServer - test.test_socketserver.SocketServerTest.test_ThreadingUnixDatagramServer
Summary of the results of the build (if available):
==
Click to see traceback logs
Traceback (most recent call last):
File "/Users/buildbot/Library/Developer/XCTestDevices/F4BBB41D-5207-4016-951B-2DC02AC8DD0F/data/Containers/Bundle/Application/150C37C0-A406-4BC6-B95F-53E7B448E825/iOSTestbed.app/python/lib/python3.13/threading.py", line 1041, in _bootstrap_inner
self.run()
~~~~~~~~^^
File "/Users/buildbot/Library/Developer/XCTestDevices/F4BBB41D-5207-4016-951B-2DC02AC8DD0F/data/Containers/Bundle/Application/150C37C0-A406-4BC6-B95F-53E7B448E825/iOSTestbed.app/python/lib/python3.13/threading.py", line 992, in run
self._target(*self._args, **self._kwargs)
~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/buildbot/Library/Developer/XCTestDevices/F4BBB41D-5207-4016-951B-2DC02AC8DD0F/data/Containers/Bundle/Application/150C37C0-A406-4BC6-B95F-53E7B448E825/iOSTestbed.app/python/lib/python3.13/socketserver.py", line 694, in process_request_thread
self.handle_error(request, client_address)
~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/buildbot/Library/Developer/XCTestDevices/F4BBB41D-5207-4016-951B-2DC02AC8DD0F/data/Containers/Bundle/Application/150C37C0-A406-4BC6-B95F-53E7B448E825/iOSTestbed.app/python/lib/python3.13/socketserver.py", line 692, in process_request_thread
self.finish_request(request, client_address)
~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/buildbot/Library/Developer/XCTestDevices/F4BBB41D-5207-4016-951B-2DC02AC8DD0F/data/Containers/Bundle/Application/150C37C0-A406-4BC6-B95F-53E7B448E825/iOSTestbed.app/python/lib/python3.13/socketserver.py", line 362, in finish_request
self.RequestHandlerClass(request, client_address, self)
~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/buildbot/Library/Developer/XCTestDevices/F4BBB41D-5207-4016-951B-2DC02AC8DD0F/data/Containers/Bundle/Application/150C37C0-A406-4BC6-B95F-53E7B448E825/iOSTestbed.app/python/lib/python3.13/socketserver.py", line 763, in __init__
self.finish()
~~~~~~~~~~~^^
File "/Users/buildbot/Library/Developer/XCTestDevices/F4BBB41D-5207-4016-951B-2DC02AC8DD0F/data/Containers/Bundle/Application/150C37C0-A406-4BC6-B95F-53E7B448E825/iOSTestbed.app/python/lib/python3.13/socketserver.py", line 858, in finish
self.socket.sendto(self.wfile.getvalue(), self.client_address)
~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
ConnectionResetError: [Errno 54] Connection reset by peer
Warning -- threading_cleanup() failed to clean up threads in 1.0 seconds
Warning -- before: thread count=0, dangling=1
Warning -- after: thread count=1, dangling=4
Warning -- Dangling thread: <_MainThread(MainThread, started 4366598720)>
Warning -- Dangling thread: <Thread(Thread-2873 (process_request_thread), stopped 6137769984)>
Warning -- Dangling thread: <Thread(<class 'socketserver.ThreadingUnixDatagramServer'> serving, started daemon 6120943616)>
Warning -- Dangling thread: <Thread(Thread-2874 (process_request_thread), stopped 6154596352)>
ERROR
Traceback (most recent call last):
File "/Users/buildbot/Library/Developer/XCTestDevices/F4BBB41D-5207-4016-951B-2DC02AC8DD0F/data/Containers/Bundle/Application/150C37C0-A406-4BC6-B95F-53E7B448E825/iOSTestbed.app/python/lib/python3.13/test/test_socketserver.py", line 228, in test_ThreadingUnixDatagramServer
self.run_server(socketserver.ThreadingUnixDatagramServer,
~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
socketserver.DatagramRequestHandler,
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
self.dgram_examine)
^^^^^^^^^^^^^^^^^^^
File "/Users/buildbot/Library/Developer/XCTestDevices/F4BBB41D-5207-4016-951B-2DC02AC8DD0F/data/Containers/Bundle/Application/150C37C0-A406-4BC6-B95F-53E7B448E825/iOSTestbed.app/python/lib/python3.13/test/support/threading_helper.py", line 66, in decorator
return func(*args)
File "/Users/buildbot/Library/Developer/XCTestDevices/F4BBB41D-5207-4016-951B-2DC02AC8DD0F/data/Containers/Bundle/Application/150C37C0-A406-4BC6-B95F-53E7B448E825/iOSTestbed.app/python/lib/python3.13/test/test_socketserver.py", line 133, in run_server
testfunc(svrcls.address_family, addr)
~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/buildbot/Library/Developer/XCTestDevices/F4BBB41D-5207-4016-951B-2DC02AC8DD0F/data/Containers/Bundle/Application/150C37C0-A406-4BC6-B95F-53E7B448E825/iOSTestbed.app/python/lib/python3.13/test/test_socketserver.py", line 160, in dgram_examine
buf = data = receive(s, 100)
~~~~~~~^^^^^^^^
File "/Users/buildbot/Library/Developer/XCTestDevices/F4BBB41D-5207-4016-951B-2DC02AC8DD0F/data/Containers/Bundle/Application/150C37C0-A406-4BC6-B95F-53E7B448E825/iOSTestbed.app/python/lib/python3.13/test/test_socketserver.py", line 43, in receive
raise RuntimeError("timed out on %r" % (sock,))
RuntimeError: timed out on <socket.socket fd=33, family=1, type=2, proto=0, laddr=./test_python__imgs0_7.sock>
Traceback (most recent call last):
File "/Users/buildbot/Library/Developer/XCTestDevices/F4BBB41D-5207-4016-951B-2DC02AC8DD0F/data/Containers/Bundle/Application/150C37C0-A406-4BC6-B95F-53E7B448E825/iOSTestbed.app/python/lib/python3.13/threading.py", line 1041, in _bootstrap_inner
self.run()
~~~~~~~~^^
File "/Users/buildbot/Library/Developer/XCTestDevices/F4BBB41D-5207-4016-951B-2DC02AC8DD0F/data/Containers/Bundle/Application/150C37C0-A406-4BC6-B95F-53E7B448E825/iOSTestbed.app/python/lib/python3.13/threading.py", line 992, in run
self._target(*self._args, **self._kwargs)
~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/buildbot/Library/Developer/XCTestDevices/F4BBB41D-5207-4016-951B-2DC02AC8DD0F/data/Containers/Bundle/Application/150C37C0-A406-4BC6-B95F-53E7B448E825/iOSTestbed.app/python/lib/python3.13/socketserver.py", line 240, in serve_forever
self._handle_request_noblock()
~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^
File "/Users/buildbot/Library/Developer/XCTestDevices/F4BBB41D-5207-4016-951B-2DC02AC8DD0F/data/Containers/Bundle/Application/150C37C0-A406-4BC6-B95F-53E7B448E825/iOSTestbed.app/python/lib/python3.13/socketserver.py", line 320, in _handle_request_noblock
self.handle_error(request, client_address)
~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/buildbot/Library/Developer/XCTestDevices/F4BBB41D-5207-4016-951B-2DC02AC8DD0F/data/Containers/Bundle/Application/150C37C0-A406-4BC6-B95F-53E7B448E825/iOSTestbed.app/python/lib/python3.13/socketserver.py", line 318, in _handle_request_noblock
self.process_request(request, client_address)
~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/buildbot/Library/Developer/XCTestDevices/F4BBB41D-5207-4016-951B-2DC02AC8DD0F/data/Containers/Bundle/Application/150C37C0-A406-4BC6-B95F-53E7B448E825/iOSTestbed.app/python/lib/python3.13/socketserver.py", line 349, in process_request
self.finish_request(request, client_address)
~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/buildbot/Library/Developer/XCTestDevices/F4BBB41D-5207-4016-951B-2DC02AC8DD0F/data/Containers/Bundle/Application/150C37C0-A406-4BC6-B95F-53E7B448E825/iOSTestbed.app/python/lib/python3.13/socketserver.py", line 362, in finish_request
self.RequestHandlerClass(request, client_address, self)
~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/buildbot/Library/Developer/XCTestDevices/F4BBB41D-5207-4016-951B-2DC02AC8DD0F/data/Containers/Bundle/Application/150C37C0-A406-4BC6-B95F-53E7B448E825/iOSTestbed.app/python/lib/python3.13/socketserver.py", line 763, in __init__
self.finish()
~~~~~~~~~~~^^
File "/Users/buildbot/Library/Developer/XCTestDevices/F4BBB41D-5207-4016-951B-2DC02AC8DD0F/data/Containers/Bundle/Application/150C37C0-A406-4BC6-B95F-53E7B448E825/iOSTestbed.app/python/lib/python3.13/socketserver.py", line 858, in finish
self.socket.sendto(self.wfile.getvalue(), self.client_address)
~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
ConnectionResetError: [Errno 54] Connection reset by peer
ERROR
Traceback (most recent call last):
File "/Users/buildbot/Library/Developer/XCTestDevices/F4BBB41D-5207-4016-951B-2DC02AC8DD0F/data/Containers/Bundle/Application/150C37C0-A406-4BC6-B95F-53E7B448E825/iOSTestbed.app/python/lib/python3.13/test/test_socketserver.py", line 222, in test_UnixDatagramServer
self.run_server(socketserver.UnixDatagramServer,
~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
socketserver.DatagramRequestHandler,
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
self.dgram_examine)
^^^^^^^^^^^^^^^^^^^
File "/Users/buildbot/Library/Developer/XCTestDevices/F4BBB41D-5207-4016-951B-2DC02AC8DD0F/data/Containers/Bundle/Application/150C37C0-A406-4BC6-B95F-53E7B448E825/iOSTestbed.app/python/lib/python3.13/test/support/threading_helper.py", line 66, in decorator
return func(*args)
File "/Users/buildbot/Library/Developer/XCTestDevices/F4BBB41D-5207-4016-951B-2DC02AC8DD0F/data/Containers/Bundle/Application/150C37C0-A406-4BC6-B95F-53E7B448E825/iOSTestbed.app/python/lib/python3.13/test/test_socketserver.py", line 133, in run_server
testfunc(svrcls.address_family, addr)
~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/buildbot/Library/Developer/XCTestDevices/F4BBB41D-5207-4016-951B-2DC02AC8DD0F/data/Containers/Bundle/Application/150C37C0-A406-4BC6-B95F-53E7B448E825/iOSTestbed.app/python/lib/python3.13/test/test_socketserver.py", line 160, in dgram_examine
buf = data = receive(s, 100)
~~~~~~~^^^^^^^^
File "/Users/buildbot/Library/Developer/XCTestDevices/F4BBB41D-5207-4016-951B-2DC02AC8DD0F/data/Containers/Bundle/Application/150C37C0-A406-4BC6-B95F-53E7B448E825/iOSTestbed.app/python/lib/python3.13/test/test_socketserver.py", line 43, in receive
raise RuntimeError("timed out on %r" % (sock,))
RuntimeError: timed out on <socket.socket fd=34, family=1, type=2, proto=0, laddr=./test_python_sow1nfse.sock>
|
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
Reviewers
rhettinger
Awaiting requested review from rhettinger
rhettinger is a code owner
Uh oh!
There was an error while loading. Please reload this page.
Assignees
No one assigned
Milestone
No milestone
Development
Successfully merging this pull request may close these issues.
Uh oh!
There was an error while loading. Please reload this page.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
|