ejeschke / ginga

The Ginga astronomical FITS file viewer
BSD 3-Clause "New" or "Revised" License
120 stars 77 forks source link

No module named dateutil #1086

Closed pllim closed 5 months ago

pllim commented 5 months ago

This is the first time in a long time I install Ginga on a fresh environment. Now I use Python 3.12. When I try to test #1084 , I ran into a different problem:

ginga\ginga\rv\plugins\Drawing.py", line 36, in <module>
    from dateutil import tz
ModuleNotFoundError: No module named 'dateutil'

https://github.com/ejeschke/ginga/blob/8eb5aafcb208cbbae410d161d63d21b37cd5abb2/ginga/rv/plugins/Drawing.py#L36

Is dateutil an undeclared dependency? It didn't get installed automatically when I installed Ginga.

ejeschke commented 5 months ago

I thought that dateutil was part of the standard library, but I guess that it is not. I've fixed this in commit bc2606d702bf55e8c3e8a1af3edfca14430642e0.

ejeschke commented 5 months ago

dateutil was added to deal with a deprecation of a couple of API calls in recent versions (python 3.12?) of datetime.

ejeschke commented 5 months ago

@pllim, can you confirm in your python 3.12 envt and close this if fixed? Tnx!

pllim commented 5 months ago

Yes, Ginga now pulls in the extra dependency and error is gone. Thanks!