Hi guys, There was a problem with the `terraform-s...
# python
g
Hi guys, There was a problem with the
terraform-snowflake-provider
and they fixed it and updated to
2.7.0
pulumi-snowflake
updated from
2.5.0
->
2.6.0
I am trying to update my
pulumi-snowflake
version to the latest one which is
2.6.0
. Inside that update there was a PR that was merged to update the
terraform-snowflake-provider
to
2.7.0
my
requirements.txt
points to
pulumi-snowflake==2.6.0
I cleared the pip cache, removed the plugin from pulumi but when I do pulumi up, it forces it to install
2.5.0
: would anyone know why?
e
If there's old resources in the state file that are using 2.5.0 then it will be downloaded incase its needed to issue Deletes against. Might end up not being used, but we can't tell when pre-caching at startup.
g
Hi @echoing-dinner-19531 sorry what do you mean? do I need to delete something ? purge something? or purge my stack?
f
in other words, if you last ran an
up
with 2.5.0 and you have a resource in your stack (and thus state), then you upgrade to 2.7.0, the program will need both 2.5.0 and 2.7.0 downloaded and present. you may have simultaneously updated the provider to 2.7.0 as well as deleted resources created by 2.5.0. the CLI can't tell, so it precaches 2.5.0 just in case those affected resources need to be deleted. ideal outcome is you should not have to do anything here aside from have a successful
up
. does the
preview
show a concerning diff?
g
so if it just downloads it, its ok, but then I still get the issue that the fix was supposed to resolve. I updated
pulumi-snowflake
to
2.6.0
which should be pointing to the latest
terraform-snowflake-provider
here you can see the snowflake provider is
2.5.0
but we can see the terraform snowflake provider is at 2.7.0
f
ah, I'm gonna let @echoing-dinner-19531 take that one when they have a minute πŸ˜„
g
also FYI : thats the output of
pip freeze | grep pulumi
:
Copy code
pulumi==3.197.0
pulumi_aws==7.6.0
pulumi_command==1.1.0
pulumi_snowflake==2.6.0
e
You've covered over the plan but I'm assuming that's a create or update?
Can check with debug logs to confirm that the RegisterResource call for that task is setting the 2.6.0 version. Run with "--logtostderr -v10" and look for a RegsiterResource received line and see what provider its pointing to
g
its a
pulumi up
for a create, just did the command,
RegsiterResource
not found in the logs
s
Hello, I am going to reply to this thread here. @gray-art-92380 asked me via DM if we're sure this provider includes the lates updates to upstream. It does: β€’ latest release upstream: https://github.com/snowflakedb/terraform-provider-snowflake/releases/tag/v2.7.0 (note the git hash) β€’
upstream
is updated to point to that hash: https://github.com/pulumi/pulumi-snowflake/pull/976/files#diff-1581e27de87bffae0bd4d745cd7964e68528d7a83e2e4c259a782d275df6f558 β€’ You wouldn't see this in the provider's go.mod because it's there via
replace
.
g
exactly, thats what I see in the code, its using upstream
s
Reading this thread, I don't understand the problem entirely. It sounds like you're using both versions somehow?
g
when doing pulumi up, it downloads the
2.5.0
plugin
s
You should definitely be seeing a
RegisterResource
call in your logs what happens if you run
pulumi install
? and are there any explicit providers with pinned versions in your state?
(I'm presuming you did all of the Python pip install incantations already).
g
so pulumi install seemed to have resolved the issue :
s
huzzah! πŸŽ‰
g
thats why :
so it was using the cache, but pulumi install flushes the registry?
s
That's not quite why. You did clear out the plugin cache, unless you had something stuck in your PATH.
I'm presuming that you didn't run
pip install
at the right time, so your Python SDK was still the old one.
g
I did πŸ˜“
but that resolved it… so thanx @shy-arm-32391 and all of you. I will keep this in mind!
s
And "the registry" has nothing to do with it. I'm just cautioning you to take the AI explanation with a grain of salt. I'm glad we got it straightened out - we should definitely make sure that upgrades don't turn into confusion or accidentally pointing to the wrong plugins.
πŸ™Œ 1
e
Yeh that AI explanation sounds like rubbish, the cache is keyed by version
πŸ’― 1
g
ya sorry just trying to understand thats why I tried with AI to understand why @shy-arm-32391 solution worked. I did
pip install
here also did the logtostrderr too here