Skip to content

Fix Any subclassing in fpdf2 #9536

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

Merged
merged 7 commits into from
Feb 9, 2023
Merged

Conversation

Avasam
Copy link
Collaborator

@Avasam Avasam commented Jan 14, 2023

Can't reference fontools directly because it does not have a py.typed marker (it's only partially typed).
It would be a bit overkill anyway.

Fixes an Any subclassing error in fpdf2 by shimming the needed fontools types.

Ref: #9491

@github-actions

This comment has been minimized.

@github-actions

This comment has been minimized.

@Avasam Avasam mentioned this pull request Feb 1, 2023
@github-actions

This comment has been minimized.

@github-actions
Copy link
Contributor

github-actions bot commented Feb 7, 2023

According to mypy_primer, this change has no effect on the checked open source code. 🤖🎉

@Avasam
Copy link
Collaborator Author

Avasam commented Feb 8, 2023

Unlike in #9525, all type definitions here are subclasses of each-other. And parameters use standard types. So the whole shim file makes more sense for the full BasePen structure.

@srittau srittau merged commit 10086c0 into python:main Feb 9, 2023
@Avasam Avasam deleted the fonttools-in-fpdf2 branch February 9, 2023 14:45
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.

2 participants