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

mise run build fails running npm #2592

Open
NigelThorne opened this issue Sep 18, 2024 · 0 comments
Open

mise run build fails running npm #2592

NigelThorne opened this issue Sep 18, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@NigelThorne
Copy link

Describe the bug
[ERROR] failed to execute command: sh -c npm run build:watch

To Reproduce
mise.toml

[tasks.build]
description = 'watch'
run = "npm run build:watch"
dir = "functions"
alias = 'b' # `mise run b`

run mise run build fails

Expected behavior
it should behave the same way running the command directly behaves.
Running npm run build:watch from the command line works fine.

mise doctor output

$ mise doctor
version: 2024.6.2 linux-x64 (87957bc 2024-06-07)
activated: yes
shims_on_path: no

build_info:
  Target: x86_64-unknown-linux-gnu
  Features: DEFAULT, NATIVE_TLS, OPENSSL
  Built: Fri, 7 Jun 2024 02:14:47 +0000
  Rust Version: rustc 1.78.0 (9b00956e5 2024-04-29)
  Profile: release

shell:
  /bin/bash
  GNU bash, version 5.1.16(1)-release (x86_64-pc-linux-gnu)
  Copyright (C) 2020 Free Software Foundation, Inc.
  License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>

  This is free software; you are free to change and redistribute it.
  There is NO WARRANTY, to the extent permitted by law.

dirs:
  data: ~/.local/share/mise
  config: ~/.config/mise
  cache: ~/.cache/mise
  state: ~/.local/state/mise
  shims: ~/.local/share/mise/shims

config_files:
  ~/.tool-versions
  ~/.config/mise/config.toml
  ~/code/mise.toml
  ~/code/loveheart/being-core/.tool-versions
  ~/code/loveheart/being-core/.mise.toml
  ~/code/loveheart/being-core/functions/.mise.toml

backends:
  cargo
  core
  go
  npm
  pipx
  spm
  ubi

plugins:
  bun       (core)
  cmake     https://github.com/asdf-community/asdf-cmake.git#d631481
  dart      https://github.com/PatOConnor43/asdf-dart.git#d14ad3b
  deno      (core)
  dotnet    https://github.com/hensou/asdf-dotnet#0e60dd2
  elixir    https://github.com/mise-plugins/mise-elixir.git#7b06439
  erlang    (core)
  firebase  https://github.com/jthegedus/asdf-firebase.git#0fcfd62
  flutter   https://github.com/oae/asdf-flutter.git#d7ae5ad
  fzf       https://github.com/kompiro/asdf-fzf.git#d19eb67
  gcloud    https://github.com/jthegedus/asdf-gcloud.git#00cdf06
  go        (core)
  helm      https://github.com/Antiarchitect/asdf-helm.git#f4b7f38
  java      (core)
  jq        https://github.com/mise-plugins/asdf-jq.git#6d86d19
  ninja     https://github.com/asdf-community/asdf-ninja.git#267f56b
  node      (core)
  pulumi    https://github.com/canha/asdf-pulumi.git#99d675b
  python    (core)
  ruby      (core)
  rust      https://github.com/code-lever/asdf-rust.git#95acf4f
  zig       https://github.com/cheetah/asdf-zig.git#4c6cb6f

toolset:
  node@18.20.4
  npm@10.8.1      (missing)
  zig@0.12.0
  dotnet@8.0.401
  ninja@1.12.1
  jq@1.7.1
  fzf@0.52.1
  rust@1.74.1

env_vars:
  MISE_SHELL=bash

settings:
  activate_aggressive = false
  all_compile = false
  always_keep_download = false
  always_keep_install = false
  asdf_compat = false
  cargo_binstall = true
  color = true
  disable_default_shorthands = false
  disable_tools = []
  experimental = true
  go_default_packages_file = "~/.default-go-packages"
  go_download_mirror = "https://dl.google.com/go"
  go_repo = "https://github.com/golang/go"
  go_set_gopath = false
  go_set_goroot = true
  go_skip_checksum = false
  http_timeout = 30
  jobs = 4
  legacy_version_file = true
  legacy_version_file_disable_tools = []
  node_compile = false
  not_found_auto_install = true
  paranoid = false
  plugin_autoupdate_last_check_duration = "7d"
  python_default_packages_file = "/home/nigel/.default-python-packages"
  python_pyenv_repo = "https://github.com/pyenv/pyenv.git"
  raw = false
  trusted_config_paths = []
  quiet = false
  verbose = false
  yes = false
  ci = false
  debug = false
  trace = false
  log_level = "info"
  python_venv_auto_create = false

  [status]
  missing_tools = "if_other_versions_installed"
  show_env = false
  show_tools = false

1 warning found:

1. plugin zig overrides a core plugin

1 problem found:

1. new mise version 2024.9.5 available, currently on 2024.6.2

Additional context
Add any other context about the problem here. Consider running mise with --debug or --trace for extra debug info.

$ mise run build --verbose --trace
[DEBUG] (1) mise::cli: [src/cli/mod.rs:217] ARGS: /home/nigel/.local/bin/mise run build --verbose --trace
[TRACE] (1) mise::config: [src/config/mod.rs:69] Settings: Settings {
    activate_aggressive: false,
    all_compile: false,
    always_keep_download: false,
    always_keep_install: false,
    asdf_compat: false,
    cargo_binstall: true,
    color: true,
    disable_default_shorthands: false,
    disable_tools: {},
    experimental: true,
    go_default_packages_file: "~/.default-go-packages",
    go_download_mirror: "https://dl.google.com/go",
    go_repo: "https://github.com/golang/go",
    go_set_gobin: None,
    go_set_gopath: false,
    go_set_goroot: true,
    go_skip_checksum: false,
    http_timeout: 30,
    jobs: 4,
    legacy_version_file: true,
    legacy_version_file_disable_tools: {},
    node_compile: false,
    not_found_auto_install: true,
    paranoid: false,
    plugin_autoupdate_last_check_duration: "7d",
    python_compile: None,
    python_default_packages_file: Some(
        "/home/nigel/.default-python-packages",
    ),
    python_patch_url: None,
    python_patches_directory: None,
    python_precompiled_arch: None,
    python_precompiled_os: None,
    python_pyenv_repo: "https://github.com/pyenv/pyenv.git",
    raw: false,
    shorthands_file: None,
    status: SettingsStatus {
        missing_tools: IfOtherVersionsInstalled,
        show_env: false,
        show_tools: false,
    },
    task_output: None,
    trusted_config_paths: {},
    quiet: false,
    verbose: true,
    yes: false,
    ci: false,
    cd: None,
    debug: true,
    env_file: None,
    trace: true,
    log_level: "trace",
    python_venv_auto_create: false,
}
[TRACE] (2) mise::file: [src/file.rs:129] cat ~/.local/share/mise/installs/bun/.mise.backend.json
[TRACE] (6) mise::file: [src/file.rs:129] cat ~/.local/share/mise/installs/ninja/.mise.backend.json
[TRACE] (5) mise::file: [src/file.rs:129] cat ~/.local/share/mise/installs/gcloud/.mise.backend.json
[TRACE] (8) mise::file: [src/file.rs:129] cat ~/.local/share/mise/installs/jq/.mise.backend.json
[TRACE] (3) mise::file: [src/file.rs:129] cat ~/.local/share/mise/installs/fzf/.mise.backend.json
[TRACE] (2) mise::file: [src/file.rs:129] cat ~/.local/share/mise/installs/cmake/.mise.backend.json
[TRACE] (6) mise::file: [src/file.rs:129] cat ~/.local/share/mise/installs/pulumi/.mise.backend.json
[TRACE] (8) mise::file: [src/file.rs:129] cat ~/.local/share/mise/installs/elixir/.mise.backend.json
[TRACE] (4) mise::file: [src/file.rs:129] cat ~/.local/share/mise/installs/helm/.mise.backend.json
[TRACE] (3) mise::file: [src/file.rs:129] cat ~/.local/share/mise/installs/python/.mise.backend.json
[TRACE] (8) mise::file: [src/file.rs:129] cat ~/.local/share/mise/installs/deno/.mise.backend.json
[TRACE] (5) mise::file: [src/file.rs:129] cat ~/.local/share/mise/installs/rust/.mise.backend.json
[TRACE] (4) mise::file: [src/file.rs:129] cat ~/.local/share/mise/installs/ruby/.mise.backend.json
[TRACE] (2) mise::file: [src/file.rs:129] cat ~/.local/share/mise/installs/dotnet/.mise.backend.json
[TRACE] (7) mise::file: [src/file.rs:129] cat ~/.local/share/mise/installs/zig/.mise.backend.json
[TRACE] (5) mise::file: [src/file.rs:129] cat ~/.local/share/mise/installs/erlang/.mise.backend.json
[TRACE] (6) mise::file: [src/file.rs:129] cat ~/.local/share/mise/installs/dart/.mise.backend.json
[TRACE] (9) mise::file: [src/file.rs:129] cat ~/.local/share/mise/installs/flutter/.mise.backend.json
[TRACE] (3) mise::file: [src/file.rs:129] cat ~/.local/share/mise/installs/firebase/.mise.backend.json
[TRACE] (8) mise::file: [src/file.rs:129] cat ~/.local/share/mise/installs/node/.mise.backend.json
[TRACE] (3) mise::cache: [src/cache.rs:87] reading ~/.cache/mise/elixir/legacy_filenames-6991a.msgpack.z
[TRACE] (2) mise::config::config_file::mise_toml: [src/config/config_file/mise_toml.rs:86] parsing: ~/code/loveheart/being-core/functions/.mise.toml
[TRACE] (3) mise::config::config_file::mise_toml: [src/config/config_file/mise_toml.rs:86] parsing: ~/code/loveheart/being-core/.mise.toml
[TRACE] (3) mise::file: [src/file.rs:129] cat ~/code/loveheart/being-core/.mise.toml
[TRACE] (4) mise::config::config_file::mise_toml: [src/config/config_file/mise_toml.rs:86] parsing: ~/.config/mise/config.toml
[TRACE] (4) mise::file: [src/file.rs:129] cat ~/.config/mise/config.toml
[TRACE] (8) mise::config::config_file::tool_versions: [src/config/config_file/tool_versions.rs:52] parsing tool-versions: /home/nigel/.tool-versions
[TRACE] (8) mise::file: [src/file.rs:129] cat ~/.tool-versions
[TRACE] (2) mise::file: [src/file.rs:129] cat ~/code/loveheart/being-core/functions/.mise.toml
[TRACE] (5) mise::config::config_file::mise_toml: [src/config/config_file/mise_toml.rs:86] parsing: ~/code/mise.toml
[TRACE] (5) mise::file: [src/file.rs:129] cat ~/code/mise.toml
[TRACE] (6) mise::config::config_file::tool_versions: [src/config/config_file/tool_versions.rs:52] parsing tool-versions: /home/nigel/code/loveheart/being-core/.tool-versions
[TRACE] (2) mise::file: [src/file.rs:129] cat ~/code/loveheart/being-core/functions/.mise.toml
[TRACE] (6) mise::file: [src/file.rs:129] cat ~/code/loveheart/being-core/.tool-versions
[TRACE] (4) mise::file: [src/file.rs:129] cat ~/.config/mise/config.toml
[TRACE] (5) mise::file: [src/file.rs:129] cat ~/code/mise.toml
[TRACE] (2) mise::config::config_file::mise_toml: [src/config/config_file/mise_toml.rs:96] [env]
GOOGLE_APPLICATION_CREDENTIALS = "../../loveheart-773aa-c442597506ff.json"

[tools]
node = "18"
npm = "10.8.1"

[TRACE] (3) mise::file: [src/file.rs:129] cat ~/code/loveheart/being-core/.mise.toml
[TRACE] (5) mise::config::config_file::mise_toml: [src/config/config_file/mise_toml.rs:96] [tools]
zig = "latest"
dotnet = "latest"
ninja = "latest"

[TRACE] (4) mise::config::config_file::mise_toml: [src/config/config_file/mise_toml.rs:96] [tools]
jq = "1.7.1"
fzf = "0.52.1"

[settings]
experimental = true

[TRACE] (8) mise::config::config_file::tool_versions: [src/config/config_file/tool_versions.rs:74] ToolVersions(~/.tool-versions): rust@1.74.1
[TRACE] (3) mise::config::config_file::mise_toml: [src/config/config_file/mise_toml.rs:96] [tasks.build]
description = 'watch'
run = "npm run build:watch"
dir = "functions"
alias = 'b' # `mise run b`

[tasks.enumator_functions]
description = 'run enumator functions'
run = "firebase emulators:start --only functions"
dir = "functions"
alias = 'ef' # `mise run f`

[tasks.fix]
description = 'run biome fix'
run = "npm run biome:fix"
alias = 'bf' # `mise run f`

[TRACE] (6) mise::config::config_file::tool_versions: [src/config/config_file/tool_versions.rs:74] ToolVersions(~/code/loveheart/being-core/.tool-versions): node@18, npm@10.8.1
[DEBUG] (1) mise::config: [src/config/mod.rs:92] Config {
    Config Files: [
        "~/code/loveheart/being-core/functions/.mise.toml",
        "~/code/loveheart/being-core/.mise.toml",
        "~/code/loveheart/being-core/.tool-versions",
        "~/code/mise.toml",
        "~/.config/mise/config.toml",
        "~/.tool-versions",
    ],
}
[TRACE] (1) mise::config: [src/config/mod.rs:237] loading task [fix] npm run biome:fix from ~/code/loveheart/being-core/.mise.toml
[TRACE] (1) mise::config: [src/config/mod.rs:237] loading task [enumator_functions] firebase emulators:start --only functions from ~/code/loveheart/being-core/.mise.toml
[TRACE] (1) mise::config: [src/config/mod.rs:237] loading task [build] npm run build:watch from ~/code/loveheart/being-core/.mise.toml
[DEBUG] (1) mise::toolset::builder: [src/toolset/builder.rs:48] Toolset (1.387611ms): node@18, npm@10.8.1, zig@latest, dotnet@latest, ninja@latest, jq@1.7.1, fzf@0.52.1, rust@1.74.1
[TRACE] (5) mise::cache: [src/cache.rs:87] reading ~/.cache/mise/rust/1.74.1/exec_env-6991a.msgpack.z
[TRACE] (3) mise::cache: [src/cache.rs:87] reading ~/.cache/mise/ninja/1.12.1/list_bin_paths-6991a.msgpack.z
[TRACE] (5) mise::cache: [src/cache.rs:87] reading ~/.cache/mise/fzf/0.52.1/list_bin_paths-6991a.msgpack.z
[TRACE] (9) mise::cache: [src/cache.rs:87] reading ~/.cache/mise/dotnet/8.0.401/list_bin_paths-6991a.msgpack.z
[TRACE] (4) mise::cache: [src/cache.rs:87] reading ~/.cache/mise/zig/0.12.0/list_bin_paths-6991a.msgpack.z
[TRACE] (2) mise::cache: [src/cache.rs:87] reading ~/.cache/mise/jq/1.7.1/list_bin_paths-6991a.msgpack.z
[TRACE] (7) mise::cache: [src/cache.rs:87] reading ~/.cache/mise/rust/1.74.1/list_bin_paths-6991a.msgpack.z
[TRACE] (11) mise::cli::run: [src/cli/run.rs:194] running tasks: [build] npm run build:watch
[TRACE] (11) mise::cli::run: [src/cli/run.rs:455] last_modified of : None
[TRACE] (11) mise::cli::run: [src/cli/run.rs:455] last_modified of : None
[TRACE] (11) mise::cli::run: [src/cli/run.rs:430] sources: None, outputs: None
[INFO] (11) mise::cli::run: [src/cli/run.rs:278] [build] $ npm run build:watch
[DEBUG] (11) mise::cmd: [src/cmd.rs:233] $ sh -c npm run build:watch
[ERROR] (11) mise::cli::run: [src/cli/run.rs:356] failed to execute command: sh -c npm run build:watch
@NigelThorne NigelThorne added the bug Something isn't working label Sep 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant