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

[DOP-11371] Fix @slot decorator #183

Merged
merged 1 commit into from
Dec 8, 2023
Merged

[DOP-11371] Fix @slot decorator #183

merged 1 commit into from
Dec 8, 2023

Conversation

dolfinus
Copy link
Member

@dolfinus dolfinus commented Dec 8, 2023

Change Summary

It looks like Pylance (VS Code extension for Python) does not recognize typing_extensions.ParamSpec.

With ParamsSpec:
image
image

Without:
image
image

ParamSpec is a recommended way to tell linters how inputs of callable: Callable[Spec, ReturnType] are passed to def new_callable(*Spec.args, **Spec.kwargs) -> ReturnType:.
Fortunately, there is another (but less precise) way to describe this - Callable[..., ReturnType]. This is used for now.

Related issue number

Checklist

  • Commit message and PR title is comprehensive
  • Keep the change as small as possible
  • Unit and integration tests for the changes exist
  • Tests pass on CI and coverage does not decrease
  • Documentation reflects the changes where applicable
  • docs/changelog/next_release/<pull request or issue id>.<change type>.rst file added describing change
    (see CONTRIBUTING.rst for details.)
  • My PR is ready to review.

Copy link

codecov bot commented Dec 8, 2023

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (4092134) 94.08% compared to head (4d268c1) 94.05%.

Additional details and impacted files
@@             Coverage Diff             @@
##           develop     #183      +/-   ##
===========================================
- Coverage    94.08%   94.05%   -0.03%     
===========================================
  Files          205      205              
  Lines         7744     7742       -2     
  Branches      1400     1400              
===========================================
- Hits          7286     7282       -4     
- Misses         332      333       +1     
- Partials       126      127       +1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@dolfinus dolfinus merged commit 0e66bf7 into develop Dec 8, 2023
33 checks passed
@dolfinus dolfinus deleted the bugfix/DOP-11371 branch December 8, 2023 13:28
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.

None yet

2 participants