-
Notifications
You must be signed in to change notification settings - Fork 14k
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
feat: Migrates TreeMap chart #23741
feat: Migrates TreeMap chart #23741
Conversation
Codecov Report
@@ Coverage Diff @@
## master #23741 +/- ##
==========================================
+ Coverage 68.42% 68.49% +0.06%
==========================================
Files 1951 1946 -5
Lines 75472 75373 -99
Branches 8219 8218 -1
==========================================
- Hits 51640 51624 -16
+ Misses 21720 21638 -82
+ Partials 2112 2111 -1
Flags with carried forward coverage won't be shown. Click here to find out more.
📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
@michael-s-molina please also 🔥 |
Hello @michael-s-molina @villebro
|
Hi @EugeneTorap. The Superset 3.0 project answers both questions. There you'll find all legacy viz migrations that were voted and approved for 3.0. SQL Lab to SPA was not proposed for 3.0. |
@rusackas Can we add |
@EugeneTorap There's a 3.0 discussion going on for this type of request. |
* specific language governing permissions and limitations | ||
* under the License. | ||
*/ | ||
describe('Visualization > Treemap', () => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I removed the test because it's not applicable anymore. By default, charts are rendered using canvas. Even if we created a test configuration to render the charts using SVG, the groupby colors are not static anymore, they suffer small variations depending on the value. This type of test is more suitable with visual regression testing using Applitools or Chromatic, which is not in the scope of this PR.
# Ensure `slice.params` and `slice.query_context`` in MySQL is MEDIUMTEXT | ||
# before migration, as the migration will save a duplicate form_data backup | ||
# which may significantly increase the size of these fields. | ||
if isinstance(op.get_bind().dialect, MySQLDialect): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It would be great (possibly before) to make sure these columns are defined as a MediumText in the model and had a corresponding migration so we wouldn't need this logic.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@michael-s-molina has there been any update to the underlying model which would then make this redundant?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@john-bodley This migration is referenced by a previous script that was created a while ago. Because of that, we need to keep this piece of code even if the models were updated later.
e3396c2
to
1eedec7
Compare
@@ -535,12 +535,6 @@ describe('Dashboard edit', () => { | |||
applyChanges(); | |||
saveChanges(); | |||
|
|||
cy.get('.treemap #rect-sum__SP_POP_TOTL').should( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These kind of tests should be handled by Applitools or Chromatic. These selectors don't exist anymore now that we're using canvas to draw the charts.
1eedec7
to
fdbcb43
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
0647d15
to
4de9528
Compare
operator: '!=' | ||
sqlExpression: null | ||
subject: communite_time | ||
- clause: WHERE |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this not over-indented?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actually, it does look right - how was this not causing problems before? 😕
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
3f24cea
to
b45898f
Compare
505121d
to
1893774
Compare
1893774
to
6bd8548
Compare
SUMMARY
This PR migrates the Treemap chart to the ECharts version.
Note a previous migration existed however the legacy chart wasn't removed and thus new legacy Treemap charts could have been created.
AFTER SCREENSHOT
TESTING INSTRUCTIONS
1 - Make sure all Treemap (legacy) charts were converted to Treemap
2 - Make sure Treemap (legacy) is not available anymore in the viz picker
3 - Make sure that it's possible to revert the migration by executing superset db downgrade and reverting this PR
ADDITIONAL INFORMATION