Skip to content

Fallback for colour scales #6289

Closed

Description

@teunbrand

This issue was identified in #6287.

Some packages use scale_colour_continuous(low = "blue", high = "red"). This is only valid when end-users haven't touched the default "ggplot2.continuous.colour" options. The pattern these packages use are thus fragile and instead they should use scale_colour_gradient().
Likewise for scale_colour_discrete() and scale_colour_hue() and the fill aesthetic equivalents.

However, because the problem is quite ubiquitous (39 packages), we should have fallbacks in place.
I'll suggest that we use a grumpy fallback that always throws a warning, as the usage remains incorrect.

Activity

  1. added a commit that references this issue on Jan 22, 2025
    f7ce644
  2. added a commit that references this issue on Mar 25, 2025
    2478406
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions