GeezerVisonThe World Wide Web, restored to 800 pixels of glory. | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Home|About|Gaming cabinet|Archives|How it works|Starter sites | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
GeezerVison is showing github.com — feat(site): add the chat projects and memory UI (experiment) by f0ssel · Pull Request #29405 · coder/coder Conversation
|
Sorry, something went wrong.
There was an error while loading. Please reload this page.
97427a1 to
02e868b
Compare
a570d03 to
76e31de
Compare
02e868b to
51ababa
Compare
76e31de to
3181dc6
Compare
|
@codex review |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Here are some automated review suggestions for this pull request.
Reviewed commit: 3181dc6e09
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
Sorry, something went wrong.
There was an error while loading. Please reload this page.
| {onOpenProjectDialog && onDeleteProject && ( | ||
| <ProjectsSection | ||
| projects={projects} | ||
| projectPermissions={projectPermissions} | ||
| expanded={!collapsedSections.Projects} | ||
| onToggle={() => toggleSection("Projects")} | ||
| onCreate={() => onOpenProjectDialog(null)} | ||
| onEdit={onOpenProjectDialog} | ||
| onDelete={onDeleteProject} | ||
| /> |
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Render projects when the chat list is empty
Because ProjectsSection is inside the non-empty branch of isShowingEmptyState, a new user with no chats, or a user whose filters match no chats, cannot see existing projects or the New project button. Move the projects UI outside the chat-empty conditional so project access does not depend on visible chat rows.
AGENTS.md reference: site/AGENTS.md:L11-L11
Useful? React with 👍 / 👎.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
| ...(model ? { model_config_id: model } : {}), | ||
| ...(reasoningEffort ? { reasoning_effort: reasoningEffort } : {}), | ||
| ...(selectedProject ? { project_id: selectedProject.id } : {}), |
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Block chat creation until the project lookup completes
When /agents?project=... loads slowly or fails with a non-404 error, the form remains usable while selectedProject is undefined, so submitting silently creates an ordinary chat in the form-selected organization without project_id. Disable creation while the requested project is loading and surface lookup failures rather than falling back to an unscoped chat.
AGENTS.md reference: site/AGENTS.md:L11-L11
Useful? React with 👍 / 👎.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
| const defaultOrganizationId = | ||
| organizations.find((organization) => organization.is_default)?.id ?? ""; |
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Fall back to an organization the user can access
For users who are not members of the deployment's default organization, none of the accessible organizations has is_default, so this becomes an empty ID: the projects query is disabled and New project submits organization_id: "", which the API rejects. The existing agents layout explicitly handles this case by falling back to organizations[0]; the project sidebar needs the same fallback or an organization selector.
Useful? React with 👍 / 👎.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
| const chatsQuery = useInfiniteQuery({ | ||
| ...infiniteChats({ projectId }), | ||
| enabled: experiments.includes("chat-projects") && Boolean(projectId), | ||
| }); | ||
| const chats = chatsQuery.data?.pages.flat() ?? []; |
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Wire pagination for the project chat list
infiniteChats fetches 50 chats per page, but this page only flattens pages already fetched and never calls fetchNextPage or renders a load-more sentinel. Consequently, projects containing more than 50 accessible root chats permanently omit every chat after the first page.
Useful? React with 👍 / 👎.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
| const projectsQuery = useQuery({ | ||
| ...chatProjects(defaultOrganizationId), | ||
| enabled: chatProjectsEnabled && Boolean(defaultOrganizationId), | ||
| }); | ||
| const projects = chatProjectsEnabled ? (projectsQuery.data ?? []) : []; |
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Surface failures from the projects query
When the projects request fails, data ?? [] converts the failure into an empty project list and no error is passed to ChatsPanel, so users see Projects (0) and may attempt to create duplicates without any indication that loading failed. Preserve and render projectsQuery.error, ideally with a retry action, instead of treating an error as a successful empty response.
AGENTS.md reference: site/AGENTS.md:L11-L11
Useful? React with 👍 / 👎.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
| const isNameValid = memoryNamePattern.test(name); | ||
| const isDescriptionValid = description.length <= 150; | ||
| const isBodyValid = new TextEncoder().encode(body).length <= 8192; |
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Require a nonblank memory description
The server normalizes the description and rejects it when empty, but this validator considers an empty or whitespace-only description valid, enabling Save and sending a request guaranteed to return 400. Include a nonblank check here and present it as field validation so both create and edit dialogs match the API contract.
Useful? React with 👍 / 👎.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
| expect( | ||
| screen.queryByRole("button", { name: "Edit" }), | ||
| ).not.toBeInTheDocument(); | ||
| expect(screen.getByRole("link", { name: "New chat" })).toBeInTheDocument(); |
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Replace DOM-presence assertions with behavior coverage
These assertions make DOM presence the test outcome, which FE1 explicitly reserves for Storybook visual coverage. Keep the auth request assertion as the Vitest behavior check and cover the permitted and denied rendered states in stories instead of using toBeInTheDocument.
AGENTS.md reference: site/AGENTS.md:L7-L7
Useful? React with 👍 / 👎.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
Sidebar project list with create, edit, and delete gated on the authcheck result, a project page at /agents/projects/:projectId, new chat in project, and move-to-project from the chat menu. Behind the chat-projects experiment.
Collapsed memory rows expand to show the description, body, and edit and delete controls. Delete failures surface an error alert.
Adds /agents/settings/memory with the personal memory toggle and the per-organization memory list, and generalizes the project memory components to serve both scopes.
Summarizes the newest successful consolidation run in one line under the memory list.
51ababa to
3f85d61
Compare
3181dc6 to
217be16
Compare
There was an error while loading. Please reload this page.
Successfully merging this pull request may close these issues.
There was an error while loading. Please reload this page.