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

Fix/traces #335

Merged
merged 4 commits into from
Jan 19, 2025
Merged

Fix/traces #335

merged 4 commits into from
Jan 19, 2025

Conversation

skull8888888
Copy link
Collaborator

@skull8888888 skull8888888 commented Jan 19, 2025

Important

Enhance workspace and project management with API updates, UI improvements, and data handling adjustments across multiple components.

  • API Changes:
    • Update GET method in route.ts to fetch workspaces and associated projects from the database, handling unauthorized access.
    • Add POST method in route.ts for creating workspaces.
  • UI Components:
    • Modify ProjectCard to update styling and remove Card component.
    • Adjust SpanCard to fix segment height calculation and button z-index.
    • Update TraceView to handle span selection and timeline width dynamically.
    • Enhance Formatter to handle YAML parsing and rendering with state management.
    • Update WorkspaceUsage to reflect new span limits for Free and Pro tiers.
  • Types:
    • Add numSpans and numEvaluations to Project type in types.ts.

This description was created by Ellipsis for b3eeb01. It will automatically update as commits are pushed.

Copy link
Contributor

@ellipsis-dev ellipsis-dev bot left a comment

Choose a reason for hiding this comment

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

❌ Changes requested. Reviewed everything up to ece78a4 in 1 minute and 50 seconds

More details
  • Looked at 269 lines of code in 7 files
  • Skipped 0 files when reviewing.
  • Skipped posting 4 drafted comments based on config settings.
1. frontend/components/traces/span-card.tsx:47
  • Draft comment:
    Good use of Math.max(0, ...) to ensure non-negative segment height. This prevents potential layout issues.
  • Reason this comment was not posted:
    Confidence changes required: 0%
    The parentY prop in SpanCard is updated to use getBoundingClientRect().y which is a good change for dynamic positioning.
2. frontend/components/traces/span-card.tsx:112
  • Draft comment:
    The z-index change from 40 to 30 might affect the stacking order of elements. Ensure this is intentional and doesn't cause UI issues.
  • Reason this comment was not posted:
    Confidence changes required: 50%
    The z-index change from 40 to 30 might affect the stacking order of elements. Ensure this is intentional and doesn't cause UI issues.
3. frontend/components/traces/trace-view.tsx:233
  • Draft comment:
    Good use of getBoundingClientRect().y for dynamic positioning of parentY. This ensures accurate layout calculations.
  • Reason this comment was not posted:
    Confidence changes required: 0%
    The parentY prop is updated to use getBoundingClientRect().y which is a good change for dynamic positioning.
4. frontend/components/ui/formatter.tsx:63
  • Draft comment:
    Consider storing the result of renderText(value) in a state variable to avoid redundant calculations and improve performance.
  • Reason this comment was not posted:
    Comment looked like it was already resolved.

Workflow ID: wflow_40KswM2hd8XfI8aO


Want Ellipsis to fix these issues? Tag @ellipsis-dev in a comment. You can customize Ellipsis with 👍 / 👎 feedback, review rules, user-specific overrides, quiet mode, and more.

})
.from(projects)
.where(eq(projects.workspaceId, workspace.id))
.groupBy(projects.id);
Copy link
Contributor

Choose a reason for hiding this comment

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

The use of groupBy(projects.id) is unnecessary here as the selected fields are already unique per project. Consider removing it to simplify the query.

Copy link
Contributor

@ellipsis-dev ellipsis-dev bot left a comment

Choose a reason for hiding this comment

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

👍 Looks good to me! Incremental review on 1fd73b9 in 21 seconds

More details
  • Looked at 25 lines of code in 2 files
  • Skipped 0 files when reviewing.
  • Skipped posting 1 drafted comments based on config settings.
1. frontend/app/api/workspaces/route.ts:51
  • Draft comment:
    Ensure that removing the groupBy clause does not affect the expected results of the query, especially if there were any aggregations or unique constraints based on project IDs.
  • Reason this comment was not posted:
    Confidence changes required: 50%
    The removal of the groupBy clause might affect the query results if there were any aggregations or expected unique results based on project IDs. However, without additional context, it's unclear if this change is correct or not.

Workflow ID: wflow_R2Jtl1y8X027RgiT


You can customize Ellipsis with 👍 / 👎 feedback, review rules, user-specific overrides, quiet mode, and more.

Copy link
Contributor

@ellipsis-dev ellipsis-dev bot left a comment

Choose a reason for hiding this comment

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

👍 Looks good to me! Incremental review on b3eeb01 in 12 seconds

More details
  • Looked at 25 lines of code in 2 files
  • Skipped 0 files when reviewing.
  • Skipped posting 1 drafted comments based on config settings.
1. frontend/components/projects/project-card.tsx:3
  • Draft comment:
    Remove the unused import of Card to clean up the code.
  • Reason this comment was not posted:
    Confidence changes required: 50%
    The import statement for 'Card' is unnecessary since it is not used in the file.

Workflow ID: wflow_a0LaPDjeQvfDXH1L


You can customize Ellipsis with 👍 / 👎 feedback, review rules, user-specific overrides, quiet mode, and more.

@skull8888888 skull8888888 merged commit 2e0aba8 into dev Jan 19, 2025
2 checks passed
@skull8888888 skull8888888 deleted the fix/traces branch January 19, 2025 22:41
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.

1 participant