Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

helm-framework: refactor metadata from ListNestedAttribute -> SingleNestedAttribute #1516

Merged
merged 3 commits into from
Oct 25, 2024

Conversation

BBBmau
Copy link
Contributor

@BBBmau BBBmau commented Oct 25, 2024

Description

The tfstate is now in the SingleNestedAttirbute format:

(base) ┌─(~/Dev/Scratch/helm-framework-scratch)────────────────────────────────────────────────────────(mau@mau-JKDT676NCP:s029)─┐
└─(11:44:11)──> cat terraform.tfstate                                                                   1 ↵ ──(Fri,Oct25)─┘
{
  "version": 4,
  "terraform_version": "1.8.0",
  "serial": 3,
  "lineage": "4224ea60-8c75-7e04-304a-2247f1516dd0",
  "outputs": {},
  "resources": [
    {
      "mode": "managed",
      "type": "helm_release",
      "name": "helm_migration_test_1",
      "provider": "provider[\"registry.terraform.io/hashicorp/helm\"]",
      "instances": [
        {
          "status": "tainted",
          "schema_version": 1,
          "attributes": {
            "atomic": false,
            "chart": "redis",
            "cleanup_on_fail": false,
            "create_namespace": false,
            "dependency_update": false,
            "description": "Test",
            "devel": null,
            "disable_crd_hooks": false,
            "disable_openapi_validation": false,
            "disable_webhooks": false,
            "force_update": false,
            "id": "helm-test-1",
            "keyring": null,
            "lint": false,
            "manifest": null,
            "max_history": 0,
            "metadata": {
              "app_version": "7.4.0",
              "chart": "redis",
              "first_deployed": 1729881734,
              "last_deployed": 1729881734,
              "name": "helm-test-1",
              "namespace": "default",
              "revision": 1,
              "values": "{}",
              "version": "20.1.4"
            },
            "name": "helm-test-1",
            "namespace": "default",
            "pass_credentials": false,
            "postrender": null,
            "recreate_pods": false,
            "render_subchart_notes": true,
            "replace": false,
            "repository": "bitnami",
            "repository_ca_file": null,
            "repository_cert_file": null,
            "repository_key_file": null,
            "repository_password": null,
            "repository_username": null,
            "reset_values": false,
            "reuse_values": false,
            "set": null,
            "set_list": null,
            "set_sensitive": null,
            "skip_crds": false,
            "status": "deployed",
            "timeout": 300,
            "values": null,
            "verify": false,
            "version": "20.1.4",
            "wait": true,
            "wait_for_jobs": false
          },
          "sensitive_attributes": [
            [
              {
                "type": "get_attr",
                "value": "repository_password"
              }
            ]
          ]
        }
      ]
    }
  ],
  "check_results": null
}

Acceptance tests

  • Have you added an acceptance test for the functionality being added?

Release Note

Release note for CHANGELOG:

...

References

Community Note

  • Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment

@BBBmau BBBmau changed the title initial refactor of metadata to be SingleNestedAttribute helm-framework: refactor metadata from ListNestedAttribute -> SingleNestedAttribute Oct 25, 2024
@BBBmau BBBmau marked this pull request as ready for review October 25, 2024 19:03
@BBBmau BBBmau requested a review from a team as a code owner October 25, 2024 19:03
@BBBmau BBBmau requested a review from JaylonmcShan03 October 25, 2024 19:03
@github-actions github-actions bot added size/XL and removed size/M labels Oct 25, 2024
@BBBmau BBBmau force-pushed the refactor-metadata-singlenestedattribute branch from 16bccb8 to e4f1b35 Compare October 25, 2024 19:34
@github-actions github-actions bot added size/L and removed size/XL labels Oct 25, 2024
@JaylonmcShan03
Copy link
Contributor

Thanks for the updated test!

@BBBmau BBBmau merged commit 7f17727 into helm-framework Oct 25, 2024
4 of 13 checks passed
@BBBmau BBBmau deleted the refactor-metadata-singlenestedattribute branch October 25, 2024 19:37
jrhouston pushed a commit that referenced this pull request Jan 7, 2025
…SingleNestedAttribute` (#1516)

* initial refactor of metadata to be SingleNestedAttribute

* fix unknown value error by using ObjectUnknown instead of ObjectNull()

* update tests to align with SingleNested metadata attribute and not list
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants