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

runtime error #796

Open
2 tasks done
megabyte-bot opened this issue Feb 12, 2025 · 5 comments
Open
2 tasks done

runtime error #796

megabyte-bot opened this issue Feb 12, 2025 · 5 comments

Comments

@megabyte-bot
Copy link

Confirmation

  • My issue isn't already found on the issue tracker.
  • I have replicated my issue using the latest version of the library and it is still present.

cf-terraforming version

v0.23.3

Expected outcome

just like #792

Actual outcome

cf-terraforming import --resource-type "cloudflare_record" --email "[email protected]" --key "mykey" --zone "myzone"

panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x2 addr=0x28 pc=0x102ab7d84]

goroutine 1 [running]:
github.com/hashicorp/go-version.(*Version).String(0x0)
	/home/runner/go/pkg/mod/github.com/hashicorp/[email protected]/version.go:386 +0x34
github.com/cloudflare/cf-terraforming/internal/app/cf-terraforming/cmd.init.runImport.func3(0x1036fcd20, {0x102ce6d38?, 0x4?, 0x102ce6c6c?})
	/home/runner/work/cf-terraforming/cf-terraforming/internal/app/cf-terraforming/cmd/import.go:129 +0x3bc
github.com/spf13/cobra.(*Command).execute(0x1036fcd20, {0x1400014da00, 0x8, 0x8})
	/home/runner/go/pkg/mod/github.com/spf13/[email protected]/command.go:989 +0x81c
github.com/spf13/cobra.(*Command).ExecuteC(0x1036fd000)
	/home/runner/go/pkg/mod/github.com/spf13/[email protected]/command.go:1117 +0x344
github.com/spf13/cobra.(*Command).Execute(...)
	/home/runner/go/pkg/mod/github.com/spf13/[email protected]/command.go:1041
github.com/cloudflare/cf-terraforming/internal/app/cf-terraforming/cmd.Execute()
	/home/runner/work/cf-terraforming/cf-terraforming/internal/app/cf-terraforming/cmd/root.go:30 +0x24
main.main()
	/home/runner/work/cf-terraforming/cf-terraforming/cmd/cf-terraforming/main.go:8 +0x1c

Steps to reproduce

download and run

References

No response

@megabyte-bot
Copy link
Author

this still works https://github.com/cloudflare/cf-terraforming/releases/tag/v0.22.0, later releases don't

@matti
Copy link

matti commented Feb 12, 2025

okay so I think it's because I'm using tofu like in #624

@torbendevrocks
Copy link

The same happened here yesterday (brew on macOS), without any updates to the source. Could this be a Cloudflare issue?

@jhugelenpadin-iabbb
Copy link

yeah, it's failing for me too. same error.

@pheerlessliter
Copy link

FWIW, I had to (re)install the latest go version. I'm on a mac, so doing a brew install go fixed that issue, and if you do a brew info cf-terraforming, it should tell you if your go version is good with a little green checkmark. I ran into another where the new version 5.0 of the provider has a mismatch for doing maps to things like user accounts, where it is misformatted for the tool. Going back to the previous 4.x version fixed that, but that's just a temp fix until 5.x is more usable with the tool.

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

No branches or pull requests

5 participants