marcelofinamorvieira / datocms-plugin-automatic-environment-backups

A DatoCMS plugin to automatically backup your main environment every day and week.
0 stars 0 forks source link

Unable to Complete Plugin Installation on DatoCMS #1

Open duy-the-developer opened 7 months ago

duy-the-developer commented 7 months ago

Hi Marcello,

I'm trying to setup the plugin for one of my project and went through all the steps provided in this repo's README as well as the instructions provided on DatoCMS marketplace. However, at the last and final step, upon pasting the deployed URL of the instance, I received the following error message Please insert a valid URL:

image

Please advise on how I could go about troubleshooting this, and if there is any information you need, please let me know. Thanks in advance 🙏 -Duy

arcataroger commented 7 months ago

@marcelofinamorvieira I did some basic troubleshooting here: https://community.datocms.com/t/help-installing-automatic-environment-backups-plugin/4633/2?u=roger

It looks to me like that serverless func just crashes if it gets a 400 from Dato (i.e. if we don't provide a valid access token). Then if it crashes, the plugin installation try-catch will fail it and show the invalid URL message, even though the URL is fine and it's a network failure: https://github.com/marcelofinamorvieira/datocms-plugin-automatic-environment-backups/blob/master/src/entrypoints/InstallationModal.tsx#L28-L39

The textfield doesn't differentiate between a URL error and a network error (the function crashing): https://github.com/marcelofinamorvieira/datocms-plugin-automatic-environment-backups/blob/master/src/entrypoints/InstallationModal.tsx#L98

arcataroger commented 7 months ago

(But apparently that's not the issue that was affecting the reporter... they provided more detail on the forum: https://community.datocms.com/t/help-installing-automatic-environment-backups-plugin/4633/3?u=roger)