Commit graph

108 commits

Author SHA1 Message Date
adisbladis
aed290dad2
Prefer the newest possible version of a package 2020-10-01 18:21:00 +02:00
adisbladis
234b0f3f4d
Fix build with separated poetry/poetry-core build systems 2020-10-01 18:21:00 +02:00
adisbladis
99cdaa7cca
mk-poetry-dep: Add pep508 evaluation to dependency selection
Poetry 1.1.0 changed the marker format in https://github.com/python-poetry/poetry/pull/2361
2020-10-01 18:20:59 +02:00
adisbladis
099b3040ec
Null out poetry in pythonPackages set when bootstrapping 2020-10-01 14:34:58 +02:00
adisbladis
230f08e403
Bump version to 1.12.0 2020-08-26 15:01:31 +02:00
adisbladis
23a969297d
mkPoetryEnv: Add scripts from pyproject.toml (if they exist) 2020-08-17 11:06:13 +02:00
adisbladis
b6f9670d56
overrides: Remove condition from wheel override 2020-08-17 05:02:19 +02:00
adisbladis
6e2a8ce9cc
Release 1.11.0 2020-07-22 16:55:35 +02:00
adisbladis
f4fbc592d7
Make overrideOverlay composable 2020-07-22 01:21:24 +02:00
adisbladis
2a907cd9a9
Make default overrides extensible in a way that's also composable 2020-07-22 01:21:24 +02:00
adisbladis
6abe06ed6c
Make default overrides reference scope
So that overrideScope' will propagate overrides properly
2020-07-22 01:10:42 +02:00
adisbladis
f9cb26ed41
Make poetry2nix entirely overridable 2020-07-21 19:54:25 +02:00
adisbladis
78aeb5d8e3
Release 1.10.0 2020-07-14 16:13:18 +02:00
adisbladis
1d41a55f88
Always add Poetry as a build input unless bootstrapping
Currently Poetry does not have a notion of build-time
dependencies (setup-requires) in it's lock file.

When installing a dependency built with Poetry this has to be added
via an override which is really bad UX.

This change always adds Poetry as an interim solution until we have
resolved this in upstream Poetry.
2020-07-14 15:30:07 +02:00
adisbladis
8215ac6941
Add experimental support for plugin closures 2020-07-14 14:35:28 +02:00
Silvan Mosberger
bc4ac731e0
Fix moduleName not being applied for accessing python pkgs set 2020-07-01 10:24:00 +02:00
adisbladis
b6687abfc1
Release 1.9.2 2020-06-08 23:50:24 +02:00
adisbladis
35eac96f8c
Revert "Prefer newer versions of dependencies when there are multiple available ones"
This was a wrong fix based on a misunderstanding of the issue.
The actual problem has been reported upstream.

This reverts commit c19f1e414a.
2020-06-08 20:33:07 +02:00
adisbladis
c19f1e414a
Prefer newer versions of dependencies when there are multiple available ones 2020-06-08 19:48:47 +02:00
adisbladis
a2c8782734
Release 1.9.1 2020-06-08 17:31:33 +02:00
adisbladis
40a67636c3
Merge pull request #110 from Infinisil/editable-egg
Editable eggs
2020-05-28 22:23:29 +02:00
Silvan Mosberger
dfd357468f
Install an egg for editablePackageSources
This allows pkg_resources to find the package
2020-05-28 16:18:57 +02:00
adisbladis
e0d3a5e730
Fix nested git dependencies
When a dependency itself has a git dependency the metadata to infer
`ref` is not available in `pyproject.toml` and we have to fall back to `HEAD`.
2020-05-26 13:48:09 +01:00
adisbladis
9fec4a00a6
Invert meta precedence
User passed meta should always take precedence over automatically
infered meta.
2020-05-20 15:27:17 +01:00
adisbladis
cd5cd15526
Check pyproject for description & homepage attrs
These don't always exist.
2020-05-20 15:26:22 +01:00
adisbladis
8d2251bde8
Run nixpkgs-fmt again, it's seemingly not idempotent 2020-05-19 21:11:52 +01:00
adisbladis
db06bdd6e7
Format with nixpkgs-fmt 0.9 2020-05-19 21:06:02 +01:00
Silvan Mosberger
df7afa36e3
Introduce editablePackageSources to mkPoetryEnv 2020-05-08 23:01:13 +01:00
adisbladis
bbd264076a
Add suport for overriding the app together with dependencyEnv
And extend with support for all buildEnv args
2020-05-08 18:51:25 +01:00
Silvan Mosberger
d7d4fdc8de
Introduce dependencyEnv passthru 2020-05-08 18:27:51 +01:00
adisbladis
4aa4f74864
Release 1.8.0 2020-05-05 20:55:44 +01:00
adisbladis
4ebbfdacd1
nixpkgs-fmt broke it's format yet again 2020-04-29 14:12:59 +01:00
Raito Bezarius
54f4afca6d
Enable global preference for wheels for top-level functions 2020-04-29 14:08:21 +01:00
adisbladis
e164fdd78a
Fix semver pythonVersion checks
We're only looking at the major.minor currently. We need to look
major.minor.patch instead.

This is made slighty problematic non-cpython where the patch version
doesn't match. If major.minor is the same for both the Python version
& the derivation version we default to derivation.version otherwise we
set the pythonVersion to pythonVersion major.minor.0.
2020-04-29 13:22:20 +01:00
adisbladis
9dfb080d3f
Add canonicalisation of module names
This shouldn't be required and I think that these are actually
packaging bugs and not something that poetry2nix should really be
concerned with.

Closes #84
2020-04-15 10:24:46 +01:00
adisbladis
b9221f61b5
Automatically build most packages without passing format param
We should never have to use `format = "setuptools"` since pip can
_also_ handle setuptools packages.

This uses a custom pipBuildHook that removes pyproject.toml in case
there is also a setup.py in the same sources.
2020-04-01 00:14:30 +01:00
adisbladis
6a77db8213
Release 1.7.1 2020-03-27 23:17:11 +00:00
adisbladis
6ffeafff3c
Release 1.7.0 2020-03-27 22:39:38 +00:00
adisbladis
df8c9819f4
Fix git dependencies on non-default branches
Closes #73
2020-03-27 19:13:12 +00:00
adisbladis
cec428df49
Release 1.6.1 2020-03-27 14:33:15 +00:00
adisbladis
f7e435407e
nixpkgs-fmt all the things (again...) 2020-03-14 23:13:51 +00:00
Oleh Stolyar
a3655babd4 Do not leak projectDir into expressions
Fixes caching issues.
2020-03-12 13:06:06 +00:00
adisbladis
06d9687c0f
Prepare for release 1.6.0 2020-02-29 14:07:31 +00:00
adisbladis
2e55b2e95a
Remove the doc attribute
It was never really used by anything and it's output is not really
useful at this moment.
2020-02-29 14:07:28 +00:00
adisbladis
bb3c2d57d5
Add a default source filter when projectDir is used
Also use the same source filter for path deps.

The default source filter currently filters:
- Filters gitignore (if it exists, non-recursive)
- Filters pycache/pyc files
- Uses cleanSourceFilter to filter out .git/.hg, .o/.so, editor backup files & nix result symlinks
2020-02-29 12:05:23 +00:00
adisbladis
b85e2a6733
Set src to lib.cleanSource projectDir by default
Ideally we'd use `nix-gitignore` but that one fails when there is no
`.gitignore` file so it's not a sensible default.
2020-02-29 12:04:36 +00:00
adisbladis
090e2dd957
Add fixup hook
This hook should fix common mistakes like installing `tests` in
site-packages which leads to collisions.
2020-02-28 19:45:23 +00:00
adisbladis
1f413d27c9
Implement a proper fix for #52
We need to check pyproject.toml & poetry.lock constraints
_separately_.

Consider the following scenario:

- `poetry` depends on `tox` which in turn depends on `virtualenv`.

- `poetry` _also_ depends directly on virtualenv, but only for older
python versions.

In this case we don't want `virtualenv` as a direct input to `poetry`
but we _do_ want it as an input for `tox`.
2020-02-28 14:01:46 +00:00
adisbladis
7f7499462f
Set meta.platforms to something reasonable by default 2020-02-28 08:38:36 +00:00
Tobias Pflug
e1e3b90be2 Drop meta attribute for mkPoetryPackages/mkPoetryEnv
The `meta` attribute is only relevant for `mkPoetryApplication`
and can safely be dropped elsewhere.
2020-02-26 09:24:23 +01:00