Skip to content

Commit b390a01

Browse files
authored
Merge branch 'main' into feature/goalie-behavior-descend
2 parents ac08594 + 26c7f19 commit b390a01

File tree

753 files changed

+3915
-3407
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

753 files changed

+3915
-3407
lines changed

.devcontainer/Dockerfile

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,6 @@ RUN apt-get update -y \
3232
tree \
3333
uvcdynctrl \
3434
vim \
35-
vlc \
3635
wget \
3736
x11-apps \
3837
zsh

.github/workflows/pre-commit.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ on:
77

88
jobs:
99
pre-commit:
10-
runs-on: ubuntu-latest
10+
runs-on: ubuntu-22.04
1111
steps:
1212
- uses: actions/checkout@v4
1313
- uses: actions/setup-python@v4

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -227,3 +227,5 @@ doku/*
227227

228228
# Workspace git status file from the deploy tool
229229
**/workspace_status.json
230+
231+
.pytest_cache/

.vscode/settings.json

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,6 +112,7 @@
112112
"throwin",
113113
"timespec",
114114
"tldr",
115+
"torqueless",
115116
"tqdm",
116117
"unpenalize",
117118
"unpenalized",
@@ -212,7 +213,9 @@
212213
"variant": "cpp",
213214
"regex": "cpp",
214215
"future": "cpp",
215-
"*.ipp": "cpp"
216+
"*.ipp": "cpp",
217+
"span": "cpp",
218+
"ranges": "cpp"
216219
},
217220
// Tell the ROS extension where to find the setup.bash
218221
// This also utilizes the COLCON_WS environment variable, which needs to be set

Makefile

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,8 @@ install-no-root: pull-init update-no-root
1717

1818
pip:
1919
# Install and upgrade pip dependencies
20-
pip install --upgrade -r requirements/dev.txt --user
20+
pip install --upgrade pip --user
21+
pip install --upgrade -r requirements/dev.txt --user -v
2122

2223
pre-commit:
2324
# Install pre-commit hooks for all submodules that have a .pre-commit-config.yaml file
@@ -47,6 +48,8 @@ pull-files:
4748
wget \
4849
--no-verbose \
4950
--show-progress \
51+
--timeout=15 \
52+
--tries=2 \
5053
--recursive \
5154
--timestamping \
5255
--no-parent \
@@ -57,6 +60,8 @@ pull-files:
5760
wget \
5861
--no-verbose \
5962
--show-progress \
63+
--timeout=15 \
64+
--tries=2 \
6065
--recursive \
6166
--timestamping \
6267
--no-parent \
@@ -86,7 +91,7 @@ rosdep:
8691
# Initialize rosdep if not already done
8792
[ -f /etc/ros/rosdep/sources.list.d/20-default.list ] || sudo rosdep init
8893
# Update rosdep and install dependencies from meta directory
89-
rosdep update
94+
rosdep update --include-eol-distros
9095
rosdep install --from-paths . --ignore-src --rosdistro iron -y
9196

9297
status:

bitbots_behavior/bitbots_blackboard/CMakeLists.txt

Lines changed: 6 additions & 70 deletions
Original file line numberDiff line numberDiff line change
@@ -1,80 +1,16 @@
11
cmake_minimum_required(VERSION 3.5)
22
project(bitbots_blackboard)
33

4-
# Add support for C++17
5-
if(NOT CMAKE_CXX_STANDARD)
6-
set(CMAKE_CXX_STANDARD 17)
7-
endif()
8-
9-
find_package(bio_ik_msgs REQUIRED)
10-
find_package(ament_cmake REQUIRED)
11-
find_package(sensor_msgs REQUIRED)
12-
find_package(rclpy REQUIRED)
13-
find_package(tf2 REQUIRED)
14-
find_package(bitbots_msgs REQUIRED)
15-
find_package(std_msgs REQUIRED)
16-
find_package(tf2_geometry_msgs REQUIRED)
17-
find_package(std_srvs REQUIRED)
18-
find_package(geometry_msgs REQUIRED)
194
find_package(bitbots_docs REQUIRED)
5+
find_package(ament_cmake REQUIRED)
6+
find_package(ament_cmake_python REQUIRED)
207

21-
set(INCLUDE_DIRS
22-
${bio_ik_msgs_INCLUDE_DIRS}
23-
${ament_cmake_INCLUDE_DIRS}
24-
${sensor_msgs_INCLUDE_DIRS}
25-
${rclpy_INCLUDE_DIRS}
26-
${tf2_INCLUDE_DIRS}
27-
${bitbots_msgs_INCLUDE_DIRS}
28-
${std_msgs_INCLUDE_DIRS}
29-
${tf2_geometry_msgs_INCLUDE_DIRS}
30-
${std_srvs_INCLUDE_DIRS}
31-
${geometry_msgs_INCLUDE_DIRS}
32-
${bitbots_docs_INCLUDE_DIRS})
33-
include_directories(${INCLUDE_DIRS})
34-
35-
set(LIBRARY_DIRS
36-
${bio_ik_msgs_LIBRARY_DIRS}
37-
${ament_cmake_LIBRARY_DIRS}
38-
${sensor_msgs_LIBRARY_DIRS}
39-
${rclpy_LIBRARY_DIRS}
40-
${tf2_LIBRARY_DIRS}
41-
${bitbots_msgs_LIBRARY_DIRS}
42-
${std_msgs_LIBRARY_DIRS}
43-
${tf2_geometry_msgs_LIBRARY_DIRS}
44-
${std_srvs_LIBRARY_DIRS}
45-
${geometry_msgs_LIBRARY_DIRS}
46-
${bitbots_docs_LIBRARY_DIRS})
47-
48-
link_directories(${LIBRARY_DIRS})
49-
50-
set(LIBS
51-
${bio_ik_msgs_LIBRARIES}
52-
${ament_cmake_LIBRARIES}
53-
${sensor_msgs_LIBRARIES}
54-
${rclpy_LIBRARIES}
55-
${tf2_LIBRARIES}
56-
${bitbots_msgs_LIBRARIES}
57-
${std_msgs_LIBRARIES}
58-
${tf2_geometry_msgs_LIBRARIES}
59-
${std_srvs_LIBRARIES}
60-
${geometry_msgs_LIBRARIES}
61-
${bitbots_docs_LIBRARIES})
62-
63-
include(${CMAKE_BINARY_DIR}/../bitbots_docs/enable_bitbots_docs.cmake)
648
enable_bitbots_docs()
659

66-
ament_export_dependencies(bio_ik_msgs)
67-
ament_export_dependencies(ament_cmake)
68-
ament_export_dependencies(sensor_msgs)
69-
ament_export_dependencies(rclpy)
70-
ament_export_dependencies(tf2)
71-
ament_export_dependencies(bitbots_msgs)
72-
ament_export_dependencies(std_msgs)
73-
ament_export_dependencies(tf2_geometry_msgs)
74-
ament_export_dependencies(std_srvs)
75-
ament_export_dependencies(geometry_msgs)
76-
ament_export_dependencies(bitbots_docs)
77-
ament_export_include_directories(${INCLUDE_DIRS})
10+
if(BUILD_TESTING)
11+
find_package(ament_cmake_mypy REQUIRED)
12+
ament_mypy(CONFIG_FILE "${CMAKE_CURRENT_LIST_DIR}/mypy.ini")
13+
endif()
7814

7915
ament_python_install_package(${PROJECT_NAME})
8016

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
# Setting up runtime type checking for this package
2+
from beartype.claw import beartype_this_package
3+
4+
beartype_this_package()

bitbots_behavior/bitbots_blackboard/bitbots_blackboard/body_blackboard.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313

1414

1515
class BodyBlackboard:
16-
def __init__(self, node: Node, tf_buffer: tf2.Buffer):
16+
def __init__(self, node: Node, tf_buffer: tf2.BufferInterface):
1717
# References
1818
self.node = node
1919
self.tf_buffer = tf_buffer
Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
1-
from typing import TYPE_CHECKING, Optional
1+
from typing import TYPE_CHECKING
22

3+
from bitbots_utils.utils import nobeartype
34
from rclpy.node import Node
45

56
if TYPE_CHECKING:
@@ -9,6 +10,7 @@
910
class AbstractBlackboardCapsule:
1011
"""Abstract class for blackboard capsules."""
1112

12-
def __init__(self, node: Node, blackboard: Optional["BodyBlackboard"] = None):
13+
@nobeartype
14+
def __init__(self, node: Node, blackboard: "BodyBlackboard"):
1315
self._node = node
1416
self._blackboard = blackboard

bitbots_behavior/bitbots_blackboard/bitbots_blackboard/capsules/animation_capsule.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,8 @@ def __init__(self, node, blackboard):
1414
self.active = False
1515

1616
# Config
17+
self.grab_ball_animation: str = self._node.get_parameter("Animations.Throw_in.grabBall").value
18+
self.throw_animation: str = self._node.get_parameter("Animations.Throw_in.throw").value
1719
self.goalie_arms_animation: str = self._node.get_parameter("Animations.Goalie.goalieArms").value
1820
self.goalie_falling_right_animation: str = self._node.get_parameter("Animations.Goalie.fallRight").value
1921
self.goalie_falling_left_animation: str = self._node.get_parameter("Animations.Goalie.fallLeft").value

0 commit comments

Comments
 (0)