thisisnic commented on issue #40723:
URL: https://github.com/apache/arrow/issues/40723#issuecomment-2016544832

   Thanks for reporting this @r2evans.  
   
   I can confirm that I can reproduce this - nothing is returned.
   
   Thinking through the various options of what would make sense to return, I 
had a few thoughts.
   
   Looking at other examples, such as `DBI::dbWriteTable()` (as sometimes we 
think of working with datasets as analogous to working with a database 
connection), that function just returns `TRUE` invisibly to indicate success.
   
   However, looking at the [tidyverse design 
guide](https://design.tidyverse.org/out-invisible.html), a principle referenced 
there is:
   
   > If a function is called primarily for its side-effects, it should 
invisibly return a useful output. If there’s no obvious output, return the 
first argument. This makes it possible to use the function with in a pipeline.
   
   I'm not sure how common it is to use `write_dataset()` mid-pipeline, though 
it's feasible, so that could make sense too.
   
   I can see why you might want to have the list of files created, but I'm a 
bit hesitant to diverge from the behaviour of existing similar APIs, and this 
might be better thought through as a separate feature request.
   
   Curious to see what @amoeba thinks here?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to