Skip to content

dataset: change history param into retention#621

Open
nonibansal wants to merge 1 commit intomainfrom
nitin/history
Open

dataset: change history param into retention#621
nonibansal wants to merge 1 commit intomainfrom
nitin/history

Conversation

@nonibansal
Copy link
Contributor

@nonibansal nonibansal commented Dec 31, 2024

Important

Rename history parameter to retention in @dataset decorator and update related code, protobuf, and documentation.

  • Behavior:
    • Change @dataset(history="4m") to @dataset(retention="4m") in operators_ref.py, troubleshooting-guide.py, and test_dataset.py.
    • Update dataset function in datasets.py to use retention instead of history.
  • Protobuf:
    • Add disable_historical attribute to CoreDataset in dataset_pb2.py and dataset_pb2.pyi.
  • Changelog:
    • Update CHANGELOG.md to document the change from history to retention.
  • Versioning:
    • Increment version in pyproject.toml to 1.6.0.

This description was created by Ellipsis for d9a482f. It will automatically update as commits are pushed.

Copy link

@ellipsis-dev ellipsis-dev bot left a comment

Choose a reason for hiding this comment

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

👍 Looks good to me! Reviewed everything up to 96d0a9e in 41 seconds

More details
  • Looked at 478 lines of code in 13 files
  • Skipped 0 files when reviewing.
  • Skipped posting 1 drafted comments based on config settings.
1. fennel/internal_lib/to_proto/to_proto.py:221
  • Draft comment:
    The history parameter is still being used here, which seems incorrect after the change to retention. Consider removing or replacing it with retention.
  • Reason this comment was not posted:
    Comment was on unchanged code.

Workflow ID: wflow_v2l71u3pGYOQKeze


You can customize Ellipsis with 👍 / 👎 feedback, review rules, user-specific overrides, quiet mode, and more.

Copy link

@ellipsis-dev ellipsis-dev bot left a comment

Choose a reason for hiding this comment

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

👍 Looks good to me! Incremental review on ee7fae2 in 1 minute and 8 seconds

More details
  • Looked at 816 lines of code in 14 files
  • Skipped 0 files when reviewing.
  • Skipped posting 1 drafted comments based on config settings.
1. fennel/internal_lib/to_proto/to_proto.py:222
  • Draft comment:
    The history field is being set using ds._retention. It should be set using ds._history instead.
    history.FromTimedelta(ds._history)
  • Reason this comment was not posted:
    Decided after close inspection that this draft comment was likely wrong and/or not actionable:
    The presence of both _history and _retention fields, along with the new disable_historical field, suggests these are distinct concepts. The fact that both fields were changed from _history to _retention in the same PR suggests this was an intentional refactoring. The comment may be missing context about why this change was made. Without understanding the Dataset class implementation and the difference between these fields, I cannot be confident that using _retention is wrong.
    I don't have access to the Dataset class implementation to verify the intended usage of _history vs _retention. The comment could be correct if these are truly different concepts that shouldn't be mixed.
    However, the coordinated change of both fields to use _retention, plus the addition of disable_historical based on _history, suggests this was an intentional architectural change rather than a mistake.
    Delete the comment because we don't have enough context to be confident that using _retention is incorrect, and the coordinated changes suggest this was intentional.

Workflow ID: wflow_4oqEjXz6WcJL1V2l


You can customize Ellipsis with 👍 / 👎 feedback, review rules, user-specific overrides, quiet mode, and more.

Copy link

@ellipsis-dev ellipsis-dev bot left a comment

Choose a reason for hiding this comment

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

👍 Looks good to me! Incremental review on d5bf6d7 in 1 minute and 18 seconds

More details
  • Looked at 816 lines of code in 14 files
  • Skipped 0 files when reviewing.
  • Skipped posting 1 drafted comments based on config settings.
1. fennel/internal_lib/to_proto/to_proto.py:221
  • Draft comment:
    The history field is being set using ds._retention. This should be updated to reflect the new retention field instead of history.
  • Reason this comment was not posted:
    Decided after close inspection that this draft comment was likely wrong and/or not actionable:
    The comment seems to be suggesting a change that's already been made. The code is already using ds._retention to set the history field. The comment appears to have misread the diff and is suggesting something that's already implemented. This makes the comment not useful and potentially confusing.
    Could there be some deeper architectural issue the comment is trying to point out about using retention for history? Maybe there's context I'm missing about the relationship between these fields?
    While there could be deeper issues, the comment as written is clearly just pointing out that history should use retention, which is exactly what the code already does. If there were deeper architectural concerns, they should have been expressed differently.
    The comment should be deleted because it's suggesting a change that has already been made in the code, making it confusing and not useful.

Workflow ID: wflow_Ko3AoIqDUEbH6kF7


You can customize Ellipsis with 👍 / 👎 feedback, review rules, user-specific overrides, quiet mode, and more.

Copy link

@ellipsis-dev ellipsis-dev bot left a comment

Choose a reason for hiding this comment

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

👍 Looks good to me! Incremental review on 477ea04 in 58 seconds

More details
  • Looked at 815 lines of code in 14 files
  • Skipped 0 files when reviewing.
  • Skipped posting 1 drafted comments based on config settings.
1. fennel/internal_lib/to_proto/to_proto.py:221
  • Draft comment:
    The history field is being set using ds._retention. This should be updated to reflect the new retention parameter.
  • Reason this comment was not posted:
    Decided after close inspection that this draft comment was likely wrong and/or not actionable:
    The comment seems to misunderstand the intent of the code. The code is deliberately setting both history and retention to use ds._retention. There's even a TODO comment on line 224 that explains this is intentional. The comment is suggesting there's an issue when there isn't one - this appears to be the desired behavior.
    Could there be some context I'm missing about why history and retention should be different? Could the TODO comment be indicating future plans to change this?
    While the TODO suggests future changes, the current code is clearly intentional in using ds._retention for both fields. The comment is suggesting there's a mistake when it's actually working as designed.
    The comment should be deleted because it incorrectly suggests there's an issue with using ds._retention for both fields, when this appears to be the intended behavior.

Workflow ID: wflow_KG39cxPauP488APZ


You can customize Ellipsis with 👍 / 👎 feedback, review rules, user-specific overrides, quiet mode, and more.

Copy link

@ellipsis-dev ellipsis-dev bot left a comment

Choose a reason for hiding this comment

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

❌ Changes requested. Incremental review on d9a482f in 1 minute and 3 seconds

More details
  • Looked at 815 lines of code in 14 files
  • Skipped 0 files when reviewing.
  • Skipped posting 0 drafted comments based on config settings.

Workflow ID: wflow_bRZq2hUFJNI4lxg8


Want Ellipsis to fix these issues? Tag @ellipsis-dev in a comment. You can customize Ellipsis with 👍 / 👎 feedback, review rules, user-specific overrides, quiet mode, and more.

_check_owner_exists(ds)
history = duration_proto.Duration()
history.FromTimedelta(ds._history)
history.FromTimedelta(ds._retention)
Copy link

Choose a reason for hiding this comment

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

The history field is being set using ds._retention, which seems incorrect. It should be set using ds._history if it exists. Please verify and correct this.

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.

1 participant

Comments