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

Start building and publishing conda nightlies #986

Merged
merged 6 commits into from
Mar 25, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
72 changes: 72 additions & 0 deletions .github/workflows/conda.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,72 @@
name: Conda build
on:
push:
branches:
- main
tags:
- "*"
pull_request:
paths:
- setup.py
- ci/recipe/**
- .github/workflows/conda.yml
- pyproject.toml

# When this workflow is queued, automatically cancel any previous running
# or pending jobs from the same branch
concurrency:
group: conda-${{ github.ref }}
cancel-in-progress: true

# Required shell entrypoint to have properly activated conda environments
defaults:
run:
shell: bash -l {0}

jobs:
conda:
name: Build (and upload)
runs-on: ubuntu-latest
steps:
- uses: actions/[email protected]
with:
fetch-depth: 0
- name: Set up Python
uses: conda-incubator/[email protected]
with:
miniforge-variant: Mambaforge
use-mamba: true
python-version: 3.9
channel-priority: strict
- name: Install dependencies
run: |
mamba install -c conda-forge boa conda-verify

which python
pip list
mamba list
- name: Build conda packages
run: |
# suffix for pre-release package versions
export VERSION_SUFFIX=a`date +%y%m%d`

# conda search for the latest dask-core pre-release
arr=($(conda search --override-channels -c dask/label/dev dask-core | tail -n 1))

# extract dask-core pre-release version / build
export DASK_CORE_VERSION=${arr[1]}

# distributed pre-release build
conda mambabuild ci/recipe \
--channel dask/label/dev \
--no-anaconda-upload \
--output-folder .
- name: Upload conda packages
if: github.event_name == 'push' && github.repository == 'dask/dask-expr'
env:
ANACONDA_API_TOKEN: ${{ secrets.DASK_CONDA_TOKEN }}
run: |
# install anaconda for upload
mamba install -c conda-forge anaconda-client

anaconda upload --label dev noarch/*.tar.bz2
50 changes: 50 additions & 0 deletions ci/recipe/meta.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
{% set major_minor_patch = environ.get('GIT_DESCRIBE_TAG', '0.0.0.dev').lstrip('v').split('.') %}
{% set new_patch = major_minor_patch[2] | int + 1 %}
{% set version = (major_minor_patch[:2] + [new_patch]) | join('.') + environ.get('VERSION_SUFFIX', '') %}
{% set dask_version = environ.get('DASK_CORE_VERSION', '0.0.0.dev') %}


package:
name: dask-expr
version: {{ version }}

source:
git_url: ../..

build:
number: {{ GIT_DESCRIBE_NUMBER }}
noarch: python
string: py_{{ GIT_DESCRIBE_HASH }}_{{ GIT_DESCRIBE_NUMBER }}
script: {{ PYTHON }} -m pip install . -vv

requirements:
host:
- python >=3.9
- pip
- dask-core {{ dask_version }}
- versioneer =0.28
- tomli
run:
- python >=3.9
- {{ pin_compatible('dask-core', max_pin='x.x.x.x') }}
- pyarrow
- pandas >=2

test:
imports:
- dask_expr
requires:
- pip
commands:
- pip check

about:
home: https://github.com/dask/dask-expr
summary: 'High Level Expressions for Dask'
description: |
High Level Expressions for Dask
license: BSD-3-Clause
license_family: BSD
license_file: LICENSE.txt
doc_url: https://github.com/dask/dask-expr/blob/main/README.md
dev_url: https://github.com/dask/dask-expr
Loading