Make sure mapping is not stateful#4475
Conversation
|
Sorry if I'm dense. Could you explain in a few more sentences what exactly is being done? Also, if |
|
plot-level mappings and layer-level mappings needs to be fused together - earlier this was done all over the place and let to bugs which resulted in us moving the fusing into With this PR I already added a note at the |
clauswilke
left a comment
There was a problem hiding this comment.
Ok, looks good to me.
I notice that there doesn't seem to be a unit test for the inherit.aes argument, so maybe add a very simple one.
yutannihilation
left a comment
There was a problem hiding this comment.
Looks good. It seems I was kind of aware about the need to treat the statefulness at the time of #4265 (comment), but couldn't come up with any solutions. Thanks for catching!
This PR fixes the "statefulness" of the
mappingfield introduced in #4265 by aligning it with how we now treatgeom_paramsandstat_params. In fact the state has existed since the introduction ofLayerSfwhere the mapping would be modified to ensure the geometry was catched.This clean-up leaves a couple of dangling issues, mainly the fact that
default_mappingno longer needs to be passed around. It is kept as-is so we don't change the signature of the guide calculation and break extension packages. We can remove it entirely when we rewrite the guide functionality to ggproto