Skip to content

AWS doesn’t support absolute paths #205

@griffin-h

Description

@griffin-h

Describe the bug
I cannot upload reduced data products (tags "photometry" or "spectroscopy") when using AWS. When I try, I see the message "There was a problem processing your file" on site. I added a logger to tom_dataproducts.views.DataProductUploadView.form_valid to find that the exception raised is "This backend doesn't support absolute paths." Stack Overflow suggests I can fix this by replacing fits.getdata(data_product.data.path) with fits.getdata(data_product.data.name) in the methods of tom_dataproducts.data_processor.DataProcessor, but I can't get this to work either.

To Reproduce
Steps to reproduce the behavior:

  1. Have a TOM configured to use AWS for storage
  2. Go to a target page
  3. Click on the Data tab
  4. Choose a file to upload (example)
  5. Choose the "Spectroscopy" tag
  6. Click "Upload"

Expected behavior
The data file should be uploaded and processed. A spectrum should appear in the "Spectra" tab of that target.

Desktop (please complete the following information):

  • OS: heroku-18
  • Browser: Safari
  • Version: 13.0.1
  • Python Version: 3.7.0

Additional context
When I upload a raw data product (e.g., tag "Fits File") it goes in a directory TargetName/none/filename.fits at the top level of my AWS bucket.

Metadata

Metadata

Assignees

Labels

Patch PartyCollaborative effort mostly done as part of a patch partyUserIssue Raised by a userbugSomething isn't workingmaintenanceNon-user facing updates to clean code and make developer life easier.

Type

No type

Projects

Status

Backlog

Relationships

None yet

Development

No branches or pull requests

Issue actions