You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by GitBox <gi...@apache.org> on 2022/02/07 16:46:36 UTC

[GitHub] [superset] geido opened a new pull request #18603: fix(Explore): Force different color for same metrics in Mixed Time-Series

geido opened a new pull request #18603:
URL: https://github.com/apache/superset/pull/18603


   ### SUMMARY
   This PR forces the `colorScale` to return a different color when the same metrics are found across the two queries in order to apply contrasting colors. It appends a `-A` to the name of the metric in series A when found in series B so that the `colorScale` will treat it as a different value.
   
   ### BEFORE
   
   https://user-images.githubusercontent.com/60598000/152832268-17552fbb-5bdd-4abc-ae8c-f6b347bb4bce.mp4
   
   ### AFTER
   
   https://user-images.githubusercontent.com/60598000/152831369-b0953035-1b1e-4cf0-ab59-92a2f01dba6d.mp4
   
   
   ### TESTING INSTRUCTIONS
   1. Choose a mixed time-series chart
   2. Date added in Time with a Grain: Month
   3. Add the same metrics A and B
   4. Customize -> Create 1 metric as a Line and the other as a Bar
   5. Make sure different colors applied
   
   ### ADDITIONAL INFORMATION
   <!--- Check any relevant boxes with "x" -->
   <!--- HINT: Include "Fixes #nnn" if you are fixing an existing issue -->
   - [ ] Has associated issue:
   - [ ] Required feature flags:
   - [ ] Changes UI
   - [ ] Includes DB Migration (follow approval process in [SIP-59](https://github.com/apache/superset/issues/13351))
     - [ ] Migration is atomic, supports rollback & is backwards-compatible
     - [ ] Confirm DB migration upgrade and downgrade tested
     - [ ] Runtime estimates and downtime expectations provided
   - [ ] Introduces new feature or API
   - [ ] Removes existing feature or API
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] stephenLYZ commented on a change in pull request #18603: fix(Explore): Force different color for same metrics in Mixed Time-Series

Posted by GitBox <gi...@apache.org>.
stephenLYZ commented on a change in pull request #18603:
URL: https://github.com/apache/superset/pull/18603#discussion_r801290739



##########
File path: superset-frontend/plugins/plugin-chart-echarts/src/Timeseries/transformers.ts
##########
@@ -84,6 +84,7 @@ export function transformSeries(
     thresholdValues?: number[];
     richTooltip?: boolean;
   },
+  rawSeriesB?: SeriesOption[],

Review comment:
       I think it makes sense. However, I have a concern that since the label color is specified by colorScale function, there may be some problem if user wants to set the custom label colors. User may not know how to set the label color of the chart B in this case.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] stephenLYZ commented on a change in pull request #18603: fix(Explore): Force different color for same metrics in Mixed Time-Series

Posted by GitBox <gi...@apache.org>.
stephenLYZ commented on a change in pull request #18603:
URL: https://github.com/apache/superset/pull/18603#discussion_r801290739



##########
File path: superset-frontend/plugins/plugin-chart-echarts/src/Timeseries/transformers.ts
##########
@@ -84,6 +84,7 @@ export function transformSeries(
     thresholdValues?: number[];
     richTooltip?: boolean;
   },
+  rawSeriesB?: SeriesOption[],

Review comment:
       I think it makes sense. However, I have a concern that since the label value is specified by colorScale function, there may be some problem if user wants to set the custom label colors. User may not know how to set the label color of the chart B in this case.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] codecov[bot] commented on pull request #18603: fix(Explore): Force different color for same metrics in Mixed Time-Series

Posted by GitBox <gi...@apache.org>.
codecov[bot] commented on pull request #18603:
URL: https://github.com/apache/superset/pull/18603#issuecomment-1031732620


   # [Codecov](https://codecov.io/gh/apache/superset/pull/18603?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) Report
   > Merging [#18603](https://codecov.io/gh/apache/superset/pull/18603?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (a559e10) into [master](https://codecov.io/gh/apache/superset/commit/aa21a963a6137a1d29ad422c6d7bf79839bc7078?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (aa21a96) will **decrease** coverage by `0.00%`.
   > The diff coverage is `25.00%`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/superset/pull/18603/graphs/tree.svg?width=650&height=150&src=pr&token=KsB0fHcx6l&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)](https://codecov.io/gh/apache/superset/pull/18603?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   
   ```diff
   @@            Coverage Diff             @@
   ##           master   #18603      +/-   ##
   ==========================================
   - Coverage   66.30%   66.30%   -0.01%     
   ==========================================
     Files        1595     1595              
     Lines       62630    62633       +3     
     Branches     6308     6310       +2     
   ==========================================
   + Hits        41528    41529       +1     
   - Misses      19453    19454       +1     
   - Partials     1649     1650       +1     
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | javascript | `51.37% <25.00%> (-0.01%)` | :arrow_down: |
   
   Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#carryforward-flags-in-the-pull-request-comment) to find out more.
   
   | [Impacted Files](https://codecov.io/gh/apache/superset/pull/18603?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) | Coverage Δ | |
   |---|---|---|
   | [...hart-echarts/src/MixedTimeseries/transformProps.ts](https://codecov.io/gh/apache/superset/pull/18603/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQtZnJvbnRlbmQvcGx1Z2lucy9wbHVnaW4tY2hhcnQtZWNoYXJ0cy9zcmMvTWl4ZWRUaW1lc2VyaWVzL3RyYW5zZm9ybVByb3BzLnRz) | `0.00% <0.00%> (ø)` | |
   | [...lugin-chart-echarts/src/Timeseries/transformers.ts](https://codecov.io/gh/apache/superset/pull/18603/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQtZnJvbnRlbmQvcGx1Z2lucy9wbHVnaW4tY2hhcnQtZWNoYXJ0cy9zcmMvVGltZXNlcmllcy90cmFuc2Zvcm1lcnMudHM=) | `50.40% <33.33%> (-0.43%)` | :arrow_down: |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/superset/pull/18603?src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/superset/pull/18603?src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation). Last update [aa21a96...a559e10](https://codecov.io/gh/apache/superset/pull/18603?src=pr&el=lastupdated&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation).
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] stephenLYZ commented on a change in pull request #18603: fix(Explore): Force different color for same metrics in Mixed Time-Series

Posted by GitBox <gi...@apache.org>.
stephenLYZ commented on a change in pull request #18603:
URL: https://github.com/apache/superset/pull/18603#discussion_r801293302



##########
File path: superset-frontend/plugins/plugin-chart-echarts/src/Timeseries/transformers.ts
##########
@@ -147,8 +148,14 @@ export function transformSeries(
   } else {
     plotType = seriesType === 'bar' ? 'bar' : 'line';
   }
+  const rawSeriesBHasMetric = !!(rawSeriesB || []).find(
+    (serie: SeriesOption) => serie.name === forecastSeries.name,

Review comment:
       here may need to use the series name which extracts forecast context.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] geido commented on pull request #18603: fix(Explore): Force different color for same metrics in Mixed Time-Series

Posted by GitBox <gi...@apache.org>.
geido commented on pull request #18603:
URL: https://github.com/apache/superset/pull/18603#issuecomment-1032680789


   @stephenLYZ @zhaoyongjie I updated the PR in a way that conforms with the way the chart labels behave, by adding a suffix `(1)` to the end of the label name, as you can see in the screenshot. That's standard behaviour.
   
   <img width="1680" alt="Screen Shot 2022-02-08 at 16 33 30" src="https://user-images.githubusercontent.com/60598000/153008974-a4980062-94f3-4cfc-a666-2cf581592d00.png">
   
   With this update the user can now customize the label colors fully and it should still guarantee that same metrics across different queries, use different colors by default. Please watch the video below that shows the new behaviour.
   
   https://user-images.githubusercontent.com/60598000/153009181-8161365e-e0cc-4fe2-a477-5db853b2f272.mp4
   
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] codecov[bot] edited a comment on pull request #18603: fix(Explore): Force different color for same metrics in Mixed Time-Series

Posted by GitBox <gi...@apache.org>.
codecov[bot] edited a comment on pull request #18603:
URL: https://github.com/apache/superset/pull/18603#issuecomment-1031732620


   # [Codecov](https://codecov.io/gh/apache/superset/pull/18603?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) Report
   > Merging [#18603](https://codecov.io/gh/apache/superset/pull/18603?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (6b0f3c7) into [master](https://codecov.io/gh/apache/superset/commit/aa21a963a6137a1d29ad422c6d7bf79839bc7078?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (aa21a96) will **decrease** coverage by `0.01%`.
   > The diff coverage is `50.00%`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/superset/pull/18603/graphs/tree.svg?width=650&height=150&src=pr&token=KsB0fHcx6l&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)](https://codecov.io/gh/apache/superset/pull/18603?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   
   ```diff
   @@            Coverage Diff             @@
   ##           master   #18603      +/-   ##
   ==========================================
   - Coverage   66.30%   66.29%   -0.02%     
   ==========================================
     Files        1595     1595              
     Lines       62630    62596      -34     
     Branches     6308     6304       -4     
   ==========================================
   - Hits        41528    41499      -29     
   + Misses      19453    19452       -1     
   + Partials     1649     1645       -4     
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | javascript | `51.33% <50.00%> (-0.04%)` | :arrow_down: |
   
   Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#carryforward-flags-in-the-pull-request-comment) to find out more.
   
   | [Impacted Files](https://codecov.io/gh/apache/superset/pull/18603?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) | Coverage Δ | |
   |---|---|---|
   | [...hart-echarts/src/MixedTimeseries/transformProps.ts](https://codecov.io/gh/apache/superset/pull/18603/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQtZnJvbnRlbmQvcGx1Z2lucy9wbHVnaW4tY2hhcnQtZWNoYXJ0cy9zcmMvTWl4ZWRUaW1lc2VyaWVzL3RyYW5zZm9ybVByb3BzLnRz) | `0.00% <0.00%> (ø)` | |
   | [...lugin-chart-echarts/src/Timeseries/transformers.ts](https://codecov.io/gh/apache/superset/pull/18603/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQtZnJvbnRlbmQvcGx1Z2lucy9wbHVnaW4tY2hhcnQtZWNoYXJ0cy9zcmMvVGltZXNlcmllcy90cmFuc2Zvcm1lcnMudHM=) | `51.23% <100.00%> (+0.40%)` | :arrow_up: |
   | [...tend/src/SqlLab/components/ColumnElement/index.tsx](https://codecov.io/gh/apache/superset/pull/18603/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL1NxbExhYi9jb21wb25lbnRzL0NvbHVtbkVsZW1lbnQvaW5kZXgudHN4) | `93.33% <0.00%> (-0.42%)` | :arrow_down: |
   | [...frontend/src/SqlLab/components/ResultSet/index.tsx](https://codecov.io/gh/apache/superset/pull/18603/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL1NxbExhYi9jb21wb25lbnRzL1Jlc3VsdFNldC9pbmRleC50c3g=) | `50.73% <0.00%> (ø)` | |
   | [...RUD/data/database/DatabaseModal/SqlAlchemyForm.tsx](https://codecov.io/gh/apache/superset/pull/18603/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL3ZpZXdzL0NSVUQvZGF0YS9kYXRhYmFzZS9EYXRhYmFzZU1vZGFsL1NxbEFsY2hlbXlGb3JtLnRzeA==) | `66.66% <0.00%> (ø)` | |
   | [.../src/explore/components/controls/BoundsControl.jsx](https://codecov.io/gh/apache/superset/pull/18603/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2V4cGxvcmUvY29tcG9uZW50cy9jb250cm9scy9Cb3VuZHNDb250cm9sLmpzeA==) | | |
   | [...c/SqlLab/components/ExploreResultsButton/index.jsx](https://codecov.io/gh/apache/superset/pull/18603/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL1NxbExhYi9jb21wb25lbnRzL0V4cGxvcmVSZXN1bHRzQnV0dG9uL2luZGV4LmpzeA==) | | |
   | [.../src/explore/components/controls/BoundsControl.tsx](https://codecov.io/gh/apache/superset/pull/18603/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2V4cGxvcmUvY29tcG9uZW50cy9jb250cm9scy9Cb3VuZHNDb250cm9sLnRzeA==) | `88.88% <0.00%> (ø)` | |
   | [...c/SqlLab/components/ExploreResultsButton/index.tsx](https://codecov.io/gh/apache/superset/pull/18603/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL1NxbExhYi9jb21wb25lbnRzL0V4cGxvcmVSZXN1bHRzQnV0dG9uL2luZGV4LnRzeA==) | `100.00% <0.00%> (ø)` | |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/superset/pull/18603?src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/superset/pull/18603?src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation). Last update [aa21a96...6b0f3c7](https://codecov.io/gh/apache/superset/pull/18603?src=pr&el=lastupdated&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation).
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] stephenLYZ commented on a change in pull request #18603: fix(Explore): Force different color for same metrics in Mixed Time-Series

Posted by GitBox <gi...@apache.org>.
stephenLYZ commented on a change in pull request #18603:
URL: https://github.com/apache/superset/pull/18603#discussion_r801293302



##########
File path: superset-frontend/plugins/plugin-chart-echarts/src/Timeseries/transformers.ts
##########
@@ -147,8 +148,14 @@ export function transformSeries(
   } else {
     plotType = seriesType === 'bar' ? 'bar' : 'line';
   }
+  const rawSeriesBHasMetric = !!(rawSeriesB || []).find(
+    (serie: SeriesOption) => serie.name === forecastSeries.name,

Review comment:
       here may need to use the series name after extracting forecast context.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] zhaoyongjie commented on a change in pull request #18603: fix(Explore): Force different color for same metrics in Mixed Time-Series

Posted by GitBox <gi...@apache.org>.
zhaoyongjie commented on a change in pull request #18603:
URL: https://github.com/apache/superset/pull/18603#discussion_r801240112



##########
File path: superset-frontend/plugins/plugin-chart-echarts/src/Timeseries/transformers.ts
##########
@@ -147,8 +148,14 @@ export function transformSeries(
   } else {
     plotType = seriesType === 'bar' ? 'bar' : 'line';
   }
+  const rawSeriesBHasMetric = !!(rawSeriesB || []).find(
+    (serie: SeriesOption) => serie.name === forecastSeries.name,
+  );
+  // forcing the colorScale to return a different color for same metrics across different queries
   const itemStyle = {
-    color: colorScale(forecastSeries.name),
+    color: colorScale(
+      rawSeriesBHasMetric ? `${forecastSeries.name}-A` : forecastSeries.name,
+    ),

Review comment:
       ```suggestion
       color: colorScale(seriesHash || forecastSeries.name),
   ```

##########
File path: superset-frontend/plugins/plugin-chart-echarts/src/MixedTimeseries/transformProps.ts
##########
@@ -165,19 +165,25 @@ export default function transformProps(
   );
 
   rawSeriesA.forEach(entry => {
-    const transformedSeries = transformSeries(entry, colorScale, {
-      area,
-      markerEnabled,
-      markerSize,
-      areaOpacity: opacity,
-      seriesType,
-      showValue,
-      stack,
-      yAxisIndex,
-      filterState,
-    });
+    const transformedSeries = transformSeries(
+      entry,
+      colorScale,
+      {
+        area,
+        markerEnabled,
+        markerSize,
+        areaOpacity: opacity,
+        seriesType,
+        showValue,
+        stack,
+        yAxisIndex,
+        filterState,
+      },
+      rawSeriesB,

Review comment:
       ```suggestion
           filterState,
           seriesHash: `query A ${metric name} ${series name}`  <---- make a hash key for different series
         },
   ```

##########
File path: superset-frontend/plugins/plugin-chart-echarts/src/Timeseries/transformers.ts
##########
@@ -84,6 +84,7 @@ export function transformSeries(
     thresholdValues?: number[];
     richTooltip?: boolean;
   },
+  rawSeriesB?: SeriesOption[],

Review comment:
       transformSeries means how to generate echart SeriesOption from form_data. we can set different attributes on the different series to resolve this issue.
   
   ```suggestion
      richTooltip?: boolean;
      seriesHash?: string;
     },
   ```




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] codecov[bot] edited a comment on pull request #18603: fix(Explore): Force different color for same metrics in Mixed Time-Series

Posted by GitBox <gi...@apache.org>.
codecov[bot] edited a comment on pull request #18603:
URL: https://github.com/apache/superset/pull/18603#issuecomment-1031732620


   # [Codecov](https://codecov.io/gh/apache/superset/pull/18603?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) Report
   > Merging [#18603](https://codecov.io/gh/apache/superset/pull/18603?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (a559e10) into [master](https://codecov.io/gh/apache/superset/commit/aa21a963a6137a1d29ad422c6d7bf79839bc7078?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (aa21a96) will **decrease** coverage by `0.00%`.
   > The diff coverage is `25.00%`.
   
   > :exclamation: Current head a559e10 differs from pull request most recent head 754c334. Consider uploading reports for the commit 754c334 to get more accurate results
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/superset/pull/18603/graphs/tree.svg?width=650&height=150&src=pr&token=KsB0fHcx6l&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)](https://codecov.io/gh/apache/superset/pull/18603?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   
   ```diff
   @@            Coverage Diff             @@
   ##           master   #18603      +/-   ##
   ==========================================
   - Coverage   66.30%   66.30%   -0.01%     
   ==========================================
     Files        1595     1595              
     Lines       62630    62633       +3     
     Branches     6308     6310       +2     
   ==========================================
   + Hits        41528    41529       +1     
   - Misses      19453    19454       +1     
   - Partials     1649     1650       +1     
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | javascript | `51.37% <25.00%> (-0.01%)` | :arrow_down: |
   
   Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#carryforward-flags-in-the-pull-request-comment) to find out more.
   
   | [Impacted Files](https://codecov.io/gh/apache/superset/pull/18603?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) | Coverage Δ | |
   |---|---|---|
   | [...hart-echarts/src/MixedTimeseries/transformProps.ts](https://codecov.io/gh/apache/superset/pull/18603/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQtZnJvbnRlbmQvcGx1Z2lucy9wbHVnaW4tY2hhcnQtZWNoYXJ0cy9zcmMvTWl4ZWRUaW1lc2VyaWVzL3RyYW5zZm9ybVByb3BzLnRz) | `0.00% <0.00%> (ø)` | |
   | [...lugin-chart-echarts/src/Timeseries/transformers.ts](https://codecov.io/gh/apache/superset/pull/18603/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQtZnJvbnRlbmQvcGx1Z2lucy9wbHVnaW4tY2hhcnQtZWNoYXJ0cy9zcmMvVGltZXNlcmllcy90cmFuc2Zvcm1lcnMudHM=) | `50.40% <33.33%> (-0.43%)` | :arrow_down: |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/superset/pull/18603?src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/superset/pull/18603?src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation). Last update [aa21a96...754c334](https://codecov.io/gh/apache/superset/pull/18603?src=pr&el=lastupdated&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation).
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] codecov[bot] edited a comment on pull request #18603: fix(Explore): Force different color for same metrics in Mixed Time-Series

Posted by GitBox <gi...@apache.org>.
codecov[bot] edited a comment on pull request #18603:
URL: https://github.com/apache/superset/pull/18603#issuecomment-1031732620


   # [Codecov](https://codecov.io/gh/apache/superset/pull/18603?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) Report
   > Merging [#18603](https://codecov.io/gh/apache/superset/pull/18603?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (374089f) into [master](https://codecov.io/gh/apache/superset/commit/aa21a963a6137a1d29ad422c6d7bf79839bc7078?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (aa21a96) will **decrease** coverage by `0.00%`.
   > The diff coverage is `76.74%`.
   
   > :exclamation: Current head 374089f differs from pull request most recent head 754c334. Consider uploading reports for the commit 754c334 to get more accurate results
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/superset/pull/18603/graphs/tree.svg?width=650&height=150&src=pr&token=KsB0fHcx6l&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)](https://codecov.io/gh/apache/superset/pull/18603?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   
   ```diff
   @@            Coverage Diff             @@
   ##           master   #18603      +/-   ##
   ==========================================
   - Coverage   66.30%   66.30%   -0.01%     
   ==========================================
     Files        1595     1595              
     Lines       62630    62633       +3     
     Branches     6308     6311       +3     
   ==========================================
   - Hits        41528    41527       -1     
   - Misses      19453    19457       +4     
     Partials     1649     1649              
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | javascript | `51.36% <76.74%> (-0.01%)` | :arrow_down: |
   
   Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#carryforward-flags-in-the-pull-request-comment) to find out more.
   
   | [Impacted Files](https://codecov.io/gh/apache/superset/pull/18603?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) | Coverage Δ | |
   |---|---|---|
   | [...hart-echarts/src/MixedTimeseries/transformProps.ts](https://codecov.io/gh/apache/superset/pull/18603/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQtZnJvbnRlbmQvcGx1Z2lucy9wbHVnaW4tY2hhcnQtZWNoYXJ0cy9zcmMvTWl4ZWRUaW1lc2VyaWVzL3RyYW5zZm9ybVByb3BzLnRz) | `0.00% <0.00%> (ø)` | |
   | [...lugin-chart-echarts/src/Timeseries/transformers.ts](https://codecov.io/gh/apache/superset/pull/18603/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQtZnJvbnRlbmQvcGx1Z2lucy9wbHVnaW4tY2hhcnQtZWNoYXJ0cy9zcmMvVGltZXNlcmllcy90cmFuc2Zvcm1lcnMudHM=) | `49.60% <20.00%> (-1.24%)` | :arrow_down: |
   | [...RUD/data/database/DatabaseModal/SqlAlchemyForm.tsx](https://codecov.io/gh/apache/superset/pull/18603/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL3ZpZXdzL0NSVUQvZGF0YS9kYXRhYmFzZS9EYXRhYmFzZU1vZGFsL1NxbEFsY2hlbXlGb3JtLnRzeA==) | `66.66% <77.77%> (ø)` | |
   | [.../src/explore/components/controls/BoundsControl.tsx](https://codecov.io/gh/apache/superset/pull/18603/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2V4cGxvcmUvY29tcG9uZW50cy9jb250cm9scy9Cb3VuZHNDb250cm9sLnRzeA==) | `88.88% <88.88%> (ø)` | |
   | [...tend/src/SqlLab/components/ColumnElement/index.tsx](https://codecov.io/gh/apache/superset/pull/18603/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL1NxbExhYi9jb21wb25lbnRzL0NvbHVtbkVsZW1lbnQvaW5kZXgudHN4) | `93.33% <100.00%> (-0.42%)` | :arrow_down: |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/superset/pull/18603?src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/superset/pull/18603?src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation). Last update [aa21a96...754c334](https://codecov.io/gh/apache/superset/pull/18603?src=pr&el=lastupdated&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation).
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] codecov[bot] edited a comment on pull request #18603: fix(Explore): Force different color for same metrics in Mixed Time-Series

Posted by GitBox <gi...@apache.org>.
codecov[bot] edited a comment on pull request #18603:
URL: https://github.com/apache/superset/pull/18603#issuecomment-1031732620


   # [Codecov](https://codecov.io/gh/apache/superset/pull/18603?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) Report
   > Merging [#18603](https://codecov.io/gh/apache/superset/pull/18603?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (374089f) into [master](https://codecov.io/gh/apache/superset/commit/aa21a963a6137a1d29ad422c6d7bf79839bc7078?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (aa21a96) will **decrease** coverage by `0.00%`.
   > The diff coverage is `76.74%`.
   
   > :exclamation: Current head 374089f differs from pull request most recent head 6b0f3c7. Consider uploading reports for the commit 6b0f3c7 to get more accurate results
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/superset/pull/18603/graphs/tree.svg?width=650&height=150&src=pr&token=KsB0fHcx6l&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)](https://codecov.io/gh/apache/superset/pull/18603?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   
   ```diff
   @@            Coverage Diff             @@
   ##           master   #18603      +/-   ##
   ==========================================
   - Coverage   66.30%   66.30%   -0.01%     
   ==========================================
     Files        1595     1595              
     Lines       62630    62633       +3     
     Branches     6308     6311       +3     
   ==========================================
   - Hits        41528    41527       -1     
   - Misses      19453    19457       +4     
     Partials     1649     1649              
   ```
   
   | Flag | Coverage Δ | |
   |---|---|---|
   | javascript | `51.36% <76.74%> (-0.01%)` | :arrow_down: |
   
   Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#carryforward-flags-in-the-pull-request-comment) to find out more.
   
   | [Impacted Files](https://codecov.io/gh/apache/superset/pull/18603?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) | Coverage Δ | |
   |---|---|---|
   | [...hart-echarts/src/MixedTimeseries/transformProps.ts](https://codecov.io/gh/apache/superset/pull/18603/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQtZnJvbnRlbmQvcGx1Z2lucy9wbHVnaW4tY2hhcnQtZWNoYXJ0cy9zcmMvTWl4ZWRUaW1lc2VyaWVzL3RyYW5zZm9ybVByb3BzLnRz) | `0.00% <0.00%> (ø)` | |
   | [...lugin-chart-echarts/src/Timeseries/transformers.ts](https://codecov.io/gh/apache/superset/pull/18603/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQtZnJvbnRlbmQvcGx1Z2lucy9wbHVnaW4tY2hhcnQtZWNoYXJ0cy9zcmMvVGltZXNlcmllcy90cmFuc2Zvcm1lcnMudHM=) | `49.60% <20.00%> (-1.24%)` | :arrow_down: |
   | [...RUD/data/database/DatabaseModal/SqlAlchemyForm.tsx](https://codecov.io/gh/apache/superset/pull/18603/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL3ZpZXdzL0NSVUQvZGF0YS9kYXRhYmFzZS9EYXRhYmFzZU1vZGFsL1NxbEFsY2hlbXlGb3JtLnRzeA==) | `66.66% <77.77%> (ø)` | |
   | [.../src/explore/components/controls/BoundsControl.tsx](https://codecov.io/gh/apache/superset/pull/18603/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL2V4cGxvcmUvY29tcG9uZW50cy9jb250cm9scy9Cb3VuZHNDb250cm9sLnRzeA==) | `88.88% <88.88%> (ø)` | |
   | [...tend/src/SqlLab/components/ColumnElement/index.tsx](https://codecov.io/gh/apache/superset/pull/18603/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-c3VwZXJzZXQtZnJvbnRlbmQvc3JjL1NxbExhYi9jb21wb25lbnRzL0NvbHVtbkVsZW1lbnQvaW5kZXgudHN4) | `93.33% <100.00%> (-0.42%)` | :arrow_down: |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/superset/pull/18603?src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/superset/pull/18603?src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation). Last update [aa21a96...6b0f3c7](https://codecov.io/gh/apache/superset/pull/18603?src=pr&el=lastupdated&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation).
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] geido merged pull request #18603: fix(Explore): Force different color for same metrics in Mixed Time-Series

Posted by GitBox <gi...@apache.org>.
geido merged pull request #18603:
URL: https://github.com/apache/superset/pull/18603


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] zhaoyongjie commented on a change in pull request #18603: fix(Explore): Force different color for same metrics in Mixed Time-Series

Posted by GitBox <gi...@apache.org>.
zhaoyongjie commented on a change in pull request #18603:
URL: https://github.com/apache/superset/pull/18603#discussion_r801319448



##########
File path: superset-frontend/plugins/plugin-chart-echarts/src/Timeseries/transformers.ts
##########
@@ -84,6 +84,7 @@ export function transformSeries(
     thresholdValues?: number[];
     richTooltip?: boolean;
   },
+  rawSeriesB?: SeriesOption[],

Review comment:
       > I think it makes sense. However, I have a concern that since the label color is specified by colorScale function, there may be some problem if user wants to set the custom label colors.
   
   Good question! we need to apply a customize color panel before apply random string.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] stephenLYZ commented on a change in pull request #18603: fix(Explore): Force different color for same metrics in Mixed Time-Series

Posted by GitBox <gi...@apache.org>.
stephenLYZ commented on a change in pull request #18603:
URL: https://github.com/apache/superset/pull/18603#discussion_r801290739



##########
File path: superset-frontend/plugins/plugin-chart-echarts/src/Timeseries/transformers.ts
##########
@@ -84,6 +84,7 @@ export function transformSeries(
     thresholdValues?: number[];
     richTooltip?: boolean;
   },
+  rawSeriesB?: SeriesOption[],

Review comment:
       I think it makes sense. However, I have a concern that since the label color is specified by colorScale function, there may be some problem if user wants to set the custom label colors.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


[GitHub] [superset] stephenLYZ commented on a change in pull request #18603: fix(Explore): Force different color for same metrics in Mixed Time-Series

Posted by GitBox <gi...@apache.org>.
stephenLYZ commented on a change in pull request #18603:
URL: https://github.com/apache/superset/pull/18603#discussion_r801277825



##########
File path: superset-frontend/plugins/plugin-chart-echarts/src/Timeseries/transformers.ts
##########
@@ -147,8 +148,14 @@ export function transformSeries(
   } else {
     plotType = seriesType === 'bar' ? 'bar' : 'line';
   }
+  const rawSeriesBHasMetric = !!(rawSeriesB || []).find(
+    (serie: SeriesOption) => serie.name === forecastSeries.name,

Review comment:
       Here may need to use the series name after extracting forecast context.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org