-
-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
Remove redis (not before February 2025) #10592
Comments
Redis 5.0.0 added a py.typed file. Still, I wonder whether we should remove our stubs at this point, as the redis code is basically untyped, even quite fundamental classes and methods. |
Yes, I'm pretty unsure what the best course of action is for our users here. On the one hand, we generally remove stubs as soon as a library adds a On the other hand, from the conversation in redis/redis-py#2738, it sounds like the On the third hand, it also sounds from the conversation in redis/redis-py#2738 like they're unhappy with the quality of our stubs, and would prefer to provide their own type hints if possible. I suppose the ideal situation would be if we contributed as many as possible of our types in typeshed to redis. But without knowing where the errors referenced in redis/redis-py#2738 (comment) are, it's hard to know where these would be welcome and where they wouldn't be. |
@AlexWaygood typeshed recently supports creating partial stubs on purpose. Exactly with cases like this in mind. It's something that is likely to happen eventually in pywin32 as well. We can mark the stub as partial, but NOT stubtest incomplete. Then ignore known typed modules (with a comment) in Type tests will of course need the base library to be installed (can't remember if they already do that. Pyright?) |
Oh, so if we mark the stubs as |
This is the specification for partial stubs as per https://peps.python.org/pep-0561/#partial-stub-packages
Pyright's documentation about order resolution is relevant here as well: https://microsoft.github.io/pyright/#/import-resolution?id=resolution-order |
Since there are so many upstream issues yet to be resolve, can we remove the recommendation to remove
Or if you don't want it removed, at least add some caveats? |
@meshantz Thanks for the suggestion. We now removed the wording and instead suggest du leave the package installed for now. |
Note that typeshed-internal/stub_uploader#108 will probably need to be fixed first to properly support partial type stubs for Redis. |
So, we're in march. Do we know which way we wanna go? I haven't checked the state of typing in redis in a while, but assuming it's still incomplete compared to typeshed, do we wanna keep going for a gradual transition? |
It is incomplete, many types are just |
I'm marking this issue as deferred for now. |
#12426 now marks redis as obsolete again. It's been nearly a year since the release of redis 5. While I didn't check the current state of the annotations in upstream redis, our current stubs only support redis 4 and there have been PRs to add redis 5 features. I think it's best if we continue to support the redis 4 stubs for another 6 months before removing them. Any typing improvements for redis 5 should be contributed to redis-py directly. |
Not sure where best to ask this, but I don't think the typings here should be removed for
See also: redis/redis-py#2399, redis/redis-py#2933 |
@HassanAbouelela In the end this is a decision by the redis-py maintainers. As long as they commit to providing type annotations by providing a py.typed file, I don't want to step on their toes to do so. If redis-py were to drop the commitment and someone would step forward to update our stubs to redis-py 5, we could continue providing those stubs. |
I understand, thank you. |
It seems that Redis Inc., owners of the Redis trademark are tightening their use of the trademark. (Cf. redis-rs/redis-rs#1419) As such I suggest we remove the stubs now, instead of February to avoid any potential legal issues. What should we do about the published packages on PyPI? Cc @ilevkivskyi, who "owns" the package (all typeshed package really) on PyPI as far as I know. |
I have opinions but IANAL. 😶 I have no issues dropping dropping support for the stubs earlier than intended (we already dragged their removal initially in hope of maintenance or cooperation with synchronizing the stubs with upstream, which didn't happen). As for published package on PyPI, I would pity users using it if it has to be pulled, and I would hope for it not to be misused if transferred. Of course I would prefer that nothing happens with it. But that's outside my perogative. |
Recognising that people in open source have complicated feelings about redis, I don't think there's much legal risk, especially so based on comments like redis-rs/redis-rs#1419 (comment) I'm happy to mark the stubs as obsolete since upstream ships a py.typed, but I'd be strongly opposed to yanking releases or deleting the project or doing anything hasty that hurts our existing users. |
Closes: python#10592
#13157 removes the stubs from the repository. We can keep the PyPI project for now, unless we get complaints from Redis Inc. |
Btw I don't really "own" |
Deferred: As of redis-py 5.0.3 the upstream annotations are lacking. We should not remove these stubs, until the upstream annotations reach parity with the stubs.The text was updated successfully, but these errors were encountered: