Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
284 changes: 153 additions & 131 deletions Cargo.lock

Large diffs are not rendered by default.

8 changes: 4 additions & 4 deletions crates/brioche-core/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ bytesize = "2.3.1"
console-subscriber = "0.5.0"
debug-ignore = "1.0.5"
deno_ast = { version = "0.53.2", features = ["transpiling"] }
deno_core = "0.407.0"
deno_core = "0.408.0"
deno_error = "0.7.1"
directories = "6.0.0"
fastcdc = { version = "4.0.1", features = ["tokio"] }
Expand Down Expand Up @@ -103,7 +103,7 @@ rust-embed = { version = "8.11.0", features = [
rustls-native-certs = "0.8.4"
serde = { version = "1.0.228", features = ["derive"] }
serde_json = "1.0.150"
serde_v8 = "0.316.0"
serde_v8 = "0.317.0"
serde_with = { version = "3.21.0", features = ["hex"] }
sha2 = "0.11.0"
sqlx = { version = "0.8.6", features = [
Expand All @@ -129,7 +129,7 @@ tracing-subscriber = { version = "0.3.23", features = [
"json",
"tracing-log",
] }
ulid = "2.0.1"
ulid = "3.0.0"
url = { version = "2.5.8", features = ["serde"] }
urlencoding = "2.1.3"
walkdir = "2.5.0"
Expand All @@ -150,7 +150,7 @@ humantime = "2.3.0"
assert_matches = "1.5.0"
aws-runtime = "1.7.3"
brioche-test-support = { path = "../brioche-test-support" }
deno_core = { version = "0.407.0", features = [
deno_core = { version = "0.408.0", features = [
# For tests, this feature should be enabled to resolve a segfault that
# can occur if V8 detects the `pki` CPU flag. See this issue:
# https://github.com/denoland/deno_core/issues/1091
Expand Down
6 changes: 3 additions & 3 deletions crates/brioche-core/benches/input.rs
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ fn bench_input(bencher: divan::Bencher, removal: Removal) {
.unwrap();
let (brioche, context) = runtime.block_on(brioche_test_support::brioche_test());

let input_root = context.path(ulid::Ulid::r#gen().to_string());
let input_root = context.path(ulid::Ulid::generate().to_string());

let input_path = input_root.join("input");
let input_resources = input_root.join("resources");
Expand Down Expand Up @@ -92,7 +92,7 @@ fn bench_input_with_shared_resources(bencher: divan::Bencher, removal: Removal)
.unwrap();
let (brioche, context) = runtime.block_on(brioche_test_support::brioche_test());

let input_root = context.path(ulid::Ulid::r#gen().to_string());
let input_root = context.path(ulid::Ulid::generate().to_string());

let input_path = input_root.join("input");
let input_resources = input_root.join("resources");
Expand Down Expand Up @@ -163,7 +163,7 @@ fn bench_input_with_shared_ancestor_resources(bencher: divan::Bencher, removal:
.unwrap();
let (brioche, context) = runtime.block_on(brioche_test_support::brioche_test());

let input_root = context.path(ulid::Ulid::r#gen().to_string());
let input_root = context.path(ulid::Ulid::generate().to_string());

let input_path = input_root.join("input");
let input_resources = input_root.join("resources");
Expand Down
4 changes: 2 additions & 2 deletions crates/brioche-core/src/bake/process.rs
Original file line number Diff line number Diff line change
Expand Up @@ -320,7 +320,7 @@ pub async fn bake_process(
tracing::Span::current().record("recipe_hash", tracing::field::display(hash));

let temp_dir = brioche.data_dir.join("process-temp");
let bake_dir = temp_dir.join(ulid::Ulid::r#gen().to_string());
let bake_dir = temp_dir.join(ulid::Ulid::generate().to_string());
tracing::Span::current().record("bake_dir", tracing::field::display(bake_dir.display()));
let bake_dir = BakeDir::create(bake_dir).await?;

Expand Down Expand Up @@ -1612,7 +1612,7 @@ impl SandboxBackendSelector {
let temp_dir = brioche
.data_dir
.join("process-temp")
.join(format!("{}-setup", ulid::Ulid::r#gen()));
.join(format!("{}-setup", ulid::Ulid::generate()));
let temp_dir = BakeDir::create(temp_dir).await?;
let temp_dir = temp_dir.remove_on_drop();

Expand Down
6 changes: 3 additions & 3 deletions crates/brioche-core/src/blob.rs
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ pub async fn save_blob(

let temp_dir = brioche.data_dir.join("blobs-temp");
tokio::fs::create_dir_all(&temp_dir).await.unwrap();
let temp_path = temp_dir.join(ulid::Ulid::r#gen().to_string());
let temp_path = temp_dir.join(ulid::Ulid::generate().to_string());

let mut temp_file = tokio::fs::File::create(&temp_path)
.await
Expand Down Expand Up @@ -115,7 +115,7 @@ where

let temp_dir = brioche.data_dir.join("blobs-temp");
tokio::fs::create_dir_all(&temp_dir).await.unwrap();
let temp_path = temp_dir.join(ulid::Ulid::r#gen().to_string());
let temp_path = temp_dir.join(ulid::Ulid::generate().to_string());
let mut temp_file = tokio::fs::File::create(&temp_path)
.await
.context("failed to open temp file")?;
Expand Down Expand Up @@ -213,7 +213,7 @@ where

let temp_dir = brioche.data_dir.join("blobs-temp");
std::fs::create_dir_all(&temp_dir).unwrap();
let temp_path = temp_dir.join(ulid::Ulid::r#gen().to_string());
let temp_path = temp_dir.join(ulid::Ulid::generate().to_string());
let mut temp_file = std::fs::File::create(&temp_path).context("failed to open temp file")?;

tracing::trace!(temp_path = %temp_path.display(), "saving blob");
Expand Down
2 changes: 1 addition & 1 deletion crates/brioche-core/src/fs_utils.rs
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ pub async fn move_file(source: &Path, dest: &Path) -> anyhow::Result<MoveType> {
}

pub async fn atomic_copy(source: &Path, dest: &Path) -> anyhow::Result<()> {
let dest_temp = dest.with_extension(format!("tmp-{}", ulid::Ulid::r#gen()));
let dest_temp = dest.with_extension(format!("tmp-{}", ulid::Ulid::generate()));
tokio::fs::copy(source, &dest_temp)
.await
.context("failed to copy file to temp")?;
Expand Down
2 changes: 1 addition & 1 deletion crates/brioche-core/src/output.rs
Original file line number Diff line number Diff line change
Expand Up @@ -362,7 +362,7 @@ async fn create_local_output_inner(
let local_temp_dir = brioche.data_dir.join(LOCALS_TEMP_DIR_NAME);
tokio::fs::create_dir_all(&local_temp_dir).await?;

let temp_id = ulid::Ulid::r#gen();
let temp_id = ulid::Ulid::generate();
let local_temp_path = local_temp_dir.join(temp_id.to_string());
let local_temp_resource_dir = local_temp_dir.join(format!("{temp_id}-resources.d"));

Expand Down
2 changes: 1 addition & 1 deletion crates/brioche-core/src/project/artifact.rs
Original file line number Diff line number Diff line change
Expand Up @@ -541,7 +541,7 @@ async fn write_artifact_atomic(
}

// Write the file to a temp path
let temp_path = temp_dir.join(format!("temp-file-{}", ulid::Ulid::r#gen()));
let temp_path = temp_dir.join(format!("temp-file-{}", ulid::Ulid::generate()));
crate::output::create_output(
brioche,
artifact,
Expand Down
2 changes: 1 addition & 1 deletion crates/brioche-core/src/script.rs
Original file line number Diff line number Diff line change
Expand Up @@ -201,7 +201,7 @@ impl BriocheModuleLoader {
if std::fs::create_dir_all(dir).is_err() {
return;
}
let tmp = dir.join(format!("{hash:016x}.{}.tmp", ulid::Ulid::r#gen()));
let tmp = dir.join(format!("{hash:016x}.{}.tmp", ulid::Ulid::generate()));
if std::fs::write(&tmp, data).is_ok() {
let _ = std::fs::rename(&tmp, self.code_cache_path(hash));
}
Expand Down
2 changes: 1 addition & 1 deletion crates/brioche-core/src/vfs.rs
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ impl Vfs {
let contents = Arc::new(contents);

let file_id = if self.mutable {
FileId::Mutable(ulid::Ulid::r#gen())
FileId::Mutable(ulid::Ulid::generate())
} else {
FileId::Hash(BlobHash::for_content(&contents))
};
Expand Down
2 changes: 1 addition & 1 deletion crates/brioche-test-support/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ tokio-util = "0.7.18"
toml = "1.1.2"
tower-lsp = "0.20.0"
tracing = "0.1.44"
ulid = "2.0.1"
ulid = "3.0.0"
url = "2.5.8"
zstd = "0.13.3"

Expand Down
4 changes: 2 additions & 2 deletions crates/brioche-test-support/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -650,7 +650,7 @@ impl TestContext {
f: impl AsyncFnOnce(PathBuf),
) -> (Projects, ProjectHash, PathBuf) {
let temp_project_path = self
.mkdir(format!("temp-project-{}", ulid::Ulid::r#gen()))
.mkdir(format!("temp-project-{}", ulid::Ulid::generate()))
.await;

f(temp_project_path.clone()).await;
Expand Down Expand Up @@ -714,7 +714,7 @@ impl TestContext {
) -> ProjectHash {
self.cached_registry_project_by_path(cache, async |context| {
let temp_project_path = context
.mkdir(format!("temp-project-{}", ulid::Ulid::r#gen()))
.mkdir(format!("temp-project-{}", ulid::Ulid::generate()))
.await;
f(temp_project_path.clone()).await;
temp_project_path
Expand Down
2 changes: 1 addition & 1 deletion crates/brioche/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ tokio = { version = "1.52.3", features = ["full", "tracing"] }
tokio-util = "0.7.18"
tower-lsp = "0.20.0"
tracing = "0.1.44"
ulid = "2.0.1"
ulid = "3.0.0"
url = { version = "2.5.8", features = ["serde"] }
zstd-framed = { version = "0.1.1", features = ["tokio"] }

Expand Down
2 changes: 1 addition & 1 deletion crates/brioche/src/self_update.rs
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ pub async fn self_update(args: SelfUpdateArgs) -> anyhow::Result<bool> {
let mut download_body = tokio_util::io::StreamReader::new(download_body);

// Open a temporary file to save the response
let id = ulid::Ulid::r#gen();
let id = ulid::Ulid::generate();
let download_path = installation_info
.install_root
.join(format!("v{latest_version}-{download_basename}-{id}.tar.xz"));
Expand Down