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

Issues with boa 0.17.0 #81

Closed
1 task done
lohedges opened this issue Mar 26, 2024 · 7 comments · Fixed by #82
Closed
1 task done

Issues with boa 0.17.0 #81

lohedges opened this issue Mar 26, 2024 · 7 comments · Fixed by #82
Labels
bug Something isn't working

Comments

@lohedges
Copy link

Solution to issue cannot be found in the documentation.

  • I checked the documentation.

Issue

As of yesterday our CI (using boa to build our pacakges) is failing because of the update to boa 0.17.0. This happens on all platforms and all python variants. There appear to be two issues:

  1. The boltons dependency is missing:
Run conda mambabuild -c conda-forge -c openbiosim/label/dev /home/runner/work/biosimspace/biosimspace/biosimspace/recipes/biosimspace
Traceback (most recent call last):
  File "/home/runner/miniconda3/envs/bss_build/bin/conda-mambabuild", line 6, in <module>
    from boa.cli.mambabuild import main
  File "/home/runner/miniconda3/envs/bss_build/lib/python3.9/site-packages/boa/cli/mambabuild.py", line 21, in <module>
    from boa.core.solver import MambaSolver
  File "/home/runner/miniconda3/envs/bss_build/lib/python3.9/site-packages/boa/core/solver.py", line 7, in <module>
    from boltons.setutils import IndexedSet
ModuleNotFoundError: No module named 'boltons'
  1. After manually installing boltons I then run into the following assertion error:
Traceback (most recent call last):
  File "/home/runner/miniconda3/envs/bss_build/bin/conda-mambabuild", line 10, in <module>
    sys.exit(main())
  File "/home/runner/miniconda3/envs/bss_build/lib/python3.9/site-packages/boa/cli/mambabuild.py", line 301, in main
    call_conda_build(action, config)
  File "/home/runner/miniconda3/envs/bss_build/lib/python3.9/site-packages/boa/cli/mambabuild.py", line 273, in call_conda_build
    result = api.build(
  File "/home/runner/miniconda3/envs/bss_build/lib/python3.9/site-packages/conda_build/api.py", line 253, in build
    return build_tree(
  File "/home/runner/miniconda3/envs/bss_build/lib/python3.9/site-packages/conda_build/build.py", line 3799, in build_tree
    packages_from_this = build(
  File "/home/runner/miniconda3/envs/bss_build/lib/python3.9/site-packages/conda_build/build.py", line 2469, in build
    output_metas = expand_outputs([(m, need_source_download, need_reparse_in_env)])
  File "/home/runner/miniconda3/envs/bss_build/lib/python3.9/site-packages/conda_build/render.py", line 923, in expand_outputs
    for output_dict, m in deepcopy(_m).get_output_metadata_set(
  File "/home/runner/miniconda3/envs/bss_build/lib/python3.9/site-packages/conda_build/metadata.py", line 2565, in get_output_metadata_set
    conda_packages = finalize_outputs_pass(
  File "/home/runner/miniconda3/envs/bss_build/lib/python3.9/site-packages/conda_build/metadata.py", line 909, in finalize_outputs_pass
    fm = finalize_metadata(
  File "/home/runner/miniconda3/envs/bss_build/lib/python3.9/site-packages/conda_build/render.py", line 637, in finalize_metadata
    build_unsat, host_unsat = add_upstream_pins(
  File "/home/runner/miniconda3/envs/bss_build/lib/python3.9/site-packages/conda_build/render.py", line 452, in add_upstream_pins
    build_deps, build_unsat, extra_run_specs_from_build = _read_upstream_pin_files(
  File "/home/runner/miniconda3/envs/bss_build/lib/python3.9/site-packages/conda_build/render.py", line 431, in _read_upstream_pin_files
    deps, actions, unsat = get_env_dependencies(
  File "/home/runner/miniconda3/envs/bss_build/lib/python3.9/site-packages/conda_build/render.py", line 151, in get_env_dependencies
    actions = environ.get_install_actions(
  File "/home/runner/miniconda3/envs/bss_build/lib/python3.9/site-packages/boa/cli/mambabuild.py", line 180, in mamba_get_install_actions
    link_precs = mamba_get_package_records(
  File "/home/runner/miniconda3/envs/bss_build/lib/python3.9/site-packages/boa/cli/mambabuild.py", line 142, in mamba_get_package_records
    _, link_precs = solver.solve_for_unlink_link_precs(_specs, prefix)
  File "/home/runner/miniconda3/envs/bss_build/lib/python3.9/site-packages/boa/core/solver.py", line 252, in solve_for_unlink_link_precs
    return to_unlink_link_precs(
  File "/home/runner/miniconda3/envs/bss_build/lib/python3.9/site-packages/boa/core/solver.py", line 87, in to_unlink_link_precs
    unlink_precs, link_precs = diff_for_unlink_link_precs(
  File "/home/runner/miniconda3/envs/bss_build/lib/python3.9/site-packages/conda/core/solve.py", line 1152, in diff_for_unlink_link_precs
    assert isinstance(final_precs, IndexedSet)
AssertionError

Downgrading to 0.16.0 fixes the issues. I've checked the release notes here and don't see any obvious changes that would break things (or relevant issue threads). I can also report upstream if desired.

Cheers.

Installed packages

N/A

Environment info

N/A
@lohedges
Copy link
Author

It seems that this PR includes the changes that are missing, i.e. adding boltons as a dependency and pining against specific versions of conda-build. In your recipe you have:

  run:
    - python >=3.7
    - conda-build >=3.25,<24.5
    - libmambapy >=1.5,<1.6
    - ruamel.yaml >=0.15.0
    - jinja2
    - rich
    - prompt_toolkit
    - json5
    - jsonschema
    - joblib
    - watchgod
    - beautifulsoup4

However, it looks like this should be:

    - python >=3.7
    - conda-build >=3.25
    - libmambapy >=1.5,<1.6
    - ruamel.yaml >=0.15.0
    - jinja2
    - rich
    - prompt_toolkit
    - json5
    - jsonschema
    - joblib
    - watchgod
    - beautifulsoup4
    - boltons

(Here I just added boltons as in the PR above and matched the conda-build pin.)

@mbargull
Copy link
Member

Missed the notification here, sorry; a new build with the dependency fix provided by @ccordoba12 in gh-82 should be available shortly.

@mbargull
Copy link
Member

    - conda-build >=3.25,<24.5

The missing boltons part was an obvious oversight, but he stricter dependency for our package here is intentional, see #80 (comment) .

@lohedges
Copy link
Author

Many thanks. Will test after the Easter break. Thanks for the clarification about the conda-build pin too.

@ccordoba12
Copy link
Contributor

A quick note to mention that with the new build we're still seeing the second error mentioned above by @lohedges in our CIs:

File "/home/runner/miniconda3/envs/bss_build/lib/python3.9/site-packages/conda/core/solve.py", line 1152, in diff_for_unlink_link_precs
    assert isinstance(final_precs, IndexedSet)
AssertionError

@mbargull
Copy link
Member

Then we may want to add conda>=23.3 as a dependency here.
Which also means, if you update to conda>=23.3, this should go away. (I assume this is a mismatch between boltons.setutils.IndexedSet and conda._vendor.boltons.setutils.IndexedSet.)

@mbargull
Copy link
Member

For cases that prevent boltons or conda>=23.3 to be installed, we're adding conda-forge/conda-forge-repodata-patches-feedstock#693 such that all boa=0.17.0 builds will carry the correct dependency definition.

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

Successfully merging a pull request may close this issue.

3 participants