From 92e72a8911ae51bb047e93cef88a0460bb3e12eb Mon Sep 17 00:00:00 2001 From: Steve Lee Date: Mon, 17 Feb 2025 17:06:24 -0800 Subject: [PATCH 01/12] Fix progress display when using JSON, add None option; exhance progress schema --- dsc/Cargo.lock | 19 +- dsc/src/args.rs | 2 +- dsc/src/main.rs | 2 +- dsc/src/subcommand.rs | 6 +- dsc/tests/dsc_args.tests.ps1 | 6 + dsc/tests/dsc_config_get.tests.ps1 | 14 +- dsc/tests/dsc_resource_list.tests.ps1 | 1 + dsc_lib/Cargo.lock | 8 +- dsc_lib/Cargo.toml | 1 + dsc_lib/locales/en-us.toml | 3 + dsc_lib/src/configure/mod.rs | 74 ++++---- dsc_lib/src/discovery/command_discovery.rs | 47 ++--- dsc_lib/src/discovery/discovery_trait.rs | 4 +- dsc_lib/src/discovery/mod.rs | 2 +- dsc_lib/src/lib.rs | 4 +- dsc_lib/src/progress.rs | 192 +++++++++++++++++++++ dsc_lib/src/util.rs | 98 ----------- tools/test_group_resource/Cargo.lock | 8 +- 18 files changed, 300 insertions(+), 191 deletions(-) create mode 100644 dsc_lib/src/progress.rs diff --git a/dsc/Cargo.lock b/dsc/Cargo.lock index 59dfca85..02f604d9 100644 --- a/dsc/Cargo.lock +++ b/dsc/Cargo.lock @@ -555,6 +555,7 @@ dependencies = [ "tree-sitter", "tree-sitter-dscexpression", "tree-sitter-rust", + "uuid", ] [[package]] @@ -2195,9 +2196,12 @@ checksum = "06abde3611657adf66d383f00b093d7faecc7fa57071cce2578660c9f1010821" [[package]] name = "uuid" -version = "1.12.1" +version = "1.13.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b3758f5e68192bb96cc8f9b7e2c2cfdabb435499a28499a42f8f984092adad4b" +checksum = "ced87ca4be083373936a67f8de945faa23b6b42384bd5b64434850802c6dccd0" +dependencies = [ + "getrandom 0.3.1", +] [[package]] name = "uuid-simd" @@ -2286,6 +2290,15 @@ dependencies = [ "wit-bindgen-rt", ] +[[package]] +name = "wasm-bindgen" +version = "0.2.95" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "26816d2e1a4a36a2940b96c5296ce403917633dff8f3440e9b236ed6f6bacad2" +dependencies = [ + "wit-bindgen-rt", +] + [[package]] name = "wasm-bindgen" version = "0.2.100" @@ -2544,7 +2557,7 @@ version = "0.33.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3268f3d866458b787f390cf61f4bbb563b922d091359f9608842999eaee3943c" dependencies = [ - "bitflags 2.8.0", + "bitflags 2.6.0", ] [[package]] diff --git a/dsc/src/args.rs b/dsc/src/args.rs index 9da575d2..fcd9010b 100644 --- a/dsc/src/args.rs +++ b/dsc/src/args.rs @@ -4,7 +4,7 @@ use clap::{Parser, Subcommand, ValueEnum}; use clap_complete::Shell; use dsc_lib::dscresources::command_resource::TraceLevel; -use dsc_lib::util::ProgressFormat; +use dsc_lib::progress::ProgressFormat; use rust_i18n::t; use serde::Deserialize; diff --git a/dsc/src/main.rs b/dsc/src/main.rs index 81b73962..b2f7328f 100644 --- a/dsc/src/main.rs +++ b/dsc/src/main.rs @@ -8,7 +8,7 @@ use rust_i18n::{i18n, t}; use std::{io, process::exit}; use sysinfo::{Process, RefreshKind, System, get_current_pid, ProcessRefreshKind}; use tracing::{error, info, warn, debug}; -use dsc_lib::util::ProgressFormat; +use dsc_lib::progress::ProgressFormat; #[cfg(debug_assertions)] use crossterm::event; diff --git a/dsc/src/subcommand.rs b/dsc/src/subcommand.rs index fde17e78..8b55c70b 100644 --- a/dsc/src/subcommand.rs +++ b/dsc/src/subcommand.rs @@ -25,7 +25,7 @@ use dsc_lib::{ }, dscresources::dscresource::{Capability, ImplementedAs, Invoke}, dscresources::resource_manifest::{import_manifest, ResourceManifest}, - util::ProgressFormat, + progress::ProgressFormat, }; use rust_i18n::t; use std::{ @@ -288,7 +288,7 @@ pub fn config(subcommand: &ConfigSubCommand, parameters: &Option, mounte } }; - let mut configurator = match Configurator::new(&json_string) { + let mut configurator = match Configurator::new(&json_string, progress_format) { Ok(configurator) => configurator, Err(err) => { error!("Error: {err}"); @@ -296,8 +296,6 @@ pub fn config(subcommand: &ConfigSubCommand, parameters: &Option, mounte } }; - configurator.set_progress_format(progress_format); - if let ConfigSubCommand::Set { what_if , .. } = subcommand { if *what_if { configurator.context.execution_type = ExecutionKind::WhatIf; diff --git a/dsc/tests/dsc_args.tests.ps1 b/dsc/tests/dsc_args.tests.ps1 index e13e216d..b7a097ee 100644 --- a/dsc/tests/dsc_args.tests.ps1 +++ b/dsc/tests/dsc_args.tests.ps1 @@ -293,4 +293,10 @@ resources: $LASTEXITCODE | Should -Be 1 "$TestDrive/tracing.txt" | Should -FileContentMatchExactly "Target path does not exist: '/invalid/path'" } + + It '--progress-format can be None' { + dsc -p none resource list 2> $TestDrive/tracing.txt + $LASTEXITCODE | Should -Be 0 + (Get-Content $TestDrive/tracing.txt -Raw) | Should -BeNullOrEmpty + } } diff --git a/dsc/tests/dsc_config_get.tests.ps1 b/dsc/tests/dsc_config_get.tests.ps1 index ae98b447..fc7d0355 100644 --- a/dsc/tests/dsc_config_get.tests.ps1 +++ b/dsc/tests/dsc_config_get.tests.ps1 @@ -68,15 +68,25 @@ Describe 'dsc config get tests' { $config_yaml | dsc --progress-format json config get -f - 2> $TestDrive/ErrorStream.txt $LASTEXITCODE | Should -Be 0 $lines = Get-Content $TestDrive/ErrorStream.txt - $ProgressMessagesFound = $False + $ProgressMessagesFound = $false + $ProgressResultFound = $false foreach ($line in $lines) { $jp = $line | ConvertFrom-Json if ($jp.activity) { # if line is a progress message + $jp.id | Should -Not -BeNullOrEmpty $jp.percent_complete | Should -BeIn (0..100) - $ProgressMessagesFound = $True + $ProgressMessagesFound = $true + } + + if ($jp.percent_complete -eq 100 -and $jp.resourceType -eq 'Microsoft.DSC.Debug/Echo') { + $ProgressResultFound = $true + $jp.resourceName | Should -BeExactly 'Echo' + $jp.result | Should -Not -BeNullOrEmpty + $jp.result.output | Should -BeExactly 'hello' } } $ProgressMessagesFound | Should -BeTrue + $ProgressResultFound | Should -BeTrue } It 'contentVersion is ignored' { diff --git a/dsc/tests/dsc_resource_list.tests.ps1 b/dsc/tests/dsc_resource_list.tests.ps1 index b8fd4ff4..8ac85255 100644 --- a/dsc/tests/dsc_resource_list.tests.ps1 +++ b/dsc/tests/dsc_resource_list.tests.ps1 @@ -66,6 +66,7 @@ Describe 'Tests for listing resources' { foreach ($line in $lines) { $jp = $line | ConvertFrom-Json if ($jp.activity) { # if line is a progress message + $jp.id | Should -Not -BeNullOrEmpty $jp.percent_complete | Should -BeIn (0..100) $ProgressMessagesFound = $True } diff --git a/dsc_lib/Cargo.lock b/dsc_lib/Cargo.lock index 9a1ae9b2..7a9f8f75 100644 --- a/dsc_lib/Cargo.lock +++ b/dsc_lib/Cargo.lock @@ -444,6 +444,7 @@ dependencies = [ "tree-sitter", "tree-sitter-dscexpression", "tree-sitter-rust", + "uuid", ] [[package]] @@ -1833,9 +1834,12 @@ checksum = "06abde3611657adf66d383f00b093d7faecc7fa57071cce2578660c9f1010821" [[package]] name = "uuid" -version = "1.12.1" +version = "1.13.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b3758f5e68192bb96cc8f9b7e2c2cfdabb435499a28499a42f8f984092adad4b" +checksum = "ced87ca4be083373936a67f8de945faa23b6b42384bd5b64434850802c6dccd0" +dependencies = [ + "getrandom 0.3.1", +] [[package]] name = "uuid-simd" diff --git a/dsc_lib/Cargo.toml b/dsc_lib/Cargo.toml index 6ef40745..b41c12d8 100644 --- a/dsc_lib/Cargo.toml +++ b/dsc_lib/Cargo.toml @@ -35,6 +35,7 @@ tracing-indicatif = { version = "0.3" } tree-sitter = "0.25" tree-sitter-rust = "0.23" tree-sitter-dscexpression = { path = "../tree-sitter-dscexpression" } +uuid = { version = "1.13", features = ["v4"] } [dev-dependencies] serde_yaml = "0.9" diff --git a/dsc_lib/locales/en-us.toml b/dsc_lib/locales/en-us.toml index cb8cd290..04055ce8 100644 --- a/dsc_lib/locales/en-us.toml +++ b/dsc_lib/locales/en-us.toml @@ -314,6 +314,9 @@ unknown = "Unknown" validation = "Validation" setting = "Setting" +[progress] +failedToSerialize = "Failed to serialize progress JSON: %{json}" + [util] foundSetting = "Found setting '%{name}' in %{path}" notFoundSetting = "Setting '%{name}' not found in %{path}" diff --git a/dsc_lib/src/configure/mod.rs b/dsc_lib/src/configure/mod.rs index 144e0314..f9e1e075 100644 --- a/dsc_lib/src/configure/mod.rs +++ b/dsc_lib/src/configure/mod.rs @@ -13,19 +13,17 @@ use crate::dscresources::{ use crate::DscResource; use crate::discovery::Discovery; use crate::parser::Statement; -use crate::ProgressFormat; -use crate::util::ProgressBar; +use crate::progress::{ProgressBar, ProgressFormat}; use self::context::Context; use self::config_doc::{Configuration, DataType, MicrosoftDscMetadata, Operation, SecurityContextKind}; use self::depends_on::get_resource_invocation_order; use self::config_result::{ConfigurationExportResult, ConfigurationGetResult, ConfigurationSetResult, ConfigurationTestResult}; use self::constraints::{check_length, check_number_limits, check_allowed_values}; -use indicatif::ProgressStyle; use rust_i18n::t; use security_context_lib::{SecurityContext, get_security_context}; use serde_json::{Map, Value}; use std::path::PathBuf; -use std::{collections::HashMap, mem}; +use std::collections::HashMap; use tracing::{debug, info, trace}; pub mod context; pub mod config_doc; @@ -138,16 +136,6 @@ fn escape_property_values(properties: &Map) -> Result Result { - let mut pb_span = ProgressBar::new(progress_format == ProgressFormat::Json); - - pb_span.pb_set_style(&ProgressStyle::with_template( - "{spinner:.green} [{elapsed_precise:.cyan}] [{bar:40.cyan/blue}] {pos:>7}/{len:7} {msg:.yellow}" - )?); - pb_span.pb_set_length(len); - Ok(pb_span) -} - fn add_metadata(kind: &Kind, mut properties: Option> ) -> Result { if *kind == Kind::Adapter { // add metadata to the properties so the adapter knows this is a config @@ -206,7 +194,7 @@ impl Configurator { /// # Errors /// /// This function will return an error if the configuration is invalid or the underlying discovery fails. - pub fn new(json: &str) -> Result { + pub fn new(json: &str, progress_format: ProgressFormat) -> Result { let discovery = Discovery::new()?; let mut config = Configurator { json: json.to_owned(), @@ -214,7 +202,7 @@ impl Configurator { context: Context::new(), discovery, statement_parser: Statement::new()?, - progress_format: ProgressFormat::Default, + progress_format, }; config.validate_config()?; Ok(config) @@ -230,11 +218,6 @@ impl Configurator { &self.config } - /// Sets progress format for the configuration. - pub fn set_progress_format(&mut self, progress_format: ProgressFormat) { - self.progress_format = progress_format; - } - /// Invoke the get operation on a resource. /// /// # Returns @@ -247,11 +230,10 @@ impl Configurator { pub fn invoke_get(&mut self) -> Result { let mut result = ConfigurationGetResult::new(); let resources = get_resource_invocation_order(&self.config, &mut self.statement_parser, &self.context)?; - let mut pb_span = get_progress_bar_span(resources.len() as u64, self.progress_format)?; - pb_span.enter(); + let mut progress = ProgressBar::new(resources.len() as u64, self.progress_format)?; for resource in resources { - pb_span.pb_set_message(format!("Get '{}'", resource.name).as_str()); - pb_span.pb_inc(1); + progress.set_activity(format!("Get '{}'", resource.name).as_str()); + progress.set_resource(&resource.name, &resource.resource_type, None); let properties = self.invoke_property_expressions(resource.properties.as_ref())?; let Some(dsc_resource) = self.discovery.find_resource(&resource.resource_type) else { return Err(DscError::ResourceNotFound(resource.resource_type)); @@ -265,13 +247,15 @@ impl Configurator { match &get_result { GetResult::Resource(resource_result) => { self.context.references.insert(format!("{}:{}", resource.resource_type, resource.name), serde_json::to_value(&resource_result.actual_state)?); + progress.set_resource(&resource.name, &resource.resource_type, Some(&resource_result.actual_state)); }, GetResult::Group(group) => { let mut results = Vec::::new(); for result in group { results.push(serde_json::to_value(&result.result)?); } - self.context.references.insert(format!("{}:{}", resource.resource_type, resource.name), Value::Array(results)); + self.context.references.insert(format!("{}:{}", resource.resource_type, resource.name), Value::Array(results.clone())); + progress.set_resource(&resource.name, &resource.resource_type, Some(&Value::Array(results.clone()))); }, } let resource_result = config_result::ResourceGetResult { @@ -290,12 +274,12 @@ impl Configurator { result: get_result, }; result.results.push(resource_result); + progress.increment(1); } result.metadata = Some( self.get_result_metadata(Operation::Get) ); - std::mem::drop(pb_span); Ok(result) } @@ -315,11 +299,10 @@ impl Configurator { pub fn invoke_set(&mut self, skip_test: bool) -> Result { let mut result = ConfigurationSetResult::new(); let resources = get_resource_invocation_order(&self.config, &mut self.statement_parser, &self.context)?; - let mut pb_span = get_progress_bar_span(resources.len() as u64, self.progress_format)?; - pb_span.enter(); + let mut progress = ProgressBar::new(resources.len() as u64, self.progress_format)?; for resource in resources { - pb_span.pb_set_message(format!("Set '{}'", resource.name).as_str()); - pb_span.pb_inc(1); + progress.set_activity(format!("Set '{}'", resource.name).as_str()); + progress.set_resource(&resource.name, &resource.resource_type, None); let properties = self.invoke_property_expressions(resource.properties.as_ref())?; let Some(dsc_resource) = self.discovery.find_resource(&resource.resource_type) else { return Err(DscError::ResourceNotFound(resource.resource_type)); @@ -387,13 +370,15 @@ impl Configurator { match &set_result { SetResult::Resource(resource_result) => { self.context.references.insert(format!("{}:{}", resource.resource_type, resource.name), serde_json::to_value(&resource_result.after_state)?); + progress.set_resource(&resource.name, &resource.resource_type, Some(&resource_result.after_state)); }, SetResult::Group(group) => { let mut results = Vec::::new(); for result in group { results.push(serde_json::to_value(&result.result)?); } - self.context.references.insert(format!("{}:{}", resource.resource_type, resource.name), Value::Array(results)); + self.context.references.insert(format!("{}:{}", resource.resource_type, resource.name), Value::Array(results.clone())); + progress.set_resource(&resource.name, &resource.resource_type, Some(&Value::Array(results.clone()))); }, } @@ -413,12 +398,12 @@ impl Configurator { result: set_result, }; result.results.push(resource_result); + progress.increment(1); } result.metadata = Some( self.get_result_metadata(Operation::Set) ); - mem::drop(pb_span); Ok(result) } @@ -434,11 +419,10 @@ impl Configurator { pub fn invoke_test(&mut self) -> Result { let mut result = ConfigurationTestResult::new(); let resources = get_resource_invocation_order(&self.config, &mut self.statement_parser, &self.context)?; - let mut pb_span = get_progress_bar_span(resources.len() as u64, self.progress_format)?; - pb_span.enter(); + let mut progress = ProgressBar::new(resources.len() as u64, self.progress_format)?; for resource in resources { - pb_span.pb_set_message(format!("Test '{}'", resource.name).as_str()); - pb_span.pb_inc(1); + progress.set_activity(format!("Test '{}'", resource.name).as_str()); + progress.set_resource(&resource.name, &resource.resource_type, None); let properties = self.invoke_property_expressions(resource.properties.as_ref())?; let Some(dsc_resource) = self.discovery.find_resource(&resource.resource_type) else { return Err(DscError::ResourceNotFound(resource.resource_type)); @@ -452,13 +436,15 @@ impl Configurator { match &test_result { TestResult::Resource(resource_test_result) => { self.context.references.insert(format!("{}:{}", resource.resource_type, resource.name), serde_json::to_value(&resource_test_result.actual_state)?); + progress.set_resource(&resource.name, &resource.resource_type, Some(&resource_test_result.actual_state)); }, TestResult::Group(group) => { let mut results = Vec::::new(); for result in group { results.push(serde_json::to_value(&result.result)?); } - self.context.references.insert(format!("{}:{}", resource.resource_type, resource.name), Value::Array(results)); + self.context.references.insert(format!("{}:{}", resource.resource_type, resource.name), Value::Array(results.clone())); + progress.set_resource(&resource.name, &resource.resource_type, Some(&Value::Array(results.clone()))); }, } let resource_result = config_result::ResourceTestResult { @@ -477,12 +463,12 @@ impl Configurator { result: test_result, }; result.results.push(resource_result); + progress.increment(1); } result.metadata = Some( self.get_result_metadata(Operation::Test) ); - std::mem::drop(pb_span); Ok(result) } @@ -499,12 +485,11 @@ impl Configurator { let mut result = ConfigurationExportResult::new(); let mut conf = config_doc::Configuration::new(); - let mut pb_span = get_progress_bar_span(self.config.resources.len() as u64, self.progress_format)?; - pb_span.enter(); + let mut progress = ProgressBar::new(self.config.resources.len() as u64, self.progress_format)?; let resources = self.config.resources.clone(); for resource in &resources { - pb_span.pb_set_message(format!("Export '{}'", resource.name).as_str()); - pb_span.pb_inc(1); + progress.set_activity(format!("Export '{}'", resource.name).as_str()); + progress.set_resource(&resource.name, &resource.resource_type, None); let properties = self.invoke_property_expressions(resource.properties.as_ref())?; let Some(dsc_resource) = self.discovery.find_resource(&resource.resource_type) else { return Err(DscError::ResourceNotFound(resource.resource_type.clone())); @@ -513,11 +498,12 @@ impl Configurator { trace!("{}", t!("configure.mod.exportInput", input = input)); let export_result = add_resource_export_results_to_configuration(dsc_resource, Some(dsc_resource), &mut conf, input.as_str())?; self.context.references.insert(format!("{}:{}", resource.resource_type, resource.name), serde_json::to_value(&export_result.actual_state)?); + progress.set_resource(&resource.name, &resource.resource_type, Some(&Value::Array(export_result.actual_state))); + progress.increment(1); } conf.metadata = Some(self.get_result_metadata(Operation::Export)); result.result = Some(conf); - std::mem::drop(pb_span); Ok(result) } diff --git a/dsc_lib/src/discovery/command_discovery.rs b/dsc_lib/src/discovery/command_discovery.rs index f763e124..74241ac2 100644 --- a/dsc_lib/src/discovery/command_discovery.rs +++ b/dsc_lib/src/discovery/command_discovery.rs @@ -7,8 +7,7 @@ use crate::dscresources::dscresource::{Capability, DscResource, ImplementedAs}; use crate::dscresources::resource_manifest::{import_manifest, validate_semver, Kind, ResourceManifest}; use crate::dscresources::command_resource::invoke_command; use crate::dscerror::DscError; -use crate::util::ProgressFormat; -use indicatif::ProgressStyle; +use crate::progress::{ProgressBar, ProgressFormat}; use linked_hash_map::LinkedHashMap; use regex::RegexBuilder; use rust_i18n::t; @@ -22,10 +21,9 @@ use std::fs::File; use std::io::BufReader; use std::path::{Path, PathBuf}; use std::str::FromStr; -use tracing::{debug, info, trace, warn, warn_span}; -use tracing_indicatif::span_ext::IndicatifSpanExt; +use tracing::{debug, info, trace, warn}; -use crate::util::{get_setting, ProgressBar}; +use crate::util::get_setting; use crate::util::get_exe_path; pub struct CommandDiscovery { @@ -169,7 +167,7 @@ impl Default for CommandDiscovery { impl ResourceDiscovery for CommandDiscovery { - fn discover_resources(&mut self, filter: &str) -> Result<(), DscError> { + fn discover_resources(&mut self, filter: &str, progress_format: ProgressFormat) -> Result<(), DscError> { info!("{}", t!("discovery.commandDiscovery.discoverResources", filter = filter)); let regex_str = convert_wildcard_to_regex(filter); @@ -180,12 +178,8 @@ impl ResourceDiscovery for CommandDiscovery { return Err(DscError::Operation(t!("discovery.commandDiscovery.invalidAdapterFilter").to_string())); }; - let pb_span = warn_span!(""); - pb_span.pb_set_style(&ProgressStyle::with_template( - "{spinner:.green} [{elapsed_precise:.cyan}] [{bar:40.cyan/blue}] {pos:>7}/{len:7} {msg:.yellow}" - )?); - pb_span.pb_set_message(t!("discovery.commandDiscovery.progressSearching").to_string().as_str()); - let _ = pb_span.enter(); + let mut progress = ProgressBar::new(1, progress_format)?; + progress.set_activity(t!("discovery.commandDiscovery.progressSearching").to_string().as_str()); let mut resources = BTreeMap::>::new(); let mut adapters = BTreeMap::>::new(); @@ -241,6 +235,7 @@ impl ResourceDiscovery for CommandDiscovery { } } } + progress.increment(1); debug!("Found {} matching non-adapter-based resources", resources.len()); self.resources = resources; self.adapters = adapters; @@ -249,7 +244,7 @@ impl ResourceDiscovery for CommandDiscovery { fn discover_adapted_resources(&mut self, name_filter: &str, adapter_filter: &str, progress_format: ProgressFormat) -> Result<(), DscError> { if self.resources.is_empty() && self.adapters.is_empty() { - self.discover_resources("*")?; + self.discover_resources("*", progress_format)?; } if self.adapters.is_empty() { @@ -272,20 +267,15 @@ impl ResourceDiscovery for CommandDiscovery { return Err(DscError::Operation("Could not build Regex filter for resource name".to_string())); }; - let mut pb_span = ProgressBar::new(progress_format == ProgressFormat::Json); - pb_span.pb_set_style(&ProgressStyle::with_template( - "{spinner:.green} [{elapsed_precise:.cyan}] [{bar:40.cyan/blue}] {pos:>7}/{len:7} {msg:.yellow}" - )?); - pb_span.pb_set_message("Searching for adapted resources"); - pb_span.pb_set_length(self.adapters.len() as u64); - pb_span.enter(); + let mut progress = ProgressBar::new(self.adapters.len() as u64, progress_format)?; + progress.set_activity("Searching for adapted resources"); let mut adapted_resources = BTreeMap::>::new(); let mut found_adapter: bool = false; for (adapter_name, adapters) in &self.adapters { for adapter in adapters { - pb_span.pb_inc(1); + progress.increment(1); if !regex.is_match(adapter_name) { continue; @@ -293,12 +283,8 @@ impl ResourceDiscovery for CommandDiscovery { found_adapter = true; info!("Enumerating resources for adapter '{}'", adapter_name); - let mut pb_adapter_span = ProgressBar::new(progress_format == ProgressFormat::Json); - pb_adapter_span.pb_set_style(&ProgressStyle::with_template( - "{spinner:.green} [{elapsed_precise:.cyan}] {msg:.white}" - )?); - pb_adapter_span.pb_set_message(format!("Enumerating resources for adapter '{adapter_name}'").as_str()); - pb_adapter_span.enter(); + let mut adapter_progress = ProgressBar::new(1, progress_format)?; + adapter_progress.set_activity(format!("Enumerating resources for adapter '{adapter_name}'").as_str()); let manifest = if let Some(manifest) = &adapter.manifest { if let Ok(manifest) = import_manifest(manifest.clone()) { manifest @@ -350,6 +336,7 @@ impl ResourceDiscovery for CommandDiscovery { }; } + adapter_progress.increment(1); debug!("Adapter '{}' listed {} resources", adapter_name, adapter_resources_count); } } @@ -369,11 +356,11 @@ impl ResourceDiscovery for CommandDiscovery { let mut resources = BTreeMap::>::new(); if adapter_name_filter.is_empty() { - self.discover_resources(type_name_filter)?; + self.discover_resources(type_name_filter, progress_format)?; resources.append(&mut self.resources); resources.append(&mut self.adapters); } else { - self.discover_resources("*")?; + self.discover_resources("*", progress_format)?; self.discover_adapted_resources(type_name_filter, adapter_name_filter, progress_format)?; // add/update found adapted resources to the lookup_table @@ -390,7 +377,7 @@ impl ResourceDiscovery for CommandDiscovery { fn find_resources(&mut self, required_resource_types: &[String], progress_format: ProgressFormat) -> Result, DscError> { debug!("Searching for resources: {:?}", required_resource_types); - self.discover_resources("*")?; + self.discover_resources("*", progress_format)?; // convert required_resource_types to lowercase to handle case-insentiive search let mut remaining_required_resource_types = required_resource_types.iter().map(|x| x.to_lowercase()).collect::>(); diff --git a/dsc_lib/src/discovery/discovery_trait.rs b/dsc_lib/src/discovery/discovery_trait.rs index 96911e75..e5eb43ac 100644 --- a/dsc_lib/src/discovery/discovery_trait.rs +++ b/dsc_lib/src/discovery/discovery_trait.rs @@ -1,11 +1,11 @@ // Copyright (c) Microsoft Corporation. // Licensed under the MIT License. -use crate::{dscresources::dscresource::DscResource, dscerror::DscError, util::ProgressFormat}; +use crate::{dscresources::dscresource::DscResource, dscerror::DscError, progress::ProgressFormat}; use std::collections::BTreeMap; pub trait ResourceDiscovery { - fn discover_resources(&mut self, filter: &str) -> Result<(), DscError>; + fn discover_resources(&mut self, filter: &str, progress_format: ProgressFormat) -> Result<(), DscError>; fn discover_adapted_resources(&mut self, name_filter: &str, adapter_filter: &str, progress_format: ProgressFormat) -> Result<(), DscError>; fn list_available_resources(&mut self, type_name_filter: &str, adapter_name_filter: &str, progress_format: ProgressFormat) -> Result>, DscError>; fn find_resources(&mut self, required_resource_types: &[String], progress_format: ProgressFormat) -> Result, DscError>; diff --git a/dsc_lib/src/discovery/mod.rs b/dsc_lib/src/discovery/mod.rs index c216d809..91a99165 100644 --- a/dsc_lib/src/discovery/mod.rs +++ b/dsc_lib/src/discovery/mod.rs @@ -5,7 +5,7 @@ mod command_discovery; mod discovery_trait; use crate::discovery::discovery_trait::ResourceDiscovery; -use crate::{dscresources::dscresource::DscResource, dscerror::DscError, util::ProgressFormat}; +use crate::{dscresources::dscresource::DscResource, dscerror::DscError, progress::ProgressFormat}; use std::collections::BTreeMap; use tracing::error; diff --git a/dsc_lib/src/lib.rs b/dsc_lib/src/lib.rs index bb61d557..ddc1b289 100644 --- a/dsc_lib/src/lib.rs +++ b/dsc_lib/src/lib.rs @@ -1,7 +1,8 @@ // Copyright (c) Microsoft Corporation. // Licensed under the MIT License. -use crate::util::ProgressFormat; +use crate::progress::ProgressFormat; + use configure::config_doc::ExecutionKind; use dscerror::DscError; use dscresources::{dscresource::{DscResource, Invoke}, invoke_result::{GetResult, SetResult, TestResult}}; @@ -13,6 +14,7 @@ pub mod dscerror; pub mod dscresources; pub mod functions; pub mod parser; +pub mod progress; pub mod util; i18n!("locales", fallback = "en-us"); diff --git a/dsc_lib/src/progress.rs b/dsc_lib/src/progress.rs new file mode 100644 index 00000000..e60dd6e7 --- /dev/null +++ b/dsc_lib/src/progress.rs @@ -0,0 +1,192 @@ +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. + +use crate::DscError; + +use clap::ValueEnum; +use indicatif::ProgressStyle; +use rust_i18n::t; +use serde::Serialize; +use serde_json::Value; +use tracing_indicatif::span_ext::IndicatifSpanExt; +use tracing::{trace, warn_span}; +use tracing::span::Span; +use uuid::Uuid; + +#[derive(Debug, Clone, Copy, PartialEq, Eq, ValueEnum)] +pub enum ProgressFormat { + /// If interactive, use a progress bar. If not interactive, no progress is shown. + Default, + /// No progress is shown. + None, + /// Show progress as JSON. + Json, +} + +#[derive(Default, Debug, Clone, Serialize)] +pub struct Progress { + /// The unique identifier for the operation. + pub id: String, + /// The activity being performed. + pub activity: Option, + /// The percentage of the operation that is complete from 0 to 100. + #[serde(rename = "percentComplete")] + pub percent_complete: u8, + /// The status of the operation. + #[serde(skip_serializing_if = "Option::is_none")] + pub status: Option, + /// The number of seconds remaining in the operation. + #[serde(rename = "secondsRemaining", skip_serializing_if = "Option::is_none")] + pub seconds_remaining: Option, + /// The name of the resource being operated on. + #[serde(rename = "resourceName", skip_serializing_if = "Option::is_none")] + pub resource_name: Option, + /// The type of the resource being operated on. + #[serde(rename = "resourceType", skip_serializing_if = "Option::is_none")] + pub resource_type: Option, + /// The result of the operation. + #[serde(skip_serializing_if = "Option::is_none")] + pub result: Option, +} + +impl Progress { + #[must_use] + pub fn new() -> Progress { + Progress { + id: Uuid::new_v4().to_string(), + ..Default::default() + } + } +} + +pub struct ProgressBar { + progress_value: Progress, + console_bar: Span, + item_count: u64, + item_position: u64, + format: ProgressFormat +} + +impl ProgressBar { + /// Create a `ProgressBar` object to update progress + /// + /// # Arguments + /// + /// * `item_count` - Total number of steps to complete. Use '1' if unknown and increment when complete. + /// * `format` - The `ProgressFormat` to render. + /// + /// # Returns + /// + /// A `ProgressBar` oject to update progress + /// + /// # Errors + /// + /// Fails if progress style for console rendering can't be set. + /// + pub fn new(item_count: u64, format: ProgressFormat) -> Result { + let bar = warn_span!(""); + if format == ProgressFormat::Default { + bar.pb_set_style(&ProgressStyle::with_template( + "{spinner:.green} [{elapsed_precise:.cyan}] [{bar:40.cyan/blue}] {pos:>7}/{len:7} {msg:.yellow}" + )?); + bar.pb_set_length(item_count); + let _guard = bar.enter(); + } + + Ok(ProgressBar { + progress_value: Progress::new(), + console_bar: bar, + item_count, + item_position: 0, + format + }) + } + + pub fn increment(&mut self, delta: u64) { + if self.format == ProgressFormat::None { + return; + } + + self.item_position += delta; + + if self.item_count > 0 { + self.progress_value.percent_complete = if self.item_position >= self.item_count { + 100 + } else { + u8::try_from((self.item_position * 100) / self.item_count).unwrap_or(100) + }; + } + + if self.format == ProgressFormat::Json { + self.write_json(); + } else { + self.console_bar.pb_inc(delta); + } + } + + pub fn set_resource(&mut self, name: &str, resource_type: &str, result: Option<&Value>) { + self.progress_value.resource_name = Some(name.to_string()); + self.progress_value.resource_type = Some(resource_type.to_string()); + self.progress_value.result = result.cloned(); + } + + pub fn set_activity(&mut self, activity: &str) { + match self.format { + ProgressFormat::Json => { + self.progress_value.activity = Some(activity.to_string()); + self.write_json(); + }, + ProgressFormat::Default => { + self.console_bar.pb_set_message(activity); + }, + ProgressFormat::None => {} + } + } + + pub fn set_length(&mut self, len: u64) { + match self.format { + ProgressFormat::Json => { + self.item_count = len; + if self.item_count > 0 { + self.progress_value.percent_complete = if self.item_position >= self.item_count { + 100 + } else { + u8::try_from((self.item_position * 100) / self.item_count).unwrap_or(100) + }; + } + }, + ProgressFormat::Default => { + self.console_bar.pb_set_length(len); + }, + ProgressFormat::None => {} + } + } + + pub fn set_position(&mut self, pos: u64) { + match self.format { + ProgressFormat::Json => { + self.item_position = pos; + if self.item_count > 0 { + self.progress_value.percent_complete = if self.item_position >= self.item_count { + 100 + } else { + u8::try_from((self.item_position * 100) / self.item_count).unwrap_or(100) + }; + self.write_json(); + } + }, + ProgressFormat::Default => { + self.console_bar.pb_set_position(pos); + }, + ProgressFormat::None => {} + } + } + + fn write_json(&self) { + if let Ok(json) = serde_json::to_string(&self.progress_value) { + eprintln!("{json}"); + } else { + trace!("{}", t!("progress.failedToSerialize", json = self.progress_value : {:?})); + } + } +} diff --git a/dsc_lib/src/util.rs b/dsc_lib/src/util.rs index e82504a4..671db87b 100644 --- a/dsc_lib/src/util.rs +++ b/dsc_lib/src/util.rs @@ -2,10 +2,8 @@ // Licensed under the MIT License. use crate::dscerror::DscError; -use clap::ValueEnum; use rust_i18n::t; use serde_json::Value; -use serde::Serialize; use std::fs; use std::fs::File; use std::io::BufReader; @@ -13,16 +11,6 @@ use std::path::PathBuf; use std::path::Path; use std::env; use tracing::debug; -use tracing_indicatif::span_ext::IndicatifSpanExt; -use tracing::warn_span; -use tracing::span::Span; -use indicatif::ProgressStyle; - -#[derive(Debug, Clone, Copy, PartialEq, Eq, ValueEnum)] -pub enum ProgressFormat { - Default, - Json, -} pub struct DscSettingValue { pub setting: Value, @@ -38,92 +26,6 @@ impl Default for DscSettingValue { } } -/// Only `activity` and `percent_complete` fields are mandatory for Progress messages -#[derive(Default, Debug, Clone, Serialize)] -pub struct Progress { - pub activity: String, - pub percent_complete: u16, - #[serde(default, skip_serializing_if = "Option::is_none")] - pub status: Option, - #[serde(default, skip_serializing_if = "Option::is_none")] - pub seconds_remaining: Option, -} - -pub struct ProgressBar { - progress_value: Progress, - ui_bar: Span, //IndicatifSpanExt - length: u64, - position: u64, - emit_json: bool -} - -impl ProgressBar { - pub fn new(emit_json: bool) -> ProgressBar { - ProgressBar { - progress_value: Progress::default(), - ui_bar: warn_span!(""), - length: 0, - position: 0, - emit_json - } - } - - #[allow(clippy::cast_possible_truncation)] - pub fn pb_inc(&mut self, delta: u64) { - self.ui_bar.pb_inc(delta); - self.position += delta; - if self.length > 0 { - self.progress_value.percent_complete = if self.position >= self.length {100} - else { ((self.position * 100) / self.length) as u16}; - - self.emit_json(); - } - } - - pub fn pb_set_style(&mut self, style: &ProgressStyle) { - self.ui_bar.pb_set_style(style); - } - - pub fn pb_set_message(&mut self, msg: &str) { - self.ui_bar.pb_set_message(msg); - self.progress_value.activity = msg.to_string(); - self.emit_json(); - } - - #[allow(clippy::cast_possible_truncation)] - pub fn pb_set_length(&mut self, len: u64) { - self.ui_bar.pb_set_length(len); - self.length = len; - if self.length > 0 { - self.progress_value.percent_complete = if self.position >= self.length {100} - else { ((self.position * 100) / self.length) as u16}; - } - } - - #[allow(clippy::cast_possible_truncation)] - pub fn pb_set_position(&mut self, pos: u64) { - self.ui_bar.pb_set_position(pos); - self.position = pos; - if self.length > 0 { - self.progress_value.percent_complete = if self.position >= self.length {100} - else { ((self.position * 100) / self.length) as u16}; - self.emit_json(); - } - } - - pub fn enter(&self) { - _ = self.ui_bar.enter(); - } - - fn emit_json(&self) { - if self.emit_json { - if let Ok(json) = serde_json::to_string(&self.progress_value) { - eprintln!("{json}"); - } - } - } -} - /// Return JSON string whether the input is JSON or YAML /// /// # Arguments diff --git a/tools/test_group_resource/Cargo.lock b/tools/test_group_resource/Cargo.lock index 04d20d2e..a3a615ea 100644 --- a/tools/test_group_resource/Cargo.lock +++ b/tools/test_group_resource/Cargo.lock @@ -444,6 +444,7 @@ dependencies = [ "tree-sitter", "tree-sitter-dscexpression", "tree-sitter-rust", + "uuid", ] [[package]] @@ -1844,9 +1845,12 @@ checksum = "06abde3611657adf66d383f00b093d7faecc7fa57071cce2578660c9f1010821" [[package]] name = "uuid" -version = "1.12.1" +version = "1.13.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b3758f5e68192bb96cc8f9b7e2c2cfdabb435499a28499a42f8f984092adad4b" +checksum = "ced87ca4be083373936a67f8de945faa23b6b42384bd5b64434850802c6dccd0" +dependencies = [ + "getrandom 0.3.1", +] [[package]] name = "uuid-simd" From bfc7c8e214655d3364b9a00ebacd964d243d417c Mon Sep 17 00:00:00 2001 From: Steve Lee Date: Mon, 17 Feb 2025 17:46:14 -0800 Subject: [PATCH 02/12] fix tests --- dsc/tests/dsc_config_get.tests.ps1 | 4 ++-- dsc/tests/dsc_resource_list.tests.ps1 | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/dsc/tests/dsc_config_get.tests.ps1 b/dsc/tests/dsc_config_get.tests.ps1 index fc7d0355..8bcee0a0 100644 --- a/dsc/tests/dsc_config_get.tests.ps1 +++ b/dsc/tests/dsc_config_get.tests.ps1 @@ -74,11 +74,11 @@ Describe 'dsc config get tests' { $jp = $line | ConvertFrom-Json if ($jp.activity) { # if line is a progress message $jp.id | Should -Not -BeNullOrEmpty - $jp.percent_complete | Should -BeIn (0..100) + $jp.percentComplete | Should -BeIn (0..100) $ProgressMessagesFound = $true } - if ($jp.percent_complete -eq 100 -and $jp.resourceType -eq 'Microsoft.DSC.Debug/Echo') { + if ($jp.percentComplete -eq 100 -and $jp.resourceType -eq 'Microsoft.DSC.Debug/Echo') { $ProgressResultFound = $true $jp.resourceName | Should -BeExactly 'Echo' $jp.result | Should -Not -BeNullOrEmpty diff --git a/dsc/tests/dsc_resource_list.tests.ps1 b/dsc/tests/dsc_resource_list.tests.ps1 index 8ac85255..e98516aa 100644 --- a/dsc/tests/dsc_resource_list.tests.ps1 +++ b/dsc/tests/dsc_resource_list.tests.ps1 @@ -67,7 +67,7 @@ Describe 'Tests for listing resources' { $jp = $line | ConvertFrom-Json if ($jp.activity) { # if line is a progress message $jp.id | Should -Not -BeNullOrEmpty - $jp.percent_complete | Should -BeIn (0..100) + $jp.percentComplete | Should -BeIn (0..100) $ProgressMessagesFound = $True } } From 74b8a2c60ad15c71c4d752b01e9e47d6b8b83394 Mon Sep 17 00:00:00 2001 From: Steve Lee Date: Tue, 18 Feb 2025 14:32:25 -0800 Subject: [PATCH 03/12] address Tess' feedback moving common code to a function and adding comments to pub functions --- dsc_lib/src/progress.rs | 61 +++++++++++++++++++++++++++++++---------- 1 file changed, 46 insertions(+), 15 deletions(-) diff --git a/dsc_lib/src/progress.rs b/dsc_lib/src/progress.rs index e60dd6e7..c4707007 100644 --- a/dsc_lib/src/progress.rs +++ b/dsc_lib/src/progress.rs @@ -68,6 +68,7 @@ pub struct ProgressBar { } impl ProgressBar { + /// Create a `ProgressBar` object to update progress /// /// # Arguments @@ -102,6 +103,12 @@ impl ProgressBar { }) } + /// Increment the progress bar by the specified amount and write the progress + /// + /// # Arguments + /// + /// * `delta` - The amount to increment the progress bar by + /// pub fn increment(&mut self, delta: u64) { if self.format == ProgressFormat::None { return; @@ -124,12 +131,26 @@ impl ProgressBar { } } + /// Set the resource being operated on and write the progress + /// + /// # Arguments + /// + /// * `name` - The name of the resource being operated on + /// * `resource_type` - The type of the resource being operated on + /// * `result` - The result of the operation + /// pub fn set_resource(&mut self, name: &str, resource_type: &str, result: Option<&Value>) { self.progress_value.resource_name = Some(name.to_string()); self.progress_value.resource_type = Some(resource_type.to_string()); self.progress_value.result = result.cloned(); } + /// Set the status of the operation and write the progress + /// + /// # Arguments + /// + /// * `status` - The status of the operation + /// pub fn set_activity(&mut self, activity: &str) { match self.format { ProgressFormat::Json => { @@ -143,17 +164,17 @@ impl ProgressBar { } } + /// Set the number of total items to complete + /// + /// # Arguments + /// + /// * `len` - The number of total items to complete + /// pub fn set_length(&mut self, len: u64) { match self.format { ProgressFormat::Json => { self.item_count = len; - if self.item_count > 0 { - self.progress_value.percent_complete = if self.item_position >= self.item_count { - 100 - } else { - u8::try_from((self.item_position * 100) / self.item_count).unwrap_or(100) - }; - } + self.set_percent_complete(); }, ProgressFormat::Default => { self.console_bar.pb_set_length(len); @@ -162,18 +183,18 @@ impl ProgressBar { } } + /// Set the position as progress through the items and write the progress + /// + /// # Arguments + /// + /// * `pos` - The position as progress through the items + /// pub fn set_position(&mut self, pos: u64) { match self.format { ProgressFormat::Json => { self.item_position = pos; - if self.item_count > 0 { - self.progress_value.percent_complete = if self.item_position >= self.item_count { - 100 - } else { - u8::try_from((self.item_position * 100) / self.item_count).unwrap_or(100) - }; - self.write_json(); - } + self.set_percent_complete(); + self.write_json(); }, ProgressFormat::Default => { self.console_bar.pb_set_position(pos); @@ -189,4 +210,14 @@ impl ProgressBar { trace!("{}", t!("progress.failedToSerialize", json = self.progress_value : {:?})); } } + + fn set_percent_complete(&mut self) { + if self.item_count > 0 { + self.progress_value.percent_complete = if self.item_position >= self.item_count { + 100 + } else { + u8::try_from((self.item_position * 100) / self.item_count).unwrap_or(100) + }; + } + } } From 3a6196ecf736d7f43209f08aad9b2cfe3758afb6 Mon Sep 17 00:00:00 2001 From: Steve Lee Date: Tue, 18 Feb 2025 20:38:01 -0800 Subject: [PATCH 04/12] Fix ordering of setting progress data and writing it --- dsc/tests/dsc_config_get.tests.ps1 | 25 +++++++++++----- dsc_lib/src/configure/mod.rs | 34 ++++++++++------------ dsc_lib/src/discovery/command_discovery.rs | 12 ++++---- dsc_lib/src/progress.rs | 26 ++--------------- 4 files changed, 41 insertions(+), 56 deletions(-) diff --git a/dsc/tests/dsc_config_get.tests.ps1 b/dsc/tests/dsc_config_get.tests.ps1 index 8bcee0a0..cb324953 100644 --- a/dsc/tests/dsc_config_get.tests.ps1 +++ b/dsc/tests/dsc_config_get.tests.ps1 @@ -60,16 +60,21 @@ Describe 'dsc config get tests' { $config_yaml = @" `$schema: https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/2024/04/config/document.json resources: - - name: Echo + - name: Echo 1 type: Microsoft.DSC.Debug/Echo properties: output: hello + - name: Echo 2 + type: Microsoft.DSC.Debug/Echo + properties: + output: world "@ $config_yaml | dsc --progress-format json config get -f - 2> $TestDrive/ErrorStream.txt $LASTEXITCODE | Should -Be 0 $lines = Get-Content $TestDrive/ErrorStream.txt $ProgressMessagesFound = $false - $ProgressResultFound = $false + $InstanceOneFound = $false + $InstanceTwoFound = $false foreach ($line in $lines) { $jp = $line | ConvertFrom-Json if ($jp.activity) { # if line is a progress message @@ -78,15 +83,19 @@ Describe 'dsc config get tests' { $ProgressMessagesFound = $true } - if ($jp.percentComplete -eq 100 -and $jp.resourceType -eq 'Microsoft.DSC.Debug/Echo') { - $ProgressResultFound = $true - $jp.resourceName | Should -BeExactly 'Echo' - $jp.result | Should -Not -BeNullOrEmpty - $jp.result.output | Should -BeExactly 'hello' + if ($null -ne $jp.result -and $jp.resourceType -eq 'Microsoft.DSC.Debug/Echo') { + if ($jp.resourceName -eq 'Echo 1') { + $InstanceOneFound = $true + $jp.result.actualState.output | Should -BeExactly 'hello' + } elseif ($jp.resourceName -eq 'Echo 2') { + $InstanceTwoFound = $true + $jp.result.actualState.output | Should -BeExactly 'world' + } } } $ProgressMessagesFound | Should -BeTrue - $ProgressResultFound | Should -BeTrue + $InstanceOneFound | Should -BeTrue + $InstanceTwoFound | Should -BeTrue } It 'contentVersion is ignored' { diff --git a/dsc_lib/src/configure/mod.rs b/dsc_lib/src/configure/mod.rs index f9e1e075..505573f5 100644 --- a/dsc_lib/src/configure/mod.rs +++ b/dsc_lib/src/configure/mod.rs @@ -232,8 +232,8 @@ impl Configurator { let resources = get_resource_invocation_order(&self.config, &mut self.statement_parser, &self.context)?; let mut progress = ProgressBar::new(resources.len() as u64, self.progress_format)?; for resource in resources { - progress.set_activity(format!("Get '{}'", resource.name).as_str()); progress.set_resource(&resource.name, &resource.resource_type, None); + progress.write_activity(format!("Get '{}'", resource.name).as_str()); let properties = self.invoke_property_expressions(resource.properties.as_ref())?; let Some(dsc_resource) = self.discovery.find_resource(&resource.resource_type) else { return Err(DscError::ResourceNotFound(resource.resource_type)); @@ -247,7 +247,6 @@ impl Configurator { match &get_result { GetResult::Resource(resource_result) => { self.context.references.insert(format!("{}:{}", resource.resource_type, resource.name), serde_json::to_value(&resource_result.actual_state)?); - progress.set_resource(&resource.name, &resource.resource_type, Some(&resource_result.actual_state)); }, GetResult::Group(group) => { let mut results = Vec::::new(); @@ -255,7 +254,6 @@ impl Configurator { results.push(serde_json::to_value(&result.result)?); } self.context.references.insert(format!("{}:{}", resource.resource_type, resource.name), Value::Array(results.clone())); - progress.set_resource(&resource.name, &resource.resource_type, Some(&Value::Array(results.clone()))); }, } let resource_result = config_result::ResourceGetResult { @@ -271,10 +269,11 @@ impl Configurator { ), name: resource.name.clone(), resource_type: resource.resource_type.clone(), - result: get_result, + result: get_result.clone(), }; result.results.push(resource_result); - progress.increment(1); + progress.set_resource(&resource.name, &resource.resource_type, Some(&serde_json::to_value(get_result)?)); + progress.write_increment(1); } result.metadata = Some( @@ -301,8 +300,8 @@ impl Configurator { let resources = get_resource_invocation_order(&self.config, &mut self.statement_parser, &self.context)?; let mut progress = ProgressBar::new(resources.len() as u64, self.progress_format)?; for resource in resources { - progress.set_activity(format!("Set '{}'", resource.name).as_str()); progress.set_resource(&resource.name, &resource.resource_type, None); + progress.write_activity(format!("Set '{}'", resource.name).as_str()); let properties = self.invoke_property_expressions(resource.properties.as_ref())?; let Some(dsc_resource) = self.discovery.find_resource(&resource.resource_type) else { return Err(DscError::ResourceNotFound(resource.resource_type)); @@ -370,7 +369,6 @@ impl Configurator { match &set_result { SetResult::Resource(resource_result) => { self.context.references.insert(format!("{}:{}", resource.resource_type, resource.name), serde_json::to_value(&resource_result.after_state)?); - progress.set_resource(&resource.name, &resource.resource_type, Some(&resource_result.after_state)); }, SetResult::Group(group) => { let mut results = Vec::::new(); @@ -378,10 +376,8 @@ impl Configurator { results.push(serde_json::to_value(&result.result)?); } self.context.references.insert(format!("{}:{}", resource.resource_type, resource.name), Value::Array(results.clone())); - progress.set_resource(&resource.name, &resource.resource_type, Some(&Value::Array(results.clone()))); }, } - let resource_result = config_result::ResourceSetResult { metadata: Some( Metadata { @@ -395,10 +391,11 @@ impl Configurator { ), name: resource.name.clone(), resource_type: resource.resource_type.clone(), - result: set_result, + result: set_result.clone(), }; result.results.push(resource_result); - progress.increment(1); + progress.set_resource(&resource.name, &resource.resource_type, Some(&serde_json::to_value(set_result)?)); + progress.write_increment(1); } result.metadata = Some( @@ -421,8 +418,8 @@ impl Configurator { let resources = get_resource_invocation_order(&self.config, &mut self.statement_parser, &self.context)?; let mut progress = ProgressBar::new(resources.len() as u64, self.progress_format)?; for resource in resources { - progress.set_activity(format!("Test '{}'", resource.name).as_str()); progress.set_resource(&resource.name, &resource.resource_type, None); + progress.write_activity(format!("Test '{}'", resource.name).as_str()); let properties = self.invoke_property_expressions(resource.properties.as_ref())?; let Some(dsc_resource) = self.discovery.find_resource(&resource.resource_type) else { return Err(DscError::ResourceNotFound(resource.resource_type)); @@ -436,7 +433,6 @@ impl Configurator { match &test_result { TestResult::Resource(resource_test_result) => { self.context.references.insert(format!("{}:{}", resource.resource_type, resource.name), serde_json::to_value(&resource_test_result.actual_state)?); - progress.set_resource(&resource.name, &resource.resource_type, Some(&resource_test_result.actual_state)); }, TestResult::Group(group) => { let mut results = Vec::::new(); @@ -444,7 +440,6 @@ impl Configurator { results.push(serde_json::to_value(&result.result)?); } self.context.references.insert(format!("{}:{}", resource.resource_type, resource.name), Value::Array(results.clone())); - progress.set_resource(&resource.name, &resource.resource_type, Some(&Value::Array(results.clone()))); }, } let resource_result = config_result::ResourceTestResult { @@ -460,10 +455,11 @@ impl Configurator { ), name: resource.name.clone(), resource_type: resource.resource_type.clone(), - result: test_result, + result: test_result.clone(), }; result.results.push(resource_result); - progress.increment(1); + progress.set_resource(&resource.name, &resource.resource_type, Some(&serde_json::to_value(test_result)?)); + progress.write_increment(1); } result.metadata = Some( @@ -488,8 +484,8 @@ impl Configurator { let mut progress = ProgressBar::new(self.config.resources.len() as u64, self.progress_format)?; let resources = self.config.resources.clone(); for resource in &resources { - progress.set_activity(format!("Export '{}'", resource.name).as_str()); progress.set_resource(&resource.name, &resource.resource_type, None); + progress.write_activity(format!("Export '{}'", resource.name).as_str()); let properties = self.invoke_property_expressions(resource.properties.as_ref())?; let Some(dsc_resource) = self.discovery.find_resource(&resource.resource_type) else { return Err(DscError::ResourceNotFound(resource.resource_type.clone())); @@ -498,8 +494,8 @@ impl Configurator { trace!("{}", t!("configure.mod.exportInput", input = input)); let export_result = add_resource_export_results_to_configuration(dsc_resource, Some(dsc_resource), &mut conf, input.as_str())?; self.context.references.insert(format!("{}:{}", resource.resource_type, resource.name), serde_json::to_value(&export_result.actual_state)?); - progress.set_resource(&resource.name, &resource.resource_type, Some(&Value::Array(export_result.actual_state))); - progress.increment(1); + progress.set_resource(&resource.name, &resource.resource_type, Some(&serde_json::to_value(export_result)?)); + progress.write_increment(1); } conf.metadata = Some(self.get_result_metadata(Operation::Export)); diff --git a/dsc_lib/src/discovery/command_discovery.rs b/dsc_lib/src/discovery/command_discovery.rs index 74241ac2..5198fdc0 100644 --- a/dsc_lib/src/discovery/command_discovery.rs +++ b/dsc_lib/src/discovery/command_discovery.rs @@ -179,7 +179,7 @@ impl ResourceDiscovery for CommandDiscovery { }; let mut progress = ProgressBar::new(1, progress_format)?; - progress.set_activity(t!("discovery.commandDiscovery.progressSearching").to_string().as_str()); + progress.write_activity(t!("discovery.commandDiscovery.progressSearching").to_string().as_str()); let mut resources = BTreeMap::>::new(); let mut adapters = BTreeMap::>::new(); @@ -235,7 +235,7 @@ impl ResourceDiscovery for CommandDiscovery { } } } - progress.increment(1); + progress.write_increment(1); debug!("Found {} matching non-adapter-based resources", resources.len()); self.resources = resources; self.adapters = adapters; @@ -268,14 +268,14 @@ impl ResourceDiscovery for CommandDiscovery { }; let mut progress = ProgressBar::new(self.adapters.len() as u64, progress_format)?; - progress.set_activity("Searching for adapted resources"); + progress.write_activity("Searching for adapted resources"); let mut adapted_resources = BTreeMap::>::new(); let mut found_adapter: bool = false; for (adapter_name, adapters) in &self.adapters { for adapter in adapters { - progress.increment(1); + progress.write_increment(1); if !regex.is_match(adapter_name) { continue; @@ -284,7 +284,7 @@ impl ResourceDiscovery for CommandDiscovery { found_adapter = true; info!("Enumerating resources for adapter '{}'", adapter_name); let mut adapter_progress = ProgressBar::new(1, progress_format)?; - adapter_progress.set_activity(format!("Enumerating resources for adapter '{adapter_name}'").as_str()); + adapter_progress.write_activity(format!("Enumerating resources for adapter '{adapter_name}'").as_str()); let manifest = if let Some(manifest) = &adapter.manifest { if let Ok(manifest) = import_manifest(manifest.clone()) { manifest @@ -336,7 +336,7 @@ impl ResourceDiscovery for CommandDiscovery { }; } - adapter_progress.increment(1); + adapter_progress.write_increment(1); debug!("Adapter '{}' listed {} resources", adapter_name, adapter_resources_count); } } diff --git a/dsc_lib/src/progress.rs b/dsc_lib/src/progress.rs index c4707007..4cd0007d 100644 --- a/dsc_lib/src/progress.rs +++ b/dsc_lib/src/progress.rs @@ -109,7 +109,7 @@ impl ProgressBar { /// /// * `delta` - The amount to increment the progress bar by /// - pub fn increment(&mut self, delta: u64) { + pub fn write_increment(&mut self, delta: u64) { if self.format == ProgressFormat::None { return; } @@ -131,7 +131,7 @@ impl ProgressBar { } } - /// Set the resource being operated on and write the progress + /// Set the resource being operated on /// /// # Arguments /// @@ -151,7 +151,7 @@ impl ProgressBar { /// /// * `status` - The status of the operation /// - pub fn set_activity(&mut self, activity: &str) { + pub fn write_activity(&mut self, activity: &str) { match self.format { ProgressFormat::Json => { self.progress_value.activity = Some(activity.to_string()); @@ -183,26 +183,6 @@ impl ProgressBar { } } - /// Set the position as progress through the items and write the progress - /// - /// # Arguments - /// - /// * `pos` - The position as progress through the items - /// - pub fn set_position(&mut self, pos: u64) { - match self.format { - ProgressFormat::Json => { - self.item_position = pos; - self.set_percent_complete(); - self.write_json(); - }, - ProgressFormat::Default => { - self.console_bar.pb_set_position(pos); - }, - ProgressFormat::None => {} - } - } - fn write_json(&self) { if let Ok(json) = serde_json::to_string(&self.progress_value) { eprintln!("{json}"); From 12ac4a69365152fa5aed487161ddd895041d3264 Mon Sep 17 00:00:00 2001 From: Steve Lee Date: Wed, 19 Feb 2025 12:40:14 -0800 Subject: [PATCH 05/12] Update dsc_lib/src/progress.rs Co-authored-by: Tess Gauthier --- dsc_lib/src/progress.rs | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/dsc_lib/src/progress.rs b/dsc_lib/src/progress.rs index 4cd0007d..dddba6f4 100644 --- a/dsc_lib/src/progress.rs +++ b/dsc_lib/src/progress.rs @@ -116,13 +116,7 @@ impl ProgressBar { self.item_position += delta; - if self.item_count > 0 { - self.progress_value.percent_complete = if self.item_position >= self.item_count { - 100 - } else { - u8::try_from((self.item_position * 100) / self.item_count).unwrap_or(100) - }; - } + self.set_percent_complete(); if self.format == ProgressFormat::Json { self.write_json(); From cc86557b4924095759ece98fcebbd588ab7dae33 Mon Sep 17 00:00:00 2001 From: Steve Lee Date: Wed, 19 Feb 2025 12:50:40 -0800 Subject: [PATCH 06/12] encapsulate set_percent_complete() into write_json() since it's only needed there --- dsc_lib/src/progress.rs | 20 +++++++------------- 1 file changed, 7 insertions(+), 13 deletions(-) diff --git a/dsc_lib/src/progress.rs b/dsc_lib/src/progress.rs index dddba6f4..cd86a3a2 100644 --- a/dsc_lib/src/progress.rs +++ b/dsc_lib/src/progress.rs @@ -115,9 +115,6 @@ impl ProgressBar { } self.item_position += delta; - - self.set_percent_complete(); - if self.format == ProgressFormat::Json { self.write_json(); } else { @@ -168,7 +165,6 @@ impl ProgressBar { match self.format { ProgressFormat::Json => { self.item_count = len; - self.set_percent_complete(); }, ProgressFormat::Default => { self.console_bar.pb_set_length(len); @@ -177,15 +173,7 @@ impl ProgressBar { } } - fn write_json(&self) { - if let Ok(json) = serde_json::to_string(&self.progress_value) { - eprintln!("{json}"); - } else { - trace!("{}", t!("progress.failedToSerialize", json = self.progress_value : {:?})); - } - } - - fn set_percent_complete(&mut self) { + fn write_json(&mut self) { if self.item_count > 0 { self.progress_value.percent_complete = if self.item_position >= self.item_count { 100 @@ -193,5 +181,11 @@ impl ProgressBar { u8::try_from((self.item_position * 100) / self.item_count).unwrap_or(100) }; } + + if let Ok(json) = serde_json::to_string(&self.progress_value) { + eprintln!("{json}"); + } else { + trace!("{}", t!("progress.failedToSerialize", json = self.progress_value : {:?})); + } } } From 79be7790f3ff5b6ea92c1606937c8100fa2f3910 Mon Sep 17 00:00:00 2001 From: Steve Lee Date: Wed, 19 Feb 2025 21:21:45 -0800 Subject: [PATCH 07/12] Removed percentComplete and added totalItems and completedItems, add failed property to progress --- dsc/tests/dsc_config_get.tests.ps1 | 50 ++++++++++++++++++- dsc_lib/src/configure/mod.rs | 77 ++++++++++++++++++++++++------ dsc_lib/src/progress.rs | 67 +++++++++++++++----------- 3 files changed, 151 insertions(+), 43 deletions(-) diff --git a/dsc/tests/dsc_config_get.tests.ps1 b/dsc/tests/dsc_config_get.tests.ps1 index cb324953..8e9aa439 100644 --- a/dsc/tests/dsc_config_get.tests.ps1 +++ b/dsc/tests/dsc_config_get.tests.ps1 @@ -79,7 +79,8 @@ Describe 'dsc config get tests' { $jp = $line | ConvertFrom-Json if ($jp.activity) { # if line is a progress message $jp.id | Should -Not -BeNullOrEmpty - $jp.percentComplete | Should -BeIn (0..100) + $jp.totalItems | Should -Not -BeNullOrEmpty + $jp.completedItems | Should -Not -BeNullOrEmpty $ProgressMessagesFound = $true } @@ -98,6 +99,53 @@ Describe 'dsc config get tests' { $InstanceTwoFound | Should -BeTrue } + It 'json progress returns correctly for failed resource' { + $config_yaml = @' + $schema: https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/2024/04/config/document.json + resources: + - name: Echo 1 + type: Microsoft.DSC.Debug/Echo + properties: + output: hello + - name: ErrorTest + type: Test/ExitCode + properties: + exitCode: 1 +'@ + dsc --progress-format json --trace-format json config get -i $config_yaml 2> $TestDrive/ErrorStream.txt + $LASTEXITCODE | Should -Be 2 + $lines = Get-Content $TestDrive/ErrorStream.txt + $ProgressMessagesFound = $false + $InstanceOneFound = $false + $InstanceTwoFound = $false + foreach ($line in $lines) { + $jp = $line | ConvertFrom-Json + if ($jp.activity) { # if line is a progress message + $jp.id | Should -Not -BeNullOrEmpty + $jp.totalItems | Should -Not -BeNullOrEmpty + $jp.completedItems | Should -Not -BeNullOrEmpty + $ProgressMessagesFound = $true + } + + if ($null -ne $jp.result -and $jp.resourceType -eq 'Microsoft.DSC.Debug/Echo') { + if ($jp.resourceName -eq 'Echo 1') { + $InstanceOneFound = $true + $jp.result.actualState.output | Should -BeExactly 'hello' + $jp.failed | Should -BeNullOrEmpty + } + } + elseif ($null -ne $jp.failed -and $jp.resourceType -eq 'Test/ExitCode') { + if ($jp.resourceName -eq 'ErrorTest') { + $InstanceTwoFound = $true + $jp.result | Should -BeNullOrEmpty + } + } + } + $ProgressMessagesFound | Should -BeTrue + $InstanceOneFound | Should -BeTrue + $InstanceTwoFound | Should -BeTrue + } + It 'contentVersion is ignored' { $config_yaml = @" `$schema: https://raw.githubusercontent.com/PowerShell/DSC/main/schemas/2024/04/config/document.json diff --git a/dsc_lib/src/configure/mod.rs b/dsc_lib/src/configure/mod.rs index 505573f5..14f5b80e 100644 --- a/dsc_lib/src/configure/mod.rs +++ b/dsc_lib/src/configure/mod.rs @@ -232,7 +232,7 @@ impl Configurator { let resources = get_resource_invocation_order(&self.config, &mut self.statement_parser, &self.context)?; let mut progress = ProgressBar::new(resources.len() as u64, self.progress_format)?; for resource in resources { - progress.set_resource(&resource.name, &resource.resource_type, None); + progress.set_resource(&resource.name, &resource.resource_type); progress.write_activity(format!("Get '{}'", resource.name).as_str()); let properties = self.invoke_property_expressions(resource.properties.as_ref())?; let Some(dsc_resource) = self.discovery.find_resource(&resource.resource_type) else { @@ -242,7 +242,14 @@ impl Configurator { let filter = add_metadata(&dsc_resource.kind, properties)?; trace!("filter: {filter}"); let start_datetime = chrono::Local::now(); - let get_result = dsc_resource.get(&filter)?; + let get_result = match dsc_resource.get(&filter) { + Ok(result) => result, + Err(e) => { + progress.set_failed(); + progress.write_increment(1); + return Err(e); + }, + }; let end_datetime = chrono::Local::now(); match &get_result { GetResult::Resource(resource_result) => { @@ -272,7 +279,7 @@ impl Configurator { result: get_result.clone(), }; result.results.push(resource_result); - progress.set_resource(&resource.name, &resource.resource_type, Some(&serde_json::to_value(get_result)?)); + progress.set_result(&serde_json::to_value(get_result)?); progress.write_increment(1); } @@ -295,12 +302,13 @@ impl Configurator { /// # Errors /// /// This function will return an error if the underlying resource fails. + #[allow(clippy::too_many_lines)] pub fn invoke_set(&mut self, skip_test: bool) -> Result { let mut result = ConfigurationSetResult::new(); let resources = get_resource_invocation_order(&self.config, &mut self.statement_parser, &self.context)?; let mut progress = ProgressBar::new(resources.len() as u64, self.progress_format)?; for resource in resources { - progress.set_resource(&resource.name, &resource.resource_type, None); + progress.set_resource(&resource.name, &resource.resource_type); progress.write_activity(format!("Set '{}'", resource.name).as_str()); let properties = self.invoke_property_expressions(resource.properties.as_ref())?; let Some(dsc_resource) = self.discovery.find_resource(&resource.resource_type) else { @@ -331,7 +339,14 @@ impl Configurator { if exist || dsc_resource.capabilities.contains(&Capability::SetHandlesExist) { debug!("{}", t!("configure.mod.handlesExist")); start_datetime = chrono::Local::now(); - set_result = dsc_resource.set(&desired, skip_test, &self.context.execution_type)?; + set_result = match dsc_resource.set(&desired, skip_test, &self.context.execution_type) { + Ok(result) => result, + Err(e) => { + progress.set_failed(); + progress.write_increment(1); + return Err(e); + }, + }; end_datetime = chrono::Local::now(); } else if dsc_resource.capabilities.contains(&Capability::Delete) { if self.context.execution_type == ExecutionKind::WhatIf { @@ -339,10 +354,28 @@ impl Configurator { return Err(DscError::NotSupported(t!("configure.mod.whatIfNotSupportedForDelete").to_string())); } debug!("{}", t!("configure.mod.implementsDelete")); - let before_result = dsc_resource.get(&desired)?; + let before_result = match dsc_resource.get(&desired) { + Ok(result) => result, + Err(e) => { + progress.set_failed(); + progress.write_increment(1); + return Err(e); + }, + }; start_datetime = chrono::Local::now(); - dsc_resource.delete(&desired)?; - let after_result = dsc_resource.get(&desired)?; + if let Err(err) = dsc_resource.delete(&desired) { + progress.set_failed(); + progress.write_increment(1); + return Err(err); + } + let after_result = match dsc_resource.get(&desired) { + Ok(result) => result, + Err(e) => { + progress.set_failed(); + progress.write_increment(1); + return Err(e); + }, + }; // convert get result to set result set_result = match before_result { GetResult::Resource(before_response) => { @@ -394,7 +427,7 @@ impl Configurator { result: set_result.clone(), }; result.results.push(resource_result); - progress.set_resource(&resource.name, &resource.resource_type, Some(&serde_json::to_value(set_result)?)); + progress.set_result(&serde_json::to_value(set_result)?); progress.write_increment(1); } @@ -418,7 +451,7 @@ impl Configurator { let resources = get_resource_invocation_order(&self.config, &mut self.statement_parser, &self.context)?; let mut progress = ProgressBar::new(resources.len() as u64, self.progress_format)?; for resource in resources { - progress.set_resource(&resource.name, &resource.resource_type, None); + progress.set_resource(&resource.name, &resource.resource_type); progress.write_activity(format!("Test '{}'", resource.name).as_str()); let properties = self.invoke_property_expressions(resource.properties.as_ref())?; let Some(dsc_resource) = self.discovery.find_resource(&resource.resource_type) else { @@ -428,7 +461,14 @@ impl Configurator { let expected = add_metadata(&dsc_resource.kind, properties)?; trace!("{}", t!("configure.mod.expectedState", state = expected)); let start_datetime = chrono::Local::now(); - let test_result = dsc_resource.test(&expected)?; + let test_result = match dsc_resource.test(&expected) { + Ok(result) => result, + Err(e) => { + progress.set_failed(); + progress.write_increment(1); + return Err(e); + }, + }; let end_datetime = chrono::Local::now(); match &test_result { TestResult::Resource(resource_test_result) => { @@ -458,7 +498,7 @@ impl Configurator { result: test_result.clone(), }; result.results.push(resource_result); - progress.set_resource(&resource.name, &resource.resource_type, Some(&serde_json::to_value(test_result)?)); + progress.set_result( &serde_json::to_value(test_result)?); progress.write_increment(1); } @@ -484,7 +524,7 @@ impl Configurator { let mut progress = ProgressBar::new(self.config.resources.len() as u64, self.progress_format)?; let resources = self.config.resources.clone(); for resource in &resources { - progress.set_resource(&resource.name, &resource.resource_type, None); + progress.set_resource(&resource.name, &resource.resource_type); progress.write_activity(format!("Export '{}'", resource.name).as_str()); let properties = self.invoke_property_expressions(resource.properties.as_ref())?; let Some(dsc_resource) = self.discovery.find_resource(&resource.resource_type) else { @@ -492,9 +532,16 @@ impl Configurator { }; let input = add_metadata(&dsc_resource.kind, properties)?; trace!("{}", t!("configure.mod.exportInput", input = input)); - let export_result = add_resource_export_results_to_configuration(dsc_resource, Some(dsc_resource), &mut conf, input.as_str())?; + let export_result = match add_resource_export_results_to_configuration(dsc_resource, Some(dsc_resource), &mut conf, input.as_str()) { + Ok(result) => result, + Err(e) => { + progress.set_failed(); + progress.write_increment(1); + return Err(e); + }, + }; self.context.references.insert(format!("{}:{}", resource.resource_type, resource.name), serde_json::to_value(&export_result.actual_state)?); - progress.set_resource(&resource.name, &resource.resource_type, Some(&serde_json::to_value(export_result)?)); + progress.set_result(&serde_json::to_value(export_result)?); progress.write_increment(1); } diff --git a/dsc_lib/src/progress.rs b/dsc_lib/src/progress.rs index cd86a3a2..8a0f20c7 100644 --- a/dsc_lib/src/progress.rs +++ b/dsc_lib/src/progress.rs @@ -24,36 +24,42 @@ pub enum ProgressFormat { } #[derive(Default, Debug, Clone, Serialize)] +#[serde(rename_all = "camelCase")] pub struct Progress { /// The unique identifier for the operation. pub id: String, /// The activity being performed. pub activity: Option, - /// The percentage of the operation that is complete from 0 to 100. - #[serde(rename = "percentComplete")] - pub percent_complete: u8, + /// The total number of items to process. + pub total_items: u64, + /// The number of items processed. + pub completed_items: u64, /// The status of the operation. #[serde(skip_serializing_if = "Option::is_none")] pub status: Option, /// The number of seconds remaining in the operation. - #[serde(rename = "secondsRemaining", skip_serializing_if = "Option::is_none")] + #[serde(skip_serializing_if = "Option::is_none")] pub seconds_remaining: Option, /// The name of the resource being operated on. - #[serde(rename = "resourceName", skip_serializing_if = "Option::is_none")] + #[serde(skip_serializing_if = "Option::is_none")] pub resource_name: Option, /// The type of the resource being operated on. - #[serde(rename = "resourceType", skip_serializing_if = "Option::is_none")] + #[serde(skip_serializing_if = "Option::is_none")] pub resource_type: Option, /// The result of the operation. #[serde(skip_serializing_if = "Option::is_none")] pub result: Option, + /// Indicates if the operation failed. + #[serde(skip_serializing_if = "Option::is_none")] + pub failed: Option, } impl Progress { #[must_use] - pub fn new() -> Progress { + pub fn new(total_items: u64) -> Progress { Progress { id: Uuid::new_v4().to_string(), + total_items, ..Default::default() } } @@ -62,8 +68,6 @@ impl Progress { pub struct ProgressBar { progress_value: Progress, console_bar: Span, - item_count: u64, - item_position: u64, format: ProgressFormat } @@ -84,21 +88,19 @@ impl ProgressBar { /// /// Fails if progress style for console rendering can't be set. /// - pub fn new(item_count: u64, format: ProgressFormat) -> Result { + pub fn new(total_items: u64, format: ProgressFormat) -> Result { let bar = warn_span!(""); if format == ProgressFormat::Default { bar.pb_set_style(&ProgressStyle::with_template( "{spinner:.green} [{elapsed_precise:.cyan}] [{bar:40.cyan/blue}] {pos:>7}/{len:7} {msg:.yellow}" )?); - bar.pb_set_length(item_count); + bar.pb_set_length(total_items); let _guard = bar.enter(); } Ok(ProgressBar { - progress_value: Progress::new(), + progress_value: Progress::new(total_items), console_bar: bar, - item_count, - item_position: 0, format }) } @@ -114,7 +116,7 @@ impl ProgressBar { return; } - self.item_position += delta; + self.progress_value.completed_items += delta; if self.format == ProgressFormat::Json { self.write_json(); } else { @@ -130,10 +132,29 @@ impl ProgressBar { /// * `resource_type` - The type of the resource being operated on /// * `result` - The result of the operation /// - pub fn set_resource(&mut self, name: &str, resource_type: &str, result: Option<&Value>) { + pub fn set_resource(&mut self, name: &str, resource_type: &str) { self.progress_value.resource_name = Some(name.to_string()); self.progress_value.resource_type = Some(resource_type.to_string()); - self.progress_value.result = result.cloned(); + self.progress_value.result = None; + self.progress_value.failed = None; + } + + /// Set the result of the operation. This will clear any error. + /// + /// # Arguments + /// + /// * `result` - The result of the operation + /// + pub fn set_result(&mut self, result: &Value) { + self.progress_value.failed = None; + self.progress_value.result = Some(result.clone()); + } + + /// Indicate that the operation failed. This will clear any result. + /// + pub fn set_failed(&mut self) { + self.progress_value.result = None; + self.progress_value.failed = Some(true); } /// Set the status of the operation and write the progress @@ -161,10 +182,10 @@ impl ProgressBar { /// /// * `len` - The number of total items to complete /// - pub fn set_length(&mut self, len: u64) { + pub fn set_total_items(&mut self, len: u64) { match self.format { ProgressFormat::Json => { - self.item_count = len; + self.progress_value.total_items = len; }, ProgressFormat::Default => { self.console_bar.pb_set_length(len); @@ -174,14 +195,6 @@ impl ProgressBar { } fn write_json(&mut self) { - if self.item_count > 0 { - self.progress_value.percent_complete = if self.item_position >= self.item_count { - 100 - } else { - u8::try_from((self.item_position * 100) / self.item_count).unwrap_or(100) - }; - } - if let Ok(json) = serde_json::to_string(&self.progress_value) { eprintln!("{json}"); } else { From 8a1a70a477dca224228e45a53189407ee98fa47a Mon Sep 17 00:00:00 2001 From: Steve Lee Date: Wed, 19 Feb 2025 21:50:18 -0800 Subject: [PATCH 08/12] fix test --- dsc/tests/dsc_resource_list.tests.ps1 | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/dsc/tests/dsc_resource_list.tests.ps1 b/dsc/tests/dsc_resource_list.tests.ps1 index e98516aa..4e2e00c0 100644 --- a/dsc/tests/dsc_resource_list.tests.ps1 +++ b/dsc/tests/dsc_resource_list.tests.ps1 @@ -67,7 +67,8 @@ Describe 'Tests for listing resources' { $jp = $line | ConvertFrom-Json if ($jp.activity) { # if line is a progress message $jp.id | Should -Not -BeNullOrEmpty - $jp.percentComplete | Should -BeIn (0..100) + $jp.totalItems | Should -Not -BeNullOrEmpty + $jp.completedItems | Should -Not -BeNullOrEmpty $ProgressMessagesFound = $True } } From ac862bcedbeec78af056eae2c1c7b434a9bcf93f Mon Sep 17 00:00:00 2001 From: Steve Lee Date: Thu, 20 Feb 2025 13:57:12 -0800 Subject: [PATCH 09/12] change to a failure object that contains exitCode and message --- dsc/tests/dsc_config_get.tests.ps1 | 6 +++-- dsc_lib/src/configure/mod.rs | 38 ++++++++++++++++++++++-------- dsc_lib/src/progress.rs | 19 ++++++++++----- 3 files changed, 45 insertions(+), 18 deletions(-) diff --git a/dsc/tests/dsc_config_get.tests.ps1 b/dsc/tests/dsc_config_get.tests.ps1 index 8e9aa439..07c1b7d7 100644 --- a/dsc/tests/dsc_config_get.tests.ps1 +++ b/dsc/tests/dsc_config_get.tests.ps1 @@ -110,7 +110,7 @@ Describe 'dsc config get tests' { - name: ErrorTest type: Test/ExitCode properties: - exitCode: 1 + exitCode: 8 '@ dsc --progress-format json --trace-format json config get -i $config_yaml 2> $TestDrive/ErrorStream.txt $LASTEXITCODE | Should -Be 2 @@ -134,10 +134,12 @@ Describe 'dsc config get tests' { $jp.failed | Should -BeNullOrEmpty } } - elseif ($null -ne $jp.failed -and $jp.resourceType -eq 'Test/ExitCode') { + elseif ($null -ne $jp.failure -and $jp.resourceType -eq 'Test/ExitCode') { if ($jp.resourceName -eq 'ErrorTest') { $InstanceTwoFound = $true $jp.result | Should -BeNullOrEmpty + $jp.failure.exitCode | Should -Be 8 + $jp.failure.message | Should -Not -BeNullOrEmpty } } } diff --git a/dsc_lib/src/configure/mod.rs b/dsc_lib/src/configure/mod.rs index 14f5b80e..153f6407 100644 --- a/dsc_lib/src/configure/mod.rs +++ b/dsc_lib/src/configure/mod.rs @@ -13,7 +13,7 @@ use crate::dscresources::{ use crate::DscResource; use crate::discovery::Discovery; use crate::parser::Statement; -use crate::progress::{ProgressBar, ProgressFormat}; +use crate::progress::{Failure, ProgressBar, ProgressFormat}; use self::context::Context; use self::config_doc::{Configuration, DataType, MicrosoftDscMetadata, Operation, SecurityContextKind}; use self::depends_on::get_resource_invocation_order; @@ -245,7 +245,7 @@ impl Configurator { let get_result = match dsc_resource.get(&filter) { Ok(result) => result, Err(e) => { - progress.set_failed(); + progress.set_failure(get_failure_from_error(&e)); progress.write_increment(1); return Err(e); }, @@ -342,7 +342,7 @@ impl Configurator { set_result = match dsc_resource.set(&desired, skip_test, &self.context.execution_type) { Ok(result) => result, Err(e) => { - progress.set_failed(); + progress.set_failure(get_failure_from_error(&e)); progress.write_increment(1); return Err(e); }, @@ -357,21 +357,21 @@ impl Configurator { let before_result = match dsc_resource.get(&desired) { Ok(result) => result, Err(e) => { - progress.set_failed(); + progress.set_failure(get_failure_from_error(&e)); progress.write_increment(1); return Err(e); }, }; start_datetime = chrono::Local::now(); - if let Err(err) = dsc_resource.delete(&desired) { - progress.set_failed(); + if let Err(e) = dsc_resource.delete(&desired) { + progress.set_failure(get_failure_from_error(&e)); progress.write_increment(1); - return Err(err); + return Err(e); } let after_result = match dsc_resource.get(&desired) { Ok(result) => result, Err(e) => { - progress.set_failed(); + progress.set_failure(get_failure_from_error(&e)); progress.write_increment(1); return Err(e); }, @@ -464,7 +464,7 @@ impl Configurator { let test_result = match dsc_resource.test(&expected) { Ok(result) => result, Err(e) => { - progress.set_failed(); + progress.set_failure(get_failure_from_error(&e)); progress.write_increment(1); return Err(e); }, @@ -535,7 +535,7 @@ impl Configurator { let export_result = match add_resource_export_results_to_configuration(dsc_resource, Some(dsc_resource), &mut conf, input.as_str()) { Ok(result) => result, Err(e) => { - progress.set_failed(); + progress.set_failure(get_failure_from_error(&e)); progress.write_increment(1); return Err(e); }, @@ -792,3 +792,21 @@ impl Configurator { Ok(Some(result)) } } + +fn get_failure_from_error(err: &DscError) -> Option { + match err { + DscError::CommandExit(_resource, exit_code, reason) => { + Some(Failure { + message: reason.to_string(), + exit_code: exit_code.clone(), + }) + }, + DscError::CommandExitFromManifest(_resource, exit_code, reason) => { + Some(Failure { + message: reason.to_string(), + exit_code: exit_code.clone(), + }) + }, + _ => None, + } +} diff --git a/dsc_lib/src/progress.rs b/dsc_lib/src/progress.rs index 8a0f20c7..41c4ae54 100644 --- a/dsc_lib/src/progress.rs +++ b/dsc_lib/src/progress.rs @@ -23,6 +23,13 @@ pub enum ProgressFormat { Json, } +#[derive(Default, Debug, Clone, Serialize)] +#[serde(rename_all = "camelCase")] +pub struct Failure { + pub message: String, + pub exit_code: i32, +} + #[derive(Default, Debug, Clone, Serialize)] #[serde(rename_all = "camelCase")] pub struct Progress { @@ -49,9 +56,9 @@ pub struct Progress { /// The result of the operation. #[serde(skip_serializing_if = "Option::is_none")] pub result: Option, - /// Indicates if the operation failed. + /// Failure information. #[serde(skip_serializing_if = "Option::is_none")] - pub failed: Option, + pub failure: Option, } impl Progress { @@ -136,7 +143,7 @@ impl ProgressBar { self.progress_value.resource_name = Some(name.to_string()); self.progress_value.resource_type = Some(resource_type.to_string()); self.progress_value.result = None; - self.progress_value.failed = None; + self.progress_value.failure = None; } /// Set the result of the operation. This will clear any error. @@ -146,15 +153,15 @@ impl ProgressBar { /// * `result` - The result of the operation /// pub fn set_result(&mut self, result: &Value) { - self.progress_value.failed = None; + self.progress_value.failure = None; self.progress_value.result = Some(result.clone()); } /// Indicate that the operation failed. This will clear any result. /// - pub fn set_failed(&mut self) { + pub fn set_failure(&mut self, failure: Option) { self.progress_value.result = None; - self.progress_value.failed = Some(true); + self.progress_value.failure = failure; } /// Set the status of the operation and write the progress From eb1201acbb9cca5c4c76f4f145d16d93d6d67fa6 Mon Sep 17 00:00:00 2001 From: Steve Lee Date: Thu, 20 Feb 2025 14:03:08 -0800 Subject: [PATCH 10/12] fix clippy --- dsc_lib/src/configure/mod.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dsc_lib/src/configure/mod.rs b/dsc_lib/src/configure/mod.rs index 153f6407..bf088648 100644 --- a/dsc_lib/src/configure/mod.rs +++ b/dsc_lib/src/configure/mod.rs @@ -798,13 +798,13 @@ fn get_failure_from_error(err: &DscError) -> Option { DscError::CommandExit(_resource, exit_code, reason) => { Some(Failure { message: reason.to_string(), - exit_code: exit_code.clone(), + exit_code: *exit_code, }) }, DscError::CommandExitFromManifest(_resource, exit_code, reason) => { Some(Failure { message: reason.to_string(), - exit_code: exit_code.clone(), + exit_code: *exit_code, }) }, _ => None, From 66dc9d97bffaa920c85730387bbadafbe49c31f4 Mon Sep 17 00:00:00 2001 From: Steve Lee Date: Thu, 20 Feb 2025 21:45:12 -0800 Subject: [PATCH 11/12] since every discovery function takes progress, move it to constructor --- dsc_lib/src/discovery/command_discovery.rs | 32 ++++++++++++---------- dsc_lib/src/discovery/discovery_trait.rs | 10 +++---- dsc_lib/src/discovery/mod.rs | 8 +++--- 3 files changed, 26 insertions(+), 24 deletions(-) diff --git a/dsc_lib/src/discovery/command_discovery.rs b/dsc_lib/src/discovery/command_discovery.rs index 5198fdc0..989e6e8c 100644 --- a/dsc_lib/src/discovery/command_discovery.rs +++ b/dsc_lib/src/discovery/command_discovery.rs @@ -31,6 +31,7 @@ pub struct CommandDiscovery { resources: BTreeMap>, adapters: BTreeMap>, adapted_resources: BTreeMap>, + progress_format: ProgressFormat, } #[derive(Deserialize)] @@ -56,11 +57,12 @@ impl Default for ResourcePathSetting { } impl CommandDiscovery { - pub fn new() -> CommandDiscovery { + pub fn new(progress_format: ProgressFormat) -> CommandDiscovery { CommandDiscovery { resources: BTreeMap::new(), adapters: BTreeMap::new(), adapted_resources: BTreeMap::new(), + progress_format, } } @@ -161,13 +163,13 @@ impl CommandDiscovery { impl Default for CommandDiscovery { fn default() -> Self { - Self::new() + Self::new(ProgressFormat::Default) } } impl ResourceDiscovery for CommandDiscovery { - fn discover_resources(&mut self, filter: &str, progress_format: ProgressFormat) -> Result<(), DscError> { + fn discover_resources(&mut self, filter: &str) -> Result<(), DscError> { info!("{}", t!("discovery.commandDiscovery.discoverResources", filter = filter)); let regex_str = convert_wildcard_to_regex(filter); @@ -178,7 +180,7 @@ impl ResourceDiscovery for CommandDiscovery { return Err(DscError::Operation(t!("discovery.commandDiscovery.invalidAdapterFilter").to_string())); }; - let mut progress = ProgressBar::new(1, progress_format)?; + let mut progress = ProgressBar::new(1, self.progress_format)?; progress.write_activity(t!("discovery.commandDiscovery.progressSearching").to_string().as_str()); let mut resources = BTreeMap::>::new(); @@ -242,9 +244,9 @@ impl ResourceDiscovery for CommandDiscovery { Ok(()) } - fn discover_adapted_resources(&mut self, name_filter: &str, adapter_filter: &str, progress_format: ProgressFormat) -> Result<(), DscError> { + fn discover_adapted_resources(&mut self, name_filter: &str, adapter_filter: &str) -> Result<(), DscError> { if self.resources.is_empty() && self.adapters.is_empty() { - self.discover_resources("*", progress_format)?; + self.discover_resources("*")?; } if self.adapters.is_empty() { @@ -267,7 +269,7 @@ impl ResourceDiscovery for CommandDiscovery { return Err(DscError::Operation("Could not build Regex filter for resource name".to_string())); }; - let mut progress = ProgressBar::new(self.adapters.len() as u64, progress_format)?; + let mut progress = ProgressBar::new(self.adapters.len() as u64, self.progress_format)?; progress.write_activity("Searching for adapted resources"); let mut adapted_resources = BTreeMap::>::new(); @@ -283,7 +285,7 @@ impl ResourceDiscovery for CommandDiscovery { found_adapter = true; info!("Enumerating resources for adapter '{}'", adapter_name); - let mut adapter_progress = ProgressBar::new(1, progress_format)?; + let mut adapter_progress = ProgressBar::new(1, self.progress_format)?; adapter_progress.write_activity(format!("Enumerating resources for adapter '{adapter_name}'").as_str()); let manifest = if let Some(manifest) = &adapter.manifest { if let Ok(manifest) = import_manifest(manifest.clone()) { @@ -350,18 +352,18 @@ impl ResourceDiscovery for CommandDiscovery { Ok(()) } - fn list_available_resources(&mut self, type_name_filter: &str, adapter_name_filter: &str, progress_format: ProgressFormat) -> Result>, DscError> { + fn list_available_resources(&mut self, type_name_filter: &str, adapter_name_filter: &str) -> Result>, DscError> { trace!("Listing resources with type_name_filter '{type_name_filter}' and adapter_name_filter '{adapter_name_filter}'"); let mut resources = BTreeMap::>::new(); if adapter_name_filter.is_empty() { - self.discover_resources(type_name_filter, progress_format)?; + self.discover_resources(type_name_filter)?; resources.append(&mut self.resources); resources.append(&mut self.adapters); } else { - self.discover_resources("*", progress_format)?; - self.discover_adapted_resources(type_name_filter, adapter_name_filter, progress_format)?; + self.discover_resources("*")?; + self.discover_adapted_resources(type_name_filter, adapter_name_filter)?; // add/update found adapted resources to the lookup_table add_resources_to_lookup_table(&self.adapted_resources); @@ -374,10 +376,10 @@ impl ResourceDiscovery for CommandDiscovery { } // TODO: handle version requirements - fn find_resources(&mut self, required_resource_types: &[String], progress_format: ProgressFormat) -> Result, DscError> + fn find_resources(&mut self, required_resource_types: &[String]) -> Result, DscError> { debug!("Searching for resources: {:?}", required_resource_types); - self.discover_resources("*", progress_format)?; + self.discover_resources("*")?; // convert required_resource_types to lowercase to handle case-insentiive search let mut remaining_required_resource_types = required_resource_types.iter().map(|x| x.to_lowercase()).collect::>(); @@ -426,7 +428,7 @@ impl ResourceDiscovery for CommandDiscovery { } } - self.discover_adapted_resources("*", &adapter_name, progress_format)?; + self.discover_adapted_resources("*", &adapter_name)?; // add/update found adapted resources to the lookup_table add_resources_to_lookup_table(&self.adapted_resources); diff --git a/dsc_lib/src/discovery/discovery_trait.rs b/dsc_lib/src/discovery/discovery_trait.rs index e5eb43ac..a6eb226f 100644 --- a/dsc_lib/src/discovery/discovery_trait.rs +++ b/dsc_lib/src/discovery/discovery_trait.rs @@ -1,12 +1,12 @@ // Copyright (c) Microsoft Corporation. // Licensed under the MIT License. -use crate::{dscresources::dscresource::DscResource, dscerror::DscError, progress::ProgressFormat}; +use crate::{dscresources::dscresource::DscResource, dscerror::DscError}; use std::collections::BTreeMap; pub trait ResourceDiscovery { - fn discover_resources(&mut self, filter: &str, progress_format: ProgressFormat) -> Result<(), DscError>; - fn discover_adapted_resources(&mut self, name_filter: &str, adapter_filter: &str, progress_format: ProgressFormat) -> Result<(), DscError>; - fn list_available_resources(&mut self, type_name_filter: &str, adapter_name_filter: &str, progress_format: ProgressFormat) -> Result>, DscError>; - fn find_resources(&mut self, required_resource_types: &[String], progress_format: ProgressFormat) -> Result, DscError>; + fn discover_resources(&mut self, filter: &str) -> Result<(), DscError>; + fn discover_adapted_resources(&mut self, name_filter: &str, adapter_filter: &str) -> Result<(), DscError>; + fn list_available_resources(&mut self, type_name_filter: &str, adapter_name_filter: &str) -> Result>, DscError>; + fn find_resources(&mut self, required_resource_types: &[String]) -> Result, DscError>; } diff --git a/dsc_lib/src/discovery/mod.rs b/dsc_lib/src/discovery/mod.rs index 91a99165..17796999 100644 --- a/dsc_lib/src/discovery/mod.rs +++ b/dsc_lib/src/discovery/mod.rs @@ -38,14 +38,14 @@ impl Discovery { /// A vector of `DscResource` instances. pub fn list_available_resources(&mut self, type_name_filter: &str, adapter_name_filter: &str, progress_format: ProgressFormat) -> Vec { let discovery_types: Vec> = vec![ - Box::new(command_discovery::CommandDiscovery::new()), + Box::new(command_discovery::CommandDiscovery::new(progress_format)), ]; let mut resources: Vec = Vec::new(); for mut discovery_type in discovery_types { - let discovered_resources = match discovery_type.list_available_resources(type_name_filter, adapter_name_filter, progress_format) { + let discovered_resources = match discovery_type.list_available_resources(type_name_filter, adapter_name_filter) { Ok(value) => value, Err(err) => { error!("{err}"); @@ -75,12 +75,12 @@ impl Discovery { /// * `required_resource_types` - The required resource types. pub fn find_resources(&mut self, required_resource_types: &[String], progress_format: ProgressFormat) { let discovery_types: Vec> = vec![ - Box::new(command_discovery::CommandDiscovery::new()), + Box::new(command_discovery::CommandDiscovery::new(progress_format)), ]; let mut remaining_required_resource_types = required_resource_types.to_owned(); for mut discovery_type in discovery_types { - let discovered_resources = match discovery_type.find_resources(&remaining_required_resource_types, progress_format) { + let discovered_resources = match discovery_type.find_resources(&remaining_required_resource_types) { Ok(value) => value, Err(err) => { error!("{err}"); From 13419d68c3b92c190d9b8198dc1c5b311e59f91f Mon Sep 17 00:00:00 2001 From: Steve Lee Date: Tue, 25 Feb 2025 13:49:47 -0800 Subject: [PATCH 12/12] update lockfiles --- dsc/Cargo.lock | 169 ++++++++++------------ dsc_lib/Cargo.lock | 179 +++++++++-------------- dscecho/Cargo.lock | 203 ++++++++------------------- osinfo/Cargo.lock | 28 ++-- process/Cargo.lock | 28 ++-- runcommandonset/Cargo.lock | 189 ++++++++----------------- security_context_lib/Cargo.lock | 4 +- tools/dsctest/Cargo.lock | 40 +++--- tools/test_group_resource/Cargo.lock | 179 +++++++++-------------- tree-sitter-dscexpression/Cargo.lock | 32 ++--- y2j/Cargo.lock | 32 ++--- 11 files changed, 410 insertions(+), 673 deletions(-) diff --git a/dsc/Cargo.lock b/dsc/Cargo.lock index 02f604d9..bc8080b4 100644 --- a/dsc/Cargo.lock +++ b/dsc/Cargo.lock @@ -105,6 +105,12 @@ dependencies = [ "windows-sys 0.59.0", ] +[[package]] +name = "anyhow" +version = "1.0.96" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6b964d184e89d9b6b67dd2715bc8e74cf3107fb2b529990c90cf517326150bf4" + [[package]] name = "arc-swap" version = "1.7.1" @@ -240,9 +246,9 @@ checksum = "f61dac84819c6588b558454b194026eb1f09c293b9036ae9b159e74e73ab6cf9" [[package]] name = "cc" -version = "1.2.12" +version = "1.2.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "755717a7de9ec452bf7f3f1a3099085deabd7f2962b861dae91ecd7a365903d2" +checksum = "c736e259eea577f443d5c86c304f9f4ae0295c43f3ba05c21f1d66b5f06001af" dependencies = [ "shlex", ] @@ -275,9 +281,9 @@ dependencies = [ [[package]] name = "clap" -version = "4.5.28" +version = "4.5.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3e77c3243bd94243c03672cb5154667347c457ca271254724f9f393aee1c05ff" +checksum = "027bb0d98429ae334a8698531da7077bdf906419543a35a55c2cb1b66437d767" dependencies = [ "clap_builder", "clap_derive", @@ -285,9 +291,9 @@ dependencies = [ [[package]] name = "clap_builder" -version = "4.5.27" +version = "4.5.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1b26884eb4b57140e4d2d93652abfa49498b938b3c9179f9fc487b0acc3edad7" +checksum = "5589e0cba072e0f3d23791efac0fd8627b49c829c196a492e88168e6a669d863" dependencies = [ "anstream", "anstyle", @@ -297,9 +303,9 @@ dependencies = [ [[package]] name = "clap_complete" -version = "4.5.44" +version = "4.5.46" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "375f9d8255adeeedd51053574fd8d4ba875ea5fa558e86617b07f09f1680c8b6" +checksum = "f5c5508ea23c5366f77e53f5a0070e5a84e51687ec3ef9e0464c86dc8d13ce98" dependencies = [ "clap", ] @@ -566,9 +572,9 @@ checksum = "feeef44e73baff3a26d371801df019877a9866a8c493d315ab00177843314f35" [[package]] name = "either" -version = "1.13.0" +version = "1.14.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" +checksum = "b7914353092ddf589ad78f25c5c1c21b7f80b0ff8621e7c814c3485b5306da9d" [[package]] name = "email_address" @@ -587,9 +593,9 @@ checksum = "34aa73646ffb006b8f5147f3dc182bd4bcb190227ce861fc4a4844bf8e3cb2c0" [[package]] name = "equivalent" -version = "1.0.1" +version = "1.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" +checksum = "877a4ace8713b0bcf2a4e7eec82529c029f1d0619886d18145fea96c3ffe5c0f" [[package]] name = "errno" @@ -622,17 +628,11 @@ dependencies = [ "regex-syntax 0.8.5", ] -[[package]] -name = "fastrand" -version = "2.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "37909eebbb50d72f9059c3b6d82c0463f2ff062c9e95845c43a6c9c0355411be" - [[package]] name = "flate2" -version = "1.0.35" +version = "1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c936bfdafb507ebbf50b8074c54fa31c5be9a1e7e5f467dd659697041407d07c" +checksum = "11faaf5a5236997af9848be0bef4db95824b1d534ebc64d0f0c6cf3e67bd38dc" dependencies = [ "crc32fast", "miniz_oxide", @@ -1033,15 +1033,19 @@ checksum = "bbd2bcb4c963f2ddae06a2efc7e9f3591312473c50c6685e1f298068316e66fe" [[package]] name = "libc" -version = "0.2.169" +version = "0.2.170" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b5aba8db14291edd000dfcc4d620c7ebfb122c613afb886ca8803fa4e128a20a" +checksum = "875b3680cb2f8f71bdcf9a30f38d48282f5d3c95cbf9b3fa57269bb5d5c06828" [[package]] name = "libyml" -version = "0.0.4" +version = "0.0.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "64804cc6a5042d4f05379909ba25b503ec04e2c082151d62122d5dcaa274b961" +checksum = "3302702afa434ffa30847a83305f0a69d6abd74293b6554c18ec85c7ef30c980" +dependencies = [ + "anyhow", + "version_check", +] [[package]] name = "linked-hash-map" @@ -1073,9 +1077,9 @@ dependencies = [ [[package]] name = "log" -version = "0.4.25" +version = "0.4.26" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "04cbf5b083de1c7e0222a7a51dbfdba1cbe1c6ab0b15e29fff3f6c077fd9cd9f" +checksum = "30bde2b3dc3671ae49d8e2e9f044c7c005836e7a023ee57cffa25ab82764bb9e" [[package]] name = "matchers" @@ -1094,9 +1098,9 @@ checksum = "78ca9ab1a0babb1e7d5695e3530886289c18cf2f87ec19a575a0abdce112e3a3" [[package]] name = "miniz_oxide" -version = "0.8.3" +version = "0.8.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b8402cab7aefae129c6977bb0ff1b8fd9a04eb5b51efc50a70bea51cda0c7924" +checksum = "8e3e04debbb59698c15bacbb6d93584a8c0ca9cc3213cb423d31f760d8843ce5" dependencies = [ "adler2", ] @@ -1255,9 +1259,9 @@ dependencies = [ [[package]] name = "once_cell" -version = "1.20.2" +version = "1.20.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1261fe7e33c73b354eab43b1273a57c8f967d0391e80353e51f764ac02cf6775" +checksum = "945462a4b81e43c4e3ba96bd7b49d834c6f61198356aa858733bc4acf3cbe62e" [[package]] name = "outref" @@ -1339,9 +1343,9 @@ dependencies = [ [[package]] name = "portable-atomic" -version = "1.10.0" +version = "1.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "280dc24453071f1b63954171985a0b0d30058d287960968b9b2aca264c8d4ee6" +checksum = "350e9b48cbc6b0e028b0473b114454c6316e57336ee184ceab6e53f72c178b3e" [[package]] name = "powerfmt" @@ -1398,9 +1402,9 @@ dependencies = [ [[package]] name = "redox_syscall" -version = "0.5.8" +version = "0.5.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "03a862b389f93e68874fbf580b9de08dd02facb9a788ebadaf4a3fd33cf58834" +checksum = "82b568323e98e49e2a0899dcee453dd679fae22d69adf9b11dd508d1549b7e2f" dependencies = [ "bitflags 2.8.0", ] @@ -1484,9 +1488,9 @@ checksum = "2b15c43186be67a4fd63bee50d0303afffcef381492ebe2c5d87f324e1b8815c" [[package]] name = "rust-i18n" -version = "3.1.2" +version = "3.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "039f57d22229db401af3458ca939300178e99e88b938573cea12b7c2b0f09724" +checksum = "71b3a6e1c6565b77c86d868eea3068b0eb39582510f9c78cfbd5c67bd36fda9b" dependencies = [ "globwalk", "once_cell", @@ -1498,9 +1502,9 @@ dependencies = [ [[package]] name = "rust-i18n-macro" -version = "3.1.2" +version = "3.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dde5c022360a2e54477882843d56b6f9bcb4bc62f504b651a2f497f0028d174f" +checksum = "6180d8506af2b485ffc1eab7fc6d15678336a694f2b5efac5f2ca78c52928275" dependencies = [ "glob", "once_cell", @@ -1515,9 +1519,9 @@ dependencies = [ [[package]] name = "rust-i18n-support" -version = "3.1.2" +version = "3.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "75d2844d36f62b5d6b66f9cf8f8cbdbbbdcdb5fd37a473a9cc2fb45fdcf485d2" +checksum = "938f16094e2b09e893b1f85c9da251739a832d4272a5957217977da3a0713bb6" dependencies = [ "arc-swap", "base62", @@ -1578,9 +1582,9 @@ dependencies = [ [[package]] name = "schemars" -version = "0.8.21" +version = "0.8.22" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "09c024468a378b7e36765cd36702b7a90cc3cba11654f6685c8f233408e89e92" +checksum = "3fbf2ae1b8bc8e02df939598064d22402220cd5bbcca1c76f7d6a310974d5615" dependencies = [ "dyn-clone", "indexmap 1.9.3", @@ -1591,9 +1595,9 @@ dependencies = [ [[package]] name = "schemars_derive" -version = "0.8.21" +version = "0.8.22" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b1eee588578aff73f856ab961cd2f79e36bc45d7ded33a7562adba4667aecc0e" +checksum = "32e265784ad618884abaea0600a9adf15393368d840e0222d101a072f3f7534d" dependencies = [ "proc-macro2", "quote", @@ -1623,18 +1627,18 @@ checksum = "f79dfe2d285b0488816f30e700a7438c5a73d816b5b7d3ac72fbc48b0d185e03" [[package]] name = "serde" -version = "1.0.217" +version = "1.0.218" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "02fc4265df13d6fa1d00ecff087228cc0a2b5f3c0e87e258d8b94a156e984c70" +checksum = "e8dfc9d19bdbf6d17e22319da49161d5d0108e4188e8b680aef6299eed22df60" dependencies = [ "serde_derive", ] [[package]] name = "serde_derive" -version = "1.0.217" +version = "1.0.218" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5a9bf7cf98d04a2b28aead066b7496853d4779c9cc183c440dbac457641e19a0" +checksum = "f09503e191f4e797cb8aac08e9a4a4695c5edf6a2e70e376d961ddd5c969f82b" dependencies = [ "proc-macro2", "quote", @@ -1654,9 +1658,9 @@ dependencies = [ [[package]] name = "serde_json" -version = "1.0.138" +version = "1.0.139" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d434192e7da787e94a6ea7e9670b26a036d0ca41e0b7efb2676dd32bae872949" +checksum = "44f86c3acccc9c65b153fe1b85a3be07fe5515274ec9f0653b4a0875731c72a6" dependencies = [ "indexmap 2.7.1", "itoa", @@ -1689,19 +1693,17 @@ dependencies = [ [[package]] name = "serde_yml" -version = "0.0.11" +version = "0.0.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "48e76bab63c3fd98d27c17f9cbce177f64a91f5e69ac04cafe04e1bb25d1dc3c" +checksum = "59e2dd588bf1597a252c3b920e0143eb99b0f76e4e082f4c92ce34fbc9e71ddd" dependencies = [ "indexmap 2.7.1", "itoa", "libyml", - "log", "memchr", "ryu", "serde", - "serde_json", - "tempfile", + "version_check", ] [[package]] @@ -1757,9 +1759,9 @@ checksum = "56199f7ddabf13fe5074ce809e7d3f42b42ae711800501b5b16ea82ad029c39d" [[package]] name = "smallvec" -version = "1.13.2" +version = "1.14.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" +checksum = "7fcf8323ef1faaee30a44a340193b1ac6814fd9b7b4e88e9d4519a3e4abe1cfd" [[package]] name = "socket2" @@ -1847,20 +1849,6 @@ dependencies = [ "windows", ] -[[package]] -name = "tempfile" -version = "3.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "38c246215d7d24f48ae091a2902398798e05d978b24315d6efbc00ede9a8bb91" -dependencies = [ - "cfg-if", - "fastrand", - "getrandom 0.3.1", - "once_cell", - "rustix", - "windows-sys 0.59.0", -] - [[package]] name = "thiserror" version = "1.0.69" @@ -1983,9 +1971,9 @@ dependencies = [ [[package]] name = "toml" -version = "0.7.8" +version = "0.8.20" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dd79e69d3b627db300ff956027cc6c3798cef26d22526befdfcd12feeb6d2257" +checksum = "cd87a5cdd6ffab733b2f74bc4fd7ee5fff6634124999ac278c35fc78c6120148" dependencies = [ "serde", "serde_spanned", @@ -2004,9 +1992,9 @@ dependencies = [ [[package]] name = "toml_edit" -version = "0.19.15" +version = "0.22.24" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1b5bb770da30e5cbfde35a2d7b9b8a2c4b8ef89548a7a6aeab5c9a576e3e7421" +checksum = "17b4795ff5edd201c7cd6dca065ae59972ce77d1b80fa0a84d94950ece7d1474" dependencies = [ "indexmap 2.7.1", "serde", @@ -2103,9 +2091,9 @@ dependencies = [ [[package]] name = "tree-sitter" -version = "0.25.1" +version = "0.25.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1a802c93485fb6781d27e27cb5927f6b00ff8d26b56c70af87267be7e99def97" +checksum = "5168a515fe492af54c5cc8800ff8c840be09fa5168de45838afaecd3e008bce4" dependencies = [ "cc", "regex", @@ -2127,9 +2115,9 @@ dependencies = [ [[package]] name = "tree-sitter-language" -version = "0.1.4" +version = "0.1.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "38eee4db33814de3d004de9d8d825627ed3320d0989cce0dea30efaf5be4736c" +checksum = "c4013970217383f67b18aef68f6fb2e8d409bc5755227092d32efb0422ba24b8" [[package]] name = "tree-sitter-rust" @@ -2154,9 +2142,9 @@ dependencies = [ [[package]] name = "unicode-ident" -version = "1.0.16" +version = "1.0.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a210d160f08b701c8721ba1c726c11662f877ea6b7094007e1ca9a1041945034" +checksum = "00e2473a93778eb0bad35909dff6a10d28e63f792f16ed15e404fca9d5eeedbe" [[package]] name = "unicode-width" @@ -2196,9 +2184,9 @@ checksum = "06abde3611657adf66d383f00b093d7faecc7fa57071cce2578660c9f1010821" [[package]] name = "uuid" -version = "1.13.1" +version = "1.14.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ced87ca4be083373936a67f8de945faa23b6b42384bd5b64434850802c6dccd0" +checksum = "93d59ca99a559661b96bf898d8fce28ed87935fd2bea9f05983c1464dd6c71b1" dependencies = [ "getrandom 0.3.1", ] @@ -2290,15 +2278,6 @@ dependencies = [ "wit-bindgen-rt", ] -[[package]] -name = "wasm-bindgen" -version = "0.2.95" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "26816d2e1a4a36a2940b96c5296ce403917633dff8f3440e9b236ed6f6bacad2" -dependencies = [ - "wit-bindgen-rt", -] - [[package]] name = "wasm-bindgen" version = "0.2.100" @@ -2544,9 +2523,9 @@ checksum = "589f6da84c646204747d1270a2a5661ea66ed1cced2631d546fdfb155959f9ec" [[package]] name = "winnow" -version = "0.5.40" +version = "0.7.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f593a95398737aeed53e489c785df13f3618e41dbcd6718c6addbf1395aa6876" +checksum = "0e7f4ea97f6f78012141bcdb6a216b2609f0979ada50b20ca5b52dde2eac2bb1" dependencies = [ "memchr", ] @@ -2557,7 +2536,7 @@ version = "0.33.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3268f3d866458b787f390cf61f4bbb563b922d091359f9608842999eaee3943c" dependencies = [ - "bitflags 2.6.0", + "bitflags 2.8.0", ] [[package]] diff --git a/dsc_lib/Cargo.lock b/dsc_lib/Cargo.lock index 7a9f8f75..3e27073a 100644 --- a/dsc_lib/Cargo.lock +++ b/dsc_lib/Cargo.lock @@ -105,6 +105,12 @@ dependencies = [ "windows-sys 0.59.0", ] +[[package]] +name = "anyhow" +version = "1.0.96" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6b964d184e89d9b6b67dd2715bc8e74cf3107fb2b529990c90cf517326150bf4" + [[package]] name = "arc-swap" version = "1.7.1" @@ -216,9 +222,9 @@ checksum = "f61dac84819c6588b558454b194026eb1f09c293b9036ae9b159e74e73ab6cf9" [[package]] name = "cc" -version = "1.2.12" +version = "1.2.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "755717a7de9ec452bf7f3f1a3099085deabd7f2962b861dae91ecd7a365903d2" +checksum = "c736e259eea577f443d5c86c304f9f4ae0295c43f3ba05c21f1d66b5f06001af" dependencies = [ "shlex", ] @@ -251,9 +257,9 @@ dependencies = [ [[package]] name = "clap" -version = "4.5.28" +version = "4.5.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3e77c3243bd94243c03672cb5154667347c457ca271254724f9f393aee1c05ff" +checksum = "027bb0d98429ae334a8698531da7077bdf906419543a35a55c2cb1b66437d767" dependencies = [ "clap_builder", "clap_derive", @@ -261,9 +267,9 @@ dependencies = [ [[package]] name = "clap_builder" -version = "4.5.27" +version = "4.5.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1b26884eb4b57140e4d2d93652abfa49498b938b3c9179f9fc487b0acc3edad7" +checksum = "5589e0cba072e0f3d23791efac0fd8627b49c829c196a492e88168e6a669d863" dependencies = [ "anstream", "anstyle", @@ -455,9 +461,9 @@ checksum = "feeef44e73baff3a26d371801df019877a9866a8c493d315ab00177843314f35" [[package]] name = "either" -version = "1.13.0" +version = "1.14.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" +checksum = "b7914353092ddf589ad78f25c5c1c21b7f80b0ff8621e7c814c3485b5306da9d" [[package]] name = "email_address" @@ -476,19 +482,9 @@ checksum = "34aa73646ffb006b8f5147f3dc182bd4bcb190227ce861fc4a4844bf8e3cb2c0" [[package]] name = "equivalent" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" - -[[package]] -name = "errno" -version = "0.3.10" +version = "1.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "33d852cb9b869c2a9b3df2f71a3074817f01e1844f839a144f5fcef059a4eb5d" -dependencies = [ - "libc", - "windows-sys 0.59.0", -] +checksum = "877a4ace8713b0bcf2a4e7eec82529c029f1d0619886d18145fea96c3ffe5c0f" [[package]] name = "fancy-regex" @@ -501,12 +497,6 @@ dependencies = [ "regex-syntax", ] -[[package]] -name = "fastrand" -version = "2.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "37909eebbb50d72f9059c3b6d82c0463f2ff062c9e95845c43a6c9c0355411be" - [[package]] name = "fluent-uri" version = "0.3.2" @@ -902,15 +892,19 @@ checksum = "bbd2bcb4c963f2ddae06a2efc7e9f3591312473c50c6685e1f298068316e66fe" [[package]] name = "libc" -version = "0.2.169" +version = "0.2.170" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b5aba8db14291edd000dfcc4d620c7ebfb122c613afb886ca8803fa4e128a20a" +checksum = "875b3680cb2f8f71bdcf9a30f38d48282f5d3c95cbf9b3fa57269bb5d5c06828" [[package]] name = "libyml" -version = "0.0.4" +version = "0.0.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "64804cc6a5042d4f05379909ba25b503ec04e2c082151d62122d5dcaa274b961" +checksum = "3302702afa434ffa30847a83305f0a69d6abd74293b6554c18ec85c7ef30c980" +dependencies = [ + "anyhow", + "version_check", +] [[package]] name = "linked-hash-map" @@ -918,12 +912,6 @@ version = "0.5.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0717cef1bc8b636c6e1c1bbdefc09e6322da8a9321966e8928ef80d20f7f770f" -[[package]] -name = "linux-raw-sys" -version = "0.4.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d26c52dbd32dccf2d10cac7725f8eae5296885fb5703b261f7d0a0739ec807ab" - [[package]] name = "litemap" version = "0.7.4" @@ -942,9 +930,9 @@ dependencies = [ [[package]] name = "log" -version = "0.4.25" +version = "0.4.26" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "04cbf5b083de1c7e0222a7a51dbfdba1cbe1c6ab0b15e29fff3f6c077fd9cd9f" +checksum = "30bde2b3dc3671ae49d8e2e9f044c7c005836e7a023ee57cffa25ab82764bb9e" [[package]] name = "memchr" @@ -954,9 +942,9 @@ checksum = "78ca9ab1a0babb1e7d5695e3530886289c18cf2f87ec19a575a0abdce112e3a3" [[package]] name = "miniz_oxide" -version = "0.8.3" +version = "0.8.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b8402cab7aefae129c6977bb0ff1b8fd9a04eb5b51efc50a70bea51cda0c7924" +checksum = "8e3e04debbb59698c15bacbb6d93584a8c0ca9cc3213cb423d31f760d8843ce5" dependencies = [ "adler2", ] @@ -1099,9 +1087,9 @@ dependencies = [ [[package]] name = "once_cell" -version = "1.20.2" +version = "1.20.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1261fe7e33c73b354eab43b1273a57c8f967d0391e80353e51f764ac02cf6775" +checksum = "945462a4b81e43c4e3ba96bd7b49d834c6f61198356aa858733bc4acf3cbe62e" [[package]] name = "outref" @@ -1152,9 +1140,9 @@ checksum = "3b3cff922bd51709b605d9ead9aa71031d81447142d828eb4a6eba76fe619f9b" [[package]] name = "portable-atomic" -version = "1.10.0" +version = "1.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "280dc24453071f1b63954171985a0b0d30058d287960968b9b2aca264c8d4ee6" +checksum = "350e9b48cbc6b0e028b0473b114454c6316e57336ee184ceab6e53f72c178b3e" [[package]] name = "proc-macro2" @@ -1176,9 +1164,9 @@ dependencies = [ [[package]] name = "redox_syscall" -version = "0.5.8" +version = "0.5.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "03a862b389f93e68874fbf580b9de08dd02facb9a788ebadaf4a3fd33cf58834" +checksum = "82b568323e98e49e2a0899dcee453dd679fae22d69adf9b11dd508d1549b7e2f" dependencies = [ "bitflags 2.8.0", ] @@ -1247,9 +1235,9 @@ checksum = "2b15c43186be67a4fd63bee50d0303afffcef381492ebe2c5d87f324e1b8815c" [[package]] name = "rust-i18n" -version = "3.1.2" +version = "3.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "039f57d22229db401af3458ca939300178e99e88b938573cea12b7c2b0f09724" +checksum = "71b3a6e1c6565b77c86d868eea3068b0eb39582510f9c78cfbd5c67bd36fda9b" dependencies = [ "globwalk", "once_cell", @@ -1261,9 +1249,9 @@ dependencies = [ [[package]] name = "rust-i18n-macro" -version = "3.1.2" +version = "3.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dde5c022360a2e54477882843d56b6f9bcb4bc62f504b651a2f497f0028d174f" +checksum = "6180d8506af2b485ffc1eab7fc6d15678336a694f2b5efac5f2ca78c52928275" dependencies = [ "glob", "once_cell", @@ -1278,9 +1266,9 @@ dependencies = [ [[package]] name = "rust-i18n-support" -version = "3.1.2" +version = "3.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "75d2844d36f62b5d6b66f9cf8f8cbdbbbdcdb5fd37a473a9cc2fb45fdcf485d2" +checksum = "938f16094e2b09e893b1f85c9da251739a832d4272a5957217977da3a0713bb6" dependencies = [ "arc-swap", "base62", @@ -1305,19 +1293,6 @@ version = "0.1.24" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "719b953e2095829ee67db738b3bfa9fa368c94900df327b3f07fe6e794d2fe1f" -[[package]] -name = "rustix" -version = "0.38.44" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fdb5bc1ae2baa591800df16c9ca78619bf65c0488b41b96ccec5d11220d8c154" -dependencies = [ - "bitflags 2.8.0", - "errno", - "libc", - "linux-raw-sys", - "windows-sys 0.59.0", -] - [[package]] name = "rustversion" version = "1.0.19" @@ -1341,9 +1316,9 @@ dependencies = [ [[package]] name = "schemars" -version = "0.8.21" +version = "0.8.22" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "09c024468a378b7e36765cd36702b7a90cc3cba11654f6685c8f233408e89e92" +checksum = "3fbf2ae1b8bc8e02df939598064d22402220cd5bbcca1c76f7d6a310974d5615" dependencies = [ "dyn-clone", "indexmap 1.9.3", @@ -1354,9 +1329,9 @@ dependencies = [ [[package]] name = "schemars_derive" -version = "0.8.21" +version = "0.8.22" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b1eee588578aff73f856ab961cd2f79e36bc45d7ded33a7562adba4667aecc0e" +checksum = "32e265784ad618884abaea0600a9adf15393368d840e0222d101a072f3f7534d" dependencies = [ "proc-macro2", "quote", @@ -1386,18 +1361,18 @@ checksum = "f79dfe2d285b0488816f30e700a7438c5a73d816b5b7d3ac72fbc48b0d185e03" [[package]] name = "serde" -version = "1.0.217" +version = "1.0.218" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "02fc4265df13d6fa1d00ecff087228cc0a2b5f3c0e87e258d8b94a156e984c70" +checksum = "e8dfc9d19bdbf6d17e22319da49161d5d0108e4188e8b680aef6299eed22df60" dependencies = [ "serde_derive", ] [[package]] name = "serde_derive" -version = "1.0.217" +version = "1.0.218" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5a9bf7cf98d04a2b28aead066b7496853d4779c9cc183c440dbac457641e19a0" +checksum = "f09503e191f4e797cb8aac08e9a4a4695c5edf6a2e70e376d961ddd5c969f82b" dependencies = [ "proc-macro2", "quote", @@ -1417,9 +1392,9 @@ dependencies = [ [[package]] name = "serde_json" -version = "1.0.138" +version = "1.0.139" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d434192e7da787e94a6ea7e9670b26a036d0ca41e0b7efb2676dd32bae872949" +checksum = "44f86c3acccc9c65b153fe1b85a3be07fe5515274ec9f0653b4a0875731c72a6" dependencies = [ "indexmap 2.7.1", "itoa", @@ -1452,19 +1427,17 @@ dependencies = [ [[package]] name = "serde_yml" -version = "0.0.11" +version = "0.0.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "48e76bab63c3fd98d27c17f9cbce177f64a91f5e69ac04cafe04e1bb25d1dc3c" +checksum = "59e2dd588bf1597a252c3b920e0143eb99b0f76e4e082f4c92ce34fbc9e71ddd" dependencies = [ "indexmap 2.7.1", "itoa", "libyml", - "log", "memchr", "ryu", "serde", - "serde_json", - "tempfile", + "version_check", ] [[package]] @@ -1499,9 +1472,9 @@ checksum = "56199f7ddabf13fe5074ce809e7d3f42b42ae711800501b5b16ea82ad029c39d" [[package]] name = "smallvec" -version = "1.13.2" +version = "1.14.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" +checksum = "7fcf8323ef1faaee30a44a340193b1ac6814fd9b7b4e88e9d4519a3e4abe1cfd" [[package]] name = "socket2" @@ -1553,20 +1526,6 @@ dependencies = [ "syn", ] -[[package]] -name = "tempfile" -version = "3.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "38c246215d7d24f48ae091a2902398798e05d978b24315d6efbc00ede9a8bb91" -dependencies = [ - "cfg-if", - "fastrand", - "getrandom 0.3.1", - "once_cell", - "rustix", - "windows-sys 0.59.0", -] - [[package]] name = "thiserror" version = "1.0.69" @@ -1638,9 +1597,9 @@ dependencies = [ [[package]] name = "toml" -version = "0.7.8" +version = "0.8.20" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dd79e69d3b627db300ff956027cc6c3798cef26d22526befdfcd12feeb6d2257" +checksum = "cd87a5cdd6ffab733b2f74bc4fd7ee5fff6634124999ac278c35fc78c6120148" dependencies = [ "serde", "serde_spanned", @@ -1659,9 +1618,9 @@ dependencies = [ [[package]] name = "toml_edit" -version = "0.19.15" +version = "0.22.24" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1b5bb770da30e5cbfde35a2d7b9b8a2c4b8ef89548a7a6aeab5c9a576e3e7421" +checksum = "17b4795ff5edd201c7cd6dca065ae59972ce77d1b80fa0a84d94950ece7d1474" dependencies = [ "indexmap 2.7.1", "serde", @@ -1741,9 +1700,9 @@ dependencies = [ [[package]] name = "tree-sitter" -version = "0.25.1" +version = "0.25.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1a802c93485fb6781d27e27cb5927f6b00ff8d26b56c70af87267be7e99def97" +checksum = "5168a515fe492af54c5cc8800ff8c840be09fa5168de45838afaecd3e008bce4" dependencies = [ "cc", "regex", @@ -1765,9 +1724,9 @@ dependencies = [ [[package]] name = "tree-sitter-language" -version = "0.1.4" +version = "0.1.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "38eee4db33814de3d004de9d8d825627ed3320d0989cce0dea30efaf5be4736c" +checksum = "c4013970217383f67b18aef68f6fb2e8d409bc5755227092d32efb0422ba24b8" [[package]] name = "tree-sitter-rust" @@ -1792,9 +1751,9 @@ dependencies = [ [[package]] name = "unicode-ident" -version = "1.0.16" +version = "1.0.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a210d160f08b701c8721ba1c726c11662f877ea6b7094007e1ca9a1041945034" +checksum = "00e2473a93778eb0bad35909dff6a10d28e63f792f16ed15e404fca9d5eeedbe" [[package]] name = "unicode-width" @@ -1834,9 +1793,9 @@ checksum = "06abde3611657adf66d383f00b093d7faecc7fa57071cce2578660c9f1010821" [[package]] name = "uuid" -version = "1.13.1" +version = "1.14.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ced87ca4be083373936a67f8de945faa23b6b42384bd5b64434850802c6dccd0" +checksum = "93d59ca99a559661b96bf898d8fce28ed87935fd2bea9f05983c1464dd6c71b1" dependencies = [ "getrandom 0.3.1", ] @@ -2120,9 +2079,9 @@ checksum = "589f6da84c646204747d1270a2a5661ea66ed1cced2631d546fdfb155959f9ec" [[package]] name = "winnow" -version = "0.5.40" +version = "0.7.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f593a95398737aeed53e489c785df13f3618e41dbcd6718c6addbf1395aa6876" +checksum = "0e7f4ea97f6f78012141bcdb6a216b2609f0979ada50b20ca5b52dde2eac2bb1" dependencies = [ "memchr", ] diff --git a/dscecho/Cargo.lock b/dscecho/Cargo.lock index db0de17e..8f83e457 100644 --- a/dscecho/Cargo.lock +++ b/dscecho/Cargo.lock @@ -61,6 +61,12 @@ dependencies = [ "windows-sys", ] +[[package]] +name = "anyhow" +version = "1.0.96" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6b964d184e89d9b6b67dd2715bc8e74cf3107fb2b529990c90cf517326150bf4" + [[package]] name = "arc-swap" version = "1.7.1" @@ -82,12 +88,6 @@ version = "1.3.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" -[[package]] -name = "bitflags" -version = "2.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f68f53c83ab957f72c32642f3868eec03eb974d1fb82e453128456482613d36" - [[package]] name = "bstr" version = "1.11.3" @@ -98,17 +98,11 @@ dependencies = [ "serde", ] -[[package]] -name = "cfg-if" -version = "1.0.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" - [[package]] name = "clap" -version = "4.5.28" +version = "4.5.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3e77c3243bd94243c03672cb5154667347c457ca271254724f9f393aee1c05ff" +checksum = "027bb0d98429ae334a8698531da7077bdf906419543a35a55c2cb1b66437d767" dependencies = [ "clap_builder", "clap_derive", @@ -116,9 +110,9 @@ dependencies = [ [[package]] name = "clap_builder" -version = "4.5.27" +version = "4.5.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1b26884eb4b57140e4d2d93652abfa49498b938b3c9179f9fc487b0acc3edad7" +checksum = "5589e0cba072e0f3d23791efac0fd8627b49c829c196a492e88168e6a669d863" dependencies = [ "anstream", "anstyle", @@ -194,43 +188,15 @@ checksum = "feeef44e73baff3a26d371801df019877a9866a8c493d315ab00177843314f35" [[package]] name = "either" -version = "1.13.0" +version = "1.14.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" +checksum = "b7914353092ddf589ad78f25c5c1c21b7f80b0ff8621e7c814c3485b5306da9d" [[package]] name = "equivalent" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" - -[[package]] -name = "errno" -version = "0.3.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "33d852cb9b869c2a9b3df2f71a3074817f01e1844f839a144f5fcef059a4eb5d" -dependencies = [ - "libc", - "windows-sys", -] - -[[package]] -name = "fastrand" -version = "2.3.0" +version = "1.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "37909eebbb50d72f9059c3b6d82c0463f2ff062c9e95845c43a6c9c0355411be" - -[[package]] -name = "getrandom" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "43a49c392881ce6d5c3b8cb70f98717b7c07aabbdff06687b9030dbfbe2725f8" -dependencies = [ - "cfg-if", - "libc", - "wasi", - "windows-targets", -] +checksum = "877a4ace8713b0bcf2a4e7eec82529c029f1d0619886d18145fea96c3ffe5c0f" [[package]] name = "glob" @@ -257,7 +223,7 @@ version = "0.8.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "93e3af942408868f6934a7b85134a3230832b9977cf66125df2f9edcfce4ddcc" dependencies = [ - "bitflags 1.3.2", + "bitflags", "ignore", "walkdir", ] @@ -327,29 +293,21 @@ version = "1.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "bbd2bcb4c963f2ddae06a2efc7e9f3591312473c50c6685e1f298068316e66fe" -[[package]] -name = "libc" -version = "0.2.169" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b5aba8db14291edd000dfcc4d620c7ebfb122c613afb886ca8803fa4e128a20a" - [[package]] name = "libyml" -version = "0.0.4" +version = "0.0.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "64804cc6a5042d4f05379909ba25b503ec04e2c082151d62122d5dcaa274b961" - -[[package]] -name = "linux-raw-sys" -version = "0.4.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d26c52dbd32dccf2d10cac7725f8eae5296885fb5703b261f7d0a0739ec807ab" +checksum = "3302702afa434ffa30847a83305f0a69d6abd74293b6554c18ec85c7ef30c980" +dependencies = [ + "anyhow", + "version_check", +] [[package]] name = "log" -version = "0.4.25" +version = "0.4.26" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "04cbf5b083de1c7e0222a7a51dbfdba1cbe1c6ab0b15e29fff3f6c077fd9cd9f" +checksum = "30bde2b3dc3671ae49d8e2e9f044c7c005836e7a023ee57cffa25ab82764bb9e" [[package]] name = "memchr" @@ -368,9 +326,9 @@ dependencies = [ [[package]] name = "once_cell" -version = "1.20.2" +version = "1.20.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1261fe7e33c73b354eab43b1273a57c8f967d0391e80353e51f764ac02cf6775" +checksum = "945462a4b81e43c4e3ba96bd7b49d834c6f61198356aa858733bc4acf3cbe62e" [[package]] name = "proc-macro2" @@ -421,9 +379,9 @@ checksum = "2b15c43186be67a4fd63bee50d0303afffcef381492ebe2c5d87f324e1b8815c" [[package]] name = "rust-i18n" -version = "3.1.2" +version = "3.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "039f57d22229db401af3458ca939300178e99e88b938573cea12b7c2b0f09724" +checksum = "71b3a6e1c6565b77c86d868eea3068b0eb39582510f9c78cfbd5c67bd36fda9b" dependencies = [ "globwalk", "once_cell", @@ -435,9 +393,9 @@ dependencies = [ [[package]] name = "rust-i18n-macro" -version = "3.1.2" +version = "3.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dde5c022360a2e54477882843d56b6f9bcb4bc62f504b651a2f497f0028d174f" +checksum = "6180d8506af2b485ffc1eab7fc6d15678336a694f2b5efac5f2ca78c52928275" dependencies = [ "glob", "once_cell", @@ -452,9 +410,9 @@ dependencies = [ [[package]] name = "rust-i18n-support" -version = "3.1.2" +version = "3.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "75d2844d36f62b5d6b66f9cf8f8cbdbbbdcdb5fd37a473a9cc2fb45fdcf485d2" +checksum = "938f16094e2b09e893b1f85c9da251739a832d4272a5957217977da3a0713bb6" dependencies = [ "arc-swap", "base62", @@ -473,19 +431,6 @@ dependencies = [ "triomphe", ] -[[package]] -name = "rustix" -version = "0.38.44" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fdb5bc1ae2baa591800df16c9ca78619bf65c0488b41b96ccec5d11220d8c154" -dependencies = [ - "bitflags 2.8.0", - "errno", - "libc", - "linux-raw-sys", - "windows-sys", -] - [[package]] name = "rustversion" version = "1.0.19" @@ -509,9 +454,9 @@ dependencies = [ [[package]] name = "schemars" -version = "0.8.21" +version = "0.8.22" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "09c024468a378b7e36765cd36702b7a90cc3cba11654f6685c8f233408e89e92" +checksum = "3fbf2ae1b8bc8e02df939598064d22402220cd5bbcca1c76f7d6a310974d5615" dependencies = [ "dyn-clone", "schemars_derive", @@ -521,9 +466,9 @@ dependencies = [ [[package]] name = "schemars_derive" -version = "0.8.21" +version = "0.8.22" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b1eee588578aff73f856ab961cd2f79e36bc45d7ded33a7562adba4667aecc0e" +checksum = "32e265784ad618884abaea0600a9adf15393368d840e0222d101a072f3f7534d" dependencies = [ "proc-macro2", "quote", @@ -533,18 +478,18 @@ dependencies = [ [[package]] name = "serde" -version = "1.0.217" +version = "1.0.218" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "02fc4265df13d6fa1d00ecff087228cc0a2b5f3c0e87e258d8b94a156e984c70" +checksum = "e8dfc9d19bdbf6d17e22319da49161d5d0108e4188e8b680aef6299eed22df60" dependencies = [ "serde_derive", ] [[package]] name = "serde_derive" -version = "1.0.217" +version = "1.0.218" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5a9bf7cf98d04a2b28aead066b7496853d4779c9cc183c440dbac457641e19a0" +checksum = "f09503e191f4e797cb8aac08e9a4a4695c5edf6a2e70e376d961ddd5c969f82b" dependencies = [ "proc-macro2", "quote", @@ -564,9 +509,9 @@ dependencies = [ [[package]] name = "serde_json" -version = "1.0.138" +version = "1.0.139" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d434192e7da787e94a6ea7e9670b26a036d0ca41e0b7efb2676dd32bae872949" +checksum = "44f86c3acccc9c65b153fe1b85a3be07fe5515274ec9f0653b4a0875731c72a6" dependencies = [ "indexmap", "itoa", @@ -586,19 +531,17 @@ dependencies = [ [[package]] name = "serde_yml" -version = "0.0.11" +version = "0.0.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "48e76bab63c3fd98d27c17f9cbce177f64a91f5e69ac04cafe04e1bb25d1dc3c" +checksum = "59e2dd588bf1597a252c3b920e0143eb99b0f76e4e082f4c92ce34fbc9e71ddd" dependencies = [ "indexmap", "itoa", "libyml", - "log", "memchr", "ryu", "serde", - "serde_json", - "tempfile", + "version_check", ] [[package]] @@ -609,9 +552,9 @@ checksum = "56199f7ddabf13fe5074ce809e7d3f42b42ae711800501b5b16ea82ad029c39d" [[package]] name = "smallvec" -version = "1.13.2" +version = "1.14.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" +checksum = "7fcf8323ef1faaee30a44a340193b1ac6814fd9b7b4e88e9d4519a3e4abe1cfd" [[package]] name = "stable_deref_trait" @@ -636,25 +579,11 @@ dependencies = [ "unicode-ident", ] -[[package]] -name = "tempfile" -version = "3.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "38c246215d7d24f48ae091a2902398798e05d978b24315d6efbc00ede9a8bb91" -dependencies = [ - "cfg-if", - "fastrand", - "getrandom", - "once_cell", - "rustix", - "windows-sys", -] - [[package]] name = "toml" -version = "0.7.8" +version = "0.8.20" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dd79e69d3b627db300ff956027cc6c3798cef26d22526befdfcd12feeb6d2257" +checksum = "cd87a5cdd6ffab733b2f74bc4fd7ee5fff6634124999ac278c35fc78c6120148" dependencies = [ "serde", "serde_spanned", @@ -673,9 +602,9 @@ dependencies = [ [[package]] name = "toml_edit" -version = "0.19.15" +version = "0.22.24" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1b5bb770da30e5cbfde35a2d7b9b8a2c4b8ef89548a7a6aeab5c9a576e3e7421" +checksum = "17b4795ff5edd201c7cd6dca065ae59972ce77d1b80fa0a84d94950ece7d1474" dependencies = [ "indexmap", "serde", @@ -697,9 +626,9 @@ dependencies = [ [[package]] name = "unicode-ident" -version = "1.0.16" +version = "1.0.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a210d160f08b701c8721ba1c726c11662f877ea6b7094007e1ca9a1041945034" +checksum = "00e2473a93778eb0bad35909dff6a10d28e63f792f16ed15e404fca9d5eeedbe" [[package]] name = "utf8parse" @@ -707,6 +636,12 @@ version = "0.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "06abde3611657adf66d383f00b093d7faecc7fa57071cce2578660c9f1010821" +[[package]] +name = "version_check" +version = "0.9.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0b928f33d975fc6ad9f86c8f283853ad26bdd5b10b7f1542aa2fa15e2289105a" + [[package]] name = "walkdir" version = "2.5.0" @@ -717,15 +652,6 @@ dependencies = [ "winapi-util", ] -[[package]] -name = "wasi" -version = "0.13.3+wasi-0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "26816d2e1a4a36a2940b96c5296ce403917633dff8f3440e9b236ed6f6bacad2" -dependencies = [ - "wit-bindgen-rt", -] - [[package]] name = "winapi-util" version = "0.1.9" @@ -810,18 +736,9 @@ checksum = "589f6da84c646204747d1270a2a5661ea66ed1cced2631d546fdfb155959f9ec" [[package]] name = "winnow" -version = "0.5.40" +version = "0.7.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f593a95398737aeed53e489c785df13f3618e41dbcd6718c6addbf1395aa6876" +checksum = "0e7f4ea97f6f78012141bcdb6a216b2609f0979ada50b20ca5b52dde2eac2bb1" dependencies = [ "memchr", ] - -[[package]] -name = "wit-bindgen-rt" -version = "0.33.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3268f3d866458b787f390cf61f4bbb563b922d091359f9608842999eaee3943c" -dependencies = [ - "bitflags 2.8.0", -] diff --git a/osinfo/Cargo.lock b/osinfo/Cargo.lock index 886592d9..82849a1a 100644 --- a/osinfo/Cargo.lock +++ b/osinfo/Cargo.lock @@ -4,9 +4,9 @@ version = 4 [[package]] name = "equivalent" -version = "1.0.1" +version = "1.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" +checksum = "877a4ace8713b0bcf2a4e7eec82529c029f1d0619886d18145fea96c3ffe5c0f" [[package]] name = "hashbrown" @@ -32,9 +32,9 @@ checksum = "d75a2a4b1b190afb6f5425f10f6a8f959d2ea0b9c2b1d79553551850539e4674" [[package]] name = "log" -version = "0.4.25" +version = "0.4.26" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "04cbf5b083de1c7e0222a7a51dbfdba1cbe1c6ab0b15e29fff3f6c077fd9cd9f" +checksum = "30bde2b3dc3671ae49d8e2e9f044c7c005836e7a023ee57cffa25ab82764bb9e" [[package]] name = "memchr" @@ -44,9 +44,9 @@ checksum = "78ca9ab1a0babb1e7d5695e3530886289c18cf2f87ec19a575a0abdce112e3a3" [[package]] name = "os_info" -version = "3.9.2" +version = "3.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6e6520c8cc998c5741ee68ec1dc369fc47e5f0ea5320018ecf2a1ccd6328f48b" +checksum = "2a604e53c24761286860eba4e2c8b23a0161526476b1de520139d69cdb85a6b5" dependencies = [ "log", "serde", @@ -88,18 +88,18 @@ checksum = "6ea1a2d0a644769cc99faa24c3ad26b379b786fe7c36fd3c546254801650e6dd" [[package]] name = "serde" -version = "1.0.217" +version = "1.0.218" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "02fc4265df13d6fa1d00ecff087228cc0a2b5f3c0e87e258d8b94a156e984c70" +checksum = "e8dfc9d19bdbf6d17e22319da49161d5d0108e4188e8b680aef6299eed22df60" dependencies = [ "serde_derive", ] [[package]] name = "serde_derive" -version = "1.0.217" +version = "1.0.218" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5a9bf7cf98d04a2b28aead066b7496853d4779c9cc183c440dbac457641e19a0" +checksum = "f09503e191f4e797cb8aac08e9a4a4695c5edf6a2e70e376d961ddd5c969f82b" dependencies = [ "proc-macro2", "quote", @@ -108,9 +108,9 @@ dependencies = [ [[package]] name = "serde_json" -version = "1.0.138" +version = "1.0.139" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d434192e7da787e94a6ea7e9670b26a036d0ca41e0b7efb2676dd32bae872949" +checksum = "44f86c3acccc9c65b153fe1b85a3be07fe5515274ec9f0653b4a0875731c72a6" dependencies = [ "indexmap", "itoa", @@ -132,9 +132,9 @@ dependencies = [ [[package]] name = "unicode-ident" -version = "1.0.16" +version = "1.0.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a210d160f08b701c8721ba1c726c11662f877ea6b7094007e1ca9a1041945034" +checksum = "00e2473a93778eb0bad35909dff6a10d28e63f792f16ed15e404fca9d5eeedbe" [[package]] name = "windows-sys" diff --git a/process/Cargo.lock b/process/Cargo.lock index 698aa148..0d09e684 100644 --- a/process/Cargo.lock +++ b/process/Cargo.lock @@ -35,15 +35,15 @@ checksum = "d0a5c400df2834b80a4c3327b3aad3a4c4cd4de0629063962b03235697506a28" [[package]] name = "either" -version = "1.13.0" +version = "1.14.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" +checksum = "b7914353092ddf589ad78f25c5c1c21b7f80b0ff8621e7c814c3485b5306da9d" [[package]] name = "equivalent" -version = "1.0.1" +version = "1.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" +checksum = "877a4ace8713b0bcf2a4e7eec82529c029f1d0619886d18145fea96c3ffe5c0f" [[package]] name = "hashbrown" @@ -69,9 +69,9 @@ checksum = "d75a2a4b1b190afb6f5425f10f6a8f959d2ea0b9c2b1d79553551850539e4674" [[package]] name = "libc" -version = "0.2.169" +version = "0.2.170" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b5aba8db14291edd000dfcc4d620c7ebfb122c613afb886ca8803fa4e128a20a" +checksum = "875b3680cb2f8f71bdcf9a30f38d48282f5d3c95cbf9b3fa57269bb5d5c06828" [[package]] name = "memchr" @@ -143,18 +143,18 @@ checksum = "6ea1a2d0a644769cc99faa24c3ad26b379b786fe7c36fd3c546254801650e6dd" [[package]] name = "serde" -version = "1.0.217" +version = "1.0.218" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "02fc4265df13d6fa1d00ecff087228cc0a2b5f3c0e87e258d8b94a156e984c70" +checksum = "e8dfc9d19bdbf6d17e22319da49161d5d0108e4188e8b680aef6299eed22df60" dependencies = [ "serde_derive", ] [[package]] name = "serde_derive" -version = "1.0.217" +version = "1.0.218" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5a9bf7cf98d04a2b28aead066b7496853d4779c9cc183c440dbac457641e19a0" +checksum = "f09503e191f4e797cb8aac08e9a4a4695c5edf6a2e70e376d961ddd5c969f82b" dependencies = [ "proc-macro2", "quote", @@ -163,9 +163,9 @@ dependencies = [ [[package]] name = "serde_json" -version = "1.0.138" +version = "1.0.139" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d434192e7da787e94a6ea7e9670b26a036d0ca41e0b7efb2676dd32bae872949" +checksum = "44f86c3acccc9c65b153fe1b85a3be07fe5515274ec9f0653b4a0875731c72a6" dependencies = [ "indexmap", "itoa", @@ -201,9 +201,9 @@ dependencies = [ [[package]] name = "unicode-ident" -version = "1.0.16" +version = "1.0.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a210d160f08b701c8721ba1c726c11662f877ea6b7094007e1ca9a1041945034" +checksum = "00e2473a93778eb0bad35909dff6a10d28e63f792f16ed15e404fca9d5eeedbe" [[package]] name = "winapi" diff --git a/runcommandonset/Cargo.lock b/runcommandonset/Cargo.lock index 3fa59148..a412415c 100644 --- a/runcommandonset/Cargo.lock +++ b/runcommandonset/Cargo.lock @@ -61,6 +61,12 @@ dependencies = [ "windows-sys", ] +[[package]] +name = "anyhow" +version = "1.0.96" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6b964d184e89d9b6b67dd2715bc8e74cf3107fb2b529990c90cf517326150bf4" + [[package]] name = "arc-swap" version = "1.7.1" @@ -82,12 +88,6 @@ version = "1.3.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" -[[package]] -name = "bitflags" -version = "2.8.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8f68f53c83ab957f72c32642f3868eec03eb974d1fb82e453128456482613d36" - [[package]] name = "bstr" version = "1.11.3" @@ -106,9 +106,9 @@ checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" [[package]] name = "clap" -version = "4.5.28" +version = "4.5.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3e77c3243bd94243c03672cb5154667347c457ca271254724f9f393aee1c05ff" +checksum = "027bb0d98429ae334a8698531da7077bdf906419543a35a55c2cb1b66437d767" dependencies = [ "clap_builder", "clap_derive", @@ -116,9 +116,9 @@ dependencies = [ [[package]] name = "clap_builder" -version = "4.5.27" +version = "4.5.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1b26884eb4b57140e4d2d93652abfa49498b938b3c9179f9fc487b0acc3edad7" +checksum = "5589e0cba072e0f3d23791efac0fd8627b49c829c196a492e88168e6a669d863" dependencies = [ "anstream", "anstyle", @@ -177,43 +177,15 @@ checksum = "d0a5c400df2834b80a4c3327b3aad3a4c4cd4de0629063962b03235697506a28" [[package]] name = "either" -version = "1.13.0" +version = "1.14.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" +checksum = "b7914353092ddf589ad78f25c5c1c21b7f80b0ff8621e7c814c3485b5306da9d" [[package]] name = "equivalent" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" - -[[package]] -name = "errno" -version = "0.3.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "33d852cb9b869c2a9b3df2f71a3074817f01e1844f839a144f5fcef059a4eb5d" -dependencies = [ - "libc", - "windows-sys", -] - -[[package]] -name = "fastrand" -version = "2.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "37909eebbb50d72f9059c3b6d82c0463f2ff062c9e95845c43a6c9c0355411be" - -[[package]] -name = "getrandom" -version = "0.3.1" +version = "1.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "43a49c392881ce6d5c3b8cb70f98717b7c07aabbdff06687b9030dbfbe2725f8" -dependencies = [ - "cfg-if", - "libc", - "wasi", - "windows-targets", -] +checksum = "877a4ace8713b0bcf2a4e7eec82529c029f1d0619886d18145fea96c3ffe5c0f" [[package]] name = "glob" @@ -240,7 +212,7 @@ version = "0.8.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "93e3af942408868f6934a7b85134a3230832b9977cf66125df2f9edcfce4ddcc" dependencies = [ - "bitflags 1.3.2", + "bitflags", "ignore", "walkdir", ] @@ -310,29 +282,21 @@ version = "1.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "bbd2bcb4c963f2ddae06a2efc7e9f3591312473c50c6685e1f298068316e66fe" -[[package]] -name = "libc" -version = "0.2.169" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b5aba8db14291edd000dfcc4d620c7ebfb122c613afb886ca8803fa4e128a20a" - [[package]] name = "libyml" -version = "0.0.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "64804cc6a5042d4f05379909ba25b503ec04e2c082151d62122d5dcaa274b961" - -[[package]] -name = "linux-raw-sys" -version = "0.4.15" +version = "0.0.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d26c52dbd32dccf2d10cac7725f8eae5296885fb5703b261f7d0a0739ec807ab" +checksum = "3302702afa434ffa30847a83305f0a69d6abd74293b6554c18ec85c7ef30c980" +dependencies = [ + "anyhow", + "version_check", +] [[package]] name = "log" -version = "0.4.25" +version = "0.4.26" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "04cbf5b083de1c7e0222a7a51dbfdba1cbe1c6ab0b15e29fff3f6c077fd9cd9f" +checksum = "30bde2b3dc3671ae49d8e2e9f044c7c005836e7a023ee57cffa25ab82764bb9e" [[package]] name = "matchers" @@ -370,9 +334,9 @@ dependencies = [ [[package]] name = "once_cell" -version = "1.20.2" +version = "1.20.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1261fe7e33c73b354eab43b1273a57c8f967d0391e80353e51f764ac02cf6775" +checksum = "945462a4b81e43c4e3ba96bd7b49d834c6f61198356aa858733bc4acf3cbe62e" [[package]] name = "overload" @@ -462,9 +426,9 @@ dependencies = [ [[package]] name = "rust-i18n" -version = "3.1.2" +version = "3.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "039f57d22229db401af3458ca939300178e99e88b938573cea12b7c2b0f09724" +checksum = "71b3a6e1c6565b77c86d868eea3068b0eb39582510f9c78cfbd5c67bd36fda9b" dependencies = [ "globwalk", "once_cell", @@ -476,9 +440,9 @@ dependencies = [ [[package]] name = "rust-i18n-macro" -version = "3.1.2" +version = "3.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dde5c022360a2e54477882843d56b6f9bcb4bc62f504b651a2f497f0028d174f" +checksum = "6180d8506af2b485ffc1eab7fc6d15678336a694f2b5efac5f2ca78c52928275" dependencies = [ "glob", "once_cell", @@ -493,9 +457,9 @@ dependencies = [ [[package]] name = "rust-i18n-support" -version = "3.1.2" +version = "3.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "75d2844d36f62b5d6b66f9cf8f8cbdbbbdcdb5fd37a473a9cc2fb45fdcf485d2" +checksum = "938f16094e2b09e893b1f85c9da251739a832d4272a5957217977da3a0713bb6" dependencies = [ "arc-swap", "base62", @@ -514,19 +478,6 @@ dependencies = [ "triomphe", ] -[[package]] -name = "rustix" -version = "0.38.44" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fdb5bc1ae2baa591800df16c9ca78619bf65c0488b41b96ccec5d11220d8c154" -dependencies = [ - "bitflags 2.8.0", - "errno", - "libc", - "linux-raw-sys", - "windows-sys", -] - [[package]] name = "rustversion" version = "1.0.19" @@ -550,18 +501,18 @@ dependencies = [ [[package]] name = "serde" -version = "1.0.217" +version = "1.0.218" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "02fc4265df13d6fa1d00ecff087228cc0a2b5f3c0e87e258d8b94a156e984c70" +checksum = "e8dfc9d19bdbf6d17e22319da49161d5d0108e4188e8b680aef6299eed22df60" dependencies = [ "serde_derive", ] [[package]] name = "serde_derive" -version = "1.0.217" +version = "1.0.218" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5a9bf7cf98d04a2b28aead066b7496853d4779c9cc183c440dbac457641e19a0" +checksum = "f09503e191f4e797cb8aac08e9a4a4695c5edf6a2e70e376d961ddd5c969f82b" dependencies = [ "proc-macro2", "quote", @@ -570,9 +521,9 @@ dependencies = [ [[package]] name = "serde_json" -version = "1.0.138" +version = "1.0.139" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d434192e7da787e94a6ea7e9670b26a036d0ca41e0b7efb2676dd32bae872949" +checksum = "44f86c3acccc9c65b153fe1b85a3be07fe5515274ec9f0653b4a0875731c72a6" dependencies = [ "indexmap", "itoa", @@ -592,19 +543,17 @@ dependencies = [ [[package]] name = "serde_yml" -version = "0.0.11" +version = "0.0.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "48e76bab63c3fd98d27c17f9cbce177f64a91f5e69ac04cafe04e1bb25d1dc3c" +checksum = "59e2dd588bf1597a252c3b920e0143eb99b0f76e4e082f4c92ce34fbc9e71ddd" dependencies = [ "indexmap", "itoa", "libyml", - "log", "memchr", "ryu", "serde", - "serde_json", - "tempfile", + "version_check", ] [[package]] @@ -624,9 +573,9 @@ checksum = "56199f7ddabf13fe5074ce809e7d3f42b42ae711800501b5b16ea82ad029c39d" [[package]] name = "smallvec" -version = "1.13.2" +version = "1.14.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" +checksum = "7fcf8323ef1faaee30a44a340193b1ac6814fd9b7b4e88e9d4519a3e4abe1cfd" [[package]] name = "stable_deref_trait" @@ -651,20 +600,6 @@ dependencies = [ "unicode-ident", ] -[[package]] -name = "tempfile" -version = "3.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "38c246215d7d24f48ae091a2902398798e05d978b24315d6efbc00ede9a8bb91" -dependencies = [ - "cfg-if", - "fastrand", - "getrandom", - "once_cell", - "rustix", - "windows-sys", -] - [[package]] name = "thread_local" version = "1.1.8" @@ -677,9 +612,9 @@ dependencies = [ [[package]] name = "toml" -version = "0.7.8" +version = "0.8.20" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dd79e69d3b627db300ff956027cc6c3798cef26d22526befdfcd12feeb6d2257" +checksum = "cd87a5cdd6ffab733b2f74bc4fd7ee5fff6634124999ac278c35fc78c6120148" dependencies = [ "serde", "serde_spanned", @@ -698,9 +633,9 @@ dependencies = [ [[package]] name = "toml_edit" -version = "0.19.15" +version = "0.22.24" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1b5bb770da30e5cbfde35a2d7b9b8a2c4b8ef89548a7a6aeab5c9a576e3e7421" +checksum = "17b4795ff5edd201c7cd6dca065ae59972ce77d1b80fa0a84d94950ece7d1474" dependencies = [ "indexmap", "serde", @@ -796,9 +731,9 @@ dependencies = [ [[package]] name = "unicode-ident" -version = "1.0.16" +version = "1.0.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a210d160f08b701c8721ba1c726c11662f877ea6b7094007e1ca9a1041945034" +checksum = "00e2473a93778eb0bad35909dff6a10d28e63f792f16ed15e404fca9d5eeedbe" [[package]] name = "utf8parse" @@ -812,6 +747,12 @@ version = "0.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ba73ea9cf16a25df0c8caa16c51acb937d5712a8429db78a3ee29d5dcacd3a65" +[[package]] +name = "version_check" +version = "0.9.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0b928f33d975fc6ad9f86c8f283853ad26bdd5b10b7f1542aa2fa15e2289105a" + [[package]] name = "walkdir" version = "2.5.0" @@ -822,15 +763,6 @@ dependencies = [ "winapi-util", ] -[[package]] -name = "wasi" -version = "0.13.3+wasi-0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "26816d2e1a4a36a2940b96c5296ce403917633dff8f3440e9b236ed6f6bacad2" -dependencies = [ - "wit-bindgen-rt", -] - [[package]] name = "winapi" version = "0.3.9" @@ -937,18 +869,9 @@ checksum = "589f6da84c646204747d1270a2a5661ea66ed1cced2631d546fdfb155959f9ec" [[package]] name = "winnow" -version = "0.5.40" +version = "0.7.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f593a95398737aeed53e489c785df13f3618e41dbcd6718c6addbf1395aa6876" +checksum = "0e7f4ea97f6f78012141bcdb6a216b2609f0979ada50b20ca5b52dde2eac2bb1" dependencies = [ "memchr", ] - -[[package]] -name = "wit-bindgen-rt" -version = "0.33.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3268f3d866458b787f390cf61f4bbb563b922d091359f9608842999eaee3943c" -dependencies = [ - "bitflags 2.8.0", -] diff --git a/security_context_lib/Cargo.lock b/security_context_lib/Cargo.lock index cfbe4211..3ecee111 100644 --- a/security_context_lib/Cargo.lock +++ b/security_context_lib/Cargo.lock @@ -31,9 +31,9 @@ dependencies = [ [[package]] name = "libc" -version = "0.2.169" +version = "0.2.170" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b5aba8db14291edd000dfcc4d620c7ebfb122c613afb886ca8803fa4e128a20a" +checksum = "875b3680cb2f8f71bdcf9a30f38d48282f5d3c95cbf9b3fa57269bb5d5c06828" [[package]] name = "nix" diff --git a/tools/dsctest/Cargo.lock b/tools/dsctest/Cargo.lock index 558cd5f2..b3aa67f9 100644 --- a/tools/dsctest/Cargo.lock +++ b/tools/dsctest/Cargo.lock @@ -54,9 +54,9 @@ dependencies = [ [[package]] name = "clap" -version = "4.5.28" +version = "4.5.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3e77c3243bd94243c03672cb5154667347c457ca271254724f9f393aee1c05ff" +checksum = "027bb0d98429ae334a8698531da7077bdf906419543a35a55c2cb1b66437d767" dependencies = [ "clap_builder", "clap_derive", @@ -64,9 +64,9 @@ dependencies = [ [[package]] name = "clap_builder" -version = "4.5.27" +version = "4.5.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1b26884eb4b57140e4d2d93652abfa49498b938b3c9179f9fc487b0acc3edad7" +checksum = "5589e0cba072e0f3d23791efac0fd8627b49c829c196a492e88168e6a669d863" dependencies = [ "anstream", "anstyle", @@ -116,9 +116,9 @@ checksum = "feeef44e73baff3a26d371801df019877a9866a8c493d315ab00177843314f35" [[package]] name = "equivalent" -version = "1.0.1" +version = "1.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" +checksum = "877a4ace8713b0bcf2a4e7eec82529c029f1d0619886d18145fea96c3ffe5c0f" [[package]] name = "hashbrown" @@ -162,9 +162,9 @@ checksum = "78ca9ab1a0babb1e7d5695e3530886289c18cf2f87ec19a575a0abdce112e3a3" [[package]] name = "once_cell" -version = "1.20.2" +version = "1.20.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1261fe7e33c73b354eab43b1273a57c8f967d0391e80353e51f764ac02cf6775" +checksum = "945462a4b81e43c4e3ba96bd7b49d834c6f61198356aa858733bc4acf3cbe62e" [[package]] name = "proc-macro2" @@ -192,9 +192,9 @@ checksum = "6ea1a2d0a644769cc99faa24c3ad26b379b786fe7c36fd3c546254801650e6dd" [[package]] name = "schemars" -version = "0.8.21" +version = "0.8.22" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "09c024468a378b7e36765cd36702b7a90cc3cba11654f6685c8f233408e89e92" +checksum = "3fbf2ae1b8bc8e02df939598064d22402220cd5bbcca1c76f7d6a310974d5615" dependencies = [ "dyn-clone", "schemars_derive", @@ -204,9 +204,9 @@ dependencies = [ [[package]] name = "schemars_derive" -version = "0.8.21" +version = "0.8.22" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b1eee588578aff73f856ab961cd2f79e36bc45d7ded33a7562adba4667aecc0e" +checksum = "32e265784ad618884abaea0600a9adf15393368d840e0222d101a072f3f7534d" dependencies = [ "proc-macro2", "quote", @@ -216,18 +216,18 @@ dependencies = [ [[package]] name = "serde" -version = "1.0.217" +version = "1.0.218" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "02fc4265df13d6fa1d00ecff087228cc0a2b5f3c0e87e258d8b94a156e984c70" +checksum = "e8dfc9d19bdbf6d17e22319da49161d5d0108e4188e8b680aef6299eed22df60" dependencies = [ "serde_derive", ] [[package]] name = "serde_derive" -version = "1.0.217" +version = "1.0.218" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5a9bf7cf98d04a2b28aead066b7496853d4779c9cc183c440dbac457641e19a0" +checksum = "f09503e191f4e797cb8aac08e9a4a4695c5edf6a2e70e376d961ddd5c969f82b" dependencies = [ "proc-macro2", "quote", @@ -247,9 +247,9 @@ dependencies = [ [[package]] name = "serde_json" -version = "1.0.138" +version = "1.0.139" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d434192e7da787e94a6ea7e9670b26a036d0ca41e0b7efb2676dd32bae872949" +checksum = "44f86c3acccc9c65b153fe1b85a3be07fe5515274ec9f0653b4a0875731c72a6" dependencies = [ "indexmap", "itoa", @@ -277,9 +277,9 @@ dependencies = [ [[package]] name = "unicode-ident" -version = "1.0.16" +version = "1.0.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a210d160f08b701c8721ba1c726c11662f877ea6b7094007e1ca9a1041945034" +checksum = "00e2473a93778eb0bad35909dff6a10d28e63f792f16ed15e404fca9d5eeedbe" [[package]] name = "utf8parse" diff --git a/tools/test_group_resource/Cargo.lock b/tools/test_group_resource/Cargo.lock index a3a615ea..555f3906 100644 --- a/tools/test_group_resource/Cargo.lock +++ b/tools/test_group_resource/Cargo.lock @@ -105,6 +105,12 @@ dependencies = [ "windows-sys 0.59.0", ] +[[package]] +name = "anyhow" +version = "1.0.96" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6b964d184e89d9b6b67dd2715bc8e74cf3107fb2b529990c90cf517326150bf4" + [[package]] name = "arc-swap" version = "1.7.1" @@ -216,9 +222,9 @@ checksum = "f61dac84819c6588b558454b194026eb1f09c293b9036ae9b159e74e73ab6cf9" [[package]] name = "cc" -version = "1.2.12" +version = "1.2.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "755717a7de9ec452bf7f3f1a3099085deabd7f2962b861dae91ecd7a365903d2" +checksum = "c736e259eea577f443d5c86c304f9f4ae0295c43f3ba05c21f1d66b5f06001af" dependencies = [ "shlex", ] @@ -251,9 +257,9 @@ dependencies = [ [[package]] name = "clap" -version = "4.5.28" +version = "4.5.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3e77c3243bd94243c03672cb5154667347c457ca271254724f9f393aee1c05ff" +checksum = "027bb0d98429ae334a8698531da7077bdf906419543a35a55c2cb1b66437d767" dependencies = [ "clap_builder", "clap_derive", @@ -261,9 +267,9 @@ dependencies = [ [[package]] name = "clap_builder" -version = "4.5.27" +version = "4.5.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1b26884eb4b57140e4d2d93652abfa49498b938b3c9179f9fc487b0acc3edad7" +checksum = "5589e0cba072e0f3d23791efac0fd8627b49c829c196a492e88168e6a669d863" dependencies = [ "anstream", "anstyle", @@ -455,9 +461,9 @@ checksum = "feeef44e73baff3a26d371801df019877a9866a8c493d315ab00177843314f35" [[package]] name = "either" -version = "1.13.0" +version = "1.14.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" +checksum = "b7914353092ddf589ad78f25c5c1c21b7f80b0ff8621e7c814c3485b5306da9d" [[package]] name = "email_address" @@ -476,19 +482,9 @@ checksum = "34aa73646ffb006b8f5147f3dc182bd4bcb190227ce861fc4a4844bf8e3cb2c0" [[package]] name = "equivalent" -version = "1.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" - -[[package]] -name = "errno" -version = "0.3.10" +version = "1.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "33d852cb9b869c2a9b3df2f71a3074817f01e1844f839a144f5fcef059a4eb5d" -dependencies = [ - "libc", - "windows-sys 0.59.0", -] +checksum = "877a4ace8713b0bcf2a4e7eec82529c029f1d0619886d18145fea96c3ffe5c0f" [[package]] name = "fancy-regex" @@ -501,12 +497,6 @@ dependencies = [ "regex-syntax", ] -[[package]] -name = "fastrand" -version = "2.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "37909eebbb50d72f9059c3b6d82c0463f2ff062c9e95845c43a6c9c0355411be" - [[package]] name = "fluent-uri" version = "0.3.2" @@ -902,15 +892,19 @@ checksum = "bbd2bcb4c963f2ddae06a2efc7e9f3591312473c50c6685e1f298068316e66fe" [[package]] name = "libc" -version = "0.2.169" +version = "0.2.170" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b5aba8db14291edd000dfcc4d620c7ebfb122c613afb886ca8803fa4e128a20a" +checksum = "875b3680cb2f8f71bdcf9a30f38d48282f5d3c95cbf9b3fa57269bb5d5c06828" [[package]] name = "libyml" -version = "0.0.4" +version = "0.0.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "64804cc6a5042d4f05379909ba25b503ec04e2c082151d62122d5dcaa274b961" +checksum = "3302702afa434ffa30847a83305f0a69d6abd74293b6554c18ec85c7ef30c980" +dependencies = [ + "anyhow", + "version_check", +] [[package]] name = "linked-hash-map" @@ -918,12 +912,6 @@ version = "0.5.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "0717cef1bc8b636c6e1c1bbdefc09e6322da8a9321966e8928ef80d20f7f770f" -[[package]] -name = "linux-raw-sys" -version = "0.4.15" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d26c52dbd32dccf2d10cac7725f8eae5296885fb5703b261f7d0a0739ec807ab" - [[package]] name = "litemap" version = "0.7.4" @@ -942,9 +930,9 @@ dependencies = [ [[package]] name = "log" -version = "0.4.25" +version = "0.4.26" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "04cbf5b083de1c7e0222a7a51dbfdba1cbe1c6ab0b15e29fff3f6c077fd9cd9f" +checksum = "30bde2b3dc3671ae49d8e2e9f044c7c005836e7a023ee57cffa25ab82764bb9e" [[package]] name = "memchr" @@ -954,9 +942,9 @@ checksum = "78ca9ab1a0babb1e7d5695e3530886289c18cf2f87ec19a575a0abdce112e3a3" [[package]] name = "miniz_oxide" -version = "0.8.3" +version = "0.8.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b8402cab7aefae129c6977bb0ff1b8fd9a04eb5b51efc50a70bea51cda0c7924" +checksum = "8e3e04debbb59698c15bacbb6d93584a8c0ca9cc3213cb423d31f760d8843ce5" dependencies = [ "adler2", ] @@ -1099,9 +1087,9 @@ dependencies = [ [[package]] name = "once_cell" -version = "1.20.2" +version = "1.20.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1261fe7e33c73b354eab43b1273a57c8f967d0391e80353e51f764ac02cf6775" +checksum = "945462a4b81e43c4e3ba96bd7b49d834c6f61198356aa858733bc4acf3cbe62e" [[package]] name = "outref" @@ -1152,9 +1140,9 @@ checksum = "3b3cff922bd51709b605d9ead9aa71031d81447142d828eb4a6eba76fe619f9b" [[package]] name = "portable-atomic" -version = "1.10.0" +version = "1.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "280dc24453071f1b63954171985a0b0d30058d287960968b9b2aca264c8d4ee6" +checksum = "350e9b48cbc6b0e028b0473b114454c6316e57336ee184ceab6e53f72c178b3e" [[package]] name = "proc-macro2" @@ -1176,9 +1164,9 @@ dependencies = [ [[package]] name = "redox_syscall" -version = "0.5.8" +version = "0.5.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "03a862b389f93e68874fbf580b9de08dd02facb9a788ebadaf4a3fd33cf58834" +checksum = "82b568323e98e49e2a0899dcee453dd679fae22d69adf9b11dd508d1549b7e2f" dependencies = [ "bitflags 2.8.0", ] @@ -1247,9 +1235,9 @@ checksum = "2b15c43186be67a4fd63bee50d0303afffcef381492ebe2c5d87f324e1b8815c" [[package]] name = "rust-i18n" -version = "3.1.2" +version = "3.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "039f57d22229db401af3458ca939300178e99e88b938573cea12b7c2b0f09724" +checksum = "71b3a6e1c6565b77c86d868eea3068b0eb39582510f9c78cfbd5c67bd36fda9b" dependencies = [ "globwalk", "once_cell", @@ -1261,9 +1249,9 @@ dependencies = [ [[package]] name = "rust-i18n-macro" -version = "3.1.2" +version = "3.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dde5c022360a2e54477882843d56b6f9bcb4bc62f504b651a2f497f0028d174f" +checksum = "6180d8506af2b485ffc1eab7fc6d15678336a694f2b5efac5f2ca78c52928275" dependencies = [ "glob", "once_cell", @@ -1278,9 +1266,9 @@ dependencies = [ [[package]] name = "rust-i18n-support" -version = "3.1.2" +version = "3.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "75d2844d36f62b5d6b66f9cf8f8cbdbbbdcdb5fd37a473a9cc2fb45fdcf485d2" +checksum = "938f16094e2b09e893b1f85c9da251739a832d4272a5957217977da3a0713bb6" dependencies = [ "arc-swap", "base62", @@ -1305,19 +1293,6 @@ version = "0.1.24" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "719b953e2095829ee67db738b3bfa9fa368c94900df327b3f07fe6e794d2fe1f" -[[package]] -name = "rustix" -version = "0.38.44" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fdb5bc1ae2baa591800df16c9ca78619bf65c0488b41b96ccec5d11220d8c154" -dependencies = [ - "bitflags 2.8.0", - "errno", - "libc", - "linux-raw-sys", - "windows-sys 0.59.0", -] - [[package]] name = "rustversion" version = "1.0.19" @@ -1341,9 +1316,9 @@ dependencies = [ [[package]] name = "schemars" -version = "0.8.21" +version = "0.8.22" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "09c024468a378b7e36765cd36702b7a90cc3cba11654f6685c8f233408e89e92" +checksum = "3fbf2ae1b8bc8e02df939598064d22402220cd5bbcca1c76f7d6a310974d5615" dependencies = [ "dyn-clone", "indexmap 1.9.3", @@ -1354,9 +1329,9 @@ dependencies = [ [[package]] name = "schemars_derive" -version = "0.8.21" +version = "0.8.22" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b1eee588578aff73f856ab961cd2f79e36bc45d7ded33a7562adba4667aecc0e" +checksum = "32e265784ad618884abaea0600a9adf15393368d840e0222d101a072f3f7534d" dependencies = [ "proc-macro2", "quote", @@ -1386,18 +1361,18 @@ checksum = "f79dfe2d285b0488816f30e700a7438c5a73d816b5b7d3ac72fbc48b0d185e03" [[package]] name = "serde" -version = "1.0.217" +version = "1.0.218" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "02fc4265df13d6fa1d00ecff087228cc0a2b5f3c0e87e258d8b94a156e984c70" +checksum = "e8dfc9d19bdbf6d17e22319da49161d5d0108e4188e8b680aef6299eed22df60" dependencies = [ "serde_derive", ] [[package]] name = "serde_derive" -version = "1.0.217" +version = "1.0.218" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5a9bf7cf98d04a2b28aead066b7496853d4779c9cc183c440dbac457641e19a0" +checksum = "f09503e191f4e797cb8aac08e9a4a4695c5edf6a2e70e376d961ddd5c969f82b" dependencies = [ "proc-macro2", "quote", @@ -1417,9 +1392,9 @@ dependencies = [ [[package]] name = "serde_json" -version = "1.0.138" +version = "1.0.139" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d434192e7da787e94a6ea7e9670b26a036d0ca41e0b7efb2676dd32bae872949" +checksum = "44f86c3acccc9c65b153fe1b85a3be07fe5515274ec9f0653b4a0875731c72a6" dependencies = [ "indexmap 2.7.1", "itoa", @@ -1452,19 +1427,17 @@ dependencies = [ [[package]] name = "serde_yml" -version = "0.0.11" +version = "0.0.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "48e76bab63c3fd98d27c17f9cbce177f64a91f5e69ac04cafe04e1bb25d1dc3c" +checksum = "59e2dd588bf1597a252c3b920e0143eb99b0f76e4e082f4c92ce34fbc9e71ddd" dependencies = [ "indexmap 2.7.1", "itoa", "libyml", - "log", "memchr", "ryu", "serde", - "serde_json", - "tempfile", + "version_check", ] [[package]] @@ -1499,9 +1472,9 @@ checksum = "56199f7ddabf13fe5074ce809e7d3f42b42ae711800501b5b16ea82ad029c39d" [[package]] name = "smallvec" -version = "1.13.2" +version = "1.14.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" +checksum = "7fcf8323ef1faaee30a44a340193b1ac6814fd9b7b4e88e9d4519a3e4abe1cfd" [[package]] name = "socket2" @@ -1553,20 +1526,6 @@ dependencies = [ "syn", ] -[[package]] -name = "tempfile" -version = "3.16.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "38c246215d7d24f48ae091a2902398798e05d978b24315d6efbc00ede9a8bb91" -dependencies = [ - "cfg-if", - "fastrand", - "getrandom 0.3.1", - "once_cell", - "rustix", - "windows-sys 0.59.0", -] - [[package]] name = "test_group_resource" version = "0.1.0" @@ -1649,9 +1608,9 @@ dependencies = [ [[package]] name = "toml" -version = "0.7.8" +version = "0.8.20" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dd79e69d3b627db300ff956027cc6c3798cef26d22526befdfcd12feeb6d2257" +checksum = "cd87a5cdd6ffab733b2f74bc4fd7ee5fff6634124999ac278c35fc78c6120148" dependencies = [ "serde", "serde_spanned", @@ -1670,9 +1629,9 @@ dependencies = [ [[package]] name = "toml_edit" -version = "0.19.15" +version = "0.22.24" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1b5bb770da30e5cbfde35a2d7b9b8a2c4b8ef89548a7a6aeab5c9a576e3e7421" +checksum = "17b4795ff5edd201c7cd6dca065ae59972ce77d1b80fa0a84d94950ece7d1474" dependencies = [ "indexmap 2.7.1", "serde", @@ -1752,9 +1711,9 @@ dependencies = [ [[package]] name = "tree-sitter" -version = "0.25.1" +version = "0.25.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1a802c93485fb6781d27e27cb5927f6b00ff8d26b56c70af87267be7e99def97" +checksum = "5168a515fe492af54c5cc8800ff8c840be09fa5168de45838afaecd3e008bce4" dependencies = [ "cc", "regex", @@ -1776,9 +1735,9 @@ dependencies = [ [[package]] name = "tree-sitter-language" -version = "0.1.4" +version = "0.1.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "38eee4db33814de3d004de9d8d825627ed3320d0989cce0dea30efaf5be4736c" +checksum = "c4013970217383f67b18aef68f6fb2e8d409bc5755227092d32efb0422ba24b8" [[package]] name = "tree-sitter-rust" @@ -1803,9 +1762,9 @@ dependencies = [ [[package]] name = "unicode-ident" -version = "1.0.16" +version = "1.0.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a210d160f08b701c8721ba1c726c11662f877ea6b7094007e1ca9a1041945034" +checksum = "00e2473a93778eb0bad35909dff6a10d28e63f792f16ed15e404fca9d5eeedbe" [[package]] name = "unicode-width" @@ -1845,9 +1804,9 @@ checksum = "06abde3611657adf66d383f00b093d7faecc7fa57071cce2578660c9f1010821" [[package]] name = "uuid" -version = "1.13.1" +version = "1.14.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ced87ca4be083373936a67f8de945faa23b6b42384bd5b64434850802c6dccd0" +checksum = "93d59ca99a559661b96bf898d8fce28ed87935fd2bea9f05983c1464dd6c71b1" dependencies = [ "getrandom 0.3.1", ] @@ -2131,9 +2090,9 @@ checksum = "589f6da84c646204747d1270a2a5661ea66ed1cced2631d546fdfb155959f9ec" [[package]] name = "winnow" -version = "0.5.40" +version = "0.7.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f593a95398737aeed53e489c785df13f3618e41dbcd6718c6addbf1395aa6876" +checksum = "0e7f4ea97f6f78012141bcdb6a216b2609f0979ada50b20ca5b52dde2eac2bb1" dependencies = [ "memchr", ] diff --git a/tree-sitter-dscexpression/Cargo.lock b/tree-sitter-dscexpression/Cargo.lock index 75242c04..031aa27d 100644 --- a/tree-sitter-dscexpression/Cargo.lock +++ b/tree-sitter-dscexpression/Cargo.lock @@ -13,18 +13,18 @@ dependencies = [ [[package]] name = "cc" -version = "1.2.12" +version = "1.2.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "755717a7de9ec452bf7f3f1a3099085deabd7f2962b861dae91ecd7a365903d2" +checksum = "c736e259eea577f443d5c86c304f9f4ae0295c43f3ba05c21f1d66b5f06001af" dependencies = [ "shlex", ] [[package]] name = "equivalent" -version = "1.0.1" +version = "1.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" +checksum = "877a4ace8713b0bcf2a4e7eec82529c029f1d0619886d18145fea96c3ffe5c0f" [[package]] name = "hashbrown" @@ -109,18 +109,18 @@ checksum = "6ea1a2d0a644769cc99faa24c3ad26b379b786fe7c36fd3c546254801650e6dd" [[package]] name = "serde" -version = "1.0.217" +version = "1.0.218" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "02fc4265df13d6fa1d00ecff087228cc0a2b5f3c0e87e258d8b94a156e984c70" +checksum = "e8dfc9d19bdbf6d17e22319da49161d5d0108e4188e8b680aef6299eed22df60" dependencies = [ "serde_derive", ] [[package]] name = "serde_derive" -version = "1.0.217" +version = "1.0.218" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5a9bf7cf98d04a2b28aead066b7496853d4779c9cc183c440dbac457641e19a0" +checksum = "f09503e191f4e797cb8aac08e9a4a4695c5edf6a2e70e376d961ddd5c969f82b" dependencies = [ "proc-macro2", "quote", @@ -129,9 +129,9 @@ dependencies = [ [[package]] name = "serde_json" -version = "1.0.138" +version = "1.0.139" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d434192e7da787e94a6ea7e9670b26a036d0ca41e0b7efb2676dd32bae872949" +checksum = "44f86c3acccc9c65b153fe1b85a3be07fe5515274ec9f0653b4a0875731c72a6" dependencies = [ "indexmap", "itoa", @@ -165,9 +165,9 @@ dependencies = [ [[package]] name = "tree-sitter" -version = "0.25.1" +version = "0.25.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1a802c93485fb6781d27e27cb5927f6b00ff8d26b56c70af87267be7e99def97" +checksum = "5168a515fe492af54c5cc8800ff8c840be09fa5168de45838afaecd3e008bce4" dependencies = [ "cc", "regex", @@ -189,9 +189,9 @@ dependencies = [ [[package]] name = "tree-sitter-language" -version = "0.1.4" +version = "0.1.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "38eee4db33814de3d004de9d8d825627ed3320d0989cce0dea30efaf5be4736c" +checksum = "c4013970217383f67b18aef68f6fb2e8d409bc5755227092d32efb0422ba24b8" [[package]] name = "tree-sitter-rust" @@ -205,6 +205,6 @@ dependencies = [ [[package]] name = "unicode-ident" -version = "1.0.16" +version = "1.0.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a210d160f08b701c8721ba1c726c11662f877ea6b7094007e1ca9a1041945034" +checksum = "00e2473a93778eb0bad35909dff6a10d28e63f792f16ed15e404fca9d5eeedbe" diff --git a/y2j/Cargo.lock b/y2j/Cargo.lock index e5c02208..c84fd76e 100644 --- a/y2j/Cargo.lock +++ b/y2j/Cargo.lock @@ -79,9 +79,9 @@ dependencies = [ [[package]] name = "equivalent" -version = "1.0.1" +version = "1.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" +checksum = "877a4ace8713b0bcf2a4e7eec82529c029f1d0619886d18145fea96c3ffe5c0f" [[package]] name = "fancy-regex" @@ -95,9 +95,9 @@ dependencies = [ [[package]] name = "flate2" -version = "1.0.35" +version = "1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c936bfdafb507ebbf50b8074c54fa31c5be9a1e7e5f467dd659697041407d07c" +checksum = "11faaf5a5236997af9848be0bef4db95824b1d534ebc64d0f0c6cf3e67bd38dc" dependencies = [ "crc32fast", "miniz_oxide", @@ -145,9 +145,9 @@ checksum = "78ca9ab1a0babb1e7d5695e3530886289c18cf2f87ec19a575a0abdce112e3a3" [[package]] name = "miniz_oxide" -version = "0.8.3" +version = "0.8.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b8402cab7aefae129c6977bb0ff1b8fd9a04eb5b51efc50a70bea51cda0c7924" +checksum = "8e3e04debbb59698c15bacbb6d93584a8c0ca9cc3213cb423d31f760d8843ce5" dependencies = [ "adler2", ] @@ -160,9 +160,9 @@ checksum = "51d515d32fb182ee37cda2ccdcb92950d6a3c2893aa280e540671c2cd0f3b1d9" [[package]] name = "once_cell" -version = "1.20.2" +version = "1.20.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1261fe7e33c73b354eab43b1273a57c8f967d0391e80353e51f764ac02cf6775" +checksum = "945462a4b81e43c4e3ba96bd7b49d834c6f61198356aa858733bc4acf3cbe62e" [[package]] name = "plist" @@ -256,18 +256,18 @@ dependencies = [ [[package]] name = "serde" -version = "1.0.217" +version = "1.0.218" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "02fc4265df13d6fa1d00ecff087228cc0a2b5f3c0e87e258d8b94a156e984c70" +checksum = "e8dfc9d19bdbf6d17e22319da49161d5d0108e4188e8b680aef6299eed22df60" dependencies = [ "serde_derive", ] [[package]] name = "serde_derive" -version = "1.0.217" +version = "1.0.218" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5a9bf7cf98d04a2b28aead066b7496853d4779c9cc183c440dbac457641e19a0" +checksum = "f09503e191f4e797cb8aac08e9a4a4695c5edf6a2e70e376d961ddd5c969f82b" dependencies = [ "proc-macro2", "quote", @@ -276,9 +276,9 @@ dependencies = [ [[package]] name = "serde_json" -version = "1.0.138" +version = "1.0.139" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d434192e7da787e94a6ea7e9670b26a036d0ca41e0b7efb2676dd32bae872949" +checksum = "44f86c3acccc9c65b153fe1b85a3be07fe5515274ec9f0653b4a0875731c72a6" dependencies = [ "indexmap", "itoa", @@ -386,9 +386,9 @@ dependencies = [ [[package]] name = "unicode-ident" -version = "1.0.16" +version = "1.0.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a210d160f08b701c8721ba1c726c11662f877ea6b7094007e1ca9a1041945034" +checksum = "00e2473a93778eb0bad35909dff6a10d28e63f792f16ed15e404fca9d5eeedbe" [[package]] name = "unsafe-libyaml"