gdcc / dvwebloader

A web tool for uploading folders of files to a Dataverse dataset
Apache License 2.0
1 stars 8 forks source link

tell users to renew their API tokens #14

Open donsizemore opened 1 year ago

donsizemore commented 1 year ago

Just tried dv-webloader on a 5.13 test system. Visually the screen hangs, telling me: Getting Dataset Information...

Javascript console sez 401 Unauthorized

Payara log sez attempted access with expired token

It would be user-friendly to percolate this last error back to the browser.

luddaniel commented 1 year ago

This issue has been fixed with https://github.com/IQSS/dataverse/pull/9096/commits/85fc67d0ee870b938108347109a3719bb550d000 with getWebloaderUrlForDataset(Dataset d) asking for getValidApiTokenForUser(AuthenticatedUser user) that handles both cases : having no key and an expired key.

Tested on Dataverse 5.14

pdurbin commented 1 year ago

@luddaniel interesting. Thanks.

That commit is part of #9096 which made it into Dataverse 5.13 so I'm not sure why @donsizemore saw this bug, since he was testing 5.13.

@donsizemore maybe when you get a chance, you can re-test?