Skip to content

Add field model for rating field type #49

Add field model for rating field type

Add field model for rating field type #49

GitHub Actions / mypy failed Nov 30, 2024 in 0s

reviewdog [mypy] report

reported by reviewdog 🐶

Findings (15)

tagstudio/src/qt/widgets/rating.py|7 col 9| Cannot assign to a method [method-assign]
tagstudio/src/qt/widgets/rating.py|7 col 23| Incompatible types in assignment (expression has type "QHBoxLayout", variable has type "Callable[[], QLayout]") [assignment]
tagstudio/src/qt/widgets/rating.py|8 col 9| "Callable[[], QLayout]" has no attribute "setSpacing" [attr-defined]
tagstudio/src/qt/widgets/rating.py|9 col 24| Argument 1 to "setLayout" of "QWidget" has incompatible type "Callable[[], QLayout]"; expected "QLayout" [arg-type]
tagstudio/src/qt/widgets/rating.py|14 col 20| Incompatible types in assignment (expression has type "QPushButton", variable has type "int") [assignment]
tagstudio/src/qt/widgets/rating.py|15 col 13| "int" has no attribute "setCheckable" [attr-defined]
tagstudio/src/qt/widgets/rating.py|16 col 13| "int" has no attribute "clicked" [attr-defined]
tagstudio/src/qt/widgets/rating.py|17 col 13| "int" has no attribute "setStyleSheet" [attr-defined]
tagstudio/src/qt/widgets/rating.py|18 col 13| "int" has no attribute "setFixedSize" [attr-defined]
tagstudio/src/qt/widgets/rating.py|20 col 13| "Callable[[], QLayout]" has no attribute "addWidget" [attr-defined]
tagstudio/src/qt/widgets/rating.py|22 col 83| Argument 1 to "index" of "list" has incompatible type "QObject"; expected "int" [arg-type]
tagstudio/src/qt/widgets/rating.py|24 col 13| "int" has no attribute "setStyleSheet" [attr-defined]
tagstudio/src/qt/widgets/rating.py|26 col 13| "int" has no attribute "setStyleSheet" [attr-defined]
tagstudio/src/core/library/alchemy/library.py|464 col 44| "MediaCategory" has no attribute "name" [attr-defined]
tagstudio/src/core/library/alchemy/library.py|739 col 27| Incompatible types in assignment (expression has type "RatingBoxField", variable has type "TextField | DatetimeField | TagBoxField") [assignment]

Filtered Findings (0)

Annotations

Check failure on line 7 in tagstudio/src/qt/widgets/rating.py

See this annotation in the file changed.

@github-actions github-actions / mypy

[mypy] tagstudio/src/qt/widgets/rating.py#L7

Cannot assign to a method  [method-assign]
Raw output
/home/runner/work/TagStudioTesting/TagStudioTesting/tagstudio/src/qt/widgets/rating.py:7:9: error: Cannot assign to a method  [method-assign]

Check failure on line 7 in tagstudio/src/qt/widgets/rating.py

See this annotation in the file changed.

@github-actions github-actions / mypy

[mypy] tagstudio/src/qt/widgets/rating.py#L7

Incompatible types in assignment (expression has type "QHBoxLayout", variable has type "Callable[[], QLayout]")  [assignment]
Raw output
/home/runner/work/TagStudioTesting/TagStudioTesting/tagstudio/src/qt/widgets/rating.py:7:23: error: Incompatible types in assignment (expression has type "QHBoxLayout", variable has type "Callable[[], QLayout]")  [assignment]

Check failure on line 8 in tagstudio/src/qt/widgets/rating.py

See this annotation in the file changed.

@github-actions github-actions / mypy

[mypy] tagstudio/src/qt/widgets/rating.py#L8

"Callable[[], QLayout]" has no attribute "setSpacing"  [attr-defined]
Raw output
/home/runner/work/TagStudioTesting/TagStudioTesting/tagstudio/src/qt/widgets/rating.py:8:9: error: "Callable[[], QLayout]" has no attribute "setSpacing"  [attr-defined]

Check failure on line 9 in tagstudio/src/qt/widgets/rating.py

See this annotation in the file changed.

@github-actions github-actions / mypy

[mypy] tagstudio/src/qt/widgets/rating.py#L9

Argument 1 to "setLayout" of "QWidget" has incompatible type "Callable[[], QLayout]"; expected "QLayout"  [arg-type]
Raw output
/home/runner/work/TagStudioTesting/TagStudioTesting/tagstudio/src/qt/widgets/rating.py:9:24: error: Argument 1 to "setLayout" of "QWidget" has incompatible type "Callable[[], QLayout]"; expected "QLayout"  [arg-type]

Check failure on line 14 in tagstudio/src/qt/widgets/rating.py

See this annotation in the file changed.

@github-actions github-actions / mypy

[mypy] tagstudio/src/qt/widgets/rating.py#L14

Incompatible types in assignment (expression has type "QPushButton", variable has type "int")  [assignment]
Raw output
/home/runner/work/TagStudioTesting/TagStudioTesting/tagstudio/src/qt/widgets/rating.py:14:20: error: Incompatible types in assignment (expression has type "QPushButton", variable has type "int")  [assignment]

Check failure on line 15 in tagstudio/src/qt/widgets/rating.py

See this annotation in the file changed.

@github-actions github-actions / mypy

[mypy] tagstudio/src/qt/widgets/rating.py#L15

"int" has no attribute "setCheckable"  [attr-defined]
Raw output
/home/runner/work/TagStudioTesting/TagStudioTesting/tagstudio/src/qt/widgets/rating.py:15:13: error: "int" has no attribute "setCheckable"  [attr-defined]

Check failure on line 16 in tagstudio/src/qt/widgets/rating.py

See this annotation in the file changed.

@github-actions github-actions / mypy

[mypy] tagstudio/src/qt/widgets/rating.py#L16

"int" has no attribute "clicked"  [attr-defined]
Raw output
/home/runner/work/TagStudioTesting/TagStudioTesting/tagstudio/src/qt/widgets/rating.py:16:13: error: "int" has no attribute "clicked"  [attr-defined]

Check failure on line 17 in tagstudio/src/qt/widgets/rating.py

See this annotation in the file changed.

@github-actions github-actions / mypy

[mypy] tagstudio/src/qt/widgets/rating.py#L17

"int" has no attribute "setStyleSheet"  [attr-defined]
Raw output
/home/runner/work/TagStudioTesting/TagStudioTesting/tagstudio/src/qt/widgets/rating.py:17:13: error: "int" has no attribute "setStyleSheet"  [attr-defined]

Check failure on line 18 in tagstudio/src/qt/widgets/rating.py

See this annotation in the file changed.

@github-actions github-actions / mypy

[mypy] tagstudio/src/qt/widgets/rating.py#L18

"int" has no attribute "setFixedSize"  [attr-defined]
Raw output
/home/runner/work/TagStudioTesting/TagStudioTesting/tagstudio/src/qt/widgets/rating.py:18:13: error: "int" has no attribute "setFixedSize"  [attr-defined]

Check failure on line 20 in tagstudio/src/qt/widgets/rating.py

See this annotation in the file changed.

@github-actions github-actions / mypy

[mypy] tagstudio/src/qt/widgets/rating.py#L20

"Callable[[], QLayout]" has no attribute "addWidget"  [attr-defined]
Raw output
/home/runner/work/TagStudioTesting/TagStudioTesting/tagstudio/src/qt/widgets/rating.py:20:13: error: "Callable[[], QLayout]" has no attribute "addWidget"  [attr-defined]

Check failure on line 22 in tagstudio/src/qt/widgets/rating.py

See this annotation in the file changed.

@github-actions github-actions / mypy

[mypy] tagstudio/src/qt/widgets/rating.py#L22

Argument 1 to "index" of "list" has incompatible type "QObject"; expected "int"  [arg-type]
Raw output
/home/runner/work/TagStudioTesting/TagStudioTesting/tagstudio/src/qt/widgets/rating.py:22:83: error: Argument 1 to "index" of "list" has incompatible type "QObject"; expected "int"  [arg-type]

Check failure on line 24 in tagstudio/src/qt/widgets/rating.py

See this annotation in the file changed.

@github-actions github-actions / mypy

[mypy] tagstudio/src/qt/widgets/rating.py#L24

"int" has no attribute "setStyleSheet"  [attr-defined]
Raw output
/home/runner/work/TagStudioTesting/TagStudioTesting/tagstudio/src/qt/widgets/rating.py:24:13: error: "int" has no attribute "setStyleSheet"  [attr-defined]

Check failure on line 26 in tagstudio/src/qt/widgets/rating.py

See this annotation in the file changed.

@github-actions github-actions / mypy

[mypy] tagstudio/src/qt/widgets/rating.py#L26

"int" has no attribute "setStyleSheet"  [attr-defined]
Raw output
/home/runner/work/TagStudioTesting/TagStudioTesting/tagstudio/src/qt/widgets/rating.py:26:13: error: "int" has no attribute "setStyleSheet"  [attr-defined]

Check failure on line 464 in tagstudio/src/core/library/alchemy/library.py

See this annotation in the file changed.

@github-actions github-actions / mypy

[mypy] tagstudio/src/core/library/alchemy/library.py#L464

"MediaCategory" has no attribute "name"  [attr-defined]
Raw output
/home/runner/work/TagStudioTesting/TagStudioTesting/tagstudio/src/core/library/alchemy/library.py:464:44: error: "MediaCategory" has no attribute "name"  [attr-defined]

Check failure on line 739 in tagstudio/src/core/library/alchemy/library.py

See this annotation in the file changed.

@github-actions github-actions / mypy

[mypy] tagstudio/src/core/library/alchemy/library.py#L739

Incompatible types in assignment (expression has type "RatingBoxField", variable has type "TextField | DatetimeField | TagBoxField")  [assignment]
Raw output
/home/runner/work/TagStudioTesting/TagStudioTesting/tagstudio/src/core/library/alchemy/library.py:739:27: error: Incompatible types in assignment (expression has type "RatingBoxField", variable has type "TextField | DatetimeField | TagBoxField")  [assignment]