Skip to content
This repository was archived by the owner on Feb 13, 2025. It is now read-only.
This repository was archived by the owner on Feb 13, 2025. It is now read-only.

Undefined behaviour of the C-Python tests caused by lazy initialisation of stackless #126

@ghost

Description

Originally reported by: Anselm Kruis (Bitbucket: akruis, GitHub: akruis)


Problem

Since change e5a2ecca2b08 Stackless initializes the stackless subsystem only if application code loads the module stackless. This causes undefined behaviour in the C-Python test suite, if the execution order of the tests gets randomized. Especially some pickling tests are sensitive, because the initialisation of Stackless enables the pickling of additional types.

I observed failures especially with 3.5-slp, but the problem exists in all 3.x branches.

Proposed Solution

I'll import stackless in the module test.support. Nearly every test-module imports this module very early. While I'm at it, I'll also unify the tests for stackless being available.


Activity

ghost

ghost commented on Apr 15, 2017

@ghost

Original comment by Anselm Kruis (Bitbucket: akruis, GitHub: akruis):


Fixed in changesets:

  • 3.3-slp: 3fca818f7f75
  • 3.4-slp: a103f282195d
  • 3.5-slp: 540d64167ee3

Not yet merged into default-slp.

ghost added on Sep 24, 2017
ghost added this to the 3.3.7-slp milestone on Sep 24, 2017
ghost closed this as completedon Sep 24, 2017
added 4 commits that reference this issue on Oct 29, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

      Development

      No branches or pull requests

        Participants

        No participants

        Issue actions

          Undefined behaviour of the C-Python tests caused by lazy initialisation of stackless · Issue #126 · stackless-dev/stackless