Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Preliminary support for Ubuntu 24 and Ubuntu 24 ARM #3316

Merged
merged 116 commits into from
Oct 20, 2024

Conversation

itsarune
Copy link
Contributor

@itsarune itsarune commented Sep 21, 2024

Please fill out the following before requesting review on this PR

Description

Summary of changes:

  • python stepping to python 3.12 (required to install pyqt6 on ARM devices via the system package, pip install was broken)

  • updated SSL game controller to latest (for ARM binaries)

  • updated Tigers Autoref to latest (new game controller also updates several protobuf definitions)

  • What works:

  • ARM bazel build works

  • X86 full_system/thunderscope/jetson compilation works

What doesn't work:

  • jetson nano compilation for ARM (should work)

Testing Done

Resolved Issues

Length Justification and Key Files to Review

Review Checklist

It is the reviewers responsibility to also make sure every item here has been covered

  • Function & Class comments: All function definitions (usually in the .h file) should have a javadoc style comment at the start of them. For examples, see the functions defined in thunderbots/software/geom. Similarly, all classes should have an associated Javadoc comment explaining the purpose of the class.
  • Remove all commented out code
  • Remove extra print statements: for example, those just used for testing
  • Resolve all TODO's: All TODO (or similar) statements should either be completed or associated with a github issue

@itsarune itsarune requested review from a team, raymond212, Muxite, Lmh-java, mkhlb, Mr-Anyone, AmyKawa, wmostrenko and annieisawesome2 and removed request for a team October 12, 2024 08:46
@itsarune
Copy link
Contributor Author

Could someone with an ARM computer run the following command and let me know if it works: bazel build //software/embedded:thunderloop_main --copt=-O3 --//software/embedded:host_platform=NANO --platforms=//cc_toolchain:robot

@annieisawesome2
Copy link
Contributor

I gave it a try - it didn't work:

ERROR: Skipping '//software/embedded:host_platform': no such package 'software/embedded': BUILD file not found in any of the following directories. Add a BUILD file to a directory to mark it as a package.

@Lmh-java
Copy link
Contributor

It worked on my machine.

global namespace is deprecated. Please use <boost/bind/bind.hpp> + using namespace boost::placeholders, or define BOOST_BIND_GLOBAL_PLACEHOLDERS to retain the current behavior.'
   36 | BOOST_PRAGMA_MESSAGE(
      | ^~~~~~~~~~~~~~~~~~~~
Target //software/embedded:thunderloop_main up-to-date:
  bazel-bin/software/embedded/thunderloop_main
INFO: Elapsed time: 236.995s, Critical Path: 83.25s
INFO: 189 processes: 49 disk cache hit, 21 internal, 119 linux-sandbox.
INFO: Build completed successfully, 189 total actions

@raymond212 raymond212 removed their request for review October 12, 2024 18:30
Copy link
Contributor

@williamckha williamckha left a comment

Choose a reason for hiding this comment

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

🚀

@Mr-Anyone
Copy link
Contributor

Mr-Anyone commented Oct 20, 2024

I have tried a few entries in thunderscope and it worked!

One thing to note when running autoref is that a warning message is spammed:

sys:1: UserWarning: MessageFactory class is deprecated. Please use GetMessageClass() instead of MessageFactory.GetPrototype. MessageFactory class will be removed after 2024.
sys:1: UserWarning: MessageFactory class is deprecated. Please use GetMessageClass() instead of MessageFactory.GetPrototype. MessageFactory class will be removed after 2024.
sys:1: UserWarning: MessageFactory class is deprecated. Please use GetMessageClass() instead of MessageFactory.GetPrototype. MessageFactory class will be removed after 2024.
sys:1: UserWarning: MessageFactory class is deprecated. Please use GetMessageClass() instead of MessageFactory.GetPrototype. MessageFactory class will be removed after 2024.

This seems to be a google protobuf python warning

https://github.com/protocolbuffers/protobuf/blob/b8d356701a788951d92a1b4f04881fb539ca62d7/python/google/protobuf/message_factory.py#L136-L137

@Mr-Anyone
Copy link
Contributor

Apart from that, LGTM!

@itsarune
Copy link
Contributor Author

Yeah, I saw this error too. We aren't using MessageFactory but some dependency of ours is. If you're okay with it, we'll handle that in a different ticket?

@itsarune itsarune merged commit 47d45b8 into UBC-Thunderbots:master Oct 20, 2024
7 checks passed
@itsarune itsarune mentioned this pull request Oct 21, 2024
4 tasks
@Mr-Anyone
Copy link
Contributor

perfectly fine with it

@Mr-Anyone
Copy link
Contributor

deal with it once it will be a issues

@Andrewyx Andrewyx mentioned this pull request Oct 23, 2024
4 tasks
@Andrewyx Andrewyx mentioned this pull request Oct 23, 2024
4 tasks
Lmh-java pushed a commit to Lmh-java/Software that referenced this pull request Oct 25, 2024
…3316)

* Update to python 3.10.0 and bazel 5.4.0

* No need to import `typing` for collections as of python 3.9

* Update black formatter to 24.4.2

* Run fix_formatting.sh

* Remove PyOpenGL-accelerate dependency

* Install latest pip in setup_software.sh

* Install latest pip in setup_software.sh

* Testing

* Testing

* Remove testing

* Bump pyqtgraph to 0.13.3

* Update setup_software.sh

* Try fixing precommit

* Try fixing precommit

* Try fixing precommit

* Replace black/autoflake with ruff

* Remove black binary

* Remove git attribute

* Remove unused check_formatting_ci.sh

* Run fix_formatting.sh

* Add simulated/field test fixtures to conftest.py

* Address UBC-Thunderbots#3251

* Python code cleanup and fix Thunderscope

* Enable pydocstyle rules in ruff

* Add compile pip requirements to pre-commit

* Formatting and fix pre-commit

* Fix pre-commit

* Fix pre-commit

* Fix pre-commit and fsm_diagram_generator.py

* Update docstrings

* Formatting

* Fix type errors

* Nuke jetson_nano/display :(

* Switch to pyqtdarktheme

* Bump pytqtgraph to 0.13.7

* If build fails, download autoref from Google Drive mirror

* Fix setup_software.sh

* If build fails, download autoref from releases in github fork

* Remove Qt deps from ER Force Simulator and improve code quality

* Remove Qt from bazel and setup_software.sh

* Misc code quality changes

* Rename formatting_scripts to scripts

* Fix docstring

* FIx docstring

* [pre-commit.ci lite] apply automatic fixes

* Add ASCII diagram to robotmesh.cpp

* Fix pyqtdarktheme dep missing

* Misc changes

* Nits

* Use python dataclasses, remove unused stuff, nits

* [pre-commit.ci lite] apply automatic fixes

* Use dataclass

* Update setup_software for Ubuntu 24 ARM

Start migrating to python3.12

* fixup installation issues

* Working on pybind11 compilation

* downgrade pybind11 slightly

* thunderscope is running, but slowly + autoref problems

* play around with newer protobuf version

* Fix python protobuf slowness

* update ssl protos

* resolve some build issues

* Seems to compile correctly on x86 Ubuntu 2020

* fix a whole bunch of issues and leave a bunch more

* Wip add support for new Tigers Autoref

* Remove auto_continue from old gamecontroller proto message

* Wip update autoref wrapper with new autoref

* [pre-commit.ci lite] apply automatic fixes

* Fixup last little niggly issues with game controller and autoref migration

* fixing up formatting

* migrate to gcc 10 and upgrade boost

* improve jetson toolchain

* work on nano build

* fix jetson nano

* fix ensurepip for ubuntu 24

* update linux gcc extlibs paths

* not yet compiling, adding arm64 support

* update cross compile toolchain names

* wip

* wip

* [pre-commit.ci lite] apply automatic fixes

* update setup software for pyqt6

* install nvm

* works on William (not William's) computer

* update g3log and some docs

* update tbots_protobuf_test

* [pre-commit.ci lite] apply automatic fixes

* update github 24 arm machine

* hopefully fix platform io in CI

* wip toolchain resolution issue

* fixup github builds mayhaps

* cleanup PR and fixup tests

* address PR comments

* cleanup documentation

* [pre-commit.ci lite] apply automatic fixes

* fixup clang format for ARM builds

---------

Co-authored-by: williamckha <[email protected]>
Co-authored-by: pre-commit-ci-lite[bot] <117423508+pre-commit-ci-lite[bot]@users.noreply.github.com>
Co-authored-by: arun <[email protected]>
Co-authored-by: wmostrenko <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants