Skip to content

feat(openapi): Add more type/int limitations #20473

feat(openapi): Add more type/int limitations

feat(openapi): Add more type/int limitations #20473

Triggered via pull request August 28, 2024 07:14
Status Failure
Total duration 2m 1s
Artifacts

psalm.yml

on: pull_request
static-psalm-analysis
1m 29s
static-psalm-analysis
Fit to window
Zoom out
Zoom in

Annotations

10 errors
MoreSpecificReturnType: lib/Chat/ReactionManager.php#L130
lib/Chat/ReactionManager.php:130:13: MoreSpecificReturnType: The declared return type 'array<string, array<array-key, array{actorDisplayName: non-empty-string, actorId: non-empty-string, actorType: 'bots'|'bridged'|'circles'|'emails'|'federated_users'|'groups'|'guests'|'phones'|'users', timestamp: int<0, max>}>>' for OCA\Talk\Chat\ReactionManager::retrieveReactionMessages is more specific than the inferred return type 'array<string, non-empty-list<array{actorDisplayName: string, actorId: string, actorType: 'bots'|'bridged'|'circles'|'emails'|'federated_users'|'groups'|'guests'|'phones'|'users', timestamp: int}>>' (see https://psalm.dev/070)
LessSpecificReturnStatement: lib/Chat/ReactionManager.php#L152
lib/Chat/ReactionManager.php:152:10: LessSpecificReturnStatement: The type 'array<string, non-empty-list<array{actorDisplayName: string, actorId: string, actorType: 'bots'|'bridged'|'circles'|'emails'|'federated_users'|'groups'|'guests'|'phones'|'users', timestamp: int}>>' is more general than the declared return type 'array<string, array<array-key, array{actorDisplayName: non-empty-string, actorId: non-empty-string, actorType: 'bots'|'bridged'|'circles'|'emails'|'federated_users'|'groups'|'guests'|'phones'|'users', timestamp: int<0, max>}>>' for OCA\Talk\Chat\ReactionManager::retrieveReactionMessages (see https://psalm.dev/129)
MoreSpecificReturnType: lib/Config.php#L68
lib/Config.php:68:13: MoreSpecificReturnType: The declared return type '0|1' for OCA\Talk\Config::getUserReadPrivacy is more specific than the inferred return type 'int' (see https://psalm.dev/070)
LessSpecificReturnStatement: lib/Config.php#L71
lib/Config.php:71:10: LessSpecificReturnStatement: The type 'int' is more general than the declared return type '0|1' for OCA\Talk\Config::getUserReadPrivacy (see https://psalm.dev/129)
MoreSpecificReturnType: lib/Config.php#L78
lib/Config.php:78:13: MoreSpecificReturnType: The declared return type '0|1' for OCA\Talk\Config::getUserTypingPrivacy is more specific than the inferred return type 'int' (see https://psalm.dev/070)
LessSpecificReturnStatement: lib/Config.php#L81
lib/Config.php:81:10: LessSpecificReturnStatement: The type 'int' is more general than the declared return type '0|1' for OCA\Talk\Config::getUserTypingPrivacy (see https://psalm.dev/129)
MoreSpecificReturnType: lib/Controller/CallController.php#L65
lib/Controller/CallController.php:65:13: MoreSpecificReturnType: The declared return type 'OCP\AppFramework\Http\DataResponse<200, array<array-key, array{actorId: non-empty-string, actorType: 'bots'|'bridged'|'circles'|'emails'|'federated_users'|'groups'|'guests'|'phones'|'users', displayName: non-empty-string, lastPing: int<0, max>, sessionId: non-empty-string, token: non-empty-string}>, array<never, never>>' for OCA\Talk\Controller\CallController::getPeersForCall is more specific than the inferred return type 'OCP\AppFramework\Http\DataResponse<200, array<array-key, array{actorId: string, actorType: string, displayName: string, lastPing: int<0, max>, sessionId: string, token: string}>, array<never, never>>' (see https://psalm.dev/070)
LessSpecificReturnStatement: lib/Controller/CallController.php#L111
lib/Controller/CallController.php:111:10: LessSpecificReturnStatement: The type 'OCP\AppFramework\Http\DataResponse<200, list<array{actorId: string, actorType: string, displayName: string, lastPing: int<0, max>, sessionId: string, token: string}>, array<never, never>>' is more general than the declared return type 'OCP\AppFramework\Http\DataResponse<200, array<array-key, array{actorId: non-empty-string, actorType: 'bots'|'bridged'|'circles'|'emails'|'federated_users'|'groups'|'guests'|'phones'|'users', displayName: non-empty-string, lastPing: int<0, max>, sessionId: non-empty-string, token: non-empty-string}>, array<never, never>>' for OCA\Talk\Controller\CallController::getPeersForCall (see https://psalm.dev/129)
MoreSpecificReturnType: lib/Controller/ChatController.php#L1315
lib/Controller/ChatController.php:1315:13: MoreSpecificReturnType: The declared return type 'array<array-key, array{details?: non-empty-string, id: non-empty-string, label: non-empty-string, mentionId: non-empty-string, source: non-empty-string, status?: 'away'|'busy'|'dnd'|'invisible'|'offline'|'online', statusClearAt?: int<0, max>|null, statusIcon?: null|string, statusMessage?: null|string}>' for OCA\Talk\Controller\ChatController::prepareResultArray is more specific than the inferred return type 'list<array{id: mixed, label: mixed, mentionId: string, source: array-key, status?: string, statusClearAt?: int|null, statusIcon?: null|string, statusMessage?: null|string}>' (see https://psalm.dev/070)
LessSpecificReturnStatement: lib/Controller/ChatController.php#L1338
lib/Controller/ChatController.php:1338:10: LessSpecificReturnStatement: The type 'list<array{id: mixed, label: mixed, mentionId: string, source: array-key, status?: string, statusClearAt?: int|null, statusIcon?: null|string, statusMessage?: null|string}>' is more general than the declared return type 'array<array-key, array{details?: non-empty-string, id: non-empty-string, label: non-empty-string, mentionId: non-empty-string, source: non-empty-string, status?: 'away'|'busy'|'dnd'|'invisible'|'offline'|'online', statusClearAt?: int<0, max>|null, statusIcon?: null|string, statusMessage?: null|string}>' for OCA\Talk\Controller\ChatController::prepareResultArray (see https://psalm.dev/129)