about summary refs log tree commit diff
AgeCommit message (Collapse)AuthorFilesLines
2024-07-21 r/8385 chore(tvix): upgrade to tonic 0.12 / hyper 1.0Yureka15-739/+1828
Change-Id: Idd8ce48869ddd869d51a10959b920f1290a8a9b3 Reviewed-on: https://cl.tvl.fyi/c/depot/+/11991 Autosubmit: yuka <yuka@yuka.dev> Reviewed-by: flokli <flokli@flokli.de> Tested-by: BuildkiteCI
2024-07-21 r/8384 feat(tvix/tracing): http propagation for axumSimon Hauser8-11/+207
It introduces a new accept_trace function for axum0.7 which can be used to accept a header trace from a received request. This function can be used for tonic 0.12 once that version is released, and the specific `accept_trace` function within `tvix_tracing::propagate::tonic` can then be removed. This also integrates http propagation into the nar_bridge crate. Change-Id: I46dcc797d494bb3977c2633753e7060d88d29129 Reviewed-on: https://cl.tvl.fyi/c/depot/+/11925 Reviewed-by: Brian Olsen <me@griff.name> Tested-by: BuildkiteCI Reviewed-by: Simon Hauser <simon.hauser@helsinki-systems.de> Reviewed-by: flokli <flokli@flokli.de>
2024-07-21 r/8383 refactor(tvix/boot/tests): use nar-bridge-rsFlorian Klink1-4/+3
This switches the boot tests from the golang implementation to the rust one. Change-Id: Ide2a47aebe40c172077147c05bb6dacd74ba6b1e Reviewed-on: https://cl.tvl.fyi/c/depot/+/11997 Tested-by: BuildkiteCI Reviewed-by: Brian Olsen <me@griff.name>
2024-07-21 r/8382 fix(tvix/nar-bridge): fix root node decoding and validationFlorian Klink1-2/+7
This got broken while moving things around. We need to parse the b64-decoded bytes. Since we're now validating the root node, we also need to rename the root node to get past the node name validation. There probably should be some tests for this. Co-Authored-By: sinavir@sinavir.fr Change-Id: I8f24a4a0ac107b1ea5b94c0e0ed872a34eb7b587 Reviewed-on: https://cl.tvl.fyi/c/depot/+/11996 Reviewed-by: Brian Olsen <me@griff.name> Tested-by: BuildkiteCI
2024-07-20 r/8381 fix(tvix): fix outputHashes calculation for crates with versionsFlorian Klink1-2/+2
In case two crate versions are present, the key in the Cargo.nix file includes the version number too. To be able to set a specific hash for "tracing-opentelemetry 0.25.0" for example, this needs to account for keys with the version included. Access `crateName`, `version` and `src.outputHash` individually. Change-Id: Ib9800691a445ac403ff646cb32e85a7a4cbef9d8 Reviewed-on: https://cl.tvl.fyi/c/depot/+/11994 Tested-by: BuildkiteCI Reviewed-by: yuka <yuka@yuka.dev>
2024-07-20 r/8380 refactor(tvix/store): use composition in tvix_store crateYureka20-254/+572
Change-Id: Ie6290b296baba2b987f1a61c9bb4c78549ac11f1 Reviewed-on: https://cl.tvl.fyi/c/depot/+/11983 Reviewed-by: flokli <flokli@flokli.de> Autosubmit: yuka <yuka@yuka.dev> Tested-by: BuildkiteCI
2024-07-20 r/8379 feat(tvix/nar-bridge): implement PUT $outhash.narinfoFlorian Klink2-3/+79
This adds support to upload NARInfo files. We lookup the root node from the LRU cache, rename it appropriately and then put it into the PathInfoService. Change-Id: I5479032b51cd855363bc016dee63cf84b3304a36 Reviewed-on: https://cl.tvl.fyi/c/depot/+/11988 Tested-by: BuildkiteCI Reviewed-by: Brian Olsen <me@griff.name>
2024-07-20 r/8378 feat(tvix/nar-bridge): add 404 handler for GET/HEAD `/nar/…`Florian Klink1-0/+9
We currently send 405, and that confuses `nix copy`. Send a 404 for now, and add a futurework, as we can actually at least do something more meaningful in case we still have that nar hash in our LRU, which would avoid some unnecessary uploads in some cases. Change-Id: If625e9bd0fd6506cb73b88962d889aa08315fcea Reviewed-on: https://cl.tvl.fyi/c/depot/+/11987 Tested-by: BuildkiteCI Reviewed-by: Brian Olsen <me@griff.name>
2024-07-20 r/8377 feat(tvix/nar-bridge): support uploading NAR filesFlorian Klink5-13/+158
This ingests NAR files into the {Blob,Directory}Service, which are already part of the AppState. As we then need to correlate the root node to the uploaded PathInfo, we need to keep a (short-lived) lookup table from NARHash to root node around. We insert it into a `LruCache` after the NAR is uploaded, and use `peek()` to do the lookup, which doesn't update the LRU list. Change-Id: I48a4c6246bacf76559c5a4ccad2a0bc25c1b7900 Reviewed-on: https://cl.tvl.fyi/c/depot/+/11986 Tested-by: BuildkiteCI Reviewed-by: Brian Olsen <me@griff.name>
2024-07-20 r/8376 feat(tvix/nar-bridge): initFlorian Klink9-87/+1460
This adds an implementation of nar-bridge in Rust. Currently, only the GET parts are implemented. Contrary to the Go variant, this doesn't try to keep a mapping from nar hashes to root node in memory, it simply encodes the root node itself (stripped by its basename) into the URL. This pulls in a more recent version of axum than what we use in tonic, causing two versions of http and hyper, however dealing with `Body::from_stream` in axum 0.6 is much more annoying, and https://github.com/hyperium/tonic/pull/1740 suggests this will be fixed soon. Change-Id: Ia4c2dbda7cd3fdbe47a75f3e33544d19eac6e44e Reviewed-on: https://cl.tvl.fyi/c/depot/+/11898 Autosubmit: flokli <flokli@flokli.de> Reviewed-by: Brian Olsen <me@griff.name> Tested-by: BuildkiteCI
2024-07-20 r/8375 feat(tvix/castore/protos): return root node after validationFlorian Klink1-2/+4
This allows avoiding a `.node.unwrap()`` after validation. Change-Id: Ieef1ffebab16cdca94c979ca6831a7ab4f6007da Reviewed-on: https://cl.tvl.fyi/c/depot/+/11989 Reviewed-by: Brian Olsen <me@griff.name> Tested-by: BuildkiteCI
2024-07-20 r/8374 fix(tvix/store): add missing nar_info::ca::Hash::TextSha256Florian Klink1-21/+26
Also reorder to how it's ordered in the .proto file. Change-Id: I87c422feac4d12f6a84f99aa889f9c524a9878b9 Reviewed-on: https://cl.tvl.fyi/c/depot/+/11985 Tested-by: BuildkiteCI Reviewed-by: Brian Olsen <me@griff.name>
2024-07-20 r/8373 docs: More documentation of nix daemon protocolBrian Olsen6-154/+303
Uses `Set` to mark that the given list is actually a set. The format on stream is no different from `List` but is nice to know. Best effort document string formats. Documents default values for fields not used in old protocol versions. Document handshake, AddMultipleToStore format, Export format and Import paths format. Change-Id: I6cbe4c7de3770cc5caafc26229f99a07353ee3e2 Reviewed-on: https://cl.tvl.fyi/c/depot/+/11984 Reviewed-by: flokli <flokli@flokli.de> Tested-by: BuildkiteCI Autosubmit: Brian Olsen <me@griff.name>
2024-07-19 r/8372 feat(tvix): different service types in one compositionYureka11-46/+64
This will be necessary for the PathInfoService composition, as some PathInfoService implementations require a BlobService & DirectoryService to ingest into. Using the Extend trait for creating compositions allows extending the same composition with configs of various types e.g. BlobStore, DirectoryStore Generics are moved from the Composition struct to the functions.The storage of the InstantiatonStates uses the TypeId in the key and a Box<dyn Any> in the value, which is downcasted to InstantiatonState<T>. Change-Id: I2af11f26c535029adfb1c62905e0e7c4aaed7b51 Reviewed-on: https://cl.tvl.fyi/c/depot/+/11980 Reviewed-by: flokli <flokli@flokli.de> Reviewed-by: raitobezarius <tvl@lahfa.xyz> Tested-by: BuildkiteCI Autosubmit: yuka <yuka@yuka.dev>
2024-07-19 r/8371 test(tvix/castore/ObjectStoreBlobService): test correct chunkingYureka1-6/+23
Change-Id: I4a8f5cda2705560a6d52a2eb2be0dde35b784c8f Reviewed-on: https://cl.tvl.fyi/c/depot/+/11982 Tested-by: BuildkiteCI Autosubmit: yuka <yuka@yuka.dev> Reviewed-by: flokli <flokli@flokli.de>
2024-07-19 r/8370 fix(tvix/castore/blob/object_store): empty chunk list for single chunkYureka1-0/+9
Change-Id: Ie3609ac6184ecead11c4e03073433c26ce129848 Reviewed-on: https://cl.tvl.fyi/c/depot/+/11981 Autosubmit: yuka <yuka@yuka.dev> Reviewed-by: flokli <flokli@flokli.de> Tested-by: BuildkiteCI
2024-07-18 r/8369 fix(tvix/nix-compat): use `buf.filled()` to track read bytesRyan Lahfa1-1/+1
We were wrongly using `buf.initialized()` which contains more than the filled portion to compute the number of bytes read during a poll call. This made us go into the trailer reading state too early and finally failing due to invalid trailer data. Fixes b/405. Co-authored-by: Florian Klink <flokli@flokli.de> Change-Id: I66ba6e2116389e6b97305f85c4e0922195000e45 Signed-off-by: Ryan Lahfa <tvl@lahfa.xyz> Reviewed-on: https://cl.tvl.fyi/c/depot/+/11978 Tested-by: BuildkiteCI Reviewed-by: flokli <flokli@flokli.de> Reviewed-by: edef <edef@edef.eu>
2024-07-18 r/8368 refactor(tvix): use composition & registry for from_addrYureka18-229/+316
Change-Id: I3c94ecb5958294b5973c6fcdf5ee9c0d37fa54ad Reviewed-on: https://cl.tvl.fyi/c/depot/+/11976 Reviewed-by: flokli <flokli@flokli.de> Tested-by: BuildkiteCI Autosubmit: yuka <yuka@yuka.dev>
2024-07-18 r/8367 feat(tvix/castore): add sled to composition registryYureka2-1/+51
Change-Id: I03fa8dfabcee14c5f657380f86bb1a7aa00e08ef Reviewed-on: https://cl.tvl.fyi/c/depot/+/11977 Tested-by: BuildkiteCI Reviewed-by: flokli <flokli@flokli.de>
2024-07-18 r/8366 feat(tvix/composition): allow creating a blank CompositionContextYureka1-6/+13
this is useful when oneshot-instantiating a store from a single config Change-Id: I08538fdee1d0bb26b3ae2da7d3b2339b2e93bc0a Reviewed-on: https://cl.tvl.fyi/c/depot/+/11975 Reviewed-by: flokli <flokli@flokli.de> Autosubmit: yuka <yuka@yuka.dev> Tested-by: BuildkiteCI
2024-07-18 r/8365 feat(tvix/castore): add composition moduleYureka16-51/+747
Change-Id: I0868f3278db85ae5fe030089ee9033837bc08748 Signed-off-by: Yureka <tvl@yuka.dev> Reviewed-on: https://cl.tvl.fyi/c/depot/+/11853 Reviewed-by: flokli <flokli@flokli.de> Tested-by: BuildkiteCI
2024-07-09 r/8364 chore(tvix/tools/weave): Regenerate Cargo.nix and filter srcIlan Joselevich3-42/+101
The Cargo.lock also got changed because of crate2nix using --freezed. Change-Id: I79b062eddb13f59c4656a62735df1e527fc91a44 Reviewed-on: https://cl.tvl.fyi/c/depot/+/11970 Autosubmit: Ilan Joselevich <personal@ilanjoselevich.com> Tested-by: BuildkiteCI Reviewed-by: flokli <flokli@flokli.de>
2024-07-09 r/8363 chore(tvix/tools/turbofetch): Regenerate Cargo.nix and filter srcIlan Joselevich3-37/+28
The Cargo.lock also got changed because of crate2nix using --freezed. Change-Id: I48cabe514e0cf1dd1f00870bcb7958a2a49663d5 Reviewed-on: https://cl.tvl.fyi/c/depot/+/11969 Reviewed-by: flokli <flokli@flokli.de> Tested-by: BuildkiteCI Autosubmit: Ilan Joselevich <personal@ilanjoselevich.com>
2024-07-09 r/8362 chore(tvix/tools/crunch-v2): Regenerate Cargo.nix and filter srcIlan Joselevich3-68/+104
The Cargo.lock also got changed because of crate2nix using --freezed. Change-Id: I90245bad27f6fee01455557bbccc865301a4f1a0 Reviewed-on: https://cl.tvl.fyi/c/depot/+/11968 Autosubmit: Ilan Joselevich <personal@ilanjoselevich.com> Tested-by: BuildkiteCI Reviewed-by: flokli <flokli@flokli.de>
2024-07-09 r/8361 chore(tvix/tools/narinfo2parquet): Regenerate Cargo.nix and filter srcIlan Joselevich3-38/+31
The Cargo.lock also got changed because of crate2nix using --freezed. Change-Id: Id5225e73ec5894bc324f363660472a7efdd803cf Reviewed-on: https://cl.tvl.fyi/c/depot/+/11967 Autosubmit: Ilan Joselevich <personal@ilanjoselevich.com> Reviewed-by: flokli <flokli@flokli.de> Tested-by: BuildkiteCI
2024-07-09 r/8360 fix(tvix/{store,castore,build}): Compile tonic w/o config in build.rsIlan Joselevich3-21/+9
Previously we had to make a mutable Config instance and set bytes and other values in it because they were not exposed to the builder pattern (https://github.com/hyperium/tonic/issues/908) but now they are, so we just set them through the builder. Change-Id: I8904c6b93f09173b56586024b1ced59d622bce66 Reviewed-on: https://cl.tvl.fyi/c/depot/+/11966 Autosubmit: Ilan Joselevich <personal@ilanjoselevich.com> Tested-by: BuildkiteCI Reviewed-by: flokli <flokli@flokli.de>
2024-07-08 r/8359 chore(3p/gerrit): downgrade mina SSHd againLuke Granger-Brown3-44/+2
This breaks it with "ssh_dispatch_run_fatal: Connection to 2a01:4f8:242:5b21:0:feed:edef:beef port 29418: incorrect signature" Change-Id: I9bafc5fb6d4743ce4f097158ec14fecc791366ca Reviewed-on: https://cl.tvl.fyi/c/depot/+/11965 Tested-by: BuildkiteCI Autosubmit: lukegb <lukegb@tvl.fyi> Reviewed-by: flokli <flokli@flokli.de> Reviewed-by: lukegb <lukegb@tvl.fyi>
2024-07-08 r/8358 chore(3p/gerrit): create buildBazelPackageNG and migrate gerrit to itLuke Granger-Brown27-263/+458
This bumps Gerrit to 3.10.0, and also introduces a new mechanism for building it that should hopefully have some more stable hashes than the previous bodgery. In this world, we only cache what we explicitly want to. There are some hooks implemented for `rules_java` and `rules_nodejs` (before version 6) that force use of local binaries; this means we can drop the use of the FHSUserEnv and use the java and nodejs binaries provided by nixpkgs instead. detzip is deleted; it hasn't been used in yonks. We also add https://gerrit-review.googlesource.com/c/gerrit/+/431977, which bumps the SSHd version so that we can have U2F-based SSH keys. Change-Id: Ie12a9a33bbb1e4bd96aa252580aca3b8bc4a1205 Reviewed-on: https://cl.tvl.fyi/c/depot/+/11963 Reviewed-by: lukegb <lukegb@tvl.fyi> Autosubmit: lukegb <lukegb@tvl.fyi> Tested-by: BuildkiteCI
2024-07-07 r/8357 refactor(tvix): point SSL_CERT_FILE to /dev/nullFlorian Klink5-12/+12
reqwest wants to be able to read a file of trust roots when constructed, but as it doesn't actually do any HTTPS connections inside the nix build, an empty list of trust roots is totally sufficient. Thankfully /dev/null provides such a file. Change-Id: I9bd1619b2c9f8ff2a6640d2ac410d4de5b20c2ea Reviewed-on: https://cl.tvl.fyi/c/depot/+/11961 Autosubmit: flokli <flokli@flokli.de> Tested-by: BuildkiteCI Reviewed-by: aspen <root@gws.fyi>
2024-07-07 r/8356 feat(tvix/eval): Bump imbl to 3.0.0Aspen Smith3-5/+6
Change-Id: I88053fa2df35dc486c51d015f4b2156541c07af3 Reviewed-on: https://cl.tvl.fyi/c/depot/+/11962 Tested-by: BuildkiteCI Autosubmit: aspen <root@gws.fyi> Reviewed-by: flokli <flokli@flokli.de>
2024-07-07 r/8355 fix(tvix/repl): Share globals and sourcemap across evaluationsAspen Smith10-60/+221
Now that we can bind (potentially lazy, potentially lambda-containing) values in the REPL and then reference them in subsequent evaluations, it's important that the values to which we construct shared references are shared across those subsequent evaluations - otherwise, we get panics due to unknown source map locations, or dropped weak references to globals. This change assigns both the globals and the source map as fields on the Repl after the first evaluation, and then passes those in (to the EvaluationBuilder) on subsequent evaluations. On the EvaluationBuilder side, there's some panicking introduced - this is intentional, as my intent is for the builder to be configured statically enough that panicking is the best way to report errors here (it's always a bug to misconfigure an Evaluation, and we'd never want to handle it dynamically). Change-Id: I37225697235c22b683ca48a17d30fa8fedd12d1b Reviewed-on: https://cl.tvl.fyi/c/depot/+/11960 Reviewed-by: flokli <flokli@flokli.de> Autosubmit: aspen <root@gws.fyi> Tested-by: BuildkiteCI
2024-07-07 r/8354 test(tvix/cli): Add some additional REPL testsAspen Smith1-0/+42
A couple of already-passing tests covering REPL behavior Change-Id: Ie21f4abf68ab12827fd15128a8ef810cd8592d07 Reviewed-on: https://cl.tvl.fyi/c/depot/+/11959 Reviewed-by: flokli <flokli@flokli.de> Tested-by: BuildkiteCI Autosubmit: aspen <root@gws.fyi>
2024-07-07 r/8353 test(tvix/cli): Make the REPL testableAspen Smith9-346/+522
Juggle around the internals of the tvix-cli crate so that we expose the Repl as a public type with a `send` method, that sends a string to the repl and *captures all output* so that it can be subsequently asserted on in tests. Then, demonstrate that this works with a single (for now) REPL test using expect-test to assert on the output of a single command sent to the REPL. As the REPL gets more complicated, this will allow us to make tests that cover that complex behavior. Change-Id: I88175bd72d8760c79faade95ebb1d956f08a7b83 Reviewed-on: https://cl.tvl.fyi/c/depot/+/11958 Autosubmit: aspen <root@gws.fyi> Tested-by: BuildkiteCI Reviewed-by: flokli <flokli@flokli.de>
2024-07-06 r/8352 refactor(tvix/eval): Construct globals in EvaluationBuilder::buildAspen Smith2-58/+47
Construct the Rc<GlobalsMap> for the evaluation as part of EvaluiationBuilder::build, rather than deferring it until we actually compile. This changes nothing functionally, but gets us one step closer to sharing this globals map across evaluations. Change-Id: Id92e9fb88d974d763056d4f15ce61962ab776e84 Reviewed-on: https://cl.tvl.fyi/c/depot/+/11957 Tested-by: BuildkiteCI Autosubmit: aspen <root@gws.fyi> Reviewed-by: flokli <flokli@flokli.de>
2024-07-06 r/8351 refactor(tvix/eval): Builderize EvaluationAspen Smith15-155/+326
Make constructing of a new Evaluation use the builder pattern rather than setting public mutable fields. This is currently a pure refactor (no functionality has changed) but has a few advantages: - We've encapsulated the internals of the fields in Evaluation, meaning we can change them without too much breakage of clients - We have type safety that prevents us from ever changing the fields of an Evaluation after it's built (which matters more in a world where we reuse Evaluations). More importantly, this paves the road for doing different things with the construction of an Evaluation - notably, sharing certain things like the GlobalsMap across subsequent evaluations in eg the REPL. Fixes: b/262 Change-Id: I4a27116faac14cdd144fc7c992d14ae095a1aca4 Reviewed-on: https://cl.tvl.fyi/c/depot/+/11956 Tested-by: BuildkiteCI Autosubmit: aspen <root@gws.fyi> Reviewed-by: flokli <flokli@flokli.de>
2024-07-06 r/8350 chore(tvix/docs): Cross off a TODOAspen Smith1-6/+0
This is done now, as of fc6359463 (feat(tvix/repl): Allow binding variables at the top-level, 2024-07-04) Change-Id: I2126cbadeb66625cda93a7cd7ddb31409ec60fd9 Reviewed-on: https://cl.tvl.fyi/c/depot/+/11955 Reviewed-by: flokli <flokli@flokli.de> Autosubmit: aspen <root@gws.fyi> Tested-by: BuildkiteCI
2024-07-05 r/8349 refactor(web/tvixbolt): buildRustPackage -> crate2nixIlan Joselevich9-122/+4595
With the recent changes to crate2nix and buildRustCrate in nixpkgs it is now possible to build tvixbolt via crate2nix like we do for other tvix crates. We can reuse a lot of the customizations done in //tvix in tvixbolt to avoid repeating ourselves. A script for serving tvixbolt locally for testing purposes is also available now through the .serve attribute of tvixbolt. This change supersedes https://cl.tvl.fyi/c/depot/+/11821. Change-Id: I4864df8b75aec73cf5fee2428924ed4cfbb32902 Reviewed-on: https://cl.tvl.fyi/c/depot/+/11952 Tested-by: BuildkiteCI Autosubmit: Ilan Joselevich <personal@ilanjoselevich.com> Reviewed-by: flokli <flokli@flokli.de>
2024-07-05 r/8348 feat(tvix/utils): Add defaultCrateOverridesForPkgs functionIlan Joselevich2-78/+78
This function can be reused across the rest of the repo to make use of our overriden defaultCrateOverrides with support for tvix crates. Change-Id: I8c554dece052bd9dd32acac13dab8114933272a7 Reviewed-on: https://cl.tvl.fyi/c/depot/+/11951 Autosubmit: Ilan Joselevich <personal@ilanjoselevich.com> Tested-by: BuildkiteCI Reviewed-by: flokli <flokli@flokli.de>
2024-07-05 r/8347 fix(tvix/utils): Optionally add support for Cargo in filterRustCrateSrcIlan Joselevich2-5/+7
Previously we would unconditionally add Cargo.toml to the fileset. We mostly use buildRustCrate in tvix so it does not make sense to add it by default, instead I made it so you enable cargoSupport if you want Cargo.{toml,lock} to be added to the fileset. Change-Id: I5a6016534fc5599e85ab581fe3d9b81e7a24f940 Reviewed-on: https://cl.tvl.fyi/c/depot/+/11950 Reviewed-by: flokli <flokli@flokli.de> Tested-by: BuildkiteCI Autosubmit: Ilan Joselevich <personal@ilanjoselevich.com>
2024-07-05 r/8346 feat(tvix/repl): Allow binding variables at the top-levelAspen Smith6-16/+157
Allow binding variables at the REPL's toplevel in the same way the Nix REPL does, using the syntax <ident> = <expr>. This fully, strictly evaluates the value and sets it in the repl's "env", which gets passed in at the toplevel when evaluating expressions. The laziness behavior differs from Nix's, but I think this is good: ❯ nix repl Welcome to Nix version 2.3.18. Type :? for help. nix-repl> x = builtins.trace "x" 1 nix-repl> x trace: x 1 nix-repl> x 1 vs tvix: tvix-repl> x = builtins.trace "x" 1 trace: "x" :: string tvix-repl> x => 1 :: int tvix-repl> x => 1 :: int Bug: https://b.tvl.fyi/issues/371 Change-Id: Ieb2d626b7195fa87be638c9a4dae2eee45eb9ab1 Reviewed-on: https://cl.tvl.fyi/c/depot/+/11954 Reviewed-by: flokli <flokli@flokli.de> Tested-by: BuildkiteCI Autosubmit: aspen <root@gws.fyi>
2024-07-05 r/8345 feat(tvix/eval): Allow passing in an env to evaluationAspen Smith7-15/+99
Allow passing in a top-level env, a map from name to value, to evaluation. The intent is to support bound identifiers in the REPL just like upstream nix does. Getting this working involves mucking around a bit with internals - most notably, locals now only optionally have a Span (since locals don't have an easy span we can use) - and getting that working requires propagating some minor hacks to places where we currently *need* a span (and which would require too much changing now to make spans optional; my guess is that that would essentially end up making spans optional throughout the codebase). Also, some extra care has to be taken to close out the scope in the case that we do pass in an env, to avoid breaking our assumptions about the size of the stack when we return from the toplevel Change-Id: Ie475b2d3dfc72ccbf298d2a3ea28c63ac877d653 Reviewed-on: https://cl.tvl.fyi/c/depot/+/11953 Tested-by: BuildkiteCI Autosubmit: aspen <root@gws.fyi> Reviewed-by: flokli <flokli@flokli.de>
2024-07-05 r/8344 docs(tvix): update WASM statusFlorian Klink1-20/+6
crate2nix can now build WASM, and cl/11859 showcases this now. Even if it's not in the same cargo workspace, we should still migrate tvixbolt to a crate2nix build. Remove the part about Build/Store frontends, it was more of an explanation why we want WASM builds to be nice, it can be tracked in separate TODOs once more concrete. Change-Id: If4f5e0994b55520ba70cabefb4fcef9dc17bc394 Reviewed-on: https://cl.tvl.fyi/c/depot/+/11945 Tested-by: BuildkiteCI Reviewed-by: Ilan Joselevich <personal@ilanjoselevich.com> Reviewed-by: flokli <flokli@flokli.de> Autosubmit: flokli <flokli@flokli.de>
2024-07-05 r/8343 refactor(tvix/eval): Drop LightSpan entirelyAspen Smith8-175/+109
This was made unnecessary in c92d06271 (feat(tvix/eval): drop LightSpan::Delayed, 2023-12-08) because it didn't improve benchmarks as much as expected and has been vestigial since; this continues the cleanup by just removing it altogether Change-Id: I21ec7ae9b52a5cccd2092696a5a87f658194d672 Reviewed-on: https://cl.tvl.fyi/c/depot/+/11949 Autosubmit: aspen <root@gws.fyi> Tested-by: BuildkiteCI Reviewed-by: flokli <flokli@flokli.de>
2024-07-04 r/8342 docs(tvix): introductiontoastal5-0/+73
Includes hacky, but workable solution for the pronunciation ‘issue’ Karl comes from: http://ipa-reader.xyz/?text=tvɪks&voice=Karl Co-Authored-By: Florian Klink <flokli@flokli.de> Change-Id: Iad7788ec7295902fd2159766a664016c7b1e2ae9 Reviewed-on: https://cl.tvl.fyi/c/depot/+/11908 Tested-by: BuildkiteCI Reviewed-by: flokli <flokli@flokli.de>
2024-07-03 r/8341 test(tvix/store): test listing endpoint tooFlorian Klink1-1/+9
Change-Id: Ia4035aca43cf9d3f7de982dd154715120ba25496 Reviewed-on: https://cl.tvl.fyi/c/depot/+/11927 Reviewed-by: Brian Olsen <me@griff.name> Autosubmit: flokli <flokli@flokli.de> Tested-by: BuildkiteCI
2024-07-03 r/8340 fix(tvix/store/pathinfo/bigtable): fix listing endpointFlorian Klink1-1/+3
We were wrongly comparing the raw row_key with the store path digest, but we hexlower-encode the digest in the row key (via derive_pathinfo_key). Update the logic to fix that. Change-Id: I8916d8de9fb8b25a6986d4158faa91ec97c57347 Reviewed-on: https://cl.tvl.fyi/c/depot/+/11926 Reviewed-by: Brian Olsen <me@griff.name> Autosubmit: flokli <flokli@flokli.de> Tested-by: BuildkiteCI
2024-07-02 r/8339 feat(tvix/tracing): http trace propagationSimon Hauser10-17/+302
Introduces a helper function within tvix-tracing that returns a reqwest tracing middleware that will ingest the traceparent if otlp is enabled. It is feature flagged in tvix-tracing so not every consumer of that library automatically has reqwest in its dependencies. Tested using netcat to verify that the `traceparent` header is there if otlp is enabled and missing if otlp feature is disabled. Change-Id: I5abccae777b725f5ff7382e3686165383c477a39 Reviewed-on: https://cl.tvl.fyi/c/depot/+/11886 Tested-by: BuildkiteCI Reviewed-by: flokli <flokli@flokli.de>
2024-07-01 r/8338 feat(users/kranzes): add wasm-hello-worldIlan Joselevich7-0/+1262
This can be used as a reference for how to build a wasm project with crate2nix. Change-Id: Ib4d0db6bf24d8f1dec4734d5f1e8de19212a54cd Reviewed-on: https://cl.tvl.fyi/c/depot/+/11859 Reviewed-by: flokli <flokli@flokli.de> Tested-by: BuildkiteCI
2024-07-01 r/8337 chore(3p/sources): bump to OpenSSH vulnerability hotfixVincent Ambo15-230/+124
See https://github.com/NixOS/nixpkgs/pull/323753 for details. Changes: * git: temporarily comment out dottime patch (it doesn't apply, but it's not critical) * third-party/cgit: use an older git version where dottime patch still applies * 3p/crate2nix: remove crate2nix patches included in latest release * tvix: remove unneeded defaultCrateOverrides (upstreamed to nixpkgs) * tvix: regenerate Cargo.nix * tvix/nix-compat: remove unnused AtermWriteable::aterm_bytes pub(crate) function * tvix/nix-compat: remove redundant trait bounds * tvix/glue: use clone_into() to set drv.{builder,system} * tools/crate2nix: apply workaround for https://github.com/numtide/treefmt/issues/327 * toold/depotfmt: expose treefmt config as passthru * tools/crate2nix: undo some more hacks in the crate2nix-check drv Change-Id: Ifbcedeb3e8f81b2f6ec1dbf10189bfa6dfd9c75c Co-Authored-By: Florian Klink <flokli@flokli.de> Reviewed-on: https://cl.tvl.fyi/c/depot/+/11907 Reviewed-by: tazjin <tazjin@tvl.su> Tested-by: BuildkiteCI Reviewed-by: flokli <flokli@flokli.de>
2024-07-01 r/8336 feat(tvix/store): add --remote-path-info-service-addr optionFlorian Klink1-0/+26
This is allows adding a cache in front of tvix-store daemon, and is less code duplication than cl/11902, means we can probably land that until we have proper store composition config. It can be used to provide a tvix-store daemon interface for a Nix HTTP Binary cache, saving all calculated PathInfo to another PathInfoService after ingestion. Change-Id: If141d718c2635f66aa90d46a80fd79c86c07d9ff Reviewed-on: https://cl.tvl.fyi/c/depot/+/11903 Tested-by: BuildkiteCI Reviewed-by: Connor Brewster <cbrewster@hey.com>