Skip to content

[BUG] Crash on Python 3.12 (Windows) when pyxcp runs under Robot Framework (0xC0000005) #289

Description

@wolf-gili

Description

Hi,
We’re seeing a reproducible crash after migrating from Python 3.10 to 3.12 on Windows.
Setup:

  • OS: Windows 10
  • Python: 3.12.x
  • Using pyxcp over ETH/UDP (IPv6)
  • Test execution via Robot Framework
    Behavior:
  • Running the same XCP flow directly from a normal Python main script works fine.
  • Running it from Robot Framework crashes the Python process with:
    • exit code -1073741819 (0xC0000005), Windows access violation
  • faulthandler stack trace points into pyxcp:
    • pyxcp.transport.eth (_packet_listen / listen)
    • pyxcp.master.master.connect()
    • pyxcp.transport.base._request_internal()
      Notes:
  • This is not a Python exception; it is a hard process crash.
  • As a workaround, we moved pyxcp work into a separate spawned process and communicate via queues; this avoids the crash under Robot.
    Question:
  • Is this a known compatibility issue with Python 3.12 and/or threaded execution environments like Robot Framework?
  • Do you recommend a specific pyxcp version, transport/threading setting, or connect/listener sequence for Python 3.12 on Windows?
  • If useful, we can share a minimal reproducer and full faulthandler log.

Transport Layer

Ethernet (UDP)

Category

Transport / Connection

pyxcp Version

0.25.5

Python Version

3.12

Operating System

Windows 10

Installation Method

pip install pyxcp

Steps to Reproduce

  1. Use Windows + Python 3.12.x environment.
  2. Run our XCP flow with pyxcp over ETH/UDP (IPv6) inside Robot Framework (same flow that works from a normal Python main script).
  3. Execute a connection sequence that includes:
    • transport.start_listener()
    • master.connect()
  4. During Robot execution, Python crashes with:
    • Process finished with exit code -1073741819 (0xC0000005)
  5. faulthandler stack trace points to:
    • pyxcp.transport.eth (_packet_listen, listen)
    • pyxcp.transport.base._request_internal
    • pyxcp.master.master.connect

Expected Behavior

pyxcp should behave the same under Robot Framework as in a normal Python main script:

  • no native process crash,
  • no access violation (0xC0000005),
  • clean connect/status flow or a regular Python exception if connection fails.

Actual Behavior

Under Robot Framework (Windows, Python 3.12), pyxcp crashes the interpreter with:

  • Process finished with exit code -1073741819 (0xC0000005)
  • Windows fatal exception: access violation
    faulthandler points to:
  • pyxcp.master.master.connect
  • pyxcp.transport.base._request_internal
  • pyxcp.transport.eth._packet_listen / listen
    Same flow works from a regular Python main script.
    Current workaround: run pyxcp in a separate spawned process.

Configuration

Additional Logs


Checklist

  • I have searched existing issues for duplicates
  • I have tested with the latest version of pyxcp
  • I can provide a minimal reproducible example

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions