Skip to content

Commit 297fd70

Browse files
authored
Merge pull request #4977 from RSSNext/release/desktop/1.6.1
release(desktop): Release v1.6.1
2 parents 1a3607f + dc498f4 commit 297fd70

45 files changed

Lines changed: 1054 additions & 444 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.easignore

Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
node_modules
2+
dist
3+
out/*
4+
!out/
5+
!out/rn-web
6+
!out/rn-web/
7+
!out/rn-web/**
8+
.next
9+
.open-next
10+
next-env.d.ts
11+
.DS_Store
12+
*.log*
13+
.env
14+
.eslintcache
15+
.env.*
16+
!.env.example
17+
18+
# Sentry Config File
19+
.env.sentry-build-plugin
20+
.vercel
21+
stats.html
22+
23+
electron.vite.config.*.mjs
24+
vite.config.*.mjs
25+
26+
.generated
27+
.turbo
28+
29+
apps/desktop/src/renderer/dev-dist
30+
tsconfig.tsbuildinfo
31+
buildServer.json
32+
33+
**/**/generated-routes.ts
34+
35+
apps/desktop/build/appxmanifest.xml
36+
apps/desktop/resources/cli
37+
38+
.claude/settings.local.json
39+
.serena
40+
41+
.wrangler
42+
43+
# Local agent artifacts
44+
.codex/
45+
46+
# E2E outputs
47+
/apps/desktop/e2e/playwright-report/
48+
/apps/desktop/e2e/test-results/
49+
/apps/mobile/e2e/artifacts/
50+
/apps/mobile/report.xml
51+
/report.xml
52+
53+
# Mobile local E2E build artifacts
54+
apps/mobile/build-*.tar.gz

.github/workflows/build-android.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,9 @@ jobs:
7272
- name: Install dependencies
7373
run: pnpm install
7474

75+
- name: Build mobile web assets
76+
run: pnpm --dir apps/mobile/web-app build --outDir ../../../out/rn-web/html-renderer
77+
7578
- name: 🔨 Build Android app
7679
working-directory: apps/mobile
7780
run: eas build --platform android --profile ${{ github.event.inputs.profile || 'preview' }} --local --output=${{ github.workspace }}/build.${{ github.event.inputs.profile == 'production' && 'aab' || 'apk' }}

.github/workflows/build-ios-development.yml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,9 @@ jobs:
5151
- name: Install dependencies
5252
run: pnpm install
5353

54+
- name: Build mobile web assets
55+
run: pnpm --dir apps/mobile/web-app build --outDir ../../../out/rn-web/html-renderer
56+
5457
- name: 🔨 Build iOS IPA
5558
working-directory: apps/mobile
5659
run: eas build --platform ios --profile development --non-interactive --local --output=./build.ipa
@@ -104,6 +107,9 @@ jobs:
104107
- name: Install dependencies
105108
run: pnpm install
106109

110+
- name: Build mobile web assets
111+
run: pnpm --dir apps/mobile/web-app build --outDir ../../../out/rn-web/html-renderer
112+
107113
- name: 🔨 Build iOS IPA
108114
working-directory: apps/mobile
109115
run: eas build --platform ios --profile development --non-interactive --local --output=./build.ipa
@@ -151,6 +157,9 @@ jobs:
151157
- name: Install dependencies
152158
run: pnpm install
153159

160+
- name: Build mobile web assets
161+
run: pnpm --dir apps/mobile/web-app build --outDir ../../../out/rn-web/html-renderer
162+
154163
- name: 🔨 Build iOS IPA
155164
working-directory: apps/mobile
156165
run: eas build --platform ios --profile ios-simulator --non-interactive --local --output=./build-simulator.ipa

.github/workflows/build-ios.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,9 @@ jobs:
5959
- name: Install dependencies
6060
run: pnpm install
6161

62+
- name: Build mobile web assets
63+
run: pnpm --dir apps/mobile/web-app build --outDir ../../../out/rn-web/html-renderer
64+
6265
- name: 🔨 Build iOS IPA
6366
working-directory: apps/mobile
6467
run: eas build --platform ios --profile ${{ github.event.inputs.profile || 'preview' }} --non-interactive --local --output=./build.ipa
@@ -117,6 +120,9 @@ jobs:
117120
- name: Install dependencies
118121
run: pnpm install
119122

123+
- name: Build mobile web assets
124+
run: pnpm --dir apps/mobile/web-app build --outDir ../../../out/rn-web/html-renderer
125+
120126
- name: 🔨 Build iOS IPA
121127
working-directory: apps/mobile
122128
run: eas build --platform ios --profile ${{ github.event.inputs.profile || 'preview' }} --non-interactive --local --output=./build.ipa

.prettierignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ pnpm-lock.yaml
22

33
CHANGELOG.md
44
.context
5+
.waylog
56

67
apps/external/postcss.config.cjs
78

apps/desktop/changelog/1.6.1.md

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
# What's new in v1.6.1
2+
3+
## Shiny new things
4+
5+
- Added Spotlight settings with refined highlighting controls
6+
- Unified desktop updates with the OTA service for more consistent delivery
7+
8+
## Improvements
9+
10+
- Moved desktop text-to-speech playback to the Folo service
11+
- Improved update compatibility handling and release metadata generation
12+
13+
## No longer broken
14+
15+
- Fixed regressions in desktop update and release flows
16+
- Fixed PDF export layout and branding
17+
- Fixed future credit reset dates in AI chat
18+
- Fixed PlayerProgress switching to hour formatting too late
19+
20+
## Thanks
21+
22+
Special thanks to volunteer contributor @kuishou68 for their valuable contribution

apps/desktop/changelog/next.md

Lines changed: 1 addition & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -2,21 +2,10 @@
22

33
## Shiny new things
44

5-
- Added Spotlight settings with refined highlighting controls
6-
- Unified desktop updates with the OTA service for more consistent delivery
7-
85
## Improvements
96

10-
- Moved desktop text-to-speech playback to the Folo service
11-
- Improved update compatibility handling and release metadata generation
12-
137
## No longer broken
148

15-
- Fixed regressions in desktop update and release flows
16-
- Fixed PDF export layout and branding
17-
- Fixed future credit reset dates in AI chat
18-
- Fixed PlayerProgress switching to hour formatting too late
19-
209
## Thanks
2110

22-
Special thanks to volunteer contributor @kuishou68 for their valuable contribution
11+
Special thanks to volunteer contributors @ for their valuable contributions

apps/desktop/layer/main/src/manager/bootstrap.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,8 @@ export class BootstrapManager {
8585
currentApiURL: env.VITE_API_URL,
8686
})
8787

88+
await cleanupOldRender()
89+
8890
// Bypass CORS for PostHog analytics
8991
session.defaultSession.webRequest.onHeadersReceived((details, callback) => {
9092
const url = new URL(details.url)

apps/desktop/layer/main/src/updater/api.test.ts

Lines changed: 46 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,11 @@
11
import { beforeEach, describe, expect, it, vi } from "vitest"
22

3+
const { getCurrentRendererManifestMock } = vi.hoisted(() => ({
4+
getCurrentRendererManifestMock: vi.fn<() => null | { runtimeVersion: string; version: string }>(
5+
() => null,
6+
),
7+
}))
8+
39
vi.mock("@follow/shared/env.desktop", () => ({
410
env: {
511
VITE_OTA_URL: "https://ota.folo.is",
@@ -27,12 +33,30 @@ vi.mock("../env", () => ({
2733
}))
2834

2935
vi.mock("~/updater/hot-updater", () => ({
30-
getCurrentRendererManifest: () => null,
36+
getCurrentRendererManifest: getCurrentRendererManifestMock,
37+
isRendererManifestUsable: (
38+
manifest: { runtimeVersion?: string; version?: string } | null,
39+
input: { appVersion: string; runtimeVersion: string },
40+
) => {
41+
if (!manifest?.runtimeVersion || manifest.runtimeVersion !== input.runtimeVersion) {
42+
return false
43+
}
44+
45+
const manifestVersion = manifest.version?.split("-")[0]
46+
const appVersion = input.appVersion?.split("-")[0]
47+
48+
if (!manifestVersion || !appVersion) {
49+
return false
50+
}
51+
52+
return manifestVersion >= appVersion
53+
},
3154
}))
3255

3356
describe("desktop updater api", () => {
3457
beforeEach(() => {
3558
vi.stubGlobal("fetch", vi.fn())
59+
getCurrentRendererManifestMock.mockReturnValue(null)
3660
})
3761

3862
it("returns null when desktop manifest responds 204", async () => {
@@ -90,6 +114,27 @@ describe("desktop updater api", () => {
90114
expect(result?.app).toBeNull()
91115
})
92116

117+
it("falls back to the app version when the cached renderer manifest is stale", async () => {
118+
getCurrentRendererManifestMock.mockReturnValue({
119+
runtimeVersion: "1.6.0",
120+
version: "0.6.4",
121+
})
122+
123+
vi.mocked(fetch).mockResolvedValue(new Response(null, { status: 204 }))
124+
125+
const { fetchDesktopManifest } = await import("./api")
126+
await fetchDesktopManifest()
127+
128+
expect(fetch).toHaveBeenCalledWith(
129+
new URL("/manifest", "https://ota.folo.is"),
130+
expect.objectContaining({
131+
headers: expect.objectContaining({
132+
"X-App-Renderer-Version": "1.5.0",
133+
}),
134+
}),
135+
)
136+
})
137+
93138
it("parses desktop policy responses", async () => {
94139
vi.mocked(fetch).mockResolvedValue(
95140
new Response(

apps/desktop/layer/main/src/updater/api.ts

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,8 @@
11
import { env } from "@follow/shared/env.desktop"
22
import { createDesktopAPIHeaders } from "@follow/utils/headers"
33
import PKG, { runtimeVersion as configuredRuntimeVersion, version as appVersion } from "@pkg"
4-
import { gte } from "semver"
54

6-
import { getCurrentRendererManifest } from "~/updater/hot-updater"
5+
import { getCurrentRendererManifest, isRendererManifestUsable } from "~/updater/hot-updater"
76

87
import { channel } from "../env"
98
import type {
@@ -18,8 +17,12 @@ export const getDesktopRuntimeVersion = () => configuredRuntimeVersion ?? appVer
1817

1918
export const getDesktopRendererVersion = () => {
2019
const rendererManifest = getCurrentRendererManifest()
21-
return gte(rendererManifest?.version ?? appVersion, appVersion)
22-
? (rendererManifest?.version ?? appVersion)
20+
21+
return isRendererManifestUsable(rendererManifest, {
22+
appVersion,
23+
runtimeVersion: getDesktopRuntimeVersion(),
24+
})
25+
? rendererManifest!.version
2326
: appVersion
2427
}
2528

0 commit comments

Comments
 (0)