Skip to content

Multi-Instrument-Plot: Add offline mode support - #187

Merged
jgieseler merged 1 commit into
soler-he:mainfrom
jgieseler:main
Sep 29, 2026
Merged

jgieseler merged 1 commit into
soler-he:mainfrom
jgieseler:main

Conversation

@jgieseler

Copy link
Copy Markdown
Member

This pull request adds improved offline support and more robust error handling for network connectivity issues across the multi-instrument plotting package, covering #170. The main changes introduce an offline option to control data downloading behavior, propagate this flag through data loading functions, and handle network-related exceptions more gracefully to provide clearer error messages when data cannot be fetched due to connectivity problems.

Offline Mode Support:

  • Added an offline attribute to the Options class in multi_inst_plots/__init__.py, enabling users to specify whether the application should attempt to download data or work offline.
  • Updated all major data loading functions (load_data in l1_tools.py, psp_tools.py, solo_tools.py, stereo_tools.py) to propagate the offline flag and pass it to underlying data loader functions, ensuring consistent offline behavior throughout the codebase. [1] [2] [3] [4]
  • Modified calls to instrument-specific loader functions (e.g., wind3dp_load, soho_load, epd_load, psp_isois_load, stereo_load) to accept and use the offline argument, preventing data downloads when offline mode is enabled. [1] [2] [3] [4] [5] [6] [7] [8] [9] [10] [11] [12] [13]

Network Error Handling:

  • Improved exception handling for network-related errors:
    • Added handling for URLError in Wind WAVES CDF downloads to catch and report failures due to network issues. [1] [2]
    • Added handling for requests.ConnectionError and ConnectionError in STIX and GOES/XRS loaders, providing user-friendly messages when data cannot be fetched due to lack of internet connectivity. [1] [2] [3]

These changes make the package more robust for users working in environments with limited or no internet access and provide clearer feedback when data cannot be retrieved due to network issues.

@jgieseler jgieseler added the enhancement New feature or request label Sep 29, 2026
@jgieseler
jgieseler merged commit a426254 into soler-he:main Sep 29, 2026
26 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant