24.10.20 06:19, Inada Naoki пише:
> To avoid BytesWarning, the compiler needs to do some hack when they
> need to store bytes and str constants in one dict or set.
> BytesWarning has maintenance costs. It is not huge, but significant.
> 
> When can we remove it? My idea is:
> 
> 3.10: Deprecate the -b option.
> 3.11: Make the -b option no-op. Bytes warning never emits.
> 3.12: Remove the -b option.
> 
> BytesWarning will be deprecated in the document, but not to be removed.
> Users who want to use the -b option during 2->3 conversion need to use
> Python ~3.10 for a while.

I agree that it should be removed, and that BytesWarning should be kept
(maybe we will reuse it for other purposes in future).

But I do not see how deprecating it before removing could help. Using it
with -We will no longer work, and without -We it will just add a noise.

We can just make -b a no-op at any moment and remove it few versions
later. Or maybe first make it no-op, then deprecate, then remove. But it
looks too much.

-b is still usable in 3.9, so it can be removed not earlier than EOL of
3.9. Users that use it should be able to use it with all maintained
Python versions if it makes sense with at least one of them.

3.x: Make the -b option no-op. Bytes warning never emits.
3.x+4: Remove the -b option.
_______________________________________________
Python-Dev mailing list -- python-dev@python.org
To unsubscribe send an email to python-dev-le...@python.org
https://mail.python.org/mailman3/lists/python-dev.python.org/
Message archived at 
https://mail.python.org/archives/list/python-dev@python.org/message/6LBAYEQSWUEFKNR6LMJ35OAF2YZXAVWE/
Code of Conduct: http://python.org/psf/codeofconduct/

Reply via email to