Skip to content

Conversation

@Avasam
Copy link
Collaborator

@Avasam Avasam commented Nov 25, 2025

Overlaps with #2286, merging that first will reduce changes here.


I wanted to see how far I could get running the adodbapi tests (for #1495) but found them in a poor and broken state (especially on Python 3.13+)

Lots of those issues can be caught with static type-checking, so I enabled the full pyright standard checks and started fixing.

  • Added a few assert where code should fail anyway, to help static type checkers. This would also result in clearer errors in unittests
  • Added a few attributes type declaration (often that are meant to be set by subclasses implementing an abstract class)
  • Updated __getattr__ that can actually be implemented as properties
  • Fixed test detection by using loadTestsFromTestCase rather than loadTestsFromModule
  • Added a missing mdb_name param to setuptestframework.makemdb in adodbapi/test/test_adodbapi_dbapi20.py
  • Ensure this is all tested on CI
  • Fixed standalone adodbapi install (pip install ./adodbapi)
  • Some comments were better as docstrings
  • Fixed a few typos

I've managed to run all SQL Server tests locally using SQL Express. So these would be the following steps (which I'll offload to another PR(s)) to be able to run adodbapi/test/test_adodbapi_dbapi20.py on the CI:

@Avasam Avasam force-pushed the Full-adodbapi-type-check branch from 5915f6a to dddb869 Compare November 25, 2025 04:24
@Avasam Avasam force-pushed the Full-adodbapi-type-check branch from 4c0ba75 to 0239ca6 Compare November 25, 2025 16:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant