Skip to content

snyk: Cannot use sbom subcommand: unknown command error #451904

@muhmud

Description

@muhmud

Nixpkgs version

  • Unstable (25.11)

Describe the bug

The latest versions of snyk support the sbom subcommand. When trying to run this command using the nix package, I get the following error:

$ snyk sbom                                                                                                                                                                                                                                            <<<
Unknown command "sbom"

Run `snyk --help` for a list of available commands.

However, running snyk --help clearly shows the sbom command as being available.

Digging a bit deeper into this, it seems like the nix package is now using what is considered to be the fallback CLI, with snyk npm installs now being a wrapper over a static/dynamically linked binary. Essentially, the nix package definition needs to be updated.

Steps to reproduce

  • Use the snyk package
  • Run snyk sbom

Expected behaviour

The snyk sbom command should not fail

Screenshots

No response

Relevant log output

Additional context

No response

System metadata

this path will be fetched (0.00 MiB download, 0.00 MiB unpacked):
  /nix/store/7s9kyc4y36v0sv78sqkc1vnl7iizf20y-nix-info
copying path '/nix/store/7s9kyc4y36v0sv78sqkc1vnl7iizf20y-nix-info' from 'https://cache.nixos.org'...
 - system: `"x86_64-linux"`
 - host os: `Linux 6.16.8-1-MANJARO, Manjaro Linux, noversion, rolling`
 - multi-user?: `yes`
 - sandbox: `yes`
 - version: `nix-env (Nix) 2.31.1`
 - nixpkgs: `/nix/store/b1hmqq7kiy26q08663w45mm6wlrx1nn1-source`

Notify maintainers

@momeemt

Note for maintainers: Please tag this issue in your pull request description. (i.e. Resolves #ISSUE.)

I assert that this issue is relevant for Nixpkgs

Is this issue important to you?

Add a 👍 reaction to issues you find important.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions