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

Mark python cp_model module as type hinted #3993

Closed
bodograumann opened this issue Nov 18, 2023 · 0 comments
Closed

Mark python cp_model module as type hinted #3993

bodograumann opened this issue Nov 18, 2023 · 0 comments
Assignees
Labels
Feature Request Missing Feature/Wrapper Lang: Python Python wrapper issue
Milestone

Comments

@bodograumann
Copy link

What language and solver does this apply to?
Python, packaging

Describe the problem you are trying to solve.
I want to typecheck my code, which is using from ortools.sat.python import cp_model, with mypy.

Currently mypy just gives an error:

error: Skipping analyzing "ortools.sat.python": module is installed, but missing library stubs or py.typed marker [import]

Cff.:

Describe the solution you'd like
Please add the py.typed marker, so that mypy accepts the module as typed.

Describe alternatives you've considered
Unfortunately it is currently not possible to force the mypy behaviour. Cf. python/mypy#8545

@Mizux Mizux self-assigned this Nov 18, 2023
@Mizux Mizux added Feature Request Missing Feature/Wrapper Lang: Python Python wrapper issue labels Nov 18, 2023
@Mizux Mizux added this to the v9.9 milestone Nov 18, 2023
lperron added a commit that referenced this issue Nov 22, 2023
@lperron lperron closed this as completed Nov 22, 2023
@Mizux Mizux assigned lperron and unassigned Mizux Nov 22, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature Request Missing Feature/Wrapper Lang: Python Python wrapper issue
Projects
Archived in project
Development

No branches or pull requests

3 participants