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

Seemingly non-deterministic behaviour, query fails sometimes, works other times #1061

Closed
Brendonk13 opened this issue Jun 5, 2022 · 2 comments · Fixed by #972
Closed

Seemingly non-deterministic behaviour, query fails sometimes, works other times #1061

Brendonk13 opened this issue Jun 5, 2022 · 2 comments · Fixed by #972
Assignees
Labels
bug Something isn't working

Comments

@Brendonk13
Copy link

Brendonk13 commented Jun 5, 2022

Describe the bug
A clear and concise description of what the bug is.
Query initially gives (SQLSTATE HV000) error, then I'll remove a random WHERE clause, run that successfully, then I go back to run the original query and it works all of a sudden. Did not change my aws config or anything also, the queries ran in the image below were from one session and entered back to back.

Steampipe version (steampipe -v)
steampipe version 0.14.4

To reproduce
Steps to reproduce the behavior (please include relevant code and/or commands).
$ steampipe query

> select record.name, record.type, records, record.account_id
from
aws_route53_record as record,
jsonb_array_elements_text(record.records) as records
where record.zone_id = 'XXXXXXXXX'
and record.type in ('CNAME', 'A')

Error Message:
status code: 400, request id: 054c56d0-ef4f-4883-b9ac-86e9c16ce9c5 (SQLSTATE HV000)

First command initially fails, then works (bottom query) when I run it again after some other queries.
steampipe_err

Expected behavior
A clear and concise description of what you expected to happen.

The query to have worked both times

Additional context
Add any other context about the problem here.

Failing under single AWS account with 1 matching record.zone_id

logs:

  71   │ 2022-06-05 18:07:40.346 UTC [ERROR] steampipe-plugin-aws.plugin: [ERROR] 1654452460993: streamRows error chan select: InvalidInput:
  72   │ 2022-06-05 18:07:40.346 UTC [WARN]  steampipe-plugin-aws.plugin: [WARN]  1654452460993: Execute call failed - cancelling pending item in cachequery: 

  73   │ 2022-06-05 18:07:40.359 UTC [ERROR] steampipe-plugin-aws.plugin: [ERROR] 1654452460993: error chan select: InvalidInput:

OS: 5.12.19-1-MANJARO

@Brendonk13 Brendonk13 added the bug Something isn't working label Jun 5, 2022
@bigdatasourav bigdatasourav transferred this issue from turbot/steampipe Jun 6, 2022
@bigdatasourav bigdatasourav self-assigned this Jun 6, 2022
@bigdatasourav
Copy link
Contributor

@Brendonk13 Thank you for using Steampipe; apologies to see that you are facing this issue. We will look into it.

@bigdatasourav
Copy link
Contributor

Hey @Brendonk13, The API is not working properly due to which we are facing the optional column support issue, we have raised an issue in AWS GO SDK for that. We are also engaging AWS with a support request.

While we are waiting to get a response from the above support requests, after testing and working to provide an alternative solution, for the time being, we have this draft [PR] (#972) fix. Could you please try it out and let us know your feedback.

cbruno10 pushed a commit that referenced this issue Jun 8, 2022
…record` table to fix duplicate rows closes #967 closes #1061 (#972)
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
2 participants