'SpectralGWCS' object has no attribute 'to_fits'
- Dominant language
- Python
- Stars
- 204
- Forks
- 134
- Avg merge
- 12h 55m
- Merged PRs (30d)
- 1
Description
Loading an SDSS spectrum with the 'SDSS-I/II spSpec' format loader and then writing to fits using format "wcs1d-fits" writer raises error:
ValueError: Only Spectrum1D objects with valid WCS can be written as wcs1d: 'SpectralGWCS' object has no attribute 'to_fits'
Please see attached fits file and minimum example script.
We include in the script the output of running the script and environment info.
[SpectralGWCSBug.tar.gz](https://github.com/astropy/specutils/files/5594130/SpectralGWCSBug.tar.gz)
Contributor guide
Research direction
Start with the attached SpectralGWCSBug.tar.gz, including its minimum example, output, and environment information. Reproduce loading the SDSS-I/II spSpec file and writing it with the wcs1d-fits format, then trace why SpectralGWCS lacks to_fits where the writer validates WCS support. Done means the example writes successfully without the reported ValueError.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- data
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100