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

Error: failed to load schemas: sql: expected 8 destination arguments in Scan, not 9 #2324

Closed
zfLQ2qx2 opened this issue Aug 10, 2022 · 5 comments
Assignees
Labels
bug Something isn't working

Comments

@zfLQ2qx2
Copy link

Describe the bug

This is a really interesting bug but I seem to be able to hit it consistently. Running steampipe locally in a container works perfectly. However when I try to use steampipe query to connect to a remote service then I'm getting killed after a couple seconds with "Error: failed to load schemas: sql: expected 8 destination arguments in Scan, not 9"

steampipe query --workspace-database postgres://steampipe:xxx@hhh:9193/steampipe

2022-08-10 13:40:38.172 UTC [TRACE] steampipe: no modfile exists in workspace folder - NOT creating pseudoresources and only loading resource files from top level folder
2022-08-10 13:40:38.174 UTC [TRACE] steampipe: parse complete after 1 decode passes
2022-08-10 13:40:38.175 UTC [TRACE] steampipe: parse complete after 1 decode passes
2022-08-10 13:40:38.175 UTC [TRACE] steampipe: telemetry.Init service 'steampipe', tracingEnabled: false, metricsEnabled: false
2022-08-10 13:40:38.175 UTC [TRACE] steampipe: metrics and tracing disabled' - returning
Welcome to Steampipe v0.15.4
For more information, type .help

2022-08-10 13:40:38.629 UTC [TRACE] steampipe: ensureSessionSearchPath
2022-08-10 13:40:38.629 UTC [TRACE] steampipe: updated the required search path to [omitted]
2022-08-10 13:40:38.629 UTC [TRACE] steampipe: session search path will be updated to [omitted]
2022-08-10 13:40:38.754 UTC [TRACE] steampipe: CreatePreparedStatements

Error: failed to load schemas: sql: expected 8 destination arguments in Scan, not 9
2022-08-10 13:40:42.262 UTC [TRACE] steampipe: cancel handler exiting
2022-08-10 13:40:42.262 UTC [TRACE] steampipe: DbClient.Close &{0 0xc0003047b0 0 {0 0} [] map[] 0 1 0xc00009ea80 false map[0xc0001007e0:map[0xc0001007e0:true]] map[] 1 1 0 0 0 0 0 0 0x108f180}

Both the local and remote steampipe are the same version. The service process runs on Linux and the query process runs on MacOS. Connecting to a remote service instead of local is the only other difference I see in the working and non-working configuration.

Steampipe version (steampipe -v)

v0.15.4

@zfLQ2qx2 zfLQ2qx2 added the bug Something isn't working label Aug 10, 2022
@zfLQ2qx2
Copy link
Author

I also tried with both client and server at v0.17.0-alpha.3 and I got the same error.

@e-gineer
Copy link
Contributor

Thanks for reporting this @zfLQ2qx2 ... I can confirm that I'm seeing the same problem testing against my cloud database:

~/src/steampipe.io $ steampipe query --workspace-database postgresql://e-gineer:redacted@e-gineer-scratch.usea1.db.steampipe.io:9193/redacted
Welcome to Steampipe v0.16.0-rc.9
For more information, type .help
> 
Error: failed to load schemas: sql: expected 8 destination arguments in Scan, not 9
~/src/steampipe.io $ 

It also fails in the shorthand version for cloud:

~/src/steampipe.io $ steampipe query --workspace-database e-gineer/scratch
Welcome to Steampipe v0.16.0-rc.9
For more information, type .help
> 
Error: failed to load schemas: sql: expected 8 destination arguments in Scan, not 9

@e-gineer
Copy link
Contributor

@zfLQ2qx2 Can you please try testing a build of the main branch with the commit above? I believe that fixes it 🤞

@zfLQ2qx2
Copy link
Author

@e-gineer Great! I was about to write that this seemed specific to the steampipe client, I downloaded a generic postgres client and I had no issues running queries. How long until your change makes a release?

@e-gineer
Copy link
Contributor

This fix will be in the next release, which 🤞 will be the week of Aug 22nd.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants