Skip to content

Conversation

teunbrand
Copy link
Collaborator

This PR aims to fix #6088.

Briefly, #5789 introduced an early exit but this unfortunately happened after data had already been transformed.
This PR performs the check earlier, and encodes this as var = NULL, which will early exit subsequent functions without data transformation.

Reprex from issue:

devtools::load_all("~/packages/ggplot2")
#> ℹ Loading ggplot2

data.frame(
  x = c(-1, 1),
  y = c("x", "y")
) |> 
  ggplot(aes(x, y)) +
  geom_col()

Created on 2024-09-16 with reprex v2.1.1

Copy link
Member

@thomasp85 thomasp85 left a comment

Choose a reason for hiding this comment

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

LGTM

@teunbrand teunbrand merged commit a33953f into tidyverse:main Sep 23, 2024
13 checks passed
@teunbrand teunbrand deleted the fix_6088 branch September 23, 2024 07:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Regression: negative geom_col disappears
2 participants