Skip to content

catboost: tweak, fix build#370663

Merged
GaetanLepage merged 1 commit into
NixOS:masterfrom
lucasew:20250103-fix-catboost
Jan 3, 2025
Merged

catboost: tweak, fix build#370663
GaetanLepage merged 1 commit into
NixOS:masterfrom
lucasew:20250103-fix-catboost

Conversation

@lucasew

@lucasew lucasew commented Jan 3, 2025

Copy link
Copy Markdown
Contributor

This is a dependency of orange3. Merging this would fix orange3 by consequence.

  • catboost: tweak, fix build

Things done

  • Built on platform(s)
    • x86_64-linux
    • aarch64-linux
    • x86_64-darwin
    • aarch64-darwin
  • For non-Linux: Is sandboxing enabled in nix.conf? (See Nix manual)
    • sandbox = relaxed
    • sandbox = true
  • Tested, as applicable:
  • Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage
  • Tested basic functionality of all binary files (usually in ./result/bin/)
  • 25.05 Release Notes (or backporting 24.11 and 25.05 Release notes)
    • (Package updates) Added a release notes entry if the change is major or breaking
    • (Module updates) Added a release notes entry if the change is significant
    • (Module addition) Added a release notes entry if adding a new NixOS module
  • Fits CONTRIBUTING.md.

Add a 👍 reaction to pull requests you find important.

Signed-off-by: lucasew <lucas59356@gmail.com>
@lucasew lucasew requested a review from GaetanLepage January 3, 2025 16:53
@github-actions github-actions Bot added 10.rebuild-darwin: 1-10 This PR causes between 1 and 10 packages to rebuild on Darwin. 10.rebuild-linux: 1-10 This PR causes between 1 and 10 packages to rebuild on Linux. labels Jan 3, 2025
@GaetanLepage

Copy link
Copy Markdown
Contributor

nixpkgs-review result

Generated using nixpkgs-review.

Command: nixpkgs-review pr 370663


x86_64-linux

❌ 8 packages failed to build:
  • python312Packages.catboost
  • python312Packages.catboost.dist
  • python312Packages.orange3
  • python312Packages.orange3.dist
  • python313Packages.catboost
  • python313Packages.catboost.dist
  • python313Packages.orange3
  • python313Packages.orange3.dist
✅ 2 packages built:
  • catboost
  • catboost.dev

x86_64-darwin

⏩ 10 packages marked as broken and skipped:
  • catboost
  • catboost.dev
  • python312Packages.catboost
  • python312Packages.catboost.dist
  • python312Packages.orange3
  • python312Packages.orange3.dist
  • python313Packages.catboost
  • python313Packages.catboost.dist
  • python313Packages.orange3
  • python313Packages.orange3.dist

aarch64-darwin

⏩ 4 packages marked as broken and skipped:
  • python312Packages.orange3
  • python312Packages.orange3.dist
  • python313Packages.orange3
  • python313Packages.orange3.dist
❌ 4 packages failed to build:
  • python312Packages.catboost
  • python312Packages.catboost.dist
  • python313Packages.catboost
  • python313Packages.catboost.dist
✅ 2 packages built:
  • catboost
  • catboost.dev

@GaetanLepage

Copy link
Copy Markdown
Contributor

@lucasew Would you be able to fix the failures ? Please, ping me if you need the logs.

@lucasew

lucasew commented Jan 3, 2025

Copy link
Copy Markdown
Contributor Author

@lucasew Would you be able to fix the failures ? Please, ping me if you need the logs.

Working on that

@lucasew

lucasew commented Jan 3, 2025

Copy link
Copy Markdown
Contributor Author

The rabbit hole is much deeper than I expected

@lucasew

lucasew commented Jan 3, 2025

Copy link
Copy Markdown
Contributor Author
catboost> Check whether the following modules can be imported: catboost
catboost> Traceback (most recent call last):
catboost>   File "<string>", line 1, in <module>
catboost>   File "<string>", line 1, in <lambda>
catboost>   File "/nix/store/c9m6yd8fg1flz2j5r4bif1ib5j20a0cy-python3-3.12.8/lib/python3.12/importlib/__init__.py", line 90, in import_module
catboost>     return _bootstrap._gcd_import(name[level:], package, level)
catboost>            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
catboost>   File "<frozen importlib._bootstrap>", line 1387, in _gcd_import
catboost>   File "<frozen importlib._bootstrap>", line 1360, in _find_and_load
catboost>   File "<frozen importlib._bootstrap>", line 1331, in _find_and_load_unlocked
catboost>   File "<frozen importlib._bootstrap>", line 935, in _load_unlocked
catboost>   File "<frozen importlib._bootstrap_external>", line 999, in exec_module
catboost>   File "<frozen importlib._bootstrap>", line 488, in _call_with_frames_removed
catboost>   File "/nix/store/m65h8awffiai2snjag7pjilq09kz75rw-python3.12-catboost-1.2.7/lib/python3.12/site-packages/catboost/__init__.py", line 1, in <module>
catboost>     from .core import (
catboost>   File "/nix/store/m65h8awffiai2snjag7pjilq09kz75rw-python3.12-catboost-1.2.7/lib/python3.12/site-packages/catboost/core.py", line 45, in <module>
catboost>     from .plot_helpers import save_plot_file, try_plot_offline, OfflineMetricVisualizer
catboost>   File "/nix/store/m65h8awffiai2snjag7pjilq09kz75rw-python3.12-catboost-1.2.7/lib/python3.12/site-packages/catboost/plot_helpers.py", line 5, in <module>
catboost>     from . import _catboost
catboost>   File "_catboost.pyx", line 1, in init _catboost
catboost> ValueError: numpy.dtype size changed, may indicate binary incompatibility. Expected 96 from C header, got 88 from PyObject

@GaetanLepage

Copy link
Copy Markdown
Contributor
catboost> Check whether the following modules can be imported: catboost
catboost> Traceback (most recent call last):
catboost>   File "<string>", line 1, in <module>
catboost>   File "<string>", line 1, in <lambda>
catboost>   File "/nix/store/c9m6yd8fg1flz2j5r4bif1ib5j20a0cy-python3-3.12.8/lib/python3.12/importlib/__init__.py", line 90, in import_module
catboost>     return _bootstrap._gcd_import(name[level:], package, level)
catboost>            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
catboost>   File "<frozen importlib._bootstrap>", line 1387, in _gcd_import
catboost>   File "<frozen importlib._bootstrap>", line 1360, in _find_and_load
catboost>   File "<frozen importlib._bootstrap>", line 1331, in _find_and_load_unlocked
catboost>   File "<frozen importlib._bootstrap>", line 935, in _load_unlocked
catboost>   File "<frozen importlib._bootstrap_external>", line 999, in exec_module
catboost>   File "<frozen importlib._bootstrap>", line 488, in _call_with_frames_removed
catboost>   File "/nix/store/m65h8awffiai2snjag7pjilq09kz75rw-python3.12-catboost-1.2.7/lib/python3.12/site-packages/catboost/__init__.py", line 1, in <module>
catboost>     from .core import (
catboost>   File "/nix/store/m65h8awffiai2snjag7pjilq09kz75rw-python3.12-catboost-1.2.7/lib/python3.12/site-packages/catboost/core.py", line 45, in <module>
catboost>     from .plot_helpers import save_plot_file, try_plot_offline, OfflineMetricVisualizer
catboost>   File "/nix/store/m65h8awffiai2snjag7pjilq09kz75rw-python3.12-catboost-1.2.7/lib/python3.12/site-packages/catboost/plot_helpers.py", line 5, in <module>
catboost>     from . import _catboost
catboost>   File "_catboost.pyx", line 1, in init _catboost
catboost> ValueError: numpy.dtype size changed, may indicate binary incompatibility. Expected 96 from C header, got 88 from PyObject

Try to rm -rf catboost in preCheck.
This happens sometimes with python package: it will import the module from the source files instead of the installed package.

@lucasew

lucasew commented Jan 3, 2025

Copy link
Copy Markdown
Contributor Author

It didn't work

BTW catboost seems to work. I think I will deliver this first and deal with the python package in another PR.

@GaetanLepage GaetanLepage left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sure, fine by me, let's merge this !

@emilazy

emilazy commented Jan 3, 2025

Copy link
Copy Markdown
Member

FWIW this uses CUDA 11 which is scheduled for removal from 25.05. It’s probably worth trying to bump it to CUDA 12 if there’s interest in keeping it working.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

10.rebuild-darwin: 1-10 This PR causes between 1 and 10 packages to rebuild on Darwin. 10.rebuild-linux: 1-10 This PR causes between 1 and 10 packages to rebuild on Linux.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants