Update to 0.8.2#125
Conversation
Introduce helpers to target the primary Discord CDP page: get_primary_discord_target, navigate_primary_discord_target, and execute_js_via_primary_discord_target. Implement low-level navigate_target_via_ws to drive Page.enable/Page.navigate and wait for load events via CDP websocket. Refactor quest CDP logic to: aggregate JSON results across all Discord-like targets (CdpJsonExecutionSummary and cdp_execute_json_on_all_targets), log partial target failures, and perform a SPA warmup/restore flow (cdp_warmup_quest_route) before quests. Add JS that attempts in-app navigation via Discord router and falls back to Page.navigate. Replace many single-target execute_js_via_cdp usages with the new multi-target APIs and improve robustness and logging. Add unit tests for the warmup plan logic. Also remove the old execute_js_via_cdp helper and bump Discord super_properties client_build_number (May 21, 2026). These changes aim to improve reliability of quest spoofing and progress polling by warming up routes and aggregating best target responses.
Signed-off-by: dependabot[bot] <support@github.com>
Signed-off-by: dependabot[bot] <support@github.com>
Signed-off-by: dependabot[bot] <support@github.com>
There was a problem hiding this comment.
Pull request overview
This PR bumps the project to version 0.8.2 while improving the Discord CDP (Chrome DevTools Protocol) quest execution flow by adding “primary target” helpers, multi-target JSON execution summaries, and a quest-route warmup step to stabilize SPA navigation before running quest scripts.
Changes:
- Added CDP utilities to identify and operate on the primary Discord target (navigation + JS execution), plus a low-level
Page.navigateWebSocket helper. - Reworked CDP quest execution to run JSON-returning JS across all Discord targets, pick best results, and log partial target failures while continuing when possible.
- Updated default Discord client/build metadata and bumped Rust/Frontend dependencies (Tauri + Vite), plus version/release-notes updates.
Reviewed changes
Copilot reviewed 7 out of 9 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
src-tauri/src/super_properties.rs |
Updates default Discord client version/user-agent/build numbers used as fallback metadata. |
src-tauri/src/cdp_quest.rs |
Implements new CDP execution/warmup flow and adds tests for warmup plan selection. |
src-tauri/src/cdp_client.rs |
Adds primary-target helpers and a WebSocket navigation helper; removes the old generic JS helper in favor of new APIs. |
src-tauri/Cargo.toml |
Bumps tauri dependency to 2.11. |
src-tauri/Cargo.lock |
Lockfile updates resulting from the Rust dependency bump. |
public/version.txt |
Updates published version to 0.8.2. |
public/version-desc.txt |
Updates release notes to reflect CDP/task changes and version bumps. |
package.json |
Bumps vite to 7.3.2. |
pnpm-lock.yaml |
Lockfile updates resulting from the frontend dependency bump. |
Files not reviewed (1)
- pnpm-lock.yaml: Language not supported
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
🧹 Nitpick comments (1)
src-tauri/src/cdp_quest.rs (1)
19-21: ⚡ Quick winConsider using relative paths for Discord variant compatibility.
These absolute URLs always point to
discord.com. When used withUrl::join()inbuild_quest_route_warmup_plan, they will navigate Canary/PTB users from their variant domain (e.g.,canary.discord.com) to the stable domain, which may disrupt their session.Using relative paths would preserve the user's Discord variant:
Proposed fix
-const QUEST_HOME_URL: &str = "https://discord.com/quest-home"; -const QUEST_HOME_DETOUR_URL: &str = "https://discord.com/store"; +const QUEST_HOME_PATH: &str = "/quest-home"; +const QUEST_HOME_DETOUR_PATH: &str = "/store";Then update
build_quest_route_warmup_planto use these paths withjoin():let warmup_url = if already_on_quest_home { - current.join(QUEST_HOME_DETOUR_URL).ok()? + current.join(QUEST_HOME_DETOUR_PATH).ok()? } else { - current.join(QUEST_HOME_URL).ok()? + current.join(QUEST_HOME_PATH).ok()? };🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@src-tauri/src/cdp_quest.rs` around lines 19 - 21, Replace the hardcoded absolute Discord URLs with relative paths so variant domains (canary/PTB) are preserved; change QUEST_HOME_URL and QUEST_HOME_DETOUR_URL to path strings like "/quest-home" and "/store" and update any callers (notably build_quest_route_warmup_plan which uses Url::join) to continue using Url::join(base_url, path) so navigation stays on the same Discord subdomain.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@public/version-desc.txt`:
- Line 5: Change the present-tense entry "Bump default `client_build_number` to
`548544`, `native_build_number` to `82474`, `client_version` to `1.0.9238`, and
`browser_user_agent`." to past tense to match the other lines—e.g., replace
"Bump" with "Bumped" so the line reads "Bumped default `client_build_number` to
`548544`, `native_build_number` to `82474`, `client_version` to `1.0.9238`, and
`browser_user_agent`." referencing the exact phrase "Bump default
`client_build_number`..." in public/version-desc.txt.
---
Nitpick comments:
In `@src-tauri/src/cdp_quest.rs`:
- Around line 19-21: Replace the hardcoded absolute Discord URLs with relative
paths so variant domains (canary/PTB) are preserved; change QUEST_HOME_URL and
QUEST_HOME_DETOUR_URL to path strings like "/quest-home" and "/store" and update
any callers (notably build_quest_route_warmup_plan which uses Url::join) to
continue using Url::join(base_url, path) so navigation stays on the same Discord
subdomain.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro Plus
Run ID: 857db8d8-9de5-4d73-8a7c-176cf78ec248
⛔ Files ignored due to path filters (2)
pnpm-lock.yamlis excluded by!**/pnpm-lock.yamlsrc-tauri/Cargo.lockis excluded by!**/*.lock
📒 Files selected for processing (7)
package.jsonpublic/version-desc.txtpublic/version.txtsrc-tauri/Cargo.tomlsrc-tauri/src/cdp_client.rssrc-tauri/src/cdp_quest.rssrc-tauri/src/super_properties.rs
| 5. Fixed quest-start UI behavior by blurring focused elements before state switches to prevent unexpected page scroll-to-top. | ||
| 1. Fixed task completion with CDP Mode. | ||
| 2. Added a task warmup script for CDP Mode. | ||
| 3. Bump default `client_build_number` to `548544`, `native_build_number` to `82474`, `client_version` to `1.0.9238`, and `browser_user_agent`. |
There was a problem hiding this comment.
Use consistent past tense in release notes.
Line 5 should match the tense of Lines 3-4 (e.g., “Bumped default …”) for changelog consistency.
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In `@public/version-desc.txt` at line 5, Change the present-tense entry "Bump
default `client_build_number` to `548544`, `native_build_number` to `82474`,
`client_version` to `1.0.9238`, and `browser_user_agent`." to past tense to
match the other lines—e.g., replace "Bump" with "Bumped" so the line reads
"Bumped default `client_build_number` to `548544`, `native_build_number` to
`82474`, `client_version` to `1.0.9238`, and `browser_user_agent`." referencing
the exact phrase "Bump default `client_build_number`..." in
public/version-desc.txt.
This pull request updates the Discord CDP (Chrome DevTools Protocol) integration and related infrastructure, focusing on improved task execution, new CDP utilities, and updated default version/build numbers. It also includes dependency updates for both the Rust backend and the frontend.
CDP Integration Improvements:
get_primary_discord_target,navigate_primary_discord_target,execute_js_via_primary_discord_target). These replace the genericexecute_js_via_cdpfunction for more robust task execution in CDP Mode. [1] [2]navigate_target_via_ws, to enable and navigate Discord targets with proper error handling and timeouts.Default Version and Build Number Updates:
client_build_numberto548544,native_build_numberto82474,client_versionto1.0.9238, and updated thebrowser_user_agentstring inSuperProperties.public/version.txtto0.8.2and revised the release notes to reflect the new CDP task execution flow and version bumps. [1] [2]Dependency Updates:
taurifrom version2.10to2.11inCargo.toml.vitefrom7.3.1to7.3.2inpackage.json.