-
Notifications
You must be signed in to change notification settings - Fork 3
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
267 add url test to resources #306
Conversation
Visit the preview URL for this PR (updated for commit 2c97aba): https://cioos-metadata-form--pr306-267-add-url-test-to-mo9x8ly3.web.app (expires Sun, 25 Feb 2024 21:49:58 GMT) 🔥 via Firebase Hosting GitHub Action 🌎 Sign: 57eda2a7622dc877ccadb675a0532261c52b09fd |
if checkURLActive is a new firebase cloud function then you can deploy it to production now, assuming it doesn't cause an error. it will only be used by the test deployments until this pr is merged into main so will not break production. |
For some reasons, I can see the http/https check is working however, modifying the url to some wrong ones doesn't seem to trigger the second check. If I remove some letters from the url which returns a 400 the check seems to still return valid:
|
@JessyBarrette if you were testing this via the preview URL and not running the firebase emulator locally, the new As per @fostermh comment above, I have just deployed |
Oh sorry yes I can see it working now :) I'm wondering if it would be worth to bring a message to the Submit tab whenever a link isn't working. |
Looks great to me. |
We can create a new issue for that if that is going over the present issue |
@JessyBarrette I can add a message to the submit tab when a link isn't working |
Awesome thanks @sorochak Once this is done I can approve all that :) nice work |
when we discussed this I was thinking of a status pill that would show if the link was resolvable or not. something similar to this pr for doi status #283 It's ok if we prefer this interface but it would be nice to be consistent across the form |
don't flag inactive URL as error
…or when adding a resource, not sure what that is about
…oos-siooc/metadata-entry-form into 267-add-url-test-to-resources
…c/metadata-entry-form into 267-add-url-test-to-resources
@JessyBarrette @timvdstap this PR is ready (again) for review. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is all looking great to me!
I guess we could eventually color code the ERROR anr WARNING sections of the submit page. But this should be an another issue first.
Well done!
I think it would highlight the difference between the two sections within
the submit page.
*Jessy Barrette M.Sc.*
*Marine Data and Instrumentation Specialist*
Hakai Institute <https://www.hakai.org/> | CIOOS Pacific
<https://cioospacific.ca/> | CIOOS <https://cioos.ca/> |
***@***.*** | (C) (250) 208-7806
Le ven. 26 janv. 2024 à 17:13, Austen Sorochak ***@***.***> a
écrit :
… I had considered making the Error and Warning headings red?
—
Reply to this email directly, view it on GitHub
<#306 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AHICYOL7UNOUQTWJRRD2NQDYQQTBJAVCNFSM6AAAAABB6TIW4KVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTSMJSG43DINBYG4>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
I think it looks good and seems to work fine! I agree with Jessy that we could perhaps at a later stage revisit the color coding of the warning messages (i.e. even if it says "URL is not active", I think it'd be nice if this shows up in red). Something to perhaps address later :-) |
This PR solves issue: #267
validateURL
was defined in more than one place - removed a definition and imported fromvalidate.js
checkURLActive
firebase functioncheckURLActive
call inResources
component, to notify users ifURL is not active
In order to test this locally you need to run the firebase emulator. Instructions here:
metadata-entry-form/README.md
Line 20 in 1bbb633
Note:
checkURLActive
is not yet deployed to Firebase.TO DO:
checkURLActive
when PR approved.