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

Feature request: Show reason for package build failing #308

Open
davidak opened this issue Feb 17, 2023 · 1 comment
Open

Feature request: Show reason for package build failing #308

davidak opened this issue Feb 17, 2023 · 1 comment
Labels
enhancement New feature or request

Comments

@davidak
Copy link

davidak commented Feb 17, 2023

To speed up reviews, it would be good to show a reason for package builds failing.

Currently it looks like this:

Result of nixpkgs-review pr 215528 run on x86_64-linux 1

3 packages failed to build:
  • blender
  • blender-hip
  • python310Packages.bpycv
1 package built:
  • alembic

I see 3 packages failed, but not why. That's why i often add the terminal output:

error: builder for '/nix/store/2ay0ynwd7639msidi0f8xjbx518l7k4m-openimagedenoise-1.4.3.drv' failed with exit code 1;
       last 10 log lines:
       > -- Found TBB version 2020.3 at /nix/store/6y5ms2chn50ksw6fbsig8jm62fimqspr-tbb-2020.3-dev
       > CMake Error at cmake/FindTBB.cmake:80 (message):
       >   Cannot find required components: ;tbb
       > Call Stack (most recent call first):
       >   cmake/FindTBB.cmake:487 (rk_tbb_error)
       >   CMakeLists.txt:73 (find_package)
       >
       > 
       > -- Configuring incomplete, errors occurred!
       > See also "/build/source/build/CMakeFiles/CMakeOutput.log".
       For full logs, run 'nix log /nix/store/2ay0ynwd7639msidi0f8xjbx518l7k4m-openimagedenoise-1.4.3.drv'.
error: builder for '/nix/store/a8bdg1wpj54fs7wafbn6n9k90gc2kxfr-embree-3.13.5.drv' failed with exit code 1;
       last 10 log lines:
       > -- Found TBB version 2020.3 at /nix/store/6y5ms2chn50ksw6fbsig8jm62fimqspr-tbb-2020.3-dev
       > CMake Error at common/cmake/FindTBB.cmake:72 (message):
       >   Cannot find required components: ;tbb
       > Call Stack (most recent call first):
       >   common/cmake/FindTBB.cmake:477 (rk_tbb_error)
       >   common/tasking/CMakeLists.txt:30 (find_package)
       >
       > 
       > -- Configuring incomplete, errors occurred!
       > See also "/build/source/build/CMakeFiles/CMakeOutput.log".
       For full logs, run 'nix log /nix/store/a8bdg1wpj54fs7wafbn6n9k90gc2kxfr-embree-3.13.5.drv'.
error: 2 dependencies of derivation '/nix/store/hqz2iip8hb7v3l9jh0b94smdbiz77pkj-blender-3.3.1.drv' failed to build
error: 2 dependencies of derivation '/nix/store/m5zrcl5hy24kbxawwx4433v5g1pb78fn-blender-3.3.1.drv' failed to build
error: 1 dependencies of derivation '/nix/store/nw0nh38h0vg6lw13ra57hrdi6ql1khs3-python3.10-bpycv-0.2.43.drv' failed to build

We could now add to every package:

3 packages failed to build:
  • blender (dependencies openimagedenoise and embree failed to build)
  • blender-hip (dependencies openimagedenoise and embree failed to build)
  • python310Packages.bpycv blender-hip (dependency openimagedenoise failed to build)
1 package built:
  • alembic

or we could go the other way around and show the dependency graph as in the error

2 packages failed to build:
    openimagedenoise-1.4.3

    ...
    -- Found TBB version 2020.3 at /nix/store/6y5ms2chn50ksw6fbsig8jm62fimqspr-tbb-2020.3-dev
    CMake Error at cmake/FindTBB.cmake:80 (message):
    Cannot find required components: ;tbb
    Call Stack (most recent call first):
    cmake/FindTBB.cmake:487 (rk_tbb_error)
    CMakeLists.txt:73 (find_package)

    -- Configuring incomplete, errors occurred!
    See also "/build/source/build/CMakeFiles/CMakeOutput.log".

    dependency of blender, blender-hip and python310Packages.bpycv

    embree-3.13.5

    ...
    -- Found TBB version 2020.3 at /nix/store/6y5ms2chn50ksw6fbsig8jm62fimqspr-tbb-2020.3-dev
    CMake Error at common/cmake/FindTBB.cmake:72 (message):
    Cannot find required components: ;tbb
    Call Stack (most recent call first):
    common/cmake/FindTBB.cmake:477 (rk_tbb_error)
    common/tasking/CMakeLists.txt:30 (find_package)

    -- Configuring incomplete, errors occurred!
    See also "/build/source/build/CMakeFiles/CMakeOutput.log".

    dependency of blender, blender-hip

or different style

2 packages failed to build:
  • openimagedenoise-1.4.3 (dependency of blender, blender-hip and python310Packages.bpycv)
  • last 10 log lines

    -- Found TBB version 2020.3 at /nix/store/6y5ms2chn50ksw6fbsig8jm62fimqspr-tbb-2020.3-dev
    CMake Error at cmake/FindTBB.cmake:80 (message):
    Cannot find required components: ;tbb
    Call Stack (most recent call first):
    cmake/FindTBB.cmake:487 (rk_tbb_error)
    CMakeLists.txt:73 (find_package)

    -- Configuring incomplete, errors occurred!
    See also "/build/source/build/CMakeFiles/CMakeOutput.log".

  • embree-3.13.5 (dependency of blender, blender-hip)
  • last 10 log lines

    -- Found TBB version 2020.3 at /nix/store/6y5ms2chn50ksw6fbsig8jm62fimqspr-tbb-2020.3-dev
    CMake Error at common/cmake/FindTBB.cmake:72 (message):
    Cannot find required components: ;tbb
    Call Stack (most recent call first):
    common/cmake/FindTBB.cmake:477 (rk_tbb_error)
    common/tasking/CMakeLists.txt:30 (find_package)

    -- Configuring incomplete, errors occurred!
    See also "/build/source/build/CMakeFiles/CMakeOutput.log".

this adds the error log to the post. 10 lines give not a lot of context, maybe it could be 15... but one might as well build it again to get the full error log

i also would like to know if the pr i'm reviewing broke a package of if it was broken before. i think hydra can answer if a package in a channel is broken

example:

2 packages failed to build:
  • openimagedenoise-1.4.3
  • last 10 log lines

    -- Found TBB version 2020.3 at /nix/store/6y5ms2chn50ksw6fbsig8jm62fimqspr-tbb-2020.3-dev
    CMake Error at cmake/FindTBB.cmake:80 (message):
    Cannot find required components: ;tbb
    Call Stack (most recent call first):
    cmake/FindTBB.cmake:487 (rk_tbb_error)
    CMakeLists.txt:73 (find_package)

    -- Configuring incomplete, errors occurred!
    See also "/build/source/build/CMakeFiles/CMakeOutput.log".

    ⚠️ package was not broken in nixos-unstable before

  • embree-3.13.5 (dependency of blender, blender-hip)
  • last 10 log lines

    -- Found TBB version 2020.3 at /nix/store/6y5ms2chn50ksw6fbsig8jm62fimqspr-tbb-2020.3-dev
    CMake Error at common/cmake/FindTBB.cmake:72 (message):
    Cannot find required components: ;tbb
    Call Stack (most recent call first):
    common/cmake/FindTBB.cmake:477 (rk_tbb_error)
    common/tasking/CMakeLists.txt:30 (find_package)

    -- Configuring incomplete, errors occurred!
    See also "/build/source/build/CMakeFiles/CMakeOutput.log".

    ℹ️ package was broken in nixos-unstable before

(check against hydra channel corresponding to PR target, master->nixos-unstable or backports)

what do you think?

@figsoda figsoda added the enhancement New feature or request label Feb 17, 2023
@SuperSandro2000
Copy link
Collaborator

Last 10 log lines are usually not enough and might cut in the middle of the error.

Matching to the dependency might not always return useful results but it should be good enough.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants