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

[SIP-5] Refactor Time Series Table #5775

Merged
merged 11 commits into from
Sep 13, 2018
Merged

Conversation

kristw
Copy link
Contributor

@kristw kristw commented Aug 29, 2018

  • Extract slice and formData
  • Break rendering into smaller pieces for readability and ease of debugging.
  • Sort out what each row is (metric or column, object or string). Some variables renamed for clarity.

Verify same slice on production and produce the same result.

@kristw kristw changed the title Refactor Time Series Table [SIP-5] Refactor Time Series Table Aug 29, 2018
@codecov-io
Copy link

codecov-io commented Aug 29, 2018

Codecov Report

Merging #5775 into master will decrease coverage by 0.1%.
The diff coverage is 0%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #5775      +/-   ##
==========================================
- Coverage   63.73%   63.63%   -0.11%     
==========================================
  Files         374      375       +1     
  Lines       23325    23363      +38     
  Branches     2607     2618      +11     
==========================================
  Hits        14867    14867              
- Misses       8445     8483      +38     
  Partials       13       13
Impacted Files Coverage Δ
.../assets/src/visualizations/TimeTable/TimeTable.jsx 0% <0%> (ø)
...s/src/visualizations/TimeTable/FormattedNumber.jsx 0% <0%> (ø)
...ets/src/visualizations/TimeTable/SparklineCell.jsx 0% <0%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update c82cea3...29cdd01. Read the comment docs.

Copy link
Contributor

@williaster williaster left a comment

Choose a reason for hiding this comment

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

LGTM!

This is so much more readable, thanks for taking the time for that!

class TimeTable extends React.PureComponent {
renderLeftCell(row) {
const { rowType, url } = this.props;
// const context = { ...fd, metric };
Copy link
Contributor

Choose a reason for hiding this comment

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

remove?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Does the url templating need anything other than the metric?
The commented was the original code and I was not sure if the url template wants something else from formData.

Copy link
Contributor

Choose a reason for hiding this comment

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

Ohh I see. I think Michelle knows more about templating or @mistercrunch

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Hi @michellethomas , we would love your thoughts about the url template in time series table.

Copy link
Contributor

Choose a reason for hiding this comment

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

I think it's was created to be used with metric, I can't think of anything else in formData that would be useful in the url. If you want to be sure, we can query charts that use this feature.

@williaster
Copy link
Contributor

@kristw is this one ready to merge when the build passes?

@kristw
Copy link
Contributor Author

kristw commented Sep 13, 2018

Yes, it is ready.

@williaster williaster merged commit 7098ada into apache:master Sep 13, 2018
@kristw kristw deleted the kristw-time-table branch September 13, 2018 21:25
betodealmeida pushed a commit to lyft/incubator-superset that referenced this pull request Oct 12, 2018
* Break TimeTable into smaller pieces

* extract function to compute color

* Handle height and scrollbar

* sort out isGroupBy

* Set default values

* Specify proptypes for data

* rename fields and update proptypes

* Add default props

* remove commented line

* swap import
@kaitorecca
Copy link

kaitorecca commented Nov 13, 2018

Then this one maybe the reason to break the Time Series Table features from version 0.28.0 :(

@mistercrunch mistercrunch added 🏷️ bot A label used by `supersetbot` to keep track of which PR where auto-tagged with release labels 🚢 0.28.0 labels Feb 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🏷️ bot A label used by `supersetbot` to keep track of which PR where auto-tagged with release labels 🚢 0.28.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants