Summary
urlbox storage list and storage show render an empty PROVIDER column for a fully configured S3 credential, because the label lookup reads provider while the API returns the kind in type.
Reproduce
-
Have an org with an S3 storage credential (bucket, region, key/secret all set, assigned to a project).
-
List it:
Expected
│ BUCKET │ ID │ PROVIDER │ … │
│ my-bucket│ store_xxx │ AWS S3 │ … │
Actual
PROVIDER is blank:
┌───────────┬────────────┬──────────┬──────────┬─────────┬──────────┐
│ BUCKET │ ID │ PROVIDER │ ENDPOINT │ KEY │ ASSIGNED │
├───────────┼────────────┼──────────┼──────────┼─────────┼──────────┤
│ my-bucket │ store_xxx │ │ │ AKIA…NN │ 1 │
└───────────┴────────────┴──────────┴──────────┴─────────┴──────────┘
This is not an unconfigured account — the credential works and is assigned to a project. The JSON shows why:
{
"bucket": "my-bucket",
"id": "store_xxx",
"provider": null,
"type": "s3",
"region": "eu-west-2"
}
provider is null; the kind lives in type.
Cause
internal/cmd/storage.go:141:
func storageProviderLabel(c map[string]any) string {
provider := valueOrEmpty(c["provider"])
if valueOrEmpty(c["type"]) == "azure" {
provider = "azure"
}
if label, ok := storageProviderLabels[provider]; ok {
return label
}
return provider
}
It reads c["provider"], and only falls back to type for the single azure case. The label map is keyed on create-time slugs (aws_s3, google_cloud_storage, cloudflare_r2, …), so the API's type: "s3" matches nothing and the function returns "".
Open question
Which field is canonical? The create command takes --provider aws_s3, but this record (created via the dashboard) has provider: null / type: "s3". If both can be populated depending on origin, the label function needs to consult type generally — not just for azure — with a mapping from API type values (s3, gcs, r2, …) to the display labels. Flagging rather than patching, since the right mapping depends on what the API guarantees.
Environment
urlbox 1.2.0 (commit 5530665), Linux.
Summary
urlbox storage listandstorage showrender an emptyPROVIDERcolumn for a fully configured S3 credential, because the label lookup readsproviderwhile the API returns the kind intype.Reproduce
Have an org with an S3 storage credential (bucket, region, key/secret all set, assigned to a project).
List it:
Expected
Actual
PROVIDERis blank:This is not an unconfigured account — the credential works and is assigned to a project. The JSON shows why:
{ "bucket": "my-bucket", "id": "store_xxx", "provider": null, "type": "s3", "region": "eu-west-2" }providerisnull; the kind lives intype.Cause
internal/cmd/storage.go:141:It reads
c["provider"], and only falls back totypefor the singleazurecase. The label map is keyed on create-time slugs (aws_s3,google_cloud_storage,cloudflare_r2, …), so the API'stype: "s3"matches nothing and the function returns"".Open question
Which field is canonical? The
createcommand takes--provider aws_s3, but this record (created via the dashboard) hasprovider: null/type: "s3". If both can be populated depending on origin, the label function needs to consulttypegenerally — not just forazure— with a mapping from APItypevalues (s3,gcs,r2, …) to the display labels. Flagging rather than patching, since the right mapping depends on what the API guarantees.Environment
urlbox 1.2.0(commit 5530665), Linux.