mirror of
https://github.com/hoppscotch/hoppscotch.git
synced 2026-04-25 16:55:59 +03:00
[GH-ISSUE #4859] [bug]: Root page fails to load with status code 404 in Desktop App on Windows #1829
Labels
No labels
CodeDay
a11y
browser limited
bug
bug fix
cli
core
critical
design
desktop
discussion
docker
documentation
duplicate
enterprise
feature
feature
fosshack
future
good first issue
hacktoberfest
help wanted
i18n
invalid
major
minor
need information
need testing
not applicable to hoppscotch
not reproducible
pull-request
question
refactor
resolved
sandbox
self-host
spam
stale
testmu
wip
wont fix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/hoppscotch#1829
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @a224327780 on GitHub (Mar 8, 2025).
Original GitHub issue: https://github.com/hoppscotch/hoppscotch/issues/4859
Is there an existing issue for this?
Current behavior
Steps to reproduce
Environment
Production
Version
Cloud
@CuriousCorrelation commented on GitHub (Mar 10, 2025):
Hi, thanks for the report, I'm unable to reproduce this on Windows 11 26100.3323.
So it will be very helpful if you could let me know your Windows version and build, if there are any logs in the developer console and how the network calls look like in the networks tab in the same console.
You can open the console like so:
See Microsoft DevTools for more details, it would look something like this:
@a224327780 commented on GitHub (Mar 13, 2025):
win10 22H2
@Saintel commented on GitHub (Mar 15, 2025):
I have the same issue on 23H2
Can you please explain how my browser understands what is host app.hoppscotch? I think, he makes nslookup and there’s no such DNS record
@CuriousCorrelation commented on GitHub (Mar 15, 2025):
We have been unable to reproduce this issue across multiple Windows environments, including both physical machines and virtual machines.
Just for additional context so you would be able to diagnose this further to understand if this is a specific Windows config or setup related oddity or a bug with the app - our desktop app is built with Tauri v2, which handles URI scheme protocols differently depending on the operating system:
app://hoppscotchschemahttp://app.hoppscotchschemaIn both cases, requests should properly route to the application's resources. We implement this using the register_uri_scheme_protocol , which you can see in our codebase here:
github.com/hoppscotch/hoppscotch@212cd4969d/packages/hoppscotch-desktop/plugin-workspace/tauri-plugin-appload/src/lib.rs (L148)Under the hood, Tauri implements this using the Windows WebView2 AddWebResourceRequestedFilter API.
The above screenshot is from Windows 10 Pro 22H2 19045.5608 live machine.
@Saintel commented on GitHub (Mar 27, 2025):
@CuriousCorrelation thank you for explaining.
I've never seen a registration new custom URI-scheme for existing URI scheme before.
For me it's a little strange, that
http://*must handle with another app (not browser).Everything I've seen before it's new URI, such as
app://,rdm://, office-apps A have an expirience for registration customvncURI-scheme via registry on Windows, and it's work.@Saintel commented on GitHub (Mar 28, 2025):
i tried to run as administrator, i tried to disable AntiVirus during installation.
Is there any way to collect logs for you?
@CuriousCorrelation commented on GitHub (Mar 28, 2025):
Hi @Saintel,
http://app.hoppscotchI believe is fully contained in the app context and doesn't globally intercept all HTTP traffic on the system like deep-linking. This is handled through WebView2's resource request filtering, which you can read more about in Tauri's documentation and with the code snippets here.Regarding logs, the desktop app does have logging capabilities. To access these, you can run the app in
devmode with theRUST_LOG=debugenvironment variable which should show you the exact logs to thestdout. The app requires multiple steps during the build process as described here (devvsbuildmodes):github.com/hoppscotch/hoppscotch@86c0bb619d/packages/hoppscotch-desktop/package.json (L11-L12)If you encounter any troubles with the above one-line command, you can split them up into parts and run them manually. And simply add or set the env var right before the final command like so
RUST_LOG=debug pnpm tauri dev. For Window, setting the env var is slightly different.@amishsthapit commented on GitHub (Mar 28, 2025):
I am also facing same issue. The app works on the first launch. But after that I just get the error message.
@dhayanands commented on GitHub (Apr 9, 2025):
Hi, The issue still persists. Was anyone able to find a workaround?
@sLIDe5 commented on GitHub (Apr 11, 2025):
Having the same issue with fresh
v25.3.1-0install on Windows 11 Pro 24H2 (26100.3775)@AndreKR commented on GitHub (Apr 14, 2025):
I'm also seeing this.
Windows 10 Pro 22H2, Edge 135.0.3179.73
I tried doing the dev mode thing but I am unable to build the app.
Details about the failing build
Part of the
pnpm installprocess is runningpnpm run postinstallinpackages\hoppscotch-backend. This fails with a lot of errors relating to prisma:I googled and fiddled around a bit and decided to copy
packages\hoppscotch-backend\node_modules\.prismatopackages\hoppscotch-backend\node_modules\@prisma\client\.prismabecause I saw some paths in@prisma\clientthat seemed to refer to.prisma. (I'm not really familiar with nest and prisma.)But I'm still getting an error:
Can you think of another way to shed some light on this?
Is there maybe a way to check which filters have been registered using
AddWebResourceRequestedFilter?@CuriousCorrelation commented on GitHub (Apr 14, 2025):
@AndreKR Thanks for trying the build. The Prisma errors you're encountering (missing client exports for
PersonalAccessToken,VerificationToken, etc.) are part of some longstanding Prisma issues specifically on Windows platforms due to how Windows handles path resolution.The most reliable fix I've found is to run
pnpm clean(or evengit clean -xdfin some cases. It clears every file in thegitdirectory which is NOT part of the monorepo) followed bypnpm install --shamefully-hoist. This flag modifies how dependencies are hoisted in thenode_modules.Regarding the
404error: I'm working on implementing persistent logging for desktop app prod build/release build, that will create and redirect logs to local storage that will make troubleshooting these types of issues much easier in the future. Aiming to include this in an upcoming release.In the meantime, if anyone discovers a workaround, please share it here. We're continuing to investigate why this affects some Windows configurations but not others.
@dhayanands commented on GitHub (Apr 16, 2025):
Going to %TEMP% on windows explorer and deleting the temporary files solved the 404 error for me.
@CuriousCorrelation commented on GitHub (Apr 30, 2025):
Hello everyone! The latest update of the desktop app (v25.4.0) now includes file-based rotating logs, a feature specifically implemented to address hard-to-reproduce problems like the one you are experiencing.
As @dhayanands mentioned, clearing your Windows
%TEMP%can resolve this issue:If you're still experiencing this
404error after trying the cleanup solution, please update to the latest version and if the issue persists, you can now share your logs here to help diagnose the problem (be sure to anonymize it if necessary!).The log files are located at:
C:\Users\<username>\AppData\Local\io.hoppscotch.desktop\logs\io.hoppscotch.desktop.log~/Library/Logs/io.hoppscotch.desktop/io.hoppscotch.desktop.log~/.local/share/io.hoppscotch.desktop/logs/io.hoppscotch.desktop.logFor more info see the PR https://github.com/hoppscotch/hoppscotch/pull/5009
The system automatically rotates logs when they reach 10MB, keeping up to 5 files for history (maximum of 50MB total).
@Saintel commented on GitHub (Apr 30, 2025):
Thank you for logging!
After clearing
TEMPthe issue is still reproduced.logs:
@CuriousCorrelation commented on GitHub (Apr 30, 2025):
Thanks @Saintel for sharing your logs! This is very strange but I think I might know what's happening. The app is failing to initialize the vendored bundle, which explains why the cache is empty (
hot_cache_len=0,disk_cache_len=0). Seems like the bundle files aren't being loaded into the cache during startup, usually located inRoaming\io.hoppscotch.desktop\bundles.While I don't know the exact environment restrictions that might be causing this issue, my educated guess would be that the app starts and tries to initialize the vendored bundle, this initialization then fails because the cache remains empty (this can happen and there are fallbacks for it), but when the app tries to load
hoppscotch:index.html, even that fails with "Cache entry not found" (this means the fallback failed as well)The cache files are (should be) located in
AppData\Roaming\io.hoppscotch.desktop\and the fact that logs are working but the cache isn't suggests there might be permission issues with the Roaming directory. Your user account might not have full access toRoaming?A few things you can try,
AppDatadirectory inRoamingif it exists, andAppData\Roamingto network locations, which is known to cause issues.@Saintel commented on GitHub (Apr 30, 2025):
Hi @CuriousCorrelation
AppData\Roaming\io.hoppscotch.desktop\? All Folders inc:\Users\my_user\AppData\Roaming\io.hoppscotch.desktop\are realy empty, includingbundles, i clean this folder and relaunch app with/without Admin permissions, and the issue is still here. Folder structure was created, but folders are empty.@CuriousCorrelation commented on GitHub (Apr 30, 2025):
Hi @Saintel, I think you figured out the issue!
See this (on a fresh install of Windows)
as you can see the directory contains information and files required by the app to function, which on your machine is empty. That being empty on you machine is likely a permissions or storage space issue (initial install may require large amount of storage for extractions, it won't use all the space after install). In either cases, the app cannot log any more information since it won't have the ability to introspect.
So essentially it's either a permissions issue or a storage space issue. One thing you can try is deleting
io.hoppscotch.desktopentirely to signal the app to try recreating the directory structure. If it's still empty after that, likely a storage issue.I looked up documentations for Windows and it seems one can check permissions using PowerShell:
Also if you have Process Monitor (from SysInternals), you could try to capture file system operations when launching the app to see exactly where it's failing.
In the meantime, I'm also looking into reproducing the environment to figure out what's exactly the root cause.
Quick edit to share the tests so far - I was able to reproduce albeit inconsistently, although it looks like there's a high likelihood that this is related to low storage capacity where some OS policies are preventing the app from creating and storing the application bundles.
@surdaft commented on GitHub (May 23, 2025):
Apologies for jumping in on the thread.
I encountered this error and came across the thread; checking the logs it shows "Bundle loaded successfully" however, as you mentioned above, it should be within the AppData Roaming dir under Bundles, but that was empty. So Bundles were not loaded successfully. I then saw your message about disk space and only had like 11GB remaining, so freeing up space fixed the issue. Potentially warning about the disk space would be handy too.
TLDR; I needed to have more than 11GB remaining disk to fix the issue
@CuriousCorrelation commented on GitHub (May 23, 2025):
@surdaft No worries at all - I actually appreciate you sharing your experience! This helps confirm diagnosis.
You're right that this is disk-space related, though the app itself only needs around 20MB or a bit more depending on how many self-hosted instances are saved.
The actual issue was quite complex and required multiple patches (see the linked PR/commit for more details on the latest) but this should be resolved fully in the upcoming release
v25.5.0.@Prikalel commented on GitHub (May 26, 2025):
so when v25.5.0 will be released?
btw do we have any temporary workarounds for that?
@bad-maths commented on GitHub (May 27, 2025):
I'm having the same issue here. 🙋♂️
Windows 10 Pro 22H2 build 19045.2846
with only 4GB free on the C drive, so I think it might be something related to disk space.
@CuriousCorrelation commented on GitHub (May 28, 2025):
Hey @Prikalel and @bad-maths the latest release
v25.5.0-0is now available with an initial attempt at fully fixing this disk space/bundle loading issue!The fix addresses the core problem that was identified where the app was failing to properly extract and cache bundles in the AppData directory when disk space was limited or when Windows was handling path resolution in unexpected ways, more of the latter.
For those who've been affected by this 404 error, please update to
v25.5.0-0(download section on official site) and let me know if this resolves the issue for you.Given that this problem appears to be highly dependent on specific Windows configurations, system policies, and available disk space, I'm cautiously optimistic but would really appreciate your feedback.
@sLIDe5 commented on GitHub (May 28, 2025):
Update from within Hoppscotch application with ~3GB left on drive didn't work (download stuck on about 10%) but fresh install is now working (even with less space free) and no more 404 error.
@CuriousCorrelation commented on GitHub (May 28, 2025):
Awesome! Thanks for the confirmation @sLIDe5
Ah yes, this tends to happen when the artifact distribution hasn't fully cached across all geo-locations, this is unrelated to disk space, more to do with update distribution, so this should be resolved once artifacts are fully populated, takes a few hours depending on GitHub traffic.
@AndreKR commented on GitHub (May 28, 2025):
Automatic update worked for me. 10 GB of 1.8 TB free.
@CuriousCorrelation commented on GitHub (Jun 6, 2025):
I have received several confirmation from different channels that the fix https://github.com/hoppscotch/hoppscotch/pull/5049 has been confirmed working. Thanks to everyone who provided debug info and feedback!
For anyone still experiencing this issue, please update to the latest version at https://hoppscotch.com/download. If updating from within the app fails, try a fresh download and install, all user data will be preserved ✅
If you continue to experience similar errors after updating to the latest version, feel free to reply here with your Windows version/build, available disk space, and the log file contents. The desktop app has persistent logs that can be found at
C:\Users\<username>\AppData\Local\io.hoppscotch.desktop\logs\io.hoppscotch.desktop.log. This will help diagnose any remaining edge cases without fragmenting the discussion across multiple issues.Thanks for helping tracked down this rather tricky issue! 🎉