Le 13/11/2017 à 17:46, Victor Stinner a écrit :
> 2017-11-13 17:40 GMT+01:00 Antoine Pitrou <solip...@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.
_______________________________________________
Python-Dev mailing list
Python-Dev@python.org
https://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com

Reply via email to