Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add NcML previewers (HDF5 and NetCDF) to demo and Harvard Dataverse #213

Closed
pdurbin opened this issue Feb 15, 2023 · 4 comments
Closed

add NcML previewers (HDF5 and NetCDF) to demo and Harvard Dataverse #213

pdurbin opened this issue Feb 15, 2023 · 4 comments
Labels
Feature: External Tool pm.netcdf-hdf5.d NIH ODSS supplement (NetCDF) Size: 3 A percentage of a sprint.

Comments

@pdurbin
Copy link
Member

pdurbin commented Feb 15, 2023

I just uploaded and HDF5 file to https://demo.dataverse.org/dataset.xhtml?persistentId=doi:10.70122/FK2/JTUS2J and the NcML file was correctly extracted...

Screen Shot 2023-02-15 at 10 16 02 AM

... but the eyeball is absent because the NcML previewer hasn't yet been added. Can we please add it to the demo site? I can also open a separate issue for Harvard Dataverse or we can just use this one.

Please note that there are actually two previewers because there are two MIME types in play. The following is copied from https://github.com/gdcc/dataverse-previewers/blob/d8193b1083d0b84443303fc345d8d6d5e12d9f04/5.2curlcommands.md#ncml-previewer-requirements

curl -X POST -H 'Content-type: application/json' http://localhost:8080/api/admin/externalTools -d \
'{
  "displayName":"Show NcML (XML)",
  "description":"Metadata from HDF5 files.",
  "toolName":"ncmlPreviewer",
  "scope":"file",
  "types":["preview"],
  "toolUrl":"https://gdcc.github.io/dataverse-previewers/previewers/betatest/NcmlPreview.html",
  "toolParameters": {
      "queryParameters":[
        {"fileid":"{fileId}"},
        {"siteUrl":"{siteUrl}"},
        {"key":"{apiToken}"},
        {"datasetid":"{datasetId}"},
        {"datasetversion":"{datasetVersion}"},
        {"locale":"{localeCode}"}
      ]
    },
  "requirements": {
    "auxFilesExist": [
      {
        "formatTag": "NcML",
        "formatVersion": "0.1"
      }
    ]
  },
  "contentType":"application/x-hdf5"
}'

Thanks!

@pdurbin pdurbin moved this to NIH NetCDF (Phil) in IQSS Dataverse Project Feb 15, 2023
@pdurbin pdurbin added Feature: External Tool Size: 3 A percentage of a sprint. labels Feb 15, 2023
@landreev
Copy link
Collaborator

BTW, this has been done - but I'll wait for somebody to check on it and confirm that it's all working they way it should be.

@landreev landreev self-assigned this Feb 23, 2023
@pdurbin
Copy link
Member Author

pdurbin commented Feb 27, 2023

https://demo.dataverse.org/file.xhtml?persistentId=doi:10.70122/FK2/JTUS2J/K68IDV&version=1.0 is looking good! Screenshot below.

Screen Shot 2023-02-27 at 4 37 39 PM

https://dataverse.harvard.edu/file.xhtml?fileId=6938801&datasetVersionId=340765 is also looking good. Screenshot below.

Screen Shot 2023-02-27 at 4 41 38 PM

Those are both HDF5. I couldn't find any NetCDF files so I uploaded one to https://demo.dataverse.org/file.xhtml?persistentId=doi:10.70122/FK2/UEMPZA/YFBGVG&version=1.0 and it looks good after publishing...

Screen Shot 2023-02-27 at 4 45 40 PM

... but before publishing I got a weird error about my API key. Not sure what's going on. I created another dataset on demo so I can see it:

"Unable to retrieve NcML file. Please try again. The most common issue is that your login has timed out. If the problem persists, please contact the support team of this data repository. Please include any status code included at the end of this message: Forbidden"

A screenshot for context:

Screen Shot 2023-02-27 at 4 48 13 PM

I get the same error for an HDF5 file when it's in draft:

Screen Shot 2023-02-27 at 4 49 16 PM

Again. I'm not sure what's going on but I'll ask around. If there's code to fix we can open a new issue and close this one. It seems like the tools were added just fine. Thanks, @landreev!

@pdurbin pdurbin self-assigned this Feb 27, 2023
@landreev landreev removed their assignment Feb 27, 2023
@landreev
Copy link
Collaborator

So, ok to close this? If there is a problem with the api token, sounds like it should be a simple fix on the tool side.

@pdurbin
Copy link
Member Author

pdurbin commented Feb 28, 2023

Yep, closing. I opened an issue to fix it:

@pdurbin pdurbin closed this as completed Feb 28, 2023
@pdurbin pdurbin removed their assignment Feb 28, 2023
@mreekie mreekie added the pm.netcdf-hdf5.d NIH ODSS supplement (NetCDF) label Feb 28, 2023
@mreekie mreekie moved this from NIH NetCDF (Phil) to Clear of the Backlog in IQSS Dataverse Project Mar 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature: External Tool pm.netcdf-hdf5.d NIH ODSS supplement (NetCDF) Size: 3 A percentage of a sprint.
Projects
Status: No status
Development

No branches or pull requests

3 participants