Skip to content

Conversation

@hoechenberger
Copy link
Member

@hoechenberger hoechenberger commented Nov 22, 2023

An incorrect type hint sneaked in via #11969, causing confusion to static type checkers.

Since we don't use type hints in MNE yet (except for some very rare exceptions), I simply removed the faulty one instead of fixing it.

cc @KristijanArmeni

FYI the correct hint for our supported versions of Python would be Optional[List[str]] or Union[None, List[str]]

An incorrect type hint sneaked in via mne-tools#11969, causing confusion
to static type checkers.

Since we don't use type hints in MNE yet (except for some very
rare exceptions), I simply removed the faulty one
instead of fixing it.
@hoechenberger
Copy link
Member Author

@larsoner I also think it's unusual that verbose isn't the last keyword in the function signature; and the last two parameters should probably be keyword-only. Thoughts?

@larsoner
Copy link
Member

Yes verbose should be last and kw-only (okay to change the exclude one, too). Can you make that change in this PR and I'll merge and backport? I think we can push out a 1.6.1 quickly to get the fix out there before the * annoys too many people :)

@hoechenberger
Copy link
Member Author

Can you take over please? I'm a bit busy with other stuff :)

@hoechenberger
Copy link
Member Author

@larsoner I rearranged the signature but didn't add a changelog entry yet

@larsoner larsoner added the backport-candidate on-merge: backport to maint/1.11 label Nov 27, 2023
* upstream/main:
  Add some omitted dependencies to "full" and "doc" variants (mne-tools#12235)
  Fix pyproject.toml setuptools configuration (mne-tools#12240)
  FIX: Allow eyetrack channels to be used with plot_compare_evoked (mne-tools#12190)
@hoechenberger
Copy link
Member Author

Thanks for cleaning things up, @larsoner!

@larsoner larsoner merged commit 133d589 into mne-tools:main Nov 27, 2023
@hoechenberger hoechenberger deleted the neuralynx branch November 27, 2023 20:36
@larsoner larsoner added backported and removed backport-candidate on-merge: backport to maint/1.11 labels Nov 28, 2023
snwnde pushed a commit to snwnde/mne-python that referenced this pull request Mar 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants