RobotLocomotion / drake

Model-based design and verification for robotics.
https://drake.mit.edu
Other
3.36k stars 1.27k forks source link

Close out the pybind11 fork #5842

Open david-german-tri opened 7 years ago

david-german-tri commented 7 years ago

It remains a goal to get off https://github.com/RobotLocomotion/pybind11 and back onto upstream. Not top priority, but we shouldn't forget to do it - and it may be easier to do the fresher our fork is.

cc @stonier @jamiesnape

jamiesnape commented 7 years ago

Relates https://github.com/pybind/pybind11/pull/1152.

EricCousineau-TRI commented 6 years ago

Porting item from #7660 to here:

Use upstream pybind11. Would need to break up pybind/pybind11#1146 and get buy-in from pybind11 authors.

  • Could relate to REPL-friendly referencing (e.g. removing use of unique_ptr in C++ arguments; use only shared_ptr).
  • Could use keep_alive workaround to prevent slicing, but would run into same caveats as for REPL-friendly referencing.
  • As a hack, could also introduce a keep-forever-alive setup for polymorphic types, and adopt a PyPy-style memory model (clean up on GC, not on reference counting).
jwnimmer-tri commented 6 years ago

Per Eric, we don't think we'll ever get to zero diffs from upstream, but we should still try to keep our diffs minimal by PRing upstream.

EricCousineau-TRI commented 4 years ago

Will close this for now. Will encode that we should keep diffs minimal in our fork's README.

EricCousineau-TRI commented 3 years ago

Given the recent uptick in interest in pybind11's holder setup (specifically for unique_ptr and some of the edge cases I've kludged through), this may become feasible over the next year or so: https://github.com/pybind/pybind11/issues/2646

jwnimmer-tri commented 2 years ago

Given that pybind11 upsteam just repaved over the entire universe with clang-format (https://github.com/pybind/pybind11/pull/3713), continuing to maintain our fork will be even more work.

EricCousineau-TRI commented 2 years ago

Agreed it will be more work, but I think reformatting our tree (hopefully idempotent with very small span of fixed points) will help PR merging. Planning to do another update in April.