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

geom_swim_label() Errors #52

Merged
merged 3 commits into from
Jul 8, 2024
Merged

geom_swim_label() Errors #52

merged 3 commits into from
Jul 8, 2024

Conversation

rsh52
Copy link
Contributor

@rsh52 rsh52 commented Jul 8, 2024

Description

There are several known errors that occur when calling geom_swim_label() in a few cases:

  • Ordering with respect to new_scale_color() and other geoms
  • Data inheritance via aes() definitions within a top-level ggplot() call

Proposed Changes

  • Add internal capture_error() function for testing only
    • capture_error() is being used to test for equivalent errors between ggplot-vanilla and ggswim. Mostly to help keep a reference of errors that aren't introduced by us (or my fault!)
  • Add further handling to try_ggswim() so it returns original error when not a special case
  • Add get_mapping_obj() function to capture geom_swim_label() mapping and correctly re-introduce inherited missing params from the current layer

Issue Addressed

Closes #50
Closes #51

@rsh52 rsh52 self-assigned this Jul 8, 2024
try_ggswim returns original quo when there isn't an identified special case error
@rsh52 rsh52 marked this pull request as ready for review July 8, 2024 19:09
@rsh52 rsh52 merged commit de7f7f7 into main Jul 8, 2024
9 checks passed
@rsh52 rsh52 deleted the geom_swim_label_errors branch July 8, 2024 19:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
1 participant