__json can be invalid without the daemon rejecting the derivation, then fails at build #380

Closed
opened 2024-06-07 22:04:19 +00:00 by jade · 1 comment
Owner

cc @puck

initially i was thinking we shouldn't accept people putting __json into derivations at all, but I'm not so sure now. i think that has possible valid use cases like wanting to serialize it in another process and avoid a round trip, perhaps, but we could certainly just outright reject derivations with bad __json as invalid at the daemon, assuming that uh we actually have any checks on those and they're not just like, sent over as bytes as it currently stands.

cc @puck initially i was thinking we shouldn't accept people putting `__json` into derivations at all, but I'm not so sure now. i think that has possible valid use cases like wanting to serialize it in another process and avoid a round trip, perhaps, but we could certainly just outright reject derivations with bad `__json` as invalid at the daemon, assuming that uh we actually have any checks on those and they're not just like, sent over as bytes as it currently stands.
pennae added this to the 2.95 milestone 2025-12-01 14:51:44 +00:00
raito self-assigned this 2026-02-27 20:46:32 +00:00
Member

This issue was mentioned on Gerrit on the following CLs:

  • commit message in cl/5286 ("libexpr/primops: reject __json in structured attrs derivations")
<!-- GERRIT_LINKBOT: {"cls": [{"backlink": "https://gerrit.lix.systems/c/lix/+/5286", "number": 5286, "kind": "commit message"}], "cl_meta": {"5286": {"change_title": "libexpr/primops: reject __json in structured attrs derivations"}}} --> This issue was mentioned on Gerrit on the following CLs: * commit message in [cl/5286](https://gerrit.lix.systems/c/lix/+/5286) ("libexpr/primops: reject __json in structured attrs derivations")
Sign in to join this conversation.
No milestone
No project
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
lix-project/lix#380
No description provided.