Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: dashboard error #889

Open
abrichr opened this issue Oct 25, 2024 · 0 comments
Open

[Bug]: dashboard error #889

abrichr opened this issue Oct 25, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@abrichr
Copy link
Member

abrichr commented Oct 25, 2024

Describe the bug

poetry shell
python -m openadapt.entrypoint
...
2024-10-25 11:21:52.595 | INFO     | openadapt.error_reporting:configure_error_reporting:28 - is_reporting_branch=True
DB_URL=sqlite:////Users/abrichr/oa/src/OpenAdapt/openadapt/data/openadapt.db
INFO  [alembic.runtime.migration] Context impl SQLiteImpl.
INFO  [alembic.runtime.migration] Will assume non-transactional DDL.

> [email protected] dev
> concurrently "npm run next-dev" "npm run fastapi-dev"

[0] 
[0] > [email protected] next-dev
[0] > next dev -p $DASHBOARD_CLIENT_PORT
[0] 
[1] 
[1] > [email protected] fastapi-dev
[1] > python3 -m uvicorn api.index:app --port $DASHBOARD_SERVER_PORT --reload
[1] 
[1] INFO:     Will watch for changes in these directories: ['/Users/abrichr/oa/src/OpenAdapt/openadapt/app/dashboard']
[1] INFO:     Uvicorn running on http://127.0.0.1:8080 (Press CTRL+C to quit)
[1] INFO:     Started reloader process [36490] using WatchFiles
[0]  ⚠ Specified "rewrites" will not automatically work with "output: export". See more info here: https://nextjs.org/docs/messages/export-no-custom-routes
[0]  ⚠ Specified "rewrites" will not automatically work with "output: export". See more info here: https://nextjs.org/docs/messages/export-no-custom-routes
[0]    ▲ Next.js 14.1.4
[0]    - Local:        http://localhost:5173
[0] 
[0]  ⚠ Specified "rewrites" will not automatically work with "output: export". See more info here: https://nextjs.org/docs/messages/export-no-custom-routes
[0]  ⚠ Specified "rewrites" will not automatically work with "output: export". See more info here: https://nextjs.org/docs/messages/export-no-custom-routes
[0]  ✓ Ready in 935ms
[1] INFO:     Started server process [36492]
[1] INFO:     Waiting for application startup.
[1] INFO:     Application startup complete.
[0]  ○ Compiling /recordings ...
[0]  ✓ Compiled /recordings in 1474ms (2325 modules)
[0] (node:36493) [DEP0060] DeprecationWarning: The `util._extend` API is deprecated. Please use Object.assign() instead.
[0] (Use `node --trace-deprecation ...` to show where the warning was created)
[1] INFO:     127.0.0.1:50055 - "GET /api/recordings HTTP/1.1" 200 OK
[1] INFO:     127.0.0.1:50057 - "GET /api/recordings/status HTTP/1.1" 200 OK
[1] INFO:     127.0.0.1:50056 - "GET /api/recordings/scrubbed HTTP/1.1" 200 OK
[0]  ○ Compiling /settings ...
[0] Browserslist: caniuse-lite is outdated. Please run:
[0]   npx update-browserslist-db@latest
[0]   Why you should do it regularly: https://github.com/browserslist/update-db#readme
[0]  ✓ Compiled /settings in 1213ms (2429 modules)
[1] INFO:     127.0.0.1:50139 - "GET /api/settings?category=api_keys HTTP/1.1" 200 OK
[1] INFO:     127.0.0.1:50187 - "GET /api/recordings HTTP/1.1" 200 OK
[1] INFO:     127.0.0.1:50189 - "GET /api/recordings/status HTTP/1.1" 200 OK
[1] INFO:     127.0.0.1:50188 - "GET /api/recordings/scrubbed HTTP/1.1" 200 OK
Warning: A component is changing an uncontrolled input to be controlled. This is likely caused by the value changing from undefined to a defined value, which should not happen. Decide between using a controlled or uncontrolled input element for the lifetime of the component. More info: https://reactjs.org/link/controlled-components
    at input
    at eval (webpack-internal:///(app-pages-browser)/./node_modules/@mantine/core/esm/core/Box/Box.mjs:36:11)
    at div
    at eval (webpack-internal:///(app-pages-browser)/./node_modules/@mantine/core/esm/core/Box/Box.mjs:36:11)
    at eval (webpack-internal:///(app-pages-browser)/./node_modules/@mantine/core/esm/components/Input/Input.mjs:70:106)
    at div
    at eval (webpack-internal:///(app-pages-browser)/./node_modules/@mantine/core/esm/core/Box/Box.mjs:36:11)
    at Provider (webpack-internal:///(app-pages-browser)/./node_modules/@mantine/core/esm/core/utils/create-optional-context/create-optional-context.mjs:17:15)
    at eval (webpack-internal:///(app-pages-browser)/./node_modules/@mantine/core/esm/components/Input/InputWrapper/InputWrapper.mjs:71:106)
    at eval (webpack-internal:///(app-pages-browser)/./node_modules/@mantine/core/esm/components/InputBase/InputBase.mjs:36:126)
    at eval (webpack-internal:///(app-pages-browser)/./node_modules/@mantine/core/esm/components/TextInput/TextInput.mjs:27:107)
    at div
    at eval (webpack-internal:///(app-pages-browser)/./node_modules/@mantine/core/esm/core/Box/Box.mjs:36:11)
    at eval (webpack-internal:///(app-pages-browser)/./node_modules/@mantine/core/esm/components/Stack/Stack.mjs:48:106)
    at fieldset
    at eval (webpack-internal:///(app-pages-browser)/./node_modules/@mantine/core/esm/core/Box/Box.mjs:36:11)
    at eval (webpack-internal:///(app-pages-browser)/./node_modules/@mantine/core/esm/components/Fieldset/Fieldset.mjs:44:106)
    at div
    at eval (webpack-internal:///(app-pages-browser)/./node_modules/@mantine/core/esm/core/Box/Box.mjs:36:11)
    at eval (webpack-internal:///(app-pages-browser)/./node_modules/@mantine/core/esm/components/Grid/GridCol/GridCol.mjs:36:106)
    at div
    at div
    at eval (webpack-internal:///(app-pages-browser)/./node_modules/@mantine/core/esm/core/Box/Box.mjs:36:11)
    at Provider (webpack-internal:///(app-pages-browser)/./node_modules/@mantine/core/esm/core/utils/create-safe-context/create-safe-context.mjs:20:15)
    at eval (webpack-internal:///(app-pages-browser)/./node_modules/@mantine/core/esm/components/Grid/Grid.mjs:54:106)
    at form
    at Form (webpack-internal:///(app-pages-browser)/./app/settings/(api_keys)/form.tsx:23:11)
    at APIKeys (webpack-internal:///(app-pages-browser)/./app/settings/(api_keys)/page.tsx:22:84)
    at StaticGenerationSearchParamsBailoutProvider (webpack-internal:///(app-pages-browser)/./node_modules/next/dist/client/components/static-generation-searchparams-bailout-provider.js:16:11)
    at InnerLayoutRouter (webpack-internal:///(app-pages-browser)/./node_modules/next/dist/client/components/layout-router.js:242:11)
    at RedirectErrorBoundary (webpack-internal:///(app-pages-browser)/./node_modules/next/dist/client/components/redirect-boundary.js:74:9)
    at RedirectBoundary (webpack-internal:///(app-pages-browser)/./node_modules/next/dist/client/components/redirect-boundary.js:82:11)
    at NotFoundBoundary (webpack-internal:///(app-pages-browser)/./node_modules/next/dist/client/components/not-found-boundary.js:84:11)
    at LoadingBoundary (webpack-internal:///(app-pages-browser)/./node_modules/next/dist/client/components/layout-router.js:340:11)
    at ErrorBoundary (webpack-internal:///(app-pages-browser)/./node_modules/next/dist/client/components/error-boundary.js:162:11)
    at InnerScrollAndFocusHandler (webpack-internal:///(app-pages-browser)/./node_modules/next/dist/client/components/layout-router.js:152:9)
    at ScrollAndFocusHandler (webpack-internal:///(app-pages-browser)/./node_modules/next/dist/client/components/layout-router.js:227:11)
    at RenderFromTemplateContext (webpack-internal:///(app-pages-browser)/./node_modules/next/dist/client/components/render-from-template-context.js:16:44)
    at OuterLayoutRouter (webpack-internal:///(app-pages-browser)/./node_modules/next/dist/client/components/layout-router.js:359:11)
    at InnerLayoutRouter (webpack-internal:///(app-pages-browser)/./node_modules/next/dist/client/components/layout-router.js:242:11)
    at RedirectErrorBoundary (webpack-internal:///(app-pages-browser)/./node_modules/next/dist/client/components/redirect-boundary.js:74:9)
    at RedirectBoundary (webpack-internal:///(app-pages-browser)/./node_modules/next/dist/client/components/redirect-boundary.js:82:11)
    at NotFoundBoundary (webpack-internal:///(app-pages-browser)/./node_modules/next/dist/client/components/not-found-boundary.js:84:11)
    at LoadingBoundary (webpack-internal:///(app-pages-browser)/./node_modules/next/dist/client/components/layout-router.js:340:11)
    at ErrorBoundary (webpack-internal:///(app-pages-browser)/./node_modules/next/dist/client/components/error-boundary.js:162:11)
    at InnerScrollAndFocusHandler (webpack-internal:///(app-pages-browser)/./node_modules/next/dist/client/components/layout-router.js:152:9)
    at ScrollAndFocusHandler (webpack-internal:///(app-pages-browser)/./node_modules/next/dist/client/components/layout-router.js:227:11)
    at RenderFromTemplateContext (webpack-internal:///(app-pages-browser)/./node_modules/next/dist/client/components/render-from-template-context.js:16:44)
    at OuterLayoutRouter (webpack-internal:///(app-pages-browser)/./node_modules/next/dist/client/components/layout-router.js:359:11)
    at div
    at eval (webpack-internal:///(app-pages-browser)/./node_modules/@mantine/core/esm/core/Box/Box.mjs:36:11)
    at div
    at eval (webpack-internal:///(app-pages-browser)/./node_modules/@mantine/core/esm/core/Box/Box.mjs:36:11)
    at eval (webpack-internal:///(app-pages-browser)/./node_modules/@mantine/core/esm/components/Flex/Flex.mjs:41:106)
    at div
    at eval (webpack-internal:///(app-pages-browser)/./node_modules/@mantine/core/esm/core/Box/Box.mjs:36:11)
    at InnerLayoutRouter (webpack-internal:///(app-pages-browser)/./node_modules/next/dist/client/components/layout-router.js:242:11)
    at RedirectErrorBoundary (webpack-internal:///(app-pages-browser)/./node_modules/next/dist/client/components/redirect-boundary.js:74:9)
    at RedirectBoundary (webpack-internal:///(app-pages-browser)/./node_modules/next/dist/client/components/redirect-boundary.js:82:11)
    at NotFoundErrorBoundary (webpack-internal:///(app-pages-browser)/./node_modules/next/dist/client/components/not-found-boundary.js:76:9)
    at NotFoundBoundary (webpack-internal:///(app-pages-browser)/./node_modules/next/dist/client/components/not-found-boundary.js:84:11)
    at LoadingBoundary (webpack-internal:///(app-pages-browser)/./node_modules/next/dist/client/components/layout-router.js:340:11)
    at ErrorBoundary (webpack-internal:///(app-pages-browser)/./node_modules/next/dist/client/components/error-boundary.js:162:11)
    at InnerScrollAndFocusHandler (webpack-internal:///(app-pages-browser)/./node_modules/next/dist/client/components/layout-router.js:152:9)
    at ScrollAndFocusHandler (webpack-internal:///(app-pages-browser)/./node_modules/next/dist/client/components/layout-router.js:227:11)
    at RenderFromTemplateContext (webpack-internal:///(app-pages-browser)/./node_modules/next/dist/client/components/render-from-template-context.js:16:44)
    at OuterLayoutRouter (webpack-internal:///(app-pages-browser)/./node_modules/next/dist/client/components/layout-router.js:359:11)
    at main
    at eval (webpack-internal:///(app-pages-browser)/./node_modules/@mantine/core/esm/core/Box/Box.mjs:36:11)
    at eval (webpack-internal:///(app-pages-browser)/./node_modules/@mantine/core/esm/components/AppShell/AppShellMain/AppShellMain.mjs:30:106)
    at div
    at eval (webpack-internal:///(app-pages-browser)/./node_modules/@mantine/core/esm/core/Box/Box.mjs:36:11)
    at Provider (webpack-internal:///(app-pages-browser)/./node_modules/@mantine/core/esm/core/utils/create-safe-context/create-safe-context.mjs:20:15)
    at eval (webpack-internal:///(app-pages-browser)/./node_modules/@mantine/core/esm/components/AppShell/AppShell.mjs:68:106)
    at Shell (webpack-internal:///(app-pages-browser)/./components/Shell/Shell.tsx:24:11)
    at MantineThemeProvider (webpack-internal:///(app-pages-browser)/./node_modules/@mantine/core/esm/core/MantineProvider/MantineThemeProvider/MantineThemeProvider.mjs:31:11)
    at MantineProvider (webpack-internal:///(app-pages-browser)/./node_modules/@mantine/core/esm/core/MantineProvider/MantineProvider.mjs:28:11)
    at body
    at CSPostHogProvider (webpack-internal:///(app-pages-browser)/./app/providers.tsx:26:11)
    at html
    at RedirectErrorBoundary (webpack-internal:///(app-pages-browser)/./node_modules/next/dist/client/components/redirect-boundary.js:74:9)
    at RedirectBoundary (webpack-internal:///(app-pages-browser)/./node_modules/next/dist/client/components/redirect-boundary.js:82:11)
    at NotFoundErrorBoundary (webpack-internal:///(app-pages-browser)/./node_modules/next/dist/client/components/not-found-boundary.js:76:9)
    at NotFoundBoundary (webpack-internal:///(app-pages-browser)/./node_modules/next/dist/client/components/not-found-boundary.js:84:11)
    at DevRootNotFoundBoundary (webpack-internal:///(app-pages-browser)/./node_modules/next/dist/client/components/dev-root-not-found-boundary.js:33:11)
    at ReactDevOverlay (webpack-internal:///(app-pages-browser)/./node_modules/next/dist/client/components/react-dev-overlay/internal/ReactDevOverlay.js:84:9)
    at HotReload (webpack-internal:///(app-pages-browser)/./node_modules/next/dist/client/components/react-dev-overlay/hot-reloader-client.js:307:11)
    at Router (webpack-internal:///(app-pages-browser)/./node_modules/next/dist/client/components/app-router.js:182:11)
    at ErrorBoundaryHandler (webpack-internal:///(app-pages-browser)/./node_modules/next/dist/client/components/error-boundary.js:115:9)
    at ErrorBoundary (webpack-internal:///(app-pages-browser)/./node_modules/next/dist/client/components/error-boundary.js:162:11)
    at AppRouter (webpack-internal:///(app-pages-browser)/./node_modules/next/dist/client/components/app-router.js:542:13)
    at ServerRoot (webpack-internal:///(app-pages-browser)/./node_modules/next/dist/client/app-index.js:129:11)
    at RSCComponent
    at Root (webpack-internal:///(app-pages-browser)/./node_modules/next/dist/client/app-index.js:145:11)

This warning typically occurs when an input's value prop changes from undefined to a defined value. It's likely happening in your Settings page, specifically in the API Keys form. To fix this:

Ensure that all form inputs have an initial value, even if it's an empty string.
Make sure you're properly handling the state of these inputs.
For example:

const [inputValue, setInputValue] = useState('');

// In your JSX
<TextInput
value={inputValue}
onChange={(event) => setInputValue(event.currentTarget.value)}
/>

To Reproduce

poetry shell
python -m openadapt.entrypoint

Select settings tab

@abrichr abrichr added the bug Something isn't working label Oct 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant