From cfaa976743ce69e295b605d6b243511646d8a670 Mon Sep 17 00:00:00 2001 From: Josh Date: Mon, 10 Aug 2026 10:39:02 -0400 Subject: [PATCH 1/2] fix(appstore): honor subclass cache invalidation duration Signed-off-by: Josh --- lib/private/App/AppStore/Fetcher/Fetcher.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/private/App/AppStore/Fetcher/Fetcher.php b/lib/private/App/AppStore/Fetcher/Fetcher.php index 7aec5f3251efd..3cd2940d0bcef 100644 --- a/lib/private/App/AppStore/Fetcher/Fetcher.php +++ b/lib/private/App/AppStore/Fetcher/Fetcher.php @@ -151,8 +151,8 @@ public function get($allowUnstable = false): array { if (is_array($jsonBlob)) { // No caching when the version has been updated if (isset($jsonBlob['ncversion']) && $jsonBlob['ncversion'] === $this->getVersion()) { - // If the timestamp is older than 3600 seconds request the files new - $invalidateAfterSeconds = self::INVALIDATE_AFTER_SECONDS; + // If the timestamp is old, request the files new + $invalidateAfterSeconds = static::INVALIDATE_AFTER_SECONDS; if ($allowUnstable) { $invalidateAfterSeconds = self::INVALIDATE_AFTER_SECONDS_UNSTABLE; From dce67f33809516106afe9bb432b39bb886156cd7 Mon Sep 17 00:00:00 2001 From: Josh Date: Tue, 11 Aug 2026 12:33:46 -0400 Subject: [PATCH 2/2] test(appstore): fix stale cache fixtures for AppDiscoverFetcher Signed-off-by: Josh --- tests/lib/App/AppStore/Fetcher/FetcherBase.php | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/tests/lib/App/AppStore/Fetcher/FetcherBase.php b/tests/lib/App/AppStore/Fetcher/FetcherBase.php index 3a0d30a32653a..082bb90ba2185 100644 --- a/tests/lib/App/AppStore/Fetcher/FetcherBase.php +++ b/tests/lib/App/AppStore/Fetcher/FetcherBase.php @@ -211,8 +211,8 @@ public function testGetWithAlreadyExistingFileAndOutdatedTimestamp(): void { ->expects($this->exactly(2)) ->method('getTime') ->willReturnOnConsecutiveCalls( - 4801, - 1502 + 90001, + 90002, ); $client = $this->createMock(IClient::class); $this->clientService @@ -474,8 +474,8 @@ public function testGetMatchingETag(): void { ->expects($this->exactly(2)) ->method('getTime') ->willReturnOnConsecutiveCalls( - 4801, - 4802 + 90001, + 90002, ); $client = $this->createMock(IClient::class); $this->clientService @@ -557,8 +557,8 @@ public function testGetNoMatchingETag(): void { ->expects($this->exactly(2)) ->method('getTime') ->willReturnOnConsecutiveCalls( - 4801, - 4802, + 90001, + 90002, ); $client = $this->createMock(IClient::class); $this->clientService