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

--continue flag is not exiting with highest exit code #454

Closed
djamaile opened this issue Dec 28, 2021 · 6 comments
Closed

--continue flag is not exiting with highest exit code #454

djamaile opened this issue Dec 28, 2021 · 6 comments
Labels
kind: bug Something isn't working owned-by: turborepo

Comments

@djamaile
Copy link

What version of Turborepo are you using?

4.4.4

What package manager are you using / does the bug impact?

Yarn v1

What operating system are you using?

Mac

Describe the Bug

Running a command in multiple packages doesn't return an exit code 1 if it encounters an error. For example, running a prettier command in package A will return an error but the exit code of the turbo command will still be 0.

yarn prettier:all --continue                                                           2216ms
yarn run v1.22.11
$ turbo run prettier:check --continue
• Packages in scope: plugin-gitlab, app, backend
• Running prettier:check in 3 packages
app:prettier:check: cache miss, executing 65e27beb04dafa0c
plugin-gitlab:prettier:check: cache miss, executing 3da4dd7e648440c0
backend:prettier:check: cache miss, executing e6932aacbc126b5b
app:prettier:check: $ prettier --check .
backend:prettier:check: $ prettier --check .
plugin-gitlab:prettier:check: $ prettier --check .
app:prettier:check: Checking formatting...
plugin-gitlab:prettier:check: Checking formatting...
backend:prettier:check: Checking formatting...
...
plugin-gitlab:prettier:check: error Command failed with exit code 1.
plugin-gitlab:prettier:check: command finished with error, but continuing...
app:prettier:check: error Command failed with exit code 1.
app:prettier:check: command finished with error, but continuing...
backend:prettier:check: error Command failed with exit code 1.
backend:prettier:check: command finished with error, but continuing...

 Tasks:    0 successful, 3 total
Cached:    0 cached, 3 total
  Time:    1.85s

✨  Done in 2.13s.
echo $status  
0

Expected Behavior

turbo command with --continue flag exists with 1 or higher eventually, if it encounters an error

To Reproduce

I guess have a prettier command setup in your repo and produce an error in package A and not one in package B.

@jaredpalmer jaredpalmer added confirmed kind: bug Something isn't working and removed confirmed labels Jan 3, 2022
@djamaile
Copy link
Author

djamaile commented Jan 4, 2022

hi @jaredpalmer do you might know where the problem is? is it something I can contribute to

LeSuisse added a commit to Enalean/tuleap that referenced this issue Jan 12, 2022
…ebase

The turborepo has a bug and it does not exit with the highest exit code
it encounters when --continue is used [0].

[0] vercel/turbo#454

Part of request #24241: Cache the build results of the JS toolchain

Change-Id: I7bf2c7cd2f5cf1a8056cb40bf0d9c09349379fd3
@davidtheclark
Copy link

davidtheclark commented Feb 9, 2022

I can confirm that I'm seeing the same problem, with unit tests. I'm on turborepo version 1.0.24.

This is a significant problem because it means we can't see all the failures on CI, only the first failures that occur.

@GlennyDC
Copy link

Present in turborepo version 1.1.2 as well.

@bkiac
Copy link

bkiac commented Mar 7, 2022

Fixed for me in 1.1.5

sokra pushed a commit that referenced this issue Oct 25, 2022
This:

* adds a test that ensures that we apply app transforms to packages symlinked under node_modules, such as in a yarn-workspaces-style monorepo.
* automatically normalizes the root path when constructing `DiskFileSystemVc`s, which previously accepted any string, even relative paths, such as from the snapshot test runner. This became an issue as the logic in #406 assumes that it begins with `/` (cc @Brooooooklyn).


To do:
  * [x] Add snapshot test covering transforming monorepo dependencies
  * [x] Implement transforming monorepo dependencies

Test Plan: Added snapshot test
@hirvinen
Copy link

Present for me in 1.8.5.

@anthonyshew
Copy link
Contributor

Hey, folks! Figuring this is a stale. Please open a new issue if you're still seeing this behavior.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind: bug Something isn't working owned-by: turborepo
Projects
None yet
Development

No branches or pull requests

8 participants