sharppy / SHARPpy

Sounding/Hodograph Analysis and Research Program in Python
https://sharppy.github.io/SHARPpy/index.html
Other
220 stars 110 forks source link

[BUG] SHARPpy Unable to Display Soundings on Ubuntu 18.04 - Crash in _getOutletWithProfile #242

Open buffaloseven opened 1 year ago

buffaloseven commented 1 year ago

Before submitting an issue to Github about SHARPpy, please follow the below checklist to ensure that your issue can be resolved quickly.

The management team for SHARPpy is a small team of volunteers. Being as thorough as possible with your issue submission will help us help you!

SHARPpy is unable to display soundings, fails with the following error (output from running with the --debug flag.

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/net/wwg/home/[user]/SHARPpy/runsharp/full_gui.py", line 609, in complete_name
    self.skewApp(ntry=n_tries)
  File "/net/wwg/home/[user]/SHARPpy/runsharp/full_gui.py", line 772, in skewApp
    raise exc
  File "/net/local/home/[user]/miniconda3/envs/sharppy/lib/python3.10/site-packages/SHARPpy-1.4.0+12.ge7ffe83e.dirty-py3.10.egg/sutils/async_threads.py", line 122, in run
    ret_val = func(*args, **kwargs)
  File "/net/wwg/home/[user]/SHARPpy/runsharp/full_gui.py", line 836, in loadData
    decoder, url = data_source.getDecoderAndURL(loc, run, outlet_num=ntry)
  File "/net/local/home/[user]/miniconda3/envs/sharppy/lib/python3.10/site-packages/SHARPpy-1.4.0+12.ge7ffe83e.dirty-py3.10.egg/datasources/data_source.py", line 436, in getDecoderAndURL
    outlet = self._getOutletWithProfile(stn, cycle_dt, outlet_num=outlet_num)
  File "/net/local/home/[user]/miniconda3/envs/sharppy/lib/python3.10/site-packages/SHARPpy-1.4.0+12.ge7ffe83e.dirty-py3.10.egg/datasources/data_source.py", line 367, in _getOutletWithProfile
    raise DataSourceError()
datasources.data_source.DataSourceError

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/net/wwg/home/[user]/SHARPpy/runsharp/full_gui.py", line 137, in doCrasher
    ret = func(*args, **kwargs)
  File "/net/wwg/home/[user]/SHARPpy/runsharp/full_gui.py", line 615, in complete_name
    raise IOError(
OSError: No outlet found with the requested profile!
Exception: No outlet found with the requested profile!

Well, this is embarrassing.
SHARPpy broke. This is probably due to an issue with one of the data source servers, but if it keeps happening, send the detailed information to the developers.

Detailed Information:
SHARPpy v1.4.0+12.ge7ffe83e.dirty Andover
Crash time: 2022-11-01 14:12:12.062775
Traceback (most recent call last):
  File "/net/local/home/[user]/miniconda3/envs/sharppy/lib/python3.10/site-packages/SHARPpy-1.4.0+12.ge7ffe83e.dirty-py3.10.egg/datasources/data_source.py", line 365, in _getOutletWithProfile
    outlet = use_outlets[outlet_num]
IndexError: list index out of range

To Reproduce Steps to reproduce the behavior:

  1. Launch SHARPpy (either via sharppy or python full_gui.py
  2. Load any sounding.
  3. Generate Profiles
  4. See error

Expected behavior The profile would be correctly generated and displayed.

Versioning Information (please complete the following information):

**

Additional context Problem occurs after a fresh install of SHARPpy in a new Conda environment. Problem occurs whether installed via conda-forge or through a Git clone.

wx4stg commented 1 year ago

same issue here with Fedora 38

wx4stg commented 1 year ago

This seems to be caused by having too new of a version of pyside2. You can work around this by creating a new conda environment with pyside2 v5.12:

conda create -n sharppy
conda activate sharppy
conda install python=3.7
pip install PySide2==5.12.6
pip install git+https://github.com/sharppy/sharppy
normanr commented 6 months ago

I had a similar issue, but had to use --ignore-requires-python and install newer versions of PySide2 and shiboken2, otherwise pip wanted to install very old versions (because newer versions didn't say that they were compatible with Python 3.11) which didn't work correctly.