You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by "justinpark (via GitHub)" <gi...@apache.org> on 2026/03/13 18:21:10 UTC

[I] Show "multiple" offset metrics in a same dashed lines [superset]

justinpark opened a new issue, #38639:
URL: https://github.com/apache/superset/issues/38639

   ### Bug description
   
   1. Create a line chart
   2. Set multiple time shift (i.e. 1 year ago, 2 year ago, 3 year ago)
   3. Each time shift line is represented with the same color and dashed style, making it difficult to distinguish between them.
   
   
   ### Screenshots/recordings
   
   
   <img width="732" height="904" alt="Image" src="https://github.com/user-attachments/assets/c6894e9f-a63c-41e4-9cb8-ba0c667cfbca" />
   
   ### Superset version
   
   master / latest-dev
   
   ### Python version
   
   3.9
   
   ### Node version
   
   16
   
   ### Browser
   
   Chrome
   
   ### Additional context
   
   superset 6.1
   
   ### Checklist
   
   - [ ] I have searched Superset docs and Slack and didn't find a solution to my problem.
   - [ ] I have searched the GitHub issue tracker and didn't find a similar bug report.
   - [ ] I have checked Superset's logs for errors and if I found a relevant Python stacktrace, I included it here as text in the "additional context" section.


-- 
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.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


Re: [I] Show "multiple" offset metrics in a same dashed lines [superset]

Posted by "Mayankaggarwal8055 (via GitHub)" <gi...@apache.org>.
Mayankaggarwal8055 commented on issue #38639:
URL: https://github.com/apache/superset/issues/38639#issuecomment-4069041868

   I opened a PR for this and tested the change locally.
   
   I was able to reproduce issue #38639 with multiple time-shifted derived series, where the previous dash styles looked too similar. The proposed fix assigns clearer and consistent dash patterns per time offset, and in local testing the derived series were easier to distinguish visually.
   
   PR: #38680


-- 
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


Re: [I] Show "multiple" offset metrics in a same dashed lines [superset]

Posted by "dosubot[bot] (via GitHub)" <gi...@apache.org>.
dosubot[bot] commented on issue #38639:
URL: https://github.com/apache/superset/issues/38639#issuecomment-4057159490

   <!-- Answer -->
   This is a known issue with multiple related bug reports and fixes. There are two problems at play:
   
   1. **Dash patterns too small to see** – The formula `[(patternIncrement % 5) + 1, (patternIncrement % 3) + 1]` generates patterns like [2, 2] (2px dash, 2px gap), which appear nearly identical to solid lines. [PR #37135](https://github.com/apache/superset/pull/37135) fixed this by using larger patterns like `[(patternIndex % 5) + 4, (patternIndex % 3) + 3]` (4-8px dash, 3-5px gap).
   
   2. **Color matching causing same color for all offsets** – The `timeShiftColor` option (enabled by default) makes time-shifted series inherit their original series' color. When you have a single metric with multiple offsets (1 year ago, 2 years ago, 3 years ago), they all inherit the same base color, making them appear identical. [PR #38473](https://github.com/apache/superset/pull/38473) addressed some color matching issues but the fundamental behavior of matching colors is intentional.
   
   **Workaround**: Try unchecking "Match time shift color with original series" in the chart customization options. This will assign distinct colors from your color scheme to each time-shifted series instead of matching them to the original.
   
   
   <!-- Dosu Comment Footer -->
   *To reply, just mention [@dosu](https://go.dosu.dev/dosubot?utm_source=github&utm_medium=bot-comment&utm_campaign=github-assistant&utm_content=brand-link).*
   
   ---
   <sup>How did I do? [Good](https://app.dosu.dev/response-feedback/e4b92a3e-bf1a-4a4b-bad3-23beabbdafc6?feedback_type=great_response&utm_source=github&utm_medium=bot-comment&utm_campaign=github-assistant&utm_content=feedback-great_response) | [Irrelevant](https://app.dosu.dev/response-feedback/e4b92a3e-bf1a-4a4b-bad3-23beabbdafc6?feedback_type=irrelevant_answer&utm_source=github&utm_medium=bot-comment&utm_campaign=github-assistant&utm_content=feedback-irrelevant_answer) | [Incorrect](https://app.dosu.dev/response-feedback/e4b92a3e-bf1a-4a4b-bad3-23beabbdafc6?feedback_type=incorrect_sources&utm_source=github&utm_medium=bot-comment&utm_campaign=github-assistant&utm_content=feedback-incorrect_sources) | [Verbose](https://app.dosu.dev/response-feedback/e4b92a3e-bf1a-4a4b-bad3-23beabbdafc6?feedback_type=too_verbose&utm_source=github&utm_medium=bot-comment&utm_campaign=github-assistant&utm_content=feedback-too_verbose) | [Hallucination](https://app.dosu.dev/response-feedback/e4b92a3e-bf1a
 -4a4b-bad3-23beabbdafc6?feedback_type=hallucination&utm_source=github&utm_medium=bot-comment&utm_campaign=github-assistant&utm_content=feedback-hallucination) | [Report šŸ›](https://app.dosu.dev/response-feedback/e4b92a3e-bf1a-4a4b-bad3-23beabbdafc6?feedback_type=bug_report&utm_source=github&utm_medium=bot-comment&utm_campaign=github-assistant&utm_content=feedback-bug_report) | [Other](https://app.dosu.dev/response-feedback/e4b92a3e-bf1a-4a4b-bad3-23beabbdafc6?feedback_type=other&utm_source=github&utm_medium=bot-comment&utm_campaign=github-assistant&utm_content=feedback-other)</sup>
   
   [![Chat with Dosu](https://dosu.dev/dosu-chat-badge.svg)](https://app.dosu.dev/a28d3c7e-a9d3-459e-9fb6-3a6f9ff4f357/ask?utm_source=github&utm_medium=bot-comment&utm_campaign=github-assistant&utm_content=chat-badge)&nbsp;[![Open in Cursor](https://dosu.dev/dosu-in-cursor.svg)](https://cursor.com/link/prompt?text=This%20is%20a%20known%20issue%20with%20multiple%20related%20bug%20reports%20and%20fixes.%20There%20are%20two%20problems%20at%20play%3A%0A%0A1.%20%2A%2ADash%20patterns%20too%20small%20to%20see%2A%2A%20%E2%80%93%20The%20formula%20%60%5B%28patternIncrement%20%25%205%29%20%2B%201%2C%20%28patternIncrement%20%25%203%29%20%2B%201%5D%60%20generates%20patterns%20like%20%5B2%2C%202%5D%20%282px%20dash%2C%202px%20gap%29%2C%20which%20appear%20nearly%20identical%20to%20solid%20lines.%20%5BPR%20%2337135%5D%28https%3A//github.com/apache/superset/pull/37135%29%20fixed%20this%20by%20using%20larger%20patterns%20like%20%60%5B%28patternIndex%20%25%205%29%20%2B%204%2C%20%28patternIndex%20%25%203
 %29%20%2B%203%5D%60%20%284-8px%20dash%2C%203-5px%20gap%29.%0A%0A2.%20%2A%2AColor%20matching%20causing%20same%20color%20for%20all%20offsets%2A%2A%20%E2%80%93%20The%20%60timeShiftColor%60%20option%20%28enabled%20by%20default%29%20makes%20time-shifted%20series%20inherit%20their%20original%20series%27%20color.%20When%20you%20have%20a%20single%20metric%20with%20multiple%20offsets%20%281%20year%20ago%2C%202%20years%20ago%2C%203%20years%20ago%29%2C%20they%20all%20inherit%20the%20same%20base%20color%2C%20making%20them%20appear%20identical.%20%5BPR%20%2338473%5D%28https%3A//github.com/apache/superset/pull/38473%29%20addressed%20some%20color%20matching%20issues%20but%20the%20fundamental%20behavior%20of%20matching%20colors%20is%20intentional.%0A%0A%2A%2AWorkaround%2A%2A%3A%20Try%20unchecking%20%22Match%20time%20shift%20color%20with%20original%20series%22%20in%20the%20chart%20customization%20options.%20This%20will%20assign%20distinct%20colors%20from%20your%20color%20scheme%20to%20each%20time-sh
 ifted%20series%20instead%20of%20matching%20them%20to%20the%20original.)&nbsp;[![Join Discord](https://img.shields.io/badge/join-5865F2?logo=discord&logoColor=white&label=)](https://go.dosu.dev/discord-bot?utm_source=github&utm_medium=bot-comment&utm_campaign=github-assistant&utm_content=join-discord)&nbsp;[![Share on X](https://img.shields.io/badge/X-share-black)](https://twitter.com/intent/tweet?text=%40dosu_ai%20helped%20me%20solve%20this%20issue!&url=https%3A//github.com/apache/superset/issues/38639)


-- 
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


Re: [I] Show "multiple" offset metrics in a same dashed lines [superset]

Posted by "justinpark (via GitHub)" <gi...@apache.org>.
justinpark commented on issue #38639:
URL: https://github.com/apache/superset/issues/38639#issuecomment-4130871692

   @Mayankaggarwal8055 Your suggested changes included code unrelated to changing the line style, so I created a separate [PR](https://github.com/apache/superset/pull/38866) for it. Additionally, since it was difficult to distinguish differences in the tooltip using only line types, I modified the symbol markers to display differently, making it easier to identify the differences between each line value. Furthermore, this change also fixes a bug where the modification persisted even when the timeShift option was turned off.


-- 
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


Re: [I] Show "multiple" offset metrics in a same dashed lines [superset]

Posted by "michael-s-molina (via GitHub)" <gi...@apache.org>.
michael-s-molina closed issue #38639: Show "multiple" offset metrics in a same dashed lines
URL: https://github.com/apache/superset/issues/38639


-- 
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


Re: [I] Show "multiple" offset metrics in a same dashed lines [superset]

Posted by "Mayankaggarwal8055 (via GitHub)" <gi...@apache.org>.
Mayankaggarwal8055 commented on issue #38639:
URL: https://github.com/apache/superset/issues/38639#issuecomment-4068722807

   I’d like to work on this.
   
   From the report, it looks like the main issue is that multiple time-shifted series become hard to distinguish when `Match time shift color with original series` is enabled and the dash patterns are too similar. I’m going to inspect the line-series styling logic and see if we can preserve the intended color matching while making each shifted series visually distinct.


-- 
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


Re: [I] Show "multiple" offset metrics in a same dashed lines [superset]

Posted by "justinpark (via GitHub)" <gi...@apache.org>.
justinpark commented on issue #38639:
URL: https://github.com/apache/superset/issues/38639#issuecomment-4101536546

   @Mayankaggarwal8055 Thanks for the contribution. I left some comments on your PR


-- 
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