Skip to content

Fix CI test job import failure by invoking pytest as a module - #1

Open
CallSohail with Copilot wants to merge 2 commits into
mainfrom
copilot/fix-test-failing-job
Open

CallSohail with Copilot wants to merge 2 commits into
mainfrom
copilot/fix-test-failing-job

Conversation

Copilot AI commented Sep 22, 2026 •

Copy link
Copy Markdown

The test GitHub Actions job was failing during collection because the workflow invoked the installed pytest entrypoint, and the local sway package was not importable in that execution path. This updates the CI test step to run pytest through the active Python interpreter so repository-local imports resolve consistently.

  • CI test invocation

    • Change the workflow’s fast-test step from the pytest console script to python -m pytest.
    • Preserves the existing test scope and behavior; only the execution path changes.
  • Failure addressed

    • Fixes ModuleNotFoundError: No module named 'sway' during tests/test_logic.py collection in Actions.
  • Workflow diff

    - name: Fast tests
      run: python -m pytest -q tests/test_logic.py

Co-authored-by: CallSohail <77721715+CallSohail@users.noreply.github.com>
Copilot AI changed the title [WIP] Fix failing GitHub Actions job "test" Fix CI test job import failure by invoking pytest as a module Sep 22, 2026
Copilot AI requested a review from CallSohail September 22, 2026 13:04
@CallSohail

Copy link
Copy Markdown
Owner

Commited

@CallSohail
CallSohail marked this pull request as ready for review September 22, 2026 13:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants