fix(tvix): add clap group id for each struct
cl/13156 did move the castore-specific URLs into their own struct, having the store one include the castore-specific struct (flattened). However, both structs had the same name, so using these structs causes clap to panic at runtime, as two groups with the same id were present. Fix this, by adding names to (all) structs. Reported-By: Domen Kožar <domen@cachix.org> Change-Id: I34064f7fb2fbbc19d836e1486ad84b52548d2ee1 Reviewed-on: https://cl.tvl.fyi/c/depot/+/13247 Tested-by: BuildkiteCI Reviewed-by: Domen Kožar <domen@cachix.org> Reviewed-by: Marijan Petričević <marijan.petricevic94@gmail.com> Autosubmit: flokli <flokli@flokli.de>
This commit is contained in:
parent
0d5effa7a6
commit
a0b6fad637
2 changed files with 6 additions and 0 deletions
|
|
@ -23,6 +23,7 @@ pub struct CompositionConfigs {
|
|||
/// This particular variant has defaults tailored for usecases accessing data
|
||||
/// directly locally, like the `tvix-store daemon` command.
|
||||
#[derive(clap::Parser, Clone)]
|
||||
#[group(id = "CastoreServiceUrls")]
|
||||
pub struct ServiceUrls {
|
||||
#[arg(
|
||||
long,
|
||||
|
|
@ -51,6 +52,7 @@ pub struct ServiceUrls {
|
|||
/// This particular variant has defaults tailored for usecases accessing data
|
||||
/// from another running tvix daemon, via gRPC.
|
||||
#[derive(clap::Parser, Clone)]
|
||||
#[group(id = "CastoreServiceUrlsGrpc")]
|
||||
pub struct ServiceUrlsGrpc {
|
||||
#[arg(long, env, default_value = "grpc+http://[::1]:8000")]
|
||||
blob_service_addr: String,
|
||||
|
|
@ -71,6 +73,7 @@ pub struct ServiceUrlsGrpc {
|
|||
/// there yet, and using something else here might make some perf output harder
|
||||
/// to interpret.
|
||||
#[derive(clap::Parser, Clone)]
|
||||
#[group(id = "CastoreServiceUrlsMemory")]
|
||||
pub struct ServiceUrlsMemory {
|
||||
#[arg(long, env, default_value = "memory://")]
|
||||
blob_service_addr: String,
|
||||
|
|
|
|||
|
|
@ -36,6 +36,7 @@ pub struct CompositionConfigs {
|
|||
/// This particular variant has defaults tailored for usecases accessing data
|
||||
/// directly locally, like the `tvix-store daemon` command.
|
||||
#[derive(clap::Parser, Clone)]
|
||||
#[group(id = "StoreServiceUrls")]
|
||||
pub struct ServiceUrls {
|
||||
#[clap(flatten)]
|
||||
castore_service_addrs: castore_utils::ServiceUrls,
|
||||
|
|
@ -56,6 +57,7 @@ pub struct ServiceUrls {
|
|||
/// This particular variant has defaults tailored for usecases accessing data
|
||||
/// from another running tvix daemon, via gRPC.
|
||||
#[derive(clap::Parser, Clone)]
|
||||
#[group(id = "StoreServiceUrlsGrpc")]
|
||||
pub struct ServiceUrlsGrpc {
|
||||
#[clap(flatten)]
|
||||
castore_service_addrs: castore_utils::ServiceUrlsGrpc,
|
||||
|
|
@ -76,6 +78,7 @@ pub struct ServiceUrlsGrpc {
|
|||
/// there yet, and using something else here might make some perf output harder
|
||||
/// to interpret.
|
||||
#[derive(clap::Parser, Clone)]
|
||||
#[group(id = "StoreServiceUrlsMemory")]
|
||||
pub struct ServiceUrlsMemory {
|
||||
#[clap(flatten)]
|
||||
castore_service_addrs: castore_utils::ServiceUrlsMemory,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue