Skip to content

Conversation

@iLLiCiTiT
Copy link
Member

Changelog Description

Fill type hints in operations code.

Testing notes:

  1. Validate code changes.

@iLLiCiTiT iLLiCiTiT added the type: enhancement New feature or request label Aug 18, 2025
@iLLiCiTiT iLLiCiTiT self-assigned this Aug 18, 2025
Copy link
Member

@antirotor antirotor left a comment

Choose a reason for hiding this comment

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

Things to consider - using TypedDict to construct return values and how to deal with NOT_SET - perhaps changing NOT_SET and similar to class and type hint that?

folder_id: str,
name: Optional[str] = None,
folder_type: Optional[str] = None,
parent_id: Optional[str] = NOT_SET,
Copy link
Member

Choose a reason for hiding this comment

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

This won't work as NOT_SET is object, but the attribute is typed as Optional[str].

Copy link
Member Author

@iLLiCiTiT iLLiCiTiT Sep 9, 2025

Choose a reason for hiding this comment

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

And what would be the solution? How to type-hint placeholder objects?

The type-hint for "developer using the code" is Optional[str] if he passes the value. I really don't want to block this PR just because it is not mypy compatible, the release of python api should have been done 2 weeks ago.

Copy link
Member

Choose a reason for hiding this comment

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

Not functional change, should not block the merge anyway. Would be nice to find how to solve that though.

@iLLiCiTiT iLLiCiTiT merged commit e5fb835 into develop Sep 15, 2025
2 checks passed
@iLLiCiTiT iLLiCiTiT deleted the enhancement/operations-type-hints branch September 15, 2025 07:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

type: enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants