Skip to content

Commit decb730

Browse files
committed
types: Migrate type implementations into basetypes subpackage
Reference: #91 Aliasing and function shadowing in the original `types` package should prevent most provider developer changes. The main exception is the newer type-specific `Typable` and `Valuable` interfaces were moved without a type alias. This should help developers find the necessary interfaces for custom types next to the base type implementations. The underlying implementation of the primitive types (`BoolType`, `Float64Type`, `Int64Type`, `NumberType`, and `StringType`) are now fully exported types instead of the unexported `primitive` type which was difficult to extend. The underlying value type creation functions were prefixed with New and the value types themselves were renamed to include Value at the end. This should prevent rough edges with the `String` value type since it conflicted with the `String()` method and could not be directly embedded easily.
1 parent d51781c commit decb730

File tree

167 files changed

+3677
-3442
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

167 files changed

+3677
-3442
lines changed

.changelog/pending.txt

+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
```release-note:feature
2+
types/basetypes: New package which contains embeddable types for custom types
3+
```
4+
5+
```release-note:breaking-change
6+
types: The type-specific `Typable` and `Valuable` interfaces have been moved into the underlying `basetypes` package.
7+
```
8+
9+
```release-note:note
10+
types: Framework type implementations have been moved into the underlying `basetypes` package. Value creation functions and type aliases have been created in the `types` package that should prevent any breaking changes.
11+
```

datasource/schema/bool_attribute.go

+3-2
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ import (
66
"github.com/hashicorp/terraform-plugin-framework/internal/fwschema/fwxschema"
77
"github.com/hashicorp/terraform-plugin-framework/schema/validator"
88
"github.com/hashicorp/terraform-plugin-framework/types"
9+
"github.com/hashicorp/terraform-plugin-framework/types/basetypes"
910
"github.com/hashicorp/terraform-plugin-go/tftypes"
1011
)
1112

@@ -29,9 +30,9 @@ var (
2930
// .example_attribute
3031
type BoolAttribute struct {
3132
// CustomType enables the use of a custom attribute type in place of the
32-
// default types.BoolType. When retrieving data, the types.BoolValuable
33+
// default basetypes.BoolType. When retrieving data, the basetypes.BoolValuable
3334
// associated with this custom type must be used in place of types.Bool.
34-
CustomType types.BoolTypable
35+
CustomType basetypes.BoolTypable
3536

3637
// Required indicates whether the practitioner must enter a value for
3738
// this attribute or not. Required and Optional cannot both be true,

datasource/schema/bool_attribute_test.go

+4-4
Original file line numberDiff line numberDiff line change
@@ -29,25 +29,25 @@ func TestBoolAttributeApplyTerraform5AttributePathStep(t *testing.T) {
2929
attribute: schema.BoolAttribute{},
3030
step: tftypes.AttributeName("test"),
3131
expected: nil,
32-
expectedError: fmt.Errorf("cannot apply AttributePathStep tftypes.AttributeName to types.BoolType"),
32+
expectedError: fmt.Errorf("cannot apply AttributePathStep tftypes.AttributeName to basetypes.BoolType"),
3333
},
3434
"ElementKeyInt": {
3535
attribute: schema.BoolAttribute{},
3636
step: tftypes.ElementKeyInt(1),
3737
expected: nil,
38-
expectedError: fmt.Errorf("cannot apply AttributePathStep tftypes.ElementKeyInt to types.BoolType"),
38+
expectedError: fmt.Errorf("cannot apply AttributePathStep tftypes.ElementKeyInt to basetypes.BoolType"),
3939
},
4040
"ElementKeyString": {
4141
attribute: schema.BoolAttribute{},
4242
step: tftypes.ElementKeyString("test"),
4343
expected: nil,
44-
expectedError: fmt.Errorf("cannot apply AttributePathStep tftypes.ElementKeyString to types.BoolType"),
44+
expectedError: fmt.Errorf("cannot apply AttributePathStep tftypes.ElementKeyString to basetypes.BoolType"),
4545
},
4646
"ElementKeyValue": {
4747
attribute: schema.BoolAttribute{},
4848
step: tftypes.ElementKeyValue(tftypes.NewValue(tftypes.String, "test")),
4949
expected: nil,
50-
expectedError: fmt.Errorf("cannot apply AttributePathStep tftypes.ElementKeyValue to types.BoolType"),
50+
expectedError: fmt.Errorf("cannot apply AttributePathStep tftypes.ElementKeyValue to basetypes.BoolType"),
5151
},
5252
}
5353

datasource/schema/float64_attribute.go

+3-2
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ import (
66
"github.com/hashicorp/terraform-plugin-framework/internal/fwschema/fwxschema"
77
"github.com/hashicorp/terraform-plugin-framework/schema/validator"
88
"github.com/hashicorp/terraform-plugin-framework/types"
9+
"github.com/hashicorp/terraform-plugin-framework/types/basetypes"
910
"github.com/hashicorp/terraform-plugin-go/tftypes"
1011
)
1112

@@ -32,9 +33,9 @@ var (
3233
// .example_attribute
3334
type Float64Attribute struct {
3435
// CustomType enables the use of a custom attribute type in place of the
35-
// default types.Float64Type. When retrieving data, the types.Float64Valuable
36+
// default basetypes.Float64Type. When retrieving data, the basetypes.Float64Valuable
3637
// associated with this custom type must be used in place of types.Float64.
37-
CustomType types.Float64Typable
38+
CustomType basetypes.Float64Typable
3839

3940
// Required indicates whether the practitioner must enter a value for
4041
// this attribute or not. Required and Optional cannot both be true,

datasource/schema/float64_attribute_test.go

+4-4
Original file line numberDiff line numberDiff line change
@@ -28,25 +28,25 @@ func TestFloat64AttributeApplyTerraform5AttributePathStep(t *testing.T) {
2828
attribute: schema.Float64Attribute{},
2929
step: tftypes.AttributeName("test"),
3030
expected: nil,
31-
expectedError: fmt.Errorf("cannot apply AttributePathStep tftypes.AttributeName to types.Float64Type"),
31+
expectedError: fmt.Errorf("cannot apply AttributePathStep tftypes.AttributeName to basetypes.Float64Type"),
3232
},
3333
"ElementKeyInt": {
3434
attribute: schema.Float64Attribute{},
3535
step: tftypes.ElementKeyInt(1),
3636
expected: nil,
37-
expectedError: fmt.Errorf("cannot apply AttributePathStep tftypes.ElementKeyInt to types.Float64Type"),
37+
expectedError: fmt.Errorf("cannot apply AttributePathStep tftypes.ElementKeyInt to basetypes.Float64Type"),
3838
},
3939
"ElementKeyString": {
4040
attribute: schema.Float64Attribute{},
4141
step: tftypes.ElementKeyString("test"),
4242
expected: nil,
43-
expectedError: fmt.Errorf("cannot apply AttributePathStep tftypes.ElementKeyString to types.Float64Type"),
43+
expectedError: fmt.Errorf("cannot apply AttributePathStep tftypes.ElementKeyString to basetypes.Float64Type"),
4444
},
4545
"ElementKeyValue": {
4646
attribute: schema.Float64Attribute{},
4747
step: tftypes.ElementKeyValue(tftypes.NewValue(tftypes.String, "test")),
4848
expected: nil,
49-
expectedError: fmt.Errorf("cannot apply AttributePathStep tftypes.ElementKeyValue to types.Float64Type"),
49+
expectedError: fmt.Errorf("cannot apply AttributePathStep tftypes.ElementKeyValue to basetypes.Float64Type"),
5050
},
5151
}
5252

datasource/schema/int64_attribute.go

+3-2
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ import (
66
"github.com/hashicorp/terraform-plugin-framework/internal/fwschema/fwxschema"
77
"github.com/hashicorp/terraform-plugin-framework/schema/validator"
88
"github.com/hashicorp/terraform-plugin-framework/types"
9+
"github.com/hashicorp/terraform-plugin-framework/types/basetypes"
910
"github.com/hashicorp/terraform-plugin-go/tftypes"
1011
)
1112

@@ -32,9 +33,9 @@ var (
3233
// .example_attribute
3334
type Int64Attribute struct {
3435
// CustomType enables the use of a custom attribute type in place of the
35-
// default types.Int64Type. When retrieving data, the types.Int64Valuable
36+
// default basetypes.Int64Type. When retrieving data, the basetypes.Int64Valuable
3637
// associated with this custom type must be used in place of types.Int64.
37-
CustomType types.Int64Typable
38+
CustomType basetypes.Int64Typable
3839

3940
// Required indicates whether the practitioner must enter a value for
4041
// this attribute or not. Required and Optional cannot both be true,

datasource/schema/int64_attribute_test.go

+4-4
Original file line numberDiff line numberDiff line change
@@ -28,25 +28,25 @@ func TestInt64AttributeApplyTerraform5AttributePathStep(t *testing.T) {
2828
attribute: schema.Int64Attribute{},
2929
step: tftypes.AttributeName("test"),
3030
expected: nil,
31-
expectedError: fmt.Errorf("cannot apply AttributePathStep tftypes.AttributeName to types.Int64Type"),
31+
expectedError: fmt.Errorf("cannot apply AttributePathStep tftypes.AttributeName to basetypes.Int64Type"),
3232
},
3333
"ElementKeyInt": {
3434
attribute: schema.Int64Attribute{},
3535
step: tftypes.ElementKeyInt(1),
3636
expected: nil,
37-
expectedError: fmt.Errorf("cannot apply AttributePathStep tftypes.ElementKeyInt to types.Int64Type"),
37+
expectedError: fmt.Errorf("cannot apply AttributePathStep tftypes.ElementKeyInt to basetypes.Int64Type"),
3838
},
3939
"ElementKeyString": {
4040
attribute: schema.Int64Attribute{},
4141
step: tftypes.ElementKeyString("test"),
4242
expected: nil,
43-
expectedError: fmt.Errorf("cannot apply AttributePathStep tftypes.ElementKeyString to types.Int64Type"),
43+
expectedError: fmt.Errorf("cannot apply AttributePathStep tftypes.ElementKeyString to basetypes.Int64Type"),
4444
},
4545
"ElementKeyValue": {
4646
attribute: schema.Int64Attribute{},
4747
step: tftypes.ElementKeyValue(tftypes.NewValue(tftypes.String, "test")),
4848
expected: nil,
49-
expectedError: fmt.Errorf("cannot apply AttributePathStep tftypes.ElementKeyValue to types.Int64Type"),
49+
expectedError: fmt.Errorf("cannot apply AttributePathStep tftypes.ElementKeyValue to basetypes.Int64Type"),
5050
},
5151
}
5252

datasource/schema/list_attribute.go

+3-2
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ import (
66
"github.com/hashicorp/terraform-plugin-framework/internal/fwschema/fwxschema"
77
"github.com/hashicorp/terraform-plugin-framework/schema/validator"
88
"github.com/hashicorp/terraform-plugin-framework/types"
9+
"github.com/hashicorp/terraform-plugin-framework/types/basetypes"
910
"github.com/hashicorp/terraform-plugin-go/tftypes"
1011
)
1112

@@ -40,9 +41,9 @@ type ListAttribute struct {
4041
ElementType attr.Type
4142

4243
// CustomType enables the use of a custom attribute type in place of the
43-
// default types.ListType. When retrieving data, the types.ListValuable
44+
// default basetypes.ListType. When retrieving data, the basetypes.ListValuable
4445
// associated with this custom type must be used in place of types.List.
45-
CustomType types.ListTypable
46+
CustomType basetypes.ListTypable
4647

4748
// Required indicates whether the practitioner must enter a value for
4849
// this attribute or not. Required and Optional cannot both be true,

datasource/schema/list_nested_attribute.go

+3-2
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ import (
88
"github.com/hashicorp/terraform-plugin-framework/internal/fwschema/fwxschema"
99
"github.com/hashicorp/terraform-plugin-framework/schema/validator"
1010
"github.com/hashicorp/terraform-plugin-framework/types"
11+
"github.com/hashicorp/terraform-plugin-framework/types/basetypes"
1112
"github.com/hashicorp/terraform-plugin-go/tftypes"
1213
)
1314

@@ -51,9 +52,9 @@ type ListNestedAttribute struct {
5152

5253
// CustomType enables the use of a custom attribute type in place of the
5354
// default types.ListType of types.ObjectType. When retrieving data, the
54-
// types.ListValuable associated with this custom type must be used in
55+
// basetypes.ListValuable associated with this custom type must be used in
5556
// place of types.List.
56-
CustomType types.ListTypable
57+
CustomType basetypes.ListTypable
5758

5859
// Required indicates whether the practitioner must enter a value for
5960
// this attribute or not. Required and Optional cannot both be true,

datasource/schema/list_nested_block.go

+3-2
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ import (
88
"github.com/hashicorp/terraform-plugin-framework/internal/fwschema/fwxschema"
99
"github.com/hashicorp/terraform-plugin-framework/schema/validator"
1010
"github.com/hashicorp/terraform-plugin-framework/types"
11+
"github.com/hashicorp/terraform-plugin-framework/types/basetypes"
1112
"github.com/hashicorp/terraform-plugin-go/tftypes"
1213
)
1314

@@ -55,9 +56,9 @@ type ListNestedBlock struct {
5556

5657
// CustomType enables the use of a custom attribute type in place of the
5758
// default types.ListType of types.ObjectType. When retrieving data, the
58-
// types.ListValuable associated with this custom type must be used in
59+
// basetypes.ListValuable associated with this custom type must be used in
5960
// place of types.List.
60-
CustomType types.ListTypable
61+
CustomType basetypes.ListTypable
6162

6263
// Description is used in various tooling, like the language server, to
6364
// give practitioners more information about what this attribute is,

datasource/schema/map_attribute.go

+3-2
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ import (
66
"github.com/hashicorp/terraform-plugin-framework/internal/fwschema/fwxschema"
77
"github.com/hashicorp/terraform-plugin-framework/schema/validator"
88
"github.com/hashicorp/terraform-plugin-framework/types"
9+
"github.com/hashicorp/terraform-plugin-framework/types/basetypes"
910
"github.com/hashicorp/terraform-plugin-go/tftypes"
1011
)
1112

@@ -43,9 +44,9 @@ type MapAttribute struct {
4344
ElementType attr.Type
4445

4546
// CustomType enables the use of a custom attribute type in place of the
46-
// default types.MapType. When retrieving data, the types.MapValuable
47+
// default basetypes.MapType. When retrieving data, the basetypes.MapValuable
4748
// associated with this custom type must be used in place of types.Map.
48-
CustomType types.MapTypable
49+
CustomType basetypes.MapTypable
4950

5051
// Required indicates whether the practitioner must enter a value for
5152
// this attribute or not. Required and Optional cannot both be true,

datasource/schema/map_nested_attribute.go

+3-2
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ import (
1010
"github.com/hashicorp/terraform-plugin-framework/internal/fwschema/fwxschema"
1111
"github.com/hashicorp/terraform-plugin-framework/schema/validator"
1212
"github.com/hashicorp/terraform-plugin-framework/types"
13+
"github.com/hashicorp/terraform-plugin-framework/types/basetypes"
1314
)
1415

1516
// Ensure the implementation satisifies the desired interfaces.
@@ -52,9 +53,9 @@ type MapNestedAttribute struct {
5253

5354
// CustomType enables the use of a custom attribute type in place of the
5455
// default types.MapType of types.ObjectType. When retrieving data, the
55-
// types.MapValuable associated with this custom type must be used in
56+
// basetypes.MapValuable associated with this custom type must be used in
5657
// place of types.Map.
57-
CustomType types.MapTypable
58+
CustomType basetypes.MapTypable
5859

5960
// Required indicates whether the practitioner must enter a value for
6061
// this attribute or not. Required and Optional cannot both be true,

datasource/schema/nested_attribute_object.go

+4-4
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ import (
44
"github.com/hashicorp/terraform-plugin-framework/internal/fwschema"
55
"github.com/hashicorp/terraform-plugin-framework/internal/fwschema/fwxschema"
66
"github.com/hashicorp/terraform-plugin-framework/schema/validator"
7-
"github.com/hashicorp/terraform-plugin-framework/types"
7+
"github.com/hashicorp/terraform-plugin-framework/types/basetypes"
88
"github.com/hashicorp/terraform-plugin-go/tftypes"
99
)
1010

@@ -27,9 +27,9 @@ type NestedAttributeObject struct {
2727
Attributes map[string]Attribute
2828

2929
// CustomType enables the use of a custom attribute type in place of the
30-
// default types.ObjectType. When retrieving data, the types.ObjectValuable
30+
// default basetypes.ObjectType. When retrieving data, the basetypes.ObjectValuable
3131
// associated with this custom type must be used in place of types.Object.
32-
CustomType types.ObjectTypable
32+
CustomType basetypes.ObjectTypable
3333

3434
// Validators define value validation functionality for the attribute. All
3535
// elements of the slice of AttributeValidator are run, regardless of any
@@ -70,7 +70,7 @@ func (o NestedAttributeObject) ObjectValidators() []validator.Object {
7070
}
7171

7272
// Type returns the framework type of the NestedAttributeObject.
73-
func (o NestedAttributeObject) Type() types.ObjectTypable {
73+
func (o NestedAttributeObject) Type() basetypes.ObjectTypable {
7474
if o.CustomType != nil {
7575
return o.CustomType
7676
}

datasource/schema/nested_block_object.go

+4-4
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ import (
44
"github.com/hashicorp/terraform-plugin-framework/internal/fwschema"
55
"github.com/hashicorp/terraform-plugin-framework/internal/fwschema/fwxschema"
66
"github.com/hashicorp/terraform-plugin-framework/schema/validator"
7-
"github.com/hashicorp/terraform-plugin-framework/types"
7+
"github.com/hashicorp/terraform-plugin-framework/types/basetypes"
88
"github.com/hashicorp/terraform-plugin-go/tftypes"
99
)
1010

@@ -34,9 +34,9 @@ type NestedBlockObject struct {
3434
Blocks map[string]Block
3535

3636
// CustomType enables the use of a custom attribute type in place of the
37-
// default types.ObjectType. When retrieving data, the types.ObjectValuable
37+
// default basetypes.ObjectType. When retrieving data, the basetypes.ObjectValuable
3838
// associated with this custom type must be used in place of types.Object.
39-
CustomType types.ObjectTypable
39+
CustomType basetypes.ObjectTypable
4040

4141
// Validators define value validation functionality for the attribute. All
4242
// elements of the slice of AttributeValidator are run, regardless of any
@@ -82,7 +82,7 @@ func (o NestedBlockObject) ObjectValidators() []validator.Object {
8282
}
8383

8484
// Type returns the framework type of the NestedBlockObject.
85-
func (o NestedBlockObject) Type() types.ObjectTypable {
85+
func (o NestedBlockObject) Type() basetypes.ObjectTypable {
8686
if o.CustomType != nil {
8787
return o.CustomType
8888
}

datasource/schema/number_attribute.go

+3-2
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ import (
66
"github.com/hashicorp/terraform-plugin-framework/internal/fwschema/fwxschema"
77
"github.com/hashicorp/terraform-plugin-framework/schema/validator"
88
"github.com/hashicorp/terraform-plugin-framework/types"
9+
"github.com/hashicorp/terraform-plugin-framework/types/basetypes"
910
"github.com/hashicorp/terraform-plugin-go/tftypes"
1011
)
1112

@@ -33,9 +34,9 @@ var (
3334
// .example_attribute
3435
type NumberAttribute struct {
3536
// CustomType enables the use of a custom attribute type in place of the
36-
// default types.NumberType. When retrieving data, the types.NumberValuable
37+
// default basetypes.NumberType. When retrieving data, the basetypes.NumberValuable
3738
// associated with this custom type must be used in place of types.Number.
38-
CustomType types.NumberTypable
39+
CustomType basetypes.NumberTypable
3940

4041
// Required indicates whether the practitioner must enter a value for
4142
// this attribute or not. Required and Optional cannot both be true,

datasource/schema/number_attribute_test.go

+4-4
Original file line numberDiff line numberDiff line change
@@ -29,25 +29,25 @@ func TestNumberAttributeApplyTerraform5AttributePathStep(t *testing.T) {
2929
attribute: schema.NumberAttribute{},
3030
step: tftypes.AttributeName("test"),
3131
expected: nil,
32-
expectedError: fmt.Errorf("cannot apply AttributePathStep tftypes.AttributeName to types.NumberType"),
32+
expectedError: fmt.Errorf("cannot apply AttributePathStep tftypes.AttributeName to basetypes.NumberType"),
3333
},
3434
"ElementKeyInt": {
3535
attribute: schema.NumberAttribute{},
3636
step: tftypes.ElementKeyInt(1),
3737
expected: nil,
38-
expectedError: fmt.Errorf("cannot apply AttributePathStep tftypes.ElementKeyInt to types.NumberType"),
38+
expectedError: fmt.Errorf("cannot apply AttributePathStep tftypes.ElementKeyInt to basetypes.NumberType"),
3939
},
4040
"ElementKeyString": {
4141
attribute: schema.NumberAttribute{},
4242
step: tftypes.ElementKeyString("test"),
4343
expected: nil,
44-
expectedError: fmt.Errorf("cannot apply AttributePathStep tftypes.ElementKeyString to types.NumberType"),
44+
expectedError: fmt.Errorf("cannot apply AttributePathStep tftypes.ElementKeyString to basetypes.NumberType"),
4545
},
4646
"ElementKeyValue": {
4747
attribute: schema.NumberAttribute{},
4848
step: tftypes.ElementKeyValue(tftypes.NewValue(tftypes.String, "test")),
4949
expected: nil,
50-
expectedError: fmt.Errorf("cannot apply AttributePathStep tftypes.ElementKeyValue to types.NumberType"),
50+
expectedError: fmt.Errorf("cannot apply AttributePathStep tftypes.ElementKeyValue to basetypes.NumberType"),
5151
},
5252
}
5353

datasource/schema/object_attribute.go

+3-2
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ import (
66
"github.com/hashicorp/terraform-plugin-framework/internal/fwschema/fwxschema"
77
"github.com/hashicorp/terraform-plugin-framework/schema/validator"
88
"github.com/hashicorp/terraform-plugin-framework/types"
9+
"github.com/hashicorp/terraform-plugin-framework/types/basetypes"
910
"github.com/hashicorp/terraform-plugin-go/tftypes"
1011
)
1112

@@ -42,9 +43,9 @@ type ObjectAttribute struct {
4243
AttributeTypes map[string]attr.Type
4344

4445
// CustomType enables the use of a custom attribute type in place of the
45-
// default types.ObjectType. When retrieving data, the types.ObjectValuable
46+
// default basetypes.ObjectType. When retrieving data, the basetypes.ObjectValuable
4647
// associated with this custom type must be used in place of types.Object.
47-
CustomType types.ObjectTypable
48+
CustomType basetypes.ObjectTypable
4849

4950
// Required indicates whether the practitioner must enter a value for
5051
// this attribute or not. Required and Optional cannot both be true,

0 commit comments

Comments
 (0)