Skip to content

Conversation

Copy link

Copilot AI commented Dec 15, 2025

Two steps in the Python 3.7 legacy test workflow had identical names "Run tests", making CI failure diagnosis ambiguous. Additionally, the tests were failing due to Python 3.7 lacking AsyncMock and IsolatedAsyncioTestCase in its standard library.

Changes:

  • Renamed dependency installation step from "Run tests" to "Install dependencies"
  • Actual test execution step retains "Run tests" name
  • Added fallback import for AsyncMock in tests/utils/_mock.py to support Python 3.7 (uses asyncmock package when unittest.mock.AsyncMock is not available)
  • Added compatibility shim for IsolatedAsyncioTestCase in tests/test_async_vinted_wrapper.py for Python 3.7 (this class was introduced in Python 3.8)

This ensures CI logs clearly distinguish between dependency installation failures and test execution failures, and enables the test suite to run successfully on Python 3.7.


💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.

Co-authored-by: Giglium <28485612+Giglium@users.noreply.github.com>
Copilot AI changed the title [WIP] Enable tests for Python 3.7 in GitHub Actions Fix duplicate step names in test_legacy.yml workflow Dec 15, 2025
Copilot AI requested a review from Giglium December 15, 2025 21:36
@Giglium
Copy link
Owner

Giglium commented Dec 15, 2025

@copilot the python legacy test is still failing

Co-authored-by: Giglium <28485612+Giglium@users.noreply.github.com>
Copy link
Author

Copilot AI commented Dec 15, 2025

@copilot the python legacy test is still failing

Fixed the Python 3.7 compatibility issue. The test was failing because AsyncMock doesn't exist in Python 3.7's standard library. Added a fallback import to use the asyncmock package for Python 3.7. (commit ab88a38)

Copilot AI changed the title Fix duplicate step names in test_legacy.yml workflow Fix Python 3.7 compatibility in legacy test workflow Dec 15, 2025
@Giglium
Copy link
Owner

Giglium commented Dec 16, 2025

@copilot nice! Now the error is: AttributeError: module 'unittest' has no attribute 'IsolatedAsyncioTestCase' Can you also solve this one?

Co-authored-by: Giglium <28485612+Giglium@users.noreply.github.com>
Copy link
Author

Copilot AI commented Dec 16, 2025

@copilot nice! Now the error is: AttributeError: module 'unittest' has no attribute 'IsolatedAsyncioTestCase' Can you also solve this one?

Fixed the IsolatedAsyncioTestCase compatibility issue. Python 3.7 doesn't have this class (introduced in Python 3.8), so I added a compatibility shim that provides the same functionality for Python 3.7. (commit ef79b98)

@Giglium Giglium closed this Dec 16, 2025
@Giglium Giglium deleted the copilot/sub-pr-137 branch December 16, 2025 08:01
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