Poetry2nix | 331 Members | |
| https://github.com/nix-community/poetry2nix | 62 Servers |
| Sender | Message | Time |
|---|---|---|
| 18 May 2022 | ||
| 22:28:37 | ||
| 19 May 2022 | ||
| 14:33:56 | ||
| Hi everyone! I'm currently trying to use poetry2nix on a project and I'm stuck when compiling
I have also made a pastebin with the build log: https://pastebin.com/TAw1m4Tc | 14:49:25 | |
| Hey folks. I have been trying to give poetry2nix a whirl on my system. I was having an almost seamless experience but then I ran into an issue with the package building for two of my dev dependencies 😅 The errors are vastly different for both. I figured the best way to ask for assistance would be to build some example "test cases", so I did: https://github.com/m1cr0man/p2n-test Both subfolders contain one of the broken packages each + the log output. Both were built simply by doing poetry init, adding my package, nix flake init --template github:nix-community/poetry2nix, and then trying nix run Would anyone be able to shed some light on these? Are they worth opening a github issue? | 19:40:27 | |
| Looks like missing deps in both cases | 19:42:27 | |
| Oh? Ok interesting. I remember using node2nix in the past that there was a way to override/augment dependency's dependencies. Is there a similar mechanism here where I can add those missing deps, or is this actually an upstream issue for the respective packages? | 19:45:41 | |
| For the first case, yes and no | 19:46:38 | |
| It declares a build system but Poetry doesn't track those correctly yet | 19:46:55 | |
| It's being worked on but for now poetry2nix has a list of overrides | 19:47:08 | |
| oh I see.. these? https://github.com/nix-community/poetry2nix/blob/master/overrides/default.nix#L86 | 19:48:17 | |
| For the second one, it could be an upstream bug or it could be another build-dep issue | 19:48:35 | |
| https://github.com/nix-community/poetry2nix/blob/master/overrides/build-systems.json | 19:48:47 | |
| These. | 19:48:49 | |
| Well, these if it's just a missing dep, and the other ones if you need something fancier | 19:49:06 | |
| Right I see. In terms of augmenting this in those examples I made, I can just put these overrides as overlays in my pkgs right? | 19:50:48 | |
| Yeah | 19:51:22 | |
| Also I looked up flake8-mutable and it's just really old and uses setup-requires | 19:51:39 | |
| Which I'm pretty sure has been deprecated multiple times by now but generally falls under the "poetry doesn't track build deps correctly" umbrella | 19:52:08 | |
| I'm half tempted to drop these two deps but they are actually quite useful 😅 I wonder if there's newer alternatives though | 19:52:52 | |
| mypy? | 19:54:40 | |
| Assuming flake8-annotations does what I think it does | 19:54:52 | |
| hm yeah that probably would work | 20:11:06 | |
Well with that sorted, I have another question. I want to set my flake's devShell to a mkPoetryEnv.env derivation, but I want to include poetry itself in the environment. Is there an easy way to do that? I tried adding poetry to extraPackages, but it confliced with poetry-core from somewhere else | 20:13:17 | |
* Well with that sorted, I have another question. I want to set my flake's devShell to a mkPoetryEnv.env derivation, but I want to include poetry itself in the environment (the PATH, that is). Is there an easy way to do that? I tried adding poetry to extraPackages, but it confliced with poetry-core from somewhere else | 20:13:49 | |
| It should already be there IIRC? | 20:14:37 | |
| Like by default | 20:14:43 | |
| uhm, Unless I messed something up... let me try again | 20:14:56 | |
| sorry got sidetracked.. yep definitely missing poetry | 20:38:20 | |
| I'll set up an example in that repo | 20:39:26 | |
| Oh it's probably my global poetry | 20:39:41 | |