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
🐛 Source Okta: Fix Infinite Loop in GroupMembers Stream #20833
🐛 Source Okta: Fix Infinite Loop in GroupMembers Stream #20833
Conversation
/test connector=connectors/source-okta
Build FailedTest summary info:
|
@michaelcabiareyes Hey, I'm one of the Airbyte maintainers and I'll be taking a look at your PR. Firstly thanks for your contribution :) The code logic seems sounds but the unit tests are failing, see the results in this PR. Could you please take a look at the unit test results and see if you can resolve. Reach out if you have any questions. |
Hi @koconder. Thank you for your response! Sure thing, let me take a look at the unit test and try to resolve this. |
@michaelcabiareyes do you have any updates? |
Hi @natalyjazzviolin . Yes, I'm currently close in finishing the resolution of the failed unit test and would be able to update 2-3 days from now. |
/test connector=connectors/source-okta |
@michaelcabiareyes ill need to run the unit tests using github actions. Its not able to be triggered by public. |
/test connector=connectors/source-okta
Build FailedTest summary info:
|
Oh, I see. Thank you @koconder! |
@michaelcabiareyes fyi test is still failing. You can follow the steps in the connector readme to use gradle commands to test locally the acceptance tests before you make your changes to verify 100% |
Understood, I think I have pushed the changes in the master branch instead of the okta-group-members-stream. I'll try again now. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I reset the params variable instead of inheriting the params from the parent class as the variables inside these are not required in the query [GroupMembers API]. Along with this, I've also removed the next_cursor in the unit testing.
/test connector=connectors/source-okta
Build FailedTest summary info:
|
Hi @koconder , I am trying to figure out how to resolve the failed acceptance tests. Can you help me point out where should I specifically resolve it and how? Because I see that it failed the users stream even though I've only modified the GroupMembers stream. |
@natalyjazzviolin can you give any guidance on the unit testing side of things? |
Hello @koconder. Can you run the unit test again? So I could check if the changes I've made is correct. Thank you! |
/test connector=connectors/source-okta
Build FailedTest summary info:
|
Still failed the testing. I am trying to replicate but I am not able to. Can you help me figure it out @natalyjazzviolin? Because I don't think that incremental tests should be done in GroupMembers stream as this resets per group iteration. |
I had this test summary when I tried disabling other streams except for Groups and GroupMembers. I suspect that due to the sample data being limited to one group only, it is not able to reproduce the same result I am having. I have also disabled the Incremental in GroupMembers as this is not applicable due to the need to reset the group_id for every stream slice. |
Hey @michaelcabiareyes, thanks for your work on this PR! My understanding is that it's possible a user may have only one group configured. Can you ensure that this case is accounted for? |
Hi @sh4sh. Thank you for your response! Yes, a user may belong to one or more groups. Can you confirm if the test account used for this connector has only one group and all users under the account belonged to that group? This is what I understood on the TestBasicRead.test_read[inputs0] as this checks if the records is the same with the contents of "integrationt_tests/expected_records.jsonl". |
I'm currently reviewing this, but there are some merge conflicts that need to be resolved before we continue. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the contribution @michaelcabiareyes
What
Resolves #20812
How
Reset the next_page_token for every group from stream slice and apply next_page_token for continuation of fetching.
Recommended reading order
source.py
🚨 User Impact 🚨
N/A
Pre-merge Checklist
Expand the relevant checklist and delete the others.
Updating a connector
Community member or Airbyter
airbyte_secret
./gradlew :airbyte-integrations:connectors:<name>:integrationTest
.README.md
bootstrap.md
. See description and examplesdocs/integrations/<source or destination>/<name>.md
including changelog. See changelog exampleAirbyter
If this is a community PR, the Airbyte engineer reviewing this PR is responsible for the below items.
/test connector=connectors/<name>
command is passing/publish
command described hereTests
Unit
Put your unit tests output here.
Integration
Put your integration tests output here.
Acceptance