Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Pydantic III] Use list/dict annotations #1021

Merged
merged 9 commits into from
Aug 21, 2024
Merged

Conversation

bendichter
Copy link
Contributor

As of Python 3.9, standard collections (list, tuple, dict) can be used in typehints instead of List, Tuple, and Dict.

@h-mayorquin
Copy link
Collaborator

This will have conflicts with #1017.
How do you guys want to handle @CodyCBakerPhD ?

@CodyCBakerPhD
Copy link
Member

@h-mayorquin I was planning on doing a PR just like this after #1017 to avoid exactly that

@bendichter
Copy link
Contributor Author

yeah, it may have been a bit early. Let's close this and wait

@CodyCBakerPhD
Copy link
Member

The damage isn't too awful

@CodyCBakerPhD CodyCBakerPhD changed the title New list typehints [Pydantic III] New list/dict typehints Aug 21, 2024
@CodyCBakerPhD CodyCBakerPhD changed the title [Pydantic III] New list/dict typehints [Pydantic III] Use list/dict annotations Aug 21, 2024
@bendichter
Copy link
Contributor Author

I'm unable to officially review since I opened this PR, but this looks good to me. I'm happy to merge once the tests pass

@CodyCBakerPhD CodyCBakerPhD enabled auto-merge (squash) August 21, 2024 18:56
@CodyCBakerPhD CodyCBakerPhD merged commit 8e20a25 into main Aug 21, 2024
34 of 35 checks passed
@CodyCBakerPhD CodyCBakerPhD deleted the new-list-typehints branch August 21, 2024 20:54
Copy link

codecov bot commented Nov 19, 2024

Codecov Report

Attention: Patch coverage is 98.24561% with 2 lines in your changes missing coverage. Please review.

Project coverage is 91.39%. Comparing base (60ca62f) to head (ec0f9c5).
Report is 87 commits behind head on main.

Files with missing lines Patch % Lines
src/neuroconv/tools/data_transfers/_dandi.py 0.00% 1 Missing ⚠️
src/neuroconv/tools/data_transfers/_globus.py 0.00% 1 Missing ⚠️
Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #1021      +/-   ##
==========================================
+ Coverage   91.37%   91.39%   +0.02%     
==========================================
  Files         129      129              
  Lines        7860     7879      +19     
==========================================
+ Hits         7182     7201      +19     
  Misses        678      678              
Flag Coverage Δ
unittests 91.39% <98.24%> (+0.02%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
src/neuroconv/basedatainterface.py 94.44% <100.00%> (+0.07%) ⬆️
...nv/datainterfaces/behavior/audio/audiointerface.py 89.02% <100.00%> (+0.13%) ⬆️
...v/datainterfaces/behavior/deeplabcut/_dlc_utils.py 56.49% <100.00%> (ø)
...ces/behavior/deeplabcut/deeplabcutdatainterface.py 92.50% <100.00%> (ø)
...s/behavior/lightningpose/lightningposeconverter.py 96.77% <100.00%> (+0.05%) ⬆️
...havior/lightningpose/lightningposedatainterface.py 95.28% <100.00%> (+0.04%) ⬆️
...onv/datainterfaces/behavior/neuralynx/nvt_utils.py 97.05% <100.00%> (ø)
...oconv/datainterfaces/behavior/video/video_utils.py 97.14% <100.00%> (ø)
...atainterfaces/behavior/video/videodatainterface.py 93.58% <100.00%> (+0.04%) ⬆️
...erfaces/ecephys/baserecordingextractorinterface.py 95.87% <100.00%> (ø)
... and 35 more
---- 🚨 Try these New Features:

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.

3 participants