9 Dec 2024 |
Irenes | oh | 22:39:51 |
Irenes | I thought I deleted that but I accidentally sent it | 22:39:56 |
Irenes | sigh | 22:39:58 |
Irenes | I was going to volunteer to review CLs because that's one of the few things so well-defined that I can reliably find spoons for it despite everything going on in my life | 22:40:25 |
Irenes | I guess I do want to volunteer for that | 22:40:36 |
Irenes | but like, add me as a reviewer on your CL if you want me to do that, I am not going to parachute in and start reviewing things I haven't been asked to, I think that would have a very bad success rate in terms of being what anyone wants | 22:41:27 |
Charles |
i have a suspicion that a lot of parts of pytest could be reused
fwiw, i find maintaining pytest test suites to be very difficult because of fixtures; they seem to make people make weird choices that become really hard to untangle later when things change that would be less of a problem with normal functions, and also they don't cooperate with lsp servers at all (at least, not the ones i know of)
| 23:47:46 |
10 Dec 2024 |
9999years | you can give them type annotations and then you can at least get autocomplete | 00:44:21 |
9999years | but nothing actually checks them | 00:44:25 |
Charles | IME, go-to-references and go-to-definition don't work, there's no guarantee that the fixture argument type signature match the type signature of the fixture definition, there's nothing to statically check the existence of a fixture, especially with things like autouse and such | 00:46:03 |
raitobezarius | piegames i think there's a big regression due to the introduction of shadow-internal-symbols | 09:49:14 |
raitobezarius | all repositories using niv are broken right now | 09:49:21 |
raitobezarius | because they do hasThisAsNixpkgsPath = <nixpkgs> == ./.; | 09:49:31 |
raitobezarius | which gets interpreted as a shadowing of __findFile | 09:49:37 |
piegames | I'm fairly certain the logic is correct w.r.t. its intent. Which if true, would mean that they are overriding __findFile somewhere? | 09:50:38 |
piegames | Alternatively it could be that the logic has a fuckup when used scopedImport . ScopedImport is notoriously brittle | 09:51:31 |
piegames | Can you link to the respective Niv code or a reproducer? | 09:51:43 |
puck | In reply to @piegames:flausch.social Alternatively it could be that the logic has a fuckup when used scopedImport . ScopedImport is notoriously brittle the StaticEnv built by scopedImport isn't marked as root, indeed; and i am going to assume this is in fact the TVL repo, which uses scopedImport to override __findFile | 11:35:45 |
puck | * the StaticEnv built by scopedImport isn't marked as root, indeed; and i am going to assume this is in fact the TVL repo, which uses scopedImport to override __findFile , and then uses the niv sources.nix | 11:36:41 |
piegames | I mean not marking it as root was a deliberate decision, but if people actually use this shit we can maybe revert it for now | 11:38:58 |
puck | the thing that's very funny is, it's explicitly overridden to avoid people using __findFile | 11:39:24 |
puck | scopedArgs.__findFile = _: _: throw "Do not import from NIX_PATH in the depot!"; | 11:39:47 |
piegames | Lol | 11:40:33 |
piegames | This should be a static lint tbh | 11:41:08 |
raitobezarius | https://git.lix.systems/lix-project/lix/issues/599 for the upstream bug | 11:48:20 |
piegames | I still don't understand why the Niv error happens, or where the override happens | 11:51:14 |
raitobezarius | the override happens in TVL default.nix | 11:51:22 |
raitobezarius | scopedArgs = {
__findFile = _: _: throw "Do not import from NIX_PATH in the depot!";
| 11:51:25 |
raitobezarius | and then niv sources is imported | 11:51:30 |
raitobezarius | niv is fine without TVL | 11:51:33 |