mdanalysis icon indicating copy to clipboard operation
mdanalysis copied to clipboard

Unpacking errors in x3dna

Open jbarnoud opened this issue 3 years ago • 3 comments
trafficstars

At least 2 lines in the legacy x3dna module use unpacking with too many values to unpack.

https://github.com/MDAnalysis/mdanalysis/blob/97ec6df207fa934095ffb093daadf319ca2bfb38/package/MDAnalysis/analysis/legacy/x3dna.py#L204

https://github.com/MDAnalysis/mdanalysis/blob/97ec6df207fa934095ffb093daadf319ca2bfb38/package/MDAnalysis/analysis/legacy/x3dna.py#L213-L216

In both occurrences, the left side expects 6 values, but 12 are provided on the right.

This issue was identified by mypy in #3752.

jbarnoud avatar Aug 23 '22 15:08 jbarnoud

Can we just set x3dna for removal in 3.0? Are people still using it? I'm not super sure why we even keep untested code in MDA, especially code which by all appearances seems to cost $1k to purchase?

IAlibay avatar Aug 23 '22 22:08 IAlibay

It is not only untested, it is broken and only shows up on our radar when we do some sort of full sweep of the code.

jbarnoud avatar Aug 24 '22 06:08 jbarnoud

Remove in 3.x — I can't remember why we kept it for 2.x.

orbeckst avatar Aug 29 '22 16:08 orbeckst

I am not sure if we need to go to any length to have the code spit out deprecation warnings. Given that it's in legacy anyway, I suggest to just

  • add deprecation note to CHANGELOG
  • add deprecation note to docs

orbeckst avatar Oct 02 '23 13:10 orbeckst