Skip to content

Commit f11fe2b

Browse files
authored
Release 2.1.1
# 2.1.1 (30 Jul 2020) Fix broken wheel packages ### Fixes: - Some wheel packages could brake through patchelf if they already contained stripped binaries. Packages like numpy wouldn't work because of this. This is now fixed by passing `dontStrip` to the `autoPatchelf` routine.
2 parents da74d4b + bfa6943 commit f11fe2b

5 files changed

Lines changed: 21 additions & 16 deletions

File tree

Changelog.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
# 2.1.1 (30 Jul 2020)
2+
Fix broken wheel packages
3+
### Fixes:
4+
- Some wheel packages could brake through patchelf if they already contained stripped binaries. Packages like numpy wouldn't work because of this. This is now fixed by passing `dontStrip` to the `autoPatchelf` routine.
5+
16
# 2.1.0 (04 Jul 2020)
27
Bug fixes + new feature **buildPythonPackage** / **buildPythonApplication**
38
### Fixes:

Readme.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -55,11 +55,11 @@ Table of Contents
5555
You can either install mach-nix via pip or by using nix in case you already have the nix package manager installed.
5656
#### Installing via pip
5757
```shell
58-
pip install git+git://github.com/DavHau/mach-nix@2.1.0
58+
pip install git+git://github.com/DavHau/mach-nix@2.1.1
5959
```
6060
#### Installing via nix
6161
```shell
62-
nix-env -if https://github.com/DavHau/mach-nix/tarball/2.1.0 -A mach-nix
62+
nix-env -if https://github.com/DavHau/mach-nix/tarball/2.1.1 -A mach-nix
6363
```
6464

6565
---
@@ -91,7 +91,7 @@ You can call mach-nix directly from a nix expression
9191
let
9292
mach-nix = import (builtins.fetchGit {
9393
url = "https://github.com/DavHau/mach-nix/";
94-
ref = "2.1.0";
94+
ref = "2.1.1";
9595
});
9696
in
9797
mach-nix.mkPython {
@@ -131,7 +131,7 @@ Mach-nix can be fine tuned with additional arguments by importing it via `builti
131131
#### Configure Providers
132132
**Providers** allow you to configure the origin for your packages on a granular basis.
133133

134-
The following 3 providers are available in version 2.1.0:
134+
The following 3 providers are available since version 2.0.0:
135135
1. **nixpkgs**: Provides packages directly from nixpkgs without modifying their sources. Has only a few versions available, but has a high success rate and all the nix features, like `cudaSupport` for tensorflow for example.
136136
2. **sdist**: Provides all package versions available from pypi which support setuptools and builds them via nixpkgs overlays wherever possible to resolve external dependencies. It still supports the nixpkgs specific features no matter which package version is selected. But chances are higher for a build to fail than with the **nixpkgs** provider.
137137
3. **wheel**: Provides all linux compatible wheel releases from pypi. Wheels can contain binaries. Mach-nix autopatches them to work on nix. Wheels are super quick to install and work quite reliable. Therefore this provider is preferred by default.

examples.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ build a python environment from a list of requirements
2424
let
2525
mach-nix = import (builtins.fetchGit {
2626
url = "https://github.com/DavHau/mach-nix/";
27-
ref = "2.1.0";
27+
ref = "2.1.1";
2828
});
2929
in mach-nix.mkPython {
3030
requirements = builtins.readFile ./requirements.txt;
@@ -37,7 +37,7 @@ Build a python package from its source code and a list of requirements
3737
let
3838
mach-nix = import (builtins.fetchGit {
3939
url = "https://github.com/DavHau/mach-nix/";
40-
ref = "2.1.0";
40+
ref = "2.1.1";
4141
});
4242
in mach-nix.buildPythonPackage {
4343
pname = "my-package";
@@ -53,7 +53,7 @@ Build a python package from its source code and a list of requirements
5353
let
5454
mach-nix = import (builtins.fetchGit {
5555
url = "https://github.com/DavHau/mach-nix/";
56-
ref = "2.1.0";
56+
ref = "2.1.1";
5757
});
5858
in mach-nix.buildPythonPackage rec {
5959
pname = "projectname";
@@ -77,7 +77,7 @@ I have a complex set of requirements including tensorflow. I'd like to have tens
7777
let
7878
mach-nix = import (builtins.fetchGit {
7979
url = "https://github.com/DavHau/mach-nix/";
80-
ref = "2.1.0";
80+
ref = "2.1.1";
8181
});
8282
in mach-nix.mkPython {
8383
@@ -100,7 +100,7 @@ I'd like to install a more recent version of tensorflow which is not available f
100100
let
101101
mach-nix = import (builtins.fetchGit {
102102
url = "https://github.com/DavHau/mach-nix/";
103-
ref = "2.1.0";
103+
ref = "2.1.1";
104104
});
105105
in mach-nix.mkPython {
106106
@@ -129,7 +129,7 @@ I'd like to use a recent version of Pytorch from wheel, but I'd like to build th
129129
let
130130
mach-nix = import (builtins.fetchGit {
131131
url = "https://github.com/DavHau/mach-nix/";
132-
ref = "2.1.0";
132+
ref = "2.1.1";
133133
});
134134
overlays = []; # some very useful overlays
135135
in mach-nix.mkPython rec {
@@ -164,7 +164,7 @@ I have a complex requirements.txt which includes `imagecodecs`. It is available
164164
let
165165
mach-nix = import (builtins.fetchGit {
166166
url = "https://github.com/DavHau/mach-nix/";
167-
ref = "2.1.0";
167+
ref = "2.1.1";
168168
});
169169
in mach-nix.mkPython rec {
170170

mach_nix/generate.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33

44
from mach_nix.data.nixpkgs import NixpkgsDirectory
55
from mach_nix.data.providers import CombinedDependencyProvider, ProviderSettings
6-
from mach_nix.generators.overlay_generator import OverlaysGenerator
6+
from mach_nix.generators.overides_generator import OverridesGenerator
77
from mach_nix.requirements import parse_reqs, filter_reqs_by_eval_marker, context
88
from mach_nix.resolver.resolvelib_resolver import ResolvelibResolver
99
from mach_nix.versions import PyVer
@@ -36,7 +36,7 @@ def main():
3636
pypi_deps_db_src=pypi_deps_db_src,
3737
py_ver=py_ver
3838
)
39-
generator = OverlaysGenerator(
39+
generator = OverridesGenerator(
4040
py_ver,
4141
nixpkgs,
4242
pypi_fetcher_commit,
Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
from typing import Dict, List
22

3-
from data.providers import WheelDependencyProvider, SdistDependencyProvider, NixpkgsDependencyProvider
3+
from mach_nix.data.providers import WheelDependencyProvider, SdistDependencyProvider, NixpkgsDependencyProvider
44
from mach_nix.data.nixpkgs import NixpkgsDirectory
55
from mach_nix.generators import ExpressionGenerator
66
from mach_nix.resolver import ResolvedPkg
@@ -12,7 +12,7 @@ def unindent(text: str, remove: int):
1212
return ''.join(map(lambda l: l[remove:], text.splitlines(keepends=True)))
1313

1414

15-
class OverlaysGenerator(ExpressionGenerator):
15+
class OverridesGenerator(ExpressionGenerator):
1616

1717
def __init__(self, py_ver, nixpkgs: NixpkgsDirectory, pypi_fetcher_commit,
1818
pypi_fetcher_sha256, disable_checks,
@@ -23,7 +23,7 @@ def __init__(self, py_ver, nixpkgs: NixpkgsDirectory, pypi_fetcher_commit,
2323
self.pypi_fetcher_commit = pypi_fetcher_commit
2424
self.pypi_fetcher_sha256 = pypi_fetcher_sha256
2525
self.py_ver_nix = py_ver.nix()
26-
super(OverlaysGenerator, self).__init__(*args, **kwargs)
26+
super(OverridesGenerator, self).__init__(*args, **kwargs)
2727

2828
def generate(self, reqs) -> str:
2929
pkgs = self.resolver.resolve(reqs)

0 commit comments

Comments
 (0)