Skip to content

Commit

Permalink
chore(deps): bump nix flakes (#9271)
Browse files Browse the repository at this point in the history
  • Loading branch information
cpcloud authored May 31, 2024
1 parent 6cffd5c commit 4c0ba2c
Show file tree
Hide file tree
Showing 13 changed files with 31 additions and 85 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/check-generated-files.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ jobs:
cache-dependency-path: requirements-dev.txt

- name: install poetry
run: pip install 'poetry==1.8.2'
run: pip install 'poetry==1.8.3'

- name: update apt-get
run: sudo apt-get update -y -q
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/ibis-backends-cloud.yml
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ jobs:
python-version: ${{ matrix.python-version }}

- name: install poetry
run: pip install 'poetry==1.8.2'
run: pip install 'poetry==1.8.3'

- name: install additional deps
if: matrix.backend.key == 'snowpark'
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/ibis-backends.yml
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ jobs:
python-version: ${{ matrix.python-version }}

- name: install poetry
run: pip install 'poetry==1.8.2'
run: pip install 'poetry==1.8.3'

- name: install ibis
run: poetry install --without dev --without docs --extras bigquery
Expand Down Expand Up @@ -457,7 +457,7 @@ jobs:
python-version: ${{ matrix.python-version }}

- name: install poetry
run: pip install 'poetry==1.8.2'
run: pip install 'poetry==1.8.3'

- name: install ibis
run: poetry install --without dev --without docs --extras "${{ join(matrix.backend.extras, ' ') }}"
Expand Down Expand Up @@ -621,7 +621,7 @@ jobs:
python-version: ${{ matrix.python-version }}

- name: install poetry
run: python -m pip install --upgrade pip 'poetry==1.8.2'
run: python -m pip install --upgrade pip 'poetry==1.8.3'

- name: remove incompatible deps
# it requires a version of pandas that min versions are not compatible with
Expand Down Expand Up @@ -709,7 +709,7 @@ jobs:
python-version: ${{ matrix.python-version }}

- name: install poetry
run: python -m pip install --upgrade pip 'poetry==1.8.2'
run: python -m pip install --upgrade pip 'poetry==1.8.3'

- name: remove lonboard
# it requires a version of pandas that pyspark is not compatible with
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/ibis-benchmarks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ jobs:
python-version: "3.11"

- name: install poetry
run: pip install 'poetry==1.8.2'
run: pip install 'poetry==1.8.3'

- name: install system dependencies
run: sudo apt-get install -qq -y build-essential libgeos-dev freetds-dev unixodbc-dev
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/ibis-main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ jobs:
python-version: ${{ matrix.python-version }}

- name: install poetry
run: pip install 'poetry==1.8.2'
run: pip install 'poetry==1.8.3'

- name: install ${{ matrix.os }} system dependencies
if: matrix.os == 'ubuntu-latest'
Expand Down Expand Up @@ -111,7 +111,7 @@ jobs:
python-version: "3.12"

- name: install poetry
run: pip install 'poetry==1.8.2'
run: pip install 'poetry==1.8.3'

- name: install system dependencies
run: |
Expand Down Expand Up @@ -150,7 +150,7 @@ jobs:
python-version: "3.12"

- name: install poetry
run: pip install 'poetry==1.8.2'
run: pip install 'poetry==1.8.3'

- name: install ibis with all extras
run: poetry install --without dev --without docs --all-extras
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/pre-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ jobs:
run: python -m pip install --upgrade pip

- name: install poetry
run: python -m pip install 'poetry==1.8.2' poetry-dynamic-versioning
run: python -m pip install 'poetry==1.8.3' poetry-dynamic-versioning

- name: compute ibis version
id: get_version
Expand Down
2 changes: 1 addition & 1 deletion docs/contribute/01_environment.qmd
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ For a better development experience see the `conda/mamba` or `nix` setup instruc
1. Install development dependencies

```sh
pip install 'poetry==1.8.2'
pip install 'poetry==1.8.3'
pip install -r requirements-dev.txt
```

Expand Down
18 changes: 9 additions & 9 deletions flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 4 additions & 3 deletions flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -125,20 +125,21 @@
in
rec {
packages = {
inherit (pkgs) ibis39 ibis310 ibis311 ibis312;
inherit (pkgs) ibis310 ibis311 ibis312;

default = pkgs.ibis312;

inherit (pkgs) update-lock-files gen-examples check-release-notes-spelling;
};

devShells = rec {
ibis39 = mkDevShell pkgs.ibisDevEnv39;
ibis310 = mkDevShell pkgs.ibisDevEnv310;
ibis311 = mkDevShell pkgs.ibisDevEnv311;
ibis312 = mkDevShell pkgs.ibisDevEnv312;

default = ibis312;
# move back to 3.12 when dask-expr is supported or the dask backend is
# removed
default = ibis310;

preCommit = pkgs.mkShell {
name = "preCommit";
Expand Down
2 changes: 1 addition & 1 deletion justfile
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ lock:
#!/usr/bin/env bash
set -euo pipefail
required_version="1.8.2"
required_version="1.8.3"
version="$(poetry --version)"
if ! grep -qF "${required_version}" <<< "${version}"; then
>&2 echo "poetry version must be ${required_version}, got ${version}"
Expand Down
9 changes: 4 additions & 5 deletions nix/ibis.nix
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,8 @@
, ibisTestingData
}:
let
backends = [ "dask" "datafusion" "duckdb" "pandas" "polars" "sqlite" ];
backends = [ "datafusion" "duckdb" "pandas" "polars" "sqlite" ]
++ lib.optionals (python3.pythonOlder "3.11") [ "dask" ];
markers = lib.concatStringsSep " or " (backends ++ [ "core" ]);
in
poetry2nix.mkPoetryApplication rec {
Expand All @@ -16,7 +17,7 @@ poetry2nix.mkPoetryApplication rec {
checkGroups = [ "test" ];
projectDir = gitignoreSource ../.;
src = gitignoreSource ../.;
extras = backends ++ [ "decompiler" ];
extras = backends ++ [ "decompiler" "visualization" ];
overrides = [
(import ../poetry-overrides.nix)
poetry2nix.defaultPoetryOverrides
Expand All @@ -26,9 +27,7 @@ poetry2nix.mkPoetryApplication rec {

POETRY_DYNAMIC_VERSIONING_BYPASS = "1";

buildInputs = [ graphviz-nox sqlite ];
checkInputs = buildInputs;
nativeCheckInputs = checkInputs;
nativeCheckInputs = [ graphviz-nox sqlite ];

preCheck = ''
set -euo pipefail
Expand Down
2 changes: 0 additions & 2 deletions nix/overlay.nix
Original file line number Diff line number Diff line change
Expand Up @@ -25,12 +25,10 @@ in
sha256 = "sha256-l5d7r/6Voy6N2pXq3IivLX3N0tNfKKwsbZXRexzc8Z8=";
};

ibis39 = pkgs.callPackage ./ibis.nix { python3 = pkgs.python39; };
ibis310 = pkgs.callPackage ./ibis.nix { python3 = pkgs.python310; };
ibis311 = pkgs.callPackage ./ibis.nix { python3 = pkgs.python311; };
ibis312 = pkgs.callPackage ./ibis.nix { python3 = pkgs.python312; };

ibisDevEnv39 = mkPoetryDevEnv pkgs.python39;
ibisDevEnv310 = mkPoetryDevEnv pkgs.python310;
ibisDevEnv311 = mkPoetryDevEnv pkgs.python311;
ibisDevEnv312 = mkPoetryDevEnv pkgs.python312;
Expand Down
54 changes: 1 addition & 53 deletions poetry-overrides.nix
Original file line number Diff line number Diff line change
@@ -1,53 +1 @@
self: super: {
# patch oscrypto for openssl 3 support: the fix is to relax some regexes that
# inspect the libcrypto version
#
# without these patches applied, snowflake doesn't work in the nix environment
#
# these overrides can be removed when oscrypto is released again (1.3.0 was
# released on 2022-03-17)
oscrypto = (super.oscrypto.override { preferWheel = false; }).overridePythonAttrs (attrs: {
patches = attrs.patches or [ ] ++ [
(self.pkgs.fetchpatch {
url = "https://github.com/wbond/oscrypto/commit/ebbc944485b278192b60080ea1f495e287efb4f8.patch";
sha256 = "sha256-c1faM8szkn/7AjDthzmDisytzO8UdrzDtPkuuITjkRQ=";
})
(self.pkgs.fetchpatch {
url = "https://github.com/wbond/oscrypto/commit/d5f3437ed24257895ae1edd9e503cfb352e635a8.patch";
sha256 = "sha256-sRwxD99EV8mmiOAjM8emews9gvDeFtpBV3sSLiNEziM=";
})
];
});

pyodbc = super.pyodbc.overridePythonAttrs (attrs: {
preFixup = attrs.preFixup or "" + ''
addAutoPatchelfSearchPath ${self.pkgs.unixODBC}
'';
});

avro-python3 = super.avro-python3.overridePythonAttrs (attrs: {
nativeBuildInputs = attrs.nativeBuildInputs or [ ] ++ [
self.pycodestyle
self.isort
];
});

apache-flink-libraries = super.apache-flink-libraries.overridePythonAttrs (attrs: {
buildInputs = attrs.nativeBuildInputs or [ ] ++ [ self.setuptools ];
# apache-flink and apache-flink-libraries both install version.py into the
# pyflink output derivation, which is invalid: whichever gets installed
# last will be used
postInstall = ''
rm $out/${self.python.sitePackages}/pyflink/version.py
rm $out/${self.python.sitePackages}/pyflink/__pycache__/version.*.pyc
'';
});

thrift = super.thrift.overridePythonAttrs (attrs: {
# ignore silly bytecode-compilation-on-install for Pythons >= 3.12
postPatch = (attrs.postPatch or "") +
self.pkgs.lib.optionalString (self.pkgs.lib.versionAtLeast self.python.version "3.12") ''
substituteInPlace setup.cfg --replace 'optimize = 1' 'optimize = 0'
'';
});
}
_final: _prev: { }

0 comments on commit 4c0ba2c

Please sign in to comment.