Full adodbapi type-check and test fixes#2681
Draft
Avasam wants to merge 11 commits intomhammond:mainfrom
Draft
Conversation
5915f6a to
dddb869
Compare
4c0ba75 to
0239ca6
Compare
…adodbapi-type-check
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
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.
assertwhere code should fail anyway, to help static type checkers. This would also result in clearer errors in unittests__getattr__that can actually be implemented as propertiesloadTestsFromTestCaserather thanloadTestsFromModulemdb_nameparam tosetuptestframework.makemdbinadodbapi/test/test_adodbapi_dbapi20.pypip install ./adodbapi)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.pyon the CI: