nathaneastwood / poorman

A poor man's dependency free grammar of data manipulation
https://nathaneastwood.github.io/poorman/
Other
339 stars 15 forks source link

Lifting code from poorman #91

Closed vincentarelbundock closed 3 years ago

vincentarelbundock commented 3 years ago

Thanks a lot for your amazing work. This is such a cool package!

I would like to know what you feel is best practice for developers who would like to lift code from poorman. For example, I wanted to reduce the number of dependencies in my modelsummary package, so I removed dplyr which I used for bind_cols and bind_rows. Instead of just substituting one dependency (dplyr) for another (poorman), I lifted the bind_cols and bind_rows from poorman and included the functions directly in my package. I also included your name, the copyright notice, and the full license in the file. See here:

https://github.com/vincentarelbundock/modelsummary/blob/main/R/bind.R

My understanding (IANAL) is that this complies with the terms of the MIT license (feel free to correct me if this is wrong). However, I'd also like to be "nice", and not just "compliant". So I would like to know how you prefer that developers like me act in cases like this. For example,

  1. Would you like to be added as a contributor to my package?
  2. Would you prefer I take out the code chunks and move back to dplyr?

Thanks again for the awesome work!

vincentarelbundock commented 3 years ago

Perhaps a better way to assign "credit" would be to list you as a copyright holder using the "cph" role in DESCRIPTION, with a comment that mentions the poorman package.

eddelbuettel commented 3 years ago

(Piping in from the side as one pal (NE) poked me about this query by another (VAB).)

I do not think we have a hard social contract on this. On the file where you lift name + copyright + full license statement appear to be the common minimum. Some (not all) add as 'ctb' in DESCRIPTION as you say. I think that can be fair, but making it "required" may reach too far. You definitely did the right thing by asking here :)

vincentarelbundock commented 3 years ago

Thanks, I appreciate that. I'm more than happy to add Nathan as a contributor. But there's also the other side of the equation: maybe they don't want their name to be associated with a bunch of crappy R packages ;)

eddelbuettel commented 3 years ago

Yours is a famous one getting more famous by the minute :)

One more thought I just had is that

nathaneastwood commented 3 years ago

Hey @vincentarelbundock. A couple of points if I may.

  1. I really like modelsummary - cool package, keep up the great work 🙂
  2. Thanks for reaching out about it. I personally have no qualms with you lifting code. It was licensed as MIT because I honestly don't mind. I think the attribution you have given me is plenty. If you would like to add me as a ctb and feel that would be appropriate then of course, I will not complain, but please do not feel obliged.
  3. Most importantly - kudos for removing dependencies from your package. This is what I'm all about - hence poorman 😉 FWIW, poorman also has a system to replace tidyselect if you are interested as I see you also use that as a dependency 😉
vincentarelbundock commented 3 years ago

Fantastic! I'll definitely check your version of tidyselect out.

https://github.com/vincentarelbundock/modelsummary/commit/a834959ede69cb61186f32f94a95cecd112a1c13