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

Be less aggressive with error messages when plugins cause errors #1025

Closed
Graham42 opened this issue Dec 6, 2017 · 4 comments
Closed

Be less aggressive with error messages when plugins cause errors #1025

Graham42 opened this issue Dec 6, 2017 · 4 comments
Labels
good first issue Good for newcomers pkg/driver This is due to an issue in the packages/driver directory type: user experience Improvements needed for UX
Milestone

Comments

@Graham42
Copy link
Contributor

Graham42 commented Dec 6, 2017

In this bug: cypress-io/cypress-watch-preprocessor#1

The wording of the error message that the user experiences has a fairly aggressive tone. Specifically this line:

This error originated from *your* test code, not from Cypress.

The error message could be better phrased to something like "This is an error from your test code."

When building developer tools it's very important to keep DX (developer experience) in mind.

@brian-mann
Copy link
Member

We derive most of our errors messages out the the feedback we get and the questions we get from real users.

These error messages just went in 1.1.3 and they originated from many situations where users thought that Cypress was throwing the error (assuming there was a bug in it). Other users were also confused whether the error was coming from test code or application code.

We updated these errors to clearly call out the point of origin, and a suggestion that the user must take action to fix it. Here's the issue that documents these errors:

#825

If you search in our issues or search gitter you will find that users regularly were confused without this specific wording. They'd have to inspect a stack trace, and even before doing that, they might not recognize the error and have no idea where it's coming from or why. Many times they would ask: "Is there a bug in Cypress?" We wanted to make it super clear that this is something on their end, and this error is happening as part of the test framework as opposed to a software error in Cypress itself.

I'll keep this issue open if anyone else has an opinion. You can find the errors and rewrite them and submit a PR if you'd like.

@jennifer-shehane jennifer-shehane added good first issue Good for newcomers pkg/driver This is due to an issue in the packages/driver directory type: user experience Improvements needed for UX labels Dec 7, 2017
@jennifer-shehane
Copy link
Member

jennifer-shehane commented Dec 7, 2017

I think they are just suggesting changing a couple words in the error. 🙃

I agree, the use of the phrase 'an error from' is much clearer than 'error originated from'.

Code where these messages can be found:

There are several tests and snapshots that will require updating when changing this message.

@jennifer-shehane jennifer-shehane added the stage: ready for work The issue is reproducible and in scope label Dec 7, 2017
@Graham42
Copy link
Contributor Author

Graham42 commented Dec 7, 2017

That reasoning makes sense. I've submitted a PR for a minimal change which I think tweaks the tone of this error message. Let me know what you think.

#1038

@brian-mann brian-mann added this to the 1.2.0 milestone Dec 12, 2017
@brian-mann
Copy link
Member

Released in 1.2.0.

@jennifer-shehane jennifer-shehane removed the stage: ready for work The issue is reproducible and in scope label Dec 15, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers pkg/driver This is due to an issue in the packages/driver directory type: user experience Improvements needed for UX
Projects
None yet
Development

No branches or pull requests

3 participants