Skip to content

Commit

Permalink
docs: Explain setuptools-scm edge case
Browse files Browse the repository at this point in the history
Helps with nix-community#921.
  • Loading branch information
l0b0 committed Jan 8, 2023
1 parent f40c155 commit bc1dc98
Showing 1 changed file with 23 additions and 0 deletions.
23 changes: 23 additions & 0 deletions docs/edgecases.md
Original file line number Diff line number Diff line change
Expand Up @@ -169,3 +169,26 @@ poetry2nix.mkPoetryApplication {

We recommend that you contribute your changes to `poetry2nix` so that other users can profit from them as well.
The specific file with the upstream overrides is [build-systems.json](https://github.com/nix-community/poetry2nix/blob/master/overrides/build-systems.json). It is a simple JSON file which contains the overrides in an array and sorted in alphabetical order.

#### ERROR: Could not find a version that satisfies the requirement [package spec] (from [package]) (from versions: none)

[Example error message](https://github.com/nix-community/poetry2nix/issues/921):

> ERROR: Could not find a version that satisfies the requirement python-ulid<2.0.0,>=1.1.0 (from linz-logger) (from versions: none)
> ERROR: No matching distribution found for python-ulid<2.0.0,>=1.1.0
[Quoting @adisbladis](https://github.com/nix-community/poetry2nix/issues/921#issuecomment-1373764661):

> This is usually because of setuptools-scm. I'd try adding an override for [the package mentioned in the package spec]. It might be sufficient to simply add setuptools-scm.
Resulting override:

```nix
{
python-ulid = super.python-ulid.overridePythonAttrs (
old: {
nativeBuildInputs = (old.nativeBuildInputs or [ ]) ++ [ self.setuptools-scm ];
}
);
}
```

0 comments on commit bc1dc98

Please sign in to comment.