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

mutate() with functions that return NULL #2187

Closed
krlmlr opened this issue Oct 20, 2016 · 2 comments
Closed

mutate() with functions that return NULL #2187

krlmlr opened this issue Oct 20, 2016 · 2 comments
Assignees
Labels
Milestone

Comments

@krlmlr
Copy link
Member

@krlmlr krlmlr commented Oct 20, 2016

gives an error. Is this by design? I can't find a test for this.

mutate(iris, x = identity(NULL))
## Error in eval(substitute(expr), envir, enclos) : 
##   Unsupported type NILSXP for column "x"
mutate(iris, x = NULL)
## (works as expected)
@krlmlr
Copy link
Member Author

@krlmlr krlmlr commented Oct 20, 2016

Return sensible error message.

@hadley
Copy link
Member

@hadley hadley commented Jan 31, 2017

We do need to handle NULL returned from functions somehow. Let's discuss in the future.

@krlmlr krlmlr self-assigned this Feb 10, 2017
@krlmlr krlmlr added this to the data frame 1 milestone Feb 10, 2017
@krlmlr krlmlr added this to the data frame 1 milestone Feb 10, 2017
@krlmlr krlmlr closed this in #2439 Feb 20, 2017
@lock lock bot locked as resolved and limited conversation to collaborators Jun 8, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants