Skip to content

Commit

Permalink
Upgrade to Drake v1.28.0 (#557)
Browse files Browse the repository at this point in the history
* Upgrade to Drake v1.28.0

* upgrade black in pre-commit and github actions

* lxml now needs an explicit opt-in for lxml-html-clean, and introduces a requirement cycle

---------

Co-authored-by: Russ Tedrake <russt@mit.edu>
  • Loading branch information
jwnimmer-tri and RussTedrake committed Apr 13, 2024
1 parent d9db61c commit e78cd17
Show file tree
Hide file tree
Showing 11 changed files with 790 additions and 692 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/main.yml
Expand Up @@ -98,7 +98,7 @@ jobs:
- name: black
uses: psf/black@stable
with:
version: 24.2.0
version: 24.4.0
jupyter: true
- name: isort
uses: isort/isort-action@master
Expand Down
2 changes: 1 addition & 1 deletion .pre-commit-config.yaml
@@ -1,6 +1,6 @@
repos:
- repo: https://github.com/psf/black
rev: 24.2.0 # NOTE: If updating, also update the version in .github/workflows/*
rev: 24.4.0 # NOTE: If updating, also update the version in .github/workflows/*
hooks:
- id: black-jupyter
types_or: ["python","jupyter"]
Expand Down
2 changes: 1 addition & 1 deletion Developers.md
Expand Up @@ -10,7 +10,7 @@ poetry install --with=dev,docs

To generate it, run
```
poetry export
poetry lock
./book/htmlbook/PoetryExport.sh
```

Expand Down
16 changes: 11 additions & 5 deletions WORKSPACE.bazel
Expand Up @@ -40,6 +40,12 @@ pip_parse(
requirements_darwin = "//:requirements-bazel-mac.txt",
requirements_linux = "//:requirements-bazel-linux.txt",
requirements_lock = "//:requirements-bazel.txt",
experimental_requirement_cycles = {
"lxml": [
"lxml",
"lxml-html-clean",
],
},
)

load("@pip_deps//:requirements.bzl", "install_deps")
Expand All @@ -59,12 +65,12 @@ load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
http_archive(
name = "drake_models",
urls = [
"https://github.com/RobotLocomotion/models/archive/fe5326c5ffc36fda12c58883d22d29dc86009d65.tar.gz",
"https://drake-mirror.csail.mit.edu/github/RobotLocomotion/models/fe5326c5ffc36fda12c58883d22d29dc86009d65.tar.gz",
"https://s3.amazonaws.com/drake-mirror/github/RobotLocomotion/models/fe5326c5ffc36fda12c58883d22d29dc86009d65.tar.gz",
"https://github.com/RobotLocomotion/models/archive/69c92595a391eb023c27ab6ac8f80d58a3e4612d.tar.gz",
"https://drake-mirror.csail.mit.edu/github/RobotLocomotion/models/69c92595a391eb023c27ab6ac8f80d58a3e4612d.tar.gz",
"https://s3.amazonaws.com/drake-mirror/github/RobotLocomotion/models/69c92595a391eb023c27ab6ac8f80d58a3e4612d.tar.gz",
],
sha256 = "2a232f7da8d575fe1fcc6ad396f634d1adc1c9ee856168f011fbeb42a01c76b1",
strip_prefix = "models-fe5326c5ffc36fda12c58883d22d29dc86009d65",
sha256 = "ba571c8b369a62c3764d250944b27d72071488789b2494604d23342994141fe2",
strip_prefix = "models-69c92595a391eb023c27ab6ac8f80d58a3e4612d",
build_file_content = """
package(default_visibility = ["//visibility:public"])
Expand Down
8 changes: 4 additions & 4 deletions book/acrobot/quadrotor.ipynb
Expand Up @@ -127,7 +127,7 @@
" plant = builder.AddSystem(MultibodyPlant(0.0))\n",
" parser = Parser(plant)\n",
" (model_instance,) = parser.AddModelsFromUrl(\n",
" \"package://drake/examples/quadrotor/quadrotor.urdf\"\n",
" \"package://drake_models/skydio_2/quadrotor.urdf\"\n",
" )\n",
" # By default the multibody has a quaternion floating base. To match\n",
" # QuadrotorPlant, we can manually add a FloatingRollPitchYaw joint. We set\n",
Expand Down Expand Up @@ -276,17 +276,17 @@
"def MakeMultipleQuadrotors():\n",
" # The RobotDiagram is a convenient way to work with a MultibodyPlant +\n",
" # SceneGraph.\n",
" builder = RobotDiagramBuilder()\n",
" builder = RobotDiagramBuilder(time_step=0.0)\n",
" plant = builder.plant()\n",
"\n",
" directives = \"\"\"\n",
" directives:\n",
" - add_model:\n",
" name: quad1\n",
" file: package://drake/examples/quadrotor/quadrotor.urdf\n",
" file: package://drake_models/skydio_2/quadrotor.urdf\n",
" - add_model:\n",
" name: quad2\n",
" file: package://drake/examples/quadrotor/quadrotor.urdf\n",
" file: package://drake_models/skydio_2/quadrotor.urdf\n",
" \"\"\"\n",
"\n",
" builder.parser().SetAutoRenaming(True)\n",
Expand Down
1,188 changes: 640 additions & 548 deletions poetry.lock

Large diffs are not rendered by default.

10 changes: 5 additions & 5 deletions pyproject.toml
Expand Up @@ -50,8 +50,8 @@ priority = "explicit"

[tool.poetry.dependencies]
python = "<4.0,>=3.10"
drake = { version = "==0.0.20240307", source = "drake-nightly" }
#drake = ">=1.23.0"
#drake = { version = "==0.0.20240307", source = "drake-nightly" }
drake = ">=1.28.0"
gradescope-utils = ">=0.4.0"
ipywidgets = ">7"
mpld3 = ">=0.5.1"
Expand All @@ -66,8 +66,8 @@ optional = true
# Must include all dependencies required to build the docs with sphinx + autodoc.
[tool.poetry.group.docs.dependencies]
# Should match drake version above.
drake = { version = "==0.0.20240307", source = "drake-nightly" }
#drake = ">=1.23.0"
#drake = { version = "==0.0.20240307", source = "drake-nightly" }
drake = ">=1.28.0"
ipython = ">=7.8.0"
sphinx = ">=7.2.6"
myst-parser = ">=2.0.0"
Expand All @@ -76,7 +76,7 @@ sphinx_rtd_theme = ">=2.0.0"
[tool.poetry.group.dev.dependencies]
beautifulsoup4 = ">=4.6.3"
black = { version = ">=23.*", extras = ["jupyter"] }
lxml = ">=4.9.2" # seems to be needed on python 3.11
lxml = {version = ">=4.9.2", extras = ["html_clean"] }
# Blocked on poetry known issue; see Developers.md
#matplotlib = [
# {platform="darwin", version=">=3.7.0"}, # old versions don't build in XCode
Expand Down
62 changes: 31 additions & 31 deletions requirements-bazel-linux.txt
@@ -1,54 +1,54 @@
--extra-index-url https://drake-packages.csail.mit.edu/whl/nightly

asttokens==2.4.1 ; python_version >= "3.10" and python_version < "4.0"
attrs==23.2.0 ; python_version >= "3.10" and python_version < "4.0" and (sys_platform == "darwin" or sys_platform == "linux")
beautifulsoup4==4.12.3 ; python_version >= "3.10" and python_version < "4.0"
black[jupyter]==24.2.0 ; python_version >= "3.10" and python_version < "4.0"
black[jupyter]==24.4.0 ; python_version >= "3.10" and python_version < "4.0"
bleach==6.1.0 ; python_version >= "3.10" and python_version < "4.0" and (sys_platform == "darwin" or sys_platform == "linux")
build==1.1.1 ; python_version >= "3.10" and python_version < "4.0"
build==1.2.1 ; python_version >= "3.10" and python_version < "4.0"
cachecontrol[filecache]==0.14.0 ; python_version >= "3.10" and python_version < "4.0"
certifi==2024.2.2 ; python_version >= "3.10" and python_version < "4.0"
cffi==1.16.0 ; python_version >= "3.10" and python_version < "4.0" and (sys_platform == "darwin" or sys_platform == "linux") and (sys_platform == "darwin" or implementation_name == "pypy" or platform_python_implementation != "PyPy")
cfgv==3.4.0 ; python_version >= "3.10" and python_version < "4.0"
charset-normalizer==3.3.2 ; python_version >= "3.10" and python_version < "4.0"
cleo==2.1.0 ; python_version >= "3.10" and python_version < "4.0"
click==8.1.7 ; python_version >= "3.10" and python_version < "4.0"
comm==0.2.1 ; python_version >= "3.10" and python_version < "4.0"
contourpy==1.2.0 ; python_version >= "3.10" and python_version < "4.0"
comm==0.2.2 ; python_version >= "3.10" and python_version < "4.0"
contourpy==1.2.1 ; python_version >= "3.10" and python_version < "4.0"
crashtest==0.4.1 ; python_version >= "3.10" and python_version < "4.0"
cryptography==42.0.5 ; python_version >= "3.10" and python_version < "4.0" and sys_platform == "linux"
cycler==0.12.1 ; python_version >= "3.10" and python_version < "4.0"
decorator==5.1.1 ; python_version >= "3.10" and python_version < "4.0"
defusedxml==0.7.1 ; python_version >= "3.10" and python_version < "4.0" and (sys_platform == "darwin" or sys_platform == "linux")
distlib==0.3.8 ; python_version >= "3.10" and python_version < "4.0"
drake==0.0.20240307 ; python_version >= "3.10" and python_version < "4.0"
drake==1.28.0 ; python_version >= "3.10" and python_version < "4.0"
dulwich==0.21.7 ; python_version >= "3.10" and python_version < "4.0"
entrypoints==0.4 ; python_version >= "3.10" and python_version < "4.0" and sys_platform == "linux"
exceptiongroup==1.2.0 ; python_version >= "3.10" and python_version < "3.11"
executing==2.0.1 ; python_version >= "3.10" and python_version < "4.0"
fastjsonschema==2.19.1 ; python_version >= "3.10" and python_version < "4.0"
filelock==3.13.1 ; python_version >= "3.10" and python_version < "4.0"
fonttools==4.49.0 ; python_version >= "3.10" and python_version < "4.0"
filelock==3.13.4 ; python_version >= "3.10" and python_version < "4.0"
fonttools==4.51.0 ; python_version >= "3.10" and python_version < "4.0"
gradescope-utils==0.5.0 ; python_version >= "3.10" and python_version < "4.0"
identify==2.5.35 ; python_version >= "3.10" and python_version < "4.0"
idna==3.6 ; python_version >= "3.10" and python_version < "4.0"
importlib-metadata==7.0.2 ; python_version >= "3.10" and python_version < "3.12"
idna==3.7 ; python_version >= "3.10" and python_version < "4.0"
importlib-metadata==7.1.0 ; python_version >= "3.10" and python_version < "3.12"
installer==0.7.0 ; python_version >= "3.10" and python_version < "4.0"
ipython==8.22.2 ; python_version >= "3.10" and python_version < "4.0"
ipython==8.23.0 ; python_version >= "3.10" and python_version < "4.0"
ipywidgets==8.1.2 ; python_version >= "3.10" and python_version < "4.0"
jaraco-classes==3.3.1 ; python_version >= "3.10" and python_version < "4.0"
jaraco-classes==3.4.0 ; python_version >= "3.10" and python_version < "4.0"
jedi==0.19.1 ; python_version >= "3.10" and python_version < "4.0"
jeepney==0.8.0 ; python_version >= "3.10" and python_version < "4.0" and sys_platform == "linux"
jinja2==3.1.3 ; python_version >= "3.10" and python_version < "4.0"
jsonschema-specifications==2023.12.1 ; python_version >= "3.10" and python_version < "4.0" and (sys_platform == "darwin" or sys_platform == "linux")
jsonschema==4.21.1 ; python_version >= "3.10" and python_version < "4.0" and (sys_platform == "darwin" or sys_platform == "linux")
jupyter-client==8.6.0 ; python_version >= "3.10" and python_version < "4.0" and (sys_platform == "darwin" or sys_platform == "linux")
jupyter-core==5.7.1 ; python_version >= "3.10" and python_version < "4.0" and (sys_platform == "darwin" or sys_platform == "linux")
jupyter-client==8.6.1 ; python_version >= "3.10" and python_version < "4.0" and (sys_platform == "darwin" or sys_platform == "linux")
jupyter-core==5.7.2 ; python_version >= "3.10" and python_version < "4.0" and (sys_platform == "darwin" or sys_platform == "linux")
jupyterlab-pygments==0.3.0 ; python_version >= "3.10" and python_version < "4.0" and (sys_platform == "darwin" or sys_platform == "linux")
jupyterlab-widgets==3.0.10 ; python_version >= "3.10" and python_version < "4.0"
keyring==24.3.1 ; python_version >= "3.10" and python_version < "4.0"
kiwisolver==1.4.5 ; python_version >= "3.10" and python_version < "4.0"
lxml==5.1.0 ; python_version >= "3.10" and python_version < "4.0"
lxml-html-clean==0.1.1 ; python_version >= "3.10" and python_version < "4.0"
lxml==5.2.1 ; python_version >= "3.10" and python_version < "4.0"
lxml[html-clean]==5.2.1 ; python_version >= "3.10" and python_version < "4.0"
markupsafe==2.1.5 ; python_version >= "3.10" and python_version < "4.0"
matplotlib-inline==0.1.6 ; python_version >= "3.10" and python_version < "4.0"
matplotlib==3.5.1 ; sys_platform == "linux"
Expand All @@ -60,24 +60,24 @@ mypy-extensions==1.0.0 ; python_version >= "3.10" and python_version < "4.0"
mysql-connector-python==8.3.0 ; python_version >= "3.10" and python_version < "4.0"
nbclient==0.5.13 ; python_version >= "3.10" and python_version < "4.0" and sys_platform == "linux"
nbconvert==6.4.0 ; python_version >= "3.10" and python_version < "4.0" and sys_platform == "linux"
nbformat==5.9.2 ; python_version >= "3.10" and python_version < "4.0" and (sys_platform == "darwin" or sys_platform == "linux")
nbformat==5.10.4 ; python_version >= "3.10" and python_version < "4.0" and (sys_platform == "darwin" or sys_platform == "linux")
nest-asyncio==1.6.0 ; python_version >= "3.10" and python_version < "4.0" and sys_platform == "linux"
nodeenv==1.8.0 ; python_version >= "3.10" and python_version < "4.0"
numpy==1.26.4 ; python_version >= "3.10" and python_version < "4.0"
packaging==23.2 ; python_version >= "3.10" and python_version < "4.0"
pandas==2.2.1 ; python_version >= "3.10" and python_version < "4.0"
packaging==24.0 ; python_version >= "3.10" and python_version < "4.0"
pandas==2.2.2 ; python_version >= "3.10" and python_version < "4.0"
pandocfilters==1.5.1 ; python_version >= "3.10" and python_version < "4.0" and (sys_platform == "darwin" or sys_platform == "linux")
parso==0.8.3 ; python_version >= "3.10" and python_version < "4.0"
parso==0.8.4 ; python_version >= "3.10" and python_version < "4.0"
pathspec==0.12.1 ; python_version >= "3.10" and python_version < "4.0"
pexpect==4.9.0 ; python_version >= "3.10" and python_version < "4.0"
pillow==10.2.0 ; python_version >= "3.10" and python_version < "4.0"
pillow==10.3.0 ; python_version >= "3.10" and python_version < "4.0"
pkginfo==1.10.0 ; python_version >= "3.10" and python_version < "4.0"
platformdirs==4.2.0 ; python_version >= "3.10" and python_version < "4.0"
pre-commit==3.6.2 ; python_version >= "3.10" and python_version < "4.0"
pre-commit==3.7.0 ; python_version >= "3.10" and python_version < "4.0"
prompt-toolkit==3.0.43 ; python_version >= "3.10" and python_version < "4.0"
ptyprocess==0.7.0 ; python_version >= "3.10" and python_version < "4.0"
pure-eval==0.2.2 ; python_version >= "3.10" and python_version < "4.0"
pycparser==2.21 ; python_version >= "3.10" and python_version < "4.0" and (sys_platform == "darwin" or sys_platform == "linux") and (sys_platform == "darwin" or implementation_name == "pypy" or platform_python_implementation != "PyPy")
pycparser==2.22 ; python_version >= "3.10" and python_version < "4.0" and (sys_platform == "darwin" or sys_platform == "linux") and (sys_platform == "darwin" or implementation_name == "pypy" or platform_python_implementation != "PyPy")
pydot==2.0.0 ; python_version >= "3.10" and python_version < "4.0"
pygments==2.17.2 ; python_version >= "3.10" and python_version < "4.0"
pyparsing==3.1.2 ; python_version >= "3.10" and python_version < "4.0"
Expand All @@ -86,14 +86,14 @@ python-dateutil==2.9.0.post0 ; python_version >= "3.10" and python_version < "4.
pytz==2024.1 ; python_version >= "3.10" and python_version < "4.0"
pyyaml==6.0.1 ; python_version >= "3.10" and python_version < "4.0"
pyzmq==25.1.2 ; python_version >= "3.10" and python_version < "4.0" and (sys_platform == "darwin" or sys_platform == "linux")
rapidfuzz==3.6.2 ; python_version >= "3.10" and python_version < "4.0"
referencing==0.33.0 ; python_version >= "3.10" and python_version < "4.0" and (sys_platform == "darwin" or sys_platform == "linux")
rapidfuzz==3.8.1 ; python_version >= "3.10" and python_version < "4.0"
referencing==0.34.0 ; python_version >= "3.10" and python_version < "4.0" and (sys_platform == "darwin" or sys_platform == "linux")
requests-toolbelt==1.0.0 ; python_version >= "3.10" and python_version < "4.0"
requests==2.31.0 ; python_version >= "3.10" and python_version < "4.0"
rpds-py==0.18.0 ; python_version >= "3.10" and python_version < "4.0" and (sys_platform == "darwin" or sys_platform == "linux")
scipy==1.12.0 ; python_version >= "3.10" and python_version < "4.0"
scipy==1.13.0 ; python_version >= "3.10" and python_version < "4.0"
secretstorage==3.3.3 ; python_version >= "3.10" and python_version < "4.0" and sys_platform == "linux"
setuptools==69.1.1 ; python_version >= "3.10" and python_version < "4.0"
setuptools==69.5.0 ; python_version >= "3.10" and python_version < "4.0"
shellingham==1.5.4 ; python_version >= "3.10" and python_version < "4.0"
six==1.16.0 ; python_version >= "3.10" and python_version < "4.0"
soupsieve==2.5 ; python_version >= "3.10" and python_version < "4.0"
Expand All @@ -104,13 +104,13 @@ tokenize-rt==5.2.0 ; python_version >= "3.10" and python_version < "4.0"
tomli==2.0.1 ; python_version >= "3.10" and python_version < "3.11"
tomlkit==0.12.4 ; python_version >= "3.10" and python_version < "4.0"
tornado==6.4 ; python_version >= "3.10" and python_version < "4.0" and (sys_platform == "darwin" or sys_platform == "linux")
traitlets==5.14.1 ; python_version >= "3.10" and python_version < "4.0"
trove-classifiers==2024.3.3 ; python_version >= "3.10" and python_version < "4.0"
typing-extensions==4.10.0 ; python_version >= "3.10" and python_version < "3.11"
traitlets==5.14.2 ; python_version >= "3.10" and python_version < "4.0"
trove-classifiers==2024.4.10 ; python_version >= "3.10" and python_version < "4.0"
typing-extensions==4.11.0 ; python_version >= "3.10" and python_version < "3.12"
tzdata==2024.1 ; python_version >= "3.10" and python_version < "4.0"
urllib3==2.2.1 ; python_version >= "3.10" and python_version < "4.0"
virtualenv==20.25.1 ; python_version >= "3.10" and python_version < "4.0"
wcwidth==0.2.13 ; python_version >= "3.10" and python_version < "4.0"
webencodings==0.5.1 ; python_version >= "3.10" and python_version < "4.0" and (sys_platform == "darwin" or sys_platform == "linux")
widgetsnbextension==4.0.10 ; python_version >= "3.10" and python_version < "4.0"
zipp==3.17.0 ; python_version >= "3.10" and python_version < "3.12"
zipp==3.18.1 ; python_version >= "3.10" and python_version < "3.12"

0 comments on commit e78cd17

Please sign in to comment.