EPICS-synApps / support

APS BCDA synApps module: support
http://epics-synapps.github.io/support/
Other
3 stars 12 forks source link

xdrlib dropped from Py3.13 #34

Open prjemian opened 3 months ago

prjemian commented 3 months ago

One of the breaking changes with Python 3.13 is dropping xdrlib from the Standard Python Library, per PEP 594.

prjemian commented 3 months ago

At least this file is affected: https://github.com/EPICS-synApps/support/blob/5774e8accd88c687d569e1c301014c0780a0620c/utils/mdaExplorer/mda.py#L17-L22

prjemian commented 3 months ago

Pay attention to commit https://github.com/EPICS-synApps/support/commit/f49b4b9ab7844b24060d3b3163d59eb76a3c5c7e. Its commit messages states:

Don't use f_xdrlib. It doesn't work for large numbers of data points.

@timmmooney : Do you know what it takes to fix f_xdrlib.py?

prjemian commented 3 months ago

https://docs.python.org/3/library/xdrlib.html

prjemian commented 3 months ago

Alternative is xdrlib3

A forked version of xdrlib, a module for encoding and decoding XDR (External Data Representation) data in Python. xdrlib is planned to be removed in Python 3.13 and later versions, therefore this fork has been created to add type hints and maintain compatibility with future versions of Python.

prjemian commented 3 months ago

Conda and PyPI package alternatives for xdrlib:

There may be others. But only one in conda-forge.

(test) prjemian@arf:~/.../BCDA-APS/mdaviz$ conda search xdrlib
Loading channels: done
No match found for: xdrlib. Search: *xdrlib*
# Name                       Version           Build  Channel             
mda-xdrlib                     0.2.0    pyhd8ed1ab_0  conda-forge