From cfc201786f178771879c55fba710f933afab3c23 Mon Sep 17 00:00:00 2001 From: Steven Masley Date: Mon, 14 Apr 2025 11:37:19 -0500 Subject: [PATCH 01/61] chore: bad default values should throw errors --- cli/clidisplay/resources.go | 6 ++- extract/parameter.go | 7 +++- go.mod | 2 +- go.sum | 4 +- types/convert.go | 73 +++++++++++++++++++++++++++++++++++++ types/enum.go | 5 ++- types/parameter.go | 40 ++++++++++++++------ 7 files changed, 120 insertions(+), 17 deletions(-) create mode 100644 types/convert.go diff --git a/cli/clidisplay/resources.go b/cli/clidisplay/resources.go index ac93025..aad72ba 100644 --- a/cli/clidisplay/resources.go +++ b/cli/clidisplay/resources.go @@ -77,9 +77,13 @@ func Parameters(writer io.Writer, params []types.Parameter, files map[string]*hc //} else { // strVal = value.GoString() //} + dp := p.DisplayName + if p.DisplayName == "" { + dp = p.Name + } tableWriter.AppendRow(table.Row{ - fmt.Sprintf("(%s) %s: %s\n%s", p.DisplayName, p.Name, p.Description, formatOptions(selections, p.Options)), + fmt.Sprintf("(%s) %s: %s\n%s", dp, p.Name, p.Description, formatOptions(selections, p.Options)), }) if hcl.Diagnostics(p.Diagnostics).HasErrors() { diff --git a/extract/parameter.go b/extract/parameter.go index 3851635..faae374 100644 --- a/extract/parameter.go +++ b/extract/parameter.go @@ -173,6 +173,12 @@ func ParameterFromBlock(block *terraform.Block) (*types.Parameter, hcl.Diagnosti } } + if !diags.HasErrors() { + // Only do this validation if the parameter is valid, as if some errors + // exist, then this is likely to fail be excess information. + diags = diags.Extend(p.Valid()) + } + usageDiags := ParameterUsageDiagnostics(p) if usageDiags.HasErrors() { p.FormType = provider.ParameterFormTypeError @@ -243,7 +249,6 @@ func ParameterValidationFromBlock(block *terraform.Block) (types.ParameterValida Min: nullableInteger(block, "min"), Max: nullableInteger(block, "max"), Monotonic: nullableString(block, "monotonic"), - Invalid: nullableBoolean(block, "invalid"), } return p, diags diff --git a/go.mod b/go.mod index 84a2d03..8a0ca87 100644 --- a/go.mod +++ b/go.mod @@ -9,7 +9,7 @@ require ( github.com/aquasecurity/trivy v0.58.2 github.com/coder/guts v1.0.2-0.20250227211802-139809366a22 github.com/coder/serpent v0.10.0 - github.com/coder/terraform-provider-coder/v2 v2.4.0-pre0 + github.com/coder/terraform-provider-coder/v2 v2.4.0-pre0.0.20250414140516-f66adaca2adf github.com/coder/websocket v1.8.13 github.com/go-chi/chi v4.1.2+incompatible github.com/google/uuid v1.6.0 diff --git a/go.sum b/go.sum index 68ca4f3..72803d2 100644 --- a/go.sum +++ b/go.sum @@ -718,8 +718,8 @@ github.com/coder/pretty v0.0.0-20230908205945-e89ba86370e0 h1:3A0ES21Ke+FxEM8CXx github.com/coder/pretty v0.0.0-20230908205945-e89ba86370e0/go.mod h1:5UuS2Ts+nTToAMeOjNlnHFkPahrtDkmpydBen/3wgZc= github.com/coder/serpent v0.10.0 h1:ofVk9FJXSek+SmL3yVE3GoArP83M+1tX+H7S4t8BSuM= github.com/coder/serpent v0.10.0/go.mod h1:cZFW6/fP+kE9nd/oRkEHJpG6sXCtQ+AX7WMMEHv0Y3Q= -github.com/coder/terraform-provider-coder/v2 v2.4.0-pre0 h1:NPt2+FVr+2QJoxrta5ZwyTaxocWMEKdh2WpIumffxfM= -github.com/coder/terraform-provider-coder/v2 v2.4.0-pre0/go.mod h1:X28s3rz+aEM5PkBKvk3xcUrQFO2eNPjzRChUg9wb70U= +github.com/coder/terraform-provider-coder/v2 v2.4.0-pre0.0.20250414140516-f66adaca2adf h1:h0ZMBLv/NiHeMWANSiUKHZkuxti4zIWCGXAXYF0tuJQ= +github.com/coder/terraform-provider-coder/v2 v2.4.0-pre0.0.20250414140516-f66adaca2adf/go.mod h1:X28s3rz+aEM5PkBKvk3xcUrQFO2eNPjzRChUg9wb70U= github.com/coder/websocket v1.8.13 h1:f3QZdXy7uGVz+4uCJy2nTZyM0yTBj8yANEHhqlXZ9FE= github.com/coder/websocket v1.8.13/go.mod h1:LNVeNrXQZfe5qhS9ALED3uA+l5pPqvwXg3CKoDBB2gs= github.com/containerd/log v0.1.0 h1:TCJt7ioM2cr/tfR8GPbGf9/VRAX8D2B4PjzCpfX540I= diff --git a/types/convert.go b/types/convert.go new file mode 100644 index 0000000..f8ee948 --- /dev/null +++ b/types/convert.go @@ -0,0 +1,73 @@ +package types + +import ( + "github.com/hashicorp/hcl/v2" + "github.com/hashicorp/terraform-plugin-sdk/v2/diag" + + "github.com/coder/terraform-provider-coder/v2/provider" +) + +func providerValidations(vals []*ParameterValidation) []provider.Validation { + cpy := make([]provider.Validation, 0, len(vals)) + for _, val := range vals { + cpy = append(cpy, providerValidation(val)) + } + return cpy +} + +func providerValidation(v *ParameterValidation) provider.Validation { + return provider.Validation{ + Min: int(orZero(v.Min)), + MinDisabled: v.Min == nil, + Max: int(orZero(v.Max)), + MaxDisabled: v.Max == nil, + Monotonic: orZero(v.Monotonic), + Regex: orZero(v.Regex), + Error: v.Error, + } +} + +func providerOptions(opts []*ParameterOption) []provider.Option { + cpy := make([]provider.Option, 0, len(opts)) + for _, opt := range opts { + cpy = append(cpy, providerOption(opt)) + } + return cpy +} + +func providerOption(opt *ParameterOption) provider.Option { + return provider.Option{ + Name: opt.Name, + Description: opt.Description, + Value: opt.Value.AsString(), + Icon: opt.Icon, + } +} + +func hclDiagnostics(diagnostics diag.Diagnostics) hcl.Diagnostics { + cpy := make(hcl.Diagnostics, 0, len(diagnostics)) + for _, d := range diagnostics { + cpy = append(cpy, hclDiagnostic(d)) + } + return cpy +} + +func hclDiagnostic(d diag.Diagnostic) *hcl.Diagnostic { + sev := hcl.DiagInvalid + switch d.Severity { + case diag.Error: + sev = hcl.DiagError + case diag.Warning: + sev = hcl.DiagWarning + } + return &hcl.Diagnostic{ + Severity: sev, + Summary: d.Summary, + Detail: d.Detail, + Subject: nil, + Context: nil, + Expression: nil, + EvalContext: nil, + Extra: nil, + } +} diff --git a/types/enum.go b/types/enum.go index ab29945..190668b 100644 --- a/types/enum.go +++ b/types/enum.go @@ -3,9 +3,12 @@ package types import ( "fmt" "strings" + + "github.com/coder/terraform-provider-coder/v2/provider" ) -type ParameterType string +// TODO: Just use the provider type directly. +type ParameterType provider.OptionType const ( ParameterTypeString ParameterType = "string" diff --git a/types/parameter.go b/types/parameter.go index 6f58ff2..90f8c79 100644 --- a/types/parameter.go +++ b/types/parameter.go @@ -6,6 +6,7 @@ import ( "strings" "github.com/aquasecurity/trivy/pkg/iac/terraform" + "github.com/hashicorp/hcl/v2" "github.com/zclconf/go-cty/cty" "github.com/coder/terraform-provider-coder/v2/provider" @@ -73,24 +74,16 @@ type ParameterValidation struct { Min *int64 `json:"validation_min"` Max *int64 `json:"validation_max"` Monotonic *string `json:"validation_monotonic"` - Invalid *bool `json:"validation_invalid"` } // Valid takes the type of the value and the value itself and returns an error // if the value is invalid. -func (v ParameterValidation) Valid(typ string, value string) error { +func (v *ParameterValidation) Valid(typ string, value string) error { // TODO: Validate typ is the enum? // Use the provider.Validation struct to validate the value to be // consistent with the provider. - return (&provider.Validation{ - Min: int(orZero(v.Min)), - MinDisabled: v.Min == nil, - Max: int(orZero(v.Max)), - MaxDisabled: v.Max == nil, - Monotonic: orZero(v.Monotonic), - Regex: orZero(v.Regex), - Error: v.Error, - }).Valid(provider.OptionType(typ), value) + pv := providerValidation(v) + return (&pv).Valid(provider.OptionType(typ), value) } type ParameterOption struct { @@ -100,6 +93,31 @@ type ParameterOption struct { Icon string `json:"icon"` } +func (r *ParameterData) Valid() hcl.Diagnostics { + diag := (&provider.Parameter{ + Name: r.Name, + DisplayName: r.DisplayName, + Description: r.Description, + Type: provider.OptionType(r.Type), + FormType: r.FormType, + Mutable: r.Mutable, + Default: r.DefaultValue.AsString(), + Icon: r.Icon, + Option: providerOptions(r.Options), + Validation: providerValidations(r.Validations), + Optional: false, + Order: int(r.Order), + Ephemeral: r.Ephemeral, + }).Valid() + + if diag.HasError() { + // TODO: We can take the attr path and decorate the error with + // source information. + return hclDiagnostics(diag) + } + return nil +} + // CtyType returns the cty.Type for the ParameterData. // A fixed set of types are supported. func (r *ParameterData) CtyType() (cty.Type, error) { From db2467948150ac3882b685334c962b0434be1b0c Mon Sep 17 00:00:00 2001 From: Steven Masley Date: Wed, 16 Apr 2025 09:55:12 -0500 Subject: [PATCH 02/61] add more error context --- types/convert.go | 30 ++++++++++++++++++++++++++---- types/parameter.go | 2 +- 2 files changed, 27 insertions(+), 5 deletions(-) diff --git a/types/convert.go b/types/convert.go index f8ee948..354db93 100644 --- a/types/convert.go +++ b/types/convert.go @@ -1,8 +1,15 @@ package types import ( + "fmt" + + "github.com/aquasecurity/trivy/pkg/iac/terraform" "github.com/hashicorp/hcl/v2" "github.com/hashicorp/terraform-plugin-sdk/v2/diag" + "github.com/zclconf/go-cty/cty" + hcty "github.com/hashicorp/go-cty/cty" + hctyjson "github.com/hashicorp/go-cty/cty/json" + ctyjson "github.com/zclconf/go-cty/cty/json" "github.com/coder/terraform-provider-coder/v2/provider" ) @@ -44,15 +51,15 @@ func providerOption(opt *ParameterOption) provider.Option { } } -func hclDiagnostics(diagnostics diag.Diagnostics) hcl.Diagnostics { +func hclDiagnostics(diagnostics diag.Diagnostics, source *terraform.Block) hcl.Diagnostics { cpy := make(hcl.Diagnostics, 0, len(diagnostics)) for _, d := range diagnostics { - cpy = append(cpy, hclDiagnostic(d)) + cpy = append(cpy, hclDiagnostic(d, source)) } return cpy } -func hclDiagnostic(d diag.Diagnostic) *hcl.Diagnostic { +func hclDiagnostic(d diag.Diagnostic, source *terraform.Block) *hcl.Diagnostic { sev := hcl.DiagInvalid switch d.Severity { case diag.Error: @@ -60,11 +67,26 @@ func hclDiagnostic(d diag.Diagnostic) *hcl.Diagnostic { case diag.Warning: sev = hcl.DiagWarning } + + // This is an imperfect way to finding the source code of the error. There is 2 + // different `cty` types at place here, the hashicorp fork and the original. So a + // more general solution is difficult. This is good enough for now to add more + // context to an error. + var subject *hcl.Range + if len(d.AttributePath) == 1 && source != nil { + if attr, ok := d.AttributePath[0].(hcty.GetAttrStep); ok { + src := source.GetAttribute(attr.Name) + if src != nil { + subject = &(src.HCLAttribute().Range) + } + } + } + return &hcl.Diagnostic{ Severity: sev, Summary: d.Summary, Detail: d.Detail, - Subject: nil, + Subject: subject, Context: nil, Expression: nil, EvalContext: nil, diff --git a/types/parameter.go b/types/parameter.go index 90f8c79..ffa0504 100644 --- a/types/parameter.go +++ b/types/parameter.go @@ -113,7 +113,7 @@ func (r *ParameterData) Valid() hcl.Diagnostics { if diag.HasError() { // TODO: We can take the attr path and decorate the error with // source information. - return hclDiagnostics(diag) + return hclDiagnostics(diag, source) } return nil } From ed766d08f9cd3056fda489494df8051b91f0a3fa Mon Sep 17 00:00:00 2001 From: Steven Masley Date: Wed, 16 Apr 2025 09:55:33 -0500 Subject: [PATCH 03/61] add more error context --- types/convert.go | 7 +------ types/parameter.go | 2 +- 2 files changed, 2 insertions(+), 7 deletions(-) diff --git a/types/convert.go b/types/convert.go index 354db93..3d395e5 100644 --- a/types/convert.go +++ b/types/convert.go @@ -1,15 +1,10 @@ package types import ( - "fmt" - "github.com/aquasecurity/trivy/pkg/iac/terraform" + hcty "github.com/hashicorp/go-cty/cty" "github.com/hashicorp/hcl/v2" "github.com/hashicorp/terraform-plugin-sdk/v2/diag" - "github.com/zclconf/go-cty/cty" - hcty "github.com/hashicorp/go-cty/cty" - hctyjson "github.com/hashicorp/go-cty/cty/json" - ctyjson "github.com/zclconf/go-cty/cty/json" "github.com/coder/terraform-provider-coder/v2/provider" ) diff --git a/types/parameter.go b/types/parameter.go index ffa0504..cf2565b 100644 --- a/types/parameter.go +++ b/types/parameter.go @@ -113,7 +113,7 @@ func (r *ParameterData) Valid() hcl.Diagnostics { if diag.HasError() { // TODO: We can take the attr path and decorate the error with // source information. - return hclDiagnostics(diag, source) + return hclDiagnostics(diag, r.Source) } return nil } From 3fcc847522f0f7c402fc84bb52bf1f0dd545caf7 Mon Sep 17 00:00:00 2001 From: Steven Masley Date: Mon, 5 May 2025 10:40:53 -0500 Subject: [PATCH 04/61] terraform provider dep update --- go.mod | 6 +++--- go.sum | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/go.mod b/go.mod index 7ea2251..ea18140 100644 --- a/go.mod +++ b/go.mod @@ -7,14 +7,16 @@ require ( github.com/aquasecurity/trivy v0.58.2 github.com/coder/guts v1.0.2-0.20250227211802-139809366a22 github.com/coder/serpent v0.10.0 - github.com/coder/terraform-provider-coder/v2 v2.4.0-pre1.0.20250417100258-c86bb5c3ddcd + github.com/coder/terraform-provider-coder/v2 v2.4.0-pre1.0.20250502142605-22f12cb73817 github.com/coder/websocket v1.8.13 github.com/go-chi/chi v4.1.2+incompatible + github.com/hashicorp/go-cty v1.4.1-0.20200414143053-d3edf31b6320 github.com/hashicorp/go-version v1.7.0 github.com/hashicorp/hc-install v0.9.2 github.com/hashicorp/hcl/v2 v2.23.0 github.com/hashicorp/terraform-exec v0.23.0 github.com/hashicorp/terraform-json v0.24.0 + github.com/hashicorp/terraform-plugin-sdk/v2 v2.36.1 github.com/jedib0t/go-pretty/v6 v6.6.7 github.com/stretchr/testify v1.10.0 github.com/zclconf/go-cty v1.16.2 @@ -69,7 +71,6 @@ require ( github.com/googleapis/gax-go/v2 v2.14.1 // indirect github.com/hashicorp/errwrap v1.1.0 // indirect github.com/hashicorp/go-cleanhttp v0.5.2 // indirect - github.com/hashicorp/go-cty v1.4.1-0.20200414143053-d3edf31b6320 // indirect github.com/hashicorp/go-getter v1.7.8 // indirect github.com/hashicorp/go-hclog v1.6.3 // indirect github.com/hashicorp/go-multierror v1.1.1 // indirect @@ -79,7 +80,6 @@ require ( github.com/hashicorp/logutils v1.0.0 // indirect github.com/hashicorp/terraform-plugin-go v0.26.0 // indirect github.com/hashicorp/terraform-plugin-log v0.9.0 // indirect - github.com/hashicorp/terraform-plugin-sdk/v2 v2.36.1 // indirect github.com/jmespath/go-jmespath v0.4.1-0.20220621161143-b0104c826a24 // indirect github.com/klauspost/compress v1.17.11 // indirect github.com/lucasb-eyer/go-colorful v1.2.0 // indirect diff --git a/go.sum b/go.sum index c22d751..81daf7e 100644 --- a/go.sum +++ b/go.sum @@ -718,8 +718,8 @@ github.com/coder/pretty v0.0.0-20230908205945-e89ba86370e0 h1:3A0ES21Ke+FxEM8CXx github.com/coder/pretty v0.0.0-20230908205945-e89ba86370e0/go.mod h1:5UuS2Ts+nTToAMeOjNlnHFkPahrtDkmpydBen/3wgZc= github.com/coder/serpent v0.10.0 h1:ofVk9FJXSek+SmL3yVE3GoArP83M+1tX+H7S4t8BSuM= github.com/coder/serpent v0.10.0/go.mod h1:cZFW6/fP+kE9nd/oRkEHJpG6sXCtQ+AX7WMMEHv0Y3Q= -github.com/coder/terraform-provider-coder/v2 v2.4.0-pre1.0.20250417100258-c86bb5c3ddcd h1:FsIG6Fd0YOEK7D0Hl/CJywRA+Y6Gd5RQbSIa2L+/BmE= -github.com/coder/terraform-provider-coder/v2 v2.4.0-pre1.0.20250417100258-c86bb5c3ddcd/go.mod h1:56/KdGYaA+VbwXJbTI8CA57XPfnuTxN8rjxbR34PbZw= +github.com/coder/terraform-provider-coder/v2 v2.4.0-pre1.0.20250502142605-22f12cb73817 h1:4ryzTbgCe+AHk/G03y48Rtg3Y+pfr5FfhGt/eEckJ6g= +github.com/coder/terraform-provider-coder/v2 v2.4.0-pre1.0.20250502142605-22f12cb73817/go.mod h1:56/KdGYaA+VbwXJbTI8CA57XPfnuTxN8rjxbR34PbZw= github.com/coder/websocket v1.8.13 h1:f3QZdXy7uGVz+4uCJy2nTZyM0yTBj8yANEHhqlXZ9FE= github.com/coder/websocket v1.8.13/go.mod h1:LNVeNrXQZfe5qhS9ALED3uA+l5pPqvwXg3CKoDBB2gs= github.com/containerd/log v0.1.0 h1:TCJt7ioM2cr/tfR8GPbGf9/VRAX8D2B4PjzCpfX540I= From 1a0b055a14938448e34705a5625e454ecf90af7b Mon Sep 17 00:00:00 2001 From: Steven Masley Date: Mon, 5 May 2025 15:36:58 -0500 Subject: [PATCH 05/61] accept empty default values --- extract/parameter.go | 51 +++++++++-------------------------- go.mod | 2 +- go.sum | 4 +-- preview_test.go | 10 +++++++ testdata/emptydefault/main.tf | 26 ++++++++++++++++++ types/parameter.go | 21 ++++++++++++--- types/value.go | 8 ++++++ 7 files changed, 77 insertions(+), 45 deletions(-) create mode 100644 testdata/emptydefault/main.tf diff --git a/extract/parameter.go b/extract/parameter.go index faae374..b5b3b05 100644 --- a/extract/parameter.go +++ b/extract/parameter.go @@ -50,7 +50,7 @@ func ParameterFromBlock(block *terraform.Block) (*types.Parameter, hcl.Diagnosti pVal := richParameterValue(block) - def := types.StringLiteral("") + def := types.NullString() defAttr := block.GetAttribute("default") if !defAttr.IsNil() { def = types.ToHCLString(block, defAttr) @@ -138,45 +138,10 @@ func ParameterFromBlock(block *terraform.Block) (*types.Parameter, hcl.Diagnosti p.Validations = append(p.Validations, &valid) } - ctyType, err := p.CtyType() - if err != nil { - paramTypeDiag := &hcl.Diagnostic{ - Severity: hcl.DiagError, - Summary: fmt.Sprintf("Invalid parameter type %q", p.Type), - Detail: err.Error(), - Context: &block.HCLBlock().DefRange, - } - - if attr := block.GetAttribute("type"); attr != nil && !attr.IsNil() { - paramTypeDiag.Subject = &attr.HCLAttribute().Range - paramTypeDiag.Expression = attr.HCLAttribute().Expr - paramTypeDiag.EvalContext = block.Context().Inner() - } - diags = diags.Append(paramTypeDiag) - p.FormType = provider.ParameterFormTypeError - } - - if ctyType != cty.NilType && pVal.Value.Type().Equals(cty.String) { - // TODO: Wish we could support more types, but only string types are - // allowed. - valStr := pVal.Value.AsString() - // Apply validations to the parameter value - for _, v := range p.Validations { - if err := v.Valid(string(pType), valStr); err != nil { - diags = diags.Append(&hcl.Diagnostic{ - Severity: hcl.DiagError, - Summary: fmt.Sprintf("Paramater validation failed for value %q", valStr), - Detail: err.Error(), - Expression: pVal.ValueExpr, - }) - } - } - } - if !diags.HasErrors() { // Only do this validation if the parameter is valid, as if some errors // exist, then this is likely to fail be excess information. - diags = diags.Extend(p.Valid()) + diags = diags.Extend(p.Valid(p.Value)) } usageDiags := ParameterUsageDiagnostics(p) @@ -194,7 +159,9 @@ func ParameterFromBlock(block *terraform.Block) (*types.Parameter, hcl.Diagnosti func ParameterUsageDiagnostics(p types.Parameter) hcl.Diagnostics { valErr := "The value of a parameter is required to be sourced (default or input) for the parameter to function." var diags hcl.Diagnostics - if !p.Value.Valid() { + if p.Value.Value.IsNull() { + // Allow null values + } else if !p.Value.Valid() { diags = diags.Append(&hcl.Diagnostic{ Severity: hcl.DiagError, Summary: "Parameter value is not valid", @@ -478,6 +445,14 @@ func richParameterValue(block *terraform.Block) types.HCLString { val, diags := valRef.Value(block.Context().Inner()) source := hclext.CreateDotReferenceFromTraversal(valRef.Traversal) + + // If no value attribute exists, then the value is `null`. + if diags.HasErrors() && diags[0].Summary == "Unsupported attribute" { + s := types.NullString() + s.Source = &source + return s + } + return types.HCLString{ Value: val, ValueDiags: diags, diff --git a/go.mod b/go.mod index ea18140..f332927 100644 --- a/go.mod +++ b/go.mod @@ -7,7 +7,7 @@ require ( github.com/aquasecurity/trivy v0.58.2 github.com/coder/guts v1.0.2-0.20250227211802-139809366a22 github.com/coder/serpent v0.10.0 - github.com/coder/terraform-provider-coder/v2 v2.4.0-pre1.0.20250502142605-22f12cb73817 + github.com/coder/terraform-provider-coder/v2 v2.4.0-pre1.0.20250505161541-0fd96eeace73 github.com/coder/websocket v1.8.13 github.com/go-chi/chi v4.1.2+incompatible github.com/hashicorp/go-cty v1.4.1-0.20200414143053-d3edf31b6320 diff --git a/go.sum b/go.sum index 81daf7e..e797eda 100644 --- a/go.sum +++ b/go.sum @@ -718,8 +718,8 @@ github.com/coder/pretty v0.0.0-20230908205945-e89ba86370e0 h1:3A0ES21Ke+FxEM8CXx github.com/coder/pretty v0.0.0-20230908205945-e89ba86370e0/go.mod h1:5UuS2Ts+nTToAMeOjNlnHFkPahrtDkmpydBen/3wgZc= github.com/coder/serpent v0.10.0 h1:ofVk9FJXSek+SmL3yVE3GoArP83M+1tX+H7S4t8BSuM= github.com/coder/serpent v0.10.0/go.mod h1:cZFW6/fP+kE9nd/oRkEHJpG6sXCtQ+AX7WMMEHv0Y3Q= -github.com/coder/terraform-provider-coder/v2 v2.4.0-pre1.0.20250502142605-22f12cb73817 h1:4ryzTbgCe+AHk/G03y48Rtg3Y+pfr5FfhGt/eEckJ6g= -github.com/coder/terraform-provider-coder/v2 v2.4.0-pre1.0.20250502142605-22f12cb73817/go.mod h1:56/KdGYaA+VbwXJbTI8CA57XPfnuTxN8rjxbR34PbZw= +github.com/coder/terraform-provider-coder/v2 v2.4.0-pre1.0.20250505161541-0fd96eeace73 h1:Gax/pSsln9cSTueP5teoWM4EPqEux4BUp7VlECiuW2M= +github.com/coder/terraform-provider-coder/v2 v2.4.0-pre1.0.20250505161541-0fd96eeace73/go.mod h1:2kaBpn5k9ZWtgKq5k4JbkVZG9DzEqR4mJSmpdshcO+s= github.com/coder/websocket v1.8.13 h1:f3QZdXy7uGVz+4uCJy2nTZyM0yTBj8yANEHhqlXZ9FE= github.com/coder/websocket v1.8.13/go.mod h1:LNVeNrXQZfe5qhS9ALED3uA+l5pPqvwXg3CKoDBB2gs= github.com/containerd/log v0.1.0 h1:TCJt7ioM2cr/tfR8GPbGf9/VRAX8D2B4PjzCpfX540I= diff --git a/preview_test.go b/preview_test.go index 0c91d36..f0061e3 100644 --- a/preview_test.go +++ b/preview_test.go @@ -211,6 +211,16 @@ func Test_Extract(t *testing.T) { unknownTags: []string{}, params: map[string]assertParam{}, }, + { + name: "empty default", + dir: "emptydefault", + expTags: map[string]string{}, + input: preview.Input{}, + unknownTags: []string{}, + params: map[string]assertParam{ + "word": ap(), + }, + }, { name: "many modules", dir: "manymodules", diff --git a/testdata/emptydefault/main.tf b/testdata/emptydefault/main.tf new file mode 100644 index 0000000..baa398e --- /dev/null +++ b/testdata/emptydefault/main.tf @@ -0,0 +1,26 @@ +terraform { + required_providers { + coder = { + source = "coder/coder" + version = "2.4.0-pre0" + } + } +} + +data "coder_parameter" "word" { + name = "word" + description = "Select something" + type = "string" + order = 1 + # No default selected + + option { + name = "Bird" + value = "bird" + description = "An animal that can fly." + } + option { + name = "Boat" + value = "boat" + } +} diff --git a/types/parameter.go b/types/parameter.go index cf2565b..ebb8988 100644 --- a/types/parameter.go +++ b/types/parameter.go @@ -93,22 +93,35 @@ type ParameterOption struct { Icon string `json:"icon"` } -func (r *ParameterData) Valid() hcl.Diagnostics { - diag := (&provider.Parameter{ +func (r *ParameterData) Valid(value HCLString) hcl.Diagnostics { + var defPtr *string + if !r.DefaultValue.Value.IsNull() { + def := r.DefaultValue.Value.AsString() + defPtr = &def + } + + var valuePtr *string + // TODO: What to do if it is not valid? + if value.Valid() { + val := value.Value.AsString() + valuePtr = &val + } + + _, diag := (&provider.Parameter{ Name: r.Name, DisplayName: r.DisplayName, Description: r.Description, Type: provider.OptionType(r.Type), FormType: r.FormType, Mutable: r.Mutable, - Default: r.DefaultValue.AsString(), + Default: defPtr, Icon: r.Icon, Option: providerOptions(r.Options), Validation: providerValidations(r.Validations), Optional: false, Order: int(r.Order), Ephemeral: r.Ephemeral, - }).Valid() + }).ValidateInput(valuePtr) if diag.HasError() { // TODO: We can take the attr path and decorate the error with diff --git a/types/value.go b/types/value.go index 4cc269b..4e22b91 100644 --- a/types/value.go +++ b/types/value.go @@ -73,6 +73,14 @@ func StringLiteral(s string) HCLString { } } +func NullString() HCLString { + v := cty.NullVal(cty.String) + return HCLString{ + Value: v, + ValueExpr: &hclsyntax.LiteralValueExpr{Val: v}, + } +} + // AsString is a safe function. It will always return a string. // The caller should check if this value is Valid and known before // calling this function. From 4f4463b504ea8be125d3e70ed3246ed4d404aa9e Mon Sep 17 00:00:00 2001 From: Steven Masley Date: Mon, 5 May 2025 15:40:27 -0500 Subject: [PATCH 06/61] populate required field --- extract/parameter.go | 4 +++- extract/state.go | 2 +- types/parameter.go | 2 +- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/extract/parameter.go b/extract/parameter.go index b5b3b05..86b09f6 100644 --- a/extract/parameter.go +++ b/extract/parameter.go @@ -50,10 +50,12 @@ func ParameterFromBlock(block *terraform.Block) (*types.Parameter, hcl.Diagnosti pVal := richParameterValue(block) + requiredValue := true def := types.NullString() defAttr := block.GetAttribute("default") if !defAttr.IsNil() { def = types.ToHCLString(block, defAttr) + requiredValue = false } ftmeta := optionalString(block, "styling") @@ -77,7 +79,7 @@ func ParameterFromBlock(block *terraform.Block) (*types.Parameter, hcl.Diagnosti Icon: optionalString(block, "icon"), Options: make([]*types.ParameterOption, 0), Validations: make([]*types.ParameterValidation, 0), - Required: optionalBoolean(block, "required"), + Required: requiredValue, DisplayName: optionalString(block, "display_name"), Order: optionalInteger(block, "order"), Ephemeral: optionalBoolean(block, "ephemeral"), diff --git a/extract/state.go b/extract/state.go index bb1a942..905cf6a 100644 --- a/extract/state.go +++ b/extract/state.go @@ -74,7 +74,7 @@ func ParameterFromState(block *tfjson.StateResource) (types.Parameter, error) { Icon: st.optionalString("icon"), Options: options, Validations: validations, - Required: st.optionalBool("required"), + Required: !st.optionalBool("optional"), DisplayName: st.optionalString("display_name"), Order: st.optionalInteger("order"), Ephemeral: st.optionalBool("ephemeral"), diff --git a/types/parameter.go b/types/parameter.go index ebb8988..a155b03 100644 --- a/types/parameter.go +++ b/types/parameter.go @@ -118,7 +118,7 @@ func (r *ParameterData) Valid(value HCLString) hcl.Diagnostics { Icon: r.Icon, Option: providerOptions(r.Options), Validation: providerValidations(r.Validations), - Optional: false, + Optional: !r.Required, Order: int(r.Order), Ephemeral: r.Ephemeral, }).ValidateInput(valuePtr) From dd15cc786002df7c92b23718d50b1179441073cb Mon Sep 17 00:00:00 2001 From: Steven Masley Date: Mon, 5 May 2025 15:44:00 -0500 Subject: [PATCH 07/61] make gen --- site/src/types/preview.ts | 1 - 1 file changed, 1 deletion(-) diff --git a/site/src/types/preview.ts b/site/src/types/preview.ts index 945c7e1..1ab72e5 100644 --- a/site/src/types/preview.ts +++ b/site/src/types/preview.ts @@ -67,7 +67,6 @@ export interface ParameterValidation { readonly validation_min: number | null; readonly validation_max: number | null; readonly validation_monotonic: string | null; - readonly validation_invalid: boolean | null; } // From web/session.go From 5104c529d6309b55a724dbc780097420ea8ba5ed Mon Sep 17 00:00:00 2001 From: Steven Masley Date: Mon, 5 May 2025 15:48:10 -0500 Subject: [PATCH 08/61] fixup default usage --- types/parameter.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/types/parameter.go b/types/parameter.go index a155b03..700b42e 100644 --- a/types/parameter.go +++ b/types/parameter.go @@ -95,7 +95,8 @@ type ParameterOption struct { func (r *ParameterData) Valid(value HCLString) hcl.Diagnostics { var defPtr *string - if !r.DefaultValue.Value.IsNull() { + + if r.DefaultValue.Valid() && r.DefaultValue.IsKnown() { def := r.DefaultValue.Value.AsString() defPtr = &def } From 3ba59d2fb72acdc5f5b330489b21c800f445ddc7 Mon Sep 17 00:00:00 2001 From: Steven Masley Date: Mon, 5 May 2025 16:05:08 -0500 Subject: [PATCH 09/61] fix AsString reference --- cli/clidisplay/resources.go | 2 +- types/parameter.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/cli/clidisplay/resources.go b/cli/clidisplay/resources.go index aad72ba..dea4ba9 100644 --- a/cli/clidisplay/resources.go +++ b/cli/clidisplay/resources.go @@ -30,7 +30,7 @@ func WorkspaceTags(writer io.Writer, tags types.TagBlocks) hcl.Diagnostics { k, v := tag.AsStrings() tableWriter.AppendRow(table.Row{k, v, ""}) continue - //diags = diags.Extend(tDiags) + // diags = diags.Extend(tDiags) //if !diags.HasErrors() { // tableWriter.AppendRow(table.Row{k, v, ""}) // continue diff --git a/types/parameter.go b/types/parameter.go index 700b42e..6eeee34 100644 --- a/types/parameter.go +++ b/types/parameter.go @@ -97,7 +97,7 @@ func (r *ParameterData) Valid(value HCLString) hcl.Diagnostics { var defPtr *string if r.DefaultValue.Valid() && r.DefaultValue.IsKnown() { - def := r.DefaultValue.Value.AsString() + def := r.DefaultValue.AsString() defPtr = &def } From b198910aa54d62c894038a18ff32c9b517ed9289 Mon Sep 17 00:00:00 2001 From: Steven Masley Date: Mon, 5 May 2025 16:06:06 -0500 Subject: [PATCH 10/61] chore: add golangci-lint --- .golangci.yaml | 269 ++++++++++++++++++++++++++++++++++++ cli/clidisplay/resources.go | 8 +- cmd/preview/main.go | 3 +- log.go | 2 +- paramhook.go | 2 +- plan.go | 2 +- preview.go | 4 +- previewe2e_test.go | 4 +- scripts/rules.go | 16 +++ workspacetags.go | 12 +- 10 files changed, 304 insertions(+), 18 deletions(-) create mode 100644 .golangci.yaml create mode 100644 scripts/rules.go diff --git a/.golangci.yaml b/.golangci.yaml new file mode 100644 index 0000000..df8f68a --- /dev/null +++ b/.golangci.yaml @@ -0,0 +1,269 @@ +# See https://golangci-lint.run/usage/configuration/ +# Over time we should try tightening some of these. + +linters-settings: + dupl: + # goal: 100 + threshold: 412 + + exhaustruct: + include: + # Gradually extend to cover more of the codebase. + - 'httpmw\.\w+' + # We want to enforce all values are specified when inserting or updating + # a database row. Ref: #9936 + - 'github.com/coder/coder/v2/coderd/database\.[^G][^e][^t]\w+Params' + gocognit: + min-complexity: 300 + + goconst: + min-len: 4 # Min length of string consts (def 3). + min-occurrences: 3 # Min number of const occurrences (def 3). + + gocritic: + enabled-checks: + # - appendAssign + # - appendCombine + # - assignOp + # - badCall + - badLock + - badRegexp + - boolExprSimplify + # - builtinShadow + - builtinShadowDecl + # - commentedOutCode + - commentedOutImport + - deferUnlambda + # - deprecatedComment + # - docStub + - dupImport + # - elseif + - emptyFallthrough + # - emptyStringTest + # - equalFold + # - evalOrder + # - exitAfterDefer + # - exposedSyncMutex + # - filepathJoin + - hexLiteral + # - httpNoBody + # - hugeParam + # - ifElseChain + # - importShadow + - indexAlloc + - initClause + - methodExprCall + # - nestingReduce + - nilValReturn + # - octalLiteral + # - paramTypeCombine + # - preferStringWriter + # - preferWriteByte + # - ptrToRefParam + # - rangeExprCopy + # - rangeValCopy + - regexpPattern + # - regexpSimplify + - ruleguard + # - sloppyReassign + - sortSlice + - sprintfQuotedString + - sqlQuery + # - stringConcatSimplify + # - stringXbytes + # - suspiciousSorting + - truncateCmp + - typeAssertChain + # - typeDefFirst + # - typeUnparen + # - unlabelStmt + # - unlambda + # - unnamedResult + # - unnecessaryBlock + # - unnecessaryDefer + # - unslice + - weakCond + # - whyNoLint + # - wrapperFunc + # - yodaStyleExpr + settings: + ruleguard: + failOn: all + rules: "${configDir}/scripts/rules.go" + + staticcheck: + # https://staticcheck.io/docs/options#checks + # We disable SA1019 because it gets angry about our usage of xerrors. We + # intentionally xerrors because stack frame support didn't make it into the + # stdlib port. + checks: ["all", "-SA1019"] + + goimports: + local-prefixes: coder.com,cdr.dev,go.coder.com,github.com/cdr,github.com/coder + + importas: + no-unaliased: true + + misspell: + locale: US + ignore-words: + - trialer + + nestif: + # goal: 10 + min-complexity: 20 + + revive: + # see https://github.com/mgechev/revive#available-rules for details. + ignore-generated-header: true + severity: warning + rules: + - name: atomic + - name: bare-return + - name: blank-imports + - name: bool-literal-in-expr + - name: call-to-gc + - name: confusing-naming + - name: confusing-results + - name: constant-logical-expr + - name: context-as-argument + - name: context-keys-type + - name: deep-exit + - name: defer + - name: dot-imports + - name: duplicated-imports + - name: early-return + - name: empty-block + - name: empty-lines + - name: error-naming + - name: error-return + - name: error-strings + - name: errorf + - name: exported + - name: flag-parameter + - name: get-return + - name: identical-branches + - name: if-return + - name: import-shadowing + - name: increment-decrement + - name: indent-error-flow + # - name: modifies-parameter + - name: modifies-value-receiver + - name: package-comments + - name: range + - name: receiver-naming + - name: redefines-builtin-id + - name: string-of-int + - name: struct-tag + - name: superfluous-else + - name: time-naming + - name: unconditional-recursion + - name: unexported-naming + - name: unexported-return + - name: unhandled-error + - name: unnecessary-stmt + - name: unreachable-code + - name: unused-parameter + exclude: "**/*_test.go" + - name: unused-receiver + - name: var-declaration + - name: var-naming + - name: waitgroup-by-value + + # irrelevant as of Go v1.22: https://go.dev/blog/loopvar-preview + govet: + disable: + - loopclosure + gosec: + excludes: + # Implicit memory aliasing of items from a range statement (irrelevant as of Go v1.22) + - G601 + +issues: + exclude-dirs: + - coderd/database/dbmem + - node_modules + - .git + + exclude-files: + - scripts/rules.go + + # Rules listed here: https://github.com/securego/gosec#available-rules + exclude-rules: + - path: _test\.go + linters: + # We use assertions rather than explicitly checking errors in tests + - errcheck + - forcetypeassert + - exhaustruct # This is unhelpful in tests. + - path: scripts/* + linters: + - exhaustruct + - path: scripts/rules.go + linters: + - ALL + + fix: true + max-issues-per-linter: 0 + max-same-issues: 0 + +run: + timeout: 10m + +# Over time, add more and more linters from +# https://golangci-lint.run/usage/linters/ as the code improves. +linters: + disable-all: true + enable: + - asciicheck + - bidichk + - bodyclose + - dogsled + - errcheck + - errname + - errorlint + - exhaustruct + - forcetypeassert + - gocritic + # gocyclo is may be useful in the future when we start caring + # about testing complexity, but for the time being we should + # create a good culture around cognitive complexity. + # - gocyclo + - gocognit + - nestif + - goimports + - gomodguard + - gosec + - gosimple + - govet + - importas + - ineffassign + - makezero + - misspell + - nilnil + - noctx + - paralleltest + - revive + + # These don't work until the following issue is solved. + # https://github.com/golangci/golangci-lint/issues/2649 + # - rowserrcheck + # - sqlclosecheck + # - structcheck + # - wastedassign + + - staticcheck + - tenv + # In Go, it's possible for a package to test it's internal functionality + # without testing any exported functions. This is enabled to promote + # decomposing a package before testing it's internals. A function caller + # should be able to test most of the functionality from exported functions. + # + # There are edge-cases to this rule, but they should be carefully considered + # to avoid structural inconsistency. + - testpackage + - tparallel + - typecheck + - unconvert + - unused + - dupl \ No newline at end of file diff --git a/cli/clidisplay/resources.go b/cli/clidisplay/resources.go index ac93025..ec2ca94 100644 --- a/cli/clidisplay/resources.go +++ b/cli/clidisplay/resources.go @@ -30,7 +30,7 @@ func WorkspaceTags(writer io.Writer, tags types.TagBlocks) hcl.Diagnostics { k, v := tag.AsStrings() tableWriter.AppendRow(table.Row{k, v, ""}) continue - //diags = diags.Extend(tDiags) + // diags = diags.Extend(tDiags) //if !diags.HasErrors() { // tableWriter.AppendRow(table.Row{k, v, ""}) // continue @@ -41,7 +41,7 @@ func WorkspaceTags(writer io.Writer, tags types.TagBlocks) hcl.Diagnostics { refs := tag.References() tableWriter.AppendRow(table.Row{k, "??", strings.Join(refs, "\n")}) - //refs := tb.AllReferences() + // refs := tb.AllReferences() //refsStr := make([]string, 0, len(refs)) //for _, ref := range refs { // refsStr = append(refsStr, ref.String()) @@ -55,7 +55,7 @@ func WorkspaceTags(writer io.Writer, tags types.TagBlocks) hcl.Diagnostics { func Parameters(writer io.Writer, params []types.Parameter, files map[string]*hcl.File) { tableWriter := table.NewWriter() - //tableWriter.SetTitle("Parameters") + // tableWriter.SetTitle("Parameters") tableWriter.SetStyle(table.StyleLight) tableWriter.Style().Options.SeparateColumns = false row := table.Row{"Parameter"} @@ -66,7 +66,7 @@ func Parameters(writer io.Writer, params []types.Parameter, files map[string]*hc if p.FormType == provider.ParameterFormTypeMultiSelect { _ = json.Unmarshal([]byte(strVal), &selections) } - //value := p.Value.Value + // value := p.Value.Value // //if value.IsNull() { // strVal = "null" diff --git a/cmd/preview/main.go b/cmd/preview/main.go index a035d2c..4adb498 100644 --- a/cmd/preview/main.go +++ b/cmd/preview/main.go @@ -5,8 +5,9 @@ import ( "log" "os" - "github.com/coder/preview/cli" "github.com/hashicorp/hcl/v2" + + "github.com/coder/preview/cli" ) func main() { diff --git a/log.go b/log.go index db34405..ed1c223 100644 --- a/log.go +++ b/log.go @@ -11,5 +11,5 @@ func init() { Level: tlog.LevelDebug, })) var _ = ll - //tlog.SetDefault(ll) + // tlog.SetDefault(ll) } diff --git a/paramhook.go b/paramhook.go index ec10a33..b8c0cd4 100644 --- a/paramhook.go +++ b/paramhook.go @@ -156,7 +156,7 @@ func isForEachKey(key cty.Value) bool { func evaluateCoderParameterDefault(b *terraform.Block) (cty.Value, bool) { attributes := b.Attributes() - //typeAttr, exists := attributes["type"] + // typeAttr, exists := attributes["type"] //valueType := cty.String // TODO: Default to string? //if exists { // typeVal := typeAttr.Value() diff --git a/plan.go b/plan.go index 8458c24..6abc8e3 100644 --- a/plan.go +++ b/plan.go @@ -23,7 +23,7 @@ func planJSONHook(dfs fs.FS, input Input) (func(ctx *tfcontext.Context, blocks t var contents io.Reader = bytes.NewReader(input.PlanJSON) // Also accept `{}` as an empty plan. If this is stored in postgres or another json // type, then `{}` is the "empty" value. - if len(input.PlanJSON) == 0 || bytes.Compare(input.PlanJSON, []byte("{}")) == 0 { + if len(input.PlanJSON) == 0 || bytes.Equal(input.PlanJSON, []byte("{}")) { if input.PlanJSONPath == "" { return func(ctx *tfcontext.Context, blocks terraform.Blocks, inputVars map[string]cty.Value) {}, nil } diff --git a/preview.go b/preview.go index 96447ff..b30882f 100644 --- a/preview.go +++ b/preview.go @@ -58,7 +58,7 @@ func Preview(ctx context.Context, input Input, dir fs.FS) (output *Output, diagn // TODO: Fix logging. There is no way to pass in an instanced logger to // the parser. - //slog.SetLogLoggerLevel(slog.LevelDebug) + // slog.SetLogLoggerLevel(slog.LevelDebug) //slog.SetDefault(slog.New(log.NewHandler(os.Stderr, nil))) varFiles, err := tfVarFiles("", dir) @@ -127,7 +127,7 @@ func Preview(ctx context.Context, input Input, dir fs.FS) (output *Output, diagn }, } } - + outputs := hclext.ExportOutputs(modules) diags := make(hcl.Diagnostics, 0) diff --git a/previewe2e_test.go b/previewe2e_test.go index 4471611..c0c1ad0 100644 --- a/previewe2e_test.go +++ b/previewe2e_test.go @@ -47,7 +47,7 @@ import ( // The goal of the test is to compare `tfstate` with the output of `preview`. // If `preview`'s implementation of terraform is incorrect, the test will fail. // TODO: Adding varied parameter inputs would be a good idea. -// TODO: Add workspace tag comparisions. +// TODO: Add workspace tag comparisons. func Test_VerifyE2E(t *testing.T) { t.Parallel() @@ -135,7 +135,7 @@ func Test_VerifyE2E(t *testing.T) { require.NoError(t, err, "terraform show plan") pd, err := json.Marshal(plan) - require.NoError(t, err, "marshalling plan") + require.NoError(t, err, "marshaling plan") err = os.WriteFile(filepath.Join(wp, "plan.json"), pd, 0644) require.NoError(t, err, "writing plan.json") diff --git a/scripts/rules.go b/scripts/rules.go new file mode 100644 index 0000000..c0793cf --- /dev/null +++ b/scripts/rules.go @@ -0,0 +1,16 @@ +// Package gorules defines custom lint rules for ruleguard. +// +// golangci-lint runs these rules via go-critic, which includes support +// for ruleguard. All Go files in this directory define lint rules +// in the Ruleguard DSL; see: +// +// - https://go-ruleguard.github.io/by-example/ +// - https://pkg.go.dev/github.com/quasilyte/go-ruleguard/dsl +// +// You run one of the following commands to execute your go rules only: +// +// golangci-lint run +// golangci-lint run --disable-all --enable=gocritic +// +// Note: don't forget to run `golangci-lint cache clean`! +package gorules diff --git a/workspacetags.go b/workspacetags.go index 8f7702b..6181c4a 100644 --- a/workspacetags.go +++ b/workspacetags.go @@ -47,7 +47,7 @@ func workspaceTags(modules terraform.Modules, files map[string]*hcl.File) (types continue } - //tagsObj, ok := tagsAttr.HCLAttribute().Expr.(*hclsyntax.ObjectConsExpr) + // tagsObj, ok := tagsAttr.HCLAttribute().Expr.(*hclsyntax.ObjectConsExpr) //if !ok { // diags = diags.Append(&hcl.Diagnostic{ // Severity: hcl.DiagError, @@ -75,7 +75,7 @@ func workspaceTags(modules terraform.Modules, files map[string]*hcl.File) (types return false }) - //for _, item := range tagsObj.Items { + // for _, item := range tagsObj.Items { // tag, tagDiag := newTag(tagsObj, files, item, evCtx) // if tagDiag != nil { // diags = diags.Append(tagDiag) @@ -96,12 +96,12 @@ func workspaceTags(modules terraform.Modules, files map[string]*hcl.File) (types // newTag creates a workspace tag from its hcl expression. func newTag(srcRange *hcl.Range, files map[string]*hcl.File, key, val cty.Value) (types.Tag, *hcl.Diagnostic) { - //key, kdiags := expr.KeyExpr.Value(evCtx) + // key, kdiags := expr.KeyExpr.Value(evCtx) //val, vdiags := expr.ValueExpr.Value(evCtx) // TODO: ??? - //if kdiags.HasErrors() { + // if kdiags.HasErrors() { // key = cty.UnknownVal(cty.String) //} //if vdiags.HasErrors() { @@ -125,7 +125,7 @@ func newTag(srcRange *hcl.Range, files map[string]*hcl.File, key, val cty.Value) if !val.Type().Equals(cty.NilType) { fr = val.Type().FriendlyName() } - //r := expr.ValueExpr.Range() + // r := expr.ValueExpr.Range() return types.Tag{}, &hcl.Diagnostic{ Severity: hcl.DiagError, Summary: "Invalid value type for tag", @@ -150,7 +150,7 @@ func newTag(srcRange *hcl.Range, files map[string]*hcl.File, key, val cty.Value) }, } - //ks, err := source(expr.KeyExpr.Range(), files) + // ks, err := source(expr.KeyExpr.Range(), files) //if err == nil { // src := string(ks) // tag.Key.Source = &src From 45c80025982dfa9775bfeedcbbd136ce58a85f57 Mon Sep 17 00:00:00 2001 From: Steven Masley Date: Mon, 5 May 2025 16:19:13 -0500 Subject: [PATCH 11/61] chore: golangci-lint linting fixes --- attr.go | 112 ------------------------------------ cli/clidisplay/resources.go | 33 ++++++----- cli/env.go | 6 +- cli/plan.go | 3 +- cli/root.go | 5 +- cli/static/index.html | 55 ------------------ cli/web.go | 17 ++---- cmd/preview/main.go | 1 - hclext/references.go | 7 ++- internal/verify/exec.go | 10 ++-- mark.go | 10 ---- owner.go | 4 +- parameter.go | 2 +- paramhook.go | 8 +-- plan.go | 39 +------------ plan_test.go | 2 + preview.go | 2 +- preview_test.go | 2 + previewe2e_test.go | 3 +- site/genweb/main.go | 1 + source.go | 1 + types/owner.go | 2 +- types/owner_test.go | 14 +++-- types/parameter.go | 2 +- types/primitive.go | 3 +- types/tags.go | 2 +- types/value_test.go | 2 + web/websocket.go | 1 - workspacetags.go | 14 ++--- 29 files changed, 81 insertions(+), 282 deletions(-) delete mode 100644 attr.go delete mode 100644 cli/static/index.html delete mode 100644 mark.go diff --git a/attr.go b/attr.go deleted file mode 100644 index 3d81418..0000000 --- a/attr.go +++ /dev/null @@ -1,112 +0,0 @@ -package preview - -import ( - "fmt" - - "github.com/aquasecurity/trivy/pkg/iac/terraform" - "github.com/hashicorp/hcl/v2" - "github.com/zclconf/go-cty/cty" -) - -type attributeParser struct { - block *terraform.Block - diags hcl.Diagnostics -} - -func newAttributeParser(block *terraform.Block) *attributeParser { - return &attributeParser{ - block: block, - diags: make(hcl.Diagnostics, 0), - } -} - -func (a *attributeParser) attr(key string) *expectedAttribute { - return &expectedAttribute{ - Key: key, - p: a, - } -} - -type expectedAttribute struct { - Key string - diag hcl.Diagnostics - p *attributeParser -} - -func (a *expectedAttribute) error(diag hcl.Diagnostics) *expectedAttribute { - if a.diag != nil { - return a // already have an error, don't overwrite - } - - a.p.diags = a.p.diags.Extend(diag) - a.diag = diag - return a -} - -func (a *expectedAttribute) required() *expectedAttribute { - attr := a.p.block.GetAttribute(a.Key) - if attr.IsNil() { - r := a.p.block.HCLBlock().Body.MissingItemRange() - a.error(hcl.Diagnostics{ - { - Severity: hcl.DiagError, - Summary: fmt.Sprintf("Missing required attribute %q", a.Key), - // This is the error word for word from 'terraform apply' - Detail: fmt.Sprintf("The argument %q is required, but no definition is found.", a.Key), - Subject: &r, - Extra: nil, - }, - }) - } - - return a -} - -func (a *expectedAttribute) tryString() string { - attr := a.p.block.GetAttribute(a.Key) - if attr.IsNil() { - return "" - } - - if attr.Type() != cty.String { - return "" - } - - return attr.Value().AsString() -} - -func (a *expectedAttribute) string() string { - attr := a.p.block.GetAttribute(a.Key) - if attr.IsNil() { - return "" - } - - if attr.Type() != cty.String { - a.expectedTypeError(attr, "string") - return "" - } - - return attr.Value().AsString() -} - -func (a *expectedAttribute) expectedTypeError(attr *terraform.Attribute, expectedType string) { - var fn string - if attr.IsNil() || attr.Type().Equals(cty.NilType) { - fn = "nil" - } else { - fn = attr.Type().FriendlyName() - } - - a.error(hcl.Diagnostics{ - { - Severity: hcl.DiagError, - Summary: "Invalid attribute type", - Detail: fmt.Sprintf("The attribute %q must be of type %q, found type %q", attr.Name(), expectedType, fn), - Subject: &attr.HCLAttribute().Range, - Context: &a.p.block.HCLBlock().DefRange, - Expression: attr.HCLAttribute().Expr, - - EvalContext: a.p.block.Context().Inner(), - }, - }) -} diff --git a/cli/clidisplay/resources.go b/cli/clidisplay/resources.go index ec2ca94..0b4fe49 100644 --- a/cli/clidisplay/resources.go +++ b/cli/clidisplay/resources.go @@ -31,7 +31,7 @@ func WorkspaceTags(writer io.Writer, tags types.TagBlocks) hcl.Diagnostics { tableWriter.AppendRow(table.Row{k, v, ""}) continue // diags = diags.Extend(tDiags) - //if !diags.HasErrors() { + // if !diags.HasErrors() { // tableWriter.AppendRow(table.Row{k, v, ""}) // continue //} @@ -42,11 +42,11 @@ func WorkspaceTags(writer io.Writer, tags types.TagBlocks) hcl.Diagnostics { tableWriter.AppendRow(table.Row{k, "??", strings.Join(refs, "\n")}) // refs := tb.AllReferences() - //refsStr := make([]string, 0, len(refs)) - //for _, ref := range refs { + // refsStr := make([]string, 0, len(refs)) + // for _, ref := range refs { // refsStr = append(refsStr, ref.String()) //} - //tableWriter.AppendRow(table.Row{unknown, "???", strings.Join(refsStr, "\n")}) + // tableWriter.AppendRow(table.Row{unknown, "???", strings.Join(refsStr, "\n")}) } } _, _ = fmt.Fprintln(writer, tableWriter.Render()) @@ -68,13 +68,13 @@ func Parameters(writer io.Writer, params []types.Parameter, files map[string]*hc } // value := p.Value.Value // - //if value.IsNull() { + // if value.IsNull() { // strVal = "null" - //} else if !p.Value.Value.IsKnown() { + // } else if !p.Value.Value.IsKnown() { // strVal = "unknown" - //} else if value.Type().Equals(cty.String) { + // } else if value.Type().Equals(cty.String) { // strVal = value.AsString() - //} else { + // } else { // strVal = value.GoString() //} @@ -86,7 +86,6 @@ func Parameters(writer io.Writer, params []types.Parameter, files map[string]*hc var out bytes.Buffer WriteDiagnostics(&out, files, hcl.Diagnostics(p.Diagnostics)) tableWriter.AppendRow(table.Row{out.String()}) - } tableWriter.AppendSeparator() @@ -100,29 +99,29 @@ func formatOptions(selected []string, options []*types.ParameterOption) string { found := false for _, opt := range options { - str.WriteString(sep) + _, _ = str.WriteString(sep) prefix := "[ ]" if slices.Contains(selected, opt.Value.AsString()) { prefix = "[X]" found = true } - str.WriteString(fmt.Sprintf("%s %s (%s)", prefix, opt.Name, opt.Value.AsString())) + _, _ = str.WriteString(fmt.Sprintf("%s %s (%s)", prefix, opt.Name, opt.Value.AsString())) if opt.Description != "" { - str.WriteString(fmt.Sprintf("\n %s", maxLength(opt.Description, 25))) + _, _ = str.WriteString(fmt.Sprintf("\n %s", maxLength(opt.Description, 25))) } sep = "\n" } if !found { - str.WriteString(sep) - str.WriteString(fmt.Sprintf("= %s", selected)) + _, _ = str.WriteString(sep) + _, _ = str.WriteString(fmt.Sprintf("= %s", selected)) } return str.String() } -func maxLength(s string, max int) string { - if len(s) > max { - return s[:max] + "..." +func maxLength(s string, m int) string { + if len(s) > m { + return s[:m] + "..." } return s } diff --git a/cli/env.go b/cli/env.go index 1cf189f..f86704d 100644 --- a/cli/env.go +++ b/cli/env.go @@ -10,7 +10,7 @@ import ( "github.com/coder/serpent" ) -func (r *RootCmd) SetEnv() *serpent.Command { +func (*RootCmd) SetEnv() *serpent.Command { var ( vars []string groups []string @@ -38,7 +38,7 @@ func (r *RootCmd) SetEnv() *serpent.Command { }, }, Hidden: false, - Handler: func(i *serpent.Invocation) error { + Handler: func(_ *serpent.Invocation) error { for _, val := range vars { parts := strings.Split(val, "=") if len(parts) != 2 { @@ -49,7 +49,7 @@ func (r *RootCmd) SetEnv() *serpent.Command { if err != nil { return err } - fmt.Println("CODER_PARAMETER_" + hex.EncodeToString(sum[:]) + "=" + parts[1]) + _, _ = fmt.Println("CODER_PARAMETER_" + hex.EncodeToString(sum[:]) + "=" + parts[1]) } return nil diff --git a/cli/plan.go b/cli/plan.go index c5e174b..62929c5 100644 --- a/cli/plan.go +++ b/cli/plan.go @@ -10,7 +10,7 @@ import ( "github.com/coder/serpent" ) -func (r *RootCmd) TerraformPlan() *serpent.Command { +func (*RootCmd) TerraformPlan() *serpent.Command { cmd := &serpent.Command{ Use: "plan", Short: "Runs `terraform init -upgrade` and `terraform plan`, saving the output.", @@ -54,6 +54,7 @@ func (r *RootCmd) TerraformPlan() *serpent.Command { var indented bytes.Buffer _ = json.Indent(&indented, buf.Bytes(), "", " ") + //nolint:gosec _ = os.WriteFile("plan.json", indented.Bytes(), 0644) return nil }, diff --git a/cli/root.go b/cli/root.go index 56dfb8d..ab1afc5 100644 --- a/cli/root.go +++ b/cli/root.go @@ -106,11 +106,11 @@ func (r *RootCmd) Root() *serpent.Command { clidisplay.Parameters(os.Stdout, output.Parameters, output.Files) if !output.ModuleOutput.IsNull() && !(output.ModuleOutput.Type().IsObjectType() && output.ModuleOutput.LengthInt() == 0) { - fmt.Println("Module output") + _, _ = fmt.Println("Module output") data, _ := ctyjson.Marshal(output.ModuleOutput, output.ModuleOutput.Type()) var buf bytes.Buffer _ = json.Indent(&buf, data, "", " ") - fmt.Println(buf.String()) + _, _ = fmt.Println(buf.String()) } return nil @@ -122,6 +122,7 @@ func (r *RootCmd) Root() *serpent.Command { return cmd } +//nolint:unused func hclExpr(expr string) hcl.Expression { file, diags := hclsyntax.ParseConfig([]byte(fmt.Sprintf(`expr = %s`, expr)), "test.tf", hcl.InitialPos) if diags.HasErrors() { diff --git a/cli/static/index.html b/cli/static/index.html deleted file mode 100644 index 5fa349f..0000000 --- a/cli/static/index.html +++ /dev/null @@ -1,55 +0,0 @@ - - - - - - Codestin Search App - - - - -

WebSocket JSON Preview

-
-
-
-
- -

Output:

-

-
-
diff --git a/cli/web.go b/cli/web.go
index 0b9d9ac..4ffe954 100644
--- a/cli/web.go
+++ b/cli/web.go
@@ -3,7 +3,6 @@ package cli
 import (
 	"bufio"
 	"context"
-	"embed"
 	"encoding/json"
 	"fmt"
 	"io/fs"
@@ -13,6 +12,7 @@ import (
 	"os/exec"
 	"path/filepath"
 	"slices"
+	"time"
 
 	"github.com/go-chi/chi"
 
@@ -24,13 +24,9 @@ import (
 	"github.com/coder/websocket"
 )
 
-//go:embed static/*
-var static embed.FS
-
 type responseRecorder struct {
 	http.ResponseWriter
-	headerWritten bool
-	logger        slog.Logger
+	logger slog.Logger
 }
 
 // Implement Hijacker interface for WebSocket support
@@ -54,7 +50,7 @@ func debugMiddleware(logger slog.Logger) func(http.Handler) http.Handler {
 	}
 }
 
-func (r *RootCmd) WebsocketServer() *serpent.Command {
+func (*RootCmd) WebsocketServer() *serpent.Command {
 	var (
 		address string
 		siteDir string
@@ -132,7 +128,7 @@ func (r *RootCmd) WebsocketServer() *serpent.Command {
 				}
 				_ = json.NewEncoder(rw).Encode(availableUsers)
 			})
-			mux.HandleFunc("/directories", func(rw http.ResponseWriter, r *http.Request) {
+			mux.HandleFunc("/directories", func(rw http.ResponseWriter, _ *http.Request) {
 				entries, err := fs.ReadDir(dataDirFS, ".")
 				if err != nil {
 					http.Error(rw, "Could not read directory", http.StatusInternalServerError)
@@ -163,9 +159,10 @@ func (r *RootCmd) WebsocketServer() *serpent.Command {
 			srv := &http.Server{
 				Addr:    address,
 				Handler: mux,
-				BaseContext: func(listener net.Listener) context.Context {
+				BaseContext: func(_ net.Listener) context.Context {
 					return ctx
 				},
+				ReadHeaderTimeout: time.Second * 30,
 			}
 
 			if siteDir != "" {
@@ -184,7 +181,6 @@ func (r *RootCmd) WebsocketServer() *serpent.Command {
 					// Kill the server if pnpm exits
 					_ = srv.Shutdown(ctx)
 				}()
-
 			}
 
 			logger.Info(ctx, "Starting server", slog.F("address", address))
@@ -197,7 +193,6 @@ func (r *RootCmd) WebsocketServer() *serpent.Command {
 
 func websocketHandler(logger slog.Logger, dirFS fs.FS) func(rw http.ResponseWriter, r *http.Request) {
 	return func(rw http.ResponseWriter, r *http.Request) {
-
 		logger.Debug(r.Context(), "WebSocket connection attempt",
 			slog.F("remote_addr", r.RemoteAddr),
 			slog.F("path", r.URL.Path),
diff --git a/cmd/preview/main.go b/cmd/preview/main.go
index 4adb498..795ee4f 100644
--- a/cmd/preview/main.go
+++ b/cmd/preview/main.go
@@ -30,6 +30,5 @@ func main() {
 			}
 		}
 		log.Fatal(err.Error())
-		os.Exit(1)
 	}
 }
diff --git a/hclext/references.go b/hclext/references.go
index e9f38e9..7da5a0d 100644
--- a/hclext/references.go
+++ b/hclext/references.go
@@ -65,12 +65,13 @@ func CreateDotReferenceFromTraversal(traversals ...hcl.Traversal) string {
 			case hcl.TraverseAttr:
 				refParts = append(refParts, part.Name)
 			case hcl.TraverseIndex:
-				if part.Key.Type().Equals(cty.String) {
+				switch {
+				case part.Key.Type().Equals(cty.String):
 					refParts = append(refParts, fmt.Sprintf("[%s]", part.Key.AsString()))
-				} else if part.Key.Type().Equals(cty.Number) {
+				case part.Key.Type().Equals(cty.Number):
 					idx, _ := part.Key.AsBigFloat().Int64()
 					refParts = append(refParts, fmt.Sprintf("[%d]", idx))
-				} else {
+				default:
 					refParts = append(refParts, fmt.Sprintf("[?? %q]", part.Key.Type().FriendlyName()))
 				}
 			}
diff --git a/internal/verify/exec.go b/internal/verify/exec.go
index 6801e48..1294025 100644
--- a/internal/verify/exec.go
+++ b/internal/verify/exec.go
@@ -129,7 +129,7 @@ func InstallTerraforms(ctx context.Context, t *testing.T, installables ...src.In
 	return execPaths
 }
 
-func LatestTerraformVersion(ctx context.Context) *releases.LatestVersion {
+func LatestTerraformVersion(_ context.Context) *releases.LatestVersion {
 	return &releases.LatestVersion{
 		Product: product.Terraform,
 	}
@@ -158,10 +158,10 @@ func TerraformVersions(ctx context.Context, constraints version.Constraints) ([]
 	}
 
 	include := make([]*releases.ExactVersion, 0)
-	for _, src := range srcs {
-		ev, ok := src.(*releases.ExactVersion)
+	for _, s := range srcs {
+		ev, ok := s.(*releases.ExactVersion)
 		if !ok {
-			return nil, fmt.Errorf("failed to cast src to ExactVersion, type was %T", src)
+			return nil, fmt.Errorf("failed to cast src to ExactVersion, type was %T", s)
 		}
 
 		include = append(include, ev)
@@ -212,7 +212,7 @@ func CopyTFFS(dir string, fsys fs.FS) error {
 		}
 
 		if _, err := io.Copy(w, r); err != nil {
-			w.Close()
+			_ = w.Close()
 			return &os.PathError{Op: "Copy", Path: newPath, Err: err}
 		}
 		return w.Close()
diff --git a/mark.go b/mark.go
deleted file mode 100644
index d97e634..0000000
--- a/mark.go
+++ /dev/null
@@ -1,10 +0,0 @@
-package preview
-
-import (
-	"github.com/hashicorp/hcl/v2"
-	"github.com/zclconf/go-cty/cty"
-)
-
-func markWithDiagnostic(v cty.Value, diag hcl.Diagnostics) cty.Value {
-	return v.Mark(diag)
-}
diff --git a/owner.go b/owner.go
index a300a30..dbd7ad8 100644
--- a/owner.go
+++ b/owner.go
@@ -12,10 +12,10 @@ import (
 func workspaceOwnerHook(_ fs.FS, input Input) (func(ctx *tfcontext.Context, blocks terraform.Blocks, inputVars map[string]cty.Value), error) {
 	ownerValue, err := input.Owner.ToCtyValue()
 	if err != nil {
-		return nil, xerrors.Errorf("failed to convert owner value", err)
+		return nil, xerrors.Errorf("failed to convert owner value: %w", err)
 	}
 
-	return func(ctx *tfcontext.Context, blocks terraform.Blocks, inputVars map[string]cty.Value) {
+	return func(_ *tfcontext.Context, blocks terraform.Blocks, _ map[string]cty.Value) {
 		for _, block := range blocks.OfType("data") {
 			// TODO: Does it have to be me?
 			if block.TypeLabel() == "coder_workspace_owner" && block.NameLabel() == "me" {
diff --git a/parameter.go b/parameter.go
index e56660b..c5d691b 100644
--- a/parameter.go
+++ b/parameter.go
@@ -39,7 +39,7 @@ func parameters(modules terraform.Modules) ([]types.Parameter, hcl.Diagnostics)
 		var detail strings.Builder
 		for _, p := range v {
 			if p.Source != nil {
-				detail.WriteString(fmt.Sprintf("block %q at %s\n",
+				_, _ = detail.WriteString(fmt.Sprintf("block %q at %s\n",
 					p.Source.Type()+"."+strings.Join(p.Source.Labels(), "."),
 					p.Source.HCLBlock().TypeRange))
 			}
diff --git a/paramhook.go b/paramhook.go
index b8c0cd4..7966138 100644
--- a/paramhook.go
+++ b/paramhook.go
@@ -15,7 +15,7 @@ import (
 // is resolvable. The resolvable parameter will be accessible on the next
 // iteration.
 func parameterContextsEvalHook(input Input) func(ctx *tfcontext.Context, blocks terraform.Blocks, inputVars map[string]cty.Value) {
-	return func(ctx *tfcontext.Context, blocks terraform.Blocks, inputVars map[string]cty.Value) {
+	return func(ctx *tfcontext.Context, blocks terraform.Blocks, _ map[string]cty.Value) {
 		data := blocks.OfType("data")
 		for _, block := range data {
 			if block.TypeLabel() != "coder_parameter" {
@@ -157,8 +157,8 @@ func evaluateCoderParameterDefault(b *terraform.Block) (cty.Value, bool) {
 	attributes := b.Attributes()
 
 	// typeAttr, exists := attributes["type"]
-	//valueType := cty.String // TODO: Default to string?
-	//if exists {
+	// valueType := cty.String // TODO: Default to string?
+	// if exists {
 	//	typeVal := typeAttr.Value()
 	//	if !typeVal.Type().Equals(cty.String) || !typeVal.IsWhollyKnown() {
 	//		// TODO: Mark this value somehow
@@ -187,7 +187,7 @@ func evaluateCoderParameterDefault(b *terraform.Block) (cty.Value, bool) {
 	//
 	//// TODO: We should support different tf types, but at present the tf
 	//// schema is static. So only string is allowed
-	//var val cty.Value
+	// var val cty.Value
 
 	def, exists := attributes["default"]
 	if !exists {
diff --git a/plan.go b/plan.go
index 6abc8e3..2714bc8 100644
--- a/plan.go
+++ b/plan.go
@@ -25,7 +25,7 @@ func planJSONHook(dfs fs.FS, input Input) (func(ctx *tfcontext.Context, blocks t
 	// type, then `{}` is the "empty" value.
 	if len(input.PlanJSON) == 0 || bytes.Equal(input.PlanJSON, []byte("{}")) {
 		if input.PlanJSONPath == "" {
-			return func(ctx *tfcontext.Context, blocks terraform.Blocks, inputVars map[string]cty.Value) {}, nil
+			return func(_ *tfcontext.Context, _ terraform.Blocks, _ map[string]cty.Value) {}, nil
 		}
 
 		var err error
@@ -40,7 +40,7 @@ func planJSONHook(dfs fs.FS, input Input) (func(ctx *tfcontext.Context, blocks t
 		return nil, fmt.Errorf("unable to parse plan JSON: %w", err)
 	}
 
-	return func(ctx *tfcontext.Context, blocks terraform.Blocks, inputVars map[string]cty.Value) {
+	return func(_ *tfcontext.Context, blocks terraform.Blocks, _ map[string]cty.Value) {
 		loaded := make(map[*tfjson.StateModule]bool)
 
 		// Do not recurse to child blocks.
@@ -110,22 +110,6 @@ func priorPlanModule(plan *tfjson.Plan, block *terraform.Block) *tfjson.StateMod
 	return current
 }
 
-func matchingBlock(block *terraform.Block, planMod *tfjson.StateModule) *tfjson.StateResource {
-	ref := block.Reference()
-	matchKey := keyMatcher(ref.RawKey())
-
-	for _, resource := range planMod.Resources {
-		if ref.BlockType().ShortName() == string(resource.Mode) &&
-			ref.TypeLabel() == resource.Type &&
-			ref.NameLabel() == resource.Name &&
-			matchKey(resource.Index) {
-
-			return resource
-		}
-	}
-	return nil
-}
-
 func loadResourcesToContext(ctx *tfcontext.Context, resources []*tfjson.StateResource) error {
 	for _, resource := range resources {
 		if resource.Mode != "data" {
@@ -224,24 +208,7 @@ func parsePlanJSON(reader io.Reader) (*tfjson.Plan, error) {
 	return plan, json.NewDecoder(reader).Decode(plan)
 }
 
-func keyMatcher(key cty.Value) func(to any) bool {
-	switch {
-	case key.Type().Equals(cty.Number):
-		idx, _ := key.AsBigFloat().Int64()
-		return func(to any) bool {
-			asInt, ok := toInt(to)
-			return ok && asInt == idx
-		}
-
-	case key.Type().Equals(cty.String):
-		// TODO: handle key strings
-	}
-
-	return func(to any) bool {
-		return true
-	}
-}
-
+//nolint:gosec // Maybe handle overflow at some point
 func toInt(to any) (int64, bool) {
 	switch typed := to.(type) {
 	case uint:
diff --git a/plan_test.go b/plan_test.go
index af268e8..b3d0edd 100644
--- a/plan_test.go
+++ b/plan_test.go
@@ -14,6 +14,8 @@ func TestPlanJSONHook(t *testing.T) {
 	t.Parallel()
 
 	t.Run("Empty plan", func(t *testing.T) {
+		t.Parallel()
+
 		dirFS := os.DirFS("testdata/static")
 		_, diags := preview.Preview(t.Context(), preview.Input{
 			PlanJSONPath:    "",
diff --git a/preview.go b/preview.go
index b30882f..ed51211 100644
--- a/preview.go
+++ b/preview.go
@@ -59,7 +59,7 @@ func Preview(ctx context.Context, input Input, dir fs.FS) (output *Output, diagn
 	// TODO: Fix logging. There is no way to pass in an instanced logger to
 	//   the parser.
 	// slog.SetLogLoggerLevel(slog.LevelDebug)
-	//slog.SetDefault(slog.New(log.NewHandler(os.Stderr, nil)))
+	// slog.SetDefault(slog.New(log.NewHandler(os.Stderr, nil)))
 
 	varFiles, err := tfVarFiles("", dir)
 	if err != nil {
diff --git a/preview_test.go b/preview_test.go
index 0c91d36..5bba3a9 100644
--- a/preview_test.go
+++ b/preview_test.go
@@ -504,12 +504,14 @@ func (a assertParam) optVals(opts ...string) assertParam {
 	})
 }
 
+//nolint:unused
 func (a assertParam) opts(opts ...types.ParameterOption) assertParam {
 	return a.extend(func(t *testing.T, parameter types.Parameter) {
 		assert.ElementsMatch(t, opts, parameter.Options, "parameter options equality check")
 	})
 }
 
+//nolint:revive
 func (a assertParam) extend(f assertParam) assertParam {
 	if a == nil {
 		a = func(t *testing.T, parameter types.Parameter) {}
diff --git a/previewe2e_test.go b/previewe2e_test.go
index c0c1ad0..3a9adb2 100644
--- a/previewe2e_test.go
+++ b/previewe2e_test.go
@@ -80,7 +80,7 @@ func Test_VerifyE2E(t *testing.T) {
 			continue
 		}
 
-		entryFiles, err := fs.ReadDir(dirFs, filepath.Join(entry.Name()))
+		entryFiles, err := fs.ReadDir(dirFs, entry.Name())
 		require.NoError(t, err, "reading test data dir")
 		if !slices.ContainsFunc(entryFiles, func(entry fs.DirEntry) bool {
 			return filepath.Ext(entry.Name()) == ".tf"
@@ -137,6 +137,7 @@ func Test_VerifyE2E(t *testing.T) {
 					pd, err := json.Marshal(plan)
 					require.NoError(t, err, "marshaling plan")
 
+					//nolint:gosec // unit test
 					err = os.WriteFile(filepath.Join(wp, "plan.json"), pd, 0644)
 					require.NoError(t, err, "writing plan.json")
 
diff --git a/site/genweb/main.go b/site/genweb/main.go
index 153cb97..fd04236 100644
--- a/site/genweb/main.go
+++ b/site/genweb/main.go
@@ -59,6 +59,7 @@ func main() {
 	}
 
 	if outFile != nil {
+		//nolint:gosec
 		_ = os.WriteFile(*outFile, []byte(output), 0644)
 	} else {
 		_, _ = fmt.Println(output)
diff --git a/source.go b/source.go
index a1c5064..27d22c8 100644
--- a/source.go
+++ b/source.go
@@ -7,6 +7,7 @@ import (
 	"github.com/hashicorp/hcl/v2"
 )
 
+//nolint:unused
 func source(r hcl.Range, files map[string]*hcl.File) ([]byte, error) {
 	file, ok := files[r.Filename]
 	if !ok {
diff --git a/types/owner.go b/types/owner.go
index e714d5f..2962ca7 100644
--- a/types/owner.go
+++ b/types/owner.go
@@ -56,7 +56,7 @@ func (o *WorkspaceOwner) ToCtyValue() (cty.Value, error) {
 		)),
 	}))
 	if err != nil {
-		return cty.Value{}, xerrors.Errorf("failed to convert owner value", err)
+		return cty.Value{}, xerrors.Errorf("failed to convert owner value: %w", err)
 	}
 	return ownerValue, nil
 }
diff --git a/types/owner_test.go b/types/owner_test.go
index d8fb549..3361f3a 100644
--- a/types/owner_test.go
+++ b/types/owner_test.go
@@ -1,13 +1,17 @@
-package types
+package types_test
 
 import (
 	"testing"
 
 	"github.com/stretchr/testify/require"
+
+	"github.com/coder/preview/types"
 )
 
 func TestToCtyValue(t *testing.T) {
-	owner := WorkspaceOwner{
+	t.Parallel()
+
+	owner := types.WorkspaceOwner{
 		ID:           "f6457744-3e16-45b2-b3b0-80c2df491c99",
 		Name:         "Nissa",
 		FullName:     "Nissa, Worldwaker",
@@ -15,7 +19,7 @@ func TestToCtyValue(t *testing.T) {
 		SSHPublicKey: "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIBSHXs/HCgZlpEBOXLvLw4KaOrhy1DM1Vw6M/HPVE/UA\n",
 		Groups:       []string{"Everyone", "Planeswalkers", "Green"},
 		LoginType:    "password",
-		RBACRoles: []WorkspaceOwnerRBACRole{
+		RBACRoles: []types.WorkspaceOwnerRBACRole{
 			{Name: "User Admin"},
 			{Name: "Organization User Admin", OrgID: "5af9253a-ecde-4a71-b8f5-c8d15be9e52b"},
 		},
@@ -38,7 +42,9 @@ func TestToCtyValue(t *testing.T) {
 }
 
 func TestToCtyValueWithNilLists(t *testing.T) {
-	owner := WorkspaceOwner{
+	t.Parallel()
+
+	owner := types.WorkspaceOwner{
 		ID:           "f6457744-3e16-45b2-b3b0-80c2df491c99",
 		Name:         "Nissa",
 		FullName:     "Nissa, Worldwaker",
diff --git a/types/parameter.go b/types/parameter.go
index 6f58ff2..d5fbc67 100644
--- a/types/parameter.go
+++ b/types/parameter.go
@@ -90,7 +90,7 @@ func (v ParameterValidation) Valid(typ string, value string) error {
 		Monotonic:   orZero(v.Monotonic),
 		Regex:       orZero(v.Regex),
 		Error:       v.Error,
-	}).Valid(provider.OptionType(typ), value)
+	}).Valid(typ, value)
 }
 
 type ParameterOption struct {
diff --git a/types/primitive.go b/types/primitive.go
index ae81652..bb8f610 100644
--- a/types/primitive.go
+++ b/types/primitive.go
@@ -42,9 +42,8 @@ func CtyValueString(val cty.Value) (string, error) {
 	case cty.Bool:
 		if val.True() {
 			return "true", nil
-		} else {
-			return "false", nil
 		}
+		return "false", nil
 	case cty.Number:
 		return val.AsBigFloat().String(), nil
 	case cty.String:
diff --git a/types/tags.go b/types/tags.go
index b4cb487..5fadebc 100644
--- a/types/tags.go
+++ b/types/tags.go
@@ -87,7 +87,7 @@ func (t Tag) KeyString() string {
 	return t.Key.AsString()
 }
 
-func (t Tag) AsStrings() (string, string) {
+func (t Tag) AsStrings() (key string, value string) {
 	return t.KeyString(), t.Value.AsString()
 }
 
diff --git a/types/value_test.go b/types/value_test.go
index 099b0bd..fd904d6 100644
--- a/types/value_test.go
+++ b/types/value_test.go
@@ -82,6 +82,8 @@ func TestSafeHCLString(t *testing.T) {
 
 	for _, tc := range cases {
 		t.Run(tc.name, func(t *testing.T) {
+			t.Parallel()
+
 			require.Equal(t, tc.asString, tc.input.AsString())
 			require.Equal(t, tc.known, tc.input.IsKnown(), "known")
 			require.Equal(t, tc.valid, tc.input.Valid(), "valid")
diff --git a/web/websocket.go b/web/websocket.go
index a949199..d0ec8ce 100644
--- a/web/websocket.go
+++ b/web/websocket.go
@@ -25,7 +25,6 @@ func (s *Session) Listen(ctx context.Context, conn *websocket.Conn) {
 	// Always close the connection at the end of the Listen.
 	defer conn.Close(websocket.StatusNormalClosure, "closing connection")
 	<-ctx.Done()
-	return
 }
 
 func (s *Session) readLoop(ctx context.Context, cancel func(), conn *websocket.Conn) {
diff --git a/workspacetags.go b/workspacetags.go
index 6181c4a..d3f6c76 100644
--- a/workspacetags.go
+++ b/workspacetags.go
@@ -48,7 +48,7 @@ func workspaceTags(modules terraform.Modules, files map[string]*hcl.File) (types
 			}
 
 			// tagsObj, ok := tagsAttr.HCLAttribute().Expr.(*hclsyntax.ObjectConsExpr)
-			//if !ok {
+			// if !ok {
 			//	diags = diags.Append(&hcl.Diagnostic{
 			//		Severity: hcl.DiagError,
 			//		Summary:  "Incorrect type for \"tags\" attribute",
@@ -95,16 +95,16 @@ func workspaceTags(modules terraform.Modules, files map[string]*hcl.File) (types
 }
 
 // newTag creates a workspace tag from its hcl expression.
-func newTag(srcRange *hcl.Range, files map[string]*hcl.File, key, val cty.Value) (types.Tag, *hcl.Diagnostic) {
+func newTag(srcRange *hcl.Range, _ map[string]*hcl.File, key, val cty.Value) (types.Tag, *hcl.Diagnostic) {
 	// key, kdiags := expr.KeyExpr.Value(evCtx)
-	//val, vdiags := expr.ValueExpr.Value(evCtx)
+	// val, vdiags := expr.ValueExpr.Value(evCtx)
 
 	// TODO: ???
 
 	// if kdiags.HasErrors() {
 	//	key = cty.UnknownVal(cty.String)
 	//}
-	//if vdiags.HasErrors() {
+	// if vdiags.HasErrors() {
 	//	val = cty.UnknownVal(cty.String)
 	//}
 
@@ -151,13 +151,13 @@ func newTag(srcRange *hcl.Range, files map[string]*hcl.File, key, val cty.Value)
 	}
 
 	// ks, err := source(expr.KeyExpr.Range(), files)
-	//if err == nil {
+	// if err == nil {
 	//	src := string(ks)
 	//	tag.Key.Source = &src
 	//}
 	//
-	//vs, err := source(expr.ValueExpr.Range(), files)
-	//if err == nil {
+	// vs, err := source(expr.ValueExpr.Range(), files)
+	// if err == nil {
 	//	src := string(vs)
 	//	tag.Value.Source = &src
 	//}

From 1be64013cf02deb7fcfd7b805392724362d6af61 Mon Sep 17 00:00:00 2001
From: Steven Masley 
Date: Mon, 5 May 2025 16:26:23 -0500
Subject: [PATCH 12/61] match coder/coder linter version

---
 .github/workflows/lint.yml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml
index ade5940..4de789f 100644
--- a/.github/workflows/lint.yml
+++ b/.github/workflows/lint.yml
@@ -23,7 +23,7 @@ jobs:
 
       - name: Get golangci-lint cache dir
         run: |
-          linter_ver=1.55.2
+          linter_ver=1.64.8
           go install github.com/golangci/golangci-lint/cmd/golangci-lint@v$linter_ver
           dir=$(golangci-lint cache status | awk '/Dir/ { print $2 }')
           echo "LINT_CACHE_DIR=$dir" >> $GITHUB_ENV

From abce7d3c5e91a5f06e1b35251103f873aca98010 Mon Sep 17 00:00:00 2001
From: Steven Masley 
Date: Mon, 5 May 2025 16:45:07 -0500
Subject: [PATCH 13/61] add rules.go to catch a possible panic

---
 extract/parameter.go |  4 ++++
 go.mod               |  1 +
 go.sum               |  2 ++
 hclext/merge.go      |  9 ++++++++-
 hclext/references.go |  1 +
 hclext/vartypes.go   | 43 -------------------------------------------
 paramhook.go         |  1 +
 scripts/rules.go     | 19 +++++++++++++++++++
 types/primitive.go   |  9 +++++++++
 types/value.go       |  1 +
 10 files changed, 46 insertions(+), 44 deletions(-)
 delete mode 100644 hclext/vartypes.go

diff --git a/extract/parameter.go b/extract/parameter.go
index 3851635..6cbd791 100644
--- a/extract/parameter.go
+++ b/extract/parameter.go
@@ -159,6 +159,7 @@ func ParameterFromBlock(block *terraform.Block) (*types.Parameter, hcl.Diagnosti
 	if ctyType != cty.NilType && pVal.Value.Type().Equals(cty.String) {
 		// TODO: Wish we could support more types, but only string types are
 		// allowed.
+		//nolint:gocritic // string type asserted
 		valStr := pVal.Value.AsString()
 		// Apply validations to the parameter value
 		for _, v := range p.Validations {
@@ -328,6 +329,7 @@ func requiredString(block *terraform.Block, key string) (string, *hcl.Diagnostic
 		return "", diag
 	}
 
+	// nolint:gocritic // string type asserted
 	return tyVal.AsString(), nil
 }
 
@@ -400,6 +402,7 @@ func nullableString(block *terraform.Block, key string) *string {
 		return nil
 	}
 
+	//nolint:gocritic // string type asserted
 	str := val.AsString()
 	return &str
 }
@@ -414,6 +417,7 @@ func optionalString(block *terraform.Block, key string) string {
 		return ""
 	}
 
+	//nolint:gocritic // string type asserted
 	return val.AsString()
 }
 
diff --git a/go.mod b/go.mod
index 7ea2251..634edb1 100644
--- a/go.mod
+++ b/go.mod
@@ -98,6 +98,7 @@ require (
 	github.com/pion/udp v0.1.4 // indirect
 	github.com/planetscale/vtprotobuf v0.6.1-0.20240319094008-0393e58bdf10 // indirect
 	github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 // indirect
+	github.com/quasilyte/go-ruleguard/dsl v0.3.22 // indirect
 	github.com/rivo/uniseg v0.4.7 // indirect
 	github.com/robfig/cron/v3 v3.0.1 // indirect
 	github.com/samber/lo v1.49.1 // indirect
diff --git a/go.sum b/go.sum
index c22d751..3cdb559 100644
--- a/go.sum
+++ b/go.sum
@@ -1118,6 +1118,8 @@ github.com/power-devops/perfstat v0.0.0-20240221224432-82ca36839d55/go.mod h1:Om
 github.com/prometheus/client_model v0.0.0-20190812154241-14fe0d1b01d4/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA=
 github.com/prometheus/client_model v0.2.0/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA=
 github.com/prometheus/client_model v0.3.0/go.mod h1:LDGWKZIo7rky3hgvBe+caln+Dr3dPggB5dvjtD7w9+w=
+github.com/quasilyte/go-ruleguard/dsl v0.3.22 h1:wd8zkOhSNr+I+8Qeciml08ivDt1pSXe60+5DqOpCjPE=
+github.com/quasilyte/go-ruleguard/dsl v0.3.22/go.mod h1:KeCP03KrjuSO0H1kTuZQCWlQPulDV6YMIXmpQss17rU=
 github.com/remyoudompheng/bigfft v0.0.0-20200410134404-eec4a21b6bb0/go.mod h1:qqbHyh8v60DhA7CoWK5oRCqLrMHRGoxYCSS9EjAz6Eo=
 github.com/rivo/uniseg v0.1.0/go.mod h1:J6wj4VEh+S6ZtnVlnTBMWIodfgj8LQOQFoIToxlJtxc=
 github.com/rivo/uniseg v0.2.0/go.mod h1:J6wj4VEh+S6ZtnVlnTBMWIodfgj8LQOQFoIToxlJtxc=
diff --git a/hclext/merge.go b/hclext/merge.go
index 8c2919c..caeb762 100644
--- a/hclext/merge.go
+++ b/hclext/merge.go
@@ -1,6 +1,8 @@
 package hclext
 
-import "github.com/zclconf/go-cty/cty"
+import (
+	"github.com/zclconf/go-cty/cty"
+)
 
 func MergeObjects(a, b cty.Value) cty.Value {
 	output := make(map[string]cty.Value)
@@ -9,6 +11,11 @@ func MergeObjects(a, b cty.Value) cty.Value {
 		output[key] = val
 	}
 	b.ForEachElement(func(key, val cty.Value) (stop bool) {
+		// TODO: Should this error be captured?
+		if key.Type() != cty.String {
+			return true
+		}
+		//nolint:gocritic // string type asserted above
 		k := key.AsString()
 		old := output[k]
 		if old.IsKnown() && isNotEmptyObject(old) && isNotEmptyObject(val) {
diff --git a/hclext/references.go b/hclext/references.go
index 7da5a0d..ba23e3f 100644
--- a/hclext/references.go
+++ b/hclext/references.go
@@ -67,6 +67,7 @@ func CreateDotReferenceFromTraversal(traversals ...hcl.Traversal) string {
 			case hcl.TraverseIndex:
 				switch {
 				case part.Key.Type().Equals(cty.String):
+					//nolint:gocritic // string type asserted above
 					refParts = append(refParts, fmt.Sprintf("[%s]", part.Key.AsString()))
 				case part.Key.Type().Equals(cty.Number):
 					idx, _ := part.Key.AsBigFloat().Int64()
diff --git a/hclext/vartypes.go b/hclext/vartypes.go
deleted file mode 100644
index 40c8329..0000000
--- a/hclext/vartypes.go
+++ /dev/null
@@ -1,43 +0,0 @@
-package hclext
-
-import (
-	"github.com/hashicorp/hcl/v2"
-	"github.com/hashicorp/hcl/v2/ext/typeexpr"
-	"github.com/hashicorp/hcl/v2/hclsyntax"
-	"github.com/zclconf/go-cty/cty"
-)
-
-func DecodeVarType(exp hcl.Expression) (cty.Type, *typeexpr.Defaults, error) {
-	// This block converts the string literals "string" -> string
-	// Coder used to allow literal strings, instead of types as keywords. So
-	// we have to handle these cases for backwards compatibility.
-	if tpl, ok := exp.(*hclsyntax.TemplateExpr); ok && len(tpl.Parts) == 1 {
-		if lit, ok := tpl.Parts[0].(*hclsyntax.LiteralValueExpr); ok && lit.Val.Type() == cty.String {
-			keyword := lit.Val.AsString()
-
-			exp = &hclsyntax.ScopeTraversalExpr{
-				Traversal: []hcl.Traverser{
-					hcl.TraverseRoot{
-						Name:     keyword,
-						SrcRange: exp.Range(),
-					},
-				},
-				SrcRange: exp.Range(),
-			}
-		}
-	}
-
-	// Special-case the shortcuts for list(any) and map(any) which aren't hcl.
-	switch hcl.ExprAsKeyword(exp) {
-	case "list":
-		return cty.List(cty.DynamicPseudoType), nil, nil
-	case "map":
-		return cty.Map(cty.DynamicPseudoType), nil, nil
-	}
-
-	t, def, diag := typeexpr.TypeConstraintWithDefaults(exp)
-	if diag.HasErrors() {
-		return cty.NilType, nil, diag
-	}
-	return t, def, nil
-}
diff --git a/paramhook.go b/paramhook.go
index 7966138..03eadc5 100644
--- a/paramhook.go
+++ b/paramhook.go
@@ -32,6 +32,7 @@ func parameterContextsEvalHook(input Input) func(ctx *tfcontext.Context, blocks
 				continue // Ignore the errors at this point
 			}
 
+			//nolint:gocritic // string type asserted
 			name := nameVal.AsString()
 			var value cty.Value
 			pv, ok := input.RichParameterValue(name)
diff --git a/scripts/rules.go b/scripts/rules.go
index c0793cf..8634f12 100644
--- a/scripts/rules.go
+++ b/scripts/rules.go
@@ -14,3 +14,22 @@
 //
 // Note: don't forget to run `golangci-lint cache clean`!
 package gorules
+
+import "github.com/quasilyte/go-ruleguard/dsl"
+
+// asStringsIsDangerous checks for the use of AsString() on cty.Value.
+// This function can panic if not used correctly, so the cty.Type must be known
+// before calling. Ignore this lint if you are confident in your usage.
+func asStringsIsDangerous(m dsl.Matcher) {
+	m.Import("github.com/zclconf/go-cty/cty")
+
+	m.Match(
+		`$v.AsString()`,
+	).
+		Where(
+			m["v"].Type.Is("cty.Value") &&
+				// Ignore unit tests
+				!m.File().Name.Matches(`_test\.go$`),
+		).
+		Report("'AsStrings()' can result in a panic if the type is not known. Ignore this linter with caution")
+}
diff --git a/types/primitive.go b/types/primitive.go
index bb8f610..8f74317 100644
--- a/types/primitive.go
+++ b/types/primitive.go
@@ -7,6 +7,14 @@ import (
 	"github.com/zclconf/go-cty/cty"
 )
 
+func CtyValueStringDefault(def string, val cty.Value) string {
+	str, err := CtyValueString(val)
+	if err != nil {
+		return def
+	}
+	return str
+}
+
 // CtyValueString converts a cty.Value to a string.
 // It supports only primitive types - bool, number, and string.
 // As a special case, it also supports map[string]interface{} with key "value".
@@ -47,6 +55,7 @@ func CtyValueString(val cty.Value) (string, error) {
 	case cty.Number:
 		return val.AsBigFloat().String(), nil
 	case cty.String:
+		//nolint:gocritic // string type asserted above
 		return val.AsString(), nil
 	// We may also have a map[string]interface{} with key "value".
 	case cty.Map(cty.String):
diff --git a/types/value.go b/types/value.go
index 4cc269b..37f862b 100644
--- a/types/value.go
+++ b/types/value.go
@@ -80,6 +80,7 @@ func (s HCLString) AsString() string {
 	if s.Valid() && s.Value.IsKnown() {
 		switch {
 		case s.Value.Type().Equals(cty.String):
+			//nolint:gocritic // string type asserted
 			return s.Value.AsString()
 		case s.Value.Type().Equals(cty.Number):
 			// TODO: Float vs Int?

From 3710fe023aa1bdffe805f1500a8756876269c0de Mon Sep 17 00:00:00 2001
From: Steven Masley 
Date: Mon, 5 May 2025 17:00:15 -0500
Subject: [PATCH 14/61] delete more unused code

---
 cli/clidisplay/resources.go | 12 ------------
 cli/plan.go                 |  2 +-
 log.go                      | 15 ---------------
 3 files changed, 1 insertion(+), 28 deletions(-)
 delete mode 100644 log.go

diff --git a/cli/clidisplay/resources.go b/cli/clidisplay/resources.go
index 0b4fe49..e19c3e3 100644
--- a/cli/clidisplay/resources.go
+++ b/cli/clidisplay/resources.go
@@ -30,23 +30,11 @@ func WorkspaceTags(writer io.Writer, tags types.TagBlocks) hcl.Diagnostics {
 				k, v := tag.AsStrings()
 				tableWriter.AppendRow(table.Row{k, v, ""})
 				continue
-				// diags = diags.Extend(tDiags)
-				// if !diags.HasErrors() {
-				//	tableWriter.AppendRow(table.Row{k, v, ""})
-				//	continue
-				//}
 			}
 
 			k := tag.KeyString()
 			refs := tag.References()
 			tableWriter.AppendRow(table.Row{k, "??", strings.Join(refs, "\n")})
-
-			// refs := tb.AllReferences()
-			// refsStr := make([]string, 0, len(refs))
-			// for _, ref := range refs {
-			//	refsStr = append(refsStr, ref.String())
-			//}
-			// tableWriter.AppendRow(table.Row{unknown, "???", strings.Join(refsStr, "\n")})
 		}
 	}
 	_, _ = fmt.Fprintln(writer, tableWriter.Render())
diff --git a/cli/plan.go b/cli/plan.go
index 62929c5..c07c498 100644
--- a/cli/plan.go
+++ b/cli/plan.go
@@ -54,7 +54,7 @@ func (*RootCmd) TerraformPlan() *serpent.Command {
 
 			var indented bytes.Buffer
 			_ = json.Indent(&indented, buf.Bytes(), "", "  ")
-			//nolint:gosec
+			//nolint:gosec // these files are not a secret
 			_ = os.WriteFile("plan.json", indented.Bytes(), 0644)
 			return nil
 		},
diff --git a/log.go b/log.go
deleted file mode 100644
index ed1c223..0000000
--- a/log.go
+++ /dev/null
@@ -1,15 +0,0 @@
-package preview
-
-import (
-	"os"
-
-	tlog "github.com/aquasecurity/trivy/pkg/log"
-)
-
-func init() {
-	ll := tlog.New(tlog.NewHandler(os.Stderr, &tlog.Options{
-		Level: tlog.LevelDebug,
-	}))
-	var _ = ll
-	// tlog.SetDefault(ll)
-}

From 0876a7db87f0735012c1122215fe4dace7b3d08b Mon Sep 17 00:00:00 2001
From: Steven Masley 
Date: Mon, 5 May 2025 17:11:06 -0500
Subject: [PATCH 15/61] fix AsString to account for other types

---
 types/parameter.go | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/types/parameter.go b/types/parameter.go
index 6eeee34..e390bfd 100644
--- a/types/parameter.go
+++ b/types/parameter.go
@@ -104,7 +104,7 @@ func (r *ParameterData) Valid(value HCLString) hcl.Diagnostics {
 	var valuePtr *string
 	// TODO: What to do if it is not valid?
 	if value.Valid() {
-		val := value.Value.AsString()
+		val := value.AsString()
 		valuePtr = &val
 	}
 

From b20a5bcc182f543dcf5feb2be1f2140eaf0de18e Mon Sep 17 00:00:00 2001
From: Steven Masley 
Date: Mon, 5 May 2025 17:13:52 -0500
Subject: [PATCH 16/61] add skip until provider validation is merged and
 released

---
 testdata/emptydefault/skipe2e | 1 +
 1 file changed, 1 insertion(+)
 create mode 100644 testdata/emptydefault/skipe2e

diff --git a/testdata/emptydefault/skipe2e b/testdata/emptydefault/skipe2e
new file mode 100644
index 0000000..63ecd04
--- /dev/null
+++ b/testdata/emptydefault/skipe2e
@@ -0,0 +1 @@
+Skipping until https://github.com/coder/terraform-provider-coder/pull/381 is merged and released
\ No newline at end of file

From 6cf3c102c2ac8f19d5d78eb88166a4c1402acf85 Mon Sep 17 00:00:00 2001
From: Steven Masley 
Date: Mon, 5 May 2025 17:24:53 -0500
Subject: [PATCH 17/61] remove unused code

---
 types/parameter.go | 10 ----------
 1 file changed, 10 deletions(-)

diff --git a/types/parameter.go b/types/parameter.go
index e390bfd..91cd8ee 100644
--- a/types/parameter.go
+++ b/types/parameter.go
@@ -76,16 +76,6 @@ type ParameterValidation struct {
 	Monotonic *string `json:"validation_monotonic"`
 }
 
-// Valid takes the type of the value and the value itself and returns an error
-// if the value is invalid.
-func (v *ParameterValidation) Valid(typ string, value string) error {
-	// TODO: Validate typ is the enum?
-	// Use the provider.Validation struct to validate the value to be
-	// consistent with the provider.
-	pv := providerValidation(v)
-	return (&pv).Valid(provider.OptionType(typ), value)
-}
-
 type ParameterOption struct {
 	Name        string    `json:"name"`
 	Description string    `json:"description"`

From ccd1012422bceb7dffe7d978619ce71d0d26ecd3 Mon Sep 17 00:00:00 2001
From: Jaayden Halko 
Date: Tue, 6 May 2025 15:52:50 +0100
Subject: [PATCH 18/61] chore: add type for ParameterStyling

---
 site/src/types/preview.ts | 10 ++++++++--
 types/parameter.go        |  8 +++++++-
 2 files changed, 15 insertions(+), 3 deletions(-)

diff --git a/site/src/types/preview.ts b/site/src/types/preview.ts
index 945c7e1..0d19c4d 100644
--- a/site/src/types/preview.ts
+++ b/site/src/types/preview.ts
@@ -35,8 +35,7 @@ export interface ParameterData {
     readonly type: ParameterType;
     // this is likely an enum in an external package "github.com/coder/terraform-provider-coder/v2/provider.ParameterFormType"
     readonly form_type: string;
-    // empty interface{} type, falling back to unknown
-    readonly styling: unknown;
+    readonly styling: ParameterStyling;
     readonly mutable: boolean;
     readonly default_value: NullHCLString;
     readonly icon: string;
@@ -55,6 +54,13 @@ export interface ParameterOption {
     readonly icon: string;
 }
 
+// From types/parameter.go
+export interface ParameterStyling {
+    readonly placeholder?: string;
+    readonly disabled?: boolean;
+    readonly label?: string;
+}
+
 // From types/enum.go
 export type ParameterType = "bool" | "list(string)" | "number" | "string";
 
diff --git a/types/parameter.go b/types/parameter.go
index d5fbc67..f1f07b0 100644
--- a/types/parameter.go
+++ b/types/parameter.go
@@ -50,7 +50,7 @@ type ParameterData struct {
 	Description  string                     `json:"description"`
 	Type         ParameterType              `json:"type"`
 	FormType     provider.ParameterFormType `json:"form_type"`
-	Styling      any                        `json:"styling"`
+	Styling      ParameterStyling           `json:"styling"`
 	Mutable      bool                       `json:"mutable"`
 	DefaultValue HCLString                  `json:"default_value"`
 	Icon         string                     `json:"icon"`
@@ -76,6 +76,12 @@ type ParameterValidation struct {
 	Invalid   *bool   `json:"validation_invalid"`
 }
 
+type ParameterStyling struct {
+	Placeholder *string `json:"placeholder,omitempty"`
+	Disabled    *bool   `json:"disabled,omitempty"`
+	Label       *string `json:"label,omitempty"`
+}
+
 // Valid takes the type of the value and the value itself and returns an error
 // if the value is invalid.
 func (v ParameterValidation) Valid(typ string, value string) error {

From 87fe1cd89f5b400821d175427ce030210d00bc37 Mon Sep 17 00:00:00 2001
From: Jaayden Halko 
Date: Tue, 6 May 2025 16:14:18 +0100
Subject: [PATCH 19/61] chore: update extract logic for parameter styling

---
 extract/parameter.go | 2 +-
 extract/state.go     | 4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/extract/parameter.go b/extract/parameter.go
index 6cbd791..198173c 100644
--- a/extract/parameter.go
+++ b/extract/parameter.go
@@ -57,7 +57,7 @@ func ParameterFromBlock(block *terraform.Block) (*types.Parameter, hcl.Diagnosti
 	}
 
 	ftmeta := optionalString(block, "styling")
-	formTypeMeta := make(map[string]any)
+	var formTypeMeta types.ParameterStyling
 	if ftmeta != "" {
 		_ = json.Unmarshal([]byte(ftmeta), &formTypeMeta)
 	}
diff --git a/extract/state.go b/extract/state.go
index bb1a942..048ae85 100644
--- a/extract/state.go
+++ b/extract/state.go
@@ -54,11 +54,11 @@ func ParameterFromState(block *tfjson.StateResource) (types.Parameter, error) {
 	}
 
 	ftmeta := st.optionalString("styling")
-	var formTypeMeta any
+	var formTypeMeta types.ParameterStyling
 	if ftmeta != "" {
 		_ = json.Unmarshal([]byte(ftmeta), &formTypeMeta)
 	} else {
-		formTypeMeta = map[string]any{}
+		formTypeMeta = types.ParameterStyling{}
 	}
 
 	param := types.Parameter{

From 154d86b5a92a201f86a68de03816c507ef1ab292 Mon Sep 17 00:00:00 2001
From: Steven Masley 
Date: Tue, 6 May 2025 14:53:23 -0500
Subject: [PATCH 20/61] update provider

---
 types/parameter.go | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/types/parameter.go b/types/parameter.go
index 91cd8ee..5195bcf 100644
--- a/types/parameter.go
+++ b/types/parameter.go
@@ -112,7 +112,7 @@ func (r *ParameterData) Valid(value HCLString) hcl.Diagnostics {
 		Optional:    !r.Required,
 		Order:       int(r.Order),
 		Ephemeral:   r.Ephemeral,
-	}).ValidateInput(valuePtr)
+	}).ValidateInput(valuePtr, nil) // TODO: Pass in previous value
 
 	if diag.HasError() {
 		// TODO: We can take the attr path and decorate the error with

From 753772a63f1520712e5b75ecbf05e777552dd465 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E3=82=B1=E3=82=A4=E3=83=A9?= 
Date: Tue, 6 May 2025 16:37:43 -0600
Subject: [PATCH 21/61] Update testdata/emptydefault/skipe2e

---
 testdata/emptydefault/skipe2e | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/testdata/emptydefault/skipe2e b/testdata/emptydefault/skipe2e
index 63ecd04..bc530d8 100644
--- a/testdata/emptydefault/skipe2e
+++ b/testdata/emptydefault/skipe2e
@@ -1 +1 @@
-Skipping until https://github.com/coder/terraform-provider-coder/pull/381 is merged and released
\ No newline at end of file
+Skipping until https://github.com/coder/terraform-provider-coder/pull/381 is merged and released

From 670b6c8da3e882d984bccbd8bece019dba22703d Mon Sep 17 00:00:00 2001
From: Steven Masley 
Date: Thu, 8 May 2025 15:18:49 -0500
Subject: [PATCH 22/61] chore: add warnings if modules are missing

Missing or unloaded modules is an incomplete terraform. This warning
is a bit verbose, but signals the functionality will be impacted.
---
 CONTRIBUTING.md                         |  1 +
 preview_test.go                         | 27 +++++++++++++
 testdata/missingmodule/main.tf          | 12 ++++++
 testdata/missingmodule/one/one.tf       |  3 ++
 testdata/missingmodule/one/onea/onea.tf | 14 +++++++
 testdata/missingmodule/skipe2e          |  1 +
 warnings.go                             | 51 +++++++++++++++++++++++++
 7 files changed, 109 insertions(+)
 create mode 100644 testdata/missingmodule/main.tf
 create mode 100644 testdata/missingmodule/one/one.tf
 create mode 100644 testdata/missingmodule/one/onea/onea.tf
 create mode 100644 testdata/missingmodule/skipe2e

diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md
index e20c6e5..019e37e 100644
--- a/CONTRIBUTING.md
+++ b/CONTRIBUTING.md
@@ -6,3 +6,4 @@ To run preview:
 2. `pnpm install`
 3. `cd ..`
 4. `go run ./cmd/preview/main.go web --pnpm=site`
+5. visit http://localhost:5173/?testcontrols=true
diff --git a/preview_test.go b/preview_test.go
index a72dfab..afa1531 100644
--- a/preview_test.go
+++ b/preview_test.go
@@ -5,8 +5,11 @@ import (
 	"encoding/json"
 	"os"
 	"path/filepath"
+	"regexp"
+	"slices"
 	"testing"
 
+	"github.com/hashicorp/hcl/v2"
 	"github.com/stretchr/testify/assert"
 	"github.com/stretchr/testify/require"
 
@@ -38,6 +41,7 @@ func Test_Extract(t *testing.T) {
 		expTags     map[string]string
 		unknownTags []string
 		params      map[string]assertParam
+		warnings    []*regexp.Regexp
 	}{
 		{
 			name:        "bad param values",
@@ -402,6 +406,19 @@ func Test_Extract(t *testing.T) {
 				"beta":  ap().unknown(),
 			},
 		},
+		{
+			name:    "missing_module",
+			dir:     "missingmodule",
+			expTags: map[string]string{},
+			input: preview.Input{
+				ParameterValues: map[string]string{},
+			},
+			unknownTags: []string{},
+			params:      map[string]assertParam{},
+			warnings: []*regexp.Regexp{
+				regexp.MustCompile("Module not loaded"),
+			},
+		},
 		{
 			skip:    "skip until https://github.com/aquasecurity/trivy/pull/8479 is resolved",
 			name:    "submodcount",
@@ -440,6 +457,16 @@ func Test_Extract(t *testing.T) {
 			}
 			require.False(t, diags.HasErrors())
 
+			if len(tc.warnings) > 0 {
+				for _, w := range tc.warnings {
+					idx := slices.IndexFunc(diags, func(diagnostic *hcl.Diagnostic) bool {
+						return w.MatchString(diagnostic.Error())
+
+					})
+					require.Greater(t, idx, -1, "expected warning %q to be present in diags", w.String())
+				}
+			}
+
 			// Assert tags
 			validTags := output.WorkspaceTags.Tags()
 
diff --git a/testdata/missingmodule/main.tf b/testdata/missingmodule/main.tf
new file mode 100644
index 0000000..146e333
--- /dev/null
+++ b/testdata/missingmodule/main.tf
@@ -0,0 +1,12 @@
+module "does-not-exist" {
+  source         = "registry.coder.com/modules/does-not-exist/coder"
+}
+
+module "does-not-exist-2" {
+  count = 0
+  source         = "registry.coder.com/modules/does-not-exist/coder"
+}
+
+module "one" {
+  source = "./one"
+}
\ No newline at end of file
diff --git a/testdata/missingmodule/one/one.tf b/testdata/missingmodule/one/one.tf
new file mode 100644
index 0000000..786d1eb
--- /dev/null
+++ b/testdata/missingmodule/one/one.tf
@@ -0,0 +1,3 @@
+module "onea" {
+  source = "./onea"
+}
\ No newline at end of file
diff --git a/testdata/missingmodule/one/onea/onea.tf b/testdata/missingmodule/one/onea/onea.tf
new file mode 100644
index 0000000..8b0c1f5
--- /dev/null
+++ b/testdata/missingmodule/one/onea/onea.tf
@@ -0,0 +1,14 @@
+terraform {
+  required_providers {
+    coder = {
+      source = "coder/coder"
+      version = "2.4.0-pre0"
+    }
+  }
+}
+
+data "null_data_source" "values" {
+  inputs = {
+    foo = "bar"
+  }
+}
\ No newline at end of file
diff --git a/testdata/missingmodule/skipe2e b/testdata/missingmodule/skipe2e
new file mode 100644
index 0000000..ae4a73a
--- /dev/null
+++ b/testdata/missingmodule/skipe2e
@@ -0,0 +1 @@
+Not a real module
\ No newline at end of file
diff --git a/warnings.go b/warnings.go
index 8a55e3b..7e043b7 100644
--- a/warnings.go
+++ b/warnings.go
@@ -11,6 +11,57 @@ import (
 func warnings(modules terraform.Modules) hcl.Diagnostics {
 	var diags hcl.Diagnostics
 	diags = diags.Extend(unexpandedCountBlocks(modules))
+	diags = diags.Extend(unresolvedModules(modules))
+
+	return diags
+}
+
+// unresolvedModules does a best effort to try and detect if some modules
+// failed to resolve. This is usually because `terraform init` is not run.
+func unresolvedModules(modules terraform.Modules) hcl.Diagnostics {
+	var diags hcl.Diagnostics
+	modulesUsed := make(map[string]bool)
+	modulesByID := make(map[string]*terraform.Block)
+
+	// There is no easy way to know if a `module` failed to resolve. The failure is
+	// only logged in the trivy package. No errors are returned to the caller. So
+	// instead this code will infer a failed resolution by checking if any blocks
+	// exist that reference each `module` block. This will work as long as the module
+	// has some content. If a module is completely empty, then it will be detected as
+	// "not loaded".
+	blocks := modules.GetBlocks()
+	for _, block := range blocks {
+		if block.InModule() && block.ModuleBlock() != nil {
+			modulesUsed[block.ModuleBlock().ID()] = true
+		}
+
+		if block.Type() == "module" {
+			modulesByID[block.ID()] = block
+			_, ok := modulesUsed[block.ID()]
+			if !ok {
+				modulesUsed[block.ID()] = false
+			}
+		}
+	}
+
+	for id, v := range modulesUsed {
+		if !v {
+			block, ok := modulesByID[id]
+			if ok {
+				label := block.Type()
+				for _, l := range block.Labels() {
+					label += " " + fmt.Sprintf("%q", l)
+				}
+
+				diags = diags.Append(&hcl.Diagnostic{
+					Severity: hcl.DiagWarning,
+					Summary:  "Module not loaded, did you run `terraform init`? Or maybe the module is empty.",
+					Detail:   fmt.Sprintf("Module '%s' in file %q cannot be resolved. This module will be ignored.", label, block.HCLBlock().DefRange),
+					Subject:  &(block.HCLBlock().DefRange),
+				})
+			}
+		}
+	}
 
 	return diags
 }

From efcd02c9e82f00116b49af563b4ea88d5ddd6f71 Mon Sep 17 00:00:00 2001
From: Danny Kopping 
Date: Fri, 9 May 2025 13:07:41 +0200
Subject: [PATCH 23/61] chore: update terraform-provider-coder to v2.4.0

Signed-off-by: Danny Kopping 
---
 go.mod | 2 +-
 go.sum | 4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/go.mod b/go.mod
index 51c118b..b5d930a 100644
--- a/go.mod
+++ b/go.mod
@@ -7,7 +7,7 @@ require (
 	github.com/aquasecurity/trivy v0.58.2
 	github.com/coder/guts v1.0.2-0.20250227211802-139809366a22
 	github.com/coder/serpent v0.10.0
-	github.com/coder/terraform-provider-coder/v2 v2.4.0-pre1.0.20250506184715-e011f733bf27
+	github.com/coder/terraform-provider-coder/v2 v2.4.0
 	github.com/coder/websocket v1.8.13
 	github.com/go-chi/chi v4.1.2+incompatible
 	github.com/hashicorp/go-cty v1.4.1-0.20200414143053-d3edf31b6320
diff --git a/go.sum b/go.sum
index 4e42b90..1f8d157 100644
--- a/go.sum
+++ b/go.sum
@@ -718,8 +718,8 @@ github.com/coder/pretty v0.0.0-20230908205945-e89ba86370e0 h1:3A0ES21Ke+FxEM8CXx
 github.com/coder/pretty v0.0.0-20230908205945-e89ba86370e0/go.mod h1:5UuS2Ts+nTToAMeOjNlnHFkPahrtDkmpydBen/3wgZc=
 github.com/coder/serpent v0.10.0 h1:ofVk9FJXSek+SmL3yVE3GoArP83M+1tX+H7S4t8BSuM=
 github.com/coder/serpent v0.10.0/go.mod h1:cZFW6/fP+kE9nd/oRkEHJpG6sXCtQ+AX7WMMEHv0Y3Q=
-github.com/coder/terraform-provider-coder/v2 v2.4.0-pre1.0.20250506184715-e011f733bf27 h1:CLJwMqst39+wfFehYQzVOiG5uXUtC5fbAZ3/EpxOWos=
-github.com/coder/terraform-provider-coder/v2 v2.4.0-pre1.0.20250506184715-e011f733bf27/go.mod h1:2kaBpn5k9ZWtgKq5k4JbkVZG9DzEqR4mJSmpdshcO+s=
+github.com/coder/terraform-provider-coder/v2 v2.4.0 h1:uuFmF03IyahAZLXEukOdmvV9hGfUMJSESD8+G5wkTcM=
+github.com/coder/terraform-provider-coder/v2 v2.4.0/go.mod h1:2kaBpn5k9ZWtgKq5k4JbkVZG9DzEqR4mJSmpdshcO+s=
 github.com/coder/websocket v1.8.13 h1:f3QZdXy7uGVz+4uCJy2nTZyM0yTBj8yANEHhqlXZ9FE=
 github.com/coder/websocket v1.8.13/go.mod h1:LNVeNrXQZfe5qhS9ALED3uA+l5pPqvwXg3CKoDBB2gs=
 github.com/containerd/log v0.1.0 h1:TCJt7ioM2cr/tfR8GPbGf9/VRAX8D2B4PjzCpfX540I=

From 9374d44282439c6f6c785c1711d996af841d55b8 Mon Sep 17 00:00:00 2001
From: Steven Masley 
Date: Fri, 9 May 2025 09:22:44 -0500
Subject: [PATCH 24/61] Update warnings.go
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

Co-authored-by: ケイラ 
---
 warnings.go | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/warnings.go b/warnings.go
index 7e043b7..781f49a 100644
--- a/warnings.go
+++ b/warnings.go
@@ -55,7 +55,7 @@ func unresolvedModules(modules terraform.Modules) hcl.Diagnostics {
 
 				diags = diags.Append(&hcl.Diagnostic{
 					Severity: hcl.DiagWarning,
-					Summary:  "Module not loaded, did you run `terraform init`? Or maybe the module is empty.",
+					Summary:  "Module not loaded. Did you run `terraform init`?",
 					Detail:   fmt.Sprintf("Module '%s' in file %q cannot be resolved. This module will be ignored.", label, block.HCLBlock().DefRange),
 					Subject:  &(block.HCLBlock().DefRange),
 				})

From 3bfc55455542d35e989a1fda0441e8eb93193390 Mon Sep 17 00:00:00 2001
From: Steven Masley 
Date: Fri, 9 May 2025 09:23:59 -0500
Subject: [PATCH 25/61] newlines to end of file

---
 testdata/missingmodule/main.tf          | 2 +-
 testdata/missingmodule/one/one.tf       | 2 +-
 testdata/missingmodule/one/onea/onea.tf | 2 +-
 testdata/missingmodule/skipe2e          | 2 +-
 4 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/testdata/missingmodule/main.tf b/testdata/missingmodule/main.tf
index 146e333..98839f1 100644
--- a/testdata/missingmodule/main.tf
+++ b/testdata/missingmodule/main.tf
@@ -9,4 +9,4 @@ module "does-not-exist-2" {
 
 module "one" {
   source = "./one"
-}
\ No newline at end of file
+}
diff --git a/testdata/missingmodule/one/one.tf b/testdata/missingmodule/one/one.tf
index 786d1eb..89e1f85 100644
--- a/testdata/missingmodule/one/one.tf
+++ b/testdata/missingmodule/one/one.tf
@@ -1,3 +1,3 @@
 module "onea" {
   source = "./onea"
-}
\ No newline at end of file
+}
diff --git a/testdata/missingmodule/one/onea/onea.tf b/testdata/missingmodule/one/onea/onea.tf
index 8b0c1f5..54718cf 100644
--- a/testdata/missingmodule/one/onea/onea.tf
+++ b/testdata/missingmodule/one/onea/onea.tf
@@ -11,4 +11,4 @@ data "null_data_source" "values" {
   inputs = {
     foo = "bar"
   }
-}
\ No newline at end of file
+}
diff --git a/testdata/missingmodule/skipe2e b/testdata/missingmodule/skipe2e
index ae4a73a..f43c945 100644
--- a/testdata/missingmodule/skipe2e
+++ b/testdata/missingmodule/skipe2e
@@ -1 +1 @@
-Not a real module
\ No newline at end of file
+Not a real module

From 105d830e352d5c062badb81fa193433fccfdd0fe Mon Sep 17 00:00:00 2001
From: Steven Masley 
Date: Fri, 9 May 2025 09:43:52 -0500
Subject: [PATCH 26/61] chore: update github.com/coder/guts to v1.3.0

---
 go.mod              | 2 +-
 go.sum              | 4 ++--
 site/genweb/main.go | 2 ++
 3 files changed, 5 insertions(+), 3 deletions(-)

diff --git a/go.mod b/go.mod
index b5d930a..34f5855 100644
--- a/go.mod
+++ b/go.mod
@@ -5,7 +5,7 @@ go 1.24.2
 require (
 	cdr.dev/slog v1.6.2-0.20240126064726-20367d4aede6
 	github.com/aquasecurity/trivy v0.58.2
-	github.com/coder/guts v1.0.2-0.20250227211802-139809366a22
+	github.com/coder/guts v1.3.0
 	github.com/coder/serpent v0.10.0
 	github.com/coder/terraform-provider-coder/v2 v2.4.0
 	github.com/coder/websocket v1.8.13
diff --git a/go.sum b/go.sum
index 1f8d157..e3c5bf0 100644
--- a/go.sum
+++ b/go.sum
@@ -712,8 +712,8 @@ github.com/cncf/xds/go v0.0.0-20230105202645-06c439db220b/go.mod h1:eXthEFrGJvWH
 github.com/cncf/xds/go v0.0.0-20230607035331-e9ce68804cb4/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs=
 github.com/cncf/xds/go v0.0.0-20240905190251-b4127c9b8d78 h1:QVw89YDxXxEe+l8gU8ETbOasdwEV+avkR75ZzsVV9WI=
 github.com/cncf/xds/go v0.0.0-20240905190251-b4127c9b8d78/go.mod h1:W+zGtBO5Y1IgJhy4+A9GOqVhqLpfZi+vwmdNXUehLA8=
-github.com/coder/guts v1.0.2-0.20250227211802-139809366a22 h1:CACzZc2r5oQj8JKlqiBrMq/MVI7YHqbNndmHJg92B0A=
-github.com/coder/guts v1.0.2-0.20250227211802-139809366a22/go.mod h1:5ducjpIPvmGOcQVigCcXyPFqrH5xeGlZ6c9qPfE1cU4=
+github.com/coder/guts v1.3.0 h1:Kz8LrodQCfz/R06JdCJqdxZDq0BVTTXYYQC/qY3N9fo=
+github.com/coder/guts v1.3.0/go.mod h1:31NO4z6MVTOD4WaCLqE/hUAHGgNok9sRbuMc/LZFopI=
 github.com/coder/pretty v0.0.0-20230908205945-e89ba86370e0 h1:3A0ES21Ke+FxEM8CXx9n47SZOKOpgSE1bbJzlE4qPVs=
 github.com/coder/pretty v0.0.0-20230908205945-e89ba86370e0/go.mod h1:5UuS2Ts+nTToAMeOjNlnHFkPahrtDkmpydBen/3wgZc=
 github.com/coder/serpent v0.10.0 h1:ofVk9FJXSek+SmL3yVE3GoArP83M+1tX+H7S4t8BSuM=
diff --git a/site/genweb/main.go b/site/genweb/main.go
index fd04236..034afde 100644
--- a/site/genweb/main.go
+++ b/site/genweb/main.go
@@ -68,6 +68,8 @@ func main() {
 
 func TsMutations(ts *guts.Typescript) {
 	ts.ApplyMutations(
+		config.NotNullMaps,
+		config.EnumAsTypes,
 		// Enum list generator
 		config.EnumLists,
 		// Export all top level types

From ff34981a083b754b578cc79d36a8e3c102563c95 Mon Sep 17 00:00:00 2001
From: Steven Masley 
Date: Fri, 9 May 2025 10:38:38 -0500
Subject: [PATCH 27/61] fix: add json unmarshal support for diagnostics

---
 types/diagnostics.go      | 22 ++++++++++++++++++++++
 types/diagnostics_test.go | 36 ++++++++++++++++++++++++++++++++++++
 2 files changed, 58 insertions(+)
 create mode 100644 types/diagnostics_test.go

diff --git a/types/diagnostics.go b/types/diagnostics.go
index 41d18b7..3ae0955 100644
--- a/types/diagnostics.go
+++ b/types/diagnostics.go
@@ -10,6 +10,28 @@ import (
 // Data is lost when doing a json marshal.
 type Diagnostics hcl.Diagnostics
 
+func (d *Diagnostics) UnmarshalJSON(data []byte) error {
+	cpy := make([]FriendlyDiagnostic, 0)
+	if err := json.Unmarshal(data, &cpy); err != nil {
+		return err
+	}
+
+	*d = make(Diagnostics, 0, len(cpy))
+	for _, diag := range cpy {
+		severity := hcl.DiagError
+		if diag.Severity == DiagnosticSeverityWarning {
+			severity = hcl.DiagWarning
+		}
+
+		*d = append(*d, &hcl.Diagnostic{
+			Severity: severity,
+			Summary:  diag.Summary,
+			Detail:   diag.Detail,
+		})
+	}
+	return nil
+}
+
 func (d Diagnostics) MarshalJSON() ([]byte, error) {
 	cpy := make([]FriendlyDiagnostic, 0, len(d))
 	for _, diag := range d {
diff --git a/types/diagnostics_test.go b/types/diagnostics_test.go
new file mode 100644
index 0000000..82a4845
--- /dev/null
+++ b/types/diagnostics_test.go
@@ -0,0 +1,36 @@
+package types_test
+
+import (
+	"encoding/json"
+	"testing"
+
+	"github.com/hashicorp/hcl/v2"
+	"github.com/stretchr/testify/require"
+
+	"github.com/coder/preview/types"
+)
+
+func TestDiagnosticsJSON(t *testing.T) {
+
+	diags := types.Diagnostics{
+		{
+			Severity: hcl.DiagWarning,
+			Summary:  "Some summary",
+			Detail:   "Some detail",
+		},
+		{
+			Severity: hcl.DiagError,
+			Summary:  "Some summary",
+			Detail:   "Some detail",
+		},
+	}
+
+	data, err := json.Marshal(diags)
+	require.NoError(t, err, "marshal")
+
+	var newDiags types.Diagnostics
+	err = json.Unmarshal(data, &newDiags)
+	require.NoError(t, err, "unmarshal")
+
+	require.Equal(t, diags, newDiags)
+}

From 68672d2c31568957d9f2ce1db463262bd43f44d7 Mon Sep 17 00:00:00 2001
From: Steven Masley 
Date: Thu, 15 May 2025 12:29:18 -0500
Subject: [PATCH 28/61] improve template bug github issue template

---
 .../workspace-template-bug-report.md          | 66 -----------------
 .../workspace-template-bug-report.yaml        | 71 +++++++++++++++++++
 2 files changed, 71 insertions(+), 66 deletions(-)
 delete mode 100644 .github/ISSUE_TEMPLATE/workspace-template-bug-report.md
 create mode 100644 .github/ISSUE_TEMPLATE/workspace-template-bug-report.yaml

diff --git a/.github/ISSUE_TEMPLATE/workspace-template-bug-report.md b/.github/ISSUE_TEMPLATE/workspace-template-bug-report.md
deleted file mode 100644
index 5e15bc0..0000000
--- a/.github/ISSUE_TEMPLATE/workspace-template-bug-report.md
+++ /dev/null
@@ -1,66 +0,0 @@
----
-name: Workspace Template Bug Report
-about: Workspace template yielded incorrect parameters.
-title: "[BUG] Workspace template behavior"
-labels: bug
-assignees: Emyrk
-
----
-
-**Describe the bug**
-A clear and concise description of what the bug is. Was the parameter value/description/options/etc incorrect? Did you encounter an error you did not expect? Did you expect to encounter an error, and did not?
-
-**Expected behavior**
-A clear and concise description of what you expected to happen. What was the parameter supposed to look like?
-
-**Offending Template**
-Provide the most minimal workspace template that reproduces the bug. Try to remove any non-coder terraform blocks. Only `data "coder_parameter"` and `data "coder_workspace_tags"`  with any supporting or referenced blocks are required.
-
-If the template is a single `main.tf`, please include the `main.tf` in the collapsible section below. If there are multiple files, either attach the files, or create a public github repository with the directory structure. Try to avoid attaching zips or tarballs.
-
-
-
- -Template `main.tf` - -```terraform -# Replace this with your `main.tf` -terraform { - required_providers { - coder = { - source = "coder/coder" - version = "2.3.0" - } - } -} - -data "coder_parameter" "region" { - name = "region" - description = "Which region would you like to deploy to?" - type = "string" - default = "us" - order = 1 - - option { - name = "Europe" - value = "eu" - } - option { - name = "United States" - value = "us" - } -} -``` - -
- -**Screenshots** -If applicable, add screenshots to help explain your problem. - -**Tooling (please complete the following information):** - - Terraform Version: [e.g. v1.11.2] - - Coderd Version [e.g. chrome, v2.20.2] - - Coder Provider Version [e.g. 2.3.0, if not in the `main.tf`] - -**Additional context** -Add any other context about the problem here. diff --git a/.github/ISSUE_TEMPLATE/workspace-template-bug-report.yaml b/.github/ISSUE_TEMPLATE/workspace-template-bug-report.yaml new file mode 100644 index 0000000..c1a3a85 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/workspace-template-bug-report.yaml @@ -0,0 +1,71 @@ +name: "Workspace Template Bug Report" +description: "Workspace template yielded incorrect parameters." +title: "param-bug: " +labels: ["bug"] +assignees: + - Emyrk +body: + - type: textarea + id: issue + attributes: + label: "Describe the bug" + description: | + A clear and concise description of what the bug is. + Was the parameter value/description/options/etc incorrect? + Did you encounter an error you did not expect? + Did you expect to encounter an error, and did not? + placeholder: "A parameter that I expected is missing. The parameter is sourced from an external module." + validations: + required: true + + - type: textarea + id: template + attributes: + label: "Offending Template" + description: | + Provide the most minimal workspace template that reproduces the bug. + Try to remove any non-coder terraform blocks. + Only `data "coder_parameter"` and `data "coder_workspace_tags"` + with any supporting or referenced blocks are required. + + If the template is a single `main.tf`, please include the `main.tf` in the collapsible section below. + If there are multiple files, either attach the files, or create a public github repository with the directory structure. + Try to avoid attaching zips or tarballs. + value: | +
+ + Template `main.tf` + + ```terraform + # Replace this with your `main.tf` + terraform { + required_providers { + coder = { + source = "coder/coder" + version = "2.3.0" + } + } + } + ``` + +
+ validations: + required: true + + - type: textarea + id: screenshots + attributes: + label: "Screenshots" + description: | + If applicable, add screenshots to help explain your problem. + validations: + required: false + + - type: textarea + id: additional + attributes: + label: "Additional context" + description: | + Add any other context about the problem here. + validations: + required: false \ No newline at end of file From c23c379fbbe598201029bc1854c799c9544970c9 Mon Sep 17 00:00:00 2001 From: Steven Masley Date: Thu, 15 May 2025 13:05:18 -0500 Subject: [PATCH 29/61] feat: add extra diagnostic block for coder metadata Only `code` is present right now. --- types/diagnostics.go | 50 +++++++++++++++++++++++++++++++++++++-- types/diagnostics_test.go | 32 ++++++++++++++++++++++++- 2 files changed, 79 insertions(+), 3 deletions(-) diff --git a/types/diagnostics.go b/types/diagnostics.go index 3ae0955..22a86ce 100644 --- a/types/diagnostics.go +++ b/types/diagnostics.go @@ -6,6 +6,43 @@ import ( "github.com/hashicorp/hcl/v2" ) +type DiagnosticExtra struct { + Code string `json:"code"` + + // If there was a previous extra, store it here for unwrapping. + wrapped any +} + +var _ hcl.DiagnosticExtraUnwrapper = DiagnosticExtra{} + +func (e DiagnosticExtra) UnwrapDiagnosticExtra() interface{} { + return e.wrapped +} + +func ExtractDiagnosticExtra(diag *hcl.Diagnostic) DiagnosticExtra { + // Zero values for a missing extra field is fine. + extra, _ := hcl.DiagnosticExtra[DiagnosticExtra](diag) + return extra +} + +func SetDiagnosticExtra(diag *hcl.Diagnostic, extra DiagnosticExtra) { + existing, ok := hcl.DiagnosticExtra[DiagnosticExtra](diag) + if ok { + // If an existing extra is present, we will keep the underlying + // wrapped. This is not perfect, as any parents are lost. + // So try to avoid calling 'SetDiagnosticExtra' more than once. + extra.wrapped = existing.wrapped + diag.Extra = extra + return + } + + // Maintain any existing extra fields. + if diag.Extra != nil { + extra.wrapped = diag.Extra + } + diag.Extra = extra +} + // Diagnostics is a JSON friendly form of hcl.Diagnostics. // Data is lost when doing a json marshal. type Diagnostics hcl.Diagnostics @@ -23,11 +60,15 @@ func (d *Diagnostics) UnmarshalJSON(data []byte) error { severity = hcl.DiagWarning } - *d = append(*d, &hcl.Diagnostic{ + hclDiag := &hcl.Diagnostic{ Severity: severity, Summary: diag.Summary, Detail: diag.Detail, - }) + } + + SetDiagnosticExtra(hclDiag, diag.Extra) + + *d = append(*d, hclDiag) } return nil } @@ -40,10 +81,13 @@ func (d Diagnostics) MarshalJSON() ([]byte, error) { severity = DiagnosticSeverityWarning } + extra := ExtractDiagnosticExtra(diag) + cpy = append(cpy, FriendlyDiagnostic{ Severity: severity, Summary: diag.Summary, Detail: diag.Detail, + Extra: extra, }) } return json.Marshal(cpy) @@ -60,4 +104,6 @@ type FriendlyDiagnostic struct { Severity DiagnosticSeverityString `json:"severity"` Summary string `json:"summary"` Detail string `json:"detail"` + + Extra DiagnosticExtra `json:"extra"` } diff --git a/types/diagnostics_test.go b/types/diagnostics_test.go index 82a4845..305eb22 100644 --- a/types/diagnostics_test.go +++ b/types/diagnostics_test.go @@ -10,18 +10,48 @@ import ( "github.com/coder/preview/types" ) -func TestDiagnosticsJSON(t *testing.T) { +func TestDiagnosticExtra(t *testing.T) { + diag := &hcl.Diagnostic{ + Severity: hcl.DiagWarning, + Summary: "Some summary", + Detail: "Some detail", + } + + extra := types.ExtractDiagnosticExtra(diag) + require.Empty(t, extra.Code) + + // Set it + extra.Code = "foobar" + types.SetDiagnosticExtra(diag, extra) + + extra = types.ExtractDiagnosticExtra(diag) + require.Equal(t, "foobar", extra.Code) + // Set it again + extra.Code = "bazz" + types.SetDiagnosticExtra(diag, extra) + + extra = types.ExtractDiagnosticExtra(diag) + require.Equal(t, "bazz", extra.Code) +} + +func TestDiagnosticsJSON(t *testing.T) { diags := types.Diagnostics{ { Severity: hcl.DiagWarning, Summary: "Some summary", Detail: "Some detail", + Extra: types.DiagnosticExtra{ + Code: "foobar", + }, }, { Severity: hcl.DiagError, Summary: "Some summary", Detail: "Some detail", + Extra: types.DiagnosticExtra{ + Code: "", + }, }, } From af534146b858bd972d8475b99b613afd9e9f5444 Mon Sep 17 00:00:00 2001 From: Steven Masley Date: Thu, 15 May 2025 13:16:00 -0500 Subject: [PATCH 30/61] make gen --- site/src/types/preview.ts | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/site/src/types/preview.ts b/site/src/types/preview.ts index fd8fa38..419889b 100644 --- a/site/src/types/preview.ts +++ b/site/src/types/preview.ts @@ -1,5 +1,10 @@ // Code generated by 'guts'. DO NOT EDIT. +// From types/diagnostics.go +export interface DiagnosticExtra { + readonly code: string; +} + // From types/diagnostics.go export type DiagnosticSeverityString = "error" | "warning"; @@ -13,6 +18,7 @@ export interface FriendlyDiagnostic { readonly severity: DiagnosticSeverityString; readonly summary: string; readonly detail: string; + readonly extra: DiagnosticExtra; } // From types/value.go From 57148ba18741632b6f49a1527793b54f3642305d Mon Sep 17 00:00:00 2001 From: Steven Masley Date: Fri, 16 May 2025 11:23:54 -0500 Subject: [PATCH 31/61] add unit test for existing extra --- types/diagnostics.go | 11 +++++---- types/diagnostics_test.go | 49 +++++++++++++++++++++++++++++++++++++++ 2 files changed, 55 insertions(+), 5 deletions(-) diff --git a/types/diagnostics.go b/types/diagnostics.go index 22a86ce..3c54899 100644 --- a/types/diagnostics.go +++ b/types/diagnostics.go @@ -10,13 +10,13 @@ type DiagnosticExtra struct { Code string `json:"code"` // If there was a previous extra, store it here for unwrapping. - wrapped any + Wrapped any } var _ hcl.DiagnosticExtraUnwrapper = DiagnosticExtra{} func (e DiagnosticExtra) UnwrapDiagnosticExtra() interface{} { - return e.wrapped + return e.Wrapped } func ExtractDiagnosticExtra(diag *hcl.Diagnostic) DiagnosticExtra { @@ -29,16 +29,17 @@ func SetDiagnosticExtra(diag *hcl.Diagnostic, extra DiagnosticExtra) { existing, ok := hcl.DiagnosticExtra[DiagnosticExtra](diag) if ok { // If an existing extra is present, we will keep the underlying - // wrapped. This is not perfect, as any parents are lost. + // Wrapped. This is not perfect, as any parents are lost. // So try to avoid calling 'SetDiagnosticExtra' more than once. - extra.wrapped = existing.wrapped + // TODO: Fix this so we maintain the parents too. Maybe use a pointer? + extra.Wrapped = existing.Wrapped diag.Extra = extra return } // Maintain any existing extra fields. if diag.Extra != nil { - extra.wrapped = diag.Extra + extra.Wrapped = diag.Extra } diag.Extra = extra } diff --git a/types/diagnostics_test.go b/types/diagnostics_test.go index 305eb22..3bd8db6 100644 --- a/types/diagnostics_test.go +++ b/types/diagnostics_test.go @@ -35,6 +35,44 @@ func TestDiagnosticExtra(t *testing.T) { require.Equal(t, "bazz", extra.Code) } +// TestDiagnosticExtraExisting is a test case where the DiagnosticExtra +// is already set in the wrapped chain of diagnostics. +// The `parent` wrapped is lost here, so calling `SetDiagnosticExtra` is +// lossy. In practice, we only call this once, so it's ok. +// TODO: Fix SetDiagnosticExtra to maintain the parents +// if the DiagnosticExtra already exists in the chain. +func TestDiagnosticExtraExisting(t *testing.T) { + diag := &hcl.Diagnostic{ + Severity: hcl.DiagWarning, + Summary: "Some summary", + Detail: "Some detail", + // parent -> existing -> child + Extra: wrappedDiagnostic{ + name: "parent", + wrapped: types.DiagnosticExtra{ + Code: "foobar", + Wrapped: wrappedDiagnostic{ + name: "child", + wrapped: nil, + }, + }, + }, + } + + extra := types.DiagnosticExtra{ + Code: "foo", + } + types.SetDiagnosticExtra(diag, extra) + + // The parent wrapped is lost + isExtra, ok := diag.Extra.(types.DiagnosticExtra) + require.True(t, ok) + require.Equal(t, "foo", isExtra.Code) + wrapped, ok := isExtra.UnwrapDiagnosticExtra().(wrappedDiagnostic) + require.True(t, ok) + require.Equal(t, wrapped.name, "child") +} + func TestDiagnosticsJSON(t *testing.T) { diags := types.Diagnostics{ { @@ -64,3 +102,14 @@ func TestDiagnosticsJSON(t *testing.T) { require.Equal(t, diags, newDiags) } + +type wrappedDiagnostic struct { + name string + wrapped any +} + +var _ hcl.DiagnosticExtraUnwrapper = wrappedDiagnostic{} + +func (e wrappedDiagnostic) UnwrapDiagnosticExtra() interface{} { + return e.wrapped +} From bbcaee033c5003c8853098eb7633c73adf3fda0c Mon Sep 17 00:00:00 2001 From: Steven Masley Date: Fri, 16 May 2025 11:26:18 -0500 Subject: [PATCH 32/61] make gne --- site/src/types/preview.ts | 2 ++ 1 file changed, 2 insertions(+) diff --git a/site/src/types/preview.ts b/site/src/types/preview.ts index 419889b..d6726b9 100644 --- a/site/src/types/preview.ts +++ b/site/src/types/preview.ts @@ -3,6 +3,8 @@ // From types/diagnostics.go export interface DiagnosticExtra { readonly code: string; + // empty interface{} type, falling back to unknown + readonly Wrapped: unknown; } // From types/diagnostics.go From 4bd87bdd944af47a1c9dc035002019443907e542 Mon Sep 17 00:00:00 2001 From: Steven Masley Date: Fri, 16 May 2025 18:30:26 -0500 Subject: [PATCH 33/61] chore: fix panic on some string arguments --- extract/parameter.go | 16 +++++----------- hclext/asstring.go | 26 ++++++++++++++++++++++++++ types/value.go | 19 +++++-------------- 3 files changed, 36 insertions(+), 25 deletions(-) create mode 100644 hclext/asstring.go diff --git a/extract/parameter.go b/extract/parameter.go index 222807d..15f1a0f 100644 --- a/extract/parameter.go +++ b/extract/parameter.go @@ -370,13 +370,11 @@ func nullableString(block *terraform.Block, key string) *string { if attr == nil || attr.IsNil() { return nil } - val := attr.Value() - if val.Type() != cty.String { + + str, ok := hclext.AsString(attr.Value()) + if !ok { return nil } - - //nolint:gocritic // string type asserted - str := val.AsString() return &str } @@ -385,13 +383,9 @@ func optionalString(block *terraform.Block, key string) string { if attr == nil || attr.IsNil() { return "" } - val := attr.Value() - if !val.Type().Equals(cty.String) { - return "" - } - //nolint:gocritic // string type asserted - return val.AsString() + str, _ := hclext.AsString(attr.Value()) + return str } func required(block *terraform.Block, keys ...string) hcl.Diagnostics { diff --git a/hclext/asstring.go b/hclext/asstring.go new file mode 100644 index 0000000..2f231ff --- /dev/null +++ b/hclext/asstring.go @@ -0,0 +1,26 @@ +package hclext + +import "github.com/zclconf/go-cty/cty" + +func AsString(v cty.Value) (string, bool) { + if v.IsNull() || !v.IsKnown() { + return "", false + } + + switch { + case v.Type().Equals(cty.String): + //nolint:gocritic // string type asserted + return v.AsString(), true + case v.Type().Equals(cty.Number): + // TODO: Float vs Int? + return v.AsBigFloat().String(), true + case v.Type().Equals(cty.Bool): + if v.True() { + return "true", true + } + return "false", true + + } + + return "", false +} diff --git a/types/value.go b/types/value.go index e26087b..e3ef163 100644 --- a/types/value.go +++ b/types/value.go @@ -7,6 +7,8 @@ import ( "github.com/hashicorp/hcl/v2" "github.com/hashicorp/hcl/v2/hclsyntax" "github.com/zclconf/go-cty/cty" + + "github.com/coder/preview/hclext" ) const ( @@ -86,20 +88,9 @@ func NullString() HCLString { // calling this function. func (s HCLString) AsString() string { if s.Valid() && s.Value.IsKnown() { - switch { - case s.Value.Type().Equals(cty.String): - //nolint:gocritic // string type asserted - return s.Value.AsString() - case s.Value.Type().Equals(cty.Number): - // TODO: Float vs Int? - return s.Value.AsBigFloat().String() - case s.Value.Type().Equals(cty.Bool): - if s.Value.True() { - return "true" - } - return "false" - default: - // ?? What to do? + str, ok := hclext.AsString(s.Value) + if ok { + return str } } From 1a73b1594477b747a768e0f55dcf867cdaad5b72 Mon Sep 17 00:00:00 2001 From: Steven Masley Date: Sat, 17 May 2025 17:20:52 -0500 Subject: [PATCH 34/61] chore: remove 'error' as a required field in validation blocks --- extract/parameter.go | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/extract/parameter.go b/extract/parameter.go index 15f1a0f..bf66319 100644 --- a/extract/parameter.go +++ b/extract/parameter.go @@ -198,23 +198,18 @@ func ParameterUsageDiagnostics(p types.Parameter) hcl.Diagnostics { } func ParameterValidationFromBlock(block *terraform.Block) (types.ParameterValidation, hcl.Diagnostics) { - diags := required(block, "error") + diags := required(block) if diags.HasErrors() { return types.ParameterValidation{}, diags } - pErr, errDiag := requiredString(block, "error") - if errDiag != nil { - diags = diags.Append(errDiag) - } - if diags.HasErrors() { return types.ParameterValidation{}, diags } p := types.ParameterValidation{ Regex: nullableString(block, "regex"), - Error: pErr, + Error: optionalString(block, "error"), Min: nullableInteger(block, "min"), Max: nullableInteger(block, "max"), Monotonic: nullableString(block, "monotonic"), From 3ed0b3b6107b758a0533a3e185ec12a3a411b450 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 19 May 2025 07:35:38 +0000 Subject: [PATCH 35/61] chore(deps): bump github.com/coder/terraform-provider-coder/v2 Bumps [github.com/coder/terraform-provider-coder/v2](https://github.com/coder/terraform-provider-coder) from 2.4.0 to 2.4.2. - [Release notes](https://github.com/coder/terraform-provider-coder/releases) - [Changelog](https://github.com/coder/terraform-provider-coder/blob/main/.goreleaser.yml) - [Commits](https://github.com/coder/terraform-provider-coder/compare/v2.4.0...v2.4.2) --- updated-dependencies: - dependency-name: github.com/coder/terraform-provider-coder/v2 dependency-version: 2.4.2 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- go.mod | 2 +- go.sum | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/go.mod b/go.mod index 34f5855..7b142d1 100644 --- a/go.mod +++ b/go.mod @@ -7,7 +7,7 @@ require ( github.com/aquasecurity/trivy v0.58.2 github.com/coder/guts v1.3.0 github.com/coder/serpent v0.10.0 - github.com/coder/terraform-provider-coder/v2 v2.4.0 + github.com/coder/terraform-provider-coder/v2 v2.4.2 github.com/coder/websocket v1.8.13 github.com/go-chi/chi v4.1.2+incompatible github.com/hashicorp/go-cty v1.4.1-0.20200414143053-d3edf31b6320 diff --git a/go.sum b/go.sum index e3c5bf0..5700c45 100644 --- a/go.sum +++ b/go.sum @@ -718,8 +718,8 @@ github.com/coder/pretty v0.0.0-20230908205945-e89ba86370e0 h1:3A0ES21Ke+FxEM8CXx github.com/coder/pretty v0.0.0-20230908205945-e89ba86370e0/go.mod h1:5UuS2Ts+nTToAMeOjNlnHFkPahrtDkmpydBen/3wgZc= github.com/coder/serpent v0.10.0 h1:ofVk9FJXSek+SmL3yVE3GoArP83M+1tX+H7S4t8BSuM= github.com/coder/serpent v0.10.0/go.mod h1:cZFW6/fP+kE9nd/oRkEHJpG6sXCtQ+AX7WMMEHv0Y3Q= -github.com/coder/terraform-provider-coder/v2 v2.4.0 h1:uuFmF03IyahAZLXEukOdmvV9hGfUMJSESD8+G5wkTcM= -github.com/coder/terraform-provider-coder/v2 v2.4.0/go.mod h1:2kaBpn5k9ZWtgKq5k4JbkVZG9DzEqR4mJSmpdshcO+s= +github.com/coder/terraform-provider-coder/v2 v2.4.2 h1:41SJkgwgiA555kwQzGIQcNS3bCm12sVMUmBSa5zGr+A= +github.com/coder/terraform-provider-coder/v2 v2.4.2/go.mod h1:2kaBpn5k9ZWtgKq5k4JbkVZG9DzEqR4mJSmpdshcO+s= github.com/coder/websocket v1.8.13 h1:f3QZdXy7uGVz+4uCJy2nTZyM0yTBj8yANEHhqlXZ9FE= github.com/coder/websocket v1.8.13/go.mod h1:LNVeNrXQZfe5qhS9ALED3uA+l5pPqvwXg3CKoDBB2gs= github.com/containerd/log v0.1.0 h1:TCJt7ioM2cr/tfR8GPbGf9/VRAX8D2B4PjzCpfX540I= From a63139bab17ece7e080eacc302d1f8d0668f6f09 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 19 May 2025 13:48:32 +0000 Subject: [PATCH 36/61] chore(deps): bump github.com/coder/guts from 1.3.0 to 1.5.0 Bumps [github.com/coder/guts](https://github.com/coder/guts) from 1.3.0 to 1.5.0. - [Release notes](https://github.com/coder/guts/releases) - [Commits](https://github.com/coder/guts/compare/v1.3.0...v1.5.0) --- updated-dependencies: - dependency-name: github.com/coder/guts dependency-version: 1.5.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- go.mod | 16 ++++++++-------- go.sum | 32 ++++++++++++++++---------------- 2 files changed, 24 insertions(+), 24 deletions(-) diff --git a/go.mod b/go.mod index 7b142d1..86b68c0 100644 --- a/go.mod +++ b/go.mod @@ -5,7 +5,7 @@ go 1.24.2 require ( cdr.dev/slog v1.6.2-0.20240126064726-20367d4aede6 github.com/aquasecurity/trivy v0.58.2 - github.com/coder/guts v1.3.0 + github.com/coder/guts v1.5.0 github.com/coder/serpent v0.10.0 github.com/coder/terraform-provider-coder/v2 v2.4.2 github.com/coder/websocket v1.8.13 @@ -118,17 +118,17 @@ require ( go.opentelemetry.io/otel/sdk v1.34.0 // indirect go.opentelemetry.io/otel/sdk/metric v1.32.0 // indirect go.opentelemetry.io/otel/trace v1.34.0 // indirect - golang.org/x/crypto v0.36.0 // indirect + golang.org/x/crypto v0.38.0 // indirect golang.org/x/exp v0.0.0-20250106191152-7588d65b2ba8 // indirect golang.org/x/mod v0.24.0 // indirect - golang.org/x/net v0.38.0 // indirect + golang.org/x/net v0.40.0 // indirect golang.org/x/oauth2 v0.26.0 // indirect - golang.org/x/sync v0.12.0 // indirect - golang.org/x/sys v0.31.0 // indirect - golang.org/x/term v0.30.0 // indirect - golang.org/x/text v0.23.0 // indirect + golang.org/x/sync v0.14.0 // indirect + golang.org/x/sys v0.33.0 // indirect + golang.org/x/term v0.32.0 // indirect + golang.org/x/text v0.25.0 // indirect golang.org/x/time v0.10.0 // indirect - golang.org/x/tools v0.30.0 // indirect + golang.org/x/tools v0.33.0 // indirect google.golang.org/api v0.218.0 // indirect google.golang.org/appengine v1.6.8 // indirect google.golang.org/genproto v0.0.0-20241118233622-e639e219e697 // indirect diff --git a/go.sum b/go.sum index 5700c45..a967aea 100644 --- a/go.sum +++ b/go.sum @@ -712,8 +712,8 @@ github.com/cncf/xds/go v0.0.0-20230105202645-06c439db220b/go.mod h1:eXthEFrGJvWH github.com/cncf/xds/go v0.0.0-20230607035331-e9ce68804cb4/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= github.com/cncf/xds/go v0.0.0-20240905190251-b4127c9b8d78 h1:QVw89YDxXxEe+l8gU8ETbOasdwEV+avkR75ZzsVV9WI= github.com/cncf/xds/go v0.0.0-20240905190251-b4127c9b8d78/go.mod h1:W+zGtBO5Y1IgJhy4+A9GOqVhqLpfZi+vwmdNXUehLA8= -github.com/coder/guts v1.3.0 h1:Kz8LrodQCfz/R06JdCJqdxZDq0BVTTXYYQC/qY3N9fo= -github.com/coder/guts v1.3.0/go.mod h1:31NO4z6MVTOD4WaCLqE/hUAHGgNok9sRbuMc/LZFopI= +github.com/coder/guts v1.5.0 h1:a94apf7xMf5jDdg1bIHzncbRiTn3+BvBZgrFSDbUnyI= +github.com/coder/guts v1.5.0/go.mod h1:0Sbv5Kp83u1Nl7MIQiV2zmacJ3o02I341bkWkjWXSUQ= github.com/coder/pretty v0.0.0-20230908205945-e89ba86370e0 h1:3A0ES21Ke+FxEM8CXx9n47SZOKOpgSE1bbJzlE4qPVs= github.com/coder/pretty v0.0.0-20230908205945-e89ba86370e0/go.mod h1:5UuS2Ts+nTToAMeOjNlnHFkPahrtDkmpydBen/3wgZc= github.com/coder/serpent v0.10.0 h1:ofVk9FJXSek+SmL3yVE3GoArP83M+1tX+H7S4t8BSuM= @@ -1252,8 +1252,8 @@ golang.org/x/crypto v0.13.0/go.mod h1:y6Z2r+Rw4iayiXXAIxJIDAJ1zMW4yaTpebo8fPOliY golang.org/x/crypto v0.19.0/go.mod h1:Iy9bg/ha4yyC70EfRS8jz+B6ybOBKMaSxLj6P6oBDfU= golang.org/x/crypto v0.23.0/go.mod h1:CKFgDieR+mRhux2Lsu27y0fO304Db0wZe70UKqHu0v8= golang.org/x/crypto v0.32.0/go.mod h1:ZnnJkOaASj8g0AjIduWNlq2NRxL0PlBrbKVyZ6V/Ugc= -golang.org/x/crypto v0.36.0 h1:AnAEvhDddvBdpY+uR+MyHmuZzzNqXSe/GvuDeob5L34= -golang.org/x/crypto v0.36.0/go.mod h1:Y4J0ReaxCR1IMaabaSMugxJES1EpwhBHhv2bDHklZvc= +golang.org/x/crypto v0.38.0 h1:jt+WWG8IZlBnVbomuhg2Mdq0+BBQaHbtqHEFEigjUV8= +golang.org/x/crypto v0.38.0/go.mod h1:MvrbAqul58NNYPKnOra203SB9vpuZW0e+RRZV+Ggqjw= golang.org/x/exp v0.0.0-20180321215751-8460e604b9de/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/exp v0.0.0-20180807140117-3d87b88a115f/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= @@ -1381,8 +1381,8 @@ golang.org/x/net v0.15.0/go.mod h1:idbUs1IY1+zTqbi8yxTbhexhEEk5ur9LInksu6HrEpk= golang.org/x/net v0.21.0/go.mod h1:bIjVDfnllIU7BJ2DNgfnXvpSvtn8VRwhlsaeUTyUS44= golang.org/x/net v0.25.0/go.mod h1:JkAGAh7GEvH74S6FOH42FLoXpXbE/aqXSrIQjXgsiwM= golang.org/x/net v0.34.0/go.mod h1:di0qlW3YNM5oh6GqDGQr92MyTozJPmybPK4Ev/Gm31k= -golang.org/x/net v0.38.0 h1:vRMAPTMaeGqVhG5QyLJHqNDwecKTomGeqbnfZyKlBI8= -golang.org/x/net v0.38.0/go.mod h1:ivrbrMbzFq5J41QOQh0siUuly180yBYtLp+CKbEaFx8= +golang.org/x/net v0.40.0 h1:79Xs7wF06Gbdcg4kdCCIQArK11Z1hr5POQ6+fIYHNuY= +golang.org/x/net v0.40.0/go.mod h1:y0hY0exeL2Pku80/zKK7tpntoX23cqL3Oa6njdgRtds= golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U= golang.org/x/oauth2 v0.0.0-20190226205417-e64efc72b421/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= @@ -1434,8 +1434,8 @@ golang.org/x/sync v0.3.0/go.mod h1:FU7BRWz2tNW+3quACPkgCx/L+uEAv1htQ0V83Z9Rj+Y= golang.org/x/sync v0.6.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= golang.org/x/sync v0.7.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= golang.org/x/sync v0.10.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= -golang.org/x/sync v0.12.0 h1:MHc5BpPuC30uJk597Ri8TV3CNZcTLu6B6z4lJy+g6Jw= -golang.org/x/sync v0.12.0/go.mod h1:1dzgHSNfp02xaA81J2MS99Qcpr2w7fw1gpm99rleRqA= +golang.org/x/sync v0.14.0 h1:woo0S4Yywslg6hp4eUFjTVOyKt0RookbpAHG4c1HmhQ= +golang.org/x/sync v0.14.0/go.mod h1:1dzgHSNfp02xaA81J2MS99Qcpr2w7fw1gpm99rleRqA= golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190312061237-fead79001313/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -1520,8 +1520,8 @@ golang.org/x/sys v0.12.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.17.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/sys v0.20.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/sys v0.29.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= -golang.org/x/sys v0.31.0 h1:ioabZlmFYtWhL+TRYpcnNlLwhyxaM9kWTDEmfnprqik= -golang.org/x/sys v0.31.0/go.mod h1:BJP2sWEmIv4KK5OTEluFJCKSidICx8ciO85XgH3Ak8k= +golang.org/x/sys v0.33.0 h1:q3i8TbbEz+JRD9ywIRlyRAQbM0qF7hu24q3teo2hbuw= +golang.org/x/sys v0.33.0/go.mod h1:BJP2sWEmIv4KK5OTEluFJCKSidICx8ciO85XgH3Ak8k= golang.org/x/telemetry v0.0.0-20240228155512-f48c80bd79b2/go.mod h1:TeRTkGYfJXctD9OcfyVLyj2J3IxLnKwHJR8f4D8a3YE= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= @@ -1537,8 +1537,8 @@ golang.org/x/term v0.12.0/go.mod h1:owVbMEjm3cBLCHdkQu9b1opXd4ETQWc3BhuQGKgXgvU= golang.org/x/term v0.17.0/go.mod h1:lLRBjIVuehSbZlaOtGMbcMncT+aqLLLmKrsjNrUguwk= golang.org/x/term v0.20.0/go.mod h1:8UkIAJTvZgivsXaD6/pH6U9ecQzZ45awqEOzuCvwpFY= golang.org/x/term v0.28.0/go.mod h1:Sw/lC2IAUZ92udQNf3WodGtn4k/XoLyZoh8v/8uiwek= -golang.org/x/term v0.30.0 h1:PQ39fJZ+mfadBm0y5WlL4vlM7Sx1Hgf13sMIY2+QS9Y= -golang.org/x/term v0.30.0/go.mod h1:NYYFdzHoI5wRh/h5tDMdMqCqPJZEuNqVR5xJLd/n67g= +golang.org/x/term v0.32.0 h1:DR4lr0TjUs3epypdhTOkMmuF5CDFJ/8pOnbzMZPQ7bg= +golang.org/x/term v0.32.0/go.mod h1:uZG1FhGx848Sqfsq4/DlJr3xGGsYMu/L5GW4abiaEPQ= golang.org/x/text v0.0.0-20170915032832-14c0d48ead0c/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.1-0.20180807135948-17ff2d5776d2/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= @@ -1559,8 +1559,8 @@ golang.org/x/text v0.13.0/go.mod h1:TvPlkZtksWOMsz7fbANvkp4WM8x/WCo/om8BMLbz+aE= golang.org/x/text v0.14.0/go.mod h1:18ZOQIKpY8NJVqYksKHtTdi31H5itFRjB5/qKTNYzSU= golang.org/x/text v0.15.0/go.mod h1:18ZOQIKpY8NJVqYksKHtTdi31H5itFRjB5/qKTNYzSU= golang.org/x/text v0.21.0/go.mod h1:4IBbMaMmOPCJ8SecivzSH54+73PCFmPWxNTLm+vZkEQ= -golang.org/x/text v0.23.0 h1:D71I7dUrlY+VX0gQShAThNGHFxZ13dGLBHQLVl1mJlY= -golang.org/x/text v0.23.0/go.mod h1:/BLNzu4aZCJ1+kcD0DNRotWKage4q2rGVAg4o22unh4= +golang.org/x/text v0.25.0 h1:qVyWApTSYLk/drJRO5mDlNYskwQznZmkpV2c8q9zls4= +golang.org/x/text v0.25.0/go.mod h1:WEdwpYrmk1qmdHvhkSTNPm3app7v4rsT8F2UD6+VHIA= golang.org/x/time v0.0.0-20181108054448-85acf8d2951c/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20190308202827-9d24e82272b4/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20191024005414-555d28b269f0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= @@ -1632,8 +1632,8 @@ golang.org/x/tools v0.6.0/go.mod h1:Xwgl3UAJ/d3gWutnCtw505GrjyAbvKui8lOU390QaIU= golang.org/x/tools v0.7.0/go.mod h1:4pg6aUX35JBAogB10C9AtvVL+qowtN4pT3CGSQex14s= golang.org/x/tools v0.13.0/go.mod h1:HvlwmtVNQAhOuCjW7xxvovg8wbNq7LwfXh/k7wXUl58= golang.org/x/tools v0.21.1-0.20240508182429-e35e4ccd0d2d/go.mod h1:aiJjzUbINMkxbQROHiO6hDPo2LHcIPhhQsa9DLh0yGk= -golang.org/x/tools v0.30.0 h1:BgcpHewrV5AUp2G9MebG4XPFI1E2W41zU1SaqVA9vJY= -golang.org/x/tools v0.30.0/go.mod h1:c347cR/OJfw5TI+GfX7RUPNMdDRRbjvYTS0jPyvsVtY= +golang.org/x/tools v0.33.0 h1:4qz2S3zmRxbGIhDIAgjxvFutSvH5EfnsYrRBj0UI0bc= +golang.org/x/tools v0.33.0/go.mod h1:CIJMaWEY88juyUfo7UbgPqbC8rU2OqfAV1h2Qp0oMYI= golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= From c700d4ccb618a255e55445a4188f0184da9c97dc Mon Sep 17 00:00:00 2001 From: Steven Masley Date: Tue, 20 May 2025 07:26:22 -0500 Subject: [PATCH 37/61] deps: use trivy fork in coder organization --- go.mod | 10 ++++++---- go.sum | 36 ++++++++++++++++++------------------ testdata/dogfooddemo/skipe2e | 0 3 files changed, 24 insertions(+), 22 deletions(-) create mode 100644 testdata/dogfooddemo/skipe2e diff --git a/go.mod b/go.mod index 86b68c0..a63be13 100644 --- a/go.mod +++ b/go.mod @@ -113,11 +113,11 @@ require ( go.opentelemetry.io/contrib/detectors/gcp v1.32.0 // indirect go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.56.0 // indirect go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.59.0 // indirect - go.opentelemetry.io/otel v1.34.0 // indirect - go.opentelemetry.io/otel/metric v1.34.0 // indirect + go.opentelemetry.io/otel v1.35.0 // indirect + go.opentelemetry.io/otel/metric v1.35.0 // indirect go.opentelemetry.io/otel/sdk v1.34.0 // indirect go.opentelemetry.io/otel/sdk/metric v1.32.0 // indirect - go.opentelemetry.io/otel/trace v1.34.0 // indirect + go.opentelemetry.io/otel/trace v1.35.0 // indirect golang.org/x/crypto v0.38.0 // indirect golang.org/x/exp v0.0.0-20250106191152-7588d65b2ba8 // indirect golang.org/x/mod v0.24.0 // indirect @@ -140,4 +140,6 @@ require ( k8s.io/utils v0.0.0-20241104100929-3ea5e8cea738 // indirect ) -replace github.com/aquasecurity/trivy => github.com/emyrk/trivy v0.0.0-20250320190949-47caa1ac2d53 +// Trivy has some issues that we're floating patches for, and will hopefully +// be upstreamed eventually. +replace github.com/aquasecurity/trivy => github.com/coder/trivy v0.0.0-20250409153844-e6b004bc465a diff --git a/go.sum b/go.sum index a967aea..1688da1 100644 --- a/go.sum +++ b/go.sum @@ -720,6 +720,8 @@ github.com/coder/serpent v0.10.0 h1:ofVk9FJXSek+SmL3yVE3GoArP83M+1tX+H7S4t8BSuM= github.com/coder/serpent v0.10.0/go.mod h1:cZFW6/fP+kE9nd/oRkEHJpG6sXCtQ+AX7WMMEHv0Y3Q= github.com/coder/terraform-provider-coder/v2 v2.4.2 h1:41SJkgwgiA555kwQzGIQcNS3bCm12sVMUmBSa5zGr+A= github.com/coder/terraform-provider-coder/v2 v2.4.2/go.mod h1:2kaBpn5k9ZWtgKq5k4JbkVZG9DzEqR4mJSmpdshcO+s= +github.com/coder/trivy v0.0.0-20250409153844-e6b004bc465a h1:yryP7e+IQUAArlycH4hQrjXQ64eRNbxsV5/wuVXHgME= +github.com/coder/trivy v0.0.0-20250409153844-e6b004bc465a/go.mod h1:dDvq9axp3kZsT63gY2Znd1iwzfqDq3kXbQnccIrjRYY= github.com/coder/websocket v1.8.13 h1:f3QZdXy7uGVz+4uCJy2nTZyM0yTBj8yANEHhqlXZ9FE= github.com/coder/websocket v1.8.13/go.mod h1:LNVeNrXQZfe5qhS9ALED3uA+l5pPqvwXg3CKoDBB2gs= github.com/containerd/log v0.1.0 h1:TCJt7ioM2cr/tfR8GPbGf9/VRAX8D2B4PjzCpfX540I= @@ -739,8 +741,8 @@ github.com/distribution/reference v0.6.0 h1:0IXCQ5g4/QMHHkarYzh5l+u8T3t73zM5Qvfr github.com/distribution/reference v0.6.0/go.mod h1:BbU0aIcezP1/5jX/8MP0YiH4SdvB5Y4f/wlDRiLyi3E= github.com/dlclark/regexp2 v1.11.4 h1:rPYF9/LECdNymJufQKmri9gV604RvvABwgOA8un7yAo= github.com/dlclark/regexp2 v1.11.4/go.mod h1:DHkYz0B9wPfa6wondMfaivmHpzrQ3v9q8cnmRbL6yW8= -github.com/docker/docker v27.5.0+incompatible h1:um++2NcQtGRTz5eEgO6aJimo6/JxrTXC941hd05JO6U= -github.com/docker/docker v27.5.0+incompatible/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk= +github.com/docker/docker v28.0.4+incompatible h1:JNNkBctYKurkw6FrHfKqY0nKIDf5nrbxjVBtS+cdcok= +github.com/docker/docker v28.0.4+incompatible/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk= github.com/docker/go-connections v0.5.0 h1:USnMq7hx7gwdVZq1L49hLXaFtUdTADjXGp+uj1Br63c= github.com/docker/go-connections v0.5.0/go.mod h1:ov60Kzw0kKElRwhNs9UlUHAE/F9Fe6GLaXnqyDdmEXc= github.com/docker/go-units v0.5.0 h1:69rxXcBk27SvSaaxTtLh/8llcHD8vYHT7WSdRZ/jvr4= @@ -749,10 +751,10 @@ github.com/docopt/docopt-go v0.0.0-20180111231733-ee0de3bc6815/go.mod h1:WwZ+bS3 github.com/dop251/goja v0.0.0-20241024094426-79f3a7efcdbd h1:QMSNEh9uQkDjyPwu/J541GgSH+4hw+0skJDIj9HJ3mE= github.com/dop251/goja v0.0.0-20241024094426-79f3a7efcdbd/go.mod h1:MxLav0peU43GgvwVgNbLAj1s/bSGboKkhuULvq/7hx4= github.com/dustin/go-humanize v1.0.0/go.mod h1:HtrtbFcZ19U5GC7JDqmcUSB87Iq5E25KnS6fMYU6eOk= +github.com/ebitengine/purego v0.8.2 h1:jPPGWs2sZ1UgOSgD2bClL0MJIqu58nOmIcBuXr62z1I= +github.com/ebitengine/purego v0.8.2/go.mod h1:iIjxzd6CiRiOG0UyXP+V1+jWqUXVjPKLAI0mRfJZTmQ= github.com/emirpasic/gods v1.18.1 h1:FXtiHYKDGKCW2KzwZKx0iC0PQmdlorYgdFG9jPXJ1Bc= github.com/emirpasic/gods v1.18.1/go.mod h1:8tpGGwCnJ5H4r6BWwaV6OrWmMoPhUl5jm/FMNAnJvWQ= -github.com/emyrk/trivy v0.0.0-20250320190949-47caa1ac2d53 h1:0bj1/UEj/7ZwQSm2EAYuYd87feUvqmlrUfR3MRzKOag= -github.com/emyrk/trivy v0.0.0-20250320190949-47caa1ac2d53/go.mod h1:QqQijstmQF9wfPij09KE96MLfbFGtfC21dG299ty+Fc= github.com/envoyproxy/go-control-plane v0.9.0/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= github.com/envoyproxy/go-control-plane v0.9.1-0.20191026205805-5f8ba28d4473/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= github.com/envoyproxy/go-control-plane v0.9.4/go.mod h1:6rpuAdCZL397s3pYoYcLgu1mIlRU8Am5FuJP05cCM98= @@ -1139,10 +1141,8 @@ github.com/samber/lo v1.49.1 h1:4BIFyVfuQSEpluc7Fua+j1NolZHiEHEpaSEKdsH0tew= github.com/samber/lo v1.49.1/go.mod h1:dO6KHFzUKXgP8LDhU0oI8d2hekjXnGOu0DB8Jecxd6o= github.com/sergi/go-diff v1.3.2-0.20230802210424-5b0b94c5c0d3 h1:n661drycOFuPLCN3Uc8sB6B/s6Z4t2xvBgU1htSHuq8= github.com/sergi/go-diff v1.3.2-0.20230802210424-5b0b94c5c0d3/go.mod h1:A0bzQcvG0E7Rwjx0REVgAGH58e96+X0MeOfepqsbeW4= -github.com/shirou/gopsutil/v3 v3.24.2 h1:kcR0erMbLg5/3LcInpw0X/rrPSqq4CDPyI6A6ZRC18Y= -github.com/shirou/gopsutil/v3 v3.24.2/go.mod h1:tSg/594BcA+8UdQU2XcW803GWYgdtauFFPgJCJKZlVk= -github.com/shoenig/go-m1cpu v0.1.6 h1:nxdKQNcEB6vzgA2E2bvzKIYRuNj7XNJ4S/aRSwKzFtM= -github.com/shoenig/go-m1cpu v0.1.6/go.mod h1:1JJMcUBvfNwpq05QDQVAnx3gUHr9IYF7GNg9SUEw2VQ= +github.com/shirou/gopsutil/v4 v4.25.1 h1:QSWkTc+fu9LTAWfkZwZ6j8MSUk4A2LV7rbH0ZqmLjXs= +github.com/shirou/gopsutil/v4 v4.25.1/go.mod h1:RoUCUpndaJFtT+2zsZzzmhvbfGoDCJ7nFXKJf8GqJbI= github.com/sirupsen/logrus v1.9.3 h1:dueUQJ1C2q9oE3F7wvmSGAaVtTmUizReu6fjN8uqzbQ= github.com/sirupsen/logrus v1.9.3/go.mod h1:naHLuLoDiP4jHNo9R0sCBMtWGeIprob74mVsIT4qYEQ= github.com/skeema/knownhosts v1.3.1 h1:X2osQ+RAjK76shCbvhHHHVl3ZlgDm8apHEHFqRjnBY8= @@ -1170,10 +1170,10 @@ github.com/stretchr/testify v1.8.1/go.mod h1:w2LPCIKwWwSfY2zedu0+kehJoqGctiVI29o github.com/stretchr/testify v1.8.3/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo= github.com/stretchr/testify v1.10.0 h1:Xv5erBjTwe/5IxqUQTdXv5kgmIvbHo3QQyRwhJsOfJA= github.com/stretchr/testify v1.10.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY= -github.com/testcontainers/testcontainers-go v0.35.0 h1:uADsZpTKFAtp8SLK+hMwSaa+X+JiERHtd4sQAFmXeMo= -github.com/testcontainers/testcontainers-go v0.35.0/go.mod h1:oEVBj5zrfJTrgjwONs1SsRbnBtH9OKl+IGl3UMcr2B4= -github.com/testcontainers/testcontainers-go/modules/localstack v0.35.0 h1:0EbOXcy8XQkyDUs1Y9YPUHOUByNnlGsLi5B3ln8F/RU= -github.com/testcontainers/testcontainers-go/modules/localstack v0.35.0/go.mod h1:MlHuaWQimz+15dmQ6R2S1vpYxhGFEpmRZQsL2NVWNng= +github.com/testcontainers/testcontainers-go v0.36.0 h1:YpffyLuHtdp5EUsI5mT4sRw8GZhO/5ozyDT1xWGXt00= +github.com/testcontainers/testcontainers-go v0.36.0/go.mod h1:yk73GVJ0KUZIHUtFna6MO7QS144qYpoY8lEEtU9Hed0= +github.com/testcontainers/testcontainers-go/modules/localstack v0.36.0 h1:zVwbe46NYg2vtC26aF0ndClK5S9J7TgAliQbTLyHm+0= +github.com/testcontainers/testcontainers-go/modules/localstack v0.36.0/go.mod h1:rxyzj5nX/OUn7QK5PVxKYHJg1eeNtNzWMX2hSbNNJk0= github.com/tklauser/go-sysconf v0.3.13 h1:GBUpcahXSpR2xN01jhkNAbTLRk2Yzgggk8IM08lq3r4= github.com/tklauser/go-sysconf v0.3.13/go.mod h1:zwleP4Q4OehZHGn4CYZDipCgg9usW5IJePewFCGVEa0= github.com/tklauser/numcpus v0.7.0 h1:yjuerZP127QG9m5Zh/mSO4wqurYil27tHrqwRoRjpr4= @@ -1224,18 +1224,18 @@ go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.5 go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.56.0/go.mod h1:n8MR6/liuGB5EmTETUBeU5ZgqMOlqKRxUaqPQBOANZ8= go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.59.0 h1:CV7UdSGJt/Ao6Gp4CXckLxVRRsRgDHoI8XjbL3PDl8s= go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.59.0/go.mod h1:FRmFuRJfag1IZ2dPkHnEoSFVgTVPUd2qf5Vi69hLb8I= -go.opentelemetry.io/otel v1.34.0 h1:zRLXxLCgL1WyKsPVrgbSdMN4c0FMkDAskSTQP+0hdUY= -go.opentelemetry.io/otel v1.34.0/go.mod h1:OWFPOQ+h4G8xpyjgqo4SxJYdDQ/qmRH+wivy7zzx9oI= +go.opentelemetry.io/otel v1.35.0 h1:xKWKPxrxB6OtMCbmMY021CqC45J+3Onta9MqjhnusiQ= +go.opentelemetry.io/otel v1.35.0/go.mod h1:UEqy8Zp11hpkUrL73gSlELM0DupHoiq72dR+Zqel/+Y= go.opentelemetry.io/otel/exporters/stdout/stdoutmetric v1.29.0 h1:WDdP9acbMYjbKIyJUhTvtzj601sVJOqgWdUxSdR/Ysc= go.opentelemetry.io/otel/exporters/stdout/stdoutmetric v1.29.0/go.mod h1:BLbf7zbNIONBLPwvFnwNHGj4zge8uTCM/UPIVW1Mq2I= -go.opentelemetry.io/otel/metric v1.34.0 h1:+eTR3U0MyfWjRDhmFMxe2SsW64QrZ84AOhvqS7Y+PoQ= -go.opentelemetry.io/otel/metric v1.34.0/go.mod h1:CEDrp0fy2D0MvkXE+dPV7cMi8tWZwX3dmaIhwPOaqHE= +go.opentelemetry.io/otel/metric v1.35.0 h1:0znxYu2SNyuMSQT4Y9WDWej0VpcsxkuklLa4/siN90M= +go.opentelemetry.io/otel/metric v1.35.0/go.mod h1:nKVFgxBZ2fReX6IlyW28MgZojkoAkJGaE8CpgeAU3oE= go.opentelemetry.io/otel/sdk v1.34.0 h1:95zS4k/2GOy069d321O8jWgYsW3MzVV+KuSPKp7Wr1A= go.opentelemetry.io/otel/sdk v1.34.0/go.mod h1:0e/pNiaMAqaykJGKbi+tSjWfNNHMTxoC9qANsCzbyxU= go.opentelemetry.io/otel/sdk/metric v1.32.0 h1:rZvFnvmvawYb0alrYkjraqJq0Z4ZUJAiyYCU9snn1CU= go.opentelemetry.io/otel/sdk/metric v1.32.0/go.mod h1:PWeZlq0zt9YkYAp3gjKZ0eicRYvOh1Gd+X99x6GHpCQ= -go.opentelemetry.io/otel/trace v1.34.0 h1:+ouXS2V8Rd4hp4580a8q23bg0azF2nI8cqLYnC8mh/k= -go.opentelemetry.io/otel/trace v1.34.0/go.mod h1:Svm7lSjQD7kG7KJ/MUHPVXSDGz2OX4h0M2jHBhmSfRE= +go.opentelemetry.io/otel/trace v1.35.0 h1:dPpEfJu1sDIqruz7BHFG3c7528f6ddfSWfFDVt/xgMs= +go.opentelemetry.io/otel/trace v1.35.0/go.mod h1:WUk7DtFp1Aw2MkvqGdwiXYDZZNvA/1J8o6xRXLrIkyc= go.opentelemetry.io/proto/otlp v0.7.0/go.mod h1:PqfVotwruBrMGOCsRd/89rSnXhoiJIqeYNgFYFoEGnI= go.opentelemetry.io/proto/otlp v0.15.0/go.mod h1:H7XAot3MsfNsj7EXtrA2q5xSNQ10UqI405h3+duxN4U= go.opentelemetry.io/proto/otlp v0.19.0/go.mod h1:H7XAot3MsfNsj7EXtrA2q5xSNQ10UqI405h3+duxN4U= diff --git a/testdata/dogfooddemo/skipe2e b/testdata/dogfooddemo/skipe2e new file mode 100644 index 0000000..e69de29 From 3ab202239c82ab61b19c519f4a86002d6aae821b Mon Sep 17 00:00:00 2001 From: Steven Masley Date: Tue, 20 May 2025 08:36:05 -0500 Subject: [PATCH 38/61] chore: add converter methods to diagnostic and hclstring --- types/diagnostics.go | 38 +++++++++++++++++++++----------------- types/value.go | 10 +++++++--- 2 files changed, 28 insertions(+), 20 deletions(-) diff --git a/types/diagnostics.go b/types/diagnostics.go index 3c54899..8ce35da 100644 --- a/types/diagnostics.go +++ b/types/diagnostics.go @@ -48,6 +48,26 @@ func SetDiagnosticExtra(diag *hcl.Diagnostic, extra DiagnosticExtra) { // Data is lost when doing a json marshal. type Diagnostics hcl.Diagnostics +func (d Diagnostics) FriendlyDiagnostics() []FriendlyDiagnostic { + cpy := make([]FriendlyDiagnostic, 0, len(d)) + for _, diag := range d { + severity := DiagnosticSeverityError + if diag.Severity == hcl.DiagWarning { + severity = DiagnosticSeverityWarning + } + + extra := ExtractDiagnosticExtra(diag) + + cpy = append(cpy, FriendlyDiagnostic{ + Severity: severity, + Summary: diag.Summary, + Detail: diag.Detail, + Extra: extra, + }) + } + return cpy +} + func (d *Diagnostics) UnmarshalJSON(data []byte) error { cpy := make([]FriendlyDiagnostic, 0) if err := json.Unmarshal(data, &cpy); err != nil { @@ -75,23 +95,7 @@ func (d *Diagnostics) UnmarshalJSON(data []byte) error { } func (d Diagnostics) MarshalJSON() ([]byte, error) { - cpy := make([]FriendlyDiagnostic, 0, len(d)) - for _, diag := range d { - severity := DiagnosticSeverityError - if diag.Severity == hcl.DiagWarning { - severity = DiagnosticSeverityWarning - } - - extra := ExtractDiagnosticExtra(diag) - - cpy = append(cpy, FriendlyDiagnostic{ - Severity: severity, - Summary: diag.Summary, - Detail: diag.Detail, - Extra: extra, - }) - } - return json.Marshal(cpy) + return json.Marshal(d.FriendlyDiagnostics()) } type DiagnosticSeverityString string diff --git a/types/value.go b/types/value.go index e3ef163..3b5f9c4 100644 --- a/types/value.go +++ b/types/value.go @@ -46,11 +46,15 @@ func ToHCLString(block *terraform.Block, attr *terraform.Attribute) HCLString { } } -func (s HCLString) MarshalJSON() ([]byte, error) { - return json.Marshal(NullHCLString{ +func (s HCLString) NullHCLString() NullHCLString { + return NullHCLString{ Value: s.AsString(), Valid: s.Valid() && s.Value.IsKnown(), - }) + } +} + +func (s HCLString) MarshalJSON() ([]byte, error) { + return json.Marshal(s.NullHCLString()) } func (s *HCLString) UnmarshalJSON(data []byte) error { From 8aacfe600f664e59ac2e8c45925e656993193553 Mon Sep 17 00:00:00 2001 From: Steven Masley Date: Wed, 21 May 2025 12:19:14 -0500 Subject: [PATCH 39/61] chore: add error diagnostic to missing required parameters --- parameter.go | 8 +++++ preview.go | 4 +-- preview_test.go | 62 +++++++++++++++++++++++++++++++++++++-- testdata/required/main.tf | 25 ++++++++++++++++ types/diagnostics.go | 13 ++++++++ warnings.go | 2 +- 6 files changed, 109 insertions(+), 5 deletions(-) create mode 100644 testdata/required/main.tf diff --git a/parameter.go b/parameter.go index c5d691b..065b3d7 100644 --- a/parameter.go +++ b/parameter.go @@ -25,6 +25,14 @@ func parameters(modules terraform.Modules) ([]types.Parameter, hcl.Diagnostics) } if param != nil { + if param.Required && param.Value.Value.IsNull() { + param.Diagnostics = append(param.Diagnostics, types.DiagnosticCode(&hcl.Diagnostic{ + Severity: hcl.DiagError, + Summary: "Required parameter not provided", + Detail: "parameter value is null", + }, types.DiagnosticCodeRequired)) + } + params = append(params, *param) if _, ok := exists[param.Name]; !ok { diff --git a/preview.go b/preview.go index ed51211..51d980c 100644 --- a/preview.go +++ b/preview.go @@ -134,8 +134,8 @@ func Preview(ctx context.Context, input Input, dir fs.FS) (output *Output, diagn rp, rpDiags := parameters(modules) tags, tagDiags := workspaceTags(modules, p.Files()) - // Add warnings - diags = diags.Extend(warnings(modules)) + // Add parameterDiagnostics + diags = diags.Extend(parameterDiagnostics(modules)) return &Output{ ModuleOutput: outputs, diff --git a/preview_test.go b/preview_test.go index afa1531..f4224dc 100644 --- a/preview_test.go +++ b/preview_test.go @@ -7,6 +7,7 @@ import ( "path/filepath" "regexp" "slices" + "strings" "testing" "github.com/hashicorp/hcl/v2" @@ -144,7 +145,8 @@ func Test_Extract(t *testing.T) { unknownTags: []string{}, input: preview.Input{}, params: map[string]assertParam{ - "os": ap(). + "os": apWithDiags(). + errorDiagnostics("unique"). value("0000000000000000000000000000000000000000000000000000000000000000"), }, }, @@ -222,7 +224,18 @@ func Test_Extract(t *testing.T) { input: preview.Input{}, unknownTags: []string{}, params: map[string]assertParam{ - "word": ap(), + "word": apWithDiags(). + errorDiagnostics("Required"), + }, + }, + { + name: "required", + dir: "required", + expTags: map[string]string{}, + input: preview.Input{}, + unknownTags: []string{}, + params: map[string]assertParam{ + "region": apWithDiags().errorDiagnostics("Required"), }, }, { @@ -487,9 +500,53 @@ func Test_Extract(t *testing.T) { type assertParam func(t *testing.T, parameter types.Parameter) func ap() assertParam { + return func(t *testing.T, parameter types.Parameter) { + t.Helper() + assert.Empty(t, parameter.Diagnostics, "parameter should have no diagnostics") + } +} + +func apWithDiags() assertParam { return func(t *testing.T, parameter types.Parameter) {} } +func (a assertParam) errorDiagnostics(patterns ...string) assertParam { + return a.diagnostics(hcl.DiagError, patterns...) +} + +func (a assertParam) warnDiagnostics(patterns ...string) assertParam { + return a.diagnostics(hcl.DiagWarning, patterns...) +} + +func (a assertParam) diagnostics(sev hcl.DiagnosticSeverity, patterns ...string) assertParam { + shadow := patterns + return a.extend(func(t *testing.T, parameter types.Parameter) { + checks := make([]string, len(shadow)) + copy(checks, shadow) + + DiagLoop: + for _, diag := range parameter.Diagnostics { + if diag.Severity != sev { + continue + } + for i, pat := range checks { + if strings.Contains(diag.Summary, pat) || strings.Contains(diag.Detail, pat) { + checks = append(checks[:i], checks[i+1:]...) + break DiagLoop + } + } + } + + assert.Equal(t, []string{}, checks, "missing expected diagnostic errors") + }) +} + +func (a assertParam) noDiagnostics() assertParam { + return a.extend(func(t *testing.T, parameter types.Parameter) { + assert.Empty(t, parameter.Diagnostics, "parameter should have no diagnostics") + }) +} + func (a assertParam) formType(exp provider.ParameterFormType) assertParam { return a.extend(func(t *testing.T, parameter types.Parameter) { assert.Equal(t, exp, parameter.FormType, "parameter form type equality check") @@ -555,6 +612,7 @@ func (a assertParam) extend(f assertParam) assertParam { } return func(t *testing.T, parameter types.Parameter) { + t.Helper() (a)(t, parameter) f(t, parameter) } diff --git a/testdata/required/main.tf b/testdata/required/main.tf new file mode 100644 index 0000000..1008d35 --- /dev/null +++ b/testdata/required/main.tf @@ -0,0 +1,25 @@ +// Base case for workspace tags + parameters. +terraform { + required_providers { + coder = { + source = "coder/coder" + version = "2.4.0-pre0" + } + } +} + +data "coder_parameter" "region" { + name = "region" + description = "Which region would you like to deploy to?" + type = "string" + order = 1 + + option { + name = "Europe" + value = "eu" + } + option { + name = "United States" + value = "us" + } +} \ No newline at end of file diff --git a/types/diagnostics.go b/types/diagnostics.go index 8ce35da..1884726 100644 --- a/types/diagnostics.go +++ b/types/diagnostics.go @@ -6,6 +6,12 @@ import ( "github.com/hashicorp/hcl/v2" ) +const ( + // DiagnosticCodeRequired is used when a parameter value is `null`, but + // the parameter is required. + DiagnosticCodeRequired = "required" +) + type DiagnosticExtra struct { Code string `json:"code"` @@ -19,6 +25,13 @@ func (e DiagnosticExtra) UnwrapDiagnosticExtra() interface{} { return e.Wrapped } +func DiagnosticCode(diag *hcl.Diagnostic, code string) *hcl.Diagnostic { + SetDiagnosticExtra(diag, DiagnosticExtra{ + Code: code, + }) + return diag +} + func ExtractDiagnosticExtra(diag *hcl.Diagnostic) DiagnosticExtra { // Zero values for a missing extra field is fine. extra, _ := hcl.DiagnosticExtra[DiagnosticExtra](diag) diff --git a/warnings.go b/warnings.go index 781f49a..6af5e07 100644 --- a/warnings.go +++ b/warnings.go @@ -8,7 +8,7 @@ import ( "github.com/hashicorp/hcl/v2" ) -func warnings(modules terraform.Modules) hcl.Diagnostics { +func parameterDiagnostics(modules terraform.Modules) hcl.Diagnostics { var diags hcl.Diagnostics diags = diags.Extend(unexpandedCountBlocks(modules)) diags = diags.Extend(unresolvedModules(modules)) From 093cc7365bacfbaacdb9659ea4834cf002346334 Mon Sep 17 00:00:00 2001 From: Steven Masley Date: Wed, 21 May 2025 12:25:26 -0500 Subject: [PATCH 40/61] gen --- site/src/types/preview.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/site/src/types/preview.ts b/site/src/types/preview.ts index d6726b9..4aeb2d6 100644 --- a/site/src/types/preview.ts +++ b/site/src/types/preview.ts @@ -1,5 +1,8 @@ // Code generated by 'guts'. DO NOT EDIT. +// From types/diagnostics.go +export const DiagnosticCodeRequired = "required"; + // From types/diagnostics.go export interface DiagnosticExtra { readonly code: string; From 4959bc129e0342e5a798590e231ebf2834a24ede Mon Sep 17 00:00:00 2001 From: Steven Masley Date: Wed, 21 May 2025 12:26:01 -0500 Subject: [PATCH 41/61] add skip --- testdata/required/skipe2e | 1 + 1 file changed, 1 insertion(+) create mode 100644 testdata/required/skipe2e diff --git a/testdata/required/skipe2e b/testdata/required/skipe2e new file mode 100644 index 0000000..f84e0bf --- /dev/null +++ b/testdata/required/skipe2e @@ -0,0 +1 @@ +missing param value \ No newline at end of file From f5939ebfdcf110a4e15464098c29e6d4015015a4 Mon Sep 17 00:00:00 2001 From: Steven Masley Date: Wed, 21 May 2025 12:59:43 -0500 Subject: [PATCH 42/61] revert warnings name --- preview.go | 4 ++-- warnings.go | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/preview.go b/preview.go index 51d980c..ed51211 100644 --- a/preview.go +++ b/preview.go @@ -134,8 +134,8 @@ func Preview(ctx context.Context, input Input, dir fs.FS) (output *Output, diagn rp, rpDiags := parameters(modules) tags, tagDiags := workspaceTags(modules, p.Files()) - // Add parameterDiagnostics - diags = diags.Extend(parameterDiagnostics(modules)) + // Add warnings + diags = diags.Extend(warnings(modules)) return &Output{ ModuleOutput: outputs, diff --git a/warnings.go b/warnings.go index 6af5e07..781f49a 100644 --- a/warnings.go +++ b/warnings.go @@ -8,7 +8,7 @@ import ( "github.com/hashicorp/hcl/v2" ) -func parameterDiagnostics(modules terraform.Modules) hcl.Diagnostics { +func warnings(modules terraform.Modules) hcl.Diagnostics { var diags hcl.Diagnostics diags = diags.Extend(unexpandedCountBlocks(modules)) diags = diags.Extend(unresolvedModules(modules)) From e6a60ffa74f2a25a2659991784f2183fbce46bef Mon Sep 17 00:00:00 2001 From: Steven Masley Date: Wed, 21 May 2025 16:21:14 -0500 Subject: [PATCH 43/61] chore: loading plan.json with string indexs (for_each) (#132) When loading in values from a `plan.json`, loading `maps` and `lists` have to be merged with an existing hcl context. --- plan.go | 13 + preview_test.go | 24 + testdata/plan_stringindex/ides.auto.tfvars | 1 + testdata/plan_stringindex/main.tf | 236 ++++++++++ testdata/plan_stringindex/plan.json | 490 +++++++++++++++++++++ 5 files changed, 764 insertions(+) create mode 100644 testdata/plan_stringindex/ides.auto.tfvars create mode 100644 testdata/plan_stringindex/main.tf create mode 100644 testdata/plan_stringindex/plan.json diff --git a/plan.go b/plan.go index 2714bc8..de2b67c 100644 --- a/plan.go +++ b/plan.go @@ -143,6 +143,19 @@ func loadResourcesToContext(ctx *tfcontext.Context, resources []*tfjson.StateRes continue } merged = hclext.MergeWithTupleElement(existing, int(asInt), val) + case string: + keyStr, ok := resource.Index.(string) + if !ok { + return fmt.Errorf("unable to convert index '%v' for %q to a string", resource.Name, resource.Index) + } + + if !existing.CanIterateElements() { + continue + } + + instances := existing.AsValueMap() + instances[keyStr] = val + merged = cty.ObjectVal(instances) case nil: merged = hclext.MergeObjects(existing, val) default: diff --git a/preview_test.go b/preview_test.go index f4224dc..ec7ec6a 100644 --- a/preview_test.go +++ b/preview_test.go @@ -443,6 +443,20 @@ func Test_Extract(t *testing.T) { unknownTags: []string{}, params: map[string]assertParam{}, }, + { + name: "plan_stringindex", + dir: "plan_stringindex", + expTags: map[string]string{}, + input: preview.Input{ + PlanJSONPath: "plan.json", + }, + unknownTags: []string{}, + params: map[string]assertParam{ + "jetbrains_ide": ap(). + optVals("GO", "IU", "PY"). + optNames("GoLand 2024.3", "IntelliJ IDEA Ultimate 2024.3", "PyCharm Professional 2024.3"), + }, + }, } { t.Run(tc.name, func(t *testing.T) { t.Parallel() @@ -588,6 +602,16 @@ func (a assertParam) def(str string) assertParam { }) } +func (a assertParam) optNames(opts ...string) assertParam { + return a.extend(func(t *testing.T, parameter types.Parameter) { + var values []string + for _, opt := range parameter.Options { + values = append(values, opt.Name) + } + assert.ElementsMatch(t, opts, values, "parameter option names equality check") + }) +} + func (a assertParam) optVals(opts ...string) assertParam { return a.extend(func(t *testing.T, parameter types.Parameter) { var values []string diff --git a/testdata/plan_stringindex/ides.auto.tfvars b/testdata/plan_stringindex/ides.auto.tfvars new file mode 100644 index 0000000..b4d0d28 --- /dev/null +++ b/testdata/plan_stringindex/ides.auto.tfvars @@ -0,0 +1 @@ +jetbrains_ides = ["GO", "IU", "PY"] \ No newline at end of file diff --git a/testdata/plan_stringindex/main.tf b/testdata/plan_stringindex/main.tf new file mode 100644 index 0000000..3ab6d21 --- /dev/null +++ b/testdata/plan_stringindex/main.tf @@ -0,0 +1,236 @@ +terraform { + required_providers { + coder = { + source = "coder/coder" + } + docker = { + source = "kreuzwerker/docker" + version = "~> 3.0.0" + } + envbuilder = { + source = "coder/envbuilder" + } + } +} + +variable "jetbrains_ides" { + type = list(string) + description = "The list of IDE product codes." + default = ["IU", "PS", "WS", "PY", "CL", "GO", "RM", "RD", "RR"] + validation { + condition = ( + alltrue([ + for code in var.jetbrains_ides : contains(["IU", "PS", "WS", "PY", "CL", "GO", "RM", "RD", "RR"], code) + ]) + ) + error_message = "The jetbrains_ides must be a list of valid product codes. Valid product codes are ${join(",", ["IU", "PS", "WS", "PY", "CL", "GO", "RM", "RD", "RR"])}." + } + # check if the list is empty + validation { + condition = length(var.jetbrains_ides) > 0 + error_message = "The jetbrains_ides must not be empty." + } + # check if the list contains duplicates + validation { + condition = length(var.jetbrains_ides) == length(toset(var.jetbrains_ides)) + error_message = "The jetbrains_ides must not contain duplicates." + } +} + +variable "releases_base_link" { + type = string + description = "" + default = "https://data.services.jetbrains.com" + validation { + condition = can(regex("^https?://.+$", var.releases_base_link)) + error_message = "The releases_base_link must be a valid HTTP/S address." + } +} + +variable "channel" { + type = string + description = "JetBrains IDE release channel. Valid values are release and eap." + default = "release" + validation { + condition = can(regex("^(release|eap)$", var.channel)) + error_message = "The channel must be either release or eap." + } +} + + +data "http" "jetbrains_ide_versions" { + for_each = toset(var.jetbrains_ides) + url = "${var.releases_base_link}/products/releases?code=${each.key}&latest=true&type=${var.channel}" +} + +variable "download_base_link" { + type = string + description = "" + default = "https://download.jetbrains.com" + validation { + condition = can(regex("^https?://.+$", var.download_base_link)) + error_message = "The download_base_link must be a valid HTTP/S address." + } +} + +variable "arch" { + type = string + description = "The target architecture of the workspace" + default = "amd64" + validation { + condition = contains(["amd64", "arm64"], var.arch) + error_message = "Architecture must be either 'amd64' or 'arm64'." + } +} + +variable "jetbrains_ide_versions" { + type = map(object({ + build_number = string + version = string + })) + description = "The set of versions for each jetbrains IDE" + default = { + "IU" = { + build_number = "243.21565.193" + version = "2024.3" + } + "PS" = { + build_number = "243.21565.202" + version = "2024.3" + } + "WS" = { + build_number = "243.21565.180" + version = "2024.3" + } + "PY" = { + build_number = "243.21565.199" + version = "2024.3" + } + "CL" = { + build_number = "243.21565.238" + version = "2024.1" + } + "GO" = { + build_number = "243.21565.208" + version = "2024.3" + } + "RM" = { + build_number = "243.21565.197" + version = "2024.3" + } + "RD" = { + build_number = "243.21565.191" + version = "2024.3" + } + "RR" = { + build_number = "243.22562.230" + version = "2024.3" + } + } + validation { + condition = ( + alltrue([ + for code in keys(var.jetbrains_ide_versions) : contains(["IU", "PS", "WS", "PY", "CL", "GO", "RM", "RD", "RR"], code) + ]) + ) + error_message = "The jetbrains_ide_versions must contain a map of valid product codes. Valid product codes are ${join(",", ["IU", "PS", "WS", "PY", "CL", "GO", "RM", "RD", "RR"])}." + } +} + +locals { + # AMD64 versions of the images just use the version string, while ARM64 + # versions append "-aarch64". Eg: + # + # https://download.jetbrains.com/idea/ideaIU-2025.1.tar.gz + # https://download.jetbrains.com/idea/ideaIU-2025.1.tar.gz + # + # We rewrite the data map above dynamically based on the user's architecture parameter. + # + effective_jetbrains_ide_versions = { + for k, v in var.jetbrains_ide_versions : k => { + build_number = v.build_number + version = var.arch == "arm64" ? "${v.version}-aarch64" : v.version + } + } + + # When downloading the latest IDE, the download link in the JSON is either: + # + # linux.download_link + # linuxARM64.download_link + # + download_key = var.arch == "arm64" ? "linuxARM64" : "linux" + + jetbrains_ides = { + "GO" = { + icon = "/icon/goland.svg", + name = "GoLand", + identifier = "GO", + version = local.effective_jetbrains_ide_versions["GO"].version + }, + "WS" = { + icon = "/icon/webstorm.svg", + name = "WebStorm", + identifier = "WS", + version = local.effective_jetbrains_ide_versions["WS"].version + }, + "IU" = { + icon = "/icon/intellij.svg", + name = "IntelliJ IDEA Ultimate", + identifier = "IU", + version = local.effective_jetbrains_ide_versions["IU"].version + }, + "PY" = { + icon = "/icon/pycharm.svg", + name = "PyCharm Professional", + identifier = "PY", + version = local.effective_jetbrains_ide_versions["PY"].version + }, + "CL" = { + icon = "/icon/clion.svg", + name = "CLion", + identifier = "CL", + version = local.effective_jetbrains_ide_versions["CL"].version + }, + "PS" = { + icon = "/icon/phpstorm.svg", + name = "PhpStorm", + identifier = "PS", + version = local.effective_jetbrains_ide_versions["PS"].version + }, + "RM" = { + icon = "/icon/rubymine.svg", + name = "RubyMine", + identifier = "RM", + version = local.effective_jetbrains_ide_versions["RM"].version + }, + "RD" = { + icon = "/icon/rider.svg", + name = "Rider", + identifier = "RD", + version = local.effective_jetbrains_ide_versions["RD"].version + }, + "RR" = { + icon = "/icon/rustrover.svg", + name = "RustRover", + identifier = "RR", + version = local.effective_jetbrains_ide_versions["RR"].version + } + } +} +data "coder_parameter" "jetbrains_ide" { + type = "string" + name = "jetbrains_ide" + display_name = "JetBrains IDE" + icon = "/icon/gateway.svg" + mutable = true + default = var.jetbrains_ides[0] + + dynamic "option" { + for_each = var.jetbrains_ides + content { + icon = local.jetbrains_ides[option.value].icon + name = "${local.jetbrains_ides[option.value].name} ${local.jetbrains_ides[option.value].version}" + value = option.value + } + } +} diff --git a/testdata/plan_stringindex/plan.json b/testdata/plan_stringindex/plan.json new file mode 100644 index 0000000..68811eb --- /dev/null +++ b/testdata/plan_stringindex/plan.json @@ -0,0 +1,490 @@ +{ + "format_version": "1.2", + "terraform_version": "1.11.0-dev", + "variables": { + "arch": { + "value": "amd64" + }, + "channel": { + "value": "release" + }, + "download_base_link": { + "value": "https://download.jetbrains.com" + }, + "jetbrains_ide_versions": { + "value": { + "CL": { + "build_number": "243.21565.238", + "version": "2024.1" + }, + "GO": { + "build_number": "243.21565.208", + "version": "2024.3" + }, + "IU": { + "build_number": "243.21565.193", + "version": "2024.3" + }, + "PS": { + "build_number": "243.21565.202", + "version": "2024.3" + }, + "PY": { + "build_number": "243.21565.199", + "version": "2024.3" + }, + "RD": { + "build_number": "243.21565.191", + "version": "2024.3" + }, + "RM": { + "build_number": "243.21565.197", + "version": "2024.3" + }, + "RR": { + "build_number": "243.22562.230", + "version": "2024.3" + }, + "WS": { + "build_number": "243.21565.180", + "version": "2024.3" + } + } + }, + "jetbrains_ides": { + "value": [ + "GO", + "IU", + "PY" + ] + }, + "releases_base_link": { + "value": "https://data.services.jetbrains.com" + } + }, + "planned_values": { + "root_module": {} + }, + "prior_state": { + "format_version": "1.0", + "terraform_version": "1.11.0", + "values": { + "root_module": { + "resources": [ + { + "address": "data.coder_parameter.jetbrains_ide", + "mode": "data", + "type": "coder_parameter", + "name": "jetbrains_ide", + "provider_name": "registry.terraform.io/coder/coder", + "schema_version": 0, + "values": { + "default": "GO", + "description": null, + "display_name": "JetBrains IDE", + "ephemeral": false, + "form_type": "radio", + "icon": "/icon/gateway.svg", + "id": "84be2d03-2557-4923-9e4f-3ed26450e115", + "mutable": true, + "name": "jetbrains_ide", + "option": [ + { + "description": "", + "icon": "/icon/goland.svg", + "name": "GoLand 2024.3", + "value": "GO" + }, + { + "description": "", + "icon": "/icon/intellij.svg", + "name": "IntelliJ IDEA Ultimate 2024.3", + "value": "IU" + }, + { + "description": "", + "icon": "/icon/pycharm.svg", + "name": "PyCharm Professional 2024.3", + "value": "PY" + } + ], + "optional": true, + "order": null, + "styling": "{}", + "type": "string", + "validation": [], + "value": "GO" + }, + "sensitive_values": { + "option": [ + {}, + {}, + {} + ], + "validation": [] + } + }, + { + "address": "data.http.jetbrains_ide_versions[\"GO\"]", + "mode": "data", + "type": "http", + "name": "jetbrains_ide_versions", + "index": "GO", + "provider_name": "registry.terraform.io/hashicorp/http", + "schema_version": 0, + "values": { + "body": "{\"GO\":[{\"date\":\"2025-05-12\",\"type\":\"release\",\"downloads\":{\"linuxARM64\":{\"link\":\"https://download.jetbrains.com/go/goland-2025.1.1-aarch64.tar.gz\",\"size\":1118167582,\"checksumLink\":\"https://download.jetbrains.com/go/goland-2025.1.1-aarch64.tar.gz.sha256\"},\"linux\":{\"link\":\"https://download.jetbrains.com/go/goland-2025.1.1.tar.gz\",\"size\":1120783192,\"checksumLink\":\"https://download.jetbrains.com/go/goland-2025.1.1.tar.gz.sha256\"},\"thirdPartyLibrariesJson\":{\"link\":\"https://resources.jetbrains.com/storage/third-party-libraries/go/goland-2025.1.1-third-party-libraries.json\",\"size\":61075,\"checksumLink\":\"https://resources.jetbrains.com/storage/third-party-libraries/go/goland-2025.1.1-third-party-libraries.json.sha256\"},\"windows\":{\"link\":\"https://download.jetbrains.com/go/goland-2025.1.1.exe\",\"size\":832016440,\"checksumLink\":\"https://download.jetbrains.com/go/goland-2025.1.1.exe.sha256\"},\"windowsZip\":{\"link\":\"https://download.jetbrains.com/go/goland-2025.1.1.win.zip\",\"size\":1132949747,\"checksumLink\":\"https://download.jetbrains.com/go/goland-2025.1.1.win.zip.sha256\"},\"windowsARM64\":{\"link\":\"https://download.jetbrains.com/go/goland-2025.1.1-aarch64.exe\",\"size\":794419312,\"checksumLink\":\"https://download.jetbrains.com/go/goland-2025.1.1-aarch64.exe.sha256\"},\"mac\":{\"link\":\"https://download.jetbrains.com/go/goland-2025.1.1.dmg\",\"size\":1073091958,\"checksumLink\":\"https://download.jetbrains.com/go/goland-2025.1.1.dmg.sha256\"},\"macM1\":{\"link\":\"https://download.jetbrains.com/go/goland-2025.1.1-aarch64.dmg\",\"size\":1062258831,\"checksumLink\":\"https://download.jetbrains.com/go/goland-2025.1.1-aarch64.dmg.sha256\"}},\"patches\":{\"win\":[{\"fromBuild\":\"243.26053.20\",\"link\":\"https://download.jetbrains.com/go/GO-243.26053.20-251.25410.140-patch-win.jar\",\"size\":347470625,\"checksumLink\":\"https://download.jetbrains.com/go/GO-243.26053.20-251.25410.140-patch-win.jar.sha256\"},{\"fromBuild\":\"251.23774.430\",\"link\":\"https://download.jetbrains.com/go/GO-251.23774.430-251.25410.140-patch-win.jar\",\"size\":113977718,\"checksumLink\":\"https://download.jetbrains.com/go/GO-251.23774.430-251.25410.140-patch-win.jar.sha256\"}],\"mac\":[{\"fromBuild\":\"243.26053.20\",\"link\":\"https://download.jetbrains.com/go/GO-243.26053.20-251.25410.140-patch-mac.jar\",\"size\":349019823,\"checksumLink\":\"https://download.jetbrains.com/go/GO-243.26053.20-251.25410.140-patch-mac.jar.sha256\"},{\"fromBuild\":\"251.23774.430\",\"link\":\"https://download.jetbrains.com/go/GO-251.23774.430-251.25410.140-patch-mac.jar\",\"size\":112340817,\"checksumLink\":\"https://download.jetbrains.com/go/GO-251.23774.430-251.25410.140-patch-mac.jar.sha256\"}],\"unix\":[{\"fromBuild\":\"243.26053.20\",\"link\":\"https://download.jetbrains.com/go/GO-243.26053.20-251.25410.140-patch-unix.jar\",\"size\":353528662,\"checksumLink\":\"https://download.jetbrains.com/go/GO-243.26053.20-251.25410.140-patch-unix.jar.sha256\"},{\"fromBuild\":\"251.23774.430\",\"link\":\"https://download.jetbrains.com/go/GO-251.23774.430-251.25410.140-patch-unix.jar\",\"size\":112385699,\"checksumLink\":\"https://download.jetbrains.com/go/GO-251.23774.430-251.25410.140-patch-unix.jar.sha256\"}]},\"notesLink\":\"https://youtrack.jetbrains.com/articles/GO-A-231735963\",\"licenseRequired\":true,\"version\":\"2025.1.1\",\"majorVersion\":\"2025.1\",\"build\":\"251.25410.140\",\"whatsnew\":\"\u003ch3\u003eGoLand 2025.1.1 is now available!\u003c/h3\u003e\\n\u003cp\u003eIn this version, we’ve introduced a bunch of minor updates and bug fixes. Please see the \u003ca href=\\\"https://youtrack.jetbrains.com/articles/GO-A-231735963\\\"\u003erelease notes\u003c/a\u003e for the complete list of fixes and improvements.\u003c/p\u003e\",\"uninstallFeedbackLinks\":{\"linuxARM64\":\"https://www.jetbrains.com/go/uninstall/?edition=2025.1.1\",\"windowsJBR8\":\"https://www.jetbrains.com/go/uninstall/?edition=2025.1.1\",\"windowsZipJBR8\":\"https://www.jetbrains.com/go/uninstall/?edition=2025.1.1\",\"linux\":\"https://www.jetbrains.com/go/uninstall/?edition=2025.1.1\",\"thirdPartyLibrariesJson\":\"https://www.jetbrains.com/go/uninstall/?edition=2025.1.1\",\"windows\":\"https://www.jetbrains.com/go/uninstall/?edition=2025.1.1\",\"windowsZip\":\"https://www.jetbrains.com/go/uninstall/?edition=2025.1.1\",\"windowsARM64\":\"https://www.jetbrains.com/go/uninstall/?edition=2025.1.1\",\"linuxJBR8\":\"https://www.jetbrains.com/go/uninstall/?edition=2025.1.1\",\"mac\":\"https://www.jetbrains.com/go/uninstall/?edition=2025.1.1\",\"macJBR8\":\"https://www.jetbrains.com/go/uninstall/?edition=2025.1.1\",\"macM1\":\"https://www.jetbrains.com/go/uninstall/?edition=2025.1.1\"},\"printableReleaseType\":null}]}", + "ca_cert_pem": null, + "client_cert_pem": null, + "client_key_pem": null, + "id": "https://data.services.jetbrains.com/products/releases?code=GO\u0026latest=true\u0026type=release", + "insecure": null, + "method": null, + "request_body": null, + "request_headers": null, + "request_timeout_ms": null, + "response_body": "{\"GO\":[{\"date\":\"2025-05-12\",\"type\":\"release\",\"downloads\":{\"linuxARM64\":{\"link\":\"https://download.jetbrains.com/go/goland-2025.1.1-aarch64.tar.gz\",\"size\":1118167582,\"checksumLink\":\"https://download.jetbrains.com/go/goland-2025.1.1-aarch64.tar.gz.sha256\"},\"linux\":{\"link\":\"https://download.jetbrains.com/go/goland-2025.1.1.tar.gz\",\"size\":1120783192,\"checksumLink\":\"https://download.jetbrains.com/go/goland-2025.1.1.tar.gz.sha256\"},\"thirdPartyLibrariesJson\":{\"link\":\"https://resources.jetbrains.com/storage/third-party-libraries/go/goland-2025.1.1-third-party-libraries.json\",\"size\":61075,\"checksumLink\":\"https://resources.jetbrains.com/storage/third-party-libraries/go/goland-2025.1.1-third-party-libraries.json.sha256\"},\"windows\":{\"link\":\"https://download.jetbrains.com/go/goland-2025.1.1.exe\",\"size\":832016440,\"checksumLink\":\"https://download.jetbrains.com/go/goland-2025.1.1.exe.sha256\"},\"windowsZip\":{\"link\":\"https://download.jetbrains.com/go/goland-2025.1.1.win.zip\",\"size\":1132949747,\"checksumLink\":\"https://download.jetbrains.com/go/goland-2025.1.1.win.zip.sha256\"},\"windowsARM64\":{\"link\":\"https://download.jetbrains.com/go/goland-2025.1.1-aarch64.exe\",\"size\":794419312,\"checksumLink\":\"https://download.jetbrains.com/go/goland-2025.1.1-aarch64.exe.sha256\"},\"mac\":{\"link\":\"https://download.jetbrains.com/go/goland-2025.1.1.dmg\",\"size\":1073091958,\"checksumLink\":\"https://download.jetbrains.com/go/goland-2025.1.1.dmg.sha256\"},\"macM1\":{\"link\":\"https://download.jetbrains.com/go/goland-2025.1.1-aarch64.dmg\",\"size\":1062258831,\"checksumLink\":\"https://download.jetbrains.com/go/goland-2025.1.1-aarch64.dmg.sha256\"}},\"patches\":{\"win\":[{\"fromBuild\":\"243.26053.20\",\"link\":\"https://download.jetbrains.com/go/GO-243.26053.20-251.25410.140-patch-win.jar\",\"size\":347470625,\"checksumLink\":\"https://download.jetbrains.com/go/GO-243.26053.20-251.25410.140-patch-win.jar.sha256\"},{\"fromBuild\":\"251.23774.430\",\"link\":\"https://download.jetbrains.com/go/GO-251.23774.430-251.25410.140-patch-win.jar\",\"size\":113977718,\"checksumLink\":\"https://download.jetbrains.com/go/GO-251.23774.430-251.25410.140-patch-win.jar.sha256\"}],\"mac\":[{\"fromBuild\":\"243.26053.20\",\"link\":\"https://download.jetbrains.com/go/GO-243.26053.20-251.25410.140-patch-mac.jar\",\"size\":349019823,\"checksumLink\":\"https://download.jetbrains.com/go/GO-243.26053.20-251.25410.140-patch-mac.jar.sha256\"},{\"fromBuild\":\"251.23774.430\",\"link\":\"https://download.jetbrains.com/go/GO-251.23774.430-251.25410.140-patch-mac.jar\",\"size\":112340817,\"checksumLink\":\"https://download.jetbrains.com/go/GO-251.23774.430-251.25410.140-patch-mac.jar.sha256\"}],\"unix\":[{\"fromBuild\":\"243.26053.20\",\"link\":\"https://download.jetbrains.com/go/GO-243.26053.20-251.25410.140-patch-unix.jar\",\"size\":353528662,\"checksumLink\":\"https://download.jetbrains.com/go/GO-243.26053.20-251.25410.140-patch-unix.jar.sha256\"},{\"fromBuild\":\"251.23774.430\",\"link\":\"https://download.jetbrains.com/go/GO-251.23774.430-251.25410.140-patch-unix.jar\",\"size\":112385699,\"checksumLink\":\"https://download.jetbrains.com/go/GO-251.23774.430-251.25410.140-patch-unix.jar.sha256\"}]},\"notesLink\":\"https://youtrack.jetbrains.com/articles/GO-A-231735963\",\"licenseRequired\":true,\"version\":\"2025.1.1\",\"majorVersion\":\"2025.1\",\"build\":\"251.25410.140\",\"whatsnew\":\"\u003ch3\u003eGoLand 2025.1.1 is now available!\u003c/h3\u003e\\n\u003cp\u003eIn this version, we’ve introduced a bunch of minor updates and bug fixes. Please see the \u003ca href=\\\"https://youtrack.jetbrains.com/articles/GO-A-231735963\\\"\u003erelease notes\u003c/a\u003e for the complete list of fixes and improvements.\u003c/p\u003e\",\"uninstallFeedbackLinks\":{\"linuxARM64\":\"https://www.jetbrains.com/go/uninstall/?edition=2025.1.1\",\"windowsJBR8\":\"https://www.jetbrains.com/go/uninstall/?edition=2025.1.1\",\"windowsZipJBR8\":\"https://www.jetbrains.com/go/uninstall/?edition=2025.1.1\",\"linux\":\"https://www.jetbrains.com/go/uninstall/?edition=2025.1.1\",\"thirdPartyLibrariesJson\":\"https://www.jetbrains.com/go/uninstall/?edition=2025.1.1\",\"windows\":\"https://www.jetbrains.com/go/uninstall/?edition=2025.1.1\",\"windowsZip\":\"https://www.jetbrains.com/go/uninstall/?edition=2025.1.1\",\"windowsARM64\":\"https://www.jetbrains.com/go/uninstall/?edition=2025.1.1\",\"linuxJBR8\":\"https://www.jetbrains.com/go/uninstall/?edition=2025.1.1\",\"mac\":\"https://www.jetbrains.com/go/uninstall/?edition=2025.1.1\",\"macJBR8\":\"https://www.jetbrains.com/go/uninstall/?edition=2025.1.1\",\"macM1\":\"https://www.jetbrains.com/go/uninstall/?edition=2025.1.1\"},\"printableReleaseType\":null}]}", + "response_body_base64": "eyJHTyI6W3siZGF0ZSI6IjIwMjUtMDUtMTIiLCJ0eXBlIjoicmVsZWFzZSIsImRvd25sb2FkcyI6eyJsaW51eEFSTTY0Ijp7ImxpbmsiOiJodHRwczovL2Rvd25sb2FkLmpldGJy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Ly93d3cuamV0YnJhaW5zLmNvbS9nby91bmluc3RhbGwvP2VkaXRpb249MjAyNS4xLjEiLCJtYWMiOiJodHRwczovL3d3dy5qZXRicmFpbnMuY29tL2dvL3VuaW5zdGFsbC8/ZWRpdGlvbj0yMDI1LjEuMSIsIm1hY0pCUjgiOiJodHRwczovL3d3dy5qZXRicmFpbnMuY29tL2dvL3VuaW5zdGFsbC8/ZWRpdGlvbj0yMDI1LjEuMSIsIm1hY00xIjoiaHR0cHM6Ly93d3cuamV0YnJhaW5zLmNvbS9nby91bmluc3RhbGwvP2VkaXRpb249MjAyNS4xLjEifSwicHJpbnRhYmxlUmVsZWFzZVR5cGUiOm51bGx9XX0=", + "response_headers": { + "Access-Control-Allow-Origin": "*", + "Content-Type": "application/json;charset=UTF-8", + "Date": "Wed, 21 May 2025 17:57:48 GMT", + "Last-Modified": "Wed, 21 May 2025 09:29:01 GMT", + "Vary": "accept-encoding" + }, + "retry": null, + "status_code": 200, + "url": "https://data.services.jetbrains.com/products/releases?code=GO\u0026latest=true\u0026type=release" + }, + "sensitive_values": { + "response_headers": {} + } + }, + { + "address": "data.http.jetbrains_ide_versions[\"IU\"]", + "mode": "data", + "type": "http", + "name": "jetbrains_ide_versions", + "index": "IU", + "provider_name": "registry.terraform.io/hashicorp/http", + "schema_version": 0, + "values": { + "body": "{\"IIU\":[{\"date\":\"2025-05-09\",\"type\":\"release\",\"downloads\":{\"linuxARM64\":{\"link\":\"https://download.jetbrains.com/idea/ideaIU-2025.1.1.1-aarch64.tar.gz\",\"size\":1678615748,\"checksumLink\":\"https://download.jetbrains.com/idea/ideaIU-2025.1.1.1-aarch64.tar.gz.sha256\"},\"linux\":{\"link\":\"https://download.jetbrains.com/idea/ideaIU-2025.1.1.1.tar.gz\",\"size\":1681592268,\"checksumLink\":\"https://download.jetbrains.com/idea/ideaIU-2025.1.1.1.tar.gz.sha256\"},\"thirdPartyLibrariesJson\":{\"link\":\"https://resources.jetbrains.com/storage/third-party-libraries/idea/ideaIU-2025.1.1.1-third-party-libraries.json\",\"size\":388765,\"checksumLink\":\"https://resources.jetbrains.com/storage/third-party-libraries/idea/ideaIU-2025.1.1.1-third-party-libraries.json.sha256\"},\"windows\":{\"link\":\"https://download.jetbrains.com/idea/ideaIU-2025.1.1.1.exe\",\"size\":1266249784,\"checksumLink\":\"https://download.jetbrains.com/idea/ideaIU-2025.1.1.1.exe.sha256\"},\"windowsZip\":{\"link\":\"https://download.jetbrains.com/idea/ideaIU-2025.1.1.1.win.zip\",\"size\":1694591205,\"checksumLink\":\"https://download.jetbrains.com/idea/ideaIU-2025.1.1.1.win.zip.sha256\"},\"windowsARM64\":{\"link\":\"https://download.jetbrains.com/idea/ideaIU-2025.1.1.1-aarch64.exe\",\"size\":1228386664,\"checksumLink\":\"https://download.jetbrains.com/idea/ideaIU-2025.1.1.1-aarch64.exe.sha256\"},\"mac\":{\"link\":\"https://download.jetbrains.com/idea/ideaIU-2025.1.1.1.dmg\",\"size\":1616583653,\"checksumLink\":\"https://download.jetbrains.com/idea/ideaIU-2025.1.1.1.dmg.sha256\"},\"macM1\":{\"link\":\"https://download.jetbrains.com/idea/ideaIU-2025.1.1.1-aarch64.dmg\",\"size\":1605638446,\"checksumLink\":\"https://download.jetbrains.com/idea/ideaIU-2025.1.1.1-aarch64.dmg.sha256\"}},\"patches\":{\"win\":[{\"fromBuild\":\"251.25410.109\",\"link\":\"https://download.jetbrains.com/idea/IU-251.25410.109-251.25410.129-patch-win.jar\",\"size\":35358098,\"checksumLink\":\"https://download.jetbrains.com/idea/IU-251.25410.109-251.25410.129-patch-win.jar.sha256\"},{\"fromBuild\":\"243.26053.27\",\"link\":\"https://download.jetbrains.com/idea/IU-243.26053.27-251.25410.129-patch-win.jar\",\"size\":631084959,\"checksumLink\":\"https://download.jetbrains.com/idea/IU-243.26053.27-251.25410.129-patch-win.jar.sha256\"}],\"mac\":[{\"fromBuild\":\"251.25410.109\",\"link\":\"https://download.jetbrains.com/idea/IU-251.25410.109-251.25410.129-patch-mac.jar\",\"size\":33727565,\"checksumLink\":\"https://download.jetbrains.com/idea/IU-251.25410.109-251.25410.129-patch-mac.jar.sha256\"},{\"fromBuild\":\"243.26053.27\",\"link\":\"https://download.jetbrains.com/idea/IU-243.26053.27-251.25410.129-patch-mac.jar\",\"size\":632672125,\"checksumLink\":\"https://download.jetbrains.com/idea/IU-243.26053.27-251.25410.129-patch-mac.jar.sha256\"}],\"unix\":[{\"fromBuild\":\"251.25410.109\",\"link\":\"https://download.jetbrains.com/idea/IU-251.25410.109-251.25410.129-patch-unix.jar\",\"size\":33769350,\"checksumLink\":\"https://download.jetbrains.com/idea/IU-251.25410.109-251.25410.129-patch-unix.jar.sha256\"},{\"fromBuild\":\"243.26053.27\",\"link\":\"https://download.jetbrains.com/idea/IU-243.26053.27-251.25410.129-patch-unix.jar\",\"size\":637149470,\"checksumLink\":\"https://download.jetbrains.com/idea/IU-243.26053.27-251.25410.129-patch-unix.jar.sha256\"}]},\"notesLink\":\"https://youtrack.jetbrains.com/articles/IDEA-A-2100662430/IntelliJ-IDEA-2025.1.1.1-251.25410.129-build-Release-Notes\",\"licenseRequired\":true,\"version\":\"2025.1.1.1\",\"majorVersion\":\"2025.1\",\"build\":\"251.25410.129\",\"whatsnew\":\"IntelliJ IDEA 2025.1.1.1 is out! This update includes a hotfix for \u003ca href=\\\"https://youtrack.jetbrains.com/issue/KMT-1074/\\\"\u003eKMT-1074\u003c/a\u003e. Check out the release notes for all the details.\",\"uninstallFeedbackLinks\":{\"macWithJBR\":\"https://www.jetbrains.com/idea/uninstall/?edition=IU-2025.1.1.1\",\"linuxARM64\":\"https://www.jetbrains.com/idea/uninstall/?edition=IU-2025.1.1.1\",\"sourcesArchive\":\"https://www.jetbrains.com/idea/uninstall/?edition=IU-2025.1.1.1\",\"windowsJBR8\":\"https://www.jetbrains.com/idea/uninstall/?edition=IU-2025.1.1.1\",\"windowsZipJBR8\":\"https://www.jetbrains.com/idea/uninstall/?edition=IU-2025.1.1.1\",\"linuxWithoutJBR\":\"https://www.jetbrains.com/idea/uninstall/?edition=IU-2025.1.1.1\",\"windowsZipJBR11\":\"https://www.jetbrains.com/idea/uninstall/?edition=IU-2025.1.1.1\",\"thirdPartyLibrariesJson\":\"https://www.jetbrains.com/idea/uninstall/?edition=IU-2025.1.1.1\",\"windows\":\"https://www.jetbrains.com/idea/uninstall/?edition=IU-2025.1.1.1\",\"windowsZip\":\"https://www.jetbrains.com/idea/uninstall/?edition=IU-2025.1.1.1\",\"mac\":\"https://www.jetbrains.com/idea/uninstall/?edition=IU-2025.1.1.1\",\"macJBR8\":\"https://www.jetbrains.com/idea/uninstall/?edition=IU-2025.1.1.1\",\"macJBR11\":\"https://www.jetbrains.com/idea/uninstall/?edition=IU-2025.1.1.1\",\"windowsJBR11\":\"https://www.jetbrains.com/idea/uninstall/?edition=IU-2025.1.1.1\",\"linux\":\"https://www.jetbrains.com/idea/uninstall/?edition=IU-2025.1.1.1\",\"linuxJBR11\":\"https://www.jetbrains.com/idea/uninstall/?edition=IU-2025.1.1.1\",\"windowsARM64\":\"https://www.jetbrains.com/idea/uninstall/?edition=IU-2025.1.1.1\",\"linuxJBR8\":\"https://www.jetbrains.com/idea/uninstall/?edition=IU-2025.1.1.1\",\"macM1\":\"https://www.jetbrains.com/idea/uninstall/?edition=IU-2025.1.1.1\"},\"printableReleaseType\":null}]}", + "ca_cert_pem": null, + "client_cert_pem": null, + "client_key_pem": null, + "id": "https://data.services.jetbrains.com/products/releases?code=IU\u0026latest=true\u0026type=release", + "insecure": null, + "method": null, + "request_body": null, + "request_headers": null, + "request_timeout_ms": null, + "response_body": "{\"IIU\":[{\"date\":\"2025-05-09\",\"type\":\"release\",\"downloads\":{\"linuxARM64\":{\"link\":\"https://download.jetbrains.com/idea/ideaIU-2025.1.1.1-aarch64.tar.gz\",\"size\":1678615748,\"checksumLink\":\"https://download.jetbrains.com/idea/ideaIU-2025.1.1.1-aarch64.tar.gz.sha256\"},\"linux\":{\"link\":\"https://download.jetbrains.com/idea/ideaIU-2025.1.1.1.tar.gz\",\"size\":1681592268,\"checksumLink\":\"https://download.jetbrains.com/idea/ideaIU-2025.1.1.1.tar.gz.sha256\"},\"thirdPartyLibrariesJson\":{\"link\":\"https://resources.jetbrains.com/storage/third-party-libraries/idea/ideaIU-2025.1.1.1-third-party-libraries.json\",\"size\":388765,\"checksumLink\":\"https://resources.jetbrains.com/storage/third-party-libraries/idea/ideaIU-2025.1.1.1-third-party-libraries.json.sha256\"},\"windows\":{\"link\":\"https://download.jetbrains.com/idea/ideaIU-2025.1.1.1.exe\",\"size\":1266249784,\"checksumLink\":\"https://download.jetbrains.com/idea/ideaIU-2025.1.1.1.exe.sha256\"},\"windowsZip\":{\"link\":\"https://download.jetbrains.com/idea/ideaIU-2025.1.1.1.win.zip\",\"size\":1694591205,\"checksumLink\":\"https://download.jetbrains.com/idea/ideaIU-2025.1.1.1.win.zip.sha256\"},\"windowsARM64\":{\"link\":\"https://download.jetbrains.com/idea/ideaIU-2025.1.1.1-aarch64.exe\",\"size\":1228386664,\"checksumLink\":\"https://download.jetbrains.com/idea/ideaIU-2025.1.1.1-aarch64.exe.sha256\"},\"mac\":{\"link\":\"https://download.jetbrains.com/idea/ideaIU-2025.1.1.1.dmg\",\"size\":1616583653,\"checksumLink\":\"https://download.jetbrains.com/idea/ideaIU-2025.1.1.1.dmg.sha256\"},\"macM1\":{\"link\":\"https://download.jetbrains.com/idea/ideaIU-2025.1.1.1-aarch64.dmg\",\"size\":1605638446,\"checksumLink\":\"https://download.jetbrains.com/idea/ideaIU-2025.1.1.1-aarch64.dmg.sha256\"}},\"patches\":{\"win\":[{\"fromBuild\":\"251.25410.109\",\"link\":\"https://download.jetbrains.com/idea/IU-251.25410.109-251.25410.129-patch-win.jar\",\"size\":35358098,\"checksumLink\":\"https://download.jetbrains.com/idea/IU-251.25410.109-251.25410.129-patch-win.jar.sha256\"},{\"fromBuild\":\"243.26053.27\",\"link\":\"https://download.jetbrains.com/idea/IU-243.26053.27-251.25410.129-patch-win.jar\",\"size\":631084959,\"checksumLink\":\"https://download.jetbrains.com/idea/IU-243.26053.27-251.25410.129-patch-win.jar.sha256\"}],\"mac\":[{\"fromBuild\":\"251.25410.109\",\"link\":\"https://download.jetbrains.com/idea/IU-251.25410.109-251.25410.129-patch-mac.jar\",\"size\":33727565,\"checksumLink\":\"https://download.jetbrains.com/idea/IU-251.25410.109-251.25410.129-patch-mac.jar.sha256\"},{\"fromBuild\":\"243.26053.27\",\"link\":\"https://download.jetbrains.com/idea/IU-243.26053.27-251.25410.129-patch-mac.jar\",\"size\":632672125,\"checksumLink\":\"https://download.jetbrains.com/idea/IU-243.26053.27-251.25410.129-patch-mac.jar.sha256\"}],\"unix\":[{\"fromBuild\":\"251.25410.109\",\"link\":\"https://download.jetbrains.com/idea/IU-251.25410.109-251.25410.129-patch-unix.jar\",\"size\":33769350,\"checksumLink\":\"https://download.jetbrains.com/idea/IU-251.25410.109-251.25410.129-patch-unix.jar.sha256\"},{\"fromBuild\":\"243.26053.27\",\"link\":\"https://download.jetbrains.com/idea/IU-243.26053.27-251.25410.129-patch-unix.jar\",\"size\":637149470,\"checksumLink\":\"https://download.jetbrains.com/idea/IU-243.26053.27-251.25410.129-patch-unix.jar.sha256\"}]},\"notesLink\":\"https://youtrack.jetbrains.com/articles/IDEA-A-2100662430/IntelliJ-IDEA-2025.1.1.1-251.25410.129-build-Release-Notes\",\"licenseRequired\":true,\"version\":\"2025.1.1.1\",\"majorVersion\":\"2025.1\",\"build\":\"251.25410.129\",\"whatsnew\":\"IntelliJ IDEA 2025.1.1.1 is out! This update includes a hotfix for \u003ca href=\\\"https://youtrack.jetbrains.com/issue/KMT-1074/\\\"\u003eKMT-1074\u003c/a\u003e. Check out the release notes for all the details.\",\"uninstallFeedbackLinks\":{\"macWithJBR\":\"https://www.jetbrains.com/idea/uninstall/?edition=IU-2025.1.1.1\",\"linuxARM64\":\"https://www.jetbrains.com/idea/uninstall/?edition=IU-2025.1.1.1\",\"sourcesArchive\":\"https://www.jetbrains.com/idea/uninstall/?edition=IU-2025.1.1.1\",\"windowsJBR8\":\"https://www.jetbrains.com/idea/uninstall/?edition=IU-2025.1.1.1\",\"windowsZipJBR8\":\"https://www.jetbrains.com/idea/uninstall/?edition=IU-2025.1.1.1\",\"linuxWithoutJBR\":\"https://www.jetbrains.com/idea/uninstall/?edition=IU-2025.1.1.1\",\"windowsZipJBR11\":\"https://www.jetbrains.com/idea/uninstall/?edition=IU-2025.1.1.1\",\"thirdPartyLibrariesJson\":\"https://www.jetbrains.com/idea/uninstall/?edition=IU-2025.1.1.1\",\"windows\":\"https://www.jetbrains.com/idea/uninstall/?edition=IU-2025.1.1.1\",\"windowsZip\":\"https://www.jetbrains.com/idea/uninstall/?edition=IU-2025.1.1.1\",\"mac\":\"https://www.jetbrains.com/idea/uninstall/?edition=IU-2025.1.1.1\",\"macJBR8\":\"https://www.jetbrains.com/idea/uninstall/?edition=IU-2025.1.1.1\",\"macJBR11\":\"https://www.jetbrains.com/idea/uninstall/?edition=IU-2025.1.1.1\",\"windowsJBR11\":\"https://www.jetbrains.com/idea/uninstall/?edition=IU-2025.1.1.1\",\"linux\":\"https://www.jetbrains.com/idea/uninstall/?edition=IU-2025.1.1.1\",\"linuxJBR11\":\"https://www.jetbrains.com/idea/uninstall/?edition=IU-2025.1.1.1\",\"windowsARM64\":\"https://www.jetbrains.com/idea/uninstall/?edition=IU-2025.1.1.1\",\"linuxJBR8\":\"https://www.jetbrains.com/idea/uninstall/?edition=IU-2025.1.1.1\",\"macM1\":\"https://www.jetbrains.com/idea/uninstall/?edition=IU-2025.1.1.1\"},\"printableReleaseType\":null}]}", + "response_body_base64": "eyJJSVUiOlt7ImRhdGUiOiIyMDI1LTA1LTA5IiwidHlwZSI6InJlbGVhc2UiLCJkb3dubG9hZHMiOnsibGludXhBUk02NCI6eyJsaW5rIjoiaHR0cHM6Ly9kb3dubG9hZC5qZXRicmFpbnMuY29tL2lkZWEvaWRlYUlVLTIwMjUuMS4x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vbj1JVS0yMDI1LjEuMS4xIiwibGludXhKQlI4IjoiaHR0cHM6Ly93d3cuamV0YnJhaW5zLmNvbS9pZGVhL3VuaW5zdGFsbC8/ZWRpdGlvbj1JVS0yMDI1LjEuMS4xIiwibWFjTTEiOiJodHRwczovL3d3dy5qZXRicmFpbnMuY29tL2lkZWEvdW5pbnN0YWxsLz9lZGl0aW9uPUlVLTIwMjUuMS4xLjEifSwicHJpbnRhYmxlUmVsZWFzZVR5cGUiOm51bGx9XX0=", + "response_headers": { + "Access-Control-Allow-Origin": "*", + "Content-Type": "application/json;charset=UTF-8", + "Date": "Wed, 21 May 2025 17:57:48 GMT", + "Last-Modified": "Wed, 21 May 2025 09:29:01 GMT", + "Vary": "accept-encoding" + }, + "retry": null, + "status_code": 200, + "url": "https://data.services.jetbrains.com/products/releases?code=IU\u0026latest=true\u0026type=release" + }, + "sensitive_values": { + "response_headers": {} + } + }, + { + "address": "data.http.jetbrains_ide_versions[\"PY\"]", + "mode": "data", + "type": "http", + "name": "jetbrains_ide_versions", + "index": "PY", + "provider_name": "registry.terraform.io/hashicorp/http", + "schema_version": 0, + "values": { + "body": "{\"PCP\":[{\"date\":\"2025-05-15\",\"type\":\"release\",\"downloads\":{\"linuxARM64\":{\"link\":\"https://download.jetbrains.com/python/pycharm-2025.1.1.1-aarch64.tar.gz\",\"size\":1171821950,\"checksumLink\":\"https://download.jetbrains.com/python/pycharm-2025.1.1.1-aarch64.tar.gz.sha256\"},\"linux\":{\"link\":\"https://download.jetbrains.com/python/pycharm-2025.1.1.1.tar.gz\",\"size\":1174447820,\"checksumLink\":\"https://download.jetbrains.com/python/pycharm-2025.1.1.1.tar.gz.sha256\"},\"thirdPartyLibrariesJson\":{\"link\":\"https://resources.jetbrains.com/storage/third-party-libraries/python/pycharmPY-2025.1.1.1-third-party-libraries.json\",\"size\":383963,\"checksumLink\":\"https://resources.jetbrains.com/storage/third-party-libraries/python/pycharmPY-2025.1.1.1-third-party-libraries.json.sha256\"},\"windows\":{\"link\":\"https://download.jetbrains.com/python/pycharm-2025.1.1.1.exe\",\"size\":865917528,\"checksumLink\":\"https://download.jetbrains.com/python/pycharm-2025.1.1.1.exe.sha256\"},\"windowsZip\":{\"link\":\"https://download.jetbrains.com/python/pycharm-2025.1.1.1.win.zip\",\"size\":1198622914,\"checksumLink\":\"https://download.jetbrains.com/python/pycharm-2025.1.1.1.win.zip.sha256\"},\"windowsARM64\":{\"link\":\"https://download.jetbrains.com/python/pycharm-2025.1.1.1-aarch64.exe\",\"size\":828310440,\"checksumLink\":\"https://download.jetbrains.com/python/pycharm-2025.1.1.1-aarch64.exe.sha256\"},\"mac\":{\"link\":\"https://download.jetbrains.com/python/pycharm-2025.1.1.1.dmg\",\"size\":1133228342,\"checksumLink\":\"https://download.jetbrains.com/python/pycharm-2025.1.1.1.dmg.sha256\"},\"macM1\":{\"link\":\"https://download.jetbrains.com/python/pycharm-2025.1.1.1-aarch64.dmg\",\"size\":1122318478,\"checksumLink\":\"https://download.jetbrains.com/python/pycharm-2025.1.1.1-aarch64.dmg.sha256\"},\"windowsZipARM64\":{\"link\":\"https://download.jetbrains.com/python/pycharm-2025.1.1.1-aarch64.win.zip\",\"size\":1156103015,\"checksumLink\":\"https://download.jetbrains.com/python/pycharm-2025.1.1.1-aarch64.win.zip.sha256\"}},\"patches\":{\"win\":[{\"fromBuild\":\"251.25410.122\",\"link\":\"https://download.jetbrains.com/python/PY-251.25410.122-251.25410.159-patch-win.jar\",\"size\":92987228,\"checksumLink\":\"https://download.jetbrains.com/python/PY-251.25410.122-251.25410.159-patch-win.jar.sha256\"},{\"fromBuild\":\"243.26053.29\",\"link\":\"https://download.jetbrains.com/python/PY-243.26053.29-251.25410.159-patch-win.jar\",\"size\":378884244,\"checksumLink\":\"https://download.jetbrains.com/python/PY-243.26053.29-251.25410.159-patch-win.jar.sha256\"}],\"mac\":[{\"fromBuild\":\"251.25410.122\",\"link\":\"https://download.jetbrains.com/python/PY-251.25410.122-251.25410.159-patch-mac.jar\",\"size\":91343694,\"checksumLink\":\"https://download.jetbrains.com/python/PY-251.25410.122-251.25410.159-patch-mac.jar.sha256\"},{\"fromBuild\":\"243.26053.29\",\"link\":\"https://download.jetbrains.com/python/PY-243.26053.29-251.25410.159-patch-mac.jar\",\"size\":380475184,\"checksumLink\":\"https://download.jetbrains.com/python/PY-243.26053.29-251.25410.159-patch-mac.jar.sha256\"}],\"unix\":[{\"fromBuild\":\"251.25410.122\",\"link\":\"https://download.jetbrains.com/python/PY-251.25410.122-251.25410.159-patch-unix.jar\",\"size\":91390257,\"checksumLink\":\"https://download.jetbrains.com/python/PY-251.25410.122-251.25410.159-patch-unix.jar.sha256\"},{\"fromBuild\":\"243.26053.29\",\"link\":\"https://download.jetbrains.com/python/PY-243.26053.29-251.25410.159-patch-unix.jar\",\"size\":384937927,\"checksumLink\":\"https://download.jetbrains.com/python/PY-243.26053.29-251.25410.159-patch-unix.jar.sha256\"}]},\"notesLink\":\"https://youtrack.jetbrains.com/articles/PY-A-233538403/PyCharm-2025.1.1.1-251.25410.159-build-Release-Notes\",\"licenseRequired\":true,\"version\":\"2025.1.1.1\",\"majorVersion\":\"2025.1\",\"build\":\"251.25410.159\",\"whatsnew\":\"\u003cul\u003e\\n \u003cli\u003eFix for editor lags when using conda interpreter - \u003ca href=\\\"https://youtrack.jetbrains.com/issue/PY-80823\\\"\u003ePY-80823\u003c/a\u003e\u003c/li\u003e\\n\u003c/ul\u003e\\n\u003cp\u003eFor more details, refer to our \u003ca href=\\\"https://youtrack.jetbrains.com/articles/PY-A-233538403/PyCharm-2025.1.1.1-251.25410.159-build-Release-Notes\\\"\u003erelease notes\u003c/a\u003e.\u003c/p\u003e\",\"uninstallFeedbackLinks\":{\"linuxARM64\":\"https://www.jetbrains.com/pycharm/uninstall/?version=PY-2025.1.1.1\",\"macAnaconda\":\"https://www.jetbrains.com/pycharm/uninstall/?version=PY-2025.1.1.1\",\"linuxAnaconda\":\"https://www.jetbrains.com/pycharm/uninstall/?version=PY-2025.1.1.1\",\"thirdPartyLibrariesJson\":\"https://www.jetbrains.com/pycharm/uninstall/?version=PY-2025.1.1.1\",\"windows\":\"https://www.jetbrains.com/pycharm/uninstall/?version=PY-2025.1.1.1\",\"windowsZip\":\"https://www.jetbrains.com/pycharm/uninstall/?version=PY-2025.1.1.1\",\"mac\":\"https://www.jetbrains.com/pycharm/uninstall/?version=PY-2025.1.1.1\",\"linux\":\"https://www.jetbrains.com/pycharm/uninstall/?version=PY-2025.1.1.1\",\"windowsAnaconda\":\"https://www.jetbrains.com/pycharm/uninstall/?version=PY-2025.1.1.1\",\"windowsARM64\":\"https://www.jetbrains.com/pycharm/uninstall/?version=PY-2025.1.1.1\",\"macM1\":\"https://www.jetbrains.com/pycharm/uninstall/?version=PY-2025.1.1.1\",\"macM1Anaconda\":\"https://www.jetbrains.com/pycharm/uninstall/?version=PY-2025.1.1.1\",\"windowsZipARM64\":\"https://www.jetbrains.com/pycharm/uninstall/?version=PY-2025.1.1.1\"},\"printableReleaseType\":null}]}", + "ca_cert_pem": null, + "client_cert_pem": null, + "client_key_pem": null, + "id": "https://data.services.jetbrains.com/products/releases?code=PY\u0026latest=true\u0026type=release", + "insecure": null, + "method": null, + "request_body": null, + "request_headers": null, + "request_timeout_ms": null, + "response_body": "{\"PCP\":[{\"date\":\"2025-05-15\",\"type\":\"release\",\"downloads\":{\"linuxARM64\":{\"link\":\"https://download.jetbrains.com/python/pycharm-2025.1.1.1-aarch64.tar.gz\",\"size\":1171821950,\"checksumLink\":\"https://download.jetbrains.com/python/pycharm-2025.1.1.1-aarch64.tar.gz.sha256\"},\"linux\":{\"link\":\"https://download.jetbrains.com/python/pycharm-2025.1.1.1.tar.gz\",\"size\":1174447820,\"checksumLink\":\"https://download.jetbrains.com/python/pycharm-2025.1.1.1.tar.gz.sha256\"},\"thirdPartyLibrariesJson\":{\"link\":\"https://resources.jetbrains.com/storage/third-party-libraries/python/pycharmPY-2025.1.1.1-third-party-libraries.json\",\"size\":383963,\"checksumLink\":\"https://resources.jetbrains.com/storage/third-party-libraries/python/pycharmPY-2025.1.1.1-third-party-libraries.json.sha256\"},\"windows\":{\"link\":\"https://download.jetbrains.com/python/pycharm-2025.1.1.1.exe\",\"size\":865917528,\"checksumLink\":\"https://download.jetbrains.com/python/pycharm-2025.1.1.1.exe.sha256\"},\"windowsZip\":{\"link\":\"https://download.jetbrains.com/python/pycharm-2025.1.1.1.win.zip\",\"size\":1198622914,\"checksumLink\":\"https://download.jetbrains.com/python/pycharm-2025.1.1.1.win.zip.sha256\"},\"windowsARM64\":{\"link\":\"https://download.jetbrains.com/python/pycharm-2025.1.1.1-aarch64.exe\",\"size\":828310440,\"checksumLink\":\"https://download.jetbrains.com/python/pycharm-2025.1.1.1-aarch64.exe.sha256\"},\"mac\":{\"link\":\"https://download.jetbrains.com/python/pycharm-2025.1.1.1.dmg\",\"size\":1133228342,\"checksumLink\":\"https://download.jetbrains.com/python/pycharm-2025.1.1.1.dmg.sha256\"},\"macM1\":{\"link\":\"https://download.jetbrains.com/python/pycharm-2025.1.1.1-aarch64.dmg\",\"size\":1122318478,\"checksumLink\":\"https://download.jetbrains.com/python/pycharm-2025.1.1.1-aarch64.dmg.sha256\"},\"windowsZipARM64\":{\"link\":\"https://download.jetbrains.com/python/pycharm-2025.1.1.1-aarch64.win.zip\",\"size\":1156103015,\"checksumLink\":\"https://download.jetbrains.com/python/pycharm-2025.1.1.1-aarch64.win.zip.sha256\"}},\"patches\":{\"win\":[{\"fromBuild\":\"251.25410.122\",\"link\":\"https://download.jetbrains.com/python/PY-251.25410.122-251.25410.159-patch-win.jar\",\"size\":92987228,\"checksumLink\":\"https://download.jetbrains.com/python/PY-251.25410.122-251.25410.159-patch-win.jar.sha256\"},{\"fromBuild\":\"243.26053.29\",\"link\":\"https://download.jetbrains.com/python/PY-243.26053.29-251.25410.159-patch-win.jar\",\"size\":378884244,\"checksumLink\":\"https://download.jetbrains.com/python/PY-243.26053.29-251.25410.159-patch-win.jar.sha256\"}],\"mac\":[{\"fromBuild\":\"251.25410.122\",\"link\":\"https://download.jetbrains.com/python/PY-251.25410.122-251.25410.159-patch-mac.jar\",\"size\":91343694,\"checksumLink\":\"https://download.jetbrains.com/python/PY-251.25410.122-251.25410.159-patch-mac.jar.sha256\"},{\"fromBuild\":\"243.26053.29\",\"link\":\"https://download.jetbrains.com/python/PY-243.26053.29-251.25410.159-patch-mac.jar\",\"size\":380475184,\"checksumLink\":\"https://download.jetbrains.com/python/PY-243.26053.29-251.25410.159-patch-mac.jar.sha256\"}],\"unix\":[{\"fromBuild\":\"251.25410.122\",\"link\":\"https://download.jetbrains.com/python/PY-251.25410.122-251.25410.159-patch-unix.jar\",\"size\":91390257,\"checksumLink\":\"https://download.jetbrains.com/python/PY-251.25410.122-251.25410.159-patch-unix.jar.sha256\"},{\"fromBuild\":\"243.26053.29\",\"link\":\"https://download.jetbrains.com/python/PY-243.26053.29-251.25410.159-patch-unix.jar\",\"size\":384937927,\"checksumLink\":\"https://download.jetbrains.com/python/PY-243.26053.29-251.25410.159-patch-unix.jar.sha256\"}]},\"notesLink\":\"https://youtrack.jetbrains.com/articles/PY-A-233538403/PyCharm-2025.1.1.1-251.25410.159-build-Release-Notes\",\"licenseRequired\":true,\"version\":\"2025.1.1.1\",\"majorVersion\":\"2025.1\",\"build\":\"251.25410.159\",\"whatsnew\":\"\u003cul\u003e\\n \u003cli\u003eFix for editor lags when using conda interpreter - \u003ca href=\\\"https://youtrack.jetbrains.com/issue/PY-80823\\\"\u003ePY-80823\u003c/a\u003e\u003c/li\u003e\\n\u003c/ul\u003e\\n\u003cp\u003eFor more details, refer to our \u003ca href=\\\"https://youtrack.jetbrains.com/articles/PY-A-233538403/PyCharm-2025.1.1.1-251.25410.159-build-Release-Notes\\\"\u003erelease notes\u003c/a\u003e.\u003c/p\u003e\",\"uninstallFeedbackLinks\":{\"linuxARM64\":\"https://www.jetbrains.com/pycharm/uninstall/?version=PY-2025.1.1.1\",\"macAnaconda\":\"https://www.jetbrains.com/pycharm/uninstall/?version=PY-2025.1.1.1\",\"linuxAnaconda\":\"https://www.jetbrains.com/pycharm/uninstall/?version=PY-2025.1.1.1\",\"thirdPartyLibrariesJson\":\"https://www.jetbrains.com/pycharm/uninstall/?version=PY-2025.1.1.1\",\"windows\":\"https://www.jetbrains.com/pycharm/uninstall/?version=PY-2025.1.1.1\",\"windowsZip\":\"https://www.jetbrains.com/pycharm/uninstall/?version=PY-2025.1.1.1\",\"mac\":\"https://www.jetbrains.com/pycharm/uninstall/?version=PY-2025.1.1.1\",\"linux\":\"https://www.jetbrains.com/pycharm/uninstall/?version=PY-2025.1.1.1\",\"windowsAnaconda\":\"https://www.jetbrains.com/pycharm/uninstall/?version=PY-2025.1.1.1\",\"windowsARM64\":\"https://www.jetbrains.com/pycharm/uninstall/?version=PY-2025.1.1.1\",\"macM1\":\"https://www.jetbrains.com/pycharm/uninstall/?version=PY-2025.1.1.1\",\"macM1Anaconda\":\"https://www.jetbrains.com/pycharm/uninstall/?version=PY-2025.1.1.1\",\"windowsZipARM64\":\"https://www.jetbrains.com/pycharm/uninstall/?version=PY-2025.1.1.1\"},\"printableReleaseType\":null}]}", + "response_body_base64": "eyJQQ1AiOlt7ImRhdGUiOiIyMDI1LTA1LTE1IiwidHlwZSI6InJlbGVhc2UiLCJkb3dubG9hZHMiOnsibGludXhBUk02NCI6eyJsaW5rIjoiaHR0cHM6Ly9kb3dubG9hZC5qZXRicmFpbnMuY29tL3B5dGhvbi9weWNoYXJtLTIwMjUuMS4xLjEtYWFyY2g2NC50YXIuZ3oiLCJzaXplIjoxMTcxODIxOTUwLCJjaGVja3N1bUxpbmsiOiJodHRwczovL2Rvd25sb2FkLmpldGJyYWlucy5jb20vcHl0aG9uL3B5Y2hhcm0tMjAyNS4xLjEuMS1hYXJjaDY0LnRhci5nei5zaGEyNTYifSwibGludXgiOnsibGluayI6Imh0dHBzOi8vZG93bmxvYWQuamV0YnJhaW5zLmNvbS9weXRob24vcHljaGFybS0yMDI1LjEuMS4xL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W5zdGFsbC8/dmVyc2lvbj1QWS0yMDI1LjEuMS4xIiwid2luZG93c1ppcCI6Imh0dHBzOi8vd3d3LmpldGJyYWlucy5jb20vcHljaGFybS91bmluc3RhbGwvP3ZlcnNpb249UFktMjAyNS4xLjEuMSIsIm1hYyI6Imh0dHBzOi8vd3d3LmpldGJyYWlucy5jb20vcHljaGFybS91bmluc3RhbGwvP3ZlcnNpb249UFktMjAyNS4xLjEuMSIsImxpbnV4IjoiaHR0cHM6Ly93d3cuamV0YnJhaW5zLmNvbS9weWNoYXJtL3VuaW5zdGFsbC8/dmVyc2lvbj1QWS0yMDI1LjEuMS4xIiwid2luZG93c0FuYWNvbmRhIjoiaHR0cHM6Ly93d3cuamV0YnJhaW5zLmNvbS9weWNoYXJtL3VuaW5zdGFsbC8/dmVyc2lvbj1QWS0yMDI1LjEuMS4xIiwid2luZG93c0FSTTY0IjoiaHR0cHM6Ly93d3cuamV0YnJhaW5zLmNvbS9weWNoYXJtL3VuaW5zdGFsbC8/dmVyc2lvbj1QWS0yMDI1LjEuMS4xIiwibWFjTTEiOiJodHRwczovL3d3dy5qZXRicmFpbnMuY29tL3B5Y2hhcm0vdW5pbnN0YWxsLz92ZXJzaW9uPVBZLTIwMjUuMS4xLjEiLCJtYWNNMUFuYWNvbmRhIjoiaHR0cHM6Ly93d3cuamV0YnJhaW5zLmNvbS9weWNoYXJtL3VuaW5zdGFsbC8/dmVyc2lvbj1QWS0yMDI1LjEuMS4xIiwid2luZG93c1ppcEFSTTY0IjoiaHR0cHM6Ly93d3cuamV0YnJhaW5zLmNvbS9weWNoYXJtL3VuaW5zdGFsbC8/dmVyc2lvbj1QWS0yMDI1LjEuMS4xIn0sInByaW50YWJsZVJlbGVhc2VUeXBlIjpudWxsfV19", + "response_headers": { + "Access-Control-Allow-Origin": "*", + "Content-Type": "application/json;charset=UTF-8", + "Date": "Wed, 21 May 2025 17:57:48 GMT", + "Last-Modified": "Wed, 21 May 2025 09:29:01 GMT", + "Vary": "accept-encoding" + }, + "retry": null, + "status_code": 200, + "url": "https://data.services.jetbrains.com/products/releases?code=PY\u0026latest=true\u0026type=release" + }, + "sensitive_values": { + "response_headers": {} + } + } + ] + } + } + }, + "configuration": { + "provider_config": { + "coder": { + "name": "coder", + "full_name": "registry.terraform.io/coder/coder" + }, + "docker": { + "name": "docker", + "full_name": "registry.terraform.io/kreuzwerker/docker", + "version_constraint": "~\u003e 3.0.0" + }, + "envbuilder": { + "name": "envbuilder", + "full_name": "registry.terraform.io/coder/envbuilder" + }, + "http": { + "name": "http", + "full_name": "registry.terraform.io/hashicorp/http" + } + }, + "root_module": { + "resources": [ + { + "address": "data.coder_parameter.jetbrains_ide", + "mode": "data", + "type": "coder_parameter", + "name": "jetbrains_ide", + "provider_config_key": "coder", + "expressions": { + "default": { + "references": [ + "var.jetbrains_ides[0]", + "var.jetbrains_ides" + ] + }, + "display_name": { + "constant_value": "JetBrains IDE" + }, + "icon": { + "constant_value": "/icon/gateway.svg" + }, + "mutable": { + "constant_value": true + }, + "name": { + "constant_value": "jetbrains_ide" + }, + "type": { + "constant_value": "string" + } + }, + "schema_version": 0 + }, + { + "address": "data.http.jetbrains_ide_versions", + "mode": "data", + "type": "http", + "name": "jetbrains_ide_versions", + "provider_config_key": "http", + "expressions": { + "url": { + "references": [ + "var.releases_base_link", + "each.key", + "var.channel" + ] + } + }, + "schema_version": 0, + "for_each_expression": { + "references": [ + "var.jetbrains_ides" + ] + } + } + ], + "variables": { + "arch": { + "default": "amd64", + "description": "The target architecture of the workspace" + }, + "channel": { + "default": "release", + "description": "JetBrains IDE release channel. Valid values are release and eap." + }, + "download_base_link": { + "default": "https://download.jetbrains.com" + }, + "jetbrains_ide_versions": { + "default": { + "CL": { + "build_number": "243.21565.238", + "version": "2024.1" + }, + "GO": { + "build_number": "243.21565.208", + "version": "2024.3" + }, + "IU": { + "build_number": "243.21565.193", + "version": "2024.3" + }, + "PS": { + "build_number": "243.21565.202", + "version": "2024.3" + }, + "PY": { + "build_number": "243.21565.199", + "version": "2024.3" + }, + "RD": { + "build_number": "243.21565.191", + "version": "2024.3" + }, + "RM": { + "build_number": "243.21565.197", + "version": "2024.3" + }, + "RR": { + "build_number": "243.22562.230", + "version": "2024.3" + }, + "WS": { + "build_number": "243.21565.180", + "version": "2024.3" + } + }, + "description": "The set of versions for each jetbrains IDE" + }, + "jetbrains_ides": { + "default": [ + "IU", + "PS", + "WS", + "PY", + "CL", + "GO", + "RM", + "RD", + "RR" + ], + "description": "The list of IDE product codes." + }, + "releases_base_link": { + "default": "https://data.services.jetbrains.com" + } + } + } + }, + "checks": [ + { + "address": { + "kind": "var", + "name": "arch", + "to_display": "var.arch" + }, + "status": "pass", + "instances": [ + { + "address": { + "to_display": "var.arch" + }, + "status": "pass" + } + ] + }, + { + "address": { + "kind": "var", + "name": "channel", + "to_display": "var.channel" + }, + "status": "pass", + "instances": [ + { + "address": { + "to_display": "var.channel" + }, + "status": "pass" + } + ] + }, + { + "address": { + "kind": "var", + "name": "download_base_link", + "to_display": "var.download_base_link" + }, + "status": "pass", + "instances": [ + { + "address": { + "to_display": "var.download_base_link" + }, + "status": "pass" + } + ] + }, + { + "address": { + "kind": "var", + "name": "jetbrains_ide_versions", + "to_display": "var.jetbrains_ide_versions" + }, + "status": "pass", + "instances": [ + { + "address": { + "to_display": "var.jetbrains_ide_versions" + }, + "status": "pass" + } + ] + }, + { + "address": { + "kind": "var", + "name": "jetbrains_ides", + "to_display": "var.jetbrains_ides" + }, + "status": "pass", + "instances": [ + { + "address": { + "to_display": "var.jetbrains_ides" + }, + "status": "pass" + } + ] + }, + { + "address": { + "kind": "var", + "name": "releases_base_link", + "to_display": "var.releases_base_link" + }, + "status": "pass", + "instances": [ + { + "address": { + "to_display": "var.releases_base_link" + }, + "status": "pass" + } + ] + } + ], + "timestamp": "2025-05-21T17:57:48Z", + "applyable": false, + "complete": true, + "errored": false +} From ab173d35040c9a02755a8fad3303be9e46764ea8 Mon Sep 17 00:00:00 2001 From: Steven Masley Date: Tue, 27 May 2025 12:25:48 -0500 Subject: [PATCH 44/61] chore: discard logs by default (#138) Logs should be instanced. The caller can define where the logs go. Updated trivy to include this merge: https://github.com/aquasecurity/trivy/pull/8738 --- go.mod | 74 ++++++++++----------- go.sum | 190 ++++++++++++++++++++++++++++------------------------- preview.go | 11 +++- 3 files changed, 146 insertions(+), 129 deletions(-) diff --git a/go.mod b/go.mod index a63be13..9612114 100644 --- a/go.mod +++ b/go.mod @@ -20,55 +20,54 @@ require ( github.com/jedib0t/go-pretty/v6 v6.6.7 github.com/quasilyte/go-ruleguard/dsl v0.3.22 github.com/stretchr/testify v1.10.0 - github.com/zclconf/go-cty v1.16.2 + github.com/zclconf/go-cty v1.16.3 golang.org/x/xerrors v0.0.0-20240903120638-7835f813f4da ) require ( - cel.dev/expr v0.19.0 // indirect - cloud.google.com/go v0.116.0 // indirect - cloud.google.com/go/auth v0.14.0 // indirect - cloud.google.com/go/auth/oauth2adapt v0.2.7 // indirect + cel.dev/expr v0.20.0 // indirect + cloud.google.com/go v0.118.3 // indirect + cloud.google.com/go/auth v0.15.0 // indirect + cloud.google.com/go/auth/oauth2adapt v0.2.8 // indirect cloud.google.com/go/compute/metadata v0.6.0 // indirect - cloud.google.com/go/iam v1.2.2 // indirect - cloud.google.com/go/monitoring v1.21.2 // indirect - cloud.google.com/go/storage v1.49.0 // indirect - github.com/GoogleCloudPlatform/opentelemetry-operations-go/detectors/gcp v1.25.0 // indirect - github.com/GoogleCloudPlatform/opentelemetry-operations-go/exporter/metric v0.48.1 // indirect - github.com/GoogleCloudPlatform/opentelemetry-operations-go/internal/resourcemapping v0.48.1 // indirect + cloud.google.com/go/iam v1.4.1 // indirect + cloud.google.com/go/monitoring v1.24.0 // indirect + cloud.google.com/go/storage v1.50.0 // indirect + github.com/GoogleCloudPlatform/opentelemetry-operations-go/detectors/gcp v1.26.0 // indirect + github.com/GoogleCloudPlatform/opentelemetry-operations-go/exporter/metric v0.49.0 // indirect + github.com/GoogleCloudPlatform/opentelemetry-operations-go/internal/resourcemapping v0.49.0 // indirect github.com/ProtonMail/go-crypto v1.1.6 // indirect github.com/agext/levenshtein v1.2.3 // indirect github.com/apparentlymart/go-cidr v1.1.0 // indirect github.com/apparentlymart/go-textseg/v15 v15.0.0 // indirect github.com/aquasecurity/go-version v0.0.1 // indirect - github.com/aws/aws-sdk-go v1.55.6 // indirect + github.com/aws/aws-sdk-go v1.55.7 // indirect github.com/aymanbagabas/go-osc52/v2 v2.0.1 // indirect github.com/bgentry/go-netrc v0.0.0-20140422174119-9fd32a8b3d3d // indirect github.com/bmatcuk/doublestar/v4 v4.8.1 // indirect - github.com/census-instrumentation/opencensus-proto v0.4.1 // indirect github.com/cespare/xxhash/v2 v2.3.0 // indirect github.com/charmbracelet/lipgloss v0.8.0 // indirect - github.com/cloudflare/circl v1.6.0 // indirect - github.com/cncf/xds/go v0.0.0-20240905190251-b4127c9b8d78 // indirect + github.com/cloudflare/circl v1.6.1 // indirect + github.com/cncf/xds/go v0.0.0-20250121191232-2f005788dc42 // indirect github.com/coder/pretty v0.0.0-20230908205945-e89ba86370e0 // indirect github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc // indirect github.com/dlclark/regexp2 v1.11.4 // indirect github.com/dop251/goja v0.0.0-20241024094426-79f3a7efcdbd // indirect - github.com/envoyproxy/go-control-plane v0.13.1 // indirect - github.com/envoyproxy/protoc-gen-validate v1.1.0 // indirect + github.com/envoyproxy/go-control-plane/envoy v1.32.4 // indirect + github.com/envoyproxy/protoc-gen-validate v1.2.1 // indirect github.com/fatih/color v1.18.0 // indirect github.com/fatih/structtag v1.2.0 // indirect github.com/felixge/httpsnoop v1.0.4 // indirect + github.com/go-jose/go-jose/v4 v4.0.5 // indirect github.com/go-logr/logr v1.4.2 // indirect github.com/go-logr/stdr v1.2.2 // indirect github.com/go-sourcemap/sourcemap v2.1.3+incompatible // indirect - github.com/golang/groupcache v0.0.0-20241129210726-2c02b8208cf8 // indirect github.com/golang/protobuf v1.5.4 // indirect github.com/google/go-cmp v0.7.0 // indirect github.com/google/pprof v0.0.0-20240227163752-401108e1b7e7 // indirect github.com/google/s2a-go v0.1.9 // indirect github.com/google/uuid v1.6.0 // indirect - github.com/googleapis/enterprise-certificate-proxy v0.3.4 // indirect + github.com/googleapis/enterprise-certificate-proxy v0.3.6 // indirect github.com/googleapis/gax-go/v2 v2.14.1 // indirect github.com/hashicorp/errwrap v1.1.0 // indirect github.com/hashicorp/go-cleanhttp v0.5.2 // indirect @@ -82,7 +81,7 @@ require ( github.com/hashicorp/terraform-plugin-go v0.26.0 // indirect github.com/hashicorp/terraform-plugin-log v0.9.0 // indirect github.com/jmespath/go-jmespath v0.4.1-0.20220621161143-b0104c826a24 // indirect - github.com/klauspost/compress v1.17.11 // indirect + github.com/klauspost/compress v1.18.0 // indirect github.com/lucasb-eyer/go-colorful v1.2.0 // indirect github.com/mattn/go-colorable v0.1.14 // indirect github.com/mattn/go-isatty v0.0.20 // indirect @@ -101,45 +100,46 @@ require ( github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 // indirect github.com/rivo/uniseg v0.4.7 // indirect github.com/robfig/cron/v3 v3.0.1 // indirect - github.com/samber/lo v1.49.1 // indirect + github.com/samber/lo v1.50.0 // indirect github.com/spf13/pflag v1.0.6 // indirect + github.com/spiffe/go-spiffe/v2 v2.5.0 // indirect github.com/ulikunitz/xz v0.5.12 // indirect github.com/vmihailenco/msgpack v4.0.4+incompatible // indirect github.com/vmihailenco/msgpack/v5 v5.4.1 // indirect github.com/vmihailenco/tagparser/v2 v2.0.0 // indirect github.com/zclconf/go-cty-yaml v1.1.0 // indirect - go.opencensus.io v0.24.0 // indirect + github.com/zeebo/errs v1.4.0 // indirect go.opentelemetry.io/auto/sdk v1.1.0 // indirect - go.opentelemetry.io/contrib/detectors/gcp v1.32.0 // indirect - go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.56.0 // indirect - go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.59.0 // indirect + go.opentelemetry.io/contrib/detectors/gcp v1.34.0 // indirect + go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.60.0 // indirect + go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.60.0 // indirect go.opentelemetry.io/otel v1.35.0 // indirect go.opentelemetry.io/otel/metric v1.35.0 // indirect - go.opentelemetry.io/otel/sdk v1.34.0 // indirect - go.opentelemetry.io/otel/sdk/metric v1.32.0 // indirect + go.opentelemetry.io/otel/sdk v1.35.0 // indirect + go.opentelemetry.io/otel/sdk/metric v1.35.0 // indirect go.opentelemetry.io/otel/trace v1.35.0 // indirect golang.org/x/crypto v0.38.0 // indirect - golang.org/x/exp v0.0.0-20250106191152-7588d65b2ba8 // indirect + golang.org/x/exp v0.0.0-20250408133849-7e4ce0ab07d0 // indirect golang.org/x/mod v0.24.0 // indirect golang.org/x/net v0.40.0 // indirect - golang.org/x/oauth2 v0.26.0 // indirect + golang.org/x/oauth2 v0.28.0 // indirect golang.org/x/sync v0.14.0 // indirect golang.org/x/sys v0.33.0 // indirect golang.org/x/term v0.32.0 // indirect golang.org/x/text v0.25.0 // indirect - golang.org/x/time v0.10.0 // indirect + golang.org/x/time v0.11.0 // indirect golang.org/x/tools v0.33.0 // indirect - google.golang.org/api v0.218.0 // indirect + google.golang.org/api v0.228.0 // indirect google.golang.org/appengine v1.6.8 // indirect - google.golang.org/genproto v0.0.0-20241118233622-e639e219e697 // indirect - google.golang.org/genproto/googleapis/api v0.0.0-20250115164207-1a7da9e5054f // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20250115164207-1a7da9e5054f // indirect - google.golang.org/grpc v1.70.0 // indirect - google.golang.org/protobuf v1.36.5 // indirect + google.golang.org/genproto v0.0.0-20250303144028-a0af3efb3deb // indirect + google.golang.org/genproto/googleapis/api v0.0.0-20250303144028-a0af3efb3deb // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20250313205543-e70fdf4c4cb4 // indirect + google.golang.org/grpc v1.72.0 // indirect + google.golang.org/protobuf v1.36.6 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect k8s.io/utils v0.0.0-20241104100929-3ea5e8cea738 // indirect ) // Trivy has some issues that we're floating patches for, and will hopefully // be upstreamed eventually. -replace github.com/aquasecurity/trivy => github.com/coder/trivy v0.0.0-20250409153844-e6b004bc465a +replace github.com/aquasecurity/trivy => github.com/coder/trivy v0.0.0-20250527170238-9416a59d7019 diff --git a/go.sum b/go.sum index 1688da1..2295404 100644 --- a/go.sum +++ b/go.sum @@ -1,7 +1,7 @@ cdr.dev/slog v1.6.2-0.20240126064726-20367d4aede6 h1:KHblWIE/KHOwQ6lEbMZt6YpcGve2FEZ1sDtrW1Am5UI= cdr.dev/slog v1.6.2-0.20240126064726-20367d4aede6/go.mod h1:NaoTA7KwopCrnaSb0JXTC0PTp/O/Y83Lndnq0OEV3ZQ= -cel.dev/expr v0.19.0 h1:lXuo+nDhpyJSpWxpPVi5cPUwzKb+dsdOiw6IreM5yt0= -cel.dev/expr v0.19.0/go.mod h1:MrpN08Q+lEBs+bGYdLxxHkZoUSsCp0nSKTs0nTymJgw= +cel.dev/expr v0.20.0 h1:OunBvVCfvpWlt4dN7zg3FM6TDkzOePe1+foGJ9AXeeI= +cel.dev/expr v0.20.0/go.mod h1:MrpN08Q+lEBs+bGYdLxxHkZoUSsCp0nSKTs0nTymJgw= cloud.google.com/go v0.26.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw= cloud.google.com/go v0.34.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw= cloud.google.com/go v0.38.0/go.mod h1:990N+gfupTy94rShfmMCWGDn0LpTmnzTp2qbd1dvSRU= @@ -40,8 +40,8 @@ cloud.google.com/go v0.104.0/go.mod h1:OO6xxXdJyvuJPcEPBLN9BJPD+jep5G1+2U5B5gkRY cloud.google.com/go v0.105.0/go.mod h1:PrLgOJNe5nfE9UMxKxgXj4mD3voiP+YQ6gdt6KMFOKM= cloud.google.com/go v0.107.0/go.mod h1:wpc2eNrD7hXUTy8EKS10jkxpZBjASrORK7goS+3YX2I= cloud.google.com/go v0.110.0/go.mod h1:SJnCLqQ0FCFGSZMUNUf84MV3Aia54kn7pi8st7tMzaY= -cloud.google.com/go v0.116.0 h1:B3fRrSDkLRt5qSHWe40ERJvhvnQwdZiHu0bJOpldweE= -cloud.google.com/go v0.116.0/go.mod h1:cEPSRWPzZEswwdr9BxE6ChEn01dWlTaF05LiC2Xs70U= +cloud.google.com/go v0.118.3 h1:jsypSnrE/w4mJysioGdMBg4MiW/hHx/sArFpaBWHdME= +cloud.google.com/go v0.118.3/go.mod h1:Lhs3YLnBlwJ4KA6nuObNMZ/fCbOQBPuWKPoE0Wa/9Vc= cloud.google.com/go/accessapproval v1.4.0/go.mod h1:zybIuC3KpDOvotz59lFe5qxRZx6C75OtwbisN56xYB4= cloud.google.com/go/accessapproval v1.5.0/go.mod h1:HFy3tuiGvMdcd/u+Cu5b9NkO1pEICJ46IR82PoUdplw= cloud.google.com/go/accessapproval v1.6.0/go.mod h1:R0EiYnwV5fsRFiKZkPHr6mwyk2wxUJ30nL4j2pcFY2E= @@ -103,10 +103,10 @@ cloud.google.com/go/assuredworkloads v1.7.0/go.mod h1:z/736/oNmtGAyU47reJgGN+KVo cloud.google.com/go/assuredworkloads v1.8.0/go.mod h1:AsX2cqyNCOvEQC8RMPnoc0yEarXQk6WEKkxYfL6kGIo= cloud.google.com/go/assuredworkloads v1.9.0/go.mod h1:kFuI1P78bplYtT77Tb1hi0FMxM0vVpRC7VVoJC3ZoT0= cloud.google.com/go/assuredworkloads v1.10.0/go.mod h1:kwdUQuXcedVdsIaKgKTp9t0UJkE5+PAVNhdQm4ZVq2E= -cloud.google.com/go/auth v0.14.0 h1:A5C4dKV/Spdvxcl0ggWwWEzzP7AZMJSEIgrkngwhGYM= -cloud.google.com/go/auth v0.14.0/go.mod h1:CYsoRL1PdiDuqeQpZE0bP2pnPrGqFcOkI0nldEQis+A= -cloud.google.com/go/auth/oauth2adapt v0.2.7 h1:/Lc7xODdqcEw8IrZ9SvwnlLX6j9FHQM74z6cBk9Rw6M= -cloud.google.com/go/auth/oauth2adapt v0.2.7/go.mod h1:NTbTTzfvPl1Y3V1nPpOgl2w6d/FjO7NNUQaWSox6ZMc= +cloud.google.com/go/auth v0.15.0 h1:Ly0u4aA5vG/fsSsxu98qCQBemXtAtJf+95z9HK+cxps= +cloud.google.com/go/auth v0.15.0/go.mod h1:WJDGqZ1o9E9wKIL+IwStfyn/+s59zl4Bi+1KQNVXLZ8= +cloud.google.com/go/auth/oauth2adapt v0.2.8 h1:keo8NaayQZ6wimpNSmW5OPc283g65QNIiLpZnkHRbnc= +cloud.google.com/go/auth/oauth2adapt v0.2.8/go.mod h1:XQ9y31RkqZCcwJWNSx2Xvric3RrU88hAYYbjDWYDL+c= cloud.google.com/go/automl v1.5.0/go.mod h1:34EjfoFGMZ5sgJ9EoLsRtdPSNZLcfflJR39VbVNS2M0= cloud.google.com/go/automl v1.6.0/go.mod h1:ugf8a6Fx+zP0D59WLhqgTDsQI9w07o64uf/Is3Nh5p8= cloud.google.com/go/automl v1.7.0/go.mod h1:RL9MYCCsJEOmt0Wf3z9uzG0a7adTT1fe+aObgSpkCt8= @@ -321,8 +321,8 @@ cloud.google.com/go/iam v0.8.0/go.mod h1:lga0/y3iH6CX7sYqypWJ33hf7kkfXJag67naqGE cloud.google.com/go/iam v0.11.0/go.mod h1:9PiLDanza5D+oWFZiH1uG+RnRCfEGKoyl6yo4cgWZGY= cloud.google.com/go/iam v0.12.0/go.mod h1:knyHGviacl11zrtZUoDuYpDgLjvr28sLQaG0YB2GYAY= cloud.google.com/go/iam v0.13.0/go.mod h1:ljOg+rcNfzZ5d6f1nAUJ8ZIxOaZUVoS14bKCtaLZ/D0= -cloud.google.com/go/iam v1.2.2 h1:ozUSofHUGf/F4tCNy/mu9tHLTaxZFLOUiKzjcgWHGIA= -cloud.google.com/go/iam v1.2.2/go.mod h1:0Ys8ccaZHdI1dEUilwzqng/6ps2YB6vRsjIe00/+6JY= +cloud.google.com/go/iam v1.4.1 h1:cFC25Nv+u5BkTR/BT1tXdoF2daiVbZ1RLx2eqfQ9RMM= +cloud.google.com/go/iam v1.4.1/go.mod h1:2vUEJpUG3Q9p2UdsyksaKpDzlwOrnMzS30isdReIcLM= cloud.google.com/go/iap v1.4.0/go.mod h1:RGFwRJdihTINIe4wZ2iCP0zF/qu18ZwyKxrhMhygBEc= cloud.google.com/go/iap v1.5.0/go.mod h1:UH/CGgKd4KyohZL5Pt0jSKE4m3FR51qg6FKQ/z/Ix9A= cloud.google.com/go/iap v1.6.0/go.mod h1:NSuvI9C/j7UdjGjIde7t7HBz+QTwBcapPE07+sSRcLk= @@ -352,13 +352,13 @@ cloud.google.com/go/lifesciences v0.6.0/go.mod h1:ddj6tSX/7BOnhxCSd3ZcETvtNr8NZ6 cloud.google.com/go/lifesciences v0.8.0/go.mod h1:lFxiEOMqII6XggGbOnKiyZ7IBwoIqA84ClvoezaA/bo= cloud.google.com/go/logging v1.6.1/go.mod h1:5ZO0mHHbvm8gEmeEUHrmDlTDSu5imF6MUP9OfilNXBw= cloud.google.com/go/logging v1.7.0/go.mod h1:3xjP2CjkM3ZkO73aj4ASA5wRPGGCRrPIAeNqVNkzY8M= -cloud.google.com/go/logging v1.12.0 h1:ex1igYcGFd4S/RZWOCU51StlIEuey5bjqwH9ZYjHibk= -cloud.google.com/go/logging v1.12.0/go.mod h1:wwYBt5HlYP1InnrtYI0wtwttpVU1rifnMT7RejksUAM= +cloud.google.com/go/logging v1.13.0 h1:7j0HgAp0B94o1YRDqiqm26w4q1rDMH7XNRU34lJXHYc= +cloud.google.com/go/logging v1.13.0/go.mod h1:36CoKh6KA/M0PbhPKMq6/qety2DCAErbhXT62TuXALA= cloud.google.com/go/longrunning v0.1.1/go.mod h1:UUFxuDWkv22EuY93jjmDMFT5GPQKeFVJBIF6QlTqdsE= cloud.google.com/go/longrunning v0.3.0/go.mod h1:qth9Y41RRSUE69rDcOn6DdK3HfQfsUI0YSmW3iIlLJc= cloud.google.com/go/longrunning v0.4.1/go.mod h1:4iWDqhBZ70CvZ6BfETbvam3T8FMvLK+eFj0E6AaRQTo= -cloud.google.com/go/longrunning v0.6.2 h1:xjDfh1pQcWPEvnfjZmwjKQEcHnpz6lHjfy7Fo0MK+hc= -cloud.google.com/go/longrunning v0.6.2/go.mod h1:k/vIs83RN4bE3YCswdXC5PFfWVILjm3hpEUlSko4PiI= +cloud.google.com/go/longrunning v0.6.4 h1:3tyw9rO3E2XVXzSApn1gyEEnH2K9SynNQjMlBi3uHLg= +cloud.google.com/go/longrunning v0.6.4/go.mod h1:ttZpLCe6e7EXvn9OxpBRx7kZEB0efv8yBO6YnVMfhJs= cloud.google.com/go/managedidentities v1.3.0/go.mod h1:UzlW3cBOiPrzucO5qWkNkh0w33KFtBJU281hacNvsdE= cloud.google.com/go/managedidentities v1.4.0/go.mod h1:NWSBYbEMgqmbZsLIyKvxrYbtqOsxY1ZrGM+9RgDqInM= cloud.google.com/go/managedidentities v1.5.0/go.mod h1:+dWcZ0JlUmpuxpIDfyP5pP5y0bLdRwOS4Lp7gMni/LA= @@ -382,8 +382,8 @@ cloud.google.com/go/monitoring v1.7.0/go.mod h1:HpYse6kkGo//7p6sT0wsIC6IBDET0RhI cloud.google.com/go/monitoring v1.8.0/go.mod h1:E7PtoMJ1kQXWxPjB6mv2fhC5/15jInuulFdYYtlcvT4= cloud.google.com/go/monitoring v1.12.0/go.mod h1:yx8Jj2fZNEkL/GYZyTLS4ZtZEZN8WtDEiEqG4kLK50w= cloud.google.com/go/monitoring v1.13.0/go.mod h1:k2yMBAB1H9JT/QETjNkgdCGD9bPF712XiLTVr+cBrpw= -cloud.google.com/go/monitoring v1.21.2 h1:FChwVtClH19E7pJ+e0xUhJPGksctZNVOk2UhMmblmdU= -cloud.google.com/go/monitoring v1.21.2/go.mod h1:hS3pXvaG8KgWTSz+dAdyzPrGUYmi2Q+WFX8g2hqVEZU= +cloud.google.com/go/monitoring v1.24.0 h1:csSKiCJ+WVRgNkRzzz3BPoGjFhjPY23ZTcaenToJxMM= +cloud.google.com/go/monitoring v1.24.0/go.mod h1:Bd1PRK5bmQBQNnuGwHBfUamAV1ys9049oEPHnn4pcsc= cloud.google.com/go/networkconnectivity v1.4.0/go.mod h1:nOl7YL8odKyAOtzNX73/M5/mGZgqqMeryi6UPZTk/rA= cloud.google.com/go/networkconnectivity v1.5.0/go.mod h1:3GzqJx7uhtlM3kln0+x5wyFvuVH1pIBJjhCpjzSt75o= cloud.google.com/go/networkconnectivity v1.6.0/go.mod h1:OJOoEXW+0LAxHh89nXd64uGG+FbQoeH8DtxCHVOMlaM= @@ -547,8 +547,8 @@ cloud.google.com/go/storage v1.23.0/go.mod h1:vOEEDNFnciUMhBeT6hsJIn3ieU5cFRmzeL cloud.google.com/go/storage v1.27.0/go.mod h1:x9DOL8TK/ygDUMieqwfhdpQryTeEkhGKMi80i/iqR2s= cloud.google.com/go/storage v1.28.1/go.mod h1:Qnisd4CqDdo6BGs2AD5LLnEsmSQ80wQ5ogcBBKhU86Y= cloud.google.com/go/storage v1.29.0/go.mod h1:4puEjyTKnku6gfKoTfNOU/W+a9JyuVNxjpS5GBrB8h4= -cloud.google.com/go/storage v1.49.0 h1:zenOPBOWHCnojRd9aJZAyQXBYqkJkdQS42dxL55CIMw= -cloud.google.com/go/storage v1.49.0/go.mod h1:k1eHhhpLvrPjVGfo0mOUPEJ4Y2+a/Hv5PiwehZI9qGU= +cloud.google.com/go/storage v1.50.0 h1:3TbVkzTooBvnZsk7WaAQfOsNrdoM8QHusXA1cpk6QJs= +cloud.google.com/go/storage v1.50.0/go.mod h1:l7XeiD//vx5lfqE3RavfmU9yvk5Pp0Zhcv482poyafY= cloud.google.com/go/storagetransfer v1.5.0/go.mod h1:dxNzUopWy7RQevYFHewchb29POFv3/AaBgnhqzqiK0w= cloud.google.com/go/storagetransfer v1.6.0/go.mod h1:y77xm4CQV/ZhFZH75PLEXY0ROiS7Gh6pSKrM8dJyg6I= cloud.google.com/go/storagetransfer v1.7.0/go.mod h1:8Giuj1QNb1kfLAiWM1bN6dHzfdlDAVC9rv9abHot2W4= @@ -568,8 +568,8 @@ cloud.google.com/go/trace v1.3.0/go.mod h1:FFUE83d9Ca57C+K8rDl/Ih8LwOzWIV1krKgxg cloud.google.com/go/trace v1.4.0/go.mod h1:UG0v8UBqzusp+z63o7FK74SdFE+AXpCLdFb1rshXG+Y= cloud.google.com/go/trace v1.8.0/go.mod h1:zH7vcsbAhklH8hWFig58HvxcxyQbaIqMarMg9hn5ECA= cloud.google.com/go/trace v1.9.0/go.mod h1:lOQqpE5IaWY0Ixg7/r2SjixMuc6lfTFeO4QGM4dQWOk= -cloud.google.com/go/trace v1.11.2 h1:4ZmaBdL8Ng/ajrgKqY5jfvzqMXbrDcBsUGXOT9aqTtI= -cloud.google.com/go/trace v1.11.2/go.mod h1:bn7OwXd4pd5rFuAnTrzBuoZ4ax2XQeG3qNgYmfCy0Io= +cloud.google.com/go/trace v1.11.3 h1:c+I4YFjxRQjvAhRmSsmjpASUKq88chOX854ied0K/pE= +cloud.google.com/go/trace v1.11.3/go.mod h1:pt7zCYiDSQjC9Y2oqCsh9jF4GStB/hmjrYLsxRR27q8= cloud.google.com/go/translate v1.3.0/go.mod h1:gzMUwRjvOqj5i69y/LYLd8RrNQk+hOmIXTi9+nb3Djs= cloud.google.com/go/translate v1.4.0/go.mod h1:06Dn/ppvLD6WvA5Rhdp029IX2Mi3Mn7fpMRLPvXT5Wg= cloud.google.com/go/translate v1.5.0/go.mod h1:29YDSYveqqpA1CQFD7NQuP49xymq17RXNaUDdc0mNu0= @@ -625,14 +625,14 @@ github.com/Azure/go-ansiterm v0.0.0-20230124172434-306776ec8161 h1:L/gRVlceqvL25 github.com/Azure/go-ansiterm v0.0.0-20230124172434-306776ec8161/go.mod h1:xomTg63KZ2rFqZQzSB4Vz2SUXa1BpHTVz9L5PTmPC4E= github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo= -github.com/GoogleCloudPlatform/opentelemetry-operations-go/detectors/gcp v1.25.0 h1:3c8yed4lgqTt+oTQ+JNMDo+F4xprBf+O/il4ZC0nRLw= -github.com/GoogleCloudPlatform/opentelemetry-operations-go/detectors/gcp v1.25.0/go.mod h1:obipzmGjfSjam60XLwGfqUkJsfiheAl+TUjG+4yzyPM= -github.com/GoogleCloudPlatform/opentelemetry-operations-go/exporter/metric v0.48.1 h1:UQ0AhxogsIRZDkElkblfnwjc3IaltCm2HUMvezQaL7s= -github.com/GoogleCloudPlatform/opentelemetry-operations-go/exporter/metric v0.48.1/go.mod h1:jyqM3eLpJ3IbIFDTKVz2rF9T/xWGW0rIriGwnz8l9Tk= -github.com/GoogleCloudPlatform/opentelemetry-operations-go/internal/cloudmock v0.48.1 h1:oTX4vsorBZo/Zdum6OKPA4o7544hm6smoRv1QjpTwGo= -github.com/GoogleCloudPlatform/opentelemetry-operations-go/internal/cloudmock v0.48.1/go.mod h1:0wEl7vrAD8mehJyohS9HZy+WyEOaQO2mJx86Cvh93kM= -github.com/GoogleCloudPlatform/opentelemetry-operations-go/internal/resourcemapping v0.48.1 h1:8nn+rsCvTq9axyEh382S0PFLBeaFwNsT43IrPWzctRU= -github.com/GoogleCloudPlatform/opentelemetry-operations-go/internal/resourcemapping v0.48.1/go.mod h1:viRWSEhtMZqz1rhwmOVKkWl6SwmVowfL9O2YR5gI2PE= +github.com/GoogleCloudPlatform/opentelemetry-operations-go/detectors/gcp v1.26.0 h1:f2Qw/Ehhimh5uO1fayV0QIW7DShEQqhtUfhYc+cBPlw= +github.com/GoogleCloudPlatform/opentelemetry-operations-go/detectors/gcp v1.26.0/go.mod h1:2bIszWvQRlJVmJLiuLhukLImRjKPcYdzzsx6darK02A= +github.com/GoogleCloudPlatform/opentelemetry-operations-go/exporter/metric v0.49.0 h1:o90wcURuxekmXrtxmYWTyNla0+ZEHhud6DI1ZTxd1vI= +github.com/GoogleCloudPlatform/opentelemetry-operations-go/exporter/metric v0.49.0/go.mod h1:6fTWu4m3jocfUZLYF5KsZC1TUfRvEjs7lM4crme/irw= +github.com/GoogleCloudPlatform/opentelemetry-operations-go/internal/cloudmock v0.49.0 h1:jJKWl98inONJAr/IZrdFQUWcwUO95DLY1XMD1ZIut+g= +github.com/GoogleCloudPlatform/opentelemetry-operations-go/internal/cloudmock v0.49.0/go.mod h1:l2fIqmwB+FKSfvn3bAD/0i+AXAxhIZjTK2svT/mgUXs= +github.com/GoogleCloudPlatform/opentelemetry-operations-go/internal/resourcemapping v0.49.0 h1:GYUJLfvd++4DMuMhCFLgLXvFwofIxh/qOwoGuS/LTew= +github.com/GoogleCloudPlatform/opentelemetry-operations-go/internal/resourcemapping v0.49.0/go.mod h1:wRbFgBQUVm1YXrvWKofAEmq9HNJTDphbAaJSSX01KUI= github.com/JohnCGriffin/overflow v0.0.0-20211019200055-46fa312c352c/go.mod h1:X0CRv0ky0k6m906ixxpzmDRLvX58TFUKS2eePweuyxk= github.com/Masterminds/semver v1.5.0 h1:H65muMkzWKEuNDnfl9d70GUjFniHKHRbFPGBuZ3QEww= github.com/Masterminds/semver/v3 v3.3.0 h1:B8LGeaivUe71a5qox1ICM/JLl0NqZSW5CHyL+hmvYS0= @@ -667,8 +667,8 @@ github.com/aquasecurity/iamgo v0.0.10/go.mod h1:GI9IQJL2a+C+V2+i3vcwnNKuIJXZ+HAf github.com/aquasecurity/jfather v0.0.8 h1:tUjPoLGdlkJU0qE7dSzd1MHk2nQFNPR0ZfF+6shaExE= github.com/aquasecurity/jfather v0.0.8/go.mod h1:Ag+L/KuR/f8vn8okUi8Wc1d7u8yOpi2QTaGX10h71oY= github.com/aws/aws-sdk-go v1.44.122/go.mod h1:y4AeaBuwd2Lk+GepC1E9v0qOiTws0MIWAX4oIKwKHZo= -github.com/aws/aws-sdk-go v1.55.6 h1:cSg4pvZ3m8dgYcgqB97MrcdjUmZ1BeMYKUxMMB89IPk= -github.com/aws/aws-sdk-go v1.55.6/go.mod h1:eRwEWoyTWFMVYVQzKMNHWP5/RV4xIUGMQfXQHfHkpNU= +github.com/aws/aws-sdk-go v1.55.7 h1:UJrkFq7es5CShfBwlWAC8DA077vp8PyVbQd3lqLiztE= +github.com/aws/aws-sdk-go v1.55.7/go.mod h1:eRwEWoyTWFMVYVQzKMNHWP5/RV4xIUGMQfXQHfHkpNU= github.com/aymanbagabas/go-osc52/v2 v2.0.1 h1:HwpRHbFMcZLEVr42D4p7XBqjyuxQH5SMiErDT4WkJ2k= github.com/aymanbagabas/go-osc52/v2 v2.0.1/go.mod h1:uYgXzlJ7ZpABp8OJ+exZzJJhRNQ2ASbcXHWsFqH8hp8= github.com/bgentry/go-netrc v0.0.0-20140422174119-9fd32a8b3d3d h1:xDfNPAt8lFiC1UJrqV3uuy861HCTo708pDMbjHHdCas= @@ -681,7 +681,6 @@ github.com/cenkalti/backoff/v4 v4.3.0 h1:MyRJ/UdXutAwSAT+s3wNd7MfTIcy71VQueUuFK3 github.com/cenkalti/backoff/v4 v4.3.0/go.mod h1:Y3VNntkOUPxTVeUxJ/G5vcM//AlwfmyYozVcomhLiZE= github.com/census-instrumentation/opencensus-proto v0.2.1/go.mod h1:f6KPmirojxKA12rnyqOA5BBL4O983OfeGPqjHWSTneU= github.com/census-instrumentation/opencensus-proto v0.3.0/go.mod h1:f6KPmirojxKA12rnyqOA5BBL4O983OfeGPqjHWSTneU= -github.com/census-instrumentation/opencensus-proto v0.4.1 h1:iKLQ0xPNFxR/2hzXZMrBo8f1j86j5WHzznCCQxV/b8g= github.com/census-instrumentation/opencensus-proto v0.4.1/go.mod h1:4T9NM4+4Vw91VeyqjLS6ao50K5bOcLKN6Q42XnYaRYw= github.com/cespare/xxhash v1.1.0/go.mod h1:XrSqR1VqqWfGrhpAt58auRo0WTKS1nRRg3ghfAqPWnc= github.com/cespare/xxhash/v2 v2.1.1/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= @@ -695,8 +694,8 @@ github.com/chzyer/logex v1.1.10/go.mod h1:+Ywpsq7O8HXn0nuIou7OrIPyXbp3wmkHB+jjWR github.com/chzyer/readline v0.0.0-20180603132655-2972be24d48e/go.mod h1:nSuG5e5PlCu98SY8svDHJxuZscDgtXS6KTTbou5AhLI= github.com/chzyer/test v0.0.0-20180213035817-a1ea475d72b1/go.mod h1:Q3SI9o4m/ZMnBNeIyt5eFwwo7qiLfzFZmjNmxjkiQlU= github.com/client9/misspell v0.3.4/go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDkc90ppPyw= -github.com/cloudflare/circl v1.6.0 h1:cr5JKic4HI+LkINy2lg3W2jF8sHCVTBncJr5gIIq7qk= -github.com/cloudflare/circl v1.6.0/go.mod h1:uddAzsPgqdMAYatqJ0lsjX1oECcQLIlRpzZh3pJrofs= +github.com/cloudflare/circl v1.6.1 h1:zqIqSPIndyBh1bjLVVDHMPpVKqp8Su/V+6MeDzzQBQ0= +github.com/cloudflare/circl v1.6.1/go.mod h1:uddAzsPgqdMAYatqJ0lsjX1oECcQLIlRpzZh3pJrofs= github.com/cncf/udpa/go v0.0.0-20191209042840-269d4d468f6f/go.mod h1:M8M6+tZqaGXZJjfX53e64911xZQV5JYwmTeXPW+k8Sc= github.com/cncf/udpa/go v0.0.0-20200629203442-efcf912fb354/go.mod h1:WmhPx2Nbnhtbo57+VJT5O0JRkEi1Wbu0z5j0R8u5Hbk= github.com/cncf/udpa/go v0.0.0-20201120205902-5459f2c99403/go.mod h1:WmhPx2Nbnhtbo57+VJT5O0JRkEi1Wbu0z5j0R8u5Hbk= @@ -710,8 +709,8 @@ github.com/cncf/xds/go v0.0.0-20211011173535-cb28da3451f1/go.mod h1:eXthEFrGJvWH github.com/cncf/xds/go v0.0.0-20220314180256-7f1daf1720fc/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= github.com/cncf/xds/go v0.0.0-20230105202645-06c439db220b/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= github.com/cncf/xds/go v0.0.0-20230607035331-e9ce68804cb4/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= -github.com/cncf/xds/go v0.0.0-20240905190251-b4127c9b8d78 h1:QVw89YDxXxEe+l8gU8ETbOasdwEV+avkR75ZzsVV9WI= -github.com/cncf/xds/go v0.0.0-20240905190251-b4127c9b8d78/go.mod h1:W+zGtBO5Y1IgJhy4+A9GOqVhqLpfZi+vwmdNXUehLA8= +github.com/cncf/xds/go v0.0.0-20250121191232-2f005788dc42 h1:Om6kYQYDUk5wWbT0t0q6pvyM49i9XZAv9dDrkDA7gjk= +github.com/cncf/xds/go v0.0.0-20250121191232-2f005788dc42/go.mod h1:W+zGtBO5Y1IgJhy4+A9GOqVhqLpfZi+vwmdNXUehLA8= github.com/coder/guts v1.5.0 h1:a94apf7xMf5jDdg1bIHzncbRiTn3+BvBZgrFSDbUnyI= github.com/coder/guts v1.5.0/go.mod h1:0Sbv5Kp83u1Nl7MIQiV2zmacJ3o02I341bkWkjWXSUQ= github.com/coder/pretty v0.0.0-20230908205945-e89ba86370e0 h1:3A0ES21Ke+FxEM8CXx9n47SZOKOpgSE1bbJzlE4qPVs= @@ -720,8 +719,8 @@ github.com/coder/serpent v0.10.0 h1:ofVk9FJXSek+SmL3yVE3GoArP83M+1tX+H7S4t8BSuM= github.com/coder/serpent v0.10.0/go.mod h1:cZFW6/fP+kE9nd/oRkEHJpG6sXCtQ+AX7WMMEHv0Y3Q= github.com/coder/terraform-provider-coder/v2 v2.4.2 h1:41SJkgwgiA555kwQzGIQcNS3bCm12sVMUmBSa5zGr+A= github.com/coder/terraform-provider-coder/v2 v2.4.2/go.mod h1:2kaBpn5k9ZWtgKq5k4JbkVZG9DzEqR4mJSmpdshcO+s= -github.com/coder/trivy v0.0.0-20250409153844-e6b004bc465a h1:yryP7e+IQUAArlycH4hQrjXQ64eRNbxsV5/wuVXHgME= -github.com/coder/trivy v0.0.0-20250409153844-e6b004bc465a/go.mod h1:dDvq9axp3kZsT63gY2Znd1iwzfqDq3kXbQnccIrjRYY= +github.com/coder/trivy v0.0.0-20250527170238-9416a59d7019 h1:MHkv/W7l9eRAN9gOG0qZ1TLRGWIIfNi92273vPAQ8Fs= +github.com/coder/trivy v0.0.0-20250527170238-9416a59d7019/go.mod h1:eqk+w9RLBmbd/cB5XfPZFuVn77cf/A6fB7qmEVeSmXk= github.com/coder/websocket v1.8.13 h1:f3QZdXy7uGVz+4uCJy2nTZyM0yTBj8yANEHhqlXZ9FE= github.com/coder/websocket v1.8.13/go.mod h1:LNVeNrXQZfe5qhS9ALED3uA+l5pPqvwXg3CKoDBB2gs= github.com/containerd/log v0.1.0 h1:TCJt7ioM2cr/tfR8GPbGf9/VRAX8D2B4PjzCpfX540I= @@ -741,8 +740,8 @@ github.com/distribution/reference v0.6.0 h1:0IXCQ5g4/QMHHkarYzh5l+u8T3t73zM5Qvfr github.com/distribution/reference v0.6.0/go.mod h1:BbU0aIcezP1/5jX/8MP0YiH4SdvB5Y4f/wlDRiLyi3E= github.com/dlclark/regexp2 v1.11.4 h1:rPYF9/LECdNymJufQKmri9gV604RvvABwgOA8un7yAo= github.com/dlclark/regexp2 v1.11.4/go.mod h1:DHkYz0B9wPfa6wondMfaivmHpzrQ3v9q8cnmRbL6yW8= -github.com/docker/docker v28.0.4+incompatible h1:JNNkBctYKurkw6FrHfKqY0nKIDf5nrbxjVBtS+cdcok= -github.com/docker/docker v28.0.4+incompatible/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk= +github.com/docker/docker v28.1.1+incompatible h1:49M11BFLsVO1gxY9UX9p/zwkE/rswggs8AdFmXQw51I= +github.com/docker/docker v28.1.1+incompatible/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk= github.com/docker/go-connections v0.5.0 h1:USnMq7hx7gwdVZq1L49hLXaFtUdTADjXGp+uj1Br63c= github.com/docker/go-connections v0.5.0/go.mod h1:ov60Kzw0kKElRwhNs9UlUHAE/F9Fe6GLaXnqyDdmEXc= github.com/docker/go-units v0.5.0 h1:69rxXcBk27SvSaaxTtLh/8llcHD8vYHT7WSdRZ/jvr4= @@ -766,14 +765,18 @@ github.com/envoyproxy/go-control-plane v0.9.10-0.20210907150352-cf90f659a021/go. github.com/envoyproxy/go-control-plane v0.10.2-0.20220325020618-49ff273808a1/go.mod h1:KJwIaB5Mv44NWtYuAOFCVOjcI94vtpEz2JU/D2v6IjE= github.com/envoyproxy/go-control-plane v0.10.3/go.mod h1:fJJn/j26vwOu972OllsvAgJJM//w9BV6Fxbg2LuVd34= github.com/envoyproxy/go-control-plane v0.11.1-0.20230524094728-9239064ad72f/go.mod h1:sfYdkwUW4BA3PbKjySwjJy+O4Pu0h62rlqCMHNk+K+Q= -github.com/envoyproxy/go-control-plane v0.13.1 h1:vPfJZCkob6yTMEgS+0TwfTUfbHjfy/6vOJ8hUWX/uXE= -github.com/envoyproxy/go-control-plane v0.13.1/go.mod h1:X45hY0mufo6Fd0KW3rqsGvQMw58jvjymeCzBU3mWyHw= +github.com/envoyproxy/go-control-plane v0.13.4 h1:zEqyPVyku6IvWCFwux4x9RxkLOMUL+1vC9xUFv5l2/M= +github.com/envoyproxy/go-control-plane v0.13.4/go.mod h1:kDfuBlDVsSj2MjrLEtRWtHlsWIFcGyB2RMO44Dc5GZA= +github.com/envoyproxy/go-control-plane/envoy v1.32.4 h1:jb83lalDRZSpPWW2Z7Mck/8kXZ5CQAFYVjQcdVIr83A= +github.com/envoyproxy/go-control-plane/envoy v1.32.4/go.mod h1:Gzjc5k8JcJswLjAx1Zm+wSYE20UrLtt7JZMWiWQXQEw= +github.com/envoyproxy/go-control-plane/ratelimit v0.1.0 h1:/G9QYbddjL25KvtKTv3an9lx6VBE2cnb8wp1vEGNYGI= +github.com/envoyproxy/go-control-plane/ratelimit v0.1.0/go.mod h1:Wk+tMFAFbCXaJPzVVHnPgRKdUdwW/KdbRt94AzgRee4= github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c= github.com/envoyproxy/protoc-gen-validate v0.6.7/go.mod h1:dyJXwwfPK2VSqiB9Klm1J6romD608Ba7Hij42vrOBCo= github.com/envoyproxy/protoc-gen-validate v0.9.1/go.mod h1:OKNgG7TCp5pF4d6XftA0++PMirau2/yoOwVac3AbF2w= github.com/envoyproxy/protoc-gen-validate v0.10.1/go.mod h1:DRjgyB0I43LtJapqN6NiRwroiAU2PaFuvk/vjgh61ss= -github.com/envoyproxy/protoc-gen-validate v1.1.0 h1:tntQDh69XqOCOZsDz0lVJQez/2L6Uu2PdjCQwWCJ3bM= -github.com/envoyproxy/protoc-gen-validate v1.1.0/go.mod h1:sXRDRVmzEbkM7CVcM06s9shE/m23dg3wzjl0UWqJ2q4= +github.com/envoyproxy/protoc-gen-validate v1.2.1 h1:DEo3O99U8j4hBFwbJfrz9VtgcDfUKS7KJ7spH3d86P8= +github.com/envoyproxy/protoc-gen-validate v1.2.1/go.mod h1:d/C80l/jxXLdfEIhX1W2TmLfsJ31lvEjwamM4DxlWXU= github.com/fatih/color v1.7.0/go.mod h1:Zm6kSWBoL9eyXnKyktHP6abPY2pDugNf5KwzbycvMj4= github.com/fatih/color v1.13.0/go.mod h1:kLAiJbzzSOZDVNGyDpeOxJ47H46qBXwg5ILebYFFOfk= github.com/fatih/color v1.18.0 h1:S8gINlzdQ840/4pfAwic/ZE0djQEH3wM94VfqLTZcOM= @@ -796,11 +799,13 @@ github.com/go-git/gcfg v1.5.1-0.20230307220236-3a3c6141e376 h1:+zs/tPmkDkHx3U66D github.com/go-git/gcfg v1.5.1-0.20230307220236-3a3c6141e376/go.mod h1:an3vInlBmSxCcxctByoQdvwPiA7DTK7jaaFDBTtu0ic= github.com/go-git/go-billy/v5 v5.6.2 h1:6Q86EsPXMa7c3YZ3aLAQsMA0VlWmy43r6FHqa/UNbRM= github.com/go-git/go-billy/v5 v5.6.2/go.mod h1:rcFC2rAsp/erv7CMz9GczHcuD0D32fWzH+MJAU+jaUU= -github.com/go-git/go-git/v5 v5.14.0 h1:/MD3lCrGjCen5WfEAzKg00MJJffKhC8gzS80ycmCi60= -github.com/go-git/go-git/v5 v5.14.0/go.mod h1:Z5Xhoia5PcWA3NF8vRLURn9E5FRhSl7dGj9ItW3Wk5k= +github.com/go-git/go-git/v5 v5.16.0 h1:k3kuOEpkc0DeY7xlL6NaaNg39xdgQbtH5mwCafHO9AQ= +github.com/go-git/go-git/v5 v5.16.0/go.mod h1:4Ge4alE/5gPs30F2H1esi2gPd69R0C39lolkucHBOp8= github.com/go-gl/glfw v0.0.0-20190409004039-e6da0acd62b1/go.mod h1:vR7hzQXu2zJy9AVAgeJqvqgH9Q5CA+iKCZ2gyEVpxRU= github.com/go-gl/glfw/v3.3/glfw v0.0.0-20191125211704-12ad95a8df72/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8= github.com/go-gl/glfw/v3.3/glfw v0.0.0-20200222043503-6f7a984d4dc4/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8= +github.com/go-jose/go-jose/v4 v4.0.5 h1:M6T8+mKZl/+fNNuFHvGIzDz7BTLQPIounk/b9dw3AaE= +github.com/go-jose/go-jose/v4 v4.0.5/go.mod h1:s3P1lRrkT8igV8D9OjyL4WRyHvjB6a4JSllnOrmmBOA= github.com/go-latex/latex v0.0.0-20210118124228-b3d85cf34e07/go.mod h1:CO1AlKB2CSIqUrmQPqA0gdRIlnLEY0gK5JGjh37zN5U= github.com/go-latex/latex v0.0.0-20210823091927-c0d11ff05a81/go.mod h1:SX0U8uGpxhq9o2S/CELCSUxEWWAuoCUcVCQWv7G2OCk= github.com/go-logr/logr v1.2.2/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= @@ -921,8 +926,8 @@ github.com/googleapis/enterprise-certificate-proxy v0.1.0/go.mod h1:17drOmN3MwGY github.com/googleapis/enterprise-certificate-proxy v0.2.0/go.mod h1:8C0jb7/mgJe/9KK8Lm7X9ctZC2t60YyIpYEI16jx0Qg= github.com/googleapis/enterprise-certificate-proxy v0.2.1/go.mod h1:AwSRAtLfXpU5Nm3pW+v7rGDHp09LsPtGY9MduiEsR9k= github.com/googleapis/enterprise-certificate-proxy v0.2.3/go.mod h1:AwSRAtLfXpU5Nm3pW+v7rGDHp09LsPtGY9MduiEsR9k= -github.com/googleapis/enterprise-certificate-proxy v0.3.4 h1:XYIDZApgAnrN1c855gTgghdIA6Stxb52D5RnLI1SLyw= -github.com/googleapis/enterprise-certificate-proxy v0.3.4/go.mod h1:YKe7cfqYXjKGpGvmSg28/fFvhNzinZQm8DGnaburhGA= +github.com/googleapis/enterprise-certificate-proxy v0.3.6 h1:GW/XbdyBFQ8Qe+YAmFU9uHLo7OnF5tL52HFAgMmyrf4= +github.com/googleapis/enterprise-certificate-proxy v0.3.6/go.mod h1:MkHOF77EYAE7qfSuSS9PU6g4Nt4e11cnsDUowfwewLA= github.com/googleapis/gax-go/v2 v2.0.4/go.mod h1:0Wqv26UfaUD9n4G6kQubkQ+KchISgw+vpHVxEJEs9eg= github.com/googleapis/gax-go/v2 v2.0.5/go.mod h1:DWXyrwAJ9X0FpwwEdw+IPEYBICEFu5mhpdKc/us6bOk= github.com/googleapis/gax-go/v2 v2.1.0/go.mod h1:Q3nei7sK6ybPYH7twZdmQpAd1MKb7pfu6SK+H1/DsU0= @@ -1014,8 +1019,8 @@ github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+o github.com/klauspost/asmfmt v1.3.2/go.mod h1:AG8TuvYojzulgDAMCnYn50l/5QV3Bs/tp6j0HLHbNSE= github.com/klauspost/compress v1.15.9/go.mod h1:PhcZ0MbTNciWF3rruxRgKxI5NkcHHrHUDtV4Yw2GlzU= github.com/klauspost/compress v1.15.11/go.mod h1:QPwzmACJjUTFsnSHH934V6woptycfrDDJnH7hvFVbGM= -github.com/klauspost/compress v1.17.11 h1:In6xLpyWOi1+C7tXUUWv2ot1QvBjxevKAaI6IXrJmUc= -github.com/klauspost/compress v1.17.11/go.mod h1:pMDklpSncoRMuLFrf1W9Ss9KT+0rH90U12bZKk7uwG0= +github.com/klauspost/compress v1.18.0 h1:c/Cqfb0r+Yi+JtIEq73FWXVkRonBlf0CRNYc8Zttxdo= +github.com/klauspost/compress v1.18.0/go.mod h1:2Pp+KzxcywXVXMr50+X0Q/Lsb43OQHYWRCY2AiWywWQ= github.com/klauspost/cpuid/v2 v2.0.9/go.mod h1:FInQzS24/EEf25PyTYn52gqo7WaD8xa0213Md/qVLRg= github.com/kr/fs v0.1.0/go.mod h1:FFnZGqtBN9Gxj7eW1uZ42v5BccTP0vu6NEaFoC2HwRg= github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo= @@ -1036,8 +1041,8 @@ github.com/lufia/plan9stats v0.0.0-20240226150601-1dcf7310316a/go.mod h1:ilwx/Dt github.com/lyft/protoc-gen-star v0.6.0/go.mod h1:TGAoBVkt8w7MPG72TrKIu85MIdXwDuzJYeZuUPFPNwA= github.com/lyft/protoc-gen-star v0.6.1/go.mod h1:TGAoBVkt8w7MPG72TrKIu85MIdXwDuzJYeZuUPFPNwA= github.com/lyft/protoc-gen-star/v2 v2.0.1/go.mod h1:RcCdONR2ScXaYnQC5tUzxzlpA3WVYF7/opLeUgcQs/o= -github.com/magiconair/properties v1.8.9 h1:nWcCbLq1N2v/cpNsy5WvQ37Fb+YElfq20WJ/a8RkpQM= -github.com/magiconair/properties v1.8.9/go.mod h1:Dhd985XPs7jluiymwWYZ0G4Z61jb3vdS329zhj2hYo0= +github.com/magiconair/properties v1.8.10 h1:s31yESBquKXCV9a/ScB3ESkOjUYYv+X0rg8SYxI99mE= +github.com/magiconair/properties v1.8.10/go.mod h1:Dhd985XPs7jluiymwWYZ0G4Z61jb3vdS329zhj2hYo0= github.com/mattn/go-colorable v0.0.9/go.mod h1:9vuHe8Xs5qXnSaW/c/ABM9alt+Vo+STaOChaDxuIBZU= github.com/mattn/go-colorable v0.1.9/go.mod h1:u6P/XSegPjTcexA+o6vUJrdnUu04hMope9wVRipJSqc= github.com/mattn/go-colorable v0.1.12/go.mod h1:u5H1YNBxpqRaxsYJYSkiCWKzEfiAb1Gb520KVy5xxl4= @@ -1069,12 +1074,14 @@ github.com/mitchellh/reflectwalk v1.0.2 h1:G2LzWKi524PWgd3mLHV8Y5k7s6XUvT0Gef6zx github.com/mitchellh/reflectwalk v1.0.2/go.mod h1:mSTlrgnPZtwu0c4WaC2kGObEpuNDbx0jmZXqmk4esnw= github.com/moby/docker-image-spec v1.3.1 h1:jMKff3w6PgbfSa69GfNg+zN/XLhfXJGnEx3Nl2EsFP0= github.com/moby/docker-image-spec v1.3.1/go.mod h1:eKmb5VW8vQEh/BAr2yvVNvuiJuY6UIocYsFu/DxxRpo= +github.com/moby/go-archive v0.1.0 h1:Kk/5rdW/g+H8NHdJW2gsXyZ7UnzvJNOy6VKJqueWdcQ= +github.com/moby/go-archive v0.1.0/go.mod h1:G9B+YoujNohJmrIYFBpSd54GTUB4lt9S+xVQvsJyFuo= github.com/moby/patternmatcher v0.6.0 h1:GmP9lR19aU5GqSSFko+5pRqHi+Ohk1O69aFiKkVGiPk= github.com/moby/patternmatcher v0.6.0/go.mod h1:hDPoyOpDY7OrrMDLaYoY3hf52gNCR/YOUYxkhApJIxc= github.com/moby/sys/sequential v0.6.0 h1:qrx7XFUd/5DxtqcoH1h438hF5TmOvzC/lspjy7zgvCU= github.com/moby/sys/sequential v0.6.0/go.mod h1:uyv8EUTrca5PnDsdMGXhZe6CCe8U/UiTWd+lL+7b/Ko= -github.com/moby/sys/user v0.3.0 h1:9ni5DlcW5an3SvRSx4MouotOygvzaXbaSrc/wGDFWPo= -github.com/moby/sys/user v0.3.0/go.mod h1:bG+tYYYJgaMtRKgEmuueC0hJEAZWwtIbZTB+85uoHjs= +github.com/moby/sys/user v0.4.0 h1:jhcMKit7SA80hivmFJcbB1vqmw//wU61Zdui2eQXuMs= +github.com/moby/sys/user v0.4.0/go.mod h1:bG+tYYYJgaMtRKgEmuueC0hJEAZWwtIbZTB+85uoHjs= github.com/moby/sys/userns v0.1.0 h1:tVLXkFOxVu9A64/yh59slHVv9ahO9UIev4JZusOLG/g= github.com/moby/sys/userns v0.1.0/go.mod h1:IHUYgu/kao6N8YZlp9Cf444ySSvCmDlmzUcYfDHOl28= github.com/moby/term v0.5.0 h1:xt8Q1nalod/v7BqbG21f8mQPqH+xAaC9C3N3wfWbVP0= @@ -1137,8 +1144,8 @@ github.com/rogpeppe/go-internal v1.13.1 h1:KvO1DLK/DRN07sQ1LQKScxyZJuNnedQ5/wKSR github.com/rogpeppe/go-internal v1.13.1/go.mod h1:uMEvuHeurkdAXX61udpOXGD/AzZDWNMNyH2VO9fmH0o= github.com/ruudk/golang-pdf417 v0.0.0-20181029194003-1af4ab5afa58/go.mod h1:6lfFZQK844Gfx8o5WFuvpxWRwnSoipWe/p622j1v06w= github.com/ruudk/golang-pdf417 v0.0.0-20201230142125-a7e3863a1245/go.mod h1:pQAZKsJ8yyVxGRWYNEm9oFB8ieLgKFnamEyDmSA0BRk= -github.com/samber/lo v1.49.1 h1:4BIFyVfuQSEpluc7Fua+j1NolZHiEHEpaSEKdsH0tew= -github.com/samber/lo v1.49.1/go.mod h1:dO6KHFzUKXgP8LDhU0oI8d2hekjXnGOu0DB8Jecxd6o= +github.com/samber/lo v1.50.0 h1:XrG0xOeHs+4FQ8gJR97zDz5uOFMW7OwFWiFVzqopKgY= +github.com/samber/lo v1.50.0/go.mod h1:RjZyNk6WSnUFRKK6EyOhsRJMqft3G+pg7dCWHQCWvsc= github.com/sergi/go-diff v1.3.2-0.20230802210424-5b0b94c5c0d3 h1:n661drycOFuPLCN3Uc8sB6B/s6Z4t2xvBgU1htSHuq8= github.com/sergi/go-diff v1.3.2-0.20230802210424-5b0b94c5c0d3/go.mod h1:A0bzQcvG0E7Rwjx0REVgAGH58e96+X0MeOfepqsbeW4= github.com/shirou/gopsutil/v4 v4.25.1 h1:QSWkTc+fu9LTAWfkZwZ6j8MSUk4A2LV7rbH0ZqmLjXs= @@ -1155,6 +1162,8 @@ github.com/spf13/afero v1.6.0/go.mod h1:Ai8FlHk4v/PARR026UzYexafAt9roJ7LcLMAmO6Z github.com/spf13/afero v1.9.2/go.mod h1:iUV7ddyEEZPO5gA3zD4fJt6iStLlL+Lg4m2cihcDf8Y= github.com/spf13/pflag v1.0.6 h1:jFzHGLGAlb3ruxLB8MhbI6A8+AQX/2eW4qeyNZXNp2o= github.com/spf13/pflag v1.0.6/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg= +github.com/spiffe/go-spiffe/v2 v2.5.0 h1:N2I01KCUkv1FAjZXJMwh95KK1ZIQLYbPfhaxw8WS0hE= +github.com/spiffe/go-spiffe/v2 v2.5.0/go.mod h1:P+NxobPc6wXhVtINNtFjNWGBTreew1GBUCwT2wPmb7g= github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/objx v0.4.0/go.mod h1:YvHI0jy2hoMjB+UWwv71VJQ9isScKT/TqJzVSSt89Yw= github.com/stretchr/objx v0.5.0/go.mod h1:Yh+to48EsGEfYuaHDzXPcE3xhTkx73EhmCGUpEOglKo= @@ -1170,10 +1179,10 @@ github.com/stretchr/testify v1.8.1/go.mod h1:w2LPCIKwWwSfY2zedu0+kehJoqGctiVI29o github.com/stretchr/testify v1.8.3/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo= github.com/stretchr/testify v1.10.0 h1:Xv5erBjTwe/5IxqUQTdXv5kgmIvbHo3QQyRwhJsOfJA= github.com/stretchr/testify v1.10.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY= -github.com/testcontainers/testcontainers-go v0.36.0 h1:YpffyLuHtdp5EUsI5mT4sRw8GZhO/5ozyDT1xWGXt00= -github.com/testcontainers/testcontainers-go v0.36.0/go.mod h1:yk73GVJ0KUZIHUtFna6MO7QS144qYpoY8lEEtU9Hed0= -github.com/testcontainers/testcontainers-go/modules/localstack v0.36.0 h1:zVwbe46NYg2vtC26aF0ndClK5S9J7TgAliQbTLyHm+0= -github.com/testcontainers/testcontainers-go/modules/localstack v0.36.0/go.mod h1:rxyzj5nX/OUn7QK5PVxKYHJg1eeNtNzWMX2hSbNNJk0= +github.com/testcontainers/testcontainers-go v0.37.0 h1:L2Qc0vkTw2EHWQ08djon0D2uw7Z/PtHS/QzZZ5Ra/hg= +github.com/testcontainers/testcontainers-go v0.37.0/go.mod h1:QPzbxZhQ6Bclip9igjLFj6z0hs01bU8lrl2dHQmgFGM= +github.com/testcontainers/testcontainers-go/modules/localstack v0.37.0 h1:nPuxUYseqS0eYJg7KDJd95PhoMhdpTnSNtkDLwWFngo= +github.com/testcontainers/testcontainers-go/modules/localstack v0.37.0/go.mod h1:Mw+N4qqJ5iWbg45yWsdLzICfeCEwvYNudfAHHFqCU8Q= github.com/tklauser/go-sysconf v0.3.13 h1:GBUpcahXSpR2xN01jhkNAbTLRk2Yzgggk8IM08lq3r4= github.com/tklauser/go-sysconf v0.3.13/go.mod h1:zwleP4Q4OehZHGn4CYZDipCgg9usW5IJePewFCGVEa0= github.com/tklauser/numcpus v0.7.0 h1:yjuerZP127QG9m5Zh/mSO4wqurYil27tHrqwRoRjpr4= @@ -1199,13 +1208,15 @@ github.com/yuin/goldmark v1.4.1/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1 github.com/yuin/goldmark v1.4.13/go.mod h1:6yULJ656Px+3vBD8DxQVa3kxgyrAnzto9xy5taEt/CY= github.com/yusufpapurcu/wmi v1.2.4 h1:zFUKzehAFReQwLys1b/iSMl+JQGSCSjtVqQn9bBrPo0= github.com/yusufpapurcu/wmi v1.2.4/go.mod h1:SBZ9tNy3G9/m5Oi98Zks0QjeHVDvuK0qfxQmPyzfmi0= -github.com/zclconf/go-cty v1.16.2 h1:LAJSwc3v81IRBZyUVQDUdZ7hs3SYs9jv0eZJDWHD/70= -github.com/zclconf/go-cty v1.16.2/go.mod h1:VvMs5i0vgZdhYawQNq5kePSpLAoz8u1xvZgrPIxfnZE= +github.com/zclconf/go-cty v1.16.3 h1:osr++gw2T61A8KVYHoQiFbFd1Lh3JOCXc/jFLJXKTxk= +github.com/zclconf/go-cty v1.16.3/go.mod h1:VvMs5i0vgZdhYawQNq5kePSpLAoz8u1xvZgrPIxfnZE= github.com/zclconf/go-cty-debug v0.0.0-20240509010212-0d6042c53940 h1:4r45xpDWB6ZMSMNJFMOjqrGHynW3DIBuR2H9j0ug+Mo= github.com/zclconf/go-cty-debug v0.0.0-20240509010212-0d6042c53940/go.mod h1:CmBdvvj3nqzfzJ6nTCIwDTPZ56aVGvDrmztiO5g3qrM= github.com/zclconf/go-cty-yaml v1.1.0 h1:nP+jp0qPHv2IhUVqmQSzjvqAWcObN0KBkUl2rWBdig0= github.com/zclconf/go-cty-yaml v1.1.0/go.mod h1:9YLUH4g7lOhVWqUbctnVlZ5KLpg7JAprQNgxSZ1Gyxs= github.com/zeebo/assert v1.3.0/go.mod h1:Pq9JiuJQpG8JLJdtkwrJESF0Foym2/D9XMU5ciN/wJ0= +github.com/zeebo/errs v1.4.0 h1:XNdoD/RRMKP7HD0UhJnIzUy74ISdGGxURlYG8HSWSfM= +github.com/zeebo/errs v1.4.0/go.mod h1:sgbWHsvVuTPHcqJJGQ1WhI5KbWlHYz+2+2C/LSEtCw4= github.com/zeebo/xxh3 v1.0.2/go.mod h1:5NWz9Sef7zIDm2JHfFlcQvNekmcEl9ekUZQQKCYaDcA= go.opencensus.io v0.21.0/go.mod h1:mSImk1erAIZhrmZN+AvHh14ztQfjbGwt4TtuofqLduU= go.opencensus.io v0.22.0/go.mod h1:+kGneAE2xo2IficOXnaByMWTGM9T73dGwxeWcUqIpI8= @@ -1214,26 +1225,25 @@ go.opencensus.io v0.22.3/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw= go.opencensus.io v0.22.4/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw= go.opencensus.io v0.22.5/go.mod h1:5pWMHQbX5EPX2/62yrJeAkowc+lfs/XD7Uxpq3pI6kk= go.opencensus.io v0.23.0/go.mod h1:XItmlyltB5F7CS4xOC1DcqMoFqwtC6OG2xF7mCv7P7E= -go.opencensus.io v0.24.0 h1:y73uSU6J157QMP2kn2r30vwW1A2W2WFwSCGnAVxeaD0= go.opencensus.io v0.24.0/go.mod h1:vNK8G9p7aAivkbmorf4v+7Hgx+Zs0yY+0fOtgBfjQKo= go.opentelemetry.io/auto/sdk v1.1.0 h1:cH53jehLUN6UFLY71z+NDOiNJqDdPRaXzTel0sJySYA= go.opentelemetry.io/auto/sdk v1.1.0/go.mod h1:3wSPjt5PWp2RhlCcmmOial7AvC4DQqZb7a7wCow3W8A= -go.opentelemetry.io/contrib/detectors/gcp v1.32.0 h1:P78qWqkLSShicHmAzfECaTgvslqHxblNE9j62Ws1NK8= -go.opentelemetry.io/contrib/detectors/gcp v1.32.0/go.mod h1:TVqo0Sda4Cv8gCIixd7LuLwW4EylumVWfhjZJjDD4DU= -go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.56.0 h1:yMkBS9yViCc7U7yeLzJPM2XizlfdVvBRSmsQDWu6qc0= -go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.56.0/go.mod h1:n8MR6/liuGB5EmTETUBeU5ZgqMOlqKRxUaqPQBOANZ8= -go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.59.0 h1:CV7UdSGJt/Ao6Gp4CXckLxVRRsRgDHoI8XjbL3PDl8s= -go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.59.0/go.mod h1:FRmFuRJfag1IZ2dPkHnEoSFVgTVPUd2qf5Vi69hLb8I= +go.opentelemetry.io/contrib/detectors/gcp v1.34.0 h1:JRxssobiPg23otYU5SbWtQC//snGVIM3Tx6QRzlQBao= +go.opentelemetry.io/contrib/detectors/gcp v1.34.0/go.mod h1:cV4BMFcscUR/ckqLkbfQmF0PRsq8w/lMGzdbCSveBHo= +go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.60.0 h1:x7wzEgXfnzJcHDwStJT+mxOz4etr2EcexjqhBvmoakw= +go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.60.0/go.mod h1:rg+RlpR5dKwaS95IyyZqj5Wd4E13lk/msnTS0Xl9lJM= +go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.60.0 h1:sbiXRNDSWJOTobXh5HyQKjq6wUC5tNybqjIqDpAY4CU= +go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.60.0/go.mod h1:69uWxva0WgAA/4bu2Yy70SLDBwZXuQ6PbBpbsa5iZrQ= go.opentelemetry.io/otel v1.35.0 h1:xKWKPxrxB6OtMCbmMY021CqC45J+3Onta9MqjhnusiQ= go.opentelemetry.io/otel v1.35.0/go.mod h1:UEqy8Zp11hpkUrL73gSlELM0DupHoiq72dR+Zqel/+Y= go.opentelemetry.io/otel/exporters/stdout/stdoutmetric v1.29.0 h1:WDdP9acbMYjbKIyJUhTvtzj601sVJOqgWdUxSdR/Ysc= go.opentelemetry.io/otel/exporters/stdout/stdoutmetric v1.29.0/go.mod h1:BLbf7zbNIONBLPwvFnwNHGj4zge8uTCM/UPIVW1Mq2I= go.opentelemetry.io/otel/metric v1.35.0 h1:0znxYu2SNyuMSQT4Y9WDWej0VpcsxkuklLa4/siN90M= go.opentelemetry.io/otel/metric v1.35.0/go.mod h1:nKVFgxBZ2fReX6IlyW28MgZojkoAkJGaE8CpgeAU3oE= -go.opentelemetry.io/otel/sdk v1.34.0 h1:95zS4k/2GOy069d321O8jWgYsW3MzVV+KuSPKp7Wr1A= -go.opentelemetry.io/otel/sdk v1.34.0/go.mod h1:0e/pNiaMAqaykJGKbi+tSjWfNNHMTxoC9qANsCzbyxU= -go.opentelemetry.io/otel/sdk/metric v1.32.0 h1:rZvFnvmvawYb0alrYkjraqJq0Z4ZUJAiyYCU9snn1CU= -go.opentelemetry.io/otel/sdk/metric v1.32.0/go.mod h1:PWeZlq0zt9YkYAp3gjKZ0eicRYvOh1Gd+X99x6GHpCQ= +go.opentelemetry.io/otel/sdk v1.35.0 h1:iPctf8iprVySXSKJffSS79eOjl9pvxV9ZqOWT0QejKY= +go.opentelemetry.io/otel/sdk v1.35.0/go.mod h1:+ga1bZliga3DxJ3CQGg3updiaAJoNECOgJREo9KHGQg= +go.opentelemetry.io/otel/sdk/metric v1.35.0 h1:1RriWBmCKgkeHEhM7a2uMjMUfP7MsOF5JpUCaEqEI9o= +go.opentelemetry.io/otel/sdk/metric v1.35.0/go.mod h1:is6XYCUMpcKi+ZsOvfluY5YstFnhW0BidkR+gL+qN+w= go.opentelemetry.io/otel/trace v1.35.0 h1:dPpEfJu1sDIqruz7BHFG3c7528f6ddfSWfFDVt/xgMs= go.opentelemetry.io/otel/trace v1.35.0/go.mod h1:WUk7DtFp1Aw2MkvqGdwiXYDZZNvA/1J8o6xRXLrIkyc= go.opentelemetry.io/proto/otlp v0.7.0/go.mod h1:PqfVotwruBrMGOCsRd/89rSnXhoiJIqeYNgFYFoEGnI= @@ -1269,8 +1279,8 @@ golang.org/x/exp v0.0.0-20200119233911-0405dc783f0a/go.mod h1:2RIsYlXP63K8oxa1u0 golang.org/x/exp v0.0.0-20200207192155-f17229e696bd/go.mod h1:J/WKrq2StrnmMY6+EHIKF9dgMWnmCNThgcyBT1FY9mM= golang.org/x/exp v0.0.0-20200224162631-6cc2880d07d6/go.mod h1:3jZMyOhIsHpP37uCMkUooju7aAi5cS1Q23tOzKc+0MU= golang.org/x/exp v0.0.0-20220827204233-334a2380cb91/go.mod h1:cyybsKvd6eL0RnXn6p/Grxp8F5bW7iYuBgsNCOHpMYE= -golang.org/x/exp v0.0.0-20250106191152-7588d65b2ba8 h1:yqrTHse8TCMW1M1ZCP+VAR/l0kKxwaAIqN/il7x4voA= -golang.org/x/exp v0.0.0-20250106191152-7588d65b2ba8/go.mod h1:tujkw807nyEEAamNbDrEGzRav+ilXA7PCRAd6xsmwiU= +golang.org/x/exp v0.0.0-20250408133849-7e4ce0ab07d0 h1:R84qjqJb5nVJMxqWYb3np9L5ZsaDtB+a39EqjV0JSUM= +golang.org/x/exp v0.0.0-20250408133849-7e4ce0ab07d0/go.mod h1:S9Xr4PYopiDyqSyp5NjCrhFrqg6A5zA2E/iPHPhqnS8= golang.org/x/image v0.0.0-20180708004352-c73c2afc3b81/go.mod h1:ux5Hcp/YLpHSI86hEcLt0YII63i6oz57MZXIpbrjZUs= golang.org/x/image v0.0.0-20190227222117-0694c2d4d067/go.mod h1:kZ7UVZpmo3dzQBMxlp+ypCbDeSB+sBbTgSJuh5dn5js= golang.org/x/image v0.0.0-20190802002840-cff245a6509b/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0= @@ -1412,8 +1422,8 @@ golang.org/x/oauth2 v0.4.0/go.mod h1:RznEsdpjGAINPTOF0UH/t+xJ75L18YO3Ho6Pyn+uRec golang.org/x/oauth2 v0.5.0/go.mod h1:9/XBHVqLaWO3/BRHs5jbpYCnOZVjj5V0ndyaAM7KB4I= golang.org/x/oauth2 v0.6.0/go.mod h1:ycmewcwgD4Rpr3eZJLSB4Kyyljb3qDh40vJ8STE5HKw= golang.org/x/oauth2 v0.7.0/go.mod h1:hPLQkd9LyjfXTiRohC/41GhcFqxisoUQ99sCUOHO9x4= -golang.org/x/oauth2 v0.26.0 h1:afQXWNNaeC4nvZ0Ed9XvCCzXM6UHJG7iCg0W4fPqSBE= -golang.org/x/oauth2 v0.26.0/go.mod h1:XYTD2NtWslqkgxebSiOHnXEap4TF09sJSc7H1sXbhtI= +golang.org/x/oauth2 v0.28.0 h1:CrgCKl8PPAVtLnU3c+EDw6x11699EWlsDeWNWKdIOkc= +golang.org/x/oauth2 v0.28.0/go.mod h1:onh5ek6nERTohokkhCD/y2cV4Do3fxFHFuAejCkRWT8= golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20181108010431-42b317875d0f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20181221193216-37e7f081c4d4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= @@ -1567,8 +1577,8 @@ golang.org/x/time v0.0.0-20191024005414-555d28b269f0/go.mod h1:tRJNPiyCQ0inRvYxb golang.org/x/time v0.0.0-20220922220347-f3bd1da661af/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.1.0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.3.0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= -golang.org/x/time v0.10.0 h1:3usCWA8tQn0L8+hFJQNgzpWbd89begxN66o1Ojdn5L4= -golang.org/x/time v0.10.0/go.mod h1:3BpzKBy/shNhVucY/MWOyx10tF3SFh9QdLuxbVysPQM= +golang.org/x/time v0.11.0 h1:/bpjEDfN9tkoN/ryeYHnv5hcMlc8ncjMcM4XBk5NWV0= +golang.org/x/time v0.11.0/go.mod h1:CDIdPxbZBQxdj6cxyCIdrNogrJKMJ7pr37NYpMcMDSg= golang.org/x/tools v0.0.0-20180525024113-a5b4c53f6e8b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20190114222345-bf090417da8b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= @@ -1709,8 +1719,8 @@ google.golang.org/api v0.108.0/go.mod h1:2Ts0XTHNVWxypznxWOYUeI4g3WdP9Pk2Qk58+a/ google.golang.org/api v0.110.0/go.mod h1:7FC4Vvx1Mooxh8C5HWjzZHcavuS2f6pmJpZx60ca7iI= google.golang.org/api v0.111.0/go.mod h1:qtFHvU9mhgTJegR31csQ+rwxyUTHOKFqCKWp1J0fdw0= google.golang.org/api v0.114.0/go.mod h1:ifYI2ZsFK6/uGddGfAD5BMxlnkBqCmqHSDUVi45N5Yg= -google.golang.org/api v0.218.0 h1:x6JCjEWeZ9PFCRe9z0FBrNwj7pB7DOAqT35N+IPnAUA= -google.golang.org/api v0.218.0/go.mod h1:5VGHBAkxrA/8EFjLVEYmMUJ8/8+gWWQ3s4cFH0FxG2M= +google.golang.org/api v0.228.0 h1:X2DJ/uoWGnY5obVjewbp8icSL5U4FzuCfy9OjbLSnLs= +google.golang.org/api v0.228.0/go.mod h1:wNvRS1Pbe8r4+IfBIniV8fwCpGwTrYa+kMUDiC5z5a4= google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM= google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= google.golang.org/appengine v1.5.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= @@ -1852,12 +1862,12 @@ google.golang.org/genproto v0.0.0-20230323212658-478b75c54725/go.mod h1:UUQDJDOl google.golang.org/genproto v0.0.0-20230330154414-c0448cd141ea/go.mod h1:UUQDJDOlWu4KYeJZffbWgBkS1YFobzKbLVfK69pe0Ak= google.golang.org/genproto v0.0.0-20230331144136-dcfb400f0633/go.mod h1:UUQDJDOlWu4KYeJZffbWgBkS1YFobzKbLVfK69pe0Ak= google.golang.org/genproto v0.0.0-20230410155749-daa745c078e1/go.mod h1:nKE/iIaLqn2bQwXBg8f1g2Ylh6r5MN5CmZvuzZCgsCU= -google.golang.org/genproto v0.0.0-20241118233622-e639e219e697 h1:ToEetK57OidYuqD4Q5w+vfEnPvPpuTwedCNVohYJfNk= -google.golang.org/genproto v0.0.0-20241118233622-e639e219e697/go.mod h1:JJrvXBWRZaFMxBufik1a4RpFw4HhgVtBBWQeQgUj2cc= -google.golang.org/genproto/googleapis/api v0.0.0-20250115164207-1a7da9e5054f h1:gap6+3Gk41EItBuyi4XX/bp4oqJ3UwuIMl25yGinuAA= -google.golang.org/genproto/googleapis/api v0.0.0-20250115164207-1a7da9e5054f/go.mod h1:Ic02D47M+zbarjYYUlK57y316f2MoN0gjAwI3f2S95o= -google.golang.org/genproto/googleapis/rpc v0.0.0-20250115164207-1a7da9e5054f h1:OxYkA3wjPsZyBylwymxSHa7ViiW1Sml4ToBrncvFehI= -google.golang.org/genproto/googleapis/rpc v0.0.0-20250115164207-1a7da9e5054f/go.mod h1:+2Yz8+CLJbIfL9z73EW45avw8Lmge3xVElCP9zEKi50= +google.golang.org/genproto v0.0.0-20250303144028-a0af3efb3deb h1:ITgPrl429bc6+2ZraNSzMDk3I95nmQln2fuPstKwFDE= +google.golang.org/genproto v0.0.0-20250303144028-a0af3efb3deb/go.mod h1:sAo5UzpjUwgFBCzupwhcLcxHVDK7vG5IqI30YnwX2eE= +google.golang.org/genproto/googleapis/api v0.0.0-20250303144028-a0af3efb3deb h1:p31xT4yrYrSM/G4Sn2+TNUkVhFCbG9y8itM2S6Th950= +google.golang.org/genproto/googleapis/api v0.0.0-20250303144028-a0af3efb3deb/go.mod h1:jbe3Bkdp+Dh2IrslsFCklNhweNTBgSYanP1UXhJDhKg= +google.golang.org/genproto/googleapis/rpc v0.0.0-20250313205543-e70fdf4c4cb4 h1:iK2jbkWL86DXjEx0qiHcRE9dE4/Ahua5k6V8OWFb//c= +google.golang.org/genproto/googleapis/rpc v0.0.0-20250313205543-e70fdf4c4cb4/go.mod h1:LuRYeWDFV6WOn90g357N17oMCaxpgCnbi/44qJvDn2I= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= google.golang.org/grpc v1.20.1/go.mod h1:10oTOabMzJvdu6/UiuZezV6QK5dSlG84ov/aaiqXj38= google.golang.org/grpc v1.21.1/go.mod h1:oYelfM1adQP15Ek0mdvEgi9Df8B9CZIaU1084ijfRaM= @@ -1899,8 +1909,8 @@ google.golang.org/grpc v1.52.3/go.mod h1:pu6fVzoFb+NBYNAvQL08ic+lvB2IojljRYuun5v google.golang.org/grpc v1.53.0/go.mod h1:OnIrk0ipVdj4N5d9IUoFUx72/VlD7+jUsHwZgwSMQpw= google.golang.org/grpc v1.54.0/go.mod h1:PUSEXI6iWghWaB6lXM4knEgpJNu2qUcKfDtNci3EC2g= google.golang.org/grpc v1.56.3/go.mod h1:I9bI3vqKfayGqPUAwGdOSu7kt6oIJLixfffKrpXqQ9s= -google.golang.org/grpc v1.70.0 h1:pWFv03aZoHzlRKHWicjsZytKAiYCtNS0dHbXnIdq7jQ= -google.golang.org/grpc v1.70.0/go.mod h1:ofIJqVKDXx/JiXrwr2IG4/zwdH9txy3IlF40RmcJSQw= +google.golang.org/grpc v1.72.0 h1:S7UkcVa60b5AAQTaO6ZKamFp1zMZSU0fGDK2WZLbBnM= +google.golang.org/grpc v1.72.0/go.mod h1:wH5Aktxcg25y1I3w7H69nHfXdOG3UiadoBtjh3izSDM= google.golang.org/grpc/cmd/protoc-gen-go-grpc v1.1.0/go.mod h1:6Kw0yEErY5E/yWrBtf03jp27GLLJujG4z/JK95pnjjw= google.golang.org/protobuf v0.0.0-20200109180630-ec00e32a8dfd/go.mod h1:DFci5gLYBciE7Vtevhsrf46CRTquxDuWsQurQQe4oz8= google.golang.org/protobuf v0.0.0-20200221191635-4d8936d0db64/go.mod h1:kwYJMbMJ01Woi6D6+Kah6886xMZcty6N08ah7+eCXa0= @@ -1920,8 +1930,8 @@ google.golang.org/protobuf v1.28.1/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqw google.golang.org/protobuf v1.29.1/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= google.golang.org/protobuf v1.30.0/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= google.golang.org/protobuf v1.33.0/go.mod h1:c6P6GXX6sHbq/GpV6MGZEdwhWPcYBgnhAHhKbcUYpos= -google.golang.org/protobuf v1.36.5 h1:tPhr+woSbjfYvY6/GPufUoYizxw1cF/yFoxJ2fmpwlM= -google.golang.org/protobuf v1.36.5/go.mod h1:9fA7Ob0pmnwhb644+1+CVWFRbNajQ6iRojtC/QF5bRE= +google.golang.org/protobuf v1.36.6 h1:z1NpPI8ku2WgiWnf+t9wTPsn6eP1L7ksHUlkfLvd9xY= +google.golang.org/protobuf v1.36.6/go.mod h1:jduwjTPXsFjZGTmRluh+L6NjiWu7pchiJ2/5YcXBHnY= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk= diff --git a/preview.go b/preview.go index ed51211..adecdfb 100644 --- a/preview.go +++ b/preview.go @@ -5,6 +5,7 @@ import ( "encoding/json" "fmt" "io/fs" + "log/slog" "path/filepath" "github.com/aquasecurity/trivy/pkg/iac/scanners/terraform/parser" @@ -23,6 +24,7 @@ type Input struct { PlanJSON json.RawMessage ParameterValues map[string]string Owner types.WorkspaceOwner + Logger *slog.Logger } type Output struct { @@ -93,10 +95,15 @@ func Preview(ctx context.Context, input Input, dir fs.FS) (output *Output, diagn }, } } - var _ = ownerHook + + logger := input.Logger + if logger == nil { // Default to discarding logs + logger = slog.New(slog.DiscardHandler) + } // moduleSource is "" for a local module p := parser.New(dir, "", + parser.OptionWithLogger(logger), parser.OptionStopOnHCLError(false), parser.OptionWithDownloads(false), parser.OptionWithSkipCachedModules(true), @@ -117,7 +124,7 @@ func Preview(ctx context.Context, input Input, dir fs.FS) (output *Output, diagn } } - modules, _, err := p.EvaluateAll(ctx) + modules, err := p.EvaluateAll(ctx) if err != nil { return nil, hcl.Diagnostics{ { From 320b553c3e2c4825c754b7c83a0f20cf4f2a3650 Mon Sep 17 00:00:00 2001 From: Steven Masley Date: Wed, 28 May 2025 15:41:04 -0500 Subject: [PATCH 45/61] chore: do not change the form type for an invalid value (#139) Invalid values just add diagnostics. Keep the form_type --- extract/parameter.go | 3 --- preview_test.go | 11 ++++++++++ testdata/unknownoption/main.tf | 37 ++++++++++++++++++++++++++++++++++ 3 files changed, 48 insertions(+), 3 deletions(-) create mode 100644 testdata/unknownoption/main.tf diff --git a/extract/parameter.go b/extract/parameter.go index bf66319..3b5f1d0 100644 --- a/extract/parameter.go +++ b/extract/parameter.go @@ -147,9 +147,6 @@ func ParameterFromBlock(block *terraform.Block) (*types.Parameter, hcl.Diagnosti } usageDiags := ParameterUsageDiagnostics(p) - if usageDiags.HasErrors() { - p.FormType = provider.ParameterFormTypeError - } diags = diags.Extend(usageDiags) // Diagnostics are scoped to the parameter diff --git a/preview_test.go b/preview_test.go index ec7ec6a..7fb2389 100644 --- a/preview_test.go +++ b/preview_test.go @@ -457,6 +457,17 @@ func Test_Extract(t *testing.T) { optNames("GoLand 2024.3", "IntelliJ IDEA Ultimate 2024.3", "PyCharm Professional 2024.3"), }, }, + { + name: "unknownoption", + dir: "unknownoption", + expTags: map[string]string{}, + input: preview.Input{}, + unknownTags: []string{}, + params: map[string]assertParam{ + "unknown": apWithDiags(). + errorDiagnostics("The set of options cannot be resolved"), + }, + }, } { t.Run(tc.name, func(t *testing.T) { t.Parallel() diff --git a/testdata/unknownoption/main.tf b/testdata/unknownoption/main.tf new file mode 100644 index 0000000..c1943e6 --- /dev/null +++ b/testdata/unknownoption/main.tf @@ -0,0 +1,37 @@ +# main.tf + +terraform { + required_providers { + coder = { + source = "coder/coder" + version = "2.4.0-pre0" + } + docker = { + source = "kreuzwerker/docker" + version = "3.0.2" + } + } +} + +data "coder_parameter" "unknown" { + name = "unknown" + display_name = "Unknown Option Example" + type = "string" + default = "foo" + + option { + name = "Ubuntu" + value = data.docker_registry_image.ubuntu.sha256_digest + } + + option { + name = "foo" + value = "foo" + } +} + +data "docker_registry_image" "ubuntu" { + name = "ubuntu:24.04" + // sha256_digest +} + From fa5e815c2a6ea475117d551e576f238d0a3124a0 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 2 Jun 2025 07:02:31 -0500 Subject: [PATCH 46/61] chore(deps): bump github.com/coder/terraform-provider-coder/v2 from 2.4.2 to 2.5.3 (#142) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Bumps [github.com/coder/terraform-provider-coder/v2](https://github.com/coder/terraform-provider-coder) from 2.4.2 to 2.5.3.
Release notes

Sourced from github.com/coder/terraform-provider-coder/v2's releases.

v2.5.3

What's Changed

Full Changelog: https://github.com/coder/terraform-provider-coder/compare/v2.5.2...v2.5.3

v2.5.2

What's Changed

Full Changelog: https://github.com/coder/terraform-provider-coder/compare/v2.5.1...v2.5.2

v2.5.1

What's Changed

Full Changelog: https://github.com/coder/terraform-provider-coder/compare/v2.5.0...v2.5.1

v2.5.0

What's Changed

New Contributors

Full Changelog: https://github.com/coder/terraform-provider-coder/compare/v2.4.2...v2.5.0

Commits
  • cfa101d fix: limit app group length (#407)
  • 442ff2a chore: add minimum TTL value for expiration.policy.ttl (#406)
  • d0457a7 build(deps): Bump crazy-max/ghaction-import-gpg from 6.2.0 to 6.3.0 (#371)
  • 01193dc build(deps): Bump goreleaser/goreleaser-action from 6.2.1 to 6.3.0 (#372)
  • 18bfe55 Refactor documentation for parameter types and icons (#405)
  • 28dae7f feat: add expiration_policy parameter to prebuild resource (#404)
  • 7489953 feat: add group attribute to coder_app resource (#402)
  • 0c7fd6a docs: update README note for local provider testing with correct module path ...
  • a4f4065 fix: map_structure of form_type to match argument name (#401)
  • 77de38e build(deps): Bump github.com/hashicorp/terraform-plugin-sdk/v2 (#400)
  • Additional commits viewable in compare view

[![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=github.com/coder/terraform-provider-coder/v2&package-manager=go_modules&previous-version=2.4.2&new-version=2.5.3)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores) Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) ---
Dependabot commands and options
You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot show ignore conditions` will show all of the ignore conditions of the specified dependency - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- go.mod | 12 ++++++------ go.sum | 32 ++++++++++++++++---------------- 2 files changed, 22 insertions(+), 22 deletions(-) diff --git a/go.mod b/go.mod index 9612114..e04cdff 100644 --- a/go.mod +++ b/go.mod @@ -7,16 +7,16 @@ require ( github.com/aquasecurity/trivy v0.58.2 github.com/coder/guts v1.5.0 github.com/coder/serpent v0.10.0 - github.com/coder/terraform-provider-coder/v2 v2.4.2 + github.com/coder/terraform-provider-coder/v2 v2.5.3 github.com/coder/websocket v1.8.13 github.com/go-chi/chi v4.1.2+incompatible - github.com/hashicorp/go-cty v1.4.1-0.20200414143053-d3edf31b6320 + github.com/hashicorp/go-cty v1.5.0 github.com/hashicorp/go-version v1.7.0 github.com/hashicorp/hc-install v0.9.2 github.com/hashicorp/hcl/v2 v2.23.0 github.com/hashicorp/terraform-exec v0.23.0 - github.com/hashicorp/terraform-json v0.24.0 - github.com/hashicorp/terraform-plugin-sdk/v2 v2.36.1 + github.com/hashicorp/terraform-json v0.25.0 + github.com/hashicorp/terraform-plugin-sdk/v2 v2.37.0 github.com/jedib0t/go-pretty/v6 v6.6.7 github.com/quasilyte/go-ruleguard/dsl v0.3.22 github.com/stretchr/testify v1.10.0 @@ -78,7 +78,7 @@ require ( github.com/hashicorp/go-safetemp v1.0.0 // indirect github.com/hashicorp/go-uuid v1.0.3 // indirect github.com/hashicorp/logutils v1.0.0 // indirect - github.com/hashicorp/terraform-plugin-go v0.26.0 // indirect + github.com/hashicorp/terraform-plugin-go v0.27.0 // indirect github.com/hashicorp/terraform-plugin-log v0.9.0 // indirect github.com/jmespath/go-jmespath v0.4.1-0.20220621161143-b0104c826a24 // indirect github.com/klauspost/compress v1.18.0 // indirect @@ -134,7 +134,7 @@ require ( google.golang.org/genproto v0.0.0-20250303144028-a0af3efb3deb // indirect google.golang.org/genproto/googleapis/api v0.0.0-20250303144028-a0af3efb3deb // indirect google.golang.org/genproto/googleapis/rpc v0.0.0-20250313205543-e70fdf4c4cb4 // indirect - google.golang.org/grpc v1.72.0 // indirect + google.golang.org/grpc v1.72.1 // indirect google.golang.org/protobuf v1.36.6 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect k8s.io/utils v0.0.0-20241104100929-3ea5e8cea738 // indirect diff --git a/go.sum b/go.sum index 2295404..3c43335 100644 --- a/go.sum +++ b/go.sum @@ -717,8 +717,8 @@ github.com/coder/pretty v0.0.0-20230908205945-e89ba86370e0 h1:3A0ES21Ke+FxEM8CXx github.com/coder/pretty v0.0.0-20230908205945-e89ba86370e0/go.mod h1:5UuS2Ts+nTToAMeOjNlnHFkPahrtDkmpydBen/3wgZc= github.com/coder/serpent v0.10.0 h1:ofVk9FJXSek+SmL3yVE3GoArP83M+1tX+H7S4t8BSuM= github.com/coder/serpent v0.10.0/go.mod h1:cZFW6/fP+kE9nd/oRkEHJpG6sXCtQ+AX7WMMEHv0Y3Q= -github.com/coder/terraform-provider-coder/v2 v2.4.2 h1:41SJkgwgiA555kwQzGIQcNS3bCm12sVMUmBSa5zGr+A= -github.com/coder/terraform-provider-coder/v2 v2.4.2/go.mod h1:2kaBpn5k9ZWtgKq5k4JbkVZG9DzEqR4mJSmpdshcO+s= +github.com/coder/terraform-provider-coder/v2 v2.5.3 h1:EwqIIQKe/j8bsR4WyDJ3bD0dVdkfVqJ43TwClyGneUU= +github.com/coder/terraform-provider-coder/v2 v2.5.3/go.mod h1:kqP2MW/OF5u3QBRPDt84vn1izKjncICFfv26nSb781I= github.com/coder/trivy v0.0.0-20250527170238-9416a59d7019 h1:MHkv/W7l9eRAN9gOG0qZ1TLRGWIIfNi92273vPAQ8Fs= github.com/coder/trivy v0.0.0-20250527170238-9416a59d7019/go.mod h1:eqk+w9RLBmbd/cB5XfPZFuVn77cf/A6fB7qmEVeSmXk= github.com/coder/websocket v1.8.13 h1:f3QZdXy7uGVz+4uCJy2nTZyM0yTBj8yANEHhqlXZ9FE= @@ -953,16 +953,16 @@ github.com/hashicorp/go-checkpoint v0.5.0 h1:MFYpPZCnQqQTE18jFwSII6eUQrD/oxMFp3m github.com/hashicorp/go-checkpoint v0.5.0/go.mod h1:7nfLNL10NsxqO4iWuW6tWW0HjZuDrwkBuEQsVcpCOgg= github.com/hashicorp/go-cleanhttp v0.5.2 h1:035FKYIWjmULyFRBKPs8TBQoi0x6d9G4xc9neXJWAZQ= github.com/hashicorp/go-cleanhttp v0.5.2/go.mod h1:kO/YDlP8L1346E6Sodw+PrpBSV4/SoxCXGY6BqNFT48= -github.com/hashicorp/go-cty v1.4.1-0.20200414143053-d3edf31b6320 h1:1/D3zfFHttUKaCaGKZ/dR2roBXv0vKbSCnssIldfQdI= -github.com/hashicorp/go-cty v1.4.1-0.20200414143053-d3edf31b6320/go.mod h1:EiZBMaudVLy8fmjf9Npq1dq9RalhveqZG5w/yz3mHWs= +github.com/hashicorp/go-cty v1.5.0 h1:EkQ/v+dDNUqnuVpmS5fPqyY71NXVgT5gf32+57xY8g0= +github.com/hashicorp/go-cty v1.5.0/go.mod h1:lFUCG5kd8exDobgSfyj4ONE/dc822kiYMguVKdHGMLM= github.com/hashicorp/go-getter v1.7.8 h1:mshVHx1Fto0/MydBekWan5zUipGq7jO0novchgMmSiY= github.com/hashicorp/go-getter v1.7.8/go.mod h1:2c6CboOEb9jG6YvmC9xdD+tyAFsrUaJPedwXDGr0TM4= github.com/hashicorp/go-hclog v1.6.3 h1:Qr2kF+eVWjTiYmU7Y31tYlP1h0q/X3Nl3tPGdaB11/k= github.com/hashicorp/go-hclog v1.6.3/go.mod h1:W4Qnvbt70Wk/zYJryRzDRU/4r0kIg0PVHBcfoyhpF5M= github.com/hashicorp/go-multierror v1.1.1 h1:H5DkEtf6CXdFp0N0Em5UCwQpXMWke8IA0+lD48awMYo= github.com/hashicorp/go-multierror v1.1.1/go.mod h1:iw975J/qwKPdAO1clOe2L8331t/9/fmwbPZ6JB6eMoM= -github.com/hashicorp/go-plugin v1.6.2 h1:zdGAEd0V1lCaU0u+MxWQhtSDQmahpkwOun8U8EiRVog= -github.com/hashicorp/go-plugin v1.6.2/go.mod h1:CkgLQ5CZqNmdL9U9JzM532t8ZiYQ35+pj3b1FD37R0Q= +github.com/hashicorp/go-plugin v1.6.3 h1:xgHB+ZUSYeuJi96WtxEjzi23uh7YQpznjGh0U0UUrwg= +github.com/hashicorp/go-plugin v1.6.3/go.mod h1:MRobyh+Wc/nYy1V4KAXUiYfzxoYhs7V1mlH1Z7iY2h0= github.com/hashicorp/go-retryablehttp v0.7.7 h1:C8hUCYzor8PIfXHa4UrZkU4VvK8o9ISHxT2Q8+VepXU= github.com/hashicorp/go-retryablehttp v0.7.7/go.mod h1:pkQpWZeYWskR+D1tR2O5OcBFOxfA7DoAO6xtkuQnHTk= github.com/hashicorp/go-safetemp v1.0.0 h1:2HR189eFNrjHQyENnQMMpCiBAsRxzbTMIgBhEyExpmo= @@ -982,16 +982,16 @@ github.com/hashicorp/logutils v1.0.0 h1:dLEQVugN8vlakKOUE3ihGLTZJRB4j+M2cdTm/ORI github.com/hashicorp/logutils v1.0.0/go.mod h1:QIAnNjmIWmVIIkWDTG1z5v++HQmx9WQRO+LraFDTW64= github.com/hashicorp/terraform-exec v0.23.0 h1:MUiBM1s0CNlRFsCLJuM5wXZrzA3MnPYEsiXmzATMW/I= github.com/hashicorp/terraform-exec v0.23.0/go.mod h1:mA+qnx1R8eePycfwKkCRk3Wy65mwInvlpAeOwmA7vlY= -github.com/hashicorp/terraform-json v0.24.0 h1:rUiyF+x1kYawXeRth6fKFm/MdfBS6+lW4NbeATsYz8Q= -github.com/hashicorp/terraform-json v0.24.0/go.mod h1:Nfj5ubo9xbu9uiAoZVBsNOjvNKB66Oyrvtit74kC7ow= -github.com/hashicorp/terraform-plugin-go v0.26.0 h1:cuIzCv4qwigug3OS7iKhpGAbZTiypAfFQmw8aE65O2M= -github.com/hashicorp/terraform-plugin-go v0.26.0/go.mod h1:+CXjuLDiFgqR+GcrM5a2E2Kal5t5q2jb0E3D57tTdNY= +github.com/hashicorp/terraform-json v0.25.0 h1:rmNqc/CIfcWawGiwXmRuiXJKEiJu1ntGoxseG1hLhoQ= +github.com/hashicorp/terraform-json v0.25.0/go.mod h1:sMKS8fiRDX4rVlR6EJUMudg1WcanxCMoWwTLkgZP/vc= +github.com/hashicorp/terraform-plugin-go v0.27.0 h1:ujykws/fWIdsi6oTUT5Or4ukvEan4aN9lY+LOxVP8EE= +github.com/hashicorp/terraform-plugin-go v0.27.0/go.mod h1:FDa2Bb3uumkTGSkTFpWSOwWJDwA7bf3vdP3ltLDTH6o= github.com/hashicorp/terraform-plugin-log v0.9.0 h1:i7hOA+vdAItN1/7UrfBqBwvYPQ9TFvymaRGZED3FCV0= github.com/hashicorp/terraform-plugin-log v0.9.0/go.mod h1:rKL8egZQ/eXSyDqzLUuwUYLVdlYeamldAHSxjUFADow= -github.com/hashicorp/terraform-plugin-sdk/v2 v2.36.1 h1:WNMsTLkZf/3ydlgsuXePa3jvZFwAJhruxTxP/c1Viuw= -github.com/hashicorp/terraform-plugin-sdk/v2 v2.36.1/go.mod h1:P6o64QS97plG44iFzSM6rAn6VJIC/Sy9a9IkEtl79K4= -github.com/hashicorp/terraform-registry-address v0.2.4 h1:JXu/zHB2Ymg/TGVCRu10XqNa4Sh2bWcqCNyKWjnCPJA= -github.com/hashicorp/terraform-registry-address v0.2.4/go.mod h1:tUNYTVyCtU4OIGXXMDp7WNcJ+0W1B4nmstVDgHMjfAU= +github.com/hashicorp/terraform-plugin-sdk/v2 v2.37.0 h1:NFPMacTrY/IdcIcnUB+7hsore1ZaRWU9cnB6jFoBnIM= +github.com/hashicorp/terraform-plugin-sdk/v2 v2.37.0/go.mod h1:QYmYnLfsosrxjCnGY1p9c7Zj6n9thnEE+7RObeYs3fA= +github.com/hashicorp/terraform-registry-address v0.2.5 h1:2GTftHqmUhVOeuu9CW3kwDkRe4pcBDq0uuK5VJngU1M= +github.com/hashicorp/terraform-registry-address v0.2.5/go.mod h1:PpzXWINwB5kuVS5CA7m1+eO2f1jKb5ZDIxrOPfpnGkg= github.com/hashicorp/terraform-svchost v0.1.1 h1:EZZimZ1GxdqFRinZ1tpJwVxxt49xc/S52uzrw4x0jKQ= github.com/hashicorp/terraform-svchost v0.1.1/go.mod h1:mNsjQfZyf/Jhz35v6/0LWcv26+X7JPS+buii2c9/ctc= github.com/hashicorp/yamux v0.1.1 h1:yrQxtgseBDrq9Y652vSRDvsKCJKOUD+GzTS4Y0Y8pvE= @@ -1909,8 +1909,8 @@ google.golang.org/grpc v1.52.3/go.mod h1:pu6fVzoFb+NBYNAvQL08ic+lvB2IojljRYuun5v google.golang.org/grpc v1.53.0/go.mod h1:OnIrk0ipVdj4N5d9IUoFUx72/VlD7+jUsHwZgwSMQpw= google.golang.org/grpc v1.54.0/go.mod h1:PUSEXI6iWghWaB6lXM4knEgpJNu2qUcKfDtNci3EC2g= google.golang.org/grpc v1.56.3/go.mod h1:I9bI3vqKfayGqPUAwGdOSu7kt6oIJLixfffKrpXqQ9s= -google.golang.org/grpc v1.72.0 h1:S7UkcVa60b5AAQTaO6ZKamFp1zMZSU0fGDK2WZLbBnM= -google.golang.org/grpc v1.72.0/go.mod h1:wH5Aktxcg25y1I3w7H69nHfXdOG3UiadoBtjh3izSDM= +google.golang.org/grpc v1.72.1 h1:HR03wO6eyZ7lknl75XlxABNVLLFc2PAb6mHlYh756mA= +google.golang.org/grpc v1.72.1/go.mod h1:wH5Aktxcg25y1I3w7H69nHfXdOG3UiadoBtjh3izSDM= google.golang.org/grpc/cmd/protoc-gen-go-grpc v1.1.0/go.mod h1:6Kw0yEErY5E/yWrBtf03jp27GLLJujG4z/JK95pnjjw= google.golang.org/protobuf v0.0.0-20200109180630-ec00e32a8dfd/go.mod h1:DFci5gLYBciE7Vtevhsrf46CRTquxDuWsQurQQe4oz8= google.golang.org/protobuf v0.0.0-20200221191635-4d8936d0db64/go.mod h1:kwYJMbMJ01Woi6D6+Kah6886xMZcty6N08ah7+eCXa0= From 131ed6b61293d30cc759d3ab9d26e588cc222a93 Mon Sep 17 00:00:00 2001 From: Steven Masley Date: Mon, 2 Jun 2025 11:46:43 -0500 Subject: [PATCH 47/61] feat: add support to json marshal the module output (#143) --- preview.go | 34 ++++++++++++++++++++++++++++------ 1 file changed, 28 insertions(+), 6 deletions(-) diff --git a/preview.go b/preview.go index adecdfb..5635bf1 100644 --- a/preview.go +++ b/preview.go @@ -11,6 +11,7 @@ import ( "github.com/aquasecurity/trivy/pkg/iac/scanners/terraform/parser" "github.com/hashicorp/hcl/v2" "github.com/zclconf/go-cty/cty" + ctyjson "github.com/zclconf/go-cty/cty/json" "github.com/coder/preview/hclext" "github.com/coder/preview/types" @@ -31,14 +32,35 @@ type Output struct { // ModuleOutput is any 'output' values from the terraform files. This has 0 // effect on the parameters, tags, etc. It can be helpful for debugging, as it // allows exporting some terraform values to the caller to review. - ModuleOutput cty.Value + // + // JSON marshalling is handled in the custom methods. + ModuleOutput cty.Value `json:"-"` - Parameters []types.Parameter - WorkspaceTags types.TagBlocks + Parameters []types.Parameter `json:"parameters"` + WorkspaceTags types.TagBlocks `json:"workspace_tags"` // Files is included for printing diagnostics. - // TODO: Is the memory impact of this too much? Should we render diagnostic source code - // into the diagnostics up front? and remove this? - Files map[string]*hcl.File + // They can be marshalled, but not unmarshalled. This is a limitation + // of the HCL library. + Files map[string]*hcl.File `json:"-"` +} + +// MarshalJSON includes the ModuleOutput and files in the JSON output. Output +// should never be unmarshalled. Marshalling to JSON is strictly useful for +// debugging information. +func (o Output) MarshalJSON() ([]byte, error) { + // Do not make this a fatal error, as it is supplementary information. + modOutput, _ := ctyjson.Marshal(o.ModuleOutput, o.ModuleOutput.Type()) + + type Alias Output + return json.Marshal(&struct { + ModuleOutput json.RawMessage `json:"module_output"` + Files map[string]*hcl.File `json:"files"` + Alias + }{ + ModuleOutput: modOutput, + Files: o.Files, + Alias: (Alias)(o), + }) } func Preview(ctx context.Context, input Input, dir fs.FS) (output *Output, diagnostics hcl.Diagnostics) { From c9862a17f6520d124d4fd50cc71e20a01c3cc913 Mon Sep 17 00:00:00 2001 From: Steven Masley Date: Wed, 4 Jun 2025 09:44:57 -0500 Subject: [PATCH 48/61] feat: handle expanded parameter names (#144) When using a `count` meta argument, the `nameVal` is unknown. Skip unknown `nameVals`. `parameterContextsEvalHook` is called on each evaluation loop, so eventually it will be known. --- paramhook.go | 11 +++++++++-- preview_test.go | 2 ++ testdata/dynamicblock/main.tf | 18 ++++++++++++++++++ 3 files changed, 29 insertions(+), 2 deletions(-) diff --git a/paramhook.go b/paramhook.go index 03eadc5..0b8427f 100644 --- a/paramhook.go +++ b/paramhook.go @@ -28,8 +28,15 @@ func parameterContextsEvalHook(input Input) func(ctx *tfcontext.Context, blocks nameAttr := block.GetAttribute("name") nameVal := nameAttr.Value() - if !nameVal.Type().Equals(cty.String) { - continue // Ignore the errors at this point + if !nameVal.IsKnown() { + // Wait for it to be known + continue + } + + if nameVal.IsNull() || + !nameVal.Type().Equals(cty.String) { + // Ignore the errors at this point + continue } //nolint:gocritic // string type asserted diff --git a/preview_test.go b/preview_test.go index 7fb2389..b0ea9b3 100644 --- a/preview_test.go +++ b/preview_test.go @@ -132,6 +132,8 @@ func Test_Extract(t *testing.T) { "Region": ap(). value("eu"). optVals("us", "eu", "au"), + "indexed_0": ap(), + "indexed_1": ap(), }, }, { diff --git a/testdata/dynamicblock/main.tf b/testdata/dynamicblock/main.tf index 8dd93f7..bc9587b 100644 --- a/testdata/dynamicblock/main.tf +++ b/testdata/dynamicblock/main.tf @@ -12,6 +12,24 @@ variable "regions" { default = ["us", "eu", "au"] } +data "coder_parameter" "indexed" { + count = 2 + name = "indexed_${count.index}" + display_name = "Indexed Param ${count.index}" + type = "string" + form_type = "dropdown" + default = "Hello_0" + + dynamic "option" { + for_each = range(2) + + content { + name = "Hello_${option.value}" + value = "Hello_${option.value}" + } + } +} + data "coder_parameter" "region" { name = "Region" description = "Which region would you like to deploy to?" From 2e5caa65a54ab87073aaeee84e2a859e0c9fb299 Mon Sep 17 00:00:00 2001 From: Steven Masley Date: Wed, 11 Jun 2025 11:45:54 -0500 Subject: [PATCH 49/61] chore: fix heterogenous lists in plan.json (#146) Also fixes empty list values --- plan.go | 5 ++++- plan_internal_test.go | 32 ++++++++++++++++++++++++++++++++ 2 files changed, 36 insertions(+), 1 deletion(-) create mode 100644 plan_internal_test.go diff --git a/plan.go b/plan.go index de2b67c..bcf44fa 100644 --- a/plan.go +++ b/plan.go @@ -182,7 +182,10 @@ func toCtyValue(a any) (cty.Value, error) { } sv = append(sv, v) } - return cty.ListVal(sv), nil + + // Always use a tuple over a list. Tuples are heterogeneous typed lists, which is + // more robust. Functionally equivalent for our use case of looking up values. + return cty.TupleVal(sv), nil case reflect.Map: if av.Type().Key().Kind() != reflect.String { return cty.NilVal, fmt.Errorf("map keys must be string, found %q", av.Type().Key().Kind()) diff --git a/plan_internal_test.go b/plan_internal_test.go new file mode 100644 index 0000000..fe86220 --- /dev/null +++ b/plan_internal_test.go @@ -0,0 +1,32 @@ +package preview + +import ( + "testing" + + "github.com/stretchr/testify/require" + "github.com/zclconf/go-cty/cty" +) + +func Test_toCtyValue(t *testing.T) { + t.Parallel() + + t.Run("EmptyList", func(t *testing.T) { + t.Parallel() + val, err := toCtyValue([]any{}) + require.NoError(t, err) + require.True(t, val.Type().IsTupleType()) + }) + + t.Run("HeterogeneousList", func(t *testing.T) { + t.Parallel() + val, err := toCtyValue([]any{5, "hello", true}) + require.NoError(t, err) + require.True(t, val.Type().IsTupleType()) + require.Equal(t, 3, val.LengthInt()) + require.True(t, val.Equals(cty.TupleVal([]cty.Value{ + cty.NumberIntVal(5), + cty.StringVal("hello"), + cty.BoolVal(true), + })).True()) + }) +} From c8bc19cbc69a976043b067f91e966be385162601 Mon Sep 17 00:00:00 2001 From: Steven Masley Date: Wed, 11 Jun 2025 17:27:29 -0500 Subject: [PATCH 50/61] update connections --- testdata/connections/main.tf | 39 ++++++++++++++++++++++++++++++++++-- 1 file changed, 37 insertions(+), 2 deletions(-) diff --git a/testdata/connections/main.tf b/testdata/connections/main.tf index 398b74f..b9f1f59 100644 --- a/testdata/connections/main.tf +++ b/testdata/connections/main.tf @@ -41,12 +41,35 @@ locals { available_words = setsubtract(toset(local.word_bank), toset(local.used_words)) + colors = toset(["yellow", "green", "blue", "purple"]) solved = length([for color in local.colors : module.checker[color].solved if module.checker[color].solved]) == 4 } +locals { + unpadded_items = tolist(local.available_words) + target_width = 3 + remainder = length(local.unpadded_items) % local.target_width + padding_needed = local.remainder == 0 ? 0 : local.target_width - local.remainder + items = concat(local.unpadded_items, slice(["", "", ""], 0, local.padding_needed)) + + # Split into rows of 3 items each + rows = [ + for i in range(0, length(local.items), local.target_width) : slice(local.items, i, i + local.target_width) + ] + + # Generate Markdown rows + markdown_rows = [ + for row in local.rows : "| ${join(" | ", concat(row, slice(["", "", ""], 0, local.target_width - length(row))))} |" + ] + markdown = join("\n", concat( + ["| Item 1 | Item 2 | Item 3 |", "|--------|--------|--------|"], + local.markdown_rows + )) +} + module "checker" { for_each = local.colors @@ -57,8 +80,20 @@ module "checker" { data "coder_parameter" display { name = "display" - display_name = local.solved ? "Congrats, you won! You may now hit the switch!" : join(", ", local.available_words) - description = local.solved ? "Hitting the switch enables workspace creation." : "Remaining words are above, you cannot use this switch until you solve the puzzle!" + display_name = local.solved ? "Congrats, you won! You may now hit the switch!" : < Date: Fri, 20 Jun 2025 10:13:15 -0500 Subject: [PATCH 51/61] chore: unknown values should just be an empty string --- types/value.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/types/value.go b/types/value.go index 3b5f9c4..b80b29f 100644 --- a/types/value.go +++ b/types/value.go @@ -12,7 +12,7 @@ import ( ) const ( - UnknownStringValue = "??" + UnknownStringValue = "" ) type NullHCLString struct { From cf0df2ffc910001b81d9662215928326421aedfa Mon Sep 17 00:00:00 2001 From: Steven Masley Date: Mon, 23 Jun 2025 13:19:08 -0500 Subject: [PATCH 52/61] chore: regenerate types with unknown string change (#151) --- site/src/types/preview.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/site/src/types/preview.ts b/site/src/types/preview.ts index 4aeb2d6..d415468 100644 --- a/site/src/types/preview.ts +++ b/site/src/types/preview.ts @@ -106,7 +106,7 @@ export interface SessionInputs { } // From types/value.go -export const UnknownStringValue = "??"; +export const UnknownStringValue = ""; // From types/parameter.go export const ValidationMonotonicDecreasing = "decreasing"; From b2af2a4cf265ac60e25ca27e96717db45da3e37b Mon Sep 17 00:00:00 2001 From: Jaayden Halko Date: Mon, 23 Jun 2025 19:37:18 +0100 Subject: [PATCH 53/61] chore: remove frontend test project (#152) --- site/.gitignore | 24 - site/.vite/deps/_metadata.json | 31 - site/.vite/deps/chunk-GNHYFQKO.js | 1141 - site/.vite/deps/chunk-GNHYFQKO.js.map | 7 - site/.vite/deps/package.json | 3 - site/.vite/deps/react-dom_client.js | 18180 ---------------- site/.vite/deps/react-dom_client.js.map | 7 - site/.vite/deps/react.js | 4 - site/.vite/deps/react.js.map | 7 - site/.vite/deps/react_jsx-dev-runtime.js | 468 - site/.vite/deps/react_jsx-dev-runtime.js.map | 7 - site/README.md | 54 - site/components.json | 21 - site/eslint.config.js | 28 - site/gen.go | 2 - site/genweb/main.go | 128 - site/index.html | 13 - site/package.json | 48 - site/pnpm-lock.yaml | 3823 ---- site/public/vite.svg | 1 - site/src/App.css | 7 - site/src/App.tsx | 13 - site/src/DemoPage.tsx | 95 - site/src/DynamicForm.tsx | 561 - site/src/assets/react.svg | 1 - site/src/components/Badge/Badge.tsx | 56 - site/src/components/Button/Button.tsx | 71 - site/src/components/Checkbox/Checkbox.tsx | 30 - .../CollapsibleSummary/CollapsibleSummary.tsx | 91 - site/src/components/Input/Input.tsx | 24 - site/src/components/Label/Label.tsx | 25 - site/src/components/Select/Select.tsx | 164 - site/src/components/Switch/Switch.tsx | 35 - site/src/components/Textarea/Textarea.tsx | 18 - site/src/components/theme-provider.tsx | 73 - site/src/components/ui/command.tsx | 155 - site/src/components/ui/dialog.tsx | 133 - site/src/components/ui/label.tsx | 19 - site/src/components/ui/multiselect.tsx | 593 - site/src/components/ui/radio-group.tsx | 46 - site/src/components/ui/slider.tsx | 61 - site/src/hooks/debounce.ts | 99 - site/src/hooks/useDirectories.ts | 44 - site/src/hooks/useUsers.ts | 42 - site/src/index.css | 221 - site/src/main.tsx | 10 - site/src/useWebSocket.ts | 84 - site/src/utils/cn.ts | 6 - site/src/vite-env.d.ts | 1 - site/tailwind.config.js | 79 - site/tsconfig.app.json | 32 - site/tsconfig.json | 13 - site/tsconfig.node.json | 24 - site/vite.config.ts | 8 - 54 files changed, 26931 deletions(-) delete mode 100644 site/.gitignore delete mode 100644 site/.vite/deps/_metadata.json delete mode 100644 site/.vite/deps/chunk-GNHYFQKO.js delete mode 100644 site/.vite/deps/chunk-GNHYFQKO.js.map delete mode 100644 site/.vite/deps/package.json delete mode 100644 site/.vite/deps/react-dom_client.js delete mode 100644 site/.vite/deps/react-dom_client.js.map delete mode 100644 site/.vite/deps/react.js delete mode 100644 site/.vite/deps/react.js.map delete mode 100644 site/.vite/deps/react_jsx-dev-runtime.js delete mode 100644 site/.vite/deps/react_jsx-dev-runtime.js.map delete mode 100644 site/README.md delete mode 100644 site/components.json delete mode 100644 site/eslint.config.js delete mode 100644 site/gen.go delete mode 100644 site/genweb/main.go delete mode 100644 site/index.html delete mode 100644 site/package.json delete mode 100644 site/pnpm-lock.yaml delete mode 100644 site/public/vite.svg delete mode 100644 site/src/App.css delete mode 100644 site/src/App.tsx delete mode 100644 site/src/DemoPage.tsx delete mode 100644 site/src/DynamicForm.tsx delete mode 100644 site/src/assets/react.svg delete mode 100644 site/src/components/Badge/Badge.tsx delete mode 100644 site/src/components/Button/Button.tsx delete mode 100644 site/src/components/Checkbox/Checkbox.tsx delete mode 100644 site/src/components/CollapsibleSummary/CollapsibleSummary.tsx delete mode 100644 site/src/components/Input/Input.tsx delete mode 100644 site/src/components/Label/Label.tsx delete mode 100644 site/src/components/Select/Select.tsx delete mode 100644 site/src/components/Switch/Switch.tsx delete mode 100644 site/src/components/Textarea/Textarea.tsx delete mode 100644 site/src/components/theme-provider.tsx delete mode 100644 site/src/components/ui/command.tsx delete mode 100644 site/src/components/ui/dialog.tsx delete mode 100644 site/src/components/ui/label.tsx delete mode 100644 site/src/components/ui/multiselect.tsx delete mode 100644 site/src/components/ui/radio-group.tsx delete mode 100644 site/src/components/ui/slider.tsx delete mode 100644 site/src/hooks/debounce.ts delete mode 100644 site/src/hooks/useDirectories.ts delete mode 100644 site/src/hooks/useUsers.ts delete mode 100644 site/src/index.css delete mode 100644 site/src/main.tsx delete mode 100644 site/src/useWebSocket.ts delete mode 100644 site/src/utils/cn.ts delete mode 100644 site/src/vite-env.d.ts delete mode 100644 site/tailwind.config.js delete mode 100644 site/tsconfig.app.json delete mode 100644 site/tsconfig.json delete mode 100644 site/tsconfig.node.json delete mode 100644 site/vite.config.ts diff --git a/site/.gitignore b/site/.gitignore deleted file mode 100644 index a547bf3..0000000 --- a/site/.gitignore +++ /dev/null @@ -1,24 +0,0 @@ -# Logs -logs -*.log -npm-debug.log* -yarn-debug.log* -yarn-error.log* -pnpm-debug.log* -lerna-debug.log* - -node_modules -dist -dist-ssr -*.local - -# Editor directories and files -.vscode/* -!.vscode/extensions.json -.idea -.DS_Store -*.suo -*.ntvs* -*.njsproj -*.sln -*.sw? diff --git a/site/.vite/deps/_metadata.json b/site/.vite/deps/_metadata.json deleted file mode 100644 index 0dcde89..0000000 --- a/site/.vite/deps/_metadata.json +++ /dev/null @@ -1,31 +0,0 @@ -{ - "hash": "d6fe4a37", - "configHash": "f01d7f4d", - "lockfileHash": "25478000", - "browserHash": "b330bcc8", - "optimized": { - "react/jsx-dev-runtime": { - "src": "../../node_modules/.pnpm/react@19.0.0/node_modules/react/jsx-dev-runtime.js", - "file": "react_jsx-dev-runtime.js", - "fileHash": "63d4a3ac", - "needsInterop": true - }, - "react": { - "src": "../../node_modules/.pnpm/react@19.0.0/node_modules/react/index.js", - "file": "react.js", - "fileHash": "9c3f9b2a", - "needsInterop": true - }, - "react-dom/client": { - "src": "../../node_modules/.pnpm/react-dom@19.0.0_react@19.0.0/node_modules/react-dom/client.js", - "file": "react-dom_client.js", - "fileHash": "fcbe9e94", - "needsInterop": true - } - }, - "chunks": { - "chunk-GNHYFQKO": { - "file": "chunk-GNHYFQKO.js" - } - } -} \ No newline at end of file diff --git a/site/.vite/deps/chunk-GNHYFQKO.js b/site/.vite/deps/chunk-GNHYFQKO.js deleted file mode 100644 index 438e1e8..0000000 --- a/site/.vite/deps/chunk-GNHYFQKO.js +++ /dev/null @@ -1,1141 +0,0 @@ -var __getOwnPropNames = Object.getOwnPropertyNames; -var __commonJS = (cb, mod) => function __require() { - return mod || (0, cb[__getOwnPropNames(cb)[0]])((mod = { exports: {} }).exports, mod), mod.exports; -}; - -// node_modules/.pnpm/react@19.0.0/node_modules/react/cjs/react.development.js -var require_react_development = __commonJS({ - "node_modules/.pnpm/react@19.0.0/node_modules/react/cjs/react.development.js"(exports, module) { - "use strict"; - (function() { - function defineDeprecationWarning(methodName, info) { - Object.defineProperty(Component.prototype, methodName, { - get: function() { - console.warn( - "%s(...) is deprecated in plain JavaScript React classes. %s", - info[0], - info[1] - ); - } - }); - } - function getIteratorFn(maybeIterable) { - if (null === maybeIterable || "object" !== typeof maybeIterable) - return null; - maybeIterable = MAYBE_ITERATOR_SYMBOL && maybeIterable[MAYBE_ITERATOR_SYMBOL] || maybeIterable["@@iterator"]; - return "function" === typeof maybeIterable ? maybeIterable : null; - } - function warnNoop(publicInstance, callerName) { - publicInstance = (publicInstance = publicInstance.constructor) && (publicInstance.displayName || publicInstance.name) || "ReactClass"; - var warningKey = publicInstance + "." + callerName; - didWarnStateUpdateForUnmountedComponent[warningKey] || (console.error( - "Can't call %s on a component that is not yet mounted. This is a no-op, but it might indicate a bug in your application. Instead, assign to `this.state` directly or define a `state = {};` class property with the desired state in the %s component.", - callerName, - publicInstance - ), didWarnStateUpdateForUnmountedComponent[warningKey] = true); - } - function Component(props, context, updater) { - this.props = props; - this.context = context; - this.refs = emptyObject; - this.updater = updater || ReactNoopUpdateQueue; - } - function ComponentDummy() { - } - function PureComponent(props, context, updater) { - this.props = props; - this.context = context; - this.refs = emptyObject; - this.updater = updater || ReactNoopUpdateQueue; - } - function testStringCoercion(value) { - return "" + value; - } - function checkKeyStringCoercion(value) { - try { - testStringCoercion(value); - var JSCompiler_inline_result = false; - } catch (e) { - JSCompiler_inline_result = true; - } - if (JSCompiler_inline_result) { - JSCompiler_inline_result = console; - var JSCompiler_temp_const = JSCompiler_inline_result.error; - var JSCompiler_inline_result$jscomp$0 = "function" === typeof Symbol && Symbol.toStringTag && value[Symbol.toStringTag] || value.constructor.name || "Object"; - JSCompiler_temp_const.call( - JSCompiler_inline_result, - "The provided key is an unsupported type %s. This value must be coerced to a string before using it here.", - JSCompiler_inline_result$jscomp$0 - ); - return testStringCoercion(value); - } - } - function getComponentNameFromType(type) { - if (null == type) return null; - if ("function" === typeof type) - return type.$$typeof === REACT_CLIENT_REFERENCE$2 ? null : type.displayName || type.name || null; - if ("string" === typeof type) return type; - switch (type) { - case REACT_FRAGMENT_TYPE: - return "Fragment"; - case REACT_PORTAL_TYPE: - return "Portal"; - case REACT_PROFILER_TYPE: - return "Profiler"; - case REACT_STRICT_MODE_TYPE: - return "StrictMode"; - case REACT_SUSPENSE_TYPE: - return "Suspense"; - case REACT_SUSPENSE_LIST_TYPE: - return "SuspenseList"; - } - if ("object" === typeof type) - switch ("number" === typeof type.tag && console.error( - "Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue." - ), type.$$typeof) { - case REACT_CONTEXT_TYPE: - return (type.displayName || "Context") + ".Provider"; - case REACT_CONSUMER_TYPE: - return (type._context.displayName || "Context") + ".Consumer"; - case REACT_FORWARD_REF_TYPE: - var innerType = type.render; - type = type.displayName; - type || (type = innerType.displayName || innerType.name || "", type = "" !== type ? "ForwardRef(" + type + ")" : "ForwardRef"); - return type; - case REACT_MEMO_TYPE: - return innerType = type.displayName || null, null !== innerType ? innerType : getComponentNameFromType(type.type) || "Memo"; - case REACT_LAZY_TYPE: - innerType = type._payload; - type = type._init; - try { - return getComponentNameFromType(type(innerType)); - } catch (x) { - } - } - return null; - } - function isValidElementType(type) { - return "string" === typeof type || "function" === typeof type || type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || type === REACT_OFFSCREEN_TYPE || "object" === typeof type && null !== type && (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_CONSUMER_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || type.$$typeof === REACT_CLIENT_REFERENCE$1 || void 0 !== type.getModuleId) ? true : false; - } - function disabledLog() { - } - function disableLogs() { - if (0 === disabledDepth) { - prevLog = console.log; - prevInfo = console.info; - prevWarn = console.warn; - prevError = console.error; - prevGroup = console.group; - prevGroupCollapsed = console.groupCollapsed; - prevGroupEnd = console.groupEnd; - var props = { - configurable: true, - enumerable: true, - value: disabledLog, - writable: true - }; - Object.defineProperties(console, { - info: props, - log: props, - warn: props, - error: props, - group: props, - groupCollapsed: props, - groupEnd: props - }); - } - disabledDepth++; - } - function reenableLogs() { - disabledDepth--; - if (0 === disabledDepth) { - var props = { configurable: true, enumerable: true, writable: true }; - Object.defineProperties(console, { - log: assign({}, props, { value: prevLog }), - info: assign({}, props, { value: prevInfo }), - warn: assign({}, props, { value: prevWarn }), - error: assign({}, props, { value: prevError }), - group: assign({}, props, { value: prevGroup }), - groupCollapsed: assign({}, props, { value: prevGroupCollapsed }), - groupEnd: assign({}, props, { value: prevGroupEnd }) - }); - } - 0 > disabledDepth && console.error( - "disabledDepth fell below zero. This is a bug in React. Please file an issue." - ); - } - function describeBuiltInComponentFrame(name) { - if (void 0 === prefix) - try { - throw Error(); - } catch (x) { - var match = x.stack.trim().match(/\n( *(at )?)/); - prefix = match && match[1] || ""; - suffix = -1 < x.stack.indexOf("\n at") ? " ()" : -1 < x.stack.indexOf("@") ? "@unknown:0:0" : ""; - } - return "\n" + prefix + name + suffix; - } - function describeNativeComponentFrame(fn, construct) { - if (!fn || reentry) return ""; - var frame = componentFrameCache.get(fn); - if (void 0 !== frame) return frame; - reentry = true; - frame = Error.prepareStackTrace; - Error.prepareStackTrace = void 0; - var previousDispatcher = null; - previousDispatcher = ReactSharedInternals.H; - ReactSharedInternals.H = null; - disableLogs(); - try { - var RunInRootFrame = { - DetermineComponentFrameRoot: function() { - try { - if (construct) { - var Fake = function() { - throw Error(); - }; - Object.defineProperty(Fake.prototype, "props", { - set: function() { - throw Error(); - } - }); - if ("object" === typeof Reflect && Reflect.construct) { - try { - Reflect.construct(Fake, []); - } catch (x) { - var control = x; - } - Reflect.construct(fn, [], Fake); - } else { - try { - Fake.call(); - } catch (x$0) { - control = x$0; - } - fn.call(Fake.prototype); - } - } else { - try { - throw Error(); - } catch (x$1) { - control = x$1; - } - (Fake = fn()) && "function" === typeof Fake.catch && Fake.catch(function() { - }); - } - } catch (sample) { - if (sample && control && "string" === typeof sample.stack) - return [sample.stack, control.stack]; - } - return [null, null]; - } - }; - RunInRootFrame.DetermineComponentFrameRoot.displayName = "DetermineComponentFrameRoot"; - var namePropDescriptor = Object.getOwnPropertyDescriptor( - RunInRootFrame.DetermineComponentFrameRoot, - "name" - ); - namePropDescriptor && namePropDescriptor.configurable && Object.defineProperty( - RunInRootFrame.DetermineComponentFrameRoot, - "name", - { value: "DetermineComponentFrameRoot" } - ); - var _RunInRootFrame$Deter = RunInRootFrame.DetermineComponentFrameRoot(), sampleStack = _RunInRootFrame$Deter[0], controlStack = _RunInRootFrame$Deter[1]; - if (sampleStack && controlStack) { - var sampleLines = sampleStack.split("\n"), controlLines = controlStack.split("\n"); - for (_RunInRootFrame$Deter = namePropDescriptor = 0; namePropDescriptor < sampleLines.length && !sampleLines[namePropDescriptor].includes( - "DetermineComponentFrameRoot" - ); ) - namePropDescriptor++; - for (; _RunInRootFrame$Deter < controlLines.length && !controlLines[_RunInRootFrame$Deter].includes( - "DetermineComponentFrameRoot" - ); ) - _RunInRootFrame$Deter++; - if (namePropDescriptor === sampleLines.length || _RunInRootFrame$Deter === controlLines.length) - for (namePropDescriptor = sampleLines.length - 1, _RunInRootFrame$Deter = controlLines.length - 1; 1 <= namePropDescriptor && 0 <= _RunInRootFrame$Deter && sampleLines[namePropDescriptor] !== controlLines[_RunInRootFrame$Deter]; ) - _RunInRootFrame$Deter--; - for (; 1 <= namePropDescriptor && 0 <= _RunInRootFrame$Deter; namePropDescriptor--, _RunInRootFrame$Deter--) - if (sampleLines[namePropDescriptor] !== controlLines[_RunInRootFrame$Deter]) { - if (1 !== namePropDescriptor || 1 !== _RunInRootFrame$Deter) { - do - if (namePropDescriptor--, _RunInRootFrame$Deter--, 0 > _RunInRootFrame$Deter || sampleLines[namePropDescriptor] !== controlLines[_RunInRootFrame$Deter]) { - var _frame = "\n" + sampleLines[namePropDescriptor].replace( - " at new ", - " at " - ); - fn.displayName && _frame.includes("") && (_frame = _frame.replace("", fn.displayName)); - "function" === typeof fn && componentFrameCache.set(fn, _frame); - return _frame; - } - while (1 <= namePropDescriptor && 0 <= _RunInRootFrame$Deter); - } - break; - } - } - } finally { - reentry = false, ReactSharedInternals.H = previousDispatcher, reenableLogs(), Error.prepareStackTrace = frame; - } - sampleLines = (sampleLines = fn ? fn.displayName || fn.name : "") ? describeBuiltInComponentFrame(sampleLines) : ""; - "function" === typeof fn && componentFrameCache.set(fn, sampleLines); - return sampleLines; - } - function describeUnknownElementTypeFrameInDEV(type) { - if (null == type) return ""; - if ("function" === typeof type) { - var prototype = type.prototype; - return describeNativeComponentFrame( - type, - !(!prototype || !prototype.isReactComponent) - ); - } - if ("string" === typeof type) return describeBuiltInComponentFrame(type); - switch (type) { - case REACT_SUSPENSE_TYPE: - return describeBuiltInComponentFrame("Suspense"); - case REACT_SUSPENSE_LIST_TYPE: - return describeBuiltInComponentFrame("SuspenseList"); - } - if ("object" === typeof type) - switch (type.$$typeof) { - case REACT_FORWARD_REF_TYPE: - return type = describeNativeComponentFrame(type.render, false), type; - case REACT_MEMO_TYPE: - return describeUnknownElementTypeFrameInDEV(type.type); - case REACT_LAZY_TYPE: - prototype = type._payload; - type = type._init; - try { - return describeUnknownElementTypeFrameInDEV(type(prototype)); - } catch (x) { - } - } - return ""; - } - function getOwner() { - var dispatcher = ReactSharedInternals.A; - return null === dispatcher ? null : dispatcher.getOwner(); - } - function hasValidKey(config) { - if (hasOwnProperty.call(config, "key")) { - var getter = Object.getOwnPropertyDescriptor(config, "key").get; - if (getter && getter.isReactWarning) return false; - } - return void 0 !== config.key; - } - function defineKeyPropWarningGetter(props, displayName) { - function warnAboutAccessingKey() { - specialPropKeyWarningShown || (specialPropKeyWarningShown = true, console.error( - "%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://react.dev/link/special-props)", - displayName - )); - } - warnAboutAccessingKey.isReactWarning = true; - Object.defineProperty(props, "key", { - get: warnAboutAccessingKey, - configurable: true - }); - } - function elementRefGetterWithDeprecationWarning() { - var componentName = getComponentNameFromType(this.type); - didWarnAboutElementRef[componentName] || (didWarnAboutElementRef[componentName] = true, console.error( - "Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release." - )); - componentName = this.props.ref; - return void 0 !== componentName ? componentName : null; - } - function ReactElement(type, key, self, source, owner, props) { - self = props.ref; - type = { - $$typeof: REACT_ELEMENT_TYPE, - type, - key, - props, - _owner: owner - }; - null !== (void 0 !== self ? self : null) ? Object.defineProperty(type, "ref", { - enumerable: false, - get: elementRefGetterWithDeprecationWarning - }) : Object.defineProperty(type, "ref", { enumerable: false, value: null }); - type._store = {}; - Object.defineProperty(type._store, "validated", { - configurable: false, - enumerable: false, - writable: true, - value: 0 - }); - Object.defineProperty(type, "_debugInfo", { - configurable: false, - enumerable: false, - writable: true, - value: null - }); - Object.freeze && (Object.freeze(type.props), Object.freeze(type)); - return type; - } - function cloneAndReplaceKey(oldElement, newKey) { - newKey = ReactElement( - oldElement.type, - newKey, - void 0, - void 0, - oldElement._owner, - oldElement.props - ); - newKey._store.validated = oldElement._store.validated; - return newKey; - } - function validateChildKeys(node, parentType) { - if ("object" === typeof node && node && node.$$typeof !== REACT_CLIENT_REFERENCE) { - if (isArrayImpl(node)) - for (var i = 0; i < node.length; i++) { - var child = node[i]; - isValidElement(child) && validateExplicitKey(child, parentType); - } - else if (isValidElement(node)) - node._store && (node._store.validated = 1); - else if (i = getIteratorFn(node), "function" === typeof i && i !== node.entries && (i = i.call(node), i !== node)) - for (; !(node = i.next()).done; ) - isValidElement(node.value) && validateExplicitKey(node.value, parentType); - } - } - function isValidElement(object) { - return "object" === typeof object && null !== object && object.$$typeof === REACT_ELEMENT_TYPE; - } - function validateExplicitKey(element, parentType) { - if (element._store && !element._store.validated && null == element.key && (element._store.validated = 1, parentType = getCurrentComponentErrorInfo(parentType), !ownerHasKeyUseWarning[parentType])) { - ownerHasKeyUseWarning[parentType] = true; - var childOwner = ""; - element && null != element._owner && element._owner !== getOwner() && (childOwner = null, "number" === typeof element._owner.tag ? childOwner = getComponentNameFromType(element._owner.type) : "string" === typeof element._owner.name && (childOwner = element._owner.name), childOwner = " It was passed a child from " + childOwner + "."); - var prevGetCurrentStack = ReactSharedInternals.getCurrentStack; - ReactSharedInternals.getCurrentStack = function() { - var stack = describeUnknownElementTypeFrameInDEV(element.type); - prevGetCurrentStack && (stack += prevGetCurrentStack() || ""); - return stack; - }; - console.error( - 'Each child in a list should have a unique "key" prop.%s%s See https://react.dev/link/warning-keys for more information.', - parentType, - childOwner - ); - ReactSharedInternals.getCurrentStack = prevGetCurrentStack; - } - } - function getCurrentComponentErrorInfo(parentType) { - var info = "", owner = getOwner(); - owner && (owner = getComponentNameFromType(owner.type)) && (info = "\n\nCheck the render method of `" + owner + "`."); - info || (parentType = getComponentNameFromType(parentType)) && (info = "\n\nCheck the top-level render call using <" + parentType + ">."); - return info; - } - function escape(key) { - var escaperLookup = { "=": "=0", ":": "=2" }; - return "$" + key.replace(/[=:]/g, function(match) { - return escaperLookup[match]; - }); - } - function getElementKey(element, index) { - return "object" === typeof element && null !== element && null != element.key ? (checkKeyStringCoercion(element.key), escape("" + element.key)) : index.toString(36); - } - function noop$1() { - } - function resolveThenable(thenable) { - switch (thenable.status) { - case "fulfilled": - return thenable.value; - case "rejected": - throw thenable.reason; - default: - switch ("string" === typeof thenable.status ? thenable.then(noop$1, noop$1) : (thenable.status = "pending", thenable.then( - function(fulfilledValue) { - "pending" === thenable.status && (thenable.status = "fulfilled", thenable.value = fulfilledValue); - }, - function(error) { - "pending" === thenable.status && (thenable.status = "rejected", thenable.reason = error); - } - )), thenable.status) { - case "fulfilled": - return thenable.value; - case "rejected": - throw thenable.reason; - } - } - throw thenable; - } - function mapIntoArray(children, array, escapedPrefix, nameSoFar, callback) { - var type = typeof children; - if ("undefined" === type || "boolean" === type) children = null; - var invokeCallback = false; - if (null === children) invokeCallback = true; - else - switch (type) { - case "bigint": - case "string": - case "number": - invokeCallback = true; - break; - case "object": - switch (children.$$typeof) { - case REACT_ELEMENT_TYPE: - case REACT_PORTAL_TYPE: - invokeCallback = true; - break; - case REACT_LAZY_TYPE: - return invokeCallback = children._init, mapIntoArray( - invokeCallback(children._payload), - array, - escapedPrefix, - nameSoFar, - callback - ); - } - } - if (invokeCallback) { - invokeCallback = children; - callback = callback(invokeCallback); - var childKey = "" === nameSoFar ? "." + getElementKey(invokeCallback, 0) : nameSoFar; - isArrayImpl(callback) ? (escapedPrefix = "", null != childKey && (escapedPrefix = childKey.replace(userProvidedKeyEscapeRegex, "$&/") + "/"), mapIntoArray(callback, array, escapedPrefix, "", function(c) { - return c; - })) : null != callback && (isValidElement(callback) && (null != callback.key && (invokeCallback && invokeCallback.key === callback.key || checkKeyStringCoercion(callback.key)), escapedPrefix = cloneAndReplaceKey( - callback, - escapedPrefix + (null == callback.key || invokeCallback && invokeCallback.key === callback.key ? "" : ("" + callback.key).replace( - userProvidedKeyEscapeRegex, - "$&/" - ) + "/") + childKey - ), "" !== nameSoFar && null != invokeCallback && isValidElement(invokeCallback) && null == invokeCallback.key && invokeCallback._store && !invokeCallback._store.validated && (escapedPrefix._store.validated = 2), callback = escapedPrefix), array.push(callback)); - return 1; - } - invokeCallback = 0; - childKey = "" === nameSoFar ? "." : nameSoFar + ":"; - if (isArrayImpl(children)) - for (var i = 0; i < children.length; i++) - nameSoFar = children[i], type = childKey + getElementKey(nameSoFar, i), invokeCallback += mapIntoArray( - nameSoFar, - array, - escapedPrefix, - type, - callback - ); - else if (i = getIteratorFn(children), "function" === typeof i) - for (i === children.entries && (didWarnAboutMaps || console.warn( - "Using Maps as children is not supported. Use an array of keyed ReactElements instead." - ), didWarnAboutMaps = true), children = i.call(children), i = 0; !(nameSoFar = children.next()).done; ) - nameSoFar = nameSoFar.value, type = childKey + getElementKey(nameSoFar, i++), invokeCallback += mapIntoArray( - nameSoFar, - array, - escapedPrefix, - type, - callback - ); - else if ("object" === type) { - if ("function" === typeof children.then) - return mapIntoArray( - resolveThenable(children), - array, - escapedPrefix, - nameSoFar, - callback - ); - array = String(children); - throw Error( - "Objects are not valid as a React child (found: " + ("[object Object]" === array ? "object with keys {" + Object.keys(children).join(", ") + "}" : array) + "). If you meant to render a collection of children, use an array instead." - ); - } - return invokeCallback; - } - function mapChildren(children, func, context) { - if (null == children) return children; - var result = [], count = 0; - mapIntoArray(children, result, "", "", function(child) { - return func.call(context, child, count++); - }); - return result; - } - function lazyInitializer(payload) { - if (-1 === payload._status) { - var ctor = payload._result; - ctor = ctor(); - ctor.then( - function(moduleObject) { - if (0 === payload._status || -1 === payload._status) - payload._status = 1, payload._result = moduleObject; - }, - function(error) { - if (0 === payload._status || -1 === payload._status) - payload._status = 2, payload._result = error; - } - ); - -1 === payload._status && (payload._status = 0, payload._result = ctor); - } - if (1 === payload._status) - return ctor = payload._result, void 0 === ctor && console.error( - "lazy: Expected the result of a dynamic import() call. Instead received: %s\n\nYour code should look like: \n const MyComponent = lazy(() => import('./MyComponent'))\n\nDid you accidentally put curly braces around the import?", - ctor - ), "default" in ctor || console.error( - "lazy: Expected the result of a dynamic import() call. Instead received: %s\n\nYour code should look like: \n const MyComponent = lazy(() => import('./MyComponent'))", - ctor - ), ctor.default; - throw payload._result; - } - function resolveDispatcher() { - var dispatcher = ReactSharedInternals.H; - null === dispatcher && console.error( - "Invalid hook call. Hooks can only be called inside of the body of a function component. This could happen for one of the following reasons:\n1. You might have mismatching versions of React and the renderer (such as React DOM)\n2. You might be breaking the Rules of Hooks\n3. You might have more than one copy of React in the same app\nSee https://react.dev/link/invalid-hook-call for tips about how to debug and fix this problem." - ); - return dispatcher; - } - function noop() { - } - function enqueueTask(task) { - if (null === enqueueTaskImpl) - try { - var requireString = ("require" + Math.random()).slice(0, 7); - enqueueTaskImpl = (module && module[requireString]).call( - module, - "timers" - ).setImmediate; - } catch (_err) { - enqueueTaskImpl = function(callback) { - false === didWarnAboutMessageChannel && (didWarnAboutMessageChannel = true, "undefined" === typeof MessageChannel && console.error( - "This browser does not have a MessageChannel implementation, so enqueuing tasks via await act(async () => ...) will fail. Please file an issue at https://github.com/facebook/react/issues if you encounter this warning." - )); - var channel = new MessageChannel(); - channel.port1.onmessage = callback; - channel.port2.postMessage(void 0); - }; - } - return enqueueTaskImpl(task); - } - function aggregateErrors(errors) { - return 1 < errors.length && "function" === typeof AggregateError ? new AggregateError(errors) : errors[0]; - } - function popActScope(prevActQueue, prevActScopeDepth) { - prevActScopeDepth !== actScopeDepth - 1 && console.error( - "You seem to have overlapping act() calls, this is not supported. Be sure to await previous act() calls before making a new one. " - ); - actScopeDepth = prevActScopeDepth; - } - function recursivelyFlushAsyncActWork(returnValue, resolve, reject) { - var queue = ReactSharedInternals.actQueue; - if (null !== queue) - if (0 !== queue.length) - try { - flushActQueue(queue); - enqueueTask(function() { - return recursivelyFlushAsyncActWork(returnValue, resolve, reject); - }); - return; - } catch (error) { - ReactSharedInternals.thrownErrors.push(error); - } - else ReactSharedInternals.actQueue = null; - 0 < ReactSharedInternals.thrownErrors.length ? (queue = aggregateErrors(ReactSharedInternals.thrownErrors), ReactSharedInternals.thrownErrors.length = 0, reject(queue)) : resolve(returnValue); - } - function flushActQueue(queue) { - if (!isFlushing) { - isFlushing = true; - var i = 0; - try { - for (; i < queue.length; i++) { - var callback = queue[i]; - do { - ReactSharedInternals.didUsePromise = false; - var continuation = callback(false); - if (null !== continuation) { - if (ReactSharedInternals.didUsePromise) { - queue[i] = callback; - queue.splice(0, i); - return; - } - callback = continuation; - } else break; - } while (1); - } - queue.length = 0; - } catch (error) { - queue.splice(0, i + 1), ReactSharedInternals.thrownErrors.push(error); - } finally { - isFlushing = false; - } - } - } - "undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ && "function" === typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error()); - var REACT_ELEMENT_TYPE = Symbol.for("react.transitional.element"), REACT_PORTAL_TYPE = Symbol.for("react.portal"), REACT_FRAGMENT_TYPE = Symbol.for("react.fragment"), REACT_STRICT_MODE_TYPE = Symbol.for("react.strict_mode"), REACT_PROFILER_TYPE = Symbol.for("react.profiler"); - Symbol.for("react.provider"); - var REACT_CONSUMER_TYPE = Symbol.for("react.consumer"), REACT_CONTEXT_TYPE = Symbol.for("react.context"), REACT_FORWARD_REF_TYPE = Symbol.for("react.forward_ref"), REACT_SUSPENSE_TYPE = Symbol.for("react.suspense"), REACT_SUSPENSE_LIST_TYPE = Symbol.for("react.suspense_list"), REACT_MEMO_TYPE = Symbol.for("react.memo"), REACT_LAZY_TYPE = Symbol.for("react.lazy"), REACT_OFFSCREEN_TYPE = Symbol.for("react.offscreen"), MAYBE_ITERATOR_SYMBOL = Symbol.iterator, didWarnStateUpdateForUnmountedComponent = {}, ReactNoopUpdateQueue = { - isMounted: function() { - return false; - }, - enqueueForceUpdate: function(publicInstance) { - warnNoop(publicInstance, "forceUpdate"); - }, - enqueueReplaceState: function(publicInstance) { - warnNoop(publicInstance, "replaceState"); - }, - enqueueSetState: function(publicInstance) { - warnNoop(publicInstance, "setState"); - } - }, assign = Object.assign, emptyObject = {}; - Object.freeze(emptyObject); - Component.prototype.isReactComponent = {}; - Component.prototype.setState = function(partialState, callback) { - if ("object" !== typeof partialState && "function" !== typeof partialState && null != partialState) - throw Error( - "takes an object of state variables to update or a function which returns an object of state variables." - ); - this.updater.enqueueSetState(this, partialState, callback, "setState"); - }; - Component.prototype.forceUpdate = function(callback) { - this.updater.enqueueForceUpdate(this, callback, "forceUpdate"); - }; - var deprecatedAPIs = { - isMounted: [ - "isMounted", - "Instead, make sure to clean up subscriptions and pending requests in componentWillUnmount to prevent memory leaks." - ], - replaceState: [ - "replaceState", - "Refactor your code to use setState instead (see https://github.com/facebook/react/issues/3236)." - ] - }, fnName; - for (fnName in deprecatedAPIs) - deprecatedAPIs.hasOwnProperty(fnName) && defineDeprecationWarning(fnName, deprecatedAPIs[fnName]); - ComponentDummy.prototype = Component.prototype; - deprecatedAPIs = PureComponent.prototype = new ComponentDummy(); - deprecatedAPIs.constructor = PureComponent; - assign(deprecatedAPIs, Component.prototype); - deprecatedAPIs.isPureReactComponent = true; - var isArrayImpl = Array.isArray, REACT_CLIENT_REFERENCE$2 = Symbol.for("react.client.reference"), ReactSharedInternals = { - H: null, - A: null, - T: null, - S: null, - actQueue: null, - isBatchingLegacy: false, - didScheduleLegacyUpdate: false, - didUsePromise: false, - thrownErrors: [], - getCurrentStack: null - }, hasOwnProperty = Object.prototype.hasOwnProperty, REACT_CLIENT_REFERENCE$1 = Symbol.for("react.client.reference"), disabledDepth = 0, prevLog, prevInfo, prevWarn, prevError, prevGroup, prevGroupCollapsed, prevGroupEnd; - disabledLog.__reactDisabledLog = true; - var prefix, suffix, reentry = false; - var componentFrameCache = new ("function" === typeof WeakMap ? WeakMap : Map)(); - var REACT_CLIENT_REFERENCE = Symbol.for("react.client.reference"), specialPropKeyWarningShown, didWarnAboutOldJSXRuntime; - var didWarnAboutElementRef = {}; - var ownerHasKeyUseWarning = {}, didWarnAboutMaps = false, userProvidedKeyEscapeRegex = /\/+/g, reportGlobalError = "function" === typeof reportError ? reportError : function(error) { - if ("object" === typeof window && "function" === typeof window.ErrorEvent) { - var event = new window.ErrorEvent("error", { - bubbles: true, - cancelable: true, - message: "object" === typeof error && null !== error && "string" === typeof error.message ? String(error.message) : String(error), - error - }); - if (!window.dispatchEvent(event)) return; - } else if ("object" === typeof process && "function" === typeof process.emit) { - process.emit("uncaughtException", error); - return; - } - console.error(error); - }, didWarnAboutMessageChannel = false, enqueueTaskImpl = null, actScopeDepth = 0, didWarnNoAwaitAct = false, isFlushing = false, queueSeveralMicrotasks = "function" === typeof queueMicrotask ? function(callback) { - queueMicrotask(function() { - return queueMicrotask(callback); - }); - } : enqueueTask; - exports.Children = { - map: mapChildren, - forEach: function(children, forEachFunc, forEachContext) { - mapChildren( - children, - function() { - forEachFunc.apply(this, arguments); - }, - forEachContext - ); - }, - count: function(children) { - var n = 0; - mapChildren(children, function() { - n++; - }); - return n; - }, - toArray: function(children) { - return mapChildren(children, function(child) { - return child; - }) || []; - }, - only: function(children) { - if (!isValidElement(children)) - throw Error( - "React.Children.only expected to receive a single React element child." - ); - return children; - } - }; - exports.Component = Component; - exports.Fragment = REACT_FRAGMENT_TYPE; - exports.Profiler = REACT_PROFILER_TYPE; - exports.PureComponent = PureComponent; - exports.StrictMode = REACT_STRICT_MODE_TYPE; - exports.Suspense = REACT_SUSPENSE_TYPE; - exports.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE = ReactSharedInternals; - exports.act = function(callback) { - var prevActQueue = ReactSharedInternals.actQueue, prevActScopeDepth = actScopeDepth; - actScopeDepth++; - var queue = ReactSharedInternals.actQueue = null !== prevActQueue ? prevActQueue : [], didAwaitActCall = false; - try { - var result = callback(); - } catch (error) { - ReactSharedInternals.thrownErrors.push(error); - } - if (0 < ReactSharedInternals.thrownErrors.length) - throw popActScope(prevActQueue, prevActScopeDepth), callback = aggregateErrors(ReactSharedInternals.thrownErrors), ReactSharedInternals.thrownErrors.length = 0, callback; - if (null !== result && "object" === typeof result && "function" === typeof result.then) { - var thenable = result; - queueSeveralMicrotasks(function() { - didAwaitActCall || didWarnNoAwaitAct || (didWarnNoAwaitAct = true, console.error( - "You called act(async () => ...) without await. This could lead to unexpected testing behaviour, interleaving multiple act calls and mixing their scopes. You should - await act(async () => ...);" - )); - }); - return { - then: function(resolve, reject) { - didAwaitActCall = true; - thenable.then( - function(returnValue) { - popActScope(prevActQueue, prevActScopeDepth); - if (0 === prevActScopeDepth) { - try { - flushActQueue(queue), enqueueTask(function() { - return recursivelyFlushAsyncActWork( - returnValue, - resolve, - reject - ); - }); - } catch (error$2) { - ReactSharedInternals.thrownErrors.push(error$2); - } - if (0 < ReactSharedInternals.thrownErrors.length) { - var _thrownError = aggregateErrors( - ReactSharedInternals.thrownErrors - ); - ReactSharedInternals.thrownErrors.length = 0; - reject(_thrownError); - } - } else resolve(returnValue); - }, - function(error) { - popActScope(prevActQueue, prevActScopeDepth); - 0 < ReactSharedInternals.thrownErrors.length ? (error = aggregateErrors( - ReactSharedInternals.thrownErrors - ), ReactSharedInternals.thrownErrors.length = 0, reject(error)) : reject(error); - } - ); - } - }; - } - var returnValue$jscomp$0 = result; - popActScope(prevActQueue, prevActScopeDepth); - 0 === prevActScopeDepth && (flushActQueue(queue), 0 !== queue.length && queueSeveralMicrotasks(function() { - didAwaitActCall || didWarnNoAwaitAct || (didWarnNoAwaitAct = true, console.error( - "A component suspended inside an `act` scope, but the `act` call was not awaited. When testing React components that depend on asynchronous data, you must await the result:\n\nawait act(() => ...)" - )); - }), ReactSharedInternals.actQueue = null); - if (0 < ReactSharedInternals.thrownErrors.length) - throw callback = aggregateErrors(ReactSharedInternals.thrownErrors), ReactSharedInternals.thrownErrors.length = 0, callback; - return { - then: function(resolve, reject) { - didAwaitActCall = true; - 0 === prevActScopeDepth ? (ReactSharedInternals.actQueue = queue, enqueueTask(function() { - return recursivelyFlushAsyncActWork( - returnValue$jscomp$0, - resolve, - reject - ); - })) : resolve(returnValue$jscomp$0); - } - }; - }; - exports.cache = function(fn) { - return function() { - return fn.apply(null, arguments); - }; - }; - exports.cloneElement = function(element, config, children) { - if (null === element || void 0 === element) - throw Error( - "The argument must be a React element, but you passed " + element + "." - ); - var props = assign({}, element.props), key = element.key, owner = element._owner; - if (null != config) { - var JSCompiler_inline_result; - a: { - if (hasOwnProperty.call(config, "ref") && (JSCompiler_inline_result = Object.getOwnPropertyDescriptor( - config, - "ref" - ).get) && JSCompiler_inline_result.isReactWarning) { - JSCompiler_inline_result = false; - break a; - } - JSCompiler_inline_result = void 0 !== config.ref; - } - JSCompiler_inline_result && (owner = getOwner()); - hasValidKey(config) && (checkKeyStringCoercion(config.key), key = "" + config.key); - for (propName in config) - !hasOwnProperty.call(config, propName) || "key" === propName || "__self" === propName || "__source" === propName || "ref" === propName && void 0 === config.ref || (props[propName] = config[propName]); - } - var propName = arguments.length - 2; - if (1 === propName) props.children = children; - else if (1 < propName) { - JSCompiler_inline_result = Array(propName); - for (var i = 0; i < propName; i++) - JSCompiler_inline_result[i] = arguments[i + 2]; - props.children = JSCompiler_inline_result; - } - props = ReactElement(element.type, key, void 0, void 0, owner, props); - for (key = 2; key < arguments.length; key++) - validateChildKeys(arguments[key], props.type); - return props; - }; - exports.createContext = function(defaultValue) { - defaultValue = { - $$typeof: REACT_CONTEXT_TYPE, - _currentValue: defaultValue, - _currentValue2: defaultValue, - _threadCount: 0, - Provider: null, - Consumer: null - }; - defaultValue.Provider = defaultValue; - defaultValue.Consumer = { - $$typeof: REACT_CONSUMER_TYPE, - _context: defaultValue - }; - defaultValue._currentRenderer = null; - defaultValue._currentRenderer2 = null; - return defaultValue; - }; - exports.createElement = function(type, config, children) { - if (isValidElementType(type)) - for (var i = 2; i < arguments.length; i++) - validateChildKeys(arguments[i], type); - else { - i = ""; - if (void 0 === type || "object" === typeof type && null !== type && 0 === Object.keys(type).length) - i += " You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports."; - if (null === type) var typeString = "null"; - else - isArrayImpl(type) ? typeString = "array" : void 0 !== type && type.$$typeof === REACT_ELEMENT_TYPE ? (typeString = "<" + (getComponentNameFromType(type.type) || "Unknown") + " />", i = " Did you accidentally export a JSX literal instead of a component?") : typeString = typeof type; - console.error( - "React.createElement: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", - typeString, - i - ); - } - var propName; - i = {}; - typeString = null; - if (null != config) - for (propName in didWarnAboutOldJSXRuntime || !("__self" in config) || "key" in config || (didWarnAboutOldJSXRuntime = true, console.warn( - "Your app (or one of its dependencies) is using an outdated JSX transform. Update to the modern JSX transform for faster performance: https://react.dev/link/new-jsx-transform" - )), hasValidKey(config) && (checkKeyStringCoercion(config.key), typeString = "" + config.key), config) - hasOwnProperty.call(config, propName) && "key" !== propName && "__self" !== propName && "__source" !== propName && (i[propName] = config[propName]); - var childrenLength = arguments.length - 2; - if (1 === childrenLength) i.children = children; - else if (1 < childrenLength) { - for (var childArray = Array(childrenLength), _i = 0; _i < childrenLength; _i++) - childArray[_i] = arguments[_i + 2]; - Object.freeze && Object.freeze(childArray); - i.children = childArray; - } - if (type && type.defaultProps) - for (propName in childrenLength = type.defaultProps, childrenLength) - void 0 === i[propName] && (i[propName] = childrenLength[propName]); - typeString && defineKeyPropWarningGetter( - i, - "function" === typeof type ? type.displayName || type.name || "Unknown" : type - ); - return ReactElement(type, typeString, void 0, void 0, getOwner(), i); - }; - exports.createRef = function() { - var refObject = { current: null }; - Object.seal(refObject); - return refObject; - }; - exports.forwardRef = function(render) { - null != render && render.$$typeof === REACT_MEMO_TYPE ? console.error( - "forwardRef requires a render function but received a `memo` component. Instead of forwardRef(memo(...)), use memo(forwardRef(...))." - ) : "function" !== typeof render ? console.error( - "forwardRef requires a render function but was given %s.", - null === render ? "null" : typeof render - ) : 0 !== render.length && 2 !== render.length && console.error( - "forwardRef render functions accept exactly two parameters: props and ref. %s", - 1 === render.length ? "Did you forget to use the ref parameter?" : "Any additional parameter will be undefined." - ); - null != render && null != render.defaultProps && console.error( - "forwardRef render functions do not support defaultProps. Did you accidentally pass a React component?" - ); - var elementType = { $$typeof: REACT_FORWARD_REF_TYPE, render }, ownName; - Object.defineProperty(elementType, "displayName", { - enumerable: false, - configurable: true, - get: function() { - return ownName; - }, - set: function(name) { - ownName = name; - render.name || render.displayName || (Object.defineProperty(render, "name", { value: name }), render.displayName = name); - } - }); - return elementType; - }; - exports.isValidElement = isValidElement; - exports.lazy = function(ctor) { - return { - $$typeof: REACT_LAZY_TYPE, - _payload: { _status: -1, _result: ctor }, - _init: lazyInitializer - }; - }; - exports.memo = function(type, compare) { - isValidElementType(type) || console.error( - "memo: The first argument must be a component. Instead received: %s", - null === type ? "null" : typeof type - ); - compare = { - $$typeof: REACT_MEMO_TYPE, - type, - compare: void 0 === compare ? null : compare - }; - var ownName; - Object.defineProperty(compare, "displayName", { - enumerable: false, - configurable: true, - get: function() { - return ownName; - }, - set: function(name) { - ownName = name; - type.name || type.displayName || (Object.defineProperty(type, "name", { value: name }), type.displayName = name); - } - }); - return compare; - }; - exports.startTransition = function(scope) { - var prevTransition = ReactSharedInternals.T, currentTransition = {}; - ReactSharedInternals.T = currentTransition; - currentTransition._updatedFibers = /* @__PURE__ */ new Set(); - try { - var returnValue = scope(), onStartTransitionFinish = ReactSharedInternals.S; - null !== onStartTransitionFinish && onStartTransitionFinish(currentTransition, returnValue); - "object" === typeof returnValue && null !== returnValue && "function" === typeof returnValue.then && returnValue.then(noop, reportGlobalError); - } catch (error) { - reportGlobalError(error); - } finally { - null === prevTransition && currentTransition._updatedFibers && (scope = currentTransition._updatedFibers.size, currentTransition._updatedFibers.clear(), 10 < scope && console.warn( - "Detected a large number of updates inside startTransition. If this is due to a subscription please re-write it to use React provided hooks. Otherwise concurrent mode guarantees are off the table." - )), ReactSharedInternals.T = prevTransition; - } - }; - exports.unstable_useCacheRefresh = function() { - return resolveDispatcher().useCacheRefresh(); - }; - exports.use = function(usable) { - return resolveDispatcher().use(usable); - }; - exports.useActionState = function(action, initialState, permalink) { - return resolveDispatcher().useActionState( - action, - initialState, - permalink - ); - }; - exports.useCallback = function(callback, deps) { - return resolveDispatcher().useCallback(callback, deps); - }; - exports.useContext = function(Context) { - var dispatcher = resolveDispatcher(); - Context.$$typeof === REACT_CONSUMER_TYPE && console.error( - "Calling useContext(Context.Consumer) is not supported and will cause bugs. Did you mean to call useContext(Context) instead?" - ); - return dispatcher.useContext(Context); - }; - exports.useDebugValue = function(value, formatterFn) { - return resolveDispatcher().useDebugValue(value, formatterFn); - }; - exports.useDeferredValue = function(value, initialValue) { - return resolveDispatcher().useDeferredValue(value, initialValue); - }; - exports.useEffect = function(create, deps) { - return resolveDispatcher().useEffect(create, deps); - }; - exports.useId = function() { - return resolveDispatcher().useId(); - }; - exports.useImperativeHandle = function(ref, create, deps) { - return resolveDispatcher().useImperativeHandle(ref, create, deps); - }; - exports.useInsertionEffect = function(create, deps) { - return resolveDispatcher().useInsertionEffect(create, deps); - }; - exports.useLayoutEffect = function(create, deps) { - return resolveDispatcher().useLayoutEffect(create, deps); - }; - exports.useMemo = function(create, deps) { - return resolveDispatcher().useMemo(create, deps); - }; - exports.useOptimistic = function(passthrough, reducer) { - return resolveDispatcher().useOptimistic(passthrough, reducer); - }; - exports.useReducer = function(reducer, initialArg, init) { - return resolveDispatcher().useReducer(reducer, initialArg, init); - }; - exports.useRef = function(initialValue) { - return resolveDispatcher().useRef(initialValue); - }; - exports.useState = function(initialState) { - return resolveDispatcher().useState(initialState); - }; - exports.useSyncExternalStore = function(subscribe, getSnapshot, getServerSnapshot) { - return resolveDispatcher().useSyncExternalStore( - subscribe, - getSnapshot, - getServerSnapshot - ); - }; - exports.useTransition = function() { - return resolveDispatcher().useTransition(); - }; - exports.version = "19.0.0"; - "undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ && "function" === typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error()); - })(); - } -}); - -// node_modules/.pnpm/react@19.0.0/node_modules/react/index.js -var require_react = __commonJS({ - "node_modules/.pnpm/react@19.0.0/node_modules/react/index.js"(exports, module) { - if (false) { - module.exports = null; - } else { - module.exports = require_react_development(); - } - } -}); - -export { - __commonJS, - require_react -}; -/*! Bundled license information: - -react/cjs/react.development.js: - (** - * @license React - * react.development.js - * - * Copyright (c) Meta Platforms, Inc. and affiliates. - * - * This source code is licensed under the MIT license found in the - * LICENSE file in the root directory of this source tree. - *) -*/ -//# sourceMappingURL=chunk-GNHYFQKO.js.map diff --git a/site/.vite/deps/chunk-GNHYFQKO.js.map b/site/.vite/deps/chunk-GNHYFQKO.js.map deleted file mode 100644 index f2c4ce9..0000000 --- a/site/.vite/deps/chunk-GNHYFQKO.js.map +++ /dev/null @@ -1,7 +0,0 @@ -{ - "version": 3, - "sources": ["../../node_modules/.pnpm/react@19.0.0/node_modules/react/cjs/react.development.js", "../../node_modules/.pnpm/react@19.0.0/node_modules/react/index.js"], - "sourcesContent": ["/**\n * @license React\n * react.development.js\n *\n * Copyright (c) Meta Platforms, Inc. and affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n\"use strict\";\n\"production\" !== process.env.NODE_ENV &&\n (function () {\n function defineDeprecationWarning(methodName, info) {\n Object.defineProperty(Component.prototype, methodName, {\n get: function () {\n console.warn(\n \"%s(...) is deprecated in plain JavaScript React classes. %s\",\n info[0],\n info[1]\n );\n }\n });\n }\n function getIteratorFn(maybeIterable) {\n if (null === maybeIterable || \"object\" !== typeof maybeIterable)\n return null;\n maybeIterable =\n (MAYBE_ITERATOR_SYMBOL && maybeIterable[MAYBE_ITERATOR_SYMBOL]) ||\n maybeIterable[\"@@iterator\"];\n return \"function\" === typeof maybeIterable ? maybeIterable : null;\n }\n function warnNoop(publicInstance, callerName) {\n publicInstance =\n ((publicInstance = publicInstance.constructor) &&\n (publicInstance.displayName || publicInstance.name)) ||\n \"ReactClass\";\n var warningKey = publicInstance + \".\" + callerName;\n didWarnStateUpdateForUnmountedComponent[warningKey] ||\n (console.error(\n \"Can't call %s on a component that is not yet mounted. This is a no-op, but it might indicate a bug in your application. Instead, assign to `this.state` directly or define a `state = {};` class property with the desired state in the %s component.\",\n callerName,\n publicInstance\n ),\n (didWarnStateUpdateForUnmountedComponent[warningKey] = !0));\n }\n function Component(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n this.updater = updater || ReactNoopUpdateQueue;\n }\n function ComponentDummy() {}\n function PureComponent(props, context, updater) {\n this.props = props;\n this.context = context;\n this.refs = emptyObject;\n this.updater = updater || ReactNoopUpdateQueue;\n }\n function testStringCoercion(value) {\n return \"\" + value;\n }\n function checkKeyStringCoercion(value) {\n try {\n testStringCoercion(value);\n var JSCompiler_inline_result = !1;\n } catch (e) {\n JSCompiler_inline_result = !0;\n }\n if (JSCompiler_inline_result) {\n JSCompiler_inline_result = console;\n var JSCompiler_temp_const = JSCompiler_inline_result.error;\n var JSCompiler_inline_result$jscomp$0 =\n (\"function\" === typeof Symbol &&\n Symbol.toStringTag &&\n value[Symbol.toStringTag]) ||\n value.constructor.name ||\n \"Object\";\n JSCompiler_temp_const.call(\n JSCompiler_inline_result,\n \"The provided key is an unsupported type %s. This value must be coerced to a string before using it here.\",\n JSCompiler_inline_result$jscomp$0\n );\n return testStringCoercion(value);\n }\n }\n function getComponentNameFromType(type) {\n if (null == type) return null;\n if (\"function\" === typeof type)\n return type.$$typeof === REACT_CLIENT_REFERENCE$2\n ? null\n : type.displayName || type.name || null;\n if (\"string\" === typeof type) return type;\n switch (type) {\n case REACT_FRAGMENT_TYPE:\n return \"Fragment\";\n case REACT_PORTAL_TYPE:\n return \"Portal\";\n case REACT_PROFILER_TYPE:\n return \"Profiler\";\n case REACT_STRICT_MODE_TYPE:\n return \"StrictMode\";\n case REACT_SUSPENSE_TYPE:\n return \"Suspense\";\n case REACT_SUSPENSE_LIST_TYPE:\n return \"SuspenseList\";\n }\n if (\"object\" === typeof type)\n switch (\n (\"number\" === typeof type.tag &&\n console.error(\n \"Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue.\"\n ),\n type.$$typeof)\n ) {\n case REACT_CONTEXT_TYPE:\n return (type.displayName || \"Context\") + \".Provider\";\n case REACT_CONSUMER_TYPE:\n return (type._context.displayName || \"Context\") + \".Consumer\";\n case REACT_FORWARD_REF_TYPE:\n var innerType = type.render;\n type = type.displayName;\n type ||\n ((type = innerType.displayName || innerType.name || \"\"),\n (type = \"\" !== type ? \"ForwardRef(\" + type + \")\" : \"ForwardRef\"));\n return type;\n case REACT_MEMO_TYPE:\n return (\n (innerType = type.displayName || null),\n null !== innerType\n ? innerType\n : getComponentNameFromType(type.type) || \"Memo\"\n );\n case REACT_LAZY_TYPE:\n innerType = type._payload;\n type = type._init;\n try {\n return getComponentNameFromType(type(innerType));\n } catch (x) {}\n }\n return null;\n }\n function isValidElementType(type) {\n return \"string\" === typeof type ||\n \"function\" === typeof type ||\n type === REACT_FRAGMENT_TYPE ||\n type === REACT_PROFILER_TYPE ||\n type === REACT_STRICT_MODE_TYPE ||\n type === REACT_SUSPENSE_TYPE ||\n type === REACT_SUSPENSE_LIST_TYPE ||\n type === REACT_OFFSCREEN_TYPE ||\n (\"object\" === typeof type &&\n null !== type &&\n (type.$$typeof === REACT_LAZY_TYPE ||\n type.$$typeof === REACT_MEMO_TYPE ||\n type.$$typeof === REACT_CONTEXT_TYPE ||\n type.$$typeof === REACT_CONSUMER_TYPE ||\n type.$$typeof === REACT_FORWARD_REF_TYPE ||\n type.$$typeof === REACT_CLIENT_REFERENCE$1 ||\n void 0 !== type.getModuleId))\n ? !0\n : !1;\n }\n function disabledLog() {}\n function disableLogs() {\n if (0 === disabledDepth) {\n prevLog = console.log;\n prevInfo = console.info;\n prevWarn = console.warn;\n prevError = console.error;\n prevGroup = console.group;\n prevGroupCollapsed = console.groupCollapsed;\n prevGroupEnd = console.groupEnd;\n var props = {\n configurable: !0,\n enumerable: !0,\n value: disabledLog,\n writable: !0\n };\n Object.defineProperties(console, {\n info: props,\n log: props,\n warn: props,\n error: props,\n group: props,\n groupCollapsed: props,\n groupEnd: props\n });\n }\n disabledDepth++;\n }\n function reenableLogs() {\n disabledDepth--;\n if (0 === disabledDepth) {\n var props = { configurable: !0, enumerable: !0, writable: !0 };\n Object.defineProperties(console, {\n log: assign({}, props, { value: prevLog }),\n info: assign({}, props, { value: prevInfo }),\n warn: assign({}, props, { value: prevWarn }),\n error: assign({}, props, { value: prevError }),\n group: assign({}, props, { value: prevGroup }),\n groupCollapsed: assign({}, props, { value: prevGroupCollapsed }),\n groupEnd: assign({}, props, { value: prevGroupEnd })\n });\n }\n 0 > disabledDepth &&\n console.error(\n \"disabledDepth fell below zero. This is a bug in React. Please file an issue.\"\n );\n }\n function describeBuiltInComponentFrame(name) {\n if (void 0 === prefix)\n try {\n throw Error();\n } catch (x) {\n var match = x.stack.trim().match(/\\n( *(at )?)/);\n prefix = (match && match[1]) || \"\";\n suffix =\n -1 < x.stack.indexOf(\"\\n at\")\n ? \" ()\"\n : -1 < x.stack.indexOf(\"@\")\n ? \"@unknown:0:0\"\n : \"\";\n }\n return \"\\n\" + prefix + name + suffix;\n }\n function describeNativeComponentFrame(fn, construct) {\n if (!fn || reentry) return \"\";\n var frame = componentFrameCache.get(fn);\n if (void 0 !== frame) return frame;\n reentry = !0;\n frame = Error.prepareStackTrace;\n Error.prepareStackTrace = void 0;\n var previousDispatcher = null;\n previousDispatcher = ReactSharedInternals.H;\n ReactSharedInternals.H = null;\n disableLogs();\n try {\n var RunInRootFrame = {\n DetermineComponentFrameRoot: function () {\n try {\n if (construct) {\n var Fake = function () {\n throw Error();\n };\n Object.defineProperty(Fake.prototype, \"props\", {\n set: function () {\n throw Error();\n }\n });\n if (\"object\" === typeof Reflect && Reflect.construct) {\n try {\n Reflect.construct(Fake, []);\n } catch (x) {\n var control = x;\n }\n Reflect.construct(fn, [], Fake);\n } else {\n try {\n Fake.call();\n } catch (x$0) {\n control = x$0;\n }\n fn.call(Fake.prototype);\n }\n } else {\n try {\n throw Error();\n } catch (x$1) {\n control = x$1;\n }\n (Fake = fn()) &&\n \"function\" === typeof Fake.catch &&\n Fake.catch(function () {});\n }\n } catch (sample) {\n if (sample && control && \"string\" === typeof sample.stack)\n return [sample.stack, control.stack];\n }\n return [null, null];\n }\n };\n RunInRootFrame.DetermineComponentFrameRoot.displayName =\n \"DetermineComponentFrameRoot\";\n var namePropDescriptor = Object.getOwnPropertyDescriptor(\n RunInRootFrame.DetermineComponentFrameRoot,\n \"name\"\n );\n namePropDescriptor &&\n namePropDescriptor.configurable &&\n Object.defineProperty(\n RunInRootFrame.DetermineComponentFrameRoot,\n \"name\",\n { value: \"DetermineComponentFrameRoot\" }\n );\n var _RunInRootFrame$Deter =\n RunInRootFrame.DetermineComponentFrameRoot(),\n sampleStack = _RunInRootFrame$Deter[0],\n controlStack = _RunInRootFrame$Deter[1];\n if (sampleStack && controlStack) {\n var sampleLines = sampleStack.split(\"\\n\"),\n controlLines = controlStack.split(\"\\n\");\n for (\n _RunInRootFrame$Deter = namePropDescriptor = 0;\n namePropDescriptor < sampleLines.length &&\n !sampleLines[namePropDescriptor].includes(\n \"DetermineComponentFrameRoot\"\n );\n\n )\n namePropDescriptor++;\n for (\n ;\n _RunInRootFrame$Deter < controlLines.length &&\n !controlLines[_RunInRootFrame$Deter].includes(\n \"DetermineComponentFrameRoot\"\n );\n\n )\n _RunInRootFrame$Deter++;\n if (\n namePropDescriptor === sampleLines.length ||\n _RunInRootFrame$Deter === controlLines.length\n )\n for (\n namePropDescriptor = sampleLines.length - 1,\n _RunInRootFrame$Deter = controlLines.length - 1;\n 1 <= namePropDescriptor &&\n 0 <= _RunInRootFrame$Deter &&\n sampleLines[namePropDescriptor] !==\n controlLines[_RunInRootFrame$Deter];\n\n )\n _RunInRootFrame$Deter--;\n for (\n ;\n 1 <= namePropDescriptor && 0 <= _RunInRootFrame$Deter;\n namePropDescriptor--, _RunInRootFrame$Deter--\n )\n if (\n sampleLines[namePropDescriptor] !==\n controlLines[_RunInRootFrame$Deter]\n ) {\n if (1 !== namePropDescriptor || 1 !== _RunInRootFrame$Deter) {\n do\n if (\n (namePropDescriptor--,\n _RunInRootFrame$Deter--,\n 0 > _RunInRootFrame$Deter ||\n sampleLines[namePropDescriptor] !==\n controlLines[_RunInRootFrame$Deter])\n ) {\n var _frame =\n \"\\n\" +\n sampleLines[namePropDescriptor].replace(\n \" at new \",\n \" at \"\n );\n fn.displayName &&\n _frame.includes(\"\") &&\n (_frame = _frame.replace(\"\", fn.displayName));\n \"function\" === typeof fn &&\n componentFrameCache.set(fn, _frame);\n return _frame;\n }\n while (1 <= namePropDescriptor && 0 <= _RunInRootFrame$Deter);\n }\n break;\n }\n }\n } finally {\n (reentry = !1),\n (ReactSharedInternals.H = previousDispatcher),\n reenableLogs(),\n (Error.prepareStackTrace = frame);\n }\n sampleLines = (sampleLines = fn ? fn.displayName || fn.name : \"\")\n ? describeBuiltInComponentFrame(sampleLines)\n : \"\";\n \"function\" === typeof fn && componentFrameCache.set(fn, sampleLines);\n return sampleLines;\n }\n function describeUnknownElementTypeFrameInDEV(type) {\n if (null == type) return \"\";\n if (\"function\" === typeof type) {\n var prototype = type.prototype;\n return describeNativeComponentFrame(\n type,\n !(!prototype || !prototype.isReactComponent)\n );\n }\n if (\"string\" === typeof type) return describeBuiltInComponentFrame(type);\n switch (type) {\n case REACT_SUSPENSE_TYPE:\n return describeBuiltInComponentFrame(\"Suspense\");\n case REACT_SUSPENSE_LIST_TYPE:\n return describeBuiltInComponentFrame(\"SuspenseList\");\n }\n if (\"object\" === typeof type)\n switch (type.$$typeof) {\n case REACT_FORWARD_REF_TYPE:\n return (type = describeNativeComponentFrame(type.render, !1)), type;\n case REACT_MEMO_TYPE:\n return describeUnknownElementTypeFrameInDEV(type.type);\n case REACT_LAZY_TYPE:\n prototype = type._payload;\n type = type._init;\n try {\n return describeUnknownElementTypeFrameInDEV(type(prototype));\n } catch (x) {}\n }\n return \"\";\n }\n function getOwner() {\n var dispatcher = ReactSharedInternals.A;\n return null === dispatcher ? null : dispatcher.getOwner();\n }\n function hasValidKey(config) {\n if (hasOwnProperty.call(config, \"key\")) {\n var getter = Object.getOwnPropertyDescriptor(config, \"key\").get;\n if (getter && getter.isReactWarning) return !1;\n }\n return void 0 !== config.key;\n }\n function defineKeyPropWarningGetter(props, displayName) {\n function warnAboutAccessingKey() {\n specialPropKeyWarningShown ||\n ((specialPropKeyWarningShown = !0),\n console.error(\n \"%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://react.dev/link/special-props)\",\n displayName\n ));\n }\n warnAboutAccessingKey.isReactWarning = !0;\n Object.defineProperty(props, \"key\", {\n get: warnAboutAccessingKey,\n configurable: !0\n });\n }\n function elementRefGetterWithDeprecationWarning() {\n var componentName = getComponentNameFromType(this.type);\n didWarnAboutElementRef[componentName] ||\n ((didWarnAboutElementRef[componentName] = !0),\n console.error(\n \"Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release.\"\n ));\n componentName = this.props.ref;\n return void 0 !== componentName ? componentName : null;\n }\n function ReactElement(type, key, self, source, owner, props) {\n self = props.ref;\n type = {\n $$typeof: REACT_ELEMENT_TYPE,\n type: type,\n key: key,\n props: props,\n _owner: owner\n };\n null !== (void 0 !== self ? self : null)\n ? Object.defineProperty(type, \"ref\", {\n enumerable: !1,\n get: elementRefGetterWithDeprecationWarning\n })\n : Object.defineProperty(type, \"ref\", { enumerable: !1, value: null });\n type._store = {};\n Object.defineProperty(type._store, \"validated\", {\n configurable: !1,\n enumerable: !1,\n writable: !0,\n value: 0\n });\n Object.defineProperty(type, \"_debugInfo\", {\n configurable: !1,\n enumerable: !1,\n writable: !0,\n value: null\n });\n Object.freeze && (Object.freeze(type.props), Object.freeze(type));\n return type;\n }\n function cloneAndReplaceKey(oldElement, newKey) {\n newKey = ReactElement(\n oldElement.type,\n newKey,\n void 0,\n void 0,\n oldElement._owner,\n oldElement.props\n );\n newKey._store.validated = oldElement._store.validated;\n return newKey;\n }\n function validateChildKeys(node, parentType) {\n if (\n \"object\" === typeof node &&\n node &&\n node.$$typeof !== REACT_CLIENT_REFERENCE\n )\n if (isArrayImpl(node))\n for (var i = 0; i < node.length; i++) {\n var child = node[i];\n isValidElement(child) && validateExplicitKey(child, parentType);\n }\n else if (isValidElement(node))\n node._store && (node._store.validated = 1);\n else if (\n ((i = getIteratorFn(node)),\n \"function\" === typeof i &&\n i !== node.entries &&\n ((i = i.call(node)), i !== node))\n )\n for (; !(node = i.next()).done; )\n isValidElement(node.value) &&\n validateExplicitKey(node.value, parentType);\n }\n function isValidElement(object) {\n return (\n \"object\" === typeof object &&\n null !== object &&\n object.$$typeof === REACT_ELEMENT_TYPE\n );\n }\n function validateExplicitKey(element, parentType) {\n if (\n element._store &&\n !element._store.validated &&\n null == element.key &&\n ((element._store.validated = 1),\n (parentType = getCurrentComponentErrorInfo(parentType)),\n !ownerHasKeyUseWarning[parentType])\n ) {\n ownerHasKeyUseWarning[parentType] = !0;\n var childOwner = \"\";\n element &&\n null != element._owner &&\n element._owner !== getOwner() &&\n ((childOwner = null),\n \"number\" === typeof element._owner.tag\n ? (childOwner = getComponentNameFromType(element._owner.type))\n : \"string\" === typeof element._owner.name &&\n (childOwner = element._owner.name),\n (childOwner = \" It was passed a child from \" + childOwner + \".\"));\n var prevGetCurrentStack = ReactSharedInternals.getCurrentStack;\n ReactSharedInternals.getCurrentStack = function () {\n var stack = describeUnknownElementTypeFrameInDEV(element.type);\n prevGetCurrentStack && (stack += prevGetCurrentStack() || \"\");\n return stack;\n };\n console.error(\n 'Each child in a list should have a unique \"key\" prop.%s%s See https://react.dev/link/warning-keys for more information.',\n parentType,\n childOwner\n );\n ReactSharedInternals.getCurrentStack = prevGetCurrentStack;\n }\n }\n function getCurrentComponentErrorInfo(parentType) {\n var info = \"\",\n owner = getOwner();\n owner &&\n (owner = getComponentNameFromType(owner.type)) &&\n (info = \"\\n\\nCheck the render method of `\" + owner + \"`.\");\n info ||\n ((parentType = getComponentNameFromType(parentType)) &&\n (info =\n \"\\n\\nCheck the top-level render call using <\" + parentType + \">.\"));\n return info;\n }\n function escape(key) {\n var escaperLookup = { \"=\": \"=0\", \":\": \"=2\" };\n return (\n \"$\" +\n key.replace(/[=:]/g, function (match) {\n return escaperLookup[match];\n })\n );\n }\n function getElementKey(element, index) {\n return \"object\" === typeof element &&\n null !== element &&\n null != element.key\n ? (checkKeyStringCoercion(element.key), escape(\"\" + element.key))\n : index.toString(36);\n }\n function noop$1() {}\n function resolveThenable(thenable) {\n switch (thenable.status) {\n case \"fulfilled\":\n return thenable.value;\n case \"rejected\":\n throw thenable.reason;\n default:\n switch (\n (\"string\" === typeof thenable.status\n ? thenable.then(noop$1, noop$1)\n : ((thenable.status = \"pending\"),\n thenable.then(\n function (fulfilledValue) {\n \"pending\" === thenable.status &&\n ((thenable.status = \"fulfilled\"),\n (thenable.value = fulfilledValue));\n },\n function (error) {\n \"pending\" === thenable.status &&\n ((thenable.status = \"rejected\"),\n (thenable.reason = error));\n }\n )),\n thenable.status)\n ) {\n case \"fulfilled\":\n return thenable.value;\n case \"rejected\":\n throw thenable.reason;\n }\n }\n throw thenable;\n }\n function mapIntoArray(children, array, escapedPrefix, nameSoFar, callback) {\n var type = typeof children;\n if (\"undefined\" === type || \"boolean\" === type) children = null;\n var invokeCallback = !1;\n if (null === children) invokeCallback = !0;\n else\n switch (type) {\n case \"bigint\":\n case \"string\":\n case \"number\":\n invokeCallback = !0;\n break;\n case \"object\":\n switch (children.$$typeof) {\n case REACT_ELEMENT_TYPE:\n case REACT_PORTAL_TYPE:\n invokeCallback = !0;\n break;\n case REACT_LAZY_TYPE:\n return (\n (invokeCallback = children._init),\n mapIntoArray(\n invokeCallback(children._payload),\n array,\n escapedPrefix,\n nameSoFar,\n callback\n )\n );\n }\n }\n if (invokeCallback) {\n invokeCallback = children;\n callback = callback(invokeCallback);\n var childKey =\n \"\" === nameSoFar ? \".\" + getElementKey(invokeCallback, 0) : nameSoFar;\n isArrayImpl(callback)\n ? ((escapedPrefix = \"\"),\n null != childKey &&\n (escapedPrefix =\n childKey.replace(userProvidedKeyEscapeRegex, \"$&/\") + \"/\"),\n mapIntoArray(callback, array, escapedPrefix, \"\", function (c) {\n return c;\n }))\n : null != callback &&\n (isValidElement(callback) &&\n (null != callback.key &&\n ((invokeCallback && invokeCallback.key === callback.key) ||\n checkKeyStringCoercion(callback.key)),\n (escapedPrefix = cloneAndReplaceKey(\n callback,\n escapedPrefix +\n (null == callback.key ||\n (invokeCallback && invokeCallback.key === callback.key)\n ? \"\"\n : (\"\" + callback.key).replace(\n userProvidedKeyEscapeRegex,\n \"$&/\"\n ) + \"/\") +\n childKey\n )),\n \"\" !== nameSoFar &&\n null != invokeCallback &&\n isValidElement(invokeCallback) &&\n null == invokeCallback.key &&\n invokeCallback._store &&\n !invokeCallback._store.validated &&\n (escapedPrefix._store.validated = 2),\n (callback = escapedPrefix)),\n array.push(callback));\n return 1;\n }\n invokeCallback = 0;\n childKey = \"\" === nameSoFar ? \".\" : nameSoFar + \":\";\n if (isArrayImpl(children))\n for (var i = 0; i < children.length; i++)\n (nameSoFar = children[i]),\n (type = childKey + getElementKey(nameSoFar, i)),\n (invokeCallback += mapIntoArray(\n nameSoFar,\n array,\n escapedPrefix,\n type,\n callback\n ));\n else if (((i = getIteratorFn(children)), \"function\" === typeof i))\n for (\n i === children.entries &&\n (didWarnAboutMaps ||\n console.warn(\n \"Using Maps as children is not supported. Use an array of keyed ReactElements instead.\"\n ),\n (didWarnAboutMaps = !0)),\n children = i.call(children),\n i = 0;\n !(nameSoFar = children.next()).done;\n\n )\n (nameSoFar = nameSoFar.value),\n (type = childKey + getElementKey(nameSoFar, i++)),\n (invokeCallback += mapIntoArray(\n nameSoFar,\n array,\n escapedPrefix,\n type,\n callback\n ));\n else if (\"object\" === type) {\n if (\"function\" === typeof children.then)\n return mapIntoArray(\n resolveThenable(children),\n array,\n escapedPrefix,\n nameSoFar,\n callback\n );\n array = String(children);\n throw Error(\n \"Objects are not valid as a React child (found: \" +\n (\"[object Object]\" === array\n ? \"object with keys {\" + Object.keys(children).join(\", \") + \"}\"\n : array) +\n \"). If you meant to render a collection of children, use an array instead.\"\n );\n }\n return invokeCallback;\n }\n function mapChildren(children, func, context) {\n if (null == children) return children;\n var result = [],\n count = 0;\n mapIntoArray(children, result, \"\", \"\", function (child) {\n return func.call(context, child, count++);\n });\n return result;\n }\n function lazyInitializer(payload) {\n if (-1 === payload._status) {\n var ctor = payload._result;\n ctor = ctor();\n ctor.then(\n function (moduleObject) {\n if (0 === payload._status || -1 === payload._status)\n (payload._status = 1), (payload._result = moduleObject);\n },\n function (error) {\n if (0 === payload._status || -1 === payload._status)\n (payload._status = 2), (payload._result = error);\n }\n );\n -1 === payload._status &&\n ((payload._status = 0), (payload._result = ctor));\n }\n if (1 === payload._status)\n return (\n (ctor = payload._result),\n void 0 === ctor &&\n console.error(\n \"lazy: Expected the result of a dynamic import() call. Instead received: %s\\n\\nYour code should look like: \\n const MyComponent = lazy(() => import('./MyComponent'))\\n\\nDid you accidentally put curly braces around the import?\",\n ctor\n ),\n \"default\" in ctor ||\n console.error(\n \"lazy: Expected the result of a dynamic import() call. Instead received: %s\\n\\nYour code should look like: \\n const MyComponent = lazy(() => import('./MyComponent'))\",\n ctor\n ),\n ctor.default\n );\n throw payload._result;\n }\n function resolveDispatcher() {\n var dispatcher = ReactSharedInternals.H;\n null === dispatcher &&\n console.error(\n \"Invalid hook call. Hooks can only be called inside of the body of a function component. This could happen for one of the following reasons:\\n1. You might have mismatching versions of React and the renderer (such as React DOM)\\n2. You might be breaking the Rules of Hooks\\n3. You might have more than one copy of React in the same app\\nSee https://react.dev/link/invalid-hook-call for tips about how to debug and fix this problem.\"\n );\n return dispatcher;\n }\n function noop() {}\n function enqueueTask(task) {\n if (null === enqueueTaskImpl)\n try {\n var requireString = (\"require\" + Math.random()).slice(0, 7);\n enqueueTaskImpl = (module && module[requireString]).call(\n module,\n \"timers\"\n ).setImmediate;\n } catch (_err) {\n enqueueTaskImpl = function (callback) {\n !1 === didWarnAboutMessageChannel &&\n ((didWarnAboutMessageChannel = !0),\n \"undefined\" === typeof MessageChannel &&\n console.error(\n \"This browser does not have a MessageChannel implementation, so enqueuing tasks via await act(async () => ...) will fail. Please file an issue at https://github.com/facebook/react/issues if you encounter this warning.\"\n ));\n var channel = new MessageChannel();\n channel.port1.onmessage = callback;\n channel.port2.postMessage(void 0);\n };\n }\n return enqueueTaskImpl(task);\n }\n function aggregateErrors(errors) {\n return 1 < errors.length && \"function\" === typeof AggregateError\n ? new AggregateError(errors)\n : errors[0];\n }\n function popActScope(prevActQueue, prevActScopeDepth) {\n prevActScopeDepth !== actScopeDepth - 1 &&\n console.error(\n \"You seem to have overlapping act() calls, this is not supported. Be sure to await previous act() calls before making a new one. \"\n );\n actScopeDepth = prevActScopeDepth;\n }\n function recursivelyFlushAsyncActWork(returnValue, resolve, reject) {\n var queue = ReactSharedInternals.actQueue;\n if (null !== queue)\n if (0 !== queue.length)\n try {\n flushActQueue(queue);\n enqueueTask(function () {\n return recursivelyFlushAsyncActWork(returnValue, resolve, reject);\n });\n return;\n } catch (error) {\n ReactSharedInternals.thrownErrors.push(error);\n }\n else ReactSharedInternals.actQueue = null;\n 0 < ReactSharedInternals.thrownErrors.length\n ? ((queue = aggregateErrors(ReactSharedInternals.thrownErrors)),\n (ReactSharedInternals.thrownErrors.length = 0),\n reject(queue))\n : resolve(returnValue);\n }\n function flushActQueue(queue) {\n if (!isFlushing) {\n isFlushing = !0;\n var i = 0;\n try {\n for (; i < queue.length; i++) {\n var callback = queue[i];\n do {\n ReactSharedInternals.didUsePromise = !1;\n var continuation = callback(!1);\n if (null !== continuation) {\n if (ReactSharedInternals.didUsePromise) {\n queue[i] = callback;\n queue.splice(0, i);\n return;\n }\n callback = continuation;\n } else break;\n } while (1);\n }\n queue.length = 0;\n } catch (error) {\n queue.splice(0, i + 1), ReactSharedInternals.thrownErrors.push(error);\n } finally {\n isFlushing = !1;\n }\n }\n }\n \"undefined\" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ &&\n \"function\" ===\n typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart &&\n __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());\n var REACT_ELEMENT_TYPE = Symbol.for(\"react.transitional.element\"),\n REACT_PORTAL_TYPE = Symbol.for(\"react.portal\"),\n REACT_FRAGMENT_TYPE = Symbol.for(\"react.fragment\"),\n REACT_STRICT_MODE_TYPE = Symbol.for(\"react.strict_mode\"),\n REACT_PROFILER_TYPE = Symbol.for(\"react.profiler\");\n Symbol.for(\"react.provider\");\n var REACT_CONSUMER_TYPE = Symbol.for(\"react.consumer\"),\n REACT_CONTEXT_TYPE = Symbol.for(\"react.context\"),\n REACT_FORWARD_REF_TYPE = Symbol.for(\"react.forward_ref\"),\n REACT_SUSPENSE_TYPE = Symbol.for(\"react.suspense\"),\n REACT_SUSPENSE_LIST_TYPE = Symbol.for(\"react.suspense_list\"),\n REACT_MEMO_TYPE = Symbol.for(\"react.memo\"),\n REACT_LAZY_TYPE = Symbol.for(\"react.lazy\"),\n REACT_OFFSCREEN_TYPE = Symbol.for(\"react.offscreen\"),\n MAYBE_ITERATOR_SYMBOL = Symbol.iterator,\n didWarnStateUpdateForUnmountedComponent = {},\n ReactNoopUpdateQueue = {\n isMounted: function () {\n return !1;\n },\n enqueueForceUpdate: function (publicInstance) {\n warnNoop(publicInstance, \"forceUpdate\");\n },\n enqueueReplaceState: function (publicInstance) {\n warnNoop(publicInstance, \"replaceState\");\n },\n enqueueSetState: function (publicInstance) {\n warnNoop(publicInstance, \"setState\");\n }\n },\n assign = Object.assign,\n emptyObject = {};\n Object.freeze(emptyObject);\n Component.prototype.isReactComponent = {};\n Component.prototype.setState = function (partialState, callback) {\n if (\n \"object\" !== typeof partialState &&\n \"function\" !== typeof partialState &&\n null != partialState\n )\n throw Error(\n \"takes an object of state variables to update or a function which returns an object of state variables.\"\n );\n this.updater.enqueueSetState(this, partialState, callback, \"setState\");\n };\n Component.prototype.forceUpdate = function (callback) {\n this.updater.enqueueForceUpdate(this, callback, \"forceUpdate\");\n };\n var deprecatedAPIs = {\n isMounted: [\n \"isMounted\",\n \"Instead, make sure to clean up subscriptions and pending requests in componentWillUnmount to prevent memory leaks.\"\n ],\n replaceState: [\n \"replaceState\",\n \"Refactor your code to use setState instead (see https://github.com/facebook/react/issues/3236).\"\n ]\n },\n fnName;\n for (fnName in deprecatedAPIs)\n deprecatedAPIs.hasOwnProperty(fnName) &&\n defineDeprecationWarning(fnName, deprecatedAPIs[fnName]);\n ComponentDummy.prototype = Component.prototype;\n deprecatedAPIs = PureComponent.prototype = new ComponentDummy();\n deprecatedAPIs.constructor = PureComponent;\n assign(deprecatedAPIs, Component.prototype);\n deprecatedAPIs.isPureReactComponent = !0;\n var isArrayImpl = Array.isArray,\n REACT_CLIENT_REFERENCE$2 = Symbol.for(\"react.client.reference\"),\n ReactSharedInternals = {\n H: null,\n A: null,\n T: null,\n S: null,\n actQueue: null,\n isBatchingLegacy: !1,\n didScheduleLegacyUpdate: !1,\n didUsePromise: !1,\n thrownErrors: [],\n getCurrentStack: null\n },\n hasOwnProperty = Object.prototype.hasOwnProperty,\n REACT_CLIENT_REFERENCE$1 = Symbol.for(\"react.client.reference\"),\n disabledDepth = 0,\n prevLog,\n prevInfo,\n prevWarn,\n prevError,\n prevGroup,\n prevGroupCollapsed,\n prevGroupEnd;\n disabledLog.__reactDisabledLog = !0;\n var prefix,\n suffix,\n reentry = !1;\n var componentFrameCache = new (\n \"function\" === typeof WeakMap ? WeakMap : Map\n )();\n var REACT_CLIENT_REFERENCE = Symbol.for(\"react.client.reference\"),\n specialPropKeyWarningShown,\n didWarnAboutOldJSXRuntime;\n var didWarnAboutElementRef = {};\n var ownerHasKeyUseWarning = {},\n didWarnAboutMaps = !1,\n userProvidedKeyEscapeRegex = /\\/+/g,\n reportGlobalError =\n \"function\" === typeof reportError\n ? reportError\n : function (error) {\n if (\n \"object\" === typeof window &&\n \"function\" === typeof window.ErrorEvent\n ) {\n var event = new window.ErrorEvent(\"error\", {\n bubbles: !0,\n cancelable: !0,\n message:\n \"object\" === typeof error &&\n null !== error &&\n \"string\" === typeof error.message\n ? String(error.message)\n : String(error),\n error: error\n });\n if (!window.dispatchEvent(event)) return;\n } else if (\n \"object\" === typeof process &&\n \"function\" === typeof process.emit\n ) {\n process.emit(\"uncaughtException\", error);\n return;\n }\n console.error(error);\n },\n didWarnAboutMessageChannel = !1,\n enqueueTaskImpl = null,\n actScopeDepth = 0,\n didWarnNoAwaitAct = !1,\n isFlushing = !1,\n queueSeveralMicrotasks =\n \"function\" === typeof queueMicrotask\n ? function (callback) {\n queueMicrotask(function () {\n return queueMicrotask(callback);\n });\n }\n : enqueueTask;\n exports.Children = {\n map: mapChildren,\n forEach: function (children, forEachFunc, forEachContext) {\n mapChildren(\n children,\n function () {\n forEachFunc.apply(this, arguments);\n },\n forEachContext\n );\n },\n count: function (children) {\n var n = 0;\n mapChildren(children, function () {\n n++;\n });\n return n;\n },\n toArray: function (children) {\n return (\n mapChildren(children, function (child) {\n return child;\n }) || []\n );\n },\n only: function (children) {\n if (!isValidElement(children))\n throw Error(\n \"React.Children.only expected to receive a single React element child.\"\n );\n return children;\n }\n };\n exports.Component = Component;\n exports.Fragment = REACT_FRAGMENT_TYPE;\n exports.Profiler = REACT_PROFILER_TYPE;\n exports.PureComponent = PureComponent;\n exports.StrictMode = REACT_STRICT_MODE_TYPE;\n exports.Suspense = REACT_SUSPENSE_TYPE;\n exports.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE =\n ReactSharedInternals;\n exports.act = function (callback) {\n var prevActQueue = ReactSharedInternals.actQueue,\n prevActScopeDepth = actScopeDepth;\n actScopeDepth++;\n var queue = (ReactSharedInternals.actQueue =\n null !== prevActQueue ? prevActQueue : []),\n didAwaitActCall = !1;\n try {\n var result = callback();\n } catch (error) {\n ReactSharedInternals.thrownErrors.push(error);\n }\n if (0 < ReactSharedInternals.thrownErrors.length)\n throw (\n (popActScope(prevActQueue, prevActScopeDepth),\n (callback = aggregateErrors(ReactSharedInternals.thrownErrors)),\n (ReactSharedInternals.thrownErrors.length = 0),\n callback)\n );\n if (\n null !== result &&\n \"object\" === typeof result &&\n \"function\" === typeof result.then\n ) {\n var thenable = result;\n queueSeveralMicrotasks(function () {\n didAwaitActCall ||\n didWarnNoAwaitAct ||\n ((didWarnNoAwaitAct = !0),\n console.error(\n \"You called act(async () => ...) without await. This could lead to unexpected testing behaviour, interleaving multiple act calls and mixing their scopes. You should - await act(async () => ...);\"\n ));\n });\n return {\n then: function (resolve, reject) {\n didAwaitActCall = !0;\n thenable.then(\n function (returnValue) {\n popActScope(prevActQueue, prevActScopeDepth);\n if (0 === prevActScopeDepth) {\n try {\n flushActQueue(queue),\n enqueueTask(function () {\n return recursivelyFlushAsyncActWork(\n returnValue,\n resolve,\n reject\n );\n });\n } catch (error$2) {\n ReactSharedInternals.thrownErrors.push(error$2);\n }\n if (0 < ReactSharedInternals.thrownErrors.length) {\n var _thrownError = aggregateErrors(\n ReactSharedInternals.thrownErrors\n );\n ReactSharedInternals.thrownErrors.length = 0;\n reject(_thrownError);\n }\n } else resolve(returnValue);\n },\n function (error) {\n popActScope(prevActQueue, prevActScopeDepth);\n 0 < ReactSharedInternals.thrownErrors.length\n ? ((error = aggregateErrors(\n ReactSharedInternals.thrownErrors\n )),\n (ReactSharedInternals.thrownErrors.length = 0),\n reject(error))\n : reject(error);\n }\n );\n }\n };\n }\n var returnValue$jscomp$0 = result;\n popActScope(prevActQueue, prevActScopeDepth);\n 0 === prevActScopeDepth &&\n (flushActQueue(queue),\n 0 !== queue.length &&\n queueSeveralMicrotasks(function () {\n didAwaitActCall ||\n didWarnNoAwaitAct ||\n ((didWarnNoAwaitAct = !0),\n console.error(\n \"A component suspended inside an `act` scope, but the `act` call was not awaited. When testing React components that depend on asynchronous data, you must await the result:\\n\\nawait act(() => ...)\"\n ));\n }),\n (ReactSharedInternals.actQueue = null));\n if (0 < ReactSharedInternals.thrownErrors.length)\n throw (\n ((callback = aggregateErrors(ReactSharedInternals.thrownErrors)),\n (ReactSharedInternals.thrownErrors.length = 0),\n callback)\n );\n return {\n then: function (resolve, reject) {\n didAwaitActCall = !0;\n 0 === prevActScopeDepth\n ? ((ReactSharedInternals.actQueue = queue),\n enqueueTask(function () {\n return recursivelyFlushAsyncActWork(\n returnValue$jscomp$0,\n resolve,\n reject\n );\n }))\n : resolve(returnValue$jscomp$0);\n }\n };\n };\n exports.cache = function (fn) {\n return function () {\n return fn.apply(null, arguments);\n };\n };\n exports.cloneElement = function (element, config, children) {\n if (null === element || void 0 === element)\n throw Error(\n \"The argument must be a React element, but you passed \" +\n element +\n \".\"\n );\n var props = assign({}, element.props),\n key = element.key,\n owner = element._owner;\n if (null != config) {\n var JSCompiler_inline_result;\n a: {\n if (\n hasOwnProperty.call(config, \"ref\") &&\n (JSCompiler_inline_result = Object.getOwnPropertyDescriptor(\n config,\n \"ref\"\n ).get) &&\n JSCompiler_inline_result.isReactWarning\n ) {\n JSCompiler_inline_result = !1;\n break a;\n }\n JSCompiler_inline_result = void 0 !== config.ref;\n }\n JSCompiler_inline_result && (owner = getOwner());\n hasValidKey(config) &&\n (checkKeyStringCoercion(config.key), (key = \"\" + config.key));\n for (propName in config)\n !hasOwnProperty.call(config, propName) ||\n \"key\" === propName ||\n \"__self\" === propName ||\n \"__source\" === propName ||\n (\"ref\" === propName && void 0 === config.ref) ||\n (props[propName] = config[propName]);\n }\n var propName = arguments.length - 2;\n if (1 === propName) props.children = children;\n else if (1 < propName) {\n JSCompiler_inline_result = Array(propName);\n for (var i = 0; i < propName; i++)\n JSCompiler_inline_result[i] = arguments[i + 2];\n props.children = JSCompiler_inline_result;\n }\n props = ReactElement(element.type, key, void 0, void 0, owner, props);\n for (key = 2; key < arguments.length; key++)\n validateChildKeys(arguments[key], props.type);\n return props;\n };\n exports.createContext = function (defaultValue) {\n defaultValue = {\n $$typeof: REACT_CONTEXT_TYPE,\n _currentValue: defaultValue,\n _currentValue2: defaultValue,\n _threadCount: 0,\n Provider: null,\n Consumer: null\n };\n defaultValue.Provider = defaultValue;\n defaultValue.Consumer = {\n $$typeof: REACT_CONSUMER_TYPE,\n _context: defaultValue\n };\n defaultValue._currentRenderer = null;\n defaultValue._currentRenderer2 = null;\n return defaultValue;\n };\n exports.createElement = function (type, config, children) {\n if (isValidElementType(type))\n for (var i = 2; i < arguments.length; i++)\n validateChildKeys(arguments[i], type);\n else {\n i = \"\";\n if (\n void 0 === type ||\n (\"object\" === typeof type &&\n null !== type &&\n 0 === Object.keys(type).length)\n )\n i +=\n \" You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.\";\n if (null === type) var typeString = \"null\";\n else\n isArrayImpl(type)\n ? (typeString = \"array\")\n : void 0 !== type && type.$$typeof === REACT_ELEMENT_TYPE\n ? ((typeString =\n \"<\" +\n (getComponentNameFromType(type.type) || \"Unknown\") +\n \" />\"),\n (i =\n \" Did you accidentally export a JSX literal instead of a component?\"))\n : (typeString = typeof type);\n console.error(\n \"React.createElement: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s\",\n typeString,\n i\n );\n }\n var propName;\n i = {};\n typeString = null;\n if (null != config)\n for (propName in (didWarnAboutOldJSXRuntime ||\n !(\"__self\" in config) ||\n \"key\" in config ||\n ((didWarnAboutOldJSXRuntime = !0),\n console.warn(\n \"Your app (or one of its dependencies) is using an outdated JSX transform. Update to the modern JSX transform for faster performance: https://react.dev/link/new-jsx-transform\"\n )),\n hasValidKey(config) &&\n (checkKeyStringCoercion(config.key), (typeString = \"\" + config.key)),\n config))\n hasOwnProperty.call(config, propName) &&\n \"key\" !== propName &&\n \"__self\" !== propName &&\n \"__source\" !== propName &&\n (i[propName] = config[propName]);\n var childrenLength = arguments.length - 2;\n if (1 === childrenLength) i.children = children;\n else if (1 < childrenLength) {\n for (\n var childArray = Array(childrenLength), _i = 0;\n _i < childrenLength;\n _i++\n )\n childArray[_i] = arguments[_i + 2];\n Object.freeze && Object.freeze(childArray);\n i.children = childArray;\n }\n if (type && type.defaultProps)\n for (propName in ((childrenLength = type.defaultProps), childrenLength))\n void 0 === i[propName] && (i[propName] = childrenLength[propName]);\n typeString &&\n defineKeyPropWarningGetter(\n i,\n \"function\" === typeof type\n ? type.displayName || type.name || \"Unknown\"\n : type\n );\n return ReactElement(type, typeString, void 0, void 0, getOwner(), i);\n };\n exports.createRef = function () {\n var refObject = { current: null };\n Object.seal(refObject);\n return refObject;\n };\n exports.forwardRef = function (render) {\n null != render && render.$$typeof === REACT_MEMO_TYPE\n ? console.error(\n \"forwardRef requires a render function but received a `memo` component. Instead of forwardRef(memo(...)), use memo(forwardRef(...)).\"\n )\n : \"function\" !== typeof render\n ? console.error(\n \"forwardRef requires a render function but was given %s.\",\n null === render ? \"null\" : typeof render\n )\n : 0 !== render.length &&\n 2 !== render.length &&\n console.error(\n \"forwardRef render functions accept exactly two parameters: props and ref. %s\",\n 1 === render.length\n ? \"Did you forget to use the ref parameter?\"\n : \"Any additional parameter will be undefined.\"\n );\n null != render &&\n null != render.defaultProps &&\n console.error(\n \"forwardRef render functions do not support defaultProps. Did you accidentally pass a React component?\"\n );\n var elementType = { $$typeof: REACT_FORWARD_REF_TYPE, render: render },\n ownName;\n Object.defineProperty(elementType, \"displayName\", {\n enumerable: !1,\n configurable: !0,\n get: function () {\n return ownName;\n },\n set: function (name) {\n ownName = name;\n render.name ||\n render.displayName ||\n (Object.defineProperty(render, \"name\", { value: name }),\n (render.displayName = name));\n }\n });\n return elementType;\n };\n exports.isValidElement = isValidElement;\n exports.lazy = function (ctor) {\n return {\n $$typeof: REACT_LAZY_TYPE,\n _payload: { _status: -1, _result: ctor },\n _init: lazyInitializer\n };\n };\n exports.memo = function (type, compare) {\n isValidElementType(type) ||\n console.error(\n \"memo: The first argument must be a component. Instead received: %s\",\n null === type ? \"null\" : typeof type\n );\n compare = {\n $$typeof: REACT_MEMO_TYPE,\n type: type,\n compare: void 0 === compare ? null : compare\n };\n var ownName;\n Object.defineProperty(compare, \"displayName\", {\n enumerable: !1,\n configurable: !0,\n get: function () {\n return ownName;\n },\n set: function (name) {\n ownName = name;\n type.name ||\n type.displayName ||\n (Object.defineProperty(type, \"name\", { value: name }),\n (type.displayName = name));\n }\n });\n return compare;\n };\n exports.startTransition = function (scope) {\n var prevTransition = ReactSharedInternals.T,\n currentTransition = {};\n ReactSharedInternals.T = currentTransition;\n currentTransition._updatedFibers = new Set();\n try {\n var returnValue = scope(),\n onStartTransitionFinish = ReactSharedInternals.S;\n null !== onStartTransitionFinish &&\n onStartTransitionFinish(currentTransition, returnValue);\n \"object\" === typeof returnValue &&\n null !== returnValue &&\n \"function\" === typeof returnValue.then &&\n returnValue.then(noop, reportGlobalError);\n } catch (error) {\n reportGlobalError(error);\n } finally {\n null === prevTransition &&\n currentTransition._updatedFibers &&\n ((scope = currentTransition._updatedFibers.size),\n currentTransition._updatedFibers.clear(),\n 10 < scope &&\n console.warn(\n \"Detected a large number of updates inside startTransition. If this is due to a subscription please re-write it to use React provided hooks. Otherwise concurrent mode guarantees are off the table.\"\n )),\n (ReactSharedInternals.T = prevTransition);\n }\n };\n exports.unstable_useCacheRefresh = function () {\n return resolveDispatcher().useCacheRefresh();\n };\n exports.use = function (usable) {\n return resolveDispatcher().use(usable);\n };\n exports.useActionState = function (action, initialState, permalink) {\n return resolveDispatcher().useActionState(\n action,\n initialState,\n permalink\n );\n };\n exports.useCallback = function (callback, deps) {\n return resolveDispatcher().useCallback(callback, deps);\n };\n exports.useContext = function (Context) {\n var dispatcher = resolveDispatcher();\n Context.$$typeof === REACT_CONSUMER_TYPE &&\n console.error(\n \"Calling useContext(Context.Consumer) is not supported and will cause bugs. Did you mean to call useContext(Context) instead?\"\n );\n return dispatcher.useContext(Context);\n };\n exports.useDebugValue = function (value, formatterFn) {\n return resolveDispatcher().useDebugValue(value, formatterFn);\n };\n exports.useDeferredValue = function (value, initialValue) {\n return resolveDispatcher().useDeferredValue(value, initialValue);\n };\n exports.useEffect = function (create, deps) {\n return resolveDispatcher().useEffect(create, deps);\n };\n exports.useId = function () {\n return resolveDispatcher().useId();\n };\n exports.useImperativeHandle = function (ref, create, deps) {\n return resolveDispatcher().useImperativeHandle(ref, create, deps);\n };\n exports.useInsertionEffect = function (create, deps) {\n return resolveDispatcher().useInsertionEffect(create, deps);\n };\n exports.useLayoutEffect = function (create, deps) {\n return resolveDispatcher().useLayoutEffect(create, deps);\n };\n exports.useMemo = function (create, deps) {\n return resolveDispatcher().useMemo(create, deps);\n };\n exports.useOptimistic = function (passthrough, reducer) {\n return resolveDispatcher().useOptimistic(passthrough, reducer);\n };\n exports.useReducer = function (reducer, initialArg, init) {\n return resolveDispatcher().useReducer(reducer, initialArg, init);\n };\n exports.useRef = function (initialValue) {\n return resolveDispatcher().useRef(initialValue);\n };\n exports.useState = function (initialState) {\n return resolveDispatcher().useState(initialState);\n };\n exports.useSyncExternalStore = function (\n subscribe,\n getSnapshot,\n getServerSnapshot\n ) {\n return resolveDispatcher().useSyncExternalStore(\n subscribe,\n getSnapshot,\n getServerSnapshot\n );\n };\n exports.useTransition = function () {\n return resolveDispatcher().useTransition();\n };\n exports.version = \"19.0.0\";\n \"undefined\" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ &&\n \"function\" ===\n typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop &&\n __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error());\n })();\n", "'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react.production.js');\n} else {\n module.exports = require('./cjs/react.development.js');\n}\n"], - "mappings": ";;;;;;AAAA;AAAA;AAAA;AAWA,KACG,WAAY;AACX,eAAS,yBAAyB,YAAY,MAAM;AAClD,eAAO,eAAe,UAAU,WAAW,YAAY;AAAA,UACrD,KAAK,WAAY;AACf,oBAAQ;AAAA,cACN;AAAA,cACA,KAAK,CAAC;AAAA,cACN,KAAK,CAAC;AAAA,YACR;AAAA,UACF;AAAA,QACF,CAAC;AAAA,MACH;AACA,eAAS,cAAc,eAAe;AACpC,YAAI,SAAS,iBAAiB,aAAa,OAAO;AAChD,iBAAO;AACT,wBACG,yBAAyB,cAAc,qBAAqB,KAC7D,cAAc,YAAY;AAC5B,eAAO,eAAe,OAAO,gBAAgB,gBAAgB;AAAA,MAC/D;AACA,eAAS,SAAS,gBAAgB,YAAY;AAC5C,0BACI,iBAAiB,eAAe,iBAC/B,eAAe,eAAe,eAAe,SAChD;AACF,YAAI,aAAa,iBAAiB,MAAM;AACxC,gDAAwC,UAAU,MAC/C,QAAQ;AAAA,UACP;AAAA,UACA;AAAA,UACA;AAAA,QACF,GACC,wCAAwC,UAAU,IAAI;AAAA,MAC3D;AACA,eAAS,UAAU,OAAO,SAAS,SAAS;AAC1C,aAAK,QAAQ;AACb,aAAK,UAAU;AACf,aAAK,OAAO;AACZ,aAAK,UAAU,WAAW;AAAA,MAC5B;AACA,eAAS,iBAAiB;AAAA,MAAC;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E;AACA,cAAQ,SAAS,SAAU,cAAc;AACvC,eAAO,kBAAkB,EAAE,OAAO,YAAY;AAAA,MAChD;AACA,cAAQ,WAAW,SAAU,cAAc;AACzC,eAAO,kBAAkB,EAAE,SAAS,YAAY;AAAA,MAClD;AACA,cAAQ,uBAAuB,SAC7B,WACA,aACA,mBACA;AACA,eAAO,kBAAkB,EAAE;AAAA,UACzB;AAAA,UACA;AAAA,UACA;AAAA,QACF;AAAA,MACF;AACA,cAAQ,gBAAgB,WAAY;AAClC,eAAO,kBAAkB,EAAE,cAAc;AAAA,MAC3C;AACA,cAAQ,UAAU;AAClB,sBAAgB,OAAO,kCACrB,eACE,OAAO,+BAA+B,8BACxC,+BAA+B,2BAA2B,MAAM,CAAC;AAAA,IACrE,GAAG;AAAA;AAAA;;;ACh/CL;AAAA;AAEA,QAAI,OAAuC;AACzC,aAAO,UAAU;AAAA,IACnB,OAAO;AACL,aAAO,UAAU;AAAA,IACnB;AAAA;AAAA;", - "names": [] -} diff --git a/site/.vite/deps/package.json b/site/.vite/deps/package.json deleted file mode 100644 index 3dbc1ca..0000000 --- a/site/.vite/deps/package.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "type": "module" -} diff --git a/site/.vite/deps/react-dom_client.js b/site/.vite/deps/react-dom_client.js deleted file mode 100644 index 659617d..0000000 --- a/site/.vite/deps/react-dom_client.js +++ /dev/null @@ -1,18180 +0,0 @@ -import { - __commonJS, - require_react -} from "./chunk-GNHYFQKO.js"; - -// node_modules/.pnpm/scheduler@0.25.0/node_modules/scheduler/cjs/scheduler.development.js -var require_scheduler_development = __commonJS({ - "node_modules/.pnpm/scheduler@0.25.0/node_modules/scheduler/cjs/scheduler.development.js"(exports) { - "use strict"; - (function() { - function performWorkUntilDeadline() { - if (isMessageLoopRunning) { - var currentTime = exports.unstable_now(); - startTime = currentTime; - var hasMoreWork = true; - try { - a: { - isHostCallbackScheduled = false; - isHostTimeoutScheduled && (isHostTimeoutScheduled = false, localClearTimeout(taskTimeoutID), taskTimeoutID = -1); - isPerformingWork = true; - var previousPriorityLevel = currentPriorityLevel; - try { - b: { - advanceTimers(currentTime); - for (currentTask = peek(taskQueue); null !== currentTask && !(currentTask.expirationTime > currentTime && shouldYieldToHost()); ) { - var callback = currentTask.callback; - if ("function" === typeof callback) { - currentTask.callback = null; - currentPriorityLevel = currentTask.priorityLevel; - var continuationCallback = callback( - currentTask.expirationTime <= currentTime - ); - currentTime = exports.unstable_now(); - if ("function" === typeof continuationCallback) { - currentTask.callback = continuationCallback; - advanceTimers(currentTime); - hasMoreWork = true; - break b; - } - currentTask === peek(taskQueue) && pop(taskQueue); - advanceTimers(currentTime); - } else pop(taskQueue); - currentTask = peek(taskQueue); - } - if (null !== currentTask) hasMoreWork = true; - else { - var firstTimer = peek(timerQueue); - null !== firstTimer && requestHostTimeout( - handleTimeout, - firstTimer.startTime - currentTime - ); - hasMoreWork = false; - } - } - break a; - } finally { - currentTask = null, currentPriorityLevel = previousPriorityLevel, isPerformingWork = false; - } - hasMoreWork = void 0; - } - } finally { - hasMoreWork ? schedulePerformWorkUntilDeadline() : isMessageLoopRunning = false; - } - } - } - function push(heap, node) { - var index = heap.length; - heap.push(node); - a: for (; 0 < index; ) { - var parentIndex = index - 1 >>> 1, parent = heap[parentIndex]; - if (0 < compare(parent, node)) - heap[parentIndex] = node, heap[index] = parent, index = parentIndex; - else break a; - } - } - function peek(heap) { - return 0 === heap.length ? null : heap[0]; - } - function pop(heap) { - if (0 === heap.length) return null; - var first = heap[0], last = heap.pop(); - if (last !== first) { - heap[0] = last; - a: for (var index = 0, length = heap.length, halfLength = length >>> 1; index < halfLength; ) { - var leftIndex = 2 * (index + 1) - 1, left = heap[leftIndex], rightIndex = leftIndex + 1, right = heap[rightIndex]; - if (0 > compare(left, last)) - rightIndex < length && 0 > compare(right, left) ? (heap[index] = right, heap[rightIndex] = last, index = rightIndex) : (heap[index] = left, heap[leftIndex] = last, index = leftIndex); - else if (rightIndex < length && 0 > compare(right, last)) - heap[index] = right, heap[rightIndex] = last, index = rightIndex; - else break a; - } - } - return first; - } - function compare(a, b) { - var diff = a.sortIndex - b.sortIndex; - return 0 !== diff ? diff : a.id - b.id; - } - function advanceTimers(currentTime) { - for (var timer = peek(timerQueue); null !== timer; ) { - if (null === timer.callback) pop(timerQueue); - else if (timer.startTime <= currentTime) - pop(timerQueue), timer.sortIndex = timer.expirationTime, push(taskQueue, timer); - else break; - timer = peek(timerQueue); - } - } - function handleTimeout(currentTime) { - isHostTimeoutScheduled = false; - advanceTimers(currentTime); - if (!isHostCallbackScheduled) - if (null !== peek(taskQueue)) - isHostCallbackScheduled = true, requestHostCallback(); - else { - var firstTimer = peek(timerQueue); - null !== firstTimer && requestHostTimeout( - handleTimeout, - firstTimer.startTime - currentTime - ); - } - } - function shouldYieldToHost() { - return exports.unstable_now() - startTime < frameInterval ? false : true; - } - function requestHostCallback() { - isMessageLoopRunning || (isMessageLoopRunning = true, schedulePerformWorkUntilDeadline()); - } - function requestHostTimeout(callback, ms) { - taskTimeoutID = localSetTimeout(function() { - callback(exports.unstable_now()); - }, ms); - } - "undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ && "function" === typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error()); - exports.unstable_now = void 0; - if ("object" === typeof performance && "function" === typeof performance.now) { - var localPerformance = performance; - exports.unstable_now = function() { - return localPerformance.now(); - }; - } else { - var localDate = Date, initialTime = localDate.now(); - exports.unstable_now = function() { - return localDate.now() - initialTime; - }; - } - var taskQueue = [], timerQueue = [], taskIdCounter = 1, currentTask = null, currentPriorityLevel = 3, isPerformingWork = false, isHostCallbackScheduled = false, isHostTimeoutScheduled = false, localSetTimeout = "function" === typeof setTimeout ? setTimeout : null, localClearTimeout = "function" === typeof clearTimeout ? clearTimeout : null, localSetImmediate = "undefined" !== typeof setImmediate ? setImmediate : null, isMessageLoopRunning = false, taskTimeoutID = -1, frameInterval = 5, startTime = -1; - if ("function" === typeof localSetImmediate) - var schedulePerformWorkUntilDeadline = function() { - localSetImmediate(performWorkUntilDeadline); - }; - else if ("undefined" !== typeof MessageChannel) { - var channel = new MessageChannel(), port = channel.port2; - channel.port1.onmessage = performWorkUntilDeadline; - schedulePerformWorkUntilDeadline = function() { - port.postMessage(null); - }; - } else - schedulePerformWorkUntilDeadline = function() { - localSetTimeout(performWorkUntilDeadline, 0); - }; - exports.unstable_IdlePriority = 5; - exports.unstable_ImmediatePriority = 1; - exports.unstable_LowPriority = 4; - exports.unstable_NormalPriority = 3; - exports.unstable_Profiling = null; - exports.unstable_UserBlockingPriority = 2; - exports.unstable_cancelCallback = function(task) { - task.callback = null; - }; - exports.unstable_continueExecution = function() { - isHostCallbackScheduled || isPerformingWork || (isHostCallbackScheduled = true, requestHostCallback()); - }; - exports.unstable_forceFrameRate = function(fps) { - 0 > fps || 125 < fps ? console.error( - "forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported" - ) : frameInterval = 0 < fps ? Math.floor(1e3 / fps) : 5; - }; - exports.unstable_getCurrentPriorityLevel = function() { - return currentPriorityLevel; - }; - exports.unstable_getFirstCallbackNode = function() { - return peek(taskQueue); - }; - exports.unstable_next = function(eventHandler) { - switch (currentPriorityLevel) { - case 1: - case 2: - case 3: - var priorityLevel = 3; - break; - default: - priorityLevel = currentPriorityLevel; - } - var previousPriorityLevel = currentPriorityLevel; - currentPriorityLevel = priorityLevel; - try { - return eventHandler(); - } finally { - currentPriorityLevel = previousPriorityLevel; - } - }; - exports.unstable_pauseExecution = function() { - }; - exports.unstable_requestPaint = function() { - }; - exports.unstable_runWithPriority = function(priorityLevel, eventHandler) { - switch (priorityLevel) { - case 1: - case 2: - case 3: - case 4: - case 5: - break; - default: - priorityLevel = 3; - } - var previousPriorityLevel = currentPriorityLevel; - currentPriorityLevel = priorityLevel; - try { - return eventHandler(); - } finally { - currentPriorityLevel = previousPriorityLevel; - } - }; - exports.unstable_scheduleCallback = function(priorityLevel, callback, options) { - var currentTime = exports.unstable_now(); - "object" === typeof options && null !== options ? (options = options.delay, options = "number" === typeof options && 0 < options ? currentTime + options : currentTime) : options = currentTime; - switch (priorityLevel) { - case 1: - var timeout = -1; - break; - case 2: - timeout = 250; - break; - case 5: - timeout = 1073741823; - break; - case 4: - timeout = 1e4; - break; - default: - timeout = 5e3; - } - timeout = options + timeout; - priorityLevel = { - id: taskIdCounter++, - callback, - priorityLevel, - startTime: options, - expirationTime: timeout, - sortIndex: -1 - }; - options > currentTime ? (priorityLevel.sortIndex = options, push(timerQueue, priorityLevel), null === peek(taskQueue) && priorityLevel === peek(timerQueue) && (isHostTimeoutScheduled ? (localClearTimeout(taskTimeoutID), taskTimeoutID = -1) : isHostTimeoutScheduled = true, requestHostTimeout(handleTimeout, options - currentTime))) : (priorityLevel.sortIndex = timeout, push(taskQueue, priorityLevel), isHostCallbackScheduled || isPerformingWork || (isHostCallbackScheduled = true, requestHostCallback())); - return priorityLevel; - }; - exports.unstable_shouldYield = shouldYieldToHost; - exports.unstable_wrapCallback = function(callback) { - var parentPriorityLevel = currentPriorityLevel; - return function() { - var previousPriorityLevel = currentPriorityLevel; - currentPriorityLevel = parentPriorityLevel; - try { - return callback.apply(this, arguments); - } finally { - currentPriorityLevel = previousPriorityLevel; - } - }; - }; - "undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ && "function" === typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error()); - })(); - } -}); - -// node_modules/.pnpm/scheduler@0.25.0/node_modules/scheduler/index.js -var require_scheduler = __commonJS({ - "node_modules/.pnpm/scheduler@0.25.0/node_modules/scheduler/index.js"(exports, module) { - "use strict"; - if (false) { - module.exports = null; - } else { - module.exports = require_scheduler_development(); - } - } -}); - -// node_modules/.pnpm/react-dom@19.0.0_react@19.0.0/node_modules/react-dom/cjs/react-dom.development.js -var require_react_dom_development = __commonJS({ - "node_modules/.pnpm/react-dom@19.0.0_react@19.0.0/node_modules/react-dom/cjs/react-dom.development.js"(exports) { - "use strict"; - (function() { - function noop() { - } - function testStringCoercion(value) { - return "" + value; - } - function createPortal$1(children, containerInfo, implementation) { - var key = 3 < arguments.length && void 0 !== arguments[3] ? arguments[3] : null; - try { - testStringCoercion(key); - var JSCompiler_inline_result = false; - } catch (e) { - JSCompiler_inline_result = true; - } - JSCompiler_inline_result && (console.error( - "The provided key is an unsupported type %s. This value must be coerced to a string before using it here.", - "function" === typeof Symbol && Symbol.toStringTag && key[Symbol.toStringTag] || key.constructor.name || "Object" - ), testStringCoercion(key)); - return { - $$typeof: REACT_PORTAL_TYPE, - key: null == key ? null : "" + key, - children, - containerInfo, - implementation - }; - } - function getCrossOriginStringAs(as, input) { - if ("font" === as) return ""; - if ("string" === typeof input) - return "use-credentials" === input ? input : ""; - } - function getValueDescriptorExpectingObjectForWarning(thing) { - return null === thing ? "`null`" : void 0 === thing ? "`undefined`" : "" === thing ? "an empty string" : 'something with type "' + typeof thing + '"'; - } - function getValueDescriptorExpectingEnumForWarning(thing) { - return null === thing ? "`null`" : void 0 === thing ? "`undefined`" : "" === thing ? "an empty string" : "string" === typeof thing ? JSON.stringify(thing) : "number" === typeof thing ? "`" + thing + "`" : 'something with type "' + typeof thing + '"'; - } - function resolveDispatcher() { - var dispatcher = ReactSharedInternals.H; - null === dispatcher && console.error( - "Invalid hook call. Hooks can only be called inside of the body of a function component. This could happen for one of the following reasons:\n1. You might have mismatching versions of React and the renderer (such as React DOM)\n2. You might be breaking the Rules of Hooks\n3. You might have more than one copy of React in the same app\nSee https://react.dev/link/invalid-hook-call for tips about how to debug and fix this problem." - ); - return dispatcher; - } - "undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ && "function" === typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error()); - var React = require_react(), Internals = { - d: { - f: noop, - r: function() { - throw Error( - "Invalid form element. requestFormReset must be passed a form that was rendered by React." - ); - }, - D: noop, - C: noop, - L: noop, - m: noop, - X: noop, - S: noop, - M: noop - }, - p: 0, - findDOMNode: null - }, REACT_PORTAL_TYPE = Symbol.for("react.portal"), ReactSharedInternals = React.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE; - "function" === typeof Map && null != Map.prototype && "function" === typeof Map.prototype.forEach && "function" === typeof Set && null != Set.prototype && "function" === typeof Set.prototype.clear && "function" === typeof Set.prototype.forEach || console.error( - "React depends on Map and Set built-in types. Make sure that you load a polyfill in older browsers. https://reactjs.org/link/react-polyfills" - ); - exports.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE = Internals; - exports.createPortal = function(children, container) { - var key = 2 < arguments.length && void 0 !== arguments[2] ? arguments[2] : null; - if (!container || 1 !== container.nodeType && 9 !== container.nodeType && 11 !== container.nodeType) - throw Error("Target container is not a DOM element."); - return createPortal$1(children, container, null, key); - }; - exports.flushSync = function(fn) { - var previousTransition = ReactSharedInternals.T, previousUpdatePriority = Internals.p; - try { - if (ReactSharedInternals.T = null, Internals.p = 2, fn) - return fn(); - } finally { - ReactSharedInternals.T = previousTransition, Internals.p = previousUpdatePriority, Internals.d.f() && console.error( - "flushSync was called from inside a lifecycle method. React cannot flush when React is already rendering. Consider moving this call to a scheduler task or micro task." - ); - } - }; - exports.preconnect = function(href, options) { - "string" === typeof href && href ? null != options && "object" !== typeof options ? console.error( - "ReactDOM.preconnect(): Expected the `options` argument (second) to be an object but encountered %s instead. The only supported option at this time is `crossOrigin` which accepts a string.", - getValueDescriptorExpectingEnumForWarning(options) - ) : null != options && "string" !== typeof options.crossOrigin && console.error( - "ReactDOM.preconnect(): Expected the `crossOrigin` option (second argument) to be a string but encountered %s instead. Try removing this option or passing a string value instead.", - getValueDescriptorExpectingObjectForWarning(options.crossOrigin) - ) : console.error( - "ReactDOM.preconnect(): Expected the `href` argument (first) to be a non-empty string but encountered %s instead.", - getValueDescriptorExpectingObjectForWarning(href) - ); - "string" === typeof href && (options ? (options = options.crossOrigin, options = "string" === typeof options ? "use-credentials" === options ? options : "" : void 0) : options = null, Internals.d.C(href, options)); - }; - exports.prefetchDNS = function(href) { - if ("string" !== typeof href || !href) - console.error( - "ReactDOM.prefetchDNS(): Expected the `href` argument (first) to be a non-empty string but encountered %s instead.", - getValueDescriptorExpectingObjectForWarning(href) - ); - else if (1 < arguments.length) { - var options = arguments[1]; - "object" === typeof options && options.hasOwnProperty("crossOrigin") ? console.error( - "ReactDOM.prefetchDNS(): Expected only one argument, `href`, but encountered %s as a second argument instead. This argument is reserved for future options and is currently disallowed. It looks like the you are attempting to set a crossOrigin property for this DNS lookup hint. Browsers do not perform DNS queries using CORS and setting this attribute on the resource hint has no effect. Try calling ReactDOM.prefetchDNS() with just a single string argument, `href`.", - getValueDescriptorExpectingEnumForWarning(options) - ) : console.error( - "ReactDOM.prefetchDNS(): Expected only one argument, `href`, but encountered %s as a second argument instead. This argument is reserved for future options and is currently disallowed. Try calling ReactDOM.prefetchDNS() with just a single string argument, `href`.", - getValueDescriptorExpectingEnumForWarning(options) - ); - } - "string" === typeof href && Internals.d.D(href); - }; - exports.preinit = function(href, options) { - "string" === typeof href && href ? null == options || "object" !== typeof options ? console.error( - "ReactDOM.preinit(): Expected the `options` argument (second) to be an object with an `as` property describing the type of resource to be preinitialized but encountered %s instead.", - getValueDescriptorExpectingEnumForWarning(options) - ) : "style" !== options.as && "script" !== options.as && console.error( - 'ReactDOM.preinit(): Expected the `as` property in the `options` argument (second) to contain a valid value describing the type of resource to be preinitialized but encountered %s instead. Valid values for `as` are "style" and "script".', - getValueDescriptorExpectingEnumForWarning(options.as) - ) : console.error( - "ReactDOM.preinit(): Expected the `href` argument (first) to be a non-empty string but encountered %s instead.", - getValueDescriptorExpectingObjectForWarning(href) - ); - if ("string" === typeof href && options && "string" === typeof options.as) { - var as = options.as, crossOrigin = getCrossOriginStringAs(as, options.crossOrigin), integrity = "string" === typeof options.integrity ? options.integrity : void 0, fetchPriority = "string" === typeof options.fetchPriority ? options.fetchPriority : void 0; - "style" === as ? Internals.d.S( - href, - "string" === typeof options.precedence ? options.precedence : void 0, - { - crossOrigin, - integrity, - fetchPriority - } - ) : "script" === as && Internals.d.X(href, { - crossOrigin, - integrity, - fetchPriority, - nonce: "string" === typeof options.nonce ? options.nonce : void 0 - }); - } - }; - exports.preinitModule = function(href, options) { - var encountered = ""; - "string" === typeof href && href || (encountered += " The `href` argument encountered was " + getValueDescriptorExpectingObjectForWarning(href) + "."); - void 0 !== options && "object" !== typeof options ? encountered += " The `options` argument encountered was " + getValueDescriptorExpectingObjectForWarning(options) + "." : options && "as" in options && "script" !== options.as && (encountered += " The `as` option encountered was " + getValueDescriptorExpectingEnumForWarning(options.as) + "."); - if (encountered) - console.error( - "ReactDOM.preinitModule(): Expected up to two arguments, a non-empty `href` string and, optionally, an `options` object with a valid `as` property.%s", - encountered - ); - else - switch (encountered = options && "string" === typeof options.as ? options.as : "script", encountered) { - case "script": - break; - default: - encountered = getValueDescriptorExpectingEnumForWarning(encountered), console.error( - 'ReactDOM.preinitModule(): Currently the only supported "as" type for this function is "script" but received "%s" instead. This warning was generated for `href` "%s". In the future other module types will be supported, aligning with the import-attributes proposal. Learn more here: (https://github.com/tc39/proposal-import-attributes)', - encountered, - href - ); - } - if ("string" === typeof href) - if ("object" === typeof options && null !== options) { - if (null == options.as || "script" === options.as) - encountered = getCrossOriginStringAs( - options.as, - options.crossOrigin - ), Internals.d.M(href, { - crossOrigin: encountered, - integrity: "string" === typeof options.integrity ? options.integrity : void 0, - nonce: "string" === typeof options.nonce ? options.nonce : void 0 - }); - } else null == options && Internals.d.M(href); - }; - exports.preload = function(href, options) { - var encountered = ""; - "string" === typeof href && href || (encountered += " The `href` argument encountered was " + getValueDescriptorExpectingObjectForWarning(href) + "."); - null == options || "object" !== typeof options ? encountered += " The `options` argument encountered was " + getValueDescriptorExpectingObjectForWarning(options) + "." : "string" === typeof options.as && options.as || (encountered += " The `as` option encountered was " + getValueDescriptorExpectingObjectForWarning(options.as) + "."); - encountered && console.error( - 'ReactDOM.preload(): Expected two arguments, a non-empty `href` string and an `options` object with an `as` property valid for a `` tag.%s', - encountered - ); - if ("string" === typeof href && "object" === typeof options && null !== options && "string" === typeof options.as) { - encountered = options.as; - var crossOrigin = getCrossOriginStringAs( - encountered, - options.crossOrigin - ); - Internals.d.L(href, encountered, { - crossOrigin, - integrity: "string" === typeof options.integrity ? options.integrity : void 0, - nonce: "string" === typeof options.nonce ? options.nonce : void 0, - type: "string" === typeof options.type ? options.type : void 0, - fetchPriority: "string" === typeof options.fetchPriority ? options.fetchPriority : void 0, - referrerPolicy: "string" === typeof options.referrerPolicy ? options.referrerPolicy : void 0, - imageSrcSet: "string" === typeof options.imageSrcSet ? options.imageSrcSet : void 0, - imageSizes: "string" === typeof options.imageSizes ? options.imageSizes : void 0, - media: "string" === typeof options.media ? options.media : void 0 - }); - } - }; - exports.preloadModule = function(href, options) { - var encountered = ""; - "string" === typeof href && href || (encountered += " The `href` argument encountered was " + getValueDescriptorExpectingObjectForWarning(href) + "."); - void 0 !== options && "object" !== typeof options ? encountered += " The `options` argument encountered was " + getValueDescriptorExpectingObjectForWarning(options) + "." : options && "as" in options && "string" !== typeof options.as && (encountered += " The `as` option encountered was " + getValueDescriptorExpectingObjectForWarning(options.as) + "."); - encountered && console.error( - 'ReactDOM.preloadModule(): Expected two arguments, a non-empty `href` string and, optionally, an `options` object with an `as` property valid for a `` tag.%s', - encountered - ); - "string" === typeof href && (options ? (encountered = getCrossOriginStringAs( - options.as, - options.crossOrigin - ), Internals.d.m(href, { - as: "string" === typeof options.as && "script" !== options.as ? options.as : void 0, - crossOrigin: encountered, - integrity: "string" === typeof options.integrity ? options.integrity : void 0 - })) : Internals.d.m(href)); - }; - exports.requestFormReset = function(form) { - Internals.d.r(form); - }; - exports.unstable_batchedUpdates = function(fn, a) { - return fn(a); - }; - exports.useFormState = function(action, initialState, permalink) { - return resolveDispatcher().useFormState(action, initialState, permalink); - }; - exports.useFormStatus = function() { - return resolveDispatcher().useHostTransitionStatus(); - }; - exports.version = "19.0.0"; - "undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ && "function" === typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error()); - })(); - } -}); - -// node_modules/.pnpm/react-dom@19.0.0_react@19.0.0/node_modules/react-dom/index.js -var require_react_dom = __commonJS({ - "node_modules/.pnpm/react-dom@19.0.0_react@19.0.0/node_modules/react-dom/index.js"(exports, module) { - "use strict"; - if (false) { - checkDCE(); - module.exports = null; - } else { - module.exports = require_react_dom_development(); - } - } -}); - -// node_modules/.pnpm/react-dom@19.0.0_react@19.0.0/node_modules/react-dom/cjs/react-dom-client.development.js -var require_react_dom_client_development = __commonJS({ - "node_modules/.pnpm/react-dom@19.0.0_react@19.0.0/node_modules/react-dom/cjs/react-dom-client.development.js"(exports) { - "use strict"; - (function() { - function findHook(fiber, id) { - for (fiber = fiber.memoizedState; null !== fiber && 0 < id; ) - fiber = fiber.next, id--; - return fiber; - } - function copyWithSetImpl(obj, path, index, value) { - if (index >= path.length) return value; - var key = path[index], updated = isArrayImpl(obj) ? obj.slice() : assign({}, obj); - updated[key] = copyWithSetImpl(obj[key], path, index + 1, value); - return updated; - } - function copyWithRename(obj, oldPath, newPath) { - if (oldPath.length !== newPath.length) - console.warn("copyWithRename() expects paths of the same length"); - else { - for (var i = 0; i < newPath.length - 1; i++) - if (oldPath[i] !== newPath[i]) { - console.warn( - "copyWithRename() expects paths to be the same except for the deepest key" - ); - return; - } - return copyWithRenameImpl(obj, oldPath, newPath, 0); - } - } - function copyWithRenameImpl(obj, oldPath, newPath, index) { - var oldKey = oldPath[index], updated = isArrayImpl(obj) ? obj.slice() : assign({}, obj); - index + 1 === oldPath.length ? (updated[newPath[index]] = updated[oldKey], isArrayImpl(updated) ? updated.splice(oldKey, 1) : delete updated[oldKey]) : updated[oldKey] = copyWithRenameImpl( - obj[oldKey], - oldPath, - newPath, - index + 1 - ); - return updated; - } - function copyWithDeleteImpl(obj, path, index) { - var key = path[index], updated = isArrayImpl(obj) ? obj.slice() : assign({}, obj); - if (index + 1 === path.length) - return isArrayImpl(updated) ? updated.splice(key, 1) : delete updated[key], updated; - updated[key] = copyWithDeleteImpl(obj[key], path, index + 1); - return updated; - } - function shouldSuspendImpl() { - return false; - } - function shouldErrorImpl() { - return null; - } - function createFiber(tag, pendingProps, key, mode) { - return new FiberNode(tag, pendingProps, key, mode); - } - function warnInvalidHookAccess() { - console.error( - "Do not call Hooks inside useEffect(...), useMemo(...), or other built-in Hooks. You can only call Hooks at the top level of your React function. For more information, see https://react.dev/link/rules-of-hooks" - ); - } - function warnInvalidContextAccess() { - console.error( - "Context can only be read while React is rendering. In classes, you can read it in the render method or getDerivedStateFromProps. In function components, you can read it directly in the function body, but not inside Hooks like useReducer() or useMemo()." - ); - } - function noop$2() { - } - function warnForMissingKey() { - } - function setToSortedString(set) { - var array = []; - set.forEach(function(value) { - array.push(value); - }); - return array.sort().join(", "); - } - function scheduleRoot(root2, element) { - root2.context === emptyContextObject && (updateContainerSync(element, root2, null, null), flushSyncWork$1()); - } - function scheduleRefresh(root2, update) { - if (null !== resolveFamily) { - var staleFamilies = update.staleFamilies; - update = update.updatedFamilies; - flushPassiveEffects(); - scheduleFibersWithFamiliesRecursively( - root2.current, - update, - staleFamilies - ); - flushSyncWork$1(); - } - } - function setRefreshHandler(handler) { - resolveFamily = handler; - } - function isValidContainer(node) { - return !(!node || 1 !== node.nodeType && 9 !== node.nodeType && 11 !== node.nodeType); - } - function getIteratorFn(maybeIterable) { - if (null === maybeIterable || "object" !== typeof maybeIterable) - return null; - maybeIterable = MAYBE_ITERATOR_SYMBOL && maybeIterable[MAYBE_ITERATOR_SYMBOL] || maybeIterable["@@iterator"]; - return "function" === typeof maybeIterable ? maybeIterable : null; - } - function getComponentNameFromType(type) { - if (null == type) return null; - if ("function" === typeof type) - return type.$$typeof === REACT_CLIENT_REFERENCE ? null : type.displayName || type.name || null; - if ("string" === typeof type) return type; - switch (type) { - case REACT_FRAGMENT_TYPE: - return "Fragment"; - case REACT_PORTAL_TYPE: - return "Portal"; - case REACT_PROFILER_TYPE: - return "Profiler"; - case REACT_STRICT_MODE_TYPE: - return "StrictMode"; - case REACT_SUSPENSE_TYPE: - return "Suspense"; - case REACT_SUSPENSE_LIST_TYPE: - return "SuspenseList"; - } - if ("object" === typeof type) - switch ("number" === typeof type.tag && console.error( - "Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue." - ), type.$$typeof) { - case REACT_CONTEXT_TYPE: - return (type.displayName || "Context") + ".Provider"; - case REACT_CONSUMER_TYPE: - return (type._context.displayName || "Context") + ".Consumer"; - case REACT_FORWARD_REF_TYPE: - var innerType = type.render; - type = type.displayName; - type || (type = innerType.displayName || innerType.name || "", type = "" !== type ? "ForwardRef(" + type + ")" : "ForwardRef"); - return type; - case REACT_MEMO_TYPE: - return innerType = type.displayName || null, null !== innerType ? innerType : getComponentNameFromType(type.type) || "Memo"; - case REACT_LAZY_TYPE: - innerType = type._payload; - type = type._init; - try { - return getComponentNameFromType(type(innerType)); - } catch (x) { - } - } - return null; - } - function getComponentNameFromOwner(owner) { - return "number" === typeof owner.tag ? getComponentNameFromFiber(owner) : "string" === typeof owner.name ? owner.name : null; - } - function getComponentNameFromFiber(fiber) { - var type = fiber.type; - switch (fiber.tag) { - case 24: - return "Cache"; - case 9: - return (type._context.displayName || "Context") + ".Consumer"; - case 10: - return (type.displayName || "Context") + ".Provider"; - case 18: - return "DehydratedFragment"; - case 11: - return fiber = type.render, fiber = fiber.displayName || fiber.name || "", type.displayName || ("" !== fiber ? "ForwardRef(" + fiber + ")" : "ForwardRef"); - case 7: - return "Fragment"; - case 26: - case 27: - case 5: - return type; - case 4: - return "Portal"; - case 3: - return "Root"; - case 6: - return "Text"; - case 16: - return getComponentNameFromType(type); - case 8: - return type === REACT_STRICT_MODE_TYPE ? "StrictMode" : "Mode"; - case 22: - return "Offscreen"; - case 12: - return "Profiler"; - case 21: - return "Scope"; - case 13: - return "Suspense"; - case 19: - return "SuspenseList"; - case 25: - return "TracingMarker"; - case 1: - case 0: - case 14: - case 15: - if ("function" === typeof type) - return type.displayName || type.name || null; - if ("string" === typeof type) return type; - break; - case 29: - type = fiber._debugInfo; - if (null != type) { - for (var i = type.length - 1; 0 <= i; i--) - if ("string" === typeof type[i].name) return type[i].name; - } - if (null !== fiber.return) - return getComponentNameFromFiber(fiber.return); - } - return null; - } - function disabledLog() { - } - function disableLogs() { - if (0 === disabledDepth) { - prevLog = console.log; - prevInfo = console.info; - prevWarn = console.warn; - prevError = console.error; - prevGroup = console.group; - prevGroupCollapsed = console.groupCollapsed; - prevGroupEnd = console.groupEnd; - var props = { - configurable: true, - enumerable: true, - value: disabledLog, - writable: true - }; - Object.defineProperties(console, { - info: props, - log: props, - warn: props, - error: props, - group: props, - groupCollapsed: props, - groupEnd: props - }); - } - disabledDepth++; - } - function reenableLogs() { - disabledDepth--; - if (0 === disabledDepth) { - var props = { configurable: true, enumerable: true, writable: true }; - Object.defineProperties(console, { - log: assign({}, props, { value: prevLog }), - info: assign({}, props, { value: prevInfo }), - warn: assign({}, props, { value: prevWarn }), - error: assign({}, props, { value: prevError }), - group: assign({}, props, { value: prevGroup }), - groupCollapsed: assign({}, props, { value: prevGroupCollapsed }), - groupEnd: assign({}, props, { value: prevGroupEnd }) - }); - } - 0 > disabledDepth && console.error( - "disabledDepth fell below zero. This is a bug in React. Please file an issue." - ); - } - function describeBuiltInComponentFrame(name) { - if (void 0 === prefix) - try { - throw Error(); - } catch (x) { - var match = x.stack.trim().match(/\n( *(at )?)/); - prefix = match && match[1] || ""; - suffix = -1 < x.stack.indexOf("\n at") ? " ()" : -1 < x.stack.indexOf("@") ? "@unknown:0:0" : ""; - } - return "\n" + prefix + name + suffix; - } - function describeNativeComponentFrame(fn, construct) { - if (!fn || reentry) return ""; - var frame = componentFrameCache.get(fn); - if (void 0 !== frame) return frame; - reentry = true; - frame = Error.prepareStackTrace; - Error.prepareStackTrace = void 0; - var previousDispatcher2 = null; - previousDispatcher2 = ReactSharedInternals.H; - ReactSharedInternals.H = null; - disableLogs(); - try { - var RunInRootFrame = { - DetermineComponentFrameRoot: function() { - try { - if (construct) { - var Fake = function() { - throw Error(); - }; - Object.defineProperty(Fake.prototype, "props", { - set: function() { - throw Error(); - } - }); - if ("object" === typeof Reflect && Reflect.construct) { - try { - Reflect.construct(Fake, []); - } catch (x) { - var control = x; - } - Reflect.construct(fn, [], Fake); - } else { - try { - Fake.call(); - } catch (x$0) { - control = x$0; - } - fn.call(Fake.prototype); - } - } else { - try { - throw Error(); - } catch (x$1) { - control = x$1; - } - (Fake = fn()) && "function" === typeof Fake.catch && Fake.catch(function() { - }); - } - } catch (sample) { - if (sample && control && "string" === typeof sample.stack) - return [sample.stack, control.stack]; - } - return [null, null]; - } - }; - RunInRootFrame.DetermineComponentFrameRoot.displayName = "DetermineComponentFrameRoot"; - var namePropDescriptor = Object.getOwnPropertyDescriptor( - RunInRootFrame.DetermineComponentFrameRoot, - "name" - ); - namePropDescriptor && namePropDescriptor.configurable && Object.defineProperty( - RunInRootFrame.DetermineComponentFrameRoot, - "name", - { value: "DetermineComponentFrameRoot" } - ); - var _RunInRootFrame$Deter = RunInRootFrame.DetermineComponentFrameRoot(), sampleStack = _RunInRootFrame$Deter[0], controlStack = _RunInRootFrame$Deter[1]; - if (sampleStack && controlStack) { - var sampleLines = sampleStack.split("\n"), controlLines = controlStack.split("\n"); - for (_RunInRootFrame$Deter = namePropDescriptor = 0; namePropDescriptor < sampleLines.length && !sampleLines[namePropDescriptor].includes( - "DetermineComponentFrameRoot" - ); ) - namePropDescriptor++; - for (; _RunInRootFrame$Deter < controlLines.length && !controlLines[_RunInRootFrame$Deter].includes( - "DetermineComponentFrameRoot" - ); ) - _RunInRootFrame$Deter++; - if (namePropDescriptor === sampleLines.length || _RunInRootFrame$Deter === controlLines.length) - for (namePropDescriptor = sampleLines.length - 1, _RunInRootFrame$Deter = controlLines.length - 1; 1 <= namePropDescriptor && 0 <= _RunInRootFrame$Deter && sampleLines[namePropDescriptor] !== controlLines[_RunInRootFrame$Deter]; ) - _RunInRootFrame$Deter--; - for (; 1 <= namePropDescriptor && 0 <= _RunInRootFrame$Deter; namePropDescriptor--, _RunInRootFrame$Deter--) - if (sampleLines[namePropDescriptor] !== controlLines[_RunInRootFrame$Deter]) { - if (1 !== namePropDescriptor || 1 !== _RunInRootFrame$Deter) { - do - if (namePropDescriptor--, _RunInRootFrame$Deter--, 0 > _RunInRootFrame$Deter || sampleLines[namePropDescriptor] !== controlLines[_RunInRootFrame$Deter]) { - var _frame = "\n" + sampleLines[namePropDescriptor].replace( - " at new ", - " at " - ); - fn.displayName && _frame.includes("") && (_frame = _frame.replace("", fn.displayName)); - "function" === typeof fn && componentFrameCache.set(fn, _frame); - return _frame; - } - while (1 <= namePropDescriptor && 0 <= _RunInRootFrame$Deter); - } - break; - } - } - } finally { - reentry = false, ReactSharedInternals.H = previousDispatcher2, reenableLogs(), Error.prepareStackTrace = frame; - } - sampleLines = (sampleLines = fn ? fn.displayName || fn.name : "") ? describeBuiltInComponentFrame(sampleLines) : ""; - "function" === typeof fn && componentFrameCache.set(fn, sampleLines); - return sampleLines; - } - function describeFiber(fiber) { - switch (fiber.tag) { - case 26: - case 27: - case 5: - return describeBuiltInComponentFrame(fiber.type); - case 16: - return describeBuiltInComponentFrame("Lazy"); - case 13: - return describeBuiltInComponentFrame("Suspense"); - case 19: - return describeBuiltInComponentFrame("SuspenseList"); - case 0: - case 15: - return fiber = describeNativeComponentFrame(fiber.type, false), fiber; - case 11: - return fiber = describeNativeComponentFrame(fiber.type.render, false), fiber; - case 1: - return fiber = describeNativeComponentFrame(fiber.type, true), fiber; - default: - return ""; - } - } - function getStackByFiberInDevAndProd(workInProgress2) { - try { - var info = ""; - do { - info += describeFiber(workInProgress2); - var debugInfo = workInProgress2._debugInfo; - if (debugInfo) - for (var i = debugInfo.length - 1; 0 <= i; i--) { - var entry = debugInfo[i]; - if ("string" === typeof entry.name) { - var JSCompiler_temp_const = info, env = entry.env; - var JSCompiler_inline_result = describeBuiltInComponentFrame( - entry.name + (env ? " [" + env + "]" : "") - ); - info = JSCompiler_temp_const + JSCompiler_inline_result; - } - } - workInProgress2 = workInProgress2.return; - } while (workInProgress2); - return info; - } catch (x) { - return "\nError generating stack: " + x.message + "\n" + x.stack; - } - } - function getCurrentFiberOwnerNameInDevOrNull() { - if (null === current) return null; - var owner = current._debugOwner; - return null != owner ? getComponentNameFromOwner(owner) : null; - } - function getCurrentFiberStackInDev() { - return null === current ? "" : getStackByFiberInDevAndProd(current); - } - function runWithFiberInDEV(fiber, callback, arg0, arg1, arg2, arg3, arg4) { - var previousFiber = current; - ReactSharedInternals.getCurrentStack = null === fiber ? null : getCurrentFiberStackInDev; - isRendering = false; - current = fiber; - try { - return callback(arg0, arg1, arg2, arg3, arg4); - } finally { - current = previousFiber; - } - throw Error( - "runWithFiberInDEV should never be called in production. This is a bug in React." - ); - } - function getNearestMountedFiber(fiber) { - var node = fiber, nearestMounted = fiber; - if (fiber.alternate) for (; node.return; ) node = node.return; - else { - fiber = node; - do - node = fiber, 0 !== (node.flags & 4098) && (nearestMounted = node.return), fiber = node.return; - while (fiber); - } - return 3 === node.tag ? nearestMounted : null; - } - function getSuspenseInstanceFromFiber(fiber) { - if (13 === fiber.tag) { - var suspenseState = fiber.memoizedState; - null === suspenseState && (fiber = fiber.alternate, null !== fiber && (suspenseState = fiber.memoizedState)); - if (null !== suspenseState) return suspenseState.dehydrated; - } - return null; - } - function assertIsMounted(fiber) { - if (getNearestMountedFiber(fiber) !== fiber) - throw Error("Unable to find node on an unmounted component."); - } - function findCurrentFiberUsingSlowPath(fiber) { - var alternate = fiber.alternate; - if (!alternate) { - alternate = getNearestMountedFiber(fiber); - if (null === alternate) - throw Error("Unable to find node on an unmounted component."); - return alternate !== fiber ? null : fiber; - } - for (var a = fiber, b = alternate; ; ) { - var parentA = a.return; - if (null === parentA) break; - var parentB = parentA.alternate; - if (null === parentB) { - b = parentA.return; - if (null !== b) { - a = b; - continue; - } - break; - } - if (parentA.child === parentB.child) { - for (parentB = parentA.child; parentB; ) { - if (parentB === a) return assertIsMounted(parentA), fiber; - if (parentB === b) return assertIsMounted(parentA), alternate; - parentB = parentB.sibling; - } - throw Error("Unable to find node on an unmounted component."); - } - if (a.return !== b.return) a = parentA, b = parentB; - else { - for (var didFindChild = false, _child = parentA.child; _child; ) { - if (_child === a) { - didFindChild = true; - a = parentA; - b = parentB; - break; - } - if (_child === b) { - didFindChild = true; - b = parentA; - a = parentB; - break; - } - _child = _child.sibling; - } - if (!didFindChild) { - for (_child = parentB.child; _child; ) { - if (_child === a) { - didFindChild = true; - a = parentB; - b = parentA; - break; - } - if (_child === b) { - didFindChild = true; - b = parentB; - a = parentA; - break; - } - _child = _child.sibling; - } - if (!didFindChild) - throw Error( - "Child was not found in either parent set. This indicates a bug in React related to the return pointer. Please file an issue." - ); - } - } - if (a.alternate !== b) - throw Error( - "Return fibers should always be each others' alternates. This error is likely caused by a bug in React. Please file an issue." - ); - } - if (3 !== a.tag) - throw Error("Unable to find node on an unmounted component."); - return a.stateNode.current === a ? fiber : alternate; - } - function findCurrentHostFiberImpl(node) { - var tag = node.tag; - if (5 === tag || 26 === tag || 27 === tag || 6 === tag) return node; - for (node = node.child; null !== node; ) { - tag = findCurrentHostFiberImpl(node); - if (null !== tag) return tag; - node = node.sibling; - } - return null; - } - function createCursor(defaultValue) { - return { current: defaultValue }; - } - function pop(cursor, fiber) { - 0 > index$jscomp$0 ? console.error("Unexpected pop.") : (fiber !== fiberStack[index$jscomp$0] && console.error("Unexpected Fiber popped."), cursor.current = valueStack[index$jscomp$0], valueStack[index$jscomp$0] = null, fiberStack[index$jscomp$0] = null, index$jscomp$0--); - } - function push(cursor, value, fiber) { - index$jscomp$0++; - valueStack[index$jscomp$0] = cursor.current; - fiberStack[index$jscomp$0] = fiber; - cursor.current = value; - } - function requiredContext(c) { - null === c && console.error( - "Expected host context to exist. This error is likely caused by a bug in React. Please file an issue." - ); - return c; - } - function pushHostContainer(fiber, nextRootInstance) { - push(rootInstanceStackCursor, nextRootInstance, fiber); - push(contextFiberStackCursor, fiber, fiber); - push(contextStackCursor, null, fiber); - var nextRootContext = nextRootInstance.nodeType; - switch (nextRootContext) { - case 9: - case 11: - nextRootContext = 9 === nextRootContext ? "#document" : "#fragment"; - nextRootInstance = (nextRootInstance = nextRootInstance.documentElement) ? (nextRootInstance = nextRootInstance.namespaceURI) ? getOwnHostContext(nextRootInstance) : HostContextNamespaceNone : HostContextNamespaceNone; - break; - default: - if (nextRootInstance = 8 === nextRootContext ? nextRootInstance.parentNode : nextRootInstance, nextRootContext = nextRootInstance.tagName, nextRootInstance = nextRootInstance.namespaceURI) - nextRootInstance = getOwnHostContext(nextRootInstance), nextRootInstance = getChildHostContextProd( - nextRootInstance, - nextRootContext - ); - else - switch (nextRootContext) { - case "svg": - nextRootInstance = HostContextNamespaceSvg; - break; - case "math": - nextRootInstance = HostContextNamespaceMath; - break; - default: - nextRootInstance = HostContextNamespaceNone; - } - } - nextRootContext = nextRootContext.toLowerCase(); - nextRootContext = updatedAncestorInfoDev(null, nextRootContext); - nextRootContext = { - context: nextRootInstance, - ancestorInfo: nextRootContext - }; - pop(contextStackCursor, fiber); - push(contextStackCursor, nextRootContext, fiber); - } - function popHostContainer(fiber) { - pop(contextStackCursor, fiber); - pop(contextFiberStackCursor, fiber); - pop(rootInstanceStackCursor, fiber); - } - function getHostContext() { - return requiredContext(contextStackCursor.current); - } - function pushHostContext(fiber) { - null !== fiber.memoizedState && push(hostTransitionProviderCursor, fiber, fiber); - var context = requiredContext(contextStackCursor.current); - var type = fiber.type; - var nextContext = getChildHostContextProd(context.context, type); - type = updatedAncestorInfoDev(context.ancestorInfo, type); - nextContext = { context: nextContext, ancestorInfo: type }; - context !== nextContext && (push(contextFiberStackCursor, fiber, fiber), push(contextStackCursor, nextContext, fiber)); - } - function popHostContext(fiber) { - contextFiberStackCursor.current === fiber && (pop(contextStackCursor, fiber), pop(contextFiberStackCursor, fiber)); - hostTransitionProviderCursor.current === fiber && (pop(hostTransitionProviderCursor, fiber), HostTransitionContext._currentValue = NotPendingTransition); - } - function typeName(value) { - return "function" === typeof Symbol && Symbol.toStringTag && value[Symbol.toStringTag] || value.constructor.name || "Object"; - } - function willCoercionThrow(value) { - try { - return testStringCoercion(value), false; - } catch (e) { - return true; - } - } - function testStringCoercion(value) { - return "" + value; - } - function checkAttributeStringCoercion(value, attributeName) { - if (willCoercionThrow(value)) - return console.error( - "The provided `%s` attribute is an unsupported type %s. This value must be coerced to a string before using it here.", - attributeName, - typeName(value) - ), testStringCoercion(value); - } - function checkCSSPropertyStringCoercion(value, propName) { - if (willCoercionThrow(value)) - return console.error( - "The provided `%s` CSS property is an unsupported type %s. This value must be coerced to a string before using it here.", - propName, - typeName(value) - ), testStringCoercion(value); - } - function checkFormFieldValueStringCoercion(value) { - if (willCoercionThrow(value)) - return console.error( - "Form field values (value, checked, defaultValue, or defaultChecked props) must be strings, not %s. This value must be coerced to a string before using it here.", - typeName(value) - ), testStringCoercion(value); - } - function injectInternals(internals) { - if ("undefined" === typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) return false; - var hook = __REACT_DEVTOOLS_GLOBAL_HOOK__; - if (hook.isDisabled) return true; - if (!hook.supportsFiber) - return console.error( - "The installed version of React DevTools is too old and will not work with the current version of React. Please update React DevTools. https://react.dev/link/react-devtools" - ), true; - try { - rendererID = hook.inject(internals), injectedHook = hook; - } catch (err) { - console.error("React instrumentation encountered an error: %s.", err); - } - return hook.checkDCE ? true : false; - } - function onCommitRoot$1(root2, eventPriority) { - if (injectedHook && "function" === typeof injectedHook.onCommitFiberRoot) - try { - var didError = 128 === (root2.current.flags & 128); - switch (eventPriority) { - case DiscreteEventPriority: - var schedulerPriority = ImmediatePriority; - break; - case ContinuousEventPriority: - schedulerPriority = UserBlockingPriority; - break; - case DefaultEventPriority: - schedulerPriority = NormalPriority$1; - break; - case IdleEventPriority: - schedulerPriority = IdlePriority; - break; - default: - schedulerPriority = NormalPriority$1; - } - injectedHook.onCommitFiberRoot( - rendererID, - root2, - schedulerPriority, - didError - ); - } catch (err) { - hasLoggedError || (hasLoggedError = true, console.error( - "React instrumentation encountered an error: %s", - err - )); - } - } - function setIsStrictModeForDevtools(newIsStrictMode) { - "function" === typeof log$1 && unstable_setDisableYieldValue(newIsStrictMode); - if (injectedHook && "function" === typeof injectedHook.setStrictMode) - try { - injectedHook.setStrictMode(rendererID, newIsStrictMode); - } catch (err) { - hasLoggedError || (hasLoggedError = true, console.error( - "React instrumentation encountered an error: %s", - err - )); - } - } - function injectProfilingHooks(profilingHooks) { - injectedProfilingHooks = profilingHooks; - } - function markCommitStopped() { - null !== injectedProfilingHooks && "function" === typeof injectedProfilingHooks.markCommitStopped && injectedProfilingHooks.markCommitStopped(); - } - function markComponentRenderStarted(fiber) { - null !== injectedProfilingHooks && "function" === typeof injectedProfilingHooks.markComponentRenderStarted && injectedProfilingHooks.markComponentRenderStarted(fiber); - } - function markComponentRenderStopped() { - null !== injectedProfilingHooks && "function" === typeof injectedProfilingHooks.markComponentRenderStopped && injectedProfilingHooks.markComponentRenderStopped(); - } - function markRenderStarted(lanes) { - null !== injectedProfilingHooks && "function" === typeof injectedProfilingHooks.markRenderStarted && injectedProfilingHooks.markRenderStarted(lanes); - } - function markRenderStopped() { - null !== injectedProfilingHooks && "function" === typeof injectedProfilingHooks.markRenderStopped && injectedProfilingHooks.markRenderStopped(); - } - function markStateUpdateScheduled(fiber, lane) { - null !== injectedProfilingHooks && "function" === typeof injectedProfilingHooks.markStateUpdateScheduled && injectedProfilingHooks.markStateUpdateScheduled(fiber, lane); - } - function clz32Fallback(x) { - x >>>= 0; - return 0 === x ? 32 : 31 - (log(x) / LN2 | 0) | 0; - } - function getLabelForLane(lane) { - if (lane & 1) return "SyncHydrationLane"; - if (lane & 2) return "Sync"; - if (lane & 4) return "InputContinuousHydration"; - if (lane & 8) return "InputContinuous"; - if (lane & 16) return "DefaultHydration"; - if (lane & 32) return "Default"; - if (lane & 64) return "TransitionHydration"; - if (lane & 4194176) return "Transition"; - if (lane & 62914560) return "Retry"; - if (lane & 67108864) return "SelectiveHydration"; - if (lane & 134217728) return "IdleHydration"; - if (lane & 268435456) return "Idle"; - if (lane & 536870912) return "Offscreen"; - if (lane & 1073741824) return "Deferred"; - } - function getHighestPriorityLanes(lanes) { - var pendingSyncLanes = lanes & 42; - if (0 !== pendingSyncLanes) return pendingSyncLanes; - switch (lanes & -lanes) { - case 1: - return 1; - case 2: - return 2; - case 4: - return 4; - case 8: - return 8; - case 16: - return 16; - case 32: - return 32; - case 64: - return 64; - case 128: - case 256: - case 512: - case 1024: - case 2048: - case 4096: - case 8192: - case 16384: - case 32768: - case 65536: - case 131072: - case 262144: - case 524288: - case 1048576: - case 2097152: - return lanes & 4194176; - case 4194304: - case 8388608: - case 16777216: - case 33554432: - return lanes & 62914560; - case 67108864: - return 67108864; - case 134217728: - return 134217728; - case 268435456: - return 268435456; - case 536870912: - return 536870912; - case 1073741824: - return 0; - default: - return console.error( - "Should have found matching lanes. This is a bug in React." - ), lanes; - } - } - function getNextLanes(root2, wipLanes) { - var pendingLanes = root2.pendingLanes; - if (0 === pendingLanes) return 0; - var nextLanes = 0, suspendedLanes = root2.suspendedLanes, pingedLanes = root2.pingedLanes, warmLanes = root2.warmLanes; - root2 = 0 !== root2.finishedLanes; - var nonIdlePendingLanes = pendingLanes & 134217727; - 0 !== nonIdlePendingLanes ? (pendingLanes = nonIdlePendingLanes & ~suspendedLanes, 0 !== pendingLanes ? nextLanes = getHighestPriorityLanes(pendingLanes) : (pingedLanes &= nonIdlePendingLanes, 0 !== pingedLanes ? nextLanes = getHighestPriorityLanes(pingedLanes) : root2 || (warmLanes = nonIdlePendingLanes & ~warmLanes, 0 !== warmLanes && (nextLanes = getHighestPriorityLanes(warmLanes))))) : (nonIdlePendingLanes = pendingLanes & ~suspendedLanes, 0 !== nonIdlePendingLanes ? nextLanes = getHighestPriorityLanes(nonIdlePendingLanes) : 0 !== pingedLanes ? nextLanes = getHighestPriorityLanes(pingedLanes) : root2 || (warmLanes = pendingLanes & ~warmLanes, 0 !== warmLanes && (nextLanes = getHighestPriorityLanes(warmLanes)))); - return 0 === nextLanes ? 0 : 0 !== wipLanes && wipLanes !== nextLanes && 0 === (wipLanes & suspendedLanes) && (suspendedLanes = nextLanes & -nextLanes, warmLanes = wipLanes & -wipLanes, suspendedLanes >= warmLanes || 32 === suspendedLanes && 0 !== (warmLanes & 4194176)) ? wipLanes : nextLanes; - } - function checkIfRootIsPrerendering(root2, renderLanes2) { - return 0 === (root2.pendingLanes & ~(root2.suspendedLanes & ~root2.pingedLanes) & renderLanes2); - } - function computeExpirationTime(lane, currentTime) { - switch (lane) { - case 1: - case 2: - case 4: - case 8: - return currentTime + 250; - case 16: - case 32: - case 64: - case 128: - case 256: - case 512: - case 1024: - case 2048: - case 4096: - case 8192: - case 16384: - case 32768: - case 65536: - case 131072: - case 262144: - case 524288: - case 1048576: - case 2097152: - return currentTime + 5e3; - case 4194304: - case 8388608: - case 16777216: - case 33554432: - return -1; - case 67108864: - case 134217728: - case 268435456: - case 536870912: - case 1073741824: - return -1; - default: - return console.error( - "Should have found matching lanes. This is a bug in React." - ), -1; - } - } - function claimNextTransitionLane() { - var lane = nextTransitionLane; - nextTransitionLane <<= 1; - 0 === (nextTransitionLane & 4194176) && (nextTransitionLane = 128); - return lane; - } - function claimNextRetryLane() { - var lane = nextRetryLane; - nextRetryLane <<= 1; - 0 === (nextRetryLane & 62914560) && (nextRetryLane = 4194304); - return lane; - } - function createLaneMap(initial) { - for (var laneMap = [], i = 0; 31 > i; i++) laneMap.push(initial); - return laneMap; - } - function markRootUpdated$1(root2, updateLane) { - root2.pendingLanes |= updateLane; - 268435456 !== updateLane && (root2.suspendedLanes = 0, root2.pingedLanes = 0, root2.warmLanes = 0); - } - function markRootFinished(root2, finishedLanes, remainingLanes, spawnedLane, updatedLanes, suspendedRetryLanes) { - var previouslyPendingLanes = root2.pendingLanes; - root2.pendingLanes = remainingLanes; - root2.suspendedLanes = 0; - root2.pingedLanes = 0; - root2.warmLanes = 0; - root2.expiredLanes &= remainingLanes; - root2.entangledLanes &= remainingLanes; - root2.errorRecoveryDisabledLanes &= remainingLanes; - root2.shellSuspendCounter = 0; - var entanglements = root2.entanglements, expirationTimes = root2.expirationTimes, hiddenUpdates = root2.hiddenUpdates; - for (remainingLanes = previouslyPendingLanes & ~remainingLanes; 0 < remainingLanes; ) { - var index = 31 - clz32(remainingLanes), lane = 1 << index; - entanglements[index] = 0; - expirationTimes[index] = -1; - var hiddenUpdatesForLane = hiddenUpdates[index]; - if (null !== hiddenUpdatesForLane) - for (hiddenUpdates[index] = null, index = 0; index < hiddenUpdatesForLane.length; index++) { - var update = hiddenUpdatesForLane[index]; - null !== update && (update.lane &= -536870913); - } - remainingLanes &= ~lane; - } - 0 !== spawnedLane && markSpawnedDeferredLane(root2, spawnedLane, 0); - 0 !== suspendedRetryLanes && 0 === updatedLanes && 0 !== root2.tag && (root2.suspendedLanes |= suspendedRetryLanes & ~(previouslyPendingLanes & ~finishedLanes)); - } - function markSpawnedDeferredLane(root2, spawnedLane, entangledLanes) { - root2.pendingLanes |= spawnedLane; - root2.suspendedLanes &= ~spawnedLane; - var spawnedLaneIndex = 31 - clz32(spawnedLane); - root2.entangledLanes |= spawnedLane; - root2.entanglements[spawnedLaneIndex] = root2.entanglements[spawnedLaneIndex] | 1073741824 | entangledLanes & 4194218; - } - function markRootEntangled(root2, entangledLanes) { - var rootEntangledLanes = root2.entangledLanes |= entangledLanes; - for (root2 = root2.entanglements; rootEntangledLanes; ) { - var index = 31 - clz32(rootEntangledLanes), lane = 1 << index; - lane & entangledLanes | root2[index] & entangledLanes && (root2[index] |= entangledLanes); - rootEntangledLanes &= ~lane; - } - } - function addFiberToLanesMap(root2, fiber, lanes) { - if (isDevToolsPresent) - for (root2 = root2.pendingUpdatersLaneMap; 0 < lanes; ) { - var index = 31 - clz32(lanes), lane = 1 << index; - root2[index].add(fiber); - lanes &= ~lane; - } - } - function movePendingFibersToMemoized(root2, lanes) { - if (isDevToolsPresent) - for (var pendingUpdatersLaneMap = root2.pendingUpdatersLaneMap, memoizedUpdaters = root2.memoizedUpdaters; 0 < lanes; ) { - var index = 31 - clz32(lanes); - root2 = 1 << index; - index = pendingUpdatersLaneMap[index]; - 0 < index.size && (index.forEach(function(fiber) { - var alternate = fiber.alternate; - null !== alternate && memoizedUpdaters.has(alternate) || memoizedUpdaters.add(fiber); - }), index.clear()); - lanes &= ~root2; - } - } - function lanesToEventPriority(lanes) { - lanes &= -lanes; - return 0 !== DiscreteEventPriority && DiscreteEventPriority < lanes ? 0 !== ContinuousEventPriority && ContinuousEventPriority < lanes ? 0 !== (lanes & 134217727) ? DefaultEventPriority : IdleEventPriority : ContinuousEventPriority : DiscreteEventPriority; - } - function resolveUpdatePriority() { - var updatePriority = ReactDOMSharedInternals.p; - if (0 !== updatePriority) return updatePriority; - updatePriority = window.event; - return void 0 === updatePriority ? DefaultEventPriority : getEventPriority(updatePriority.type); - } - function runWithPriority(priority, fn) { - var previousPriority = ReactDOMSharedInternals.p; - try { - return ReactDOMSharedInternals.p = priority, fn(); - } finally { - ReactDOMSharedInternals.p = previousPriority; - } - } - function detachDeletedInstance(node) { - delete node[internalInstanceKey]; - delete node[internalPropsKey]; - delete node[internalEventHandlersKey]; - delete node[internalEventHandlerListenersKey]; - delete node[internalEventHandlesSetKey]; - } - function getClosestInstanceFromNode(targetNode) { - var targetInst = targetNode[internalInstanceKey]; - if (targetInst) return targetInst; - for (var parentNode = targetNode.parentNode; parentNode; ) { - if (targetInst = parentNode[internalContainerInstanceKey] || parentNode[internalInstanceKey]) { - parentNode = targetInst.alternate; - if (null !== targetInst.child || null !== parentNode && null !== parentNode.child) - for (targetNode = getParentSuspenseInstance(targetNode); null !== targetNode; ) { - if (parentNode = targetNode[internalInstanceKey]) - return parentNode; - targetNode = getParentSuspenseInstance(targetNode); - } - return targetInst; - } - targetNode = parentNode; - parentNode = targetNode.parentNode; - } - return null; - } - function getInstanceFromNode(node) { - if (node = node[internalInstanceKey] || node[internalContainerInstanceKey]) { - var tag = node.tag; - if (5 === tag || 6 === tag || 13 === tag || 26 === tag || 27 === tag || 3 === tag) - return node; - } - return null; - } - function getNodeFromInstance(inst) { - var tag = inst.tag; - if (5 === tag || 26 === tag || 27 === tag || 6 === tag) - return inst.stateNode; - throw Error("getNodeFromInstance: Invalid argument."); - } - function getResourcesFromRoot(root2) { - var resources = root2[internalRootNodeResourcesKey]; - resources || (resources = root2[internalRootNodeResourcesKey] = { hoistableStyles: /* @__PURE__ */ new Map(), hoistableScripts: /* @__PURE__ */ new Map() }); - return resources; - } - function markNodeAsHoistable(node) { - node[internalHoistableMarker] = true; - } - function registerTwoPhaseEvent(registrationName, dependencies) { - registerDirectEvent(registrationName, dependencies); - registerDirectEvent(registrationName + "Capture", dependencies); - } - function registerDirectEvent(registrationName, dependencies) { - registrationNameDependencies[registrationName] && console.error( - "EventRegistry: More than one plugin attempted to publish the same registration name, `%s`.", - registrationName - ); - registrationNameDependencies[registrationName] = dependencies; - var lowerCasedName = registrationName.toLowerCase(); - possibleRegistrationNames[lowerCasedName] = registrationName; - "onDoubleClick" === registrationName && (possibleRegistrationNames.ondblclick = registrationName); - for (registrationName = 0; registrationName < dependencies.length; registrationName++) - allNativeEvents.add(dependencies[registrationName]); - } - function checkControlledValueProps(tagName, props) { - hasReadOnlyValue[props.type] || props.onChange || props.onInput || props.readOnly || props.disabled || null == props.value || ("select" === tagName ? console.error( - "You provided a `value` prop to a form field without an `onChange` handler. This will render a read-only field. If the field should be mutable use `defaultValue`. Otherwise, set `onChange`." - ) : console.error( - "You provided a `value` prop to a form field without an `onChange` handler. This will render a read-only field. If the field should be mutable use `defaultValue`. Otherwise, set either `onChange` or `readOnly`." - )); - props.onChange || props.readOnly || props.disabled || null == props.checked || console.error( - "You provided a `checked` prop to a form field without an `onChange` handler. This will render a read-only field. If the field should be mutable use `defaultChecked`. Otherwise, set either `onChange` or `readOnly`." - ); - } - function isAttributeNameSafe(attributeName) { - if (hasOwnProperty.call(validatedAttributeNameCache, attributeName)) - return true; - if (hasOwnProperty.call(illegalAttributeNameCache, attributeName)) - return false; - if (VALID_ATTRIBUTE_NAME_REGEX.test(attributeName)) - return validatedAttributeNameCache[attributeName] = true; - illegalAttributeNameCache[attributeName] = true; - console.error("Invalid attribute name: `%s`", attributeName); - return false; - } - function getValueForAttributeOnCustomComponent(node, name, expected) { - if (isAttributeNameSafe(name)) { - if (!node.hasAttribute(name)) { - switch (typeof expected) { - case "symbol": - case "object": - return expected; - case "function": - return expected; - case "boolean": - if (false === expected) return expected; - } - return void 0 === expected ? void 0 : null; - } - node = node.getAttribute(name); - if ("" === node && true === expected) return true; - checkAttributeStringCoercion(expected, name); - return node === "" + expected ? expected : node; - } - } - function setValueForAttribute(node, name, value) { - if (isAttributeNameSafe(name)) - if (null === value) node.removeAttribute(name); - else { - switch (typeof value) { - case "undefined": - case "function": - case "symbol": - node.removeAttribute(name); - return; - case "boolean": - var prefix2 = name.toLowerCase().slice(0, 5); - if ("data-" !== prefix2 && "aria-" !== prefix2) { - node.removeAttribute(name); - return; - } - } - checkAttributeStringCoercion(value, name); - node.setAttribute(name, "" + value); - } - } - function setValueForKnownAttribute(node, name, value) { - if (null === value) node.removeAttribute(name); - else { - switch (typeof value) { - case "undefined": - case "function": - case "symbol": - case "boolean": - node.removeAttribute(name); - return; - } - checkAttributeStringCoercion(value, name); - node.setAttribute(name, "" + value); - } - } - function setValueForNamespacedAttribute(node, namespace, name, value) { - if (null === value) node.removeAttribute(name); - else { - switch (typeof value) { - case "undefined": - case "function": - case "symbol": - case "boolean": - node.removeAttribute(name); - return; - } - checkAttributeStringCoercion(value, name); - node.setAttributeNS(namespace, name, "" + value); - } - } - function getToStringValue(value) { - switch (typeof value) { - case "bigint": - case "boolean": - case "number": - case "string": - case "undefined": - return value; - case "object": - return checkFormFieldValueStringCoercion(value), value; - default: - return ""; - } - } - function isCheckable(elem) { - var type = elem.type; - return (elem = elem.nodeName) && "input" === elem.toLowerCase() && ("checkbox" === type || "radio" === type); - } - function trackValueOnNode(node) { - var valueField = isCheckable(node) ? "checked" : "value", descriptor = Object.getOwnPropertyDescriptor( - node.constructor.prototype, - valueField - ); - checkFormFieldValueStringCoercion(node[valueField]); - var currentValue = "" + node[valueField]; - if (!node.hasOwnProperty(valueField) && "undefined" !== typeof descriptor && "function" === typeof descriptor.get && "function" === typeof descriptor.set) { - var get = descriptor.get, set = descriptor.set; - Object.defineProperty(node, valueField, { - configurable: true, - get: function() { - return get.call(this); - }, - set: function(value) { - checkFormFieldValueStringCoercion(value); - currentValue = "" + value; - set.call(this, value); - } - }); - Object.defineProperty(node, valueField, { - enumerable: descriptor.enumerable - }); - return { - getValue: function() { - return currentValue; - }, - setValue: function(value) { - checkFormFieldValueStringCoercion(value); - currentValue = "" + value; - }, - stopTracking: function() { - node._valueTracker = null; - delete node[valueField]; - } - }; - } - } - function track(node) { - node._valueTracker || (node._valueTracker = trackValueOnNode(node)); - } - function updateValueIfChanged(node) { - if (!node) return false; - var tracker = node._valueTracker; - if (!tracker) return true; - var lastValue = tracker.getValue(); - var value = ""; - node && (value = isCheckable(node) ? node.checked ? "true" : "false" : node.value); - node = value; - return node !== lastValue ? (tracker.setValue(node), true) : false; - } - function getActiveElement(doc) { - doc = doc || ("undefined" !== typeof document ? document : void 0); - if ("undefined" === typeof doc) return null; - try { - return doc.activeElement || doc.body; - } catch (e) { - return doc.body; - } - } - function escapeSelectorAttributeValueInsideDoubleQuotes(value) { - return value.replace( - escapeSelectorAttributeValueInsideDoubleQuotesRegex, - function(ch) { - return "\\" + ch.charCodeAt(0).toString(16) + " "; - } - ); - } - function validateInputProps(element, props) { - void 0 === props.checked || void 0 === props.defaultChecked || didWarnCheckedDefaultChecked || (console.error( - "%s contains an input of type %s with both checked and defaultChecked props. Input elements must be either controlled or uncontrolled (specify either the checked prop, or the defaultChecked prop, but not both). Decide between using a controlled or uncontrolled input element and remove one of these props. More info: https://react.dev/link/controlled-components", - getCurrentFiberOwnerNameInDevOrNull() || "A component", - props.type - ), didWarnCheckedDefaultChecked = true); - void 0 === props.value || void 0 === props.defaultValue || didWarnValueDefaultValue$1 || (console.error( - "%s contains an input of type %s with both value and defaultValue props. Input elements must be either controlled or uncontrolled (specify either the value prop, or the defaultValue prop, but not both). Decide between using a controlled or uncontrolled input element and remove one of these props. More info: https://react.dev/link/controlled-components", - getCurrentFiberOwnerNameInDevOrNull() || "A component", - props.type - ), didWarnValueDefaultValue$1 = true); - } - function updateInput(element, value, defaultValue, lastDefaultValue, checked, defaultChecked, type, name) { - element.name = ""; - null != type && "function" !== typeof type && "symbol" !== typeof type && "boolean" !== typeof type ? (checkAttributeStringCoercion(type, "type"), element.type = type) : element.removeAttribute("type"); - if (null != value) - if ("number" === type) { - if (0 === value && "" === element.value || element.value != value) - element.value = "" + getToStringValue(value); - } else - element.value !== "" + getToStringValue(value) && (element.value = "" + getToStringValue(value)); - else - "submit" !== type && "reset" !== type || element.removeAttribute("value"); - null != value ? setDefaultValue(element, type, getToStringValue(value)) : null != defaultValue ? setDefaultValue(element, type, getToStringValue(defaultValue)) : null != lastDefaultValue && element.removeAttribute("value"); - null == checked && null != defaultChecked && (element.defaultChecked = !!defaultChecked); - null != checked && (element.checked = checked && "function" !== typeof checked && "symbol" !== typeof checked); - null != name && "function" !== typeof name && "symbol" !== typeof name && "boolean" !== typeof name ? (checkAttributeStringCoercion(name, "name"), element.name = "" + getToStringValue(name)) : element.removeAttribute("name"); - } - function initInput(element, value, defaultValue, checked, defaultChecked, type, name, isHydrating2) { - null != type && "function" !== typeof type && "symbol" !== typeof type && "boolean" !== typeof type && (checkAttributeStringCoercion(type, "type"), element.type = type); - if (null != value || null != defaultValue) { - if (!("submit" !== type && "reset" !== type || void 0 !== value && null !== value)) - return; - defaultValue = null != defaultValue ? "" + getToStringValue(defaultValue) : ""; - value = null != value ? "" + getToStringValue(value) : defaultValue; - isHydrating2 || value === element.value || (element.value = value); - element.defaultValue = value; - } - checked = null != checked ? checked : defaultChecked; - checked = "function" !== typeof checked && "symbol" !== typeof checked && !!checked; - element.checked = isHydrating2 ? element.checked : !!checked; - element.defaultChecked = !!checked; - null != name && "function" !== typeof name && "symbol" !== typeof name && "boolean" !== typeof name && (checkAttributeStringCoercion(name, "name"), element.name = name); - } - function setDefaultValue(node, type, value) { - "number" === type && getActiveElement(node.ownerDocument) === node || node.defaultValue === "" + value || (node.defaultValue = "" + value); - } - function validateOptionProps(element, props) { - null == props.value && ("object" === typeof props.children && null !== props.children ? React.Children.forEach(props.children, function(child) { - null == child || "string" === typeof child || "number" === typeof child || "bigint" === typeof child || didWarnInvalidChild || (didWarnInvalidChild = true, console.error( - "Cannot infer the option value of complex children. Pass a `value` prop or use a plain string as children to