Repository navigation
Conversation
Obsidian's main process hardens every webContents the app creates, including BrowserWindows opened by plugins, with a will-navigate listener that cancels http(s) navigations and hands the URL to shell.openExternal. The initial loadURL in src/components/amazonLoginModal/index.ts survives, since programmatic loads and HTTP redirects fire did-start-navigation and will-redirect rather than will-navigate. But once the Amazon sign-in page navigates on its own, the flow is cancelled in the modal and reopened in the user's default browser. Login then completes in a different cookie jar, did-navigate never reaches kindleReaderUrl, and doLogin never resolves, leaving the sync stuck on "Logging in...". Removing that listener from the window the plugin owns restores the flow. Verified on Obsidian 1.13.4 and Electron 28.2.3 through /ap/signin, /ax/claim, /ap/mfa, and back to read.amazon.com/notebook with two factor authentication enabled.
|
The linter error is preexisting, separate from this PR. "@types/node": "^20.19.43", |
|
Hey Guys, do you have any idea when this will be merged? I can't sync anymore. Thanks a lot. |
|
ETA on merge at the moment? Plugin not useable at all for new users |
|
If you're waiting on this to be merged, I'd suggest just applying the fix yourself in the installed plugin, or pointing Claude Code or similar at this PR and asking it to apply the fix. This plugin hasn't been updated in seven months, so it seems possible the maintainer has abandoned it. |
Obsidian cancels http(s) navigations in every window it creates and reopens them in the system browser, which ejected the Amazon sign-in flow and left sync stuck on "Logging in…". Drop that will-navigate listener on the login window the plugin owns. Applies upstream hadynz#338 (fixes hadynz#337), and adds a README note explaining this fork. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Hi team +1 on fix. Could you please prioritize this, as it breaks login-flow for new users. Thanks! |
|
Thank you for developing and maintaining this useful plugin from Japan. I'm experiencing the same Amazon login issue on Windows with Kindle Highlights v2.3.1. The Amazon notebook page opens in an external browser, but Obsidian remains stuck at "Logging in..." and no highlights are imported. |
Problem
Amazon Cloud sync never completes on current Obsidian. The login window opens, but as soon as you enter your email and click Continue, the flow is ejected into your default system browser. Logging in there does nothing for the plugin, and the sync modal sits on "Logging in…" forever.
Cause
Obsidian's main process hardens every
webContentsthe app creates includingBrowserWindows opened by plugins with awill-navigatelistener that cancels http(s) navigations and hands the URL toshell.openExternal. The login then completes in the browser's cookie jar rather than the plugin'spersist:kindle-highlightspartition, sodid-navigatenever reacheskindleReaderUrland the promise returned bydoLogin()never resolves.Fix
Fix #337
Drop that listener from the window the plugin owns:
Obsidian registers it once, at
web-contents-created, guarded by anisSecuredflag, so removing it immediately after construction is sufficient and nothing re-adds it. The plugin is the only owner of this window, and it only ever loads Amazon sign-in URLs.Verification
Tested end to end on Obsidian 1.13.4 / Electron 28.2.3 / macOS 15, with two-factor authentication enabled. The full chain now stays inside the plugin window:
Note on Passkey Incompatibility
Amazon's sign-in page throws
TypeError: u.PublicKeyCredential.getClientCapabilities is not a functionfromAUIClients/IdentityWebAuthnAssets. Electron 28 ships Chrome 120, which predates that API. It does not block password or OTP sign-in, but an account configured for passkey-only auth likely cannot complete login in this window at all.Thank you for this plugin, it's a great win for my Obsidian notes!