Add check to make sure all reserved keywords are attributes and not properties - #1490
Conversation
27dc156 to
4ed506b
Compare
Greptile OverviewGreptile SummaryThis PR adds validation to ensure that the reserved keywords ( Changes:
The implementation is clean, well-tested, and includes helpful error messages that guide developers to use plain attributes or dataclass fields instead of properties. Confidence Score: 5/5
Important Files Changed
|
Signed-off-by: Ayush Dattagupta <ayushdg95@gmail.com> Signed-off-by: Omkar Kabde <omkarkabde@gmail.com>
NVIDIA-NeMo#1471) * Update transformers dependency to exact version 4.55.2 in pyproject.toml and uv.lock to prevent import failures in Cosmos Embed. Downgrade tokenizers version to 0.21.4 for compatibility. Signed-off-by: Abhinav Garg <abhinavg@stanford.edu> * Update transformers dependency in pyproject.toml and uv.lock to allow versions up to 4.55.2, ensuring compatibility with Cosmos Embed imports. Signed-off-by: Abhinav Garg <abhinavg@stanford.edu> --------- Signed-off-by: Abhinav Garg <abhinavg@stanford.edu> Co-authored-by: Ayush Dattagupta <ayushdg95@gmail.com> Signed-off-by: Omkar Kabde <omkarkabde@gmail.com>
Signed-off-by: Omkar Kabde <omkarkabde@gmail.com>
* docs: vdr feedback Signed-off-by: Lawrence Lane <llane@nvidia.com> * Update docs/admin/installation.md Co-authored-by: Sarah Yurick <53962159+sarahyurick@users.noreply.github.com> Signed-off-by: Lawrence Lane <llane@nvidia.com> * Update docs/admin/installation.md Co-authored-by: Sarah Yurick <53962159+sarahyurick@users.noreply.github.com> Signed-off-by: Lawrence Lane <llane@nvidia.com> * Update docs/admin/installation.md Co-authored-by: Sarah Yurick <53962159+sarahyurick@users.noreply.github.com> Signed-off-by: Lawrence Lane <llane@nvidia.com> * Update docs/curate-text/process-data/quality-assessment/distributed-classifier.md Co-authored-by: Sarah Yurick <53962159+sarahyurick@users.noreply.github.com> Signed-off-by: Lawrence Lane <llane@nvidia.com> * feedback Signed-off-by: Lawrence Lane <llane@nvidia.com> * feedback Signed-off-by: Lawrence Lane <llane@nvidia.com> * re order sidebar Signed-off-by: Lawrence Lane <llane@nvidia.com> * release notes draft Signed-off-by: Lawrence Lane <llane@nvidia.com> * feedback Signed-off-by: Lawrence Lane <llane@nvidia.com> * remove more internvid content Signed-off-by: Lawrence Lane <llane@nvidia.com> * release note fix Signed-off-by: Lawrence Lane <llane@nvidia.com> * Update docs/curate-video/tutorials/split-dedup.md Signed-off-by: Sarah Yurick <53962159+sarahyurick@users.noreply.github.com> --------- Signed-off-by: Lawrence Lane <llane@nvidia.com> Signed-off-by: Sarah Yurick <53962159+sarahyurick@users.noreply.github.com> Co-authored-by: Sarah Yurick <53962159+sarahyurick@users.noreply.github.com> Signed-off-by: Omkar Kabde <omkarkabde@gmail.com>
53b4266 to
ac5b0e1
Compare
|
The commits got messed up while rebasing and signing the commits I guess.. |
| def process(self, task: MockTask) -> MockTask: | ||
| return task | ||
|
|
||
| def test_plain_attribute_override_allowed(self): |
There was a problem hiding this comment.
I think this may not be needed and should already be covered by TestProcessingStageWith which uses ConcreteProcessingStage. What do you think @omkar-334 ?
There was a problem hiding this comment.
You're right... TestProcessingStageWith already tests for attribute overrides. Thanks for this!. Ive removed it now
Signed-off-by: Omkar Kabde <omkarkabde@gmail.com>
|
/ok to test ba29581 |
sarahyurick
left a comment
There was a problem hiding this comment.
Thanks @omkar-334 for the quick response!
…roperties (NVIDIA-NeMo#1490) * Fix: fasttext predict call for numpy>2 (NVIDIA-NeMo#1482) Signed-off-by: Ayush Dattagupta <ayushdg95@gmail.com> Signed-off-by: Omkar Kabde <omkarkabde@gmail.com> * Update transformers dependency to exact version 4.55.2 in pyproject.t… (NVIDIA-NeMo#1471) * Update transformers dependency to exact version 4.55.2 in pyproject.toml and uv.lock to prevent import failures in Cosmos Embed. Downgrade tokenizers version to 0.21.4 for compatibility. Signed-off-by: Abhinav Garg <abhinavg@stanford.edu> * Update transformers dependency in pyproject.toml and uv.lock to allow versions up to 4.55.2, ensuring compatibility with Cosmos Embed imports. Signed-off-by: Abhinav Garg <abhinavg@stanford.edu> --------- Signed-off-by: Abhinav Garg <abhinavg@stanford.edu> Co-authored-by: Ayush Dattagupta <ayushdg95@gmail.com> Signed-off-by: Omkar Kabde <omkarkabde@gmail.com> * remove property and add check Signed-off-by: Omkar Kabde <omkarkabde@gmail.com> * add tests Signed-off-by: Omkar Kabde <omkarkabde@gmail.com> * docs: vdr feedback (NVIDIA-NeMo#1477) * docs: vdr feedback Signed-off-by: Lawrence Lane <llane@nvidia.com> * Update docs/admin/installation.md Co-authored-by: Sarah Yurick <53962159+sarahyurick@users.noreply.github.com> Signed-off-by: Lawrence Lane <llane@nvidia.com> * Update docs/admin/installation.md Co-authored-by: Sarah Yurick <53962159+sarahyurick@users.noreply.github.com> Signed-off-by: Lawrence Lane <llane@nvidia.com> * Update docs/admin/installation.md Co-authored-by: Sarah Yurick <53962159+sarahyurick@users.noreply.github.com> Signed-off-by: Lawrence Lane <llane@nvidia.com> * Update docs/curate-text/process-data/quality-assessment/distributed-classifier.md Co-authored-by: Sarah Yurick <53962159+sarahyurick@users.noreply.github.com> Signed-off-by: Lawrence Lane <llane@nvidia.com> * feedback Signed-off-by: Lawrence Lane <llane@nvidia.com> * feedback Signed-off-by: Lawrence Lane <llane@nvidia.com> * re order sidebar Signed-off-by: Lawrence Lane <llane@nvidia.com> * release notes draft Signed-off-by: Lawrence Lane <llane@nvidia.com> * feedback Signed-off-by: Lawrence Lane <llane@nvidia.com> * remove more internvid content Signed-off-by: Lawrence Lane <llane@nvidia.com> * release note fix Signed-off-by: Lawrence Lane <llane@nvidia.com> * Update docs/curate-video/tutorials/split-dedup.md Signed-off-by: Sarah Yurick <53962159+sarahyurick@users.noreply.github.com> --------- Signed-off-by: Lawrence Lane <llane@nvidia.com> Signed-off-by: Sarah Yurick <53962159+sarahyurick@users.noreply.github.com> Co-authored-by: Sarah Yurick <53962159+sarahyurick@users.noreply.github.com> Signed-off-by: Omkar Kabde <omkarkabde@gmail.com> * remove override test Signed-off-by: Omkar Kabde <omkarkabde@gmail.com> --------- Signed-off-by: Ayush Dattagupta <ayushdg95@gmail.com> Signed-off-by: Omkar Kabde <omkarkabde@gmail.com> Signed-off-by: Abhinav Garg <abhinavg@stanford.edu> Signed-off-by: Lawrence Lane <llane@nvidia.com> Signed-off-by: Sarah Yurick <53962159+sarahyurick@users.noreply.github.com> Co-authored-by: Ayush Dattagupta <ayushdg95@gmail.com> Co-authored-by: Abhinav Garg <abhinavg@stanford.edu> Co-authored-by: Lawrence Lane <llane@nvidia.com> Co-authored-by: Sarah Yurick <53962159+sarahyurick@users.noreply.github.com> Signed-off-by: Omkar Kabde <omkarkabde@gmail.com>
closes #1481