gmichels / terraform-provider-adguard

Terraform provider for AdGuard
https://registry.terraform.io/providers/gmichels/adguard/latest/docs
MIT License
9 stars 4 forks source link

Add support for new DNS config settings #81

Closed gmichels closed 6 months ago

gmichels commented 7 months ago

Add support for new DNS config settings:

cryptiklemur commented 6 months ago

Got some issues that cropped up here:

When not specifying blocked_services_pause_schedule in my config

│ Error: Value Conversion Error
│
│   with module.adguard.adguard_config.config,
│   on adguard/main.tf line 1, in resource "adguard_config" "config":
│    1: resource "adguard_config" "config" {
│
│ An unexpected error was encountered while verifying an attribute value matched its expected type to prevent
│ unexpected behavior or panics. This is always an error in the provider. Please report the following to the
│ provider developer:
│
│ Expected framework type from provider logic:
│ types.ObjectType["fri":types.ObjectType["end":basetypes.StringType, "start":basetypes.StringType],
│ "mon":types.ObjectType["end":basetypes.StringType, "start":basetypes.StringType],
│ "sat":types.ObjectType["end":basetypes.StringType, "start":basetypes.StringType],
│ "sun":types.ObjectType["end":basetypes.StringType, "start":basetypes.StringType],
│ "thu":types.ObjectType["end":basetypes.StringType, "start":basetypes.StringType],
│ "time_zone":basetypes.StringType, "tue":types.ObjectType["end":basetypes.StringType,
│ "start":basetypes.StringType], "wed":types.ObjectType["end":basetypes.StringType,
│ "start":basetypes.StringType]] / underlying type: tftypes.Object["fri":tftypes.Object["end":tftypes.String,
│ "start":tftypes.String], "mon":tftypes.Object["end":tftypes.String, "start":tftypes.String],
│ "sat":tftypes.Object["end":tftypes.String, "start":tftypes.String], "sun":tftypes.Object["end":tftypes.String,
│ "start":tftypes.String], "thu":tftypes.Object["end":tftypes.String, "start":tftypes.String],
│ "time_zone":tftypes.String, "tue":tftypes.Object["end":tftypes.String, "start":tftypes.String],
│ "wed":tftypes.Object["end":tftypes.String, "start":tftypes.String]]
│ Received framework type from provider logic: types.ObjectType[] / underlying type: tftypes.Object[]
│ Path: blocked_services_pause_schedule
│
│   with module.adguard.adguard_client.home,
│   on adguard/clients.tf line 64, in resource "adguard_client" "home":
│   64:   tags                        = ["device_other"]
│
│ An unexpected error was encountered while verifying an attribute value matched its expected type to prevent
│ unexpected behavior or panics. This is always an error in the provider. Please report the following to the
│ provider developer:
│
│ Expected framework type from provider logic: types.SetType[basetypes.StringType] / underlying type:
│ tftypes.Set[tftypes.String]
│ Received framework type from provider logic: types.SetType[!!! MISSING TYPE !!!] / underlying type:
│ tftypes.Set[tftypes.DynamicPseudoType]
│ Path: tags
╷
│ Error: Value Conversion Error
│
│   with module.adguard.adguard_client.homelab,
│   on adguard/clients.tf line 40, in resource "adguard_client" "homelab":
│   40: resource "adguard_client" "homelab" {
│
│ An unexpected error was encountered while verifying an attribute value matched its expected type to prevent
│ unexpected behavior or panics. This is always an error in the provider. Please report the following to the
│ provider developer:
│
│ Expected framework type from provider logic: types.SetType[basetypes.StringType] / underlying type:
│ tftypes.Set[tftypes.String]
│ Received framework type from provider logic: types.SetType[!!! MISSING TYPE !!!] / underlying type:
│ tftypes.Set[tftypes.DynamicPseudoType]
│ Path: blocked_services
gmichels commented 6 months ago

Seems this only happens when upgrading from an earlier version, as I can't reproduce on a clean state. Will try to understand what is going on.

gmichels commented 6 months ago

Should be fixed in v1.1.2.