Skip to content

Commit d4ab706

Browse files
Fix CI failures on Github (#94)
* Accommodate FrameLocalsProxy introduction in Python 3.13 The `frame.f_locals` is now a write-through proxy object of type `FrameLocalsProxy`; see PEP 667. This fix is based on zopefoundation/zope.interface#294 and specifically on zopefoundation/zope.interface#294 (comment). Fixes #91. * add 3.13 to checked ci * use macos-12 to test macos (later versions dont seem to build python correctly) --------- Co-authored-by: Benjamin A. Beasley <[email protected]>
1 parent 966cce8 commit d4ab706

File tree

3 files changed

+13
-3
lines changed

3 files changed

+13
-3
lines changed

.github/workflows/ci-tests.yml

+3-2
Original file line numberDiff line numberDiff line change
@@ -22,11 +22,12 @@ jobs:
2222
- "3.10"
2323
- "3.11"
2424
- "3.12"
25+
- "3.13"
2526
- "pypy-3.8"
2627
os:
2728
- "ubuntu-latest"
2829
- "windows-latest"
29-
- "macos-latest"
30+
- "macos-12" # (later seem to fail building python)
3031
architecture:
3132
- x64
3233
- x86
@@ -35,7 +36,7 @@ jobs:
3536
# Linux and macOS don't have x86 python
3637
- os: "ubuntu-latest"
3738
architecture: x86
38-
- os: "macos-latest"
39+
- os: "macos-12"
3940
architecture: x86
4041

4142
name: "Python: ${{ matrix.py }}-${{ matrix.architecture }} on ${{ matrix.os }}"

CHANGES.rst

+7
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,10 @@
1+
Unreleased
2+
----------
3+
4+
- Add support for Python 3.13 (thanks to musicinmybrain).
5+
6+
- Fix GitHub test actions.
7+
18
3.1.0 (2023-11-06)
29
------------------
310

tests/test_advice.py

+3-1
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,9 @@ def testCallInfo(self):
9393
sys._getframe()
9494
)
9595
self.assertEqual(kind, "function call")
96-
self.assertTrue(f_locals is locals()) # ???
96+
frame = sys._getframe()
97+
self.assertEqual(f_locals, frame.f_locals)
98+
self.assertEqual(f_locals, locals())
9799
for d in module.__dict__, f_globals:
98100
self.assertTrue(d is globals())
99101
self.assertEqual(len(codeinfo), 4)

0 commit comments

Comments
 (0)