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

Tdl 21520 skip donotprocess records #115

Merged
merged 8 commits into from Jan 9, 2023

Conversation

RushiT0122
Copy link
Contributor

@RushiT0122 RushiT0122 commented Dec 23, 2022

Description of change

If any visitor is set the Do Not Process flag then Pendo will stop collecting events from that visitor and will stop displaying guides to that visitor. In such scenario we should skip fetching visitor_history.

Manual QA steps

  • On cloned connection verified that donotprocess records are getting skipped.
  • Updated 'donotprocess' of few visitors in the test account to cover this scenario in the integration tests

Risks

Rollback steps

  • revert this branch

@RushiT0122 RushiT0122 requested review from dmosorast and luandy64 and removed request for dmosorast December 23, 2022 05:42
parent_last_updated = datetime.fromtimestamp(float(record['metadata']['auto'][self.replication_key]) / 1000.0, timezone.utc)
# If there is no last_update key then set 'last_updated=now()' and fetch the records from recent bookmark
parent_last_updated = datetime.fromtimestamp(float(
record['metadata']['auto'][self.replication_key]) / 1000.0, timezone.utc) if record['metadata']['auto'].get(self.replication_key) else now()

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

140 characters on one line which is too long. Can you please align it properly. 100 chars per line are preferred.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we know under what scenarios a record will not have a last_update key? Is it linked exclusively to visitors with do_not_process flags set?

@@ -22,7 +22,7 @@ jobs:
command: |
source /usr/local/share/virtualenvs/tap-pendo/bin/activate
# TODO: Adjust the pylint disables
pylint tap_pendo --disable 'broad-except,chained-comparison,empty-docstring,fixme,invalid-name,line-too-long,missing-class-docstring,missing-function-docstring,missing-module-docstring,no-else-raise,no-else-return,too-few-public-methods,too-many-arguments,too-many-branches,too-many-lines,too-many-locals,ungrouped-imports,wrong-spelling-in-comment,wrong-spelling-in-docstring,bad-whitespace,missing-class-docstring'
pylint tap_pendo --disable 'broad-except,chained-comparison,empty-docstring,fixme,invalid-name,line-too-long,missing-class-docstring,missing-function-docstring,missing-module-docstring,no-else-raise,no-else-return,too-few-public-methods,too-many-arguments,too-many-branches,too-many-lines,too-many-locals,ungrouped-imports,wrong-spelling-in-comment,wrong-spelling-in-docstring,bad-whitespace,missing-class-docstring,too-many-statements'

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

break into multiple lines for readability purpose.

tap_pendo/streams.py Outdated Show resolved Hide resolved
@kethan1122 kethan1122 merged commit 6b98ca4 into master Jan 9, 2023
@kethan1122 kethan1122 deleted the TDL-21520-skip-donotprocess-records branch January 9, 2023 14:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants