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

refactor(cubesql): Improve EGraph debugger, part 3: parsing and data preparation in UI side #8934

Merged
merged 6 commits into from
Dec 6, 2024

Conversation

mcheshkov
Copy link
Member

Check List

  • Tests has been run in packages where changes made if available
  • Linter has been run for changed code
  • Tests for the changes have been added if not covered yet
  • Docs have been added / updated if required

Description of Changes Made (if issue reference is not provided)

Add proper parsing on UI side, to catch data format changes.
Move most of data preparation related to UI (like a concepts of edge or combo) to UI completely, simplify data collection on rewriter side.

Copy link

codecov bot commented Nov 8, 2024

Codecov Report

Attention: Patch coverage is 0% with 48 lines in your changes missing coverage. Please review.

Project coverage is 82.78%. Comparing base (060d666) to head (2435b7f).
Report is 1 commits behind head on master.

Files with missing lines Patch % Lines
...st/cubesql/cubesql/src/compile/rewrite/rewriter.rs 0.00% 47 Missing ⚠️
...st/cubesql/cubesql/src/compile/rewrite/analysis.rs 0.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #8934      +/-   ##
==========================================
+ Coverage   82.72%   82.78%   +0.05%     
==========================================
  Files         221      221              
  Lines       78553    78494      -59     
==========================================
- Hits        64980    64978       -2     
+ Misses      13573    13516      -57     
Flag Coverage Δ
cubesql 82.78% <0.00%> (+0.05%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@mcheshkov mcheshkov marked this pull request as ready for review November 8, 2024 15:00
@mcheshkov mcheshkov requested review from a team as code owners November 8, 2024 15:00
Copy link
Member

@KSDaemon KSDaemon left a comment

Choose a reason for hiding this comment

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

👍🏻 LGTM! Left minor note.

@@ -18,6 +18,7 @@ import type {
NodeProps,
} from 'reactflow';
import 'reactflow/dist/style.css';
import { z } from 'zod';
Copy link
Member

Choose a reason for hiding this comment

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

Probably, not a big deal but still:
We already have a joi scheme validator in our codebase, so maybe we can reuse it here too? I know, node_modules is a black hole and could hold any number of packages) but... If we can reduce and reuse...Why not?

Copy link
Member Author

Choose a reason for hiding this comment

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

I'd rather switch to zod in those places 😅

Joi does not introduce static types in TypeScript along with building parser, so one need to manually support and ensure compatibility for both. There are solutions like joi-to-typescript, but, given the usual process of working with codegen in JS, it's not very comfortable.

Also egraph debugger is a completely separate package from monorepo, so it wouldn't pollute anything with unnecessary dependencies in "usual" case, and it would install them second time even if dependencies were same.

@mcheshkov mcheshkov force-pushed the refactor-egraph-debugger-3 branch from 676b716 to 5212ee8 Compare November 13, 2024 12:13
Copy link

vercel bot commented Nov 13, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

8 Skipped Deployments
Name Status Preview Comments Updated (UTC)
examples-angular-dashboard ⬜️ Ignored (Inspect) Visit Preview Nov 27, 2024 2:01pm
examples-react-d3 ⬜️ Ignored (Inspect) Visit Preview Nov 27, 2024 2:01pm
examples-react-dashboard ⬜️ Ignored (Inspect) Visit Preview Nov 27, 2024 2:01pm
examples-react-data-table ⬜️ Ignored (Inspect) Visit Preview Nov 27, 2024 2:01pm
examples-react-highcharts ⬜️ Ignored (Inspect) Visit Preview Nov 27, 2024 2:01pm
examples-react-material-ui ⬜️ Ignored (Inspect) Visit Preview Nov 27, 2024 2:01pm
examples-react-pivot-table ⬜️ Ignored (Inspect) Visit Preview Nov 27, 2024 2:01pm
examples-vue-query-builder ⬜️ Ignored (Inspect) Visit Preview Nov 27, 2024 2:01pm

@mcheshkov mcheshkov force-pushed the refactor-egraph-debugger-3 branch from 5212ee8 to 05e20cb Compare November 15, 2024 11:45
@mcheshkov mcheshkov force-pushed the refactor-egraph-debugger-3 branch from 05e20cb to 6dcd819 Compare November 27, 2024 14:01
@mcheshkov mcheshkov force-pushed the refactor-egraph-debugger-3 branch from 6dcd819 to 2435b7f Compare December 6, 2024 12:42
@mcheshkov mcheshkov merged commit 3ca3811 into master Dec 6, 2024
78 checks passed
@mcheshkov mcheshkov deleted the refactor-egraph-debugger-3 branch December 6, 2024 13:51
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.

2 participants