Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package terragrunt for openSUSE:Factory 
checked in at 2025-10-08 18:14:57
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/terragrunt (Old)
 and      /work/SRC/openSUSE:Factory/.terragrunt.new.11973 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "terragrunt"

Wed Oct  8 18:14:57 2025 rev:259 rq:1309738 version:0.89.2

Changes:
--------
--- /work/SRC/openSUSE:Factory/terragrunt/terragrunt.changes    2025-10-07 
18:29:22.720017668 +0200
+++ /work/SRC/openSUSE:Factory/.terragrunt.new.11973/terragrunt.changes 
2025-10-08 18:19:25.046735237 +0200
@@ -1,0 +2,14 @@
+Wed Oct 08 05:24:31 UTC 2025 - Johannes Kastl 
<[email protected]>
+
+- Update to version 0.89.2:
+  * fix: Fixing external dependency resolution (#4926)
+  * fix: Fixing Terralith to Terragrunt integration test (#4909)
+
+-------------------------------------------------------------------
+Wed Oct 08 05:10:58 UTC 2025 - Johannes Kastl 
<[email protected]>
+
+- Update to version 0.89.1:
+  * fix: Fixed bug where discovery warned that outputs were mocked.
+    (#4923)
+
+-------------------------------------------------------------------

Old:
----
  terragrunt-0.89.0.obscpio

New:
----
  terragrunt-0.89.2.obscpio

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ terragrunt.spec ++++++
--- /var/tmp/diff_new_pack.eJHhNz/_old  2025-10-08 18:19:27.882854256 +0200
+++ /var/tmp/diff_new_pack.eJHhNz/_new  2025-10-08 18:19:27.886854424 +0200
@@ -17,7 +17,7 @@
 
 
 Name:           terragrunt
-Version:        0.89.0
+Version:        0.89.2
 Release:        0
 Summary:        Thin wrapper for Terraform for working with multiple Terraform 
modules
 License:        MIT

++++++ _service ++++++
--- /var/tmp/diff_new_pack.eJHhNz/_old  2025-10-08 18:19:27.966857781 +0200
+++ /var/tmp/diff_new_pack.eJHhNz/_new  2025-10-08 18:19:27.974858117 +0200
@@ -3,7 +3,7 @@
     <param name="url">https://github.com/gruntwork-io/terragrunt</param>
     <param name="scm">git</param>
     <param name="exclude">.git</param>
-    <param name="revision">v0.89.0</param>
+    <param name="revision">v0.89.2</param>
     <param name="versionformat">@PARENT_TAG@</param>
     <param name="versionrewrite-pattern">v(.*)</param>
     <param name="changesgenerate">enable</param>

++++++ _servicedata ++++++
--- /var/tmp/diff_new_pack.eJHhNz/_old  2025-10-08 18:19:28.002859292 +0200
+++ /var/tmp/diff_new_pack.eJHhNz/_new  2025-10-08 18:19:28.014859795 +0200
@@ -1,6 +1,6 @@
 <servicedata>
 <service name="tar_scm">
                 <param 
name="url">https://github.com/gruntwork-io/terragrunt</param>
-              <param 
name="changesrevision">434625845bcaa7633af0dae18ccf9efb24982ac3</param></service></servicedata>
+              <param 
name="changesrevision">255ead175b7a82d8154a5503eaead684feeda30f</param></service></servicedata>
 (No newline at EOF)
 

++++++ terragrunt-0.89.0.obscpio -> terragrunt-0.89.2.obscpio ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/terragrunt-0.89.0/config/config.go 
new/terragrunt-0.89.2/config/config.go
--- old/terragrunt-0.89.0/config/config.go      2025-10-06 17:03:34.000000000 
+0200
+++ new/terragrunt-0.89.2/config/config.go      2025-10-07 22:48:59.000000000 
+0200
@@ -1274,7 +1274,12 @@
 //     - dependency
 //  5. Merge the included config with the parsed config. Note that all the 
config data is mergeable except for `locals`
 //     blocks, which are only scoped to be available within the defining 
config.
-func ParseConfig(ctx *ParsingContext, l log.Logger, file *hclparse.File, 
includeFromChild *IncludeConfig) (*TerragruntConfig, error) {
+func ParseConfig(
+       ctx *ParsingContext,
+       l log.Logger,
+       file *hclparse.File,
+       includeFromChild *IncludeConfig,
+) (*TerragruntConfig, error) {
        errs := &errors.MultiError{}
 
        if err := detectDeprecatedConfigurations(ctx, l, file); err != nil {
@@ -1309,7 +1314,7 @@
                ctx = ctx.WithLocals(baseBlocks.Locals)
        }
 
-       if ctx.DecodedDependencies == nil {
+       if !ctx.SkipOutputsResolution && ctx.DecodedDependencies == nil {
                // Decode just the `dependency` blocks, retrieving the outputs 
from the target terragrunt config in the
                // process.
                retrievedOutputs, err := decodeAndRetrieveOutputs(ctx, l, file)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/terragrunt-0.89.0/config/parsing_context.go 
new/terragrunt-0.89.2/config/parsing_context.go
--- old/terragrunt-0.89.0/config/parsing_context.go     2025-10-06 
17:03:34.000000000 +0200
+++ new/terragrunt-0.89.2/config/parsing_context.go     2025-10-07 
22:48:59.000000000 +0200
@@ -48,8 +48,11 @@
        // expected to be available.
        PartialParseDecodeList []PartialDecodeSectionType
 
-       // `ParserOptions` is used to configure hcl Parser.
+       // ParserOptions is used to configure hcl Parser.
        ParserOptions []hclparse.Option
+
+       // SkipOutputsResolution is used to optionally opt-out of resolving 
outputs.
+       SkipOutputsResolution bool
 }
 
 func NewParsingContext(ctx context.Context, l log.Logger, opts 
*options.TerragruntOptions) *ParsingContext {
@@ -97,3 +100,8 @@
        ctx.ParserOptions = parserOptions
        return &ctx
 }
+
+func (ctx ParsingContext) WithSkipOutputsResolution() *ParsingContext {
+       ctx.SkipOutputsResolution = true
+       return &ctx
+}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/terragrunt-0.89.0/internal/discovery/discovery.go 
new/terragrunt-0.89.2/internal/discovery/discovery.go
--- old/terragrunt-0.89.0/internal/discovery/discovery.go       2025-10-06 
17:03:34.000000000 +0200
+++ new/terragrunt-0.89.2/internal/discovery/discovery.go       2025-10-07 
22:48:59.000000000 +0200
@@ -39,6 +39,14 @@
        // skipOutputDiagnostics is a string used to identify diagnostics that 
reference outputs.
        skipOutputDiagnostics = "output"
 
+       // skipNoVariableNamedDependencyDiagnostic is a string used to identify 
diagnostics
+       // that reference the missing dependency variable.
+       //
+       // This is fine during discovery, as we don't need dependency outputs 
resolved.
+       //
+       // This is a hack, and there should be a better way of handling this...
+       skipNoVariableNamedDependencyDiagnostic = `There is no variable named 
"dependency".`
+
        // Default number of concurrent workers for discovery operations
        defaultDiscoveryWorkers = 4
 
@@ -440,7 +448,7 @@
                config.DependencyBlock,
                config.FeatureFlagsBlock,
                config.ExcludeBlock,
-       )
+       ).WithSkipOutputsResolution()
 
        // Apply custom parser options if provided via discovery
        if len(parserOptions) > 0 {
@@ -454,10 +462,11 @@
                        filteredDiags := hcl.Diagnostics{}
 
                        for _, hclDiag := range hclDiags {
-                               containsOutputRef := 
strings.Contains(strings.ToLower(hclDiag.Summary), skipOutputDiagnostics) ||
-                                       
strings.Contains(strings.ToLower(hclDiag.Detail), skipOutputDiagnostics)
+                               filterOut := 
strings.Contains(strings.ToLower(hclDiag.Summary), skipOutputDiagnostics) ||
+                                       
strings.Contains(strings.ToLower(hclDiag.Detail), skipOutputDiagnostics) ||
+                                       strings.Contains(hclDiag.Detail, 
skipNoVariableNamedDependencyDiagnostic)
 
-                               if !containsOutputRef {
+                               if !filterOut {
                                        filteredDiags = append(filteredDiags, 
hclDiag)
                                }
                        }
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/terragrunt-0.89.0/test/integration_docs_aws_tofu_test.go 
new/terragrunt-0.89.2/test/integration_docs_aws_tofu_test.go
--- old/terragrunt-0.89.0/test/integration_docs_aws_tofu_test.go        
2025-10-06 17:03:34.000000000 +0200
+++ new/terragrunt-0.89.2/test/integration_docs_aws_tofu_test.go        
2025-10-07 22:48:59.000000000 +0200
@@ -799,6 +799,39 @@
 
                fixtureStepPath := filepath.Join(fixturePath, "walkthrough", 
"step-6-breaking-the-terralith-further")
 
+               // Ensure root.hcl uses the correct stateBucketName
+               rootHclContent := fmt.Sprintf(`remote_state {
+  backend = "s3"
+  generate = {
+    path      = "backend.tf"
+    if_exists = "overwrite"
+  }
+  config = {
+    bucket       = "%s"
+    key          = "${path_relative_to_include()}/tofu.tfstate"
+    region       = "%s"
+    encrypt      = true
+    use_lockfile = true
+  }
+}
+
+generate "providers" {
+  path      = "providers.tf"
+  if_exists = "overwrite_terragrunt"
+  contents  = <<EOF
+provider "aws" {
+  region = "%s"
+}
+EOF
+}
+`, stateBucketName, region, region)
+
+               require.NoError(t, os.WriteFile(
+                       filepath.Join(liveDir, "root.hcl"),
+                       []byte(rootHclContent),
+                       0644,
+               ))
+
                // Create directories for each component in both environments
                components := []string{"s3", "ddb", "iam", "lambda"}
                environments := []string{"dev", "prod"}
@@ -826,7 +859,7 @@
                                        nameToUse = name + "-dev"
                                }
 
-                               content := 
strings.ReplaceAll(string(sourceContent), "best-cat-2025-07-31-01", name)
+                               content := 
strings.ReplaceAll(string(sourceContent), "best-cat-2025-09-24-2359", name)
                                content = strings.ReplaceAll(content, 
name+"-dev", nameToUse)
                                content = strings.ReplaceAll(content, name, 
nameToUse)
 
@@ -852,7 +885,7 @@
                        }
                }
 
-               require.NoError(t, os.WriteFile(filepath.Join(liveDir, "dev", 
"s3", "terragrunt.hcl"), fmt.Appendf(nil, `include "root" {
+               devS3Content := fmt.Sprintf(`include "root" {
   path = find_in_parent_folders("root.hcl")
 }
 
@@ -864,9 +897,10 @@
   name = "%s-dev"
   force_destroy = true
 }
-`, name), 0644))
+`, name)
+               require.NoError(t, os.WriteFile(filepath.Join(liveDir, "dev", 
"s3", "terragrunt.hcl"), []byte(devS3Content), 0644))
 
-               require.NoError(t, os.WriteFile(filepath.Join(liveDir, "prod", 
"s3", "terragrunt.hcl"), fmt.Appendf(nil, `include "root" {
+               prodS3Content := fmt.Sprintf(`include "root" {
   path = find_in_parent_folders("root.hcl")
 }
 
@@ -878,7 +912,8 @@
   name = "%s"
   force_destroy = true
 }
-`, name), 0644))
+`, name)
+               require.NoError(t, os.WriteFile(filepath.Join(liveDir, "prod", 
"s3", "terragrunt.hcl"), []byte(prodS3Content), 0644))
 
                // Remove the old terragrunt.hcl and moved.tf files from the 
environment root directories
                for _, env := range environments {
@@ -956,6 +991,39 @@
                // Path to step 7 fixtures
                fixtureStepPath := filepath.Join(fixturePath, "walkthrough", 
"step-7-taking-advantage-of-terragrunt-stacks")
 
+               // Ensure root.hcl uses the correct stateBucketName
+               rootHclContent := fmt.Sprintf(`remote_state {
+  backend = "s3"
+  generate = {
+    path      = "backend.tf"
+    if_exists = "overwrite"
+  }
+  config = {
+    bucket       = "%s"
+    key          = "${path_relative_to_include()}/tofu.tfstate"
+    region       = "%s"
+    encrypt      = true
+    use_lockfile = true
+  }
+}
+
+generate "providers" {
+  path      = "providers.tf"
+  if_exists = "overwrite_terragrunt"
+  contents  = <<EOF
+provider "aws" {
+  region = "%s"
+}
+EOF
+}
+`, stateBucketName, region, region)
+
+               require.NoError(t, os.WriteFile(
+                       filepath.Join(liveDir, "root.hcl"),
+                       []byte(rootHclContent),
+                       0644,
+               ))
+
                // Create the catalog/units directory structure for unit 
definitions
                catalogUnitsDir := filepath.Join(catalogDir, "units")
                components := []string{"ddb", "iam", "lambda", "s3"}
@@ -992,7 +1060,7 @@
                require.NoError(t, err)
 
                // Replace the hardcoded name with our test-specific name
-               customizedDevStackContent := 
strings.ReplaceAll(string(devStackContent), "best-cat-2025-07-31-01-dev", 
name+"-dev")
+               customizedDevStackContent := 
strings.ReplaceAll(string(devStackContent), "best-cat-2025-09-24-2359-dev", 
name+"-dev")
                customizedDevStackContent = 
strings.ReplaceAll(customizedDevStackContent, "us-east-1", region)
 
                require.NoError(t, os.WriteFile(
@@ -1007,7 +1075,7 @@
                require.NoError(t, err)
 
                // Replace the hardcoded name with our test-specific name
-               customizedProdStackContent := 
strings.ReplaceAll(string(prodStackContent), "best-cat-2025-07-31-01", name)
+               customizedProdStackContent := 
strings.ReplaceAll(string(prodStackContent), "best-cat-2025-09-24-2359", name)
                customizedProdStackContent = 
strings.ReplaceAll(customizedProdStackContent, "us-east-1", region)
 
                require.NoError(t, os.WriteFile(
@@ -1094,6 +1162,39 @@
                // Path to step 8 fixtures
                fixtureStepPath := filepath.Join(fixturePath, "walkthrough", 
"step-8-refactoring-state-with-terragrunt-stacks")
 
+               // Ensure root.hcl uses the correct stateBucketName
+               rootHclContent := fmt.Sprintf(`remote_state {
+  backend = "s3"
+  generate = {
+    path      = "backend.tf"
+    if_exists = "overwrite"
+  }
+  config = {
+    bucket       = "%s"
+    key          = "${path_relative_to_include()}/tofu.tfstate"
+    region       = "%s"
+    encrypt      = true
+    use_lockfile = true
+  }
+}
+
+generate "providers" {
+  path      = "providers.tf"
+  if_exists = "overwrite_terragrunt"
+  contents  = <<EOF
+provider "aws" {
+  region = "%s"
+}
+EOF
+}
+`, stateBucketName, region, region)
+
+               require.NoError(t, os.WriteFile(
+                       filepath.Join(liveDir, "root.hcl"),
+                       []byte(rootHclContent),
+                       0644,
+               ))
+
                // First, generate the current stack to ensure everything is 
present
                helpers.ExecWithMiseAndTestLogger(t, liveDir, "terragrunt", 
"stack", "generate")
 
@@ -1104,7 +1205,7 @@
                require.NoError(t, err)
 
                // Replace the hardcoded name with our test-specific name
-               customizedDevStackContent := 
strings.ReplaceAll(string(devStackContent), "best-cat-2025-07-31-01-dev", 
name+"-dev")
+               customizedDevStackContent := 
strings.ReplaceAll(string(devStackContent), "best-cat-2025-09-24-2359-dev", 
name+"-dev")
                customizedDevStackContent = 
strings.ReplaceAll(customizedDevStackContent, "us-east-1", region)
 
                require.NoError(t, os.WriteFile(
@@ -1119,7 +1220,7 @@
                require.NoError(t, err)
 
                // Replace the hardcoded name with our test-specific name
-               customizedProdStackContent := 
strings.ReplaceAll(string(prodStackContent), "best-cat-2025-07-31-01", name)
+               customizedProdStackContent := 
strings.ReplaceAll(string(prodStackContent), "best-cat-2025-09-24-2359", name)
                customizedProdStackContent = 
strings.ReplaceAll(customizedProdStackContent, "us-east-1", region)
 
                require.NoError(t, os.WriteFile(
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/terragrunt-0.89.0/test/integration_test.go 
new/terragrunt-0.89.2/test/integration_test.go
--- old/terragrunt-0.89.0/test/integration_test.go      2025-10-06 
17:03:34.000000000 +0200
+++ new/terragrunt-0.89.2/test/integration_test.go      2025-10-07 
22:48:59.000000000 +0200
@@ -4252,3 +4252,167 @@
        _, _, err := helpers.RunTerragruntCommandWithOutput(t, "terragrunt 
workspace list --non-interactive --working-dir "+rootPath)
        require.Error(t, err, "expected error when invoking unknown top-level 
command without 'run'")
 }
+
+func TestDiscoveryDoesntResolveOutputs(t *testing.T) {
+       t.Parallel()
+
+       tmpDir := t.TempDir()
+
+       depDir := filepath.Join(tmpDir, "dep")
+       err := os.MkdirAll(depDir, 0755)
+       require.NoError(t, err)
+
+       mainDir := filepath.Join(tmpDir, "main")
+       err = os.MkdirAll(mainDir, 0755)
+       require.NoError(t, err)
+
+       depConfig := `
+terraform {
+  source = "."
+}
+`
+       err = os.WriteFile(filepath.Join(depDir, "terragrunt.hcl"), 
[]byte(depConfig), 0644)
+       require.NoError(t, err)
+
+       depTerraform := `
+output "value" {
+  value = "hello from dependency"
+}
+`
+       err = os.WriteFile(filepath.Join(depDir, "main.tf"), 
[]byte(depTerraform), 0644)
+       require.NoError(t, err)
+
+       mainConfig := `
+terraform {
+  source = "."
+}
+
+dependency "dep" {
+  config_path = "../dep"
+
+  mock_outputs = {
+    value = "mock value"
+  }
+}
+
+inputs = {
+  dep_value = dependency.dep.outputs.value
+}
+`
+       err = os.WriteFile(filepath.Join(mainDir, "terragrunt.hcl"), 
[]byte(mainConfig), 0644)
+       require.NoError(t, err)
+
+       mainTerraform := `
+variable "dep_value" {
+  type = string
+}
+
+output "result" {
+  value = var.dep_value
+}
+`
+       err = os.WriteFile(filepath.Join(mainDir, "main.tf"), 
[]byte(mainTerraform), 0644)
+       require.NoError(t, err)
+
+       _, _, err = helpers.RunTerragruntCommandWithOutput(t, "terragrunt apply 
-auto-approve --non-interactive --working-dir "+depDir)
+       require.NoError(t, err)
+
+       stdout, _, err := helpers.RunTerragruntCommandWithOutput(t, "terragrunt 
output -no-color -json --non-interactive --working-dir "+depDir)
+       require.NoError(t, err)
+       assert.Contains(t, stdout, "hello from dependency")
+
+       stdout, stderr, err := helpers.RunTerragruntCommandWithOutput(t, 
"terragrunt run --all apply --non-interactive --working-dir "+tmpDir)
+       require.NoError(t, err)
+
+       assert.NotEmpty(t, stdout)
+       assert.NotEmpty(t, stderr)
+
+       assert.NotContains(t, stderr, "that has no outputs, but mock outputs 
provided and returning those in dependency output")
+
+       stdout, _, err = helpers.RunTerragruntCommandWithOutput(t, "terragrunt 
output -no-color -json --non-interactive --working-dir "+mainDir)
+       require.NoError(t, err)
+
+       assert.Contains(t, stdout, "hello from dependency")
+}
+
+func TestExternalDependenciesAreResolved(t *testing.T) {
+       t.Parallel()
+
+       tmpDir := t.TempDir()
+
+       depDir := filepath.Join(tmpDir, "dep")
+       err := os.MkdirAll(depDir, 0755)
+       require.NoError(t, err)
+
+       mainDir := filepath.Join(tmpDir, "main")
+       err = os.MkdirAll(mainDir, 0755)
+       require.NoError(t, err)
+
+       depConfig := `
+terraform {
+  source = "."
+}
+`
+       err = os.WriteFile(filepath.Join(depDir, "terragrunt.hcl"), 
[]byte(depConfig), 0644)
+       require.NoError(t, err)
+
+       depTerraform := `
+output "value" {
+  value = "hello from dependency"
+}
+`
+       err = os.WriteFile(filepath.Join(depDir, "main.tf"), 
[]byte(depTerraform), 0644)
+       require.NoError(t, err)
+
+       mainConfig := `
+terraform {
+  source = "."
+}
+
+dependency "dep" {
+  config_path = "../dep"
+
+  mock_outputs = {
+    value = "mock value"
+  }
+}
+
+inputs = {
+  dep_value = dependency.dep.outputs.value
+}
+`
+       err = os.WriteFile(filepath.Join(mainDir, "terragrunt.hcl"), 
[]byte(mainConfig), 0644)
+       require.NoError(t, err)
+
+       mainTerraform := `
+variable "dep_value" {
+  type = string
+}
+
+output "result" {
+  value = var.dep_value
+}
+`
+       err = os.WriteFile(filepath.Join(mainDir, "main.tf"), 
[]byte(mainTerraform), 0644)
+       require.NoError(t, err)
+
+       stdout, stderr, err := helpers.RunTerragruntCommandWithOutput(
+               t,
+               "terragrunt run --all plan --non-interactive 
--queue-exclude-external --working-dir "+mainDir,
+       )
+       require.NoError(t, err)
+
+       assert.NotEmpty(t, stdout)
+       assert.NotEmpty(t, stderr)
+
+       assert.Contains(
+               t,
+               stderr,
+               "that has no outputs, but mock outputs provided and returning 
those in dependency output",
+       )
+       assert.NotContains(
+               t,
+               stderr,
+               `There is no variable named "dependency".`,
+       )
+}

++++++ terragrunt.obsinfo ++++++
--- /var/tmp/diff_new_pack.eJHhNz/_old  2025-10-08 18:19:41.031406041 +0200
+++ /var/tmp/diff_new_pack.eJHhNz/_new  2025-10-08 18:19:41.083408224 +0200
@@ -1,5 +1,5 @@
 name: terragrunt
-version: 0.89.0
-mtime: 1759763014
-commit: 434625845bcaa7633af0dae18ccf9efb24982ac3
+version: 0.89.2
+mtime: 1759870139
+commit: 255ead175b7a82d8154a5503eaead684feeda30f
 

++++++ vendor.tar.gz ++++++
/work/SRC/openSUSE:Factory/terragrunt/vendor.tar.gz 
/work/SRC/openSUSE:Factory/.terragrunt.new.11973/vendor.tar.gz differ: char 13, 
line 1

Reply via email to