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

Improve consistency in BaseLib docs. #796

Merged
merged 29 commits into from
Dec 1, 2024
Merged

Conversation

knutnergaard
Copy link
Contributor

No description provided.

knutnergaard and others added 29 commits November 20, 2024 14:08
- Add type annotation.
- Add/improve documentation.
- changed `BaseSegments.segments` to return `tuple` instead of `list`.
Remaining errors to be collected in robotools#775:

```zsh
contour.py:58: error: Signature of "_reprContents" incompatible with supertype "BaseObject"  [override]
contour.py:58: note:      Superclass:
contour.py:58: note:          @classmethod
contour.py:58: note:          def _reprContents(cls) -> List[str]
contour.py:58: note:      Subclass:
contour.py:58: note:          def _reprContents(self) -> List[str]
contour.py:125: error: Incompatible types in assignment (expression has type "Callable[[], Any]", variable has type "Optional[BaseGlyph]")  [assignment]
contour.py:125: error: Argument 1 to "reference" has incompatible type "BaseGlyph"; expected "Callable[[], Any]"  [arg-type]
contour.py:277: error: "BaseContour" has no attribute "_getIdentifierforPoint"; maybe "_getIdentifierForPoint" or "getIdentifierForPoint"?  [attr-defined]
contour.py:477: error: Signature of "isCompatible" incompatible with supertype "InterpolationMixin"  [override]
contour.py:477: note:      Superclass:
contour.py:477: note:          def isCompatible(self, other: Any, cls: Type[Any]) -> Tuple[bool, Any]
contour.py:477: note:      Subclass:
contour.py:477: note:          def isCompatible(self, other: BaseContour) -> Tuple[bool, str]
contour.py:532: error: "str" has no attribute "fatal"  [attr-defined]
contour.py:532: error: "str" has no attribute "warning"  [attr-defined]
contour.py:533: error: "str" has no attribute "fatal"  [attr-defined]
contour.py:535: error: "str" has no attribute "warning"  [attr-defined]
contour.py:657: error: "BaseContour" has no attribute "_reverseContour"  [attr-defined]
```
Changes in normalizers.py include:
- Handle normalization of specific plistlib-compatible types in `normalizeLibValue`.
- Resolve `mypy` errors.
- Improve error messages and efficiency in certain functions.
@benkiel
Copy link
Member

benkiel commented Dec 1, 2024

Thank you!

@benkiel benkiel merged commit ad2dccd into robotools:v1 Dec 1, 2024
10 checks passed
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.

2 participants