Skip to content

only poll remote server from frontend in local mode#418

Open
pmeier wants to merge 1 commit into
mainfrom
guard-use-remote
Open

only poll remote server from frontend in local mode#418
pmeier wants to merge 1 commit into
mainfrom
guard-use-remote

Conversation

@pmeier

@pmeier pmeier commented Jun 24, 2026

Copy link
Copy Markdown
Member

Regression from #93. Without this guard, the frontend unconditionally polls the /api/v1/remote/server endpoint, which only exists in local mode.

@pmeier pmeier requested a review from Adam-D-Lewis June 24, 2026 11:50
@netlify

netlify Bot commented Jun 24, 2026

Copy link
Copy Markdown

Deploy Preview for nebi-docs canceled.

Name Link
🔨 Latest commit c14f933
🔍 Latest deploy log https://app.netlify.com/projects/nebi-docs/deploys/6a3bc488758fde0008ad96ef

@pmeier pmeier mentioned this pull request Jun 24, 2026

describe('useRemoteServer', () => {
beforeEach(() => {
useModeStore.setState({ mode: 'local' });

@Adam-D-Lewis Adam-D-Lewis Jun 25, 2026

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@pmeier Not causing a problem at the moment, but the value leaks into the tests that run after this block. Probably worth setting useModeStore state back to null in an afterEach.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll go ahead and approve as is though.

@Adam-D-Lewis Adam-D-Lewis self-requested a review June 25, 2026 17:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants