Skip to content

Revert "PR-B: Unify frontend URL structure and make API timeout configurable"#48

Open
IzBrain67 wants to merge 1 commit into
feature/45-minimize-accidental-devprod-configuration-driftfrom
revert-47-dev-prod-parity-frontend-urls
Open

Revert "PR-B: Unify frontend URL structure and make API timeout configurable"#48
IzBrain67 wants to merge 1 commit into
feature/45-minimize-accidental-devprod-configuration-driftfrom
revert-47-dev-prod-parity-frontend-urls

Conversation

@IzBrain67
Copy link
Copy Markdown
Collaborator

Reverts #47

Copilot AI review requested due to automatic review settings May 21, 2026 18:20
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR reverts the earlier changes from #47 that attempted to unify frontend URL structure and make the frontend API timeout configurable, restoring prior dev/proxy and configuration behavior.

Changes:

  • Removes Vite dev-server proxy routes for /jupyter, /mcp, and /auth, and simplifies the docker Vite proxy config.
  • Reverts frontend API timeout handling from env-configurable to fixed per-environment values.
  • Adjusts frontend env template guidance and updates Docker Compose defaults (notably JUPYTERHUB_BASE_URL).

Reviewed changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 4 comments.

Show a summary per file
File Description
gui/workflow_frontend/vite.config.ts Removes non-/api dev proxy routes.
gui/workflow_frontend/vite.config.docker.ts Hardcodes docker dev proxy target to the backend service.
gui/workflow_frontend/src/api/config.ts Replaces env-parsed timeout with fixed timeouts by mode.
gui/workflow_frontend/env.template Updates URL guidance and defaults (notably Jupyter base URL).
gui/docker-compose.yml Updates JupyterHub base URL defaults and frontend networking/depends_on.
Comments suppressed due to low confidence (1)

gui/workflow_frontend/vite.config.docker.ts:34

  • vite.config.docker.ts now hardcodes the backend proxy target to http://backend:3000 and no longer supports VITE_PROXY_BACKEND overrides. This makes docker-based dev less configurable (and is inconsistent with env.template, which still suggests proxy configuration). Consider restoring env-based targets or updating the template/docs so users aren’t misled.
  server: {
    watch: {
      usePolling: true,
    },
    proxy: {
      "/api": {
        target: "http://backend:3000",
        changeOrigin: true,
        secure: false,
      },
    },

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread gui/docker-compose.yml
- ./workflow_frontend/.env
depends_on:
- backend
- backend
@@ -31,22 +31,6 @@ export default defineConfig({
changeOrigin: true,
secure: false,
},
# Browser-facing base URLs.
# These are always relative paths. In dev, the Vite proxy forwards each
# prefix to the appropriate container; in prod, nginx does the same routing.
# Behind nginx these become relative paths; in local dev they use localhost:PORT.
Comment on lines 7 to +16
export const getApiConfig = (): ApiConfig => {
const isDev = (import.meta.env.MODE || "development") === "development";
return {
baseURL: import.meta.env.VITE_API_BASE_URL,
internalSecret:
import.meta.env.VITE_INTERNAL_SECRET || (isDev ? "dev-secret" : ""),
timeout: parseTimeout(import.meta.env.VITE_API_TIMEOUT),
};
const env = import.meta.env.MODE || "development";

switch (env) {
case "production":
return {
baseURL: import.meta.env.VITE_API_BASE_URL,
internalSecret: import.meta.env.VITE_INTERNAL_SECRET || "",
timeout: 10000,
};
@carlosengutierrez
Copy link
Copy Markdown
Collaborator

@IzBrain67 @kirillmitrofanov Thank you for your help. I will review the code myself for some days to get up to date. After that I will review future paths or collaboration or work specification with leaders before reaching you. Hold on. Thank you.

@oist oist deleted a comment from IzBrain67 May 23, 2026
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.

3 participants