sintaxi / surge

CLI for the surge.sh CDN
https://surge.sh
2.87k stars 136 forks source link

Should provide better error when trying to publish to a domain you don’t own #141

Open kennethormandy opened 8 years ago

kennethormandy commented 8 years ago

Talking with Mike about the notifications when you try and publish to a domain you don’t own. Really confusing right now if your team member published before you did, the error message doesn’t give you any indication that you just aren’t one of the collaborators.

Potentially this is good for security, being vague, but all someone needs to do is visit the site to know it’s a real project. At least giving a link to a help page that describes what the problem might be would be an improvement on the existing error.

kevnoutsawo commented 2 years ago

Hi, has there been any progress about that? I was about to open a similar issue but this explains it well. It looks like the surge CLI is still very unintuitive. For instance, the following message should point out why you don't have the said permission. "Aborted - you do not have permission to publish to random-subdomain.surge.sh" Some users had the message because they had not confirmed their email (which should be prompted at account creation), others because the subdomain was already taken. They all get the same message and have to guess. Also, the automatic random subdomains should be checked automatically at generation to avoid collisions. I don't know if it is appropriate to open separate issues for all this.

sintaxi commented 2 years ago

@kevnoutsawo, as far as I'm aware this error message is only shown if you don't have publishing rights for the domain. It is not ever shown in the event your email isn't confirmed. If you see this message I suggest running surge whoami to be sure you are logged in as the account you think you are. Also check your inbox for past "welcome to surge" emails.

kevnoutsawo commented 2 years ago

@sintaxi Yes, it makes sense. I have confirmed my email before realizing it was not the issue. When someone doesn't have publishing rights for a domain, shouldn't it let them know why? Also, the automatic suggestions regularly are already taken and it shouldn't be the case in my opinion. I have used Heroku and mainly use Netlify these days. The random subdomains they propose are always available. I think Surge should perform at least that check before suggesting a subdomain to users. When I understood that the subdomain was actually the issue, I tried many names before finding an available one and that is very frustrating. When it finally worked, it was very fast and smooth though. Surge is powerful but the user experience needs serious improvements, there shouldn't be so much guesswork involved considering that the platform is not new. I also saw people online asking for a web-based dashboard. Are there plans to create one or if it exists, how to access it? I hope this doesn't sound like empty criticism, it's just my two cents regarding how we can make surge more enjoyable for every user. Thanks a lot for your time.