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

CDK: improve day_delta macro and MinMaxDatetime component #22400

Merged
merged 5 commits into from
Feb 8, 2023

Conversation

grubberr
Copy link
Contributor

@grubberr grubberr commented Feb 6, 2023

Signed-off-by: Sergey Chvalyuk grubberr@gmail.com

What

  • day_delta - add 2-nd optional parameter format
  • MinMaxDatetime - skip min or max datetime if result of evaluation is empty string

Signed-off-by: Sergey Chvalyuk <grubberr@gmail.com>
@grubberr grubberr requested a review from a team as a code owner February 6, 2023 09:10
@octavia-squidington-iii octavia-squidington-iii added the CDK Connector Development Kit label Feb 6, 2023
@grubberr grubberr changed the title adjust_datetime added CDK: Add jinja macro adjust_datetime Feb 6, 2023
@grubberr grubberr self-assigned this Feb 6, 2023
Copy link
Contributor

@brianjlai brianjlai left a comment

Choose a reason for hiding this comment

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

So the basic functionality is that when a provided datetime is earlier, then we set it to the boundary. When developing a connector, was there a limitation of the MinMaxDatetime component that prevented you from using instead of the macro? And if there was, maybe we could try to fold the functionality into the existing component instead of a new jinja macro

@grubberr
Copy link
Contributor Author

grubberr commented Feb 6, 2023

@brianjlai

oops it seems I have missed that mix/max feature of datetime param
let me re-implement

@grubberr grubberr changed the title CDK: Add jinja macro adjust_datetime CDK: improve day_delta macro and MinMaxDatetime component Feb 7, 2023
@grubberr
Copy link
Contributor Author

grubberr commented Feb 7, 2023

@brianjlai

I have removed that new macro adjust_datetime which I introduced.
But I have changed current macro day_delta and changed current component MinMaxDatetime
can you please look ?

Copy link
Contributor

@brianjlai brianjlai left a comment

Choose a reason for hiding this comment

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

changes look good! non-blocking change, but just a note to add some new tests for this case

Copy link
Contributor

@brianjlai brianjlai left a comment

Choose a reason for hiding this comment

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

thanks for adding the tests!

@grubberr grubberr merged commit 730225f into master Feb 8, 2023
@grubberr grubberr deleted the grubberr/cdk-declarative-macros-adjust_datetime branch February 8, 2023 20:52
danidelvalle pushed a commit to danidelvalle/airbyte that referenced this pull request Feb 9, 2023
…q#22400)

Signed-off-by: Sergey Chvalyuk <grubberr@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CDK Connector Development Kit
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants