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

Show warning when running binary directly and not from NPM module #1573

Closed
bahmutov opened this issue Apr 12, 2018 · 4 comments · Fixed by #4701
Closed

Show warning when running binary directly and not from NPM module #1573

bahmutov opened this issue Apr 12, 2018 · 4 comments · Fixed by #4701
Assignees
Labels
cli pkg/server This is due to an issue in the packages/server directory type: user experience Improvements needed for UX

Comments

@bahmutov
Copy link
Contributor

New feature

Cypress binary should not be executed directly - instead the user should run NPM module which collects all arguments and then calls the binary.

We can pass an argument from NPM package to the binary, and if this argument is missing, the binary can show a warning, for example --run-from-cli.

From

#756 (comment)

@bahmutov bahmutov added cli pkg/server This is due to an issue in the packages/server directory type: user experience Improvements needed for UX labels Apr 12, 2018
@bahmutov bahmutov self-assigned this Apr 12, 2018
@jennifer-shehane
Copy link
Member

There's actually a PR open for this. Going to see if I can move it along. #1574

@cypress-bot cypress-bot bot added the stage: needs review The PR code is done & tested, needs review label Jul 12, 2019
@cypress-bot cypress-bot bot added stage: work in progress stage: ready for work The issue is reproducible and in scope stage: needs review The PR code is done & tested, needs review and removed stage: needs review The PR code is done & tested, needs review stage: work in progress stage: ready for work The issue is reproducible and in scope labels Jul 12, 2019
@jennifer-shehane
Copy link
Member

Closing the old PR in favor of #4701

@cypress-bot
Copy link
Contributor

cypress-bot bot commented Jul 29, 2019

The code for this is done in cypress-io/cypress#4701, but has yet to be released.
We'll update this issue and reference the changelog when it's released.

@cypress-bot cypress-bot bot added stage: pending release and removed stage: needs review The PR code is done & tested, needs review labels Jul 29, 2019
brian-mann added a commit that referenced this issue Jul 29, 2019
* commit previous changes made by @bahmutov for #1573

* Pass '--run-from-cli' flag through ping test in order to prevent warning from printing

* woops, require 'argsUntil'

* 'headed' was changed to 'interactiveMode'

* fix duplicate misspelled require

* tighten up args utils and cleanup decaf garbage

* cleanup errors.log to take a cb and conditionally be async

* remove extraneous --run-from-cli argument, consolidate to use --cli

- update tests

* fixes tests, ensure that record.createRun() always returns a promise

* refactor tests to handle new errors.logException interface

* make logException always return a promise, cleanup interface, add test

* fix linting errors


Co-authored-by: Brian Mann <brian.mann86@gmail.com>
@cypress-bot
Copy link
Contributor

cypress-bot bot commented Oct 23, 2019

Released in 3.5.0.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
cli pkg/server This is due to an issue in the packages/server directory type: user experience Improvements needed for UX
Projects
None yet
2 participants