Skip to content

Ubuntu environement install fixup - #35071

Draft
khancyr wants to merge 6 commits into
ArduPilot:masterfrom
khancyr:pr-env-install-cleanup
Draft

khancyr wants to merge 6 commits into
ArduPilot:masterfrom
khancyr:pr-env-install-cleanup

Conversation

@khancyr

@khancyr khancyr commented Nov 9, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Remove plucky and questing support as EOL
Remove dead code and dead code path
Realpath is garantee to be installed as part of coreutil now
Make STM32 toolchain install better with validation and retry

Install wxpython wheel from github release as their doc state since extras.wxpython.org is not updated anymore

Fixup a bit the script rerun, so it won't retry to install toolchain not add export to .bashrc/shell config.

Tested locally.
Claude helps

Classification & Testing (check all that apply and add your own)

  • Checked by a human programmer
  • Non-functional change
  • No-binary change
  • Infrastructure change (e.g. unit tests, helper scripts)
  • Automated test(s) verify changes (e.g. unit test, autotest)
  • Tested manually, description below (e.g. SITL)
  • Tested on hardware
  • Logs attached
  • Logs available on request

Description

khancyr and others added 6 commits November 9, 2026 12:34
Ubuntu 25.04 Plucky reached end of life in January 2026 and 25.10
Questing in July 2026. Move them to the unsupported list and drop the
Pillow reinstall workaround that only applied to them.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- check ~/.bashrc, where the completion line is written, instead of
  the login file
- only append the venv activate line and the docker
  ~/.ardupilot_env source line if not already present
- look for .git in ARDUPILOT_ROOT rather than the current directory,
  and accept a file so git worktrees get their submodules updated

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Unknown release codenames exit early, so the fallbacks for SFML
version detection, python-argparse, python-wxgtk2.8/3.0 and the
realpath package can never run. Jammy does not pip install wxpython,
so its wheel repository entry is unused. Also drop the undefined
PX4_PKGS, the SETUPTOOLS indirection and the duplicate opencv-python.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Merge the identical x86_64 and aarch64 blocks, check the tarball
sha256, and extract into a staging directory that is moved into place
only once complete, so an interrupted extraction is retried on the
next run instead of leaving a broken toolchain.
A download with a bad checksum is retried up to 3 times, then the
script stops and asks the user to rerun it.
Skip the toolchain and its PATH entry on unsupported architectures.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The second check tested arm-none-eabi-g++ again, so the gcc link was
never created after the g++ one.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The extras.wxpython.org wheels stop at 4.2.5 while PyPI is at 4.3.2,
so "pip install --upgrade --find-links" ignored them and built wxPython
from source (~30 minutes), and resolute had no wheel repository at all.

wxPython GitHub releases ship wheels per Ubuntu release and CPython
version, so install the matching one from the latest release, falling
back to the PyPI source build if there is none (e.g. aarch64).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
SITLCFML_VERSION="3.0"
PYTHON_V="python3"
PIP="python3 -m pip"
else

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we be killing this block or using it?!

I think we might have done the if/elif thing when a distro had a choice of two, but we just kind of grew the pattern.

It would be nice if we had one fewer blocks for people to edit when adding support for a distro.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

that is dead code now, since we exit 1 if the distribution is unknown or not supported anymore

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Right, but it doesn't need to be dead code. Instead of nominating the versions we could work it out with this block!

My suggestion is to use the existing block for the most recent Ubuntu and just let the others age out.

Your call, happy to merge as-is.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

right, I understand what you mean.
I will try to make something simpler to support maxium distribution. Current stance was to explictly mark the package for each version group, but we can try to go to something more generic with automagical discovery .
Let's see if I can work out something

@peterbarker peterbarker self-assigned this Nov 9, 2026
@khancyr
khancyr marked this pull request as draft November 10, 2026 13:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants