fix(studio): Code agent link issues and blocked action menu on fileset header#602
fix(studio): Code agent link issues and blocked action menu on fileset header#602htolentino-nvidia wants to merge 1 commit into
Conversation
Signed-off-by: Henrique Tolentino <htolentino@nvidia.com>
50b53cf to
f997b9b
Compare
📝 WalkthroughWalkthroughStudio link generation now namespaces the ChangesNamespaced Fileset Link Generation
Parquet File Preview and Header Styling
Sequence Diagram(s)sequenceDiagram
participant Caller
participant buildStudioLinkHrefFromInput
participant NAMESPACED_FILESET_DESTINATIONS
participant URLEncoder
Caller->>buildStudioLinkHrefFromInput: request href(destination, name, workspace)
buildStudioLinkHrefFromInput->>NAMESPACED_FILESET_DESTINATIONS: check destination membership
alt destination namespaced and name lacks "/"
buildStudioLinkHrefFromInput->>buildStudioLinkHrefFromInput: prefix workspace to name
end
buildStudioLinkHrefFromInput->>URLEncoder: encode resolved name
URLEncoder-->>Caller: encoded href with {name} substituted
Possibly related PRs
Suggested reviewers: 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Comment |
There was a problem hiding this comment.
🧹 Nitpick comments (1)
web/packages/common/src/components/FileContentPreview/FileContentPreview.test.tsx (1)
168-187: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick winAdd edge-case coverage for parquet parsing.
Only the happy path (uniform, valid JSON rows) is tested. Given trace files can contain malformed lines or scalar/non-object JSON (per
buildRowsAndKeysFromJsonlSample's raw-line/scalar fallback paths), consider adding tests for: a line that failsJSON.parse, a non-object JSON value, and empty content (fallback to code editor).🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@web/packages/common/src/components/FileContentPreview/FileContentPreview.test.tsx` around lines 168 - 187, Add edge-case tests to FileContentPreview.test.tsx around the parquet/JSONL parsing path, since only the happy path is covered today. Extend the existing FileContentPreview and buildRowsAndKeysFromJsonlSample coverage to verify a malformed line that fails JSON.parse, a scalar/non-object JSON value, and empty content. Assert the raw-line/scalar fallback behavior and that empty content renders the code editor fallback rather than a table.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Nitpick comments:
In
`@web/packages/common/src/components/FileContentPreview/FileContentPreview.test.tsx`:
- Around line 168-187: Add edge-case tests to FileContentPreview.test.tsx around
the parquet/JSONL parsing path, since only the happy path is covered today.
Extend the existing FileContentPreview and buildRowsAndKeysFromJsonlSample
coverage to verify a malformed line that fails JSON.parse, a scalar/non-object
JSON value, and empty content. Assert the raw-line/scalar fallback behavior and
that empty content renders the code editor fallback rather than a table.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Enterprise
Run ID: 8fe02cef-2e33-4345-b7fe-42575f6863a7
📒 Files selected for processing (7)
services/studio/src/nmp/studio/studio_links.pyservices/studio/tests/unit/test_coding_agents.pyweb/packages/common/src/components/FileContentPreview/FileContentPreview.test.tsxweb/packages/common/src/components/FileContentPreview/index.tsxweb/packages/studio/src/components/FilesetFilePreviewPanel/components/FilesetFilePreviewHeader/index.tsxweb/packages/studio/src/routes/agents/ClaudeCodeChatRoute/artifacts.test.tsweb/packages/studio/src/routes/agents/ClaudeCodeChatRoute/artifacts.ts
|
@CodeRabbit review it now |
|
The PR description image shows a dark-themed file viewer displaying
✅ Action performedReview finished.
|
|
| })); | ||
|
|
||
| return ( | ||
| <div className="h-full p-4"> |
There was a problem hiding this comment.
nit: Block instead of div here?
| <Flex justify="between" align="center" gap="density-sm" className="shrink-0 w-full"> | ||
| <Flex gap="density-sm" align="center" className="min-w-0"> | ||
| <FolderOpen width={16} height={16} /> | ||
| <Flex justify="between" align="center" gap="density-sm" className="shrink-0 w-full pr-28"> |
There was a problem hiding this comment.
pr-28? Seems like you'd want a set value instead at that width like pr-[112px]?
This PR aims to fix Code Agent links to filesets, fileset file headers blocking the action menu and allowing parquet files to be rendered as tables.
Fileset header Issue:

Summary by CodeRabbit
New Features
Bug Fixes
Style