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

Adopt cfep 25 #48

Merged
merged 4 commits into from
Nov 13, 2024
Merged

Adopt cfep 25 #48

merged 4 commits into from
Nov 13, 2024

Conversation

soapy1
Copy link
Contributor

@soapy1 soapy1 commented Nov 12, 2024

ref: https://github.com/conda-forge/cfep/blob/main/cfep-25.md

This pr:

  • creates a new build for conda-store 2024.10.1
  • updates the min python version to 3.10

Checklist

  • Used a personal fork of the feedstock to propose changes
  • Bumped the build number (if the version is unchanged)
  • Reset the build number to 0 (if the version changed)
  • Re-rendered with the latest conda-smithy (Use the phrase @conda-forge-admin, please rerender in a comment in this PR for automated rerendering)
  • Ensured the license file is being packaged.

@soapy1
Copy link
Contributor Author

soapy1 commented Nov 12, 2024

@conda-forge-admin, please rerender

@conda-forge-admin
Copy link
Contributor

Hi! This is the friendly automated conda-forge-linting service.

I just wanted to let you know that I linted all conda-recipes in your PR (recipe/meta.yaml) and found it was in an excellent condition.

I do have some suggestions for making it better though...

For recipe/meta.yaml:

  • ℹ️ PyPI default URL is now pypi.org, and not pypi.io. You may want to update the default source url.
  • ℹ️ PyPI default URL is now pypi.org, and not pypi.io. You may want to update the default source url.

@soapy1 soapy1 force-pushed the bump-2024.10.1-build branch from fceec0c to 27b7170 Compare November 12, 2024 19:28
@conda-forge-admin
Copy link
Contributor

Hi! This is the friendly automated conda-forge-linting service.

I just wanted to let you know that I linted all conda-recipes in your PR (recipe/meta.yaml) and found it was in an excellent condition.

@soapy1 soapy1 marked this pull request as ready for review November 12, 2024 19:51
@jaimergp
Copy link
Member

Hm, why is this expanding the CI matrix to so many Python-specific jobs? It's still noarch:python after all 🤔 Could this be a conda-smithy bug @beckermr?

@peytondmurray
Copy link

Looks like 3.9 is still being built.

@soapy1
Copy link
Contributor Author

soapy1 commented Nov 12, 2024

oh, I think that was my fault for rewriting some git history and force pushing rapidly :O lemme trigger one more build and I think things should clear up 🤞

@soapy1 soapy1 force-pushed the bump-2024.10.1-build branch 2 times, most recently from 6599025 to 317f376 Compare November 12, 2024 22:25
@soapy1
Copy link
Contributor Author

soapy1 commented Nov 12, 2024

@conda-forge-admin, please rerender

@soapy1 soapy1 force-pushed the bump-2024.10.1-build branch from 66d4c29 to 85efadb Compare November 12, 2024 22:46
@soapy1
Copy link
Contributor Author

soapy1 commented Nov 12, 2024

@conda-forge-admin, please rerender

@soapy1
Copy link
Contributor Author

soapy1 commented Nov 12, 2024

ok so, I think this might be a bug with conda-smithy. When I test out re-rendering locally after modifying the recipe to not be a split package things work as expected. For example,

just build one of the packages (not as a split package)

{% set name = "conda-store" %}
{% set version = "2024.10.1" %}

package:
  name: {{ name|lower }}-split
  version: {{ version }}

source:
  - url: https://pypi.org/packages/source/c/conda-store/conda_store-{{ version }}.tar.gz
    sha256: 2b2c5039776d299f14af48739701def9bfc3764f67f1b7335ae9f9d88cc52fc0
    folder: conda-store
  - url: https://pypi.org/packages/source/c/conda-store-server/conda_store_server-{{ version }}.tar.gz
    sha256: 61451e3893e8a109d7015dbedc4748691f59c11357f92ab2face5c0e66eef760
    folder: conda-store-server

build:
  number: 1
  noarch: python
  script: python -m pip install ./conda-store-server -vv --no-deps --no-build-isolation --no-index
  entry_points:
      - conda-store-server = conda_store_server._internal.server.__main__:main
      - conda-store-worker = conda_store_server._internal.worker.__main__:main
  requirements:
    host:
      - python {{ python_min }}
      - pip
      - hatchling >=1.14.0
      - hatch-vcs
    run:
      - alembic
      - celery
      - conda
      - conda-docker  # [linux]
      - __linux  # [linux]
      - __osx    # [osx]
      - __win    # [win]
      - conda-pack
      - conda-lock
      - constructor
      - fastapi
      - filelock
      - itsdangerous
      - jinja2
      - minio
      - pydantic <2.0a0
      - pyjwt
      - python >={{ python_min }}
      - python-docker
      - python-multipart
      - pyyaml
      - redis-py
      - requests
      - sqlalchemy <2.0a0
      - traitlets
      - uvicorn
      - yarl
      - psycopg2
      - pymysql
    run_constrained:
      - {{ pin_subpackage('conda-store', min_pin='x.x.x', max_pin='x.x.x') }}

  test:
    imports:
      - conda_store_server
    commands:
      - conda-store-server --help
      - conda-store-worker --help

about:
  home: https://github.com/conda-incubator/conda-store
  license: BSD-3-Clause
  license_family: BSD
  license_file: LICENSE
  summary: Conda Environment Management, Builds, and Serve
  description: |
    End users think in terms of environments not packages. The core
    philosophy of conda-store is to serve identical conda environments
    in as many ways as possible. Conda Store controls the environment
    lifecycle: management, builds, and serving of environments.
  doc_url: https://conda.store/
  dev_url: https://github.com/conda-incubator/conda-store

extra:
  feedstock-name: conda-store
  recipe-maintainers:
    - peytondmurray
    - soapy1
    - trallard
    - jaimergp

run the rerender

$ conda-smithy rerender
. . .
INFO:conda_smithy.configure_feedstock:You can commit the changes with:

    git commit -m "MNT: Re-rendered with conda-build 24.9.0, conda-smithy 3.44.3, and conda-forge-pinning 2024.11.12.14.24.54"

the generated .ci_support/linux_64.yaml looks correct

cdt_name:
- conda
channel_sources:
- conda-forge
channel_targets:
- conda-forge main
docker_image:
- quay.io/condaforge/linux-anvil-cos7-x86_64
pin_run_as_build:
  python:
    min_pin: x.x
    max_pin: x.x
python:
- 3.12.* *_cpython
python_min:
- '3.10'

@beckermr
Copy link
Member

Try using jinja2 to set python_min to 3.10 instead of the conda build config.

@beckermr
Copy link
Member

I think the issue is that on the first pass, conda build does not use the python_min variable in the conda build config. I think the next version of conda build will have this fixed due to a PR I sent. However, in the mean time jinja2 should fix it.

@soapy1
Copy link
Contributor Author

soapy1 commented Nov 13, 2024

Ah I see, gotcha! Thanks for taking a look 👀

@soapy1
Copy link
Contributor Author

soapy1 commented Nov 13, 2024

@conda-forge-admin, please rerender

@beckermr
Copy link
Member

Hrmmm that didn't work. I'll take a closer look tomorrow.

@beckermr
Copy link
Member

@conda-forge-admin rerender

@conda-forge-admin
Copy link
Contributor

Hi! This is the friendly automated conda-forge-webservice.

I tried to rerender for you, but it looks like there was nothing to do.

This message was generated by GitHub actions workflow run https://github.com/conda-forge/conda-forge-webservices/actions/runs/11809133888.

@beckermr
Copy link
Member

beckermr commented Nov 13, 2024

So as far as I can tell, this regex for finding variants is wrong:

https://github.com/conda/conda-build/blob/main/conda_build/variants.py#L752

For python, it renders to \{\s*(?:pin_[a-z]+\(\s*?['\"])?python[^'\"]*?\}\}. This matches both {{ python }} and {{ python_min }} when it should only match {{ python }}.

It also does not match {{ pin_compatbile('python') }} which again is quite odd to me. If one did not want to match any pinning statements, why include the optional pin_ part of the regex in the first place?

@beckermr
Copy link
Member

This PR appears to have broken matches to pin_compatible statements: conda/conda-build#2838

@beckermr
Copy link
Member

This PR appears to fix things: conda/conda-build#5535

…dev3+g6789a15a, and conda-forge-pinning 2024.11.12.14.24.54
@soapy1
Copy link
Contributor Author

soapy1 commented Nov 13, 2024

wow @beckermr thanks for looking into this!

Copy link
Member

@trallard trallard left a comment

Choose a reason for hiding this comment

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

Thank you a bunch @soapy1 and @beckermr ✨ will approve and merge right away 🚀

@trallard trallard merged commit 2c597dd into conda-forge:main Nov 13, 2024
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants