[Python-Dev] Add a developer mode to Python: -X dev command line option (original) (raw)
Antoine Pitrou antoine at python.org
Mon Nov 13 11:51:06 EST 2017
- Previous message (by thread): [Python-Dev] Add a developer mode to Python: -X dev command line option
- Next message (by thread): [Python-Dev] Add a developer mode to Python: -X dev command line option
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Le 13/11/2017 à 17:46, Victor Stinner a écrit :
2017-11-13 17:40 GMT+01:00 Antoine Pitrou <solipsis at pitrou.net>:
I would personally not add
-b
in those options. I think it was useful while porting stuff to 3.x, but not so much these days. You should consider youself as lucky if you completed to port all your code to Python 3. It's not my case yet :-) (I'm thinking to code that I have to port, not only code that I wrote myself.)
The main issue I have with -b
is actually that you can get spurious
warnings about properly working code. You can also get warnings in
well-tested third-party libraries, e.g.:
distributed/tests/test_client.py::test_get_versions /home/antoine/miniconda3/envs/dask36/lib/python3.6/site-packages/pandas/core/dtypes/common.py:20: BytesWarning: Comparison between bytes and string for t in ['O', 'int8', 'uint8', 'int16', 'uint16', /home/antoine/miniconda3/envs/dask36/lib/python3.6/site-packages/pandas/io/packers.py:231: BytesWarning: Comparison between bytes and string 7: np.dtype('int64'),
distributed/tests/test_client.py::test_serialize_collections_of_futures_sync /home/antoine/miniconda3/envs/dask36/lib/python3.6/site-packages/numpy/core/numeric.py:583: BytesWarning: Comparison between bytes and string return array(a, dtype, copy=False, order=order, subok=True)
distributed/tests/test_client.py::test_serialize_collections_of_futures /home/antoine/miniconda3/envs/dask36/lib/python3.6/site-packages/numpy/core/numeric.py:583: BytesWarning: Comparison between bytes and string return array(a, dtype, copy=False, order=order, subok=True)
(this is an excerpt of the warnings I got by running our test suite with "python -b")
Regards
Antoine.
- Previous message (by thread): [Python-Dev] Add a developer mode to Python: -X dev command line option
- Next message (by thread): [Python-Dev] Add a developer mode to Python: -X dev command line option
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]