)]}'
{"tvix/store/src/nar/import.rs":[{"author":{"_account_id":1000085,"name":"Connor Brewster","display_name":"cbrewster","email":"cbrewster@hey.com","username":"cbrewster"},"change_message_id":"ed20e2f16fd719215c9f77cd9c5715b37e404435","unresolved":true,"context_lines":[{"line_number":26,"context_line":"    // The NAR reader emits nodes in DFS preorder."},{"line_number":27,"context_line":"    let root_node \u003d nar_reader::open(r).await.map_err(Error::IO)?;"},{"line_number":28,"context_line":""},{"line_number":29,"context_line":"    let (tx, rx) \u003d mpsc::channel(1);"},{"line_number":30,"context_line":"    let rx \u003d tokio_stream::wrappers::ReceiverStream::new(rx);"},{"line_number":31,"context_line":""},{"line_number":32,"context_line":"    let produce \u003d async move {"}],"source_content_type":"text/x-rustsrc","patch_set":13,"id":"1f6f4213_46f0c857","line":29,"updated":"2024-05-06 15:09:37.000000000","message":"How come we need a channel here?","commit_id":"268ad788a7df61d65b0bcb8bfd9980cb7136a545"},{"author":{"_account_id":1000036,"name":"flokli","email":"flokli@flokli.de","username":"flokli"},"change_message_id":"ea9f2837a9a2c114cae54d6baa8d6fe839eeb4b1","unresolved":false,"context_lines":[{"line_number":26,"context_line":"    // The NAR reader emits nodes in DFS preorder."},{"line_number":27,"context_line":"    let root_node \u003d nar_reader::open(r).await.map_err(Error::IO)?;"},{"line_number":28,"context_line":""},{"line_number":29,"context_line":"    let (tx, rx) \u003d mpsc::channel(1);"},{"line_number":30,"context_line":"    let rx \u003d tokio_stream::wrappers::ReceiverStream::new(rx);"},{"line_number":31,"context_line":""},{"line_number":32,"context_line":"    let produce \u003d async move {"}],"source_content_type":"text/x-rustsrc","patch_set":13,"id":"2e294df7_f16b4fc0","line":29,"in_reply_to":"1f6f4213_46f0c857","updated":"2024-05-06 15:24:05.000000000","message":"It\u0027s because of lifetime issues. If you describe this in a loop, Rust can\u0027t prove you\u0027re not using both the \"parent\" and \"child\" nar reader objects, both holding mutable references to the underlying async reader. Hence the channel and sending things while recursing.","commit_id":"268ad788a7df61d65b0bcb8bfd9980cb7136a545"},{"author":{"_account_id":1000085,"name":"Connor Brewster","display_name":"cbrewster","email":"cbrewster@hey.com","username":"cbrewster"},"change_message_id":"ed20e2f16fd719215c9f77cd9c5715b37e404435","unresolved":true,"context_lines":[{"line_number":54,"context_line":"    Ok(node.rename(\"\".into()))"},{"line_number":55,"context_line":"}"},{"line_number":56,"context_line":""},{"line_number":57,"context_line":"#[async_recursion]"},{"line_number":58,"context_line":"async fn produce_nar_inner\u003c\u0027a: \u0027async_recursion, \u0027r: \u0027async_recursion, BS\u003e("},{"line_number":59,"context_line":"    blob_service: BS,"},{"line_number":60,"context_line":"    node: nar_reader::Node\u003c\u0027a, \u0027r\u003e,"}],"source_content_type":"text/x-rustsrc","patch_set":13,"id":"b05e1467_9d044a89","line":57,"updated":"2024-05-06 15:09:37.000000000","message":"We should upgrade to Rust 1.77 https://blog.rust-lang.org/2024/03/21/Rust-1.77.0.html#support-for-recursion-in-async-fn","commit_id":"268ad788a7df61d65b0bcb8bfd9980cb7136a545"},{"author":{"_account_id":1000036,"name":"flokli","email":"flokli@flokli.de","username":"flokli"},"change_message_id":"ea9f2837a9a2c114cae54d6baa8d6fe839eeb4b1","unresolved":false,"context_lines":[{"line_number":54,"context_line":"    Ok(node.rename(\"\".into()))"},{"line_number":55,"context_line":"}"},{"line_number":56,"context_line":""},{"line_number":57,"context_line":"#[async_recursion]"},{"line_number":58,"context_line":"async fn produce_nar_inner\u003c\u0027a: \u0027async_recursion, \u0027r: \u0027async_recursion, BS\u003e("},{"line_number":59,"context_line":"    blob_service: BS,"},{"line_number":60,"context_line":"    node: nar_reader::Node\u003c\u0027a, \u0027r\u003e,"}],"source_content_type":"text/x-rustsrc","patch_set":13,"id":"8fe8deab_622cbae1","line":57,"in_reply_to":"b05e1467_9d044a89","updated":"2024-05-06 15:24:05.000000000","message":"I think we even have Rust 1.77. Though there\u0027s other places using async_recursion too, I guess we can do that in a followup CL.","commit_id":"268ad788a7df61d65b0bcb8bfd9980cb7136a545"}],"tvix/store/src/pathinfoservice/nix_http.rs":[{"author":{"_account_id":1000085,"name":"Connor Brewster","display_name":"cbrewster","email":"cbrewster@hey.com","username":"cbrewster"},"change_message_id":"ed20e2f16fd719215c9f77cd9c5715b37e404435","unresolved":true,"context_lines":[{"line_number":221,"context_line":"            warn!("},{"line_number":222,"context_line":"                narinfo.nar_size \u003d narinfo.nar_size,"},{"line_number":223,"context_line":"                http.nar_size \u003d nar_size,"},{"line_number":224,"context_line":"                \"NARSize mismatch\""},{"line_number":225,"context_line":"            );"},{"line_number":226,"context_line":"            Err(io::Error::new("},{"line_number":227,"context_line":"                io::ErrorKind::InvalidData,"}],"source_content_type":"text/x-rustsrc","patch_set":13,"id":"40a56824_7be73334","line":224,"updated":"2024-05-06 15:09:37.000000000","message":"NarSize for consistency","commit_id":"268ad788a7df61d65b0bcb8bfd9980cb7136a545"},{"author":{"_account_id":1000036,"name":"flokli","email":"flokli@flokli.de","username":"flokli"},"change_message_id":"ea9f2837a9a2c114cae54d6baa8d6fe839eeb4b1","unresolved":false,"context_lines":[{"line_number":221,"context_line":"            warn!("},{"line_number":222,"context_line":"                narinfo.nar_size \u003d narinfo.nar_size,"},{"line_number":223,"context_line":"                http.nar_size \u003d nar_size,"},{"line_number":224,"context_line":"                \"NARSize mismatch\""},{"line_number":225,"context_line":"            );"},{"line_number":226,"context_line":"            Err(io::Error::new("},{"line_number":227,"context_line":"                io::ErrorKind::InvalidData,"}],"source_content_type":"text/x-rustsrc","patch_set":13,"id":"d48c258f_12eaf666","line":224,"in_reply_to":"40a56824_7be73334","updated":"2024-05-06 15:24:05.000000000","message":"Done","commit_id":"268ad788a7df61d65b0bcb8bfd9980cb7136a545"}]}
