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

gh-69093: Expose sqlite3.Blob as a class #91550

Merged
merged 1 commit into from
Apr 15, 2022

Conversation

JelleZijlstra
Copy link
Member

@JelleZijlstra JelleZijlstra commented Apr 15, 2022

I noticed this was missing while writing typeshed stubs. It's
useful to expose it for use in annotations.

GH-69093

I noticed this was missing while writing typeshed stubs. It's
useful to expose it for use in annotations.
@JelleZijlstra
Copy link
Member Author

Skipping news because this is a simple followup for #30680, which was merged just now.

JelleZijlstra added a commit to JelleZijlstra/typeshed that referenced this pull request Apr 15, 2022
- Blob from python/cpython#30680 (and anticipating that python/cpython#91550 will be merged)
- Aggregate window functions from python/cpython#20903
- Serialize/deserialize from python/cpython#26728
- Limit setting from python/cpython#28463
@erlend-aasland
Copy link
Contributor

erlend-aasland commented Apr 15, 2022

I don't use typing, but I guess this is ok.

BTW, we need to disallow instantiation for blob types. I should've thought about that in the first place, but with this change it's even more important. We can embed that change here, or do it in another PR; I'm fine with both.

@JelleZijlstra JelleZijlstra merged commit b7f83bd into python:main Apr 15, 2022
@JelleZijlstra JelleZijlstra deleted the exposeblob branch April 15, 2022 13:30
@JelleZijlstra
Copy link
Member Author

Thanks! Also I don't think it's useful only for annotations: we also mention this class in the docs as if it is accessible, and it's useful for interactive exploration if you can do dir(sqlite3.Blob).

@erlend-aasland
Copy link
Contributor

Thanks! Also I don't think it's useful only for annotations: we also mention this class in the docs as if it is accessible, and it's useful for interactive exploration if you can do dir(sqlite3.Blob).

Good point!

srittau pushed a commit to python/typeshed that referenced this pull request Apr 16, 2022
- Blob from python/cpython#30680 (and anticipating that python/cpython#91550 will be merged)
- Aggregate window functions from python/cpython#20903
- Serialize/deserialize from python/cpython#26728
- Limit setting from python/cpython#28463
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.

4 participants