-
Notifications
You must be signed in to change notification settings - Fork 215
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
Sqitch - Snowflake : Sqitch deploy error #564
Comments
Well now that's not an expected error. Seems like something is failing to pass a message to the Error that gets thrown. Please apply this patch and run your command again, then paste the output here. --- a/lib/App/Sqitch/X.pm
+++ b/lib/App/Sqitch/X.pm
@@ -9,6 +9,8 @@ use Throwable 0.200009;
use Sub::Exporter -setup => [qw(hurl)];
use overload '""' => 'as_string';
+use Carp; BEGIN { $SIG{__DIE__} = \&Carp::confess }
+
# VERSION
has message => ( |
Appreciate your response here. Overcame the above after installing missing modules & updating the driver path We are facing the below error message now.
From the SnowFlake side, history of events:
Our Sqitch.conf entry below
If I am using snowsql to connect snowflake using the existing config file, it works perfect without any issues. Snowsql Config
1)Is there any other command which helps to identify connectivity apart from "deploy" command |
This is expected, but it's supposed to detect that error, then looks to see if the registry exists, which is what this query is doing: SELECT true FROM information_schema.tables WHERE TABLE_CATALOG = current_database() AND TABLE_SCHEMA = UPPER(?) AND TABLE_NAME = UPPER(?) As called by this code: sqitch/lib/App/Sqitch/Engine/snowflake.pm Lines 287 to 293 in a2c9205
But it's odd that there are no more queries after that. Up to this point, Sqitch is interacting with the database via ODBC, but to create the registry schema (and later deploy changes), it uses SnowSQL. That's what this error is about:
It's worth looking to see how Sqitch is calling SnowSQL; Try applying this patch and running it again to see exactly what arguments it passes to SnowSQL: --- a/lib/App/Sqitch.pm
+++ b/lib/App/Sqitch.pm
@@ -368,6 +368,7 @@ sub capture {
};
return capturex ( shift, $self->quote_shell(@_) )
if ISWIN && IPC::System::Simple->VERSION <= 1.25;
+ use Data::Dump; Data::Dump::ddx(\@_);
capturex @_;
}
|
Hi @RajanBabuS, have you had a chance to try this? TIA! |
where do we should apply this patch, I am also getting similar error, thought of trying this way out as well. Thanks |
To the file |
Hi, Thanks for your response. I have used below command from Visual studio's Bash terminal on windows 10 machine. env DIR=snowflake REGISTRY=sqitch ./build --build-arg sf_account= $ACCOUNT docker pull sqitch/sqitch Should I try to look for the file lib/App/Sqitch.pm in docker image or my local machine? Thanks, |
Oh, yeah, for the Docker image you would have to create a new one with the patch. Kind of a pain. |
Your screenshot truncates the output, so we can't see if it was part of the command. |
Hi David Wheeler/PoojaSahu, Sorry for the delayed response. I didn't worked on the docker image, rather i configured on a Redhat 7 node. Error messages were not user friendly. But took these steps to fix my issue. Ensure these steps if you are facing issue
*** you can get the installed perl modules in a list format and cross check against the link in pointer 1 @theory You can close my request or keep it opened until Pooja S Sahu's issue is getting resolved |
Hi David,
Any thoughts? |
What does this mean?
Do you have logging enabled in the |
@theory @PoojaSSahu , I am having same error, can you guide me with the same
|
@jay-brillio Make sure the Snowflake user you're connecting as has permission to create the registry schema and the changes table. |
@theory User is having OWNERSHIP & USAGE of the Warehouse or any other permission needs to be added, can you please suggest any troubleshooting steps for the same? |
@theory from snowflake side it's showing same error, why it's trying to create, below query is causing, the issue but it's not I have run it's from sqitch side looks like SELECT c.change_id |
It sounds like for some reason Snowflake is not letting the user create the table. That query failing is expected; Sqitch catches that error and then knows to try to create the table. |
so what's next I can try I am blocked on this since long? @theory |
See if you can create a schema and a table with that user via SnowSQL. Copy the command line arguments from this example. If it fails, you'll need to figure out why. Does the user not have the access you think it has? Are you connecting as the user you think you are? Does that user, in fact, need to be granted more permissions via the Snowflake console? HTH. |
Might #853 fix this issue? |
Hi ,
We are trying to use Sqitch for Snowflake. Followed the steps provided in the given reference implementation but not able to perform sqitch deploy .
Reference Link:
Where we are now?
4)installed Snowflake Snowsql and verified the Snowflake connectivity separately : no issue here
6)able to perform sqitch init
7)able to perform sqitch add : files are getting generated automatically
8)when I perform sqitch deploy, got the error message
9)I am using password stored in the ~/.snowsql/config file
versions:
There were no straight forward documentations(for manual installation + configuration) available for us to have a decent installation and configurations. I am being very skeptical to propose Sqitch with the level of configuration steps involved.
Could you please help here for any possible solutions
The text was updated successfully, but these errors were encountered: