Add mypy type checking for Python 3.14 and fix deprecation warning #1470
+2
−4
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.
Add
mypy
type checking for Python 3.14 and useopen()
instead ofcodecs.open()
due to deprecation in 3.14.The first release candidate for Python 3.14 was released on 2025-07-22 and I did some local testing.
The first thing I realized is that
mypy
now works well with 3.14 and so we should add type checking on that platform to our GitLab Actions.The second thing I noticed is that when we ran tests with pytests, we were getting a bunch of warnings due to codecs.open() being deprecated. Since at least Python 3.6 there has been no need for that as
open()
does everything it can do plus more.