Skip to content

fix(config-version): Updated upload method and ConfigurationSource Enum in the configuration version #107

Merged
isivaselvan merged 2 commits intonext-0.1.3from
bugfix/config-version-upload
Mar 12, 2026
Merged

fix(config-version): Updated upload method and ConfigurationSource Enum in the configuration version #107
isivaselvan merged 2 commits intonext-0.1.3from
bugfix/config-version-upload

Conversation

@isivaselvan
Copy link
Copy Markdown
Collaborator

@isivaselvan isivaselvan commented Mar 4, 2026

Description

  • Removed the go-slug third-party package from the configuration version upload path, replacing it with Python's stdlib tarfile.
  • Fixed a missing ConfigurationSource enum value that caused a Pydantic ValidationError when listing CVs with source "terraform+cloud".

Changes

utils.py

  • Removed the try/except import guard for slug
  • pack_contents(path) now uses tarfile with os.walk to build the archive into an io.BytesIO buffer
  • Raises ValueError (instead of ImportError) when the path is not a valid existing directory

models/configuration_version.py

  • Added TERRAFORM_CLOUD = "terraform+cloud" to ConfigurationSource
  • Prevents a Pydantic ValidationError when deserialising configuration versions whose source is "terraform+cloud"

Examples and Unit tests

  • Updated the examples and unit tests of configuration version

Testing plan

External links

Output from tests

Including output from tests may require access to a TFE instance. Ignore this section if you have no environment to test against.

Rollback Plan

Changes to Security Controls

PCI review checklist

  • I have documented a clear reason for, and description of, the change I am making.

  • If applicable, I've documented a plan to revert these changes if they require more than reverting the pull request.

  • If applicable, I've documented the impact of any changes to security controls.

    Examples of changes to security controls include using new access control methods, adding or removing logging pipelines, etc.

If you have any questions, please contact your direct supervisor, GRC (#team-grc), or the PCI working group (#proj-pci-reboot). You can also find more information at PCI Compliance.

@isivaselvan isivaselvan requested a review from a team as a code owner March 4, 2026 16:43
@isivaselvan isivaselvan merged commit 2d2cbd4 into next-0.1.3 Mar 12, 2026
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant