Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit b80c026

Browse filesBrowse files
author
Anselm Kruis
committed
Stackless issue python#218: Fix using Stackless as embedded Python interpreter
The fix for Stackless issue 186 (support for sub-interpreters) broke some typical use cases. (cherry picked from commit 5b29b24)
1 parent bcd0122 commit b80c026
Copy full SHA for b80c026

File tree

Expand file treeCollapse file tree

3 files changed

+6
-3
lines changed
Filter options
Expand file treeCollapse file tree

3 files changed

+6
-3
lines changed

‎Stackless/changelog.txt

Copy file name to clipboardExpand all lines: Stackless/changelog.txt
+5-1Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,10 @@ What's New in Stackless 3.X.X?
99

1010
*Release date: 20XX-XX-XX*
1111

12+
- https://github.com/stackless-dev/stackless/issues/218
13+
Fix using Stackless as embedded Python interpreter. The fix for Stackless
14+
issue 186 (support for sub-interpreters) broke some typical use cases.
15+
1216
- https://github.com/stackless-dev/stackless/issues/220
1317
Improve the error handling in case of failed stack transfers / hard tasklet
1418
switches. Call Py_FatalError, if a clean recovery is impossible.
@@ -17,7 +21,7 @@ What's New in Stackless 3.X.X?
1721
C-API documentation update: update the names of watchdog flags to match the
1822
implementation.
1923

20-
- https://github.com/stackless-dev/stackless/issues/221
24+
- https://github.com/stackless-dev/stackless/issues/222
2125
Fix a bug that could cause an assertion failure and a reference leak during
2226
the termination of a main-tasklet, if an application embeds Stackless Python.
2327

‎Stackless/core/stacklesseval.c

Copy file name to clipboardExpand all lines: Stackless/core/stacklesseval.c
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -352,7 +352,7 @@ slp_eval_frame(PyFrameObject *f)
352352
retval = climb_stack_and_eval_frame(f);
353353
initial_stub = ts->st.initial_stub;
354354
/* cst might be NULL in OOM conditions */
355-
if (initial_stub != NULL) {
355+
if (ts->interp != _PyRuntime.interpreters.main && initial_stub != NULL) {
356356
PyCStackObject *cst;
357357
register int found = 0;
358358
assert(initial_stub->startaddr == ts->st.cstack_base);

‎Stackless/unittests/test_slp_embed.py

Copy file name to clipboardExpand all lines: Stackless/unittests/test_slp_embed.py
-1Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,6 @@ def setUp(self):
2424
from test.support import verbose
2525

2626

27-
@unittest.skip("Stackless issue 218")
2827
class EmbeddingTests(EmbeddingTestsMixin, unittest.TestCase):
2928
def test_schedule(self):
3029
env = dict(os.environ)

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.