SyntaxWarnings when running in Python 3.8
Closed this issue · 2 comments
giadarol commented
/afs/cern.ch/work/g/giadarol/sim_workspace_mpi_py3/PyHEADTAIL/PyHEADTAIL/particles/particles.py:199: SyntaxWarning: "is not" with a literal. Did you mean "!="?
if include_non_sliced is not 'never':
/afs/cern.ch/work/g/giadarol/sim_workspace_mpi_py3/PyHEADTAIL/PyHEADTAIL/particles/particles.py:199: SyntaxWarning: "is not" with a literal. Did you mean "!="?
if include_non_sliced is not 'never':
/afs/cern.ch/work/g/giadarol/sim_workspace_mpi_py3/PyHEADTAIL/PyHEADTAIL/particles/particles.py:201: SyntaxWarning: "is" with a literal. Did you mean "=="?
if len(ix)>0 or include_non_sliced is 'always':
/afs/cern.ch/work/g/giadarol/sim_workspace_mpi_py3/PyHEADTAIL/PyHEADTAIL/particles/particles.py:201: SyntaxWarning: "is" with a literal. Did you mean "=="?
if len(ix)>0 or include_non_sliced is 'always':
/afs/cern.ch/work/g/giadarol/sim_workspace_mpi_py3/PyHEADTAIL/PyHEADTAIL/particles/slicing.py:247: SyntaxWarning: "is" with a literal. Did you mean "=="?
if self.mode is 'uniform_charge':
/afs/cern.ch/work/g/giadarol/sim_workspace_mpi_py3/PyHEADTAIL/PyHEADTAIL/particles/slicing.py:464: SyntaxWarning: "is" with a literal. Did you mean "=="?
if pm.device is 'GPU':
giadarol commented
Some more:
if direction is 'x':
/afs/cern.ch/work/g/giadarol/sim_workspace_mpi_py3/PyHEADTAIL/PyHEADTAIL/cobra_functions/pdf_integrators_2d.py:88: SyntaxWarning: "is" with a literal. Did you mean "=="?
elif direction is 'y':
/afs/cern.ch/work/g/giadarol/sim_workspace_mpi_py3/PyHEADTAIL/PyHEADTAIL/cobra_functions/pdf_integrators_2d.py:177: SyntaxWarning: "is" with a literal. Did you mean "=="?
if direction is 'x':
/afs/cern.ch/work/g/giadarol/sim_workspace_mpi_py3/PyHEADTAIL/PyHEADTAIL/cobra_functions/pdf_integrators_2d.py:179: SyntaxWarning: "is" with a literal. Did you mean "=="?