@@ -182,44 +182,8 @@ PypeIt, upgrading the package should simply be a matter of executing:
182182
183183 If this causes problems (*e.g. *, a new PypeIt script is unavailable or you
184184encounter script errors), first try uninstalling (``pip uninstall pypeit ``) and
185- then reinstalling. There are two important things to keep in mind when
186- upgrading:
187-
188- - **PypeIt datamodels are not necessarily backwards-compatible. ** This means
189- that, *e.g. *, ``pypeit_show_2dspec `` may fault when trying to view
190- ``spec2d* `` files produced with your existing PypeIt version after upgrading
191- to a new version. **The best approach is to always re-reduce data you're
192- still working with anytime you update PypeIt. **
193-
194- - **Cached files are version-specific. ** Every time you upgrade pypeit, we
195- recommend deleting your existing cache and starting fresh! See
196- :ref: `view-cache `. The only caveat to this is if you are actively using
197- multiple versions of PypeIt, meaning you will still be using old versions of
198- the cached files. Otherwise, you will end up with multiple versions of the
199- same file on disk. **Importantly **, the code also considers local files you
200- have installed (using, e.g., ``pypeit_install_linelist ``) to be version
201- specific. If you have installed such files, you will need to re-install them
202- *after * upgrading.
203-
204- If you have locally installed files, your upgrade may look something like this:
205-
206- .. code-block :: console
207-
208- # Check the cache contents
209- pypeit_clean_cache -l
210- # Delete everything
211- pypeit_clean_cache --clear
212- # Upgrade pypeit
213- pip install pypeit --upgrade
214- # Reinstall your local line lists
215- pypeit_install_linelist /path/to/my/linelists/*_lines.dat
216-
217- .. note ::
218-
219- If you find particular data files useful for your reductions, please
220- consider issuing a PR to include them file in the PypeIt repository. This
221- helps the community, and it means you'll avoid these upgrading
222- complications.
185+ then reinstalling. Also note that not all PypeIt versions are
186+ backwards-compatible; see :ref: `versioning `.
223187
224188.. _m1_macs :
225189
@@ -236,7 +200,7 @@ installation options are welcome; please `Submit an issue`_.
236200Installation on Windows
237201-----------------------
238202
239- Generally speaking, we encounter most installation issues on Windows users.
203+ Generally speaking, we encounter most installation issues for Windows users.
240204
241205An alternative for running under Windows is to install the `Windows Subsystem
242206for Linux (WSL) <https://learn.microsoft.com/en-us/windows/wsl/install> `_. This
@@ -267,6 +231,69 @@ options for the ``python.exe`` and ``python3.exe`` executables.
267231
268232----
269233
234+ .. _versioning :
235+
236+ Versioning
237+ ==========
238+
239+ Traditionally, we provided no guarantee that *any * PypeIt version was backwards
240+ compatible. However, as of version 2.0.0, PypeIt uses `Semantic Versioning
241+ <https://packaging.python.org/en/latest/discussions/versioning/> `__. This
242+ approach uses three version categories --- *major *, *minor *, and *patch * ---
243+ where releases that increment the *major * version number are *not * backwards
244+ compatible. We expect the most common reason for incrementing the *major *
245+ version number will be because of a backwards-incompatible change to either the
246+ input configuration files (like the ``*.pypeit `` file) or the data models of the
247+ primary output products.
248+
249+ .. important ::
250+
251+ When possible, we **always ** recommend you use the most recent version of
252+ PypeIt and reprocess data as necessary. The code is always improving, not
253+ just in functionality but also in robustness of data reduction and
254+ processing.
255+
256+ Beyond this, we emphasize two important considerations regarding PypeIt versioning:
257+
258+ - **Backwards-incompatible changes to datamodels can break simple viewing
259+ scripts. ** For example, ``pypeit_show_2dspec `` may fault when trying to view
260+ ``spec2d* `` files produced using a version of PypeIt that is not backwards
261+ compatible with your current version. You can always maintain multiple python
262+ environments with different PypeIt versions installed or reprocess data with
263+ your currently installed PypeIt version.
264+
265+ - **Cached files are version-specific. ** Every time you upgrade PypeIt, we
266+ recommend deleting your existing cache and starting fresh! See
267+ :ref: `view-cache `. The only caveat to this is if you are actively using
268+ multiple versions of PypeIt (in different environments), meaning you will
269+ still be using old versions of the cached files. Otherwise, you will end up
270+ with multiple versions of the same file on disk. **Importantly **, the code
271+ also considers local files you have installed (using, e.g.,
272+ ``pypeit_install_linelist ``) to be version specific. If you have installed
273+ such files, you will need to re-install them *after * upgrading.
274+
275+ If you have locally installed files, your upgrade may look something like
276+ this:
277+
278+ .. code-block :: console
279+
280+ # Check the cache contents
281+ pypeit_clean_cache -l
282+ # Delete everything
283+ pypeit_clean_cache --clear
284+ # Upgrade pypeit
285+ pip install pypeit --upgrade
286+ # Reinstall your local line lists
287+ pypeit_install_linelist /path/to/my/linelists/*_lines.dat
288+
289+ .. note ::
290+
291+ If you find particular data files useful for your reductions, please
292+ consider issuing a PR to include them in the PypeIt repository. This helps
293+ the community, and it means you'll avoid these upgrading complications.
294+
295+ ----
296+
270297.. _data_installation :
271298
272299Additional Data and the PypeIt Cache
@@ -322,7 +349,7 @@ cache. To list the cache contents, use the ``-l`` option:
322349 github 1.15.1 tests solution_arrays.npz
323350
324351 Note that the files hosted on GitHub will be specific to a branch or version of
325- PypeIt. **Every time you upgrade pypeit , we recommend deleting your existing
352+ PypeIt. **Every time you upgrade PypeIt , we recommend deleting your existing
326353cache and starting fresh! **
327354
328355**Local files ** that have been installed into the cache (e.g., using
@@ -428,7 +455,7 @@ can be included in the PypeIt repository.
428455
429456 Because PypeIt uses the cache system to manage the local files, it will
430457 associate each file with the version of the code used to install it in the
431- cache. Every time you upgrade your pypeit version, you should delete the
458+ cache. Every time you upgrade your PypeIt version, you should delete the
432459 local files from the cache (this will not remove the local file itself) and
433460 re-install them using the upgraded version of PypeIt. See :ref: `view-cache `
434461 and :ref: `upgrade `.
@@ -510,7 +537,7 @@ Python (see :ref:`dependencies`):
510537* `PySide <https://wiki.qt.io/Qt_for_Python >`_
511538
512539At least one of those bindings must be installed for the interactive GUIs to
513- work. By default `` pypeit `` will install ``pyqt6 ``. Other backends can be used
540+ work. By default PypeIt will install ``pyqt6 ``. Other backends can be used
514541by installing them manually via ``pip `` or ``conda `` and then setting the ``QT_API ``
515542environment variable. See the `QtPy documentation <https://github.com/spyder-ide/qtpy >`_
516543for more details.
@@ -603,7 +630,7 @@ spectrum from the Shane/KAST spectrograph at Lick Observatory.
603630Troubleshooting
604631===============
605632
606- If you have trouble installing pypeit , you're encouraged to join our `PypeIt
633+ If you have trouble installing PypeIt , you're encouraged to join our `PypeIt
607634Users Slack <https://pypeit-users.slack.com> `__ using `this invitation
608635link <invite_> `_ and post your issue to the ``#installing `` channel. Below is an
609636incomplete list of issues that users have reported in the past. In addition to
@@ -612,7 +639,7 @@ let us know if these suggestions do not work for you.*
612639
613640----
614641
615- **I am trying to install pypeit for the first time and it fails! **: The root
642+ **I am trying to install PypeIt for the first time and it fails! **: The root
616643problem of this can be system dependent:
617644
618645 - First, *always * make sure you install the code into a fresh environment.
@@ -629,23 +656,23 @@ problem of this can be system dependent:
629656
630657----
631658
632- **I am trying to upgrade pypeit and it fails! **: First try uninstalling your
633- current pypeit version:
659+ **I am trying to upgrade PypeIt and it fails! **: First try uninstalling your
660+ current PypeIt version:
634661
635662.. code-block :: bash
636663
637664 pip uninstall pypeit
638665
639666 Then reinstall it. If that also fails, try creating a fresh environment and
640- reinstalling pypeit in that new environment.
667+ reinstalling PypeIt in that new environment.
641668
642669----
643670
644671**The installation process succeeded, but the code is faulting! **: This could
645672be for a few reasons:
646673
647- - Recall that pypeit isn't necessarily backwards compatible. If you've
648- upgraded pypeit and tried to use it with data that was reduced by a previous
674+ - Recall that PypeIt isn't necessarily backwards compatible. If you've
675+ upgraded PypeIt and tried to use it with data that was reduced by a previous
649676 version, the fault may because of changes between versions. You will either
650677 need to revert to your previous version or reprocess the data.
651678
@@ -680,6 +707,6 @@ Slack. However, here are a few things to note and/or try:
680707 - And, of course, the code will have bugs. If you find one, the more
681708 information you provide the developers, the easier it will be for us to track
682709 down the issue. Valuable information includes your OS, OS version, python
683- version, pypeit version, and the full Traceback provided with the error. QA
710+ version, PypeIt version, and the full Traceback provided with the error. QA
684711 plots and ``ginga `` screen grabs that illustrate the issue are also very
685712 helpful!
0 commit comments