DOG-6526: Removed system managed properties#491
Conversation
Summary of ChangesHello @Hmnt39, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request refines the file upload mechanism by removing the explicit setting of the Highlights
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
There was a problem hiding this comment.
Code Review
This pull request correctly removes the manual setting of the is_uploaded property on CogniteExtractorFileApply objects, delegating this responsibility to the Cognite SDK. The version is bumped to 7.11.0, and the changelog and project files are updated accordingly. The changes are straightforward and improve maintainability. I have identified a related high-severity issue where the object passed to the post-upload callback is stale, which is made more apparent by this change.
einarmo
left a comment
There was a problem hiding this comment.
Could you write a test for this? I'm assuming there aren't any since nothing was failing in this repo.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #491 +/- ##
==========================================
+ Coverage 80.65% 80.88% +0.22%
==========================================
Files 43 43
Lines 4203 4201 -2
==========================================
+ Hits 3390 3398 +8
+ Misses 813 803 -10
🚀 New features to boost your workflow:
|
Added the test case to check if is_uploaded is changing. |
pyproject.toml
Outdated
| [project] | ||
| name = "cognite-extractor-utils" | ||
| version = "7.10.0" | ||
| version = "7.11.0" |
There was a problem hiding this comment.
This should be a patch version, 7.10.1
This PR remove the manual updation of
CogniteExtractorFileApplyis_uploadedproperties allow SDK to handle system-managed props.Need to merge once this is done https://cognitedata.atlassian.net/browse/DM-3366
https://github.com/cognitedata/cognite-sdk-python/pull/2414/files