diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 2badd49..08c059f 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -15,7 +15,7 @@ repos: # Standard hooks - repo: https://github.com/pre-commit/pre-commit-hooks - rev: v5.0.0 + rev: v6.0.0 hooks: - id: check-added-large-files - id: check-ast @@ -34,13 +34,13 @@ repos: # Python hooks - repo: https://github.com/asottile/pyupgrade - rev: v3.19.1 + rev: v3.21.2 hooks: - id: pyupgrade args: [--py36-plus] - repo: https://github.com/astral-sh/ruff-pre-commit - rev: v0.8.4 + rev: v0.15.6 hooks: - id: ruff args: [ --fix ] @@ -48,7 +48,7 @@ repos: # CPP hooks - repo: https://github.com/pre-commit/mirrors-clang-format - rev: v14.0.3 + rev: v22.1.1 hooks: - id: clang-format args: ['-fallback-style=none', '-i'] @@ -93,7 +93,7 @@ repos: # Docs - RestructuredText hooks - repo: https://github.com/PyCQA/doc8 - rev: v1.1.2 + rev: v2.0.0 hooks: - id: doc8 args: ['--max-line-length=100', '--ignore=D001'] @@ -110,14 +110,14 @@ repos: # Spellcheck in comments and docs # skipping of *.svg files is not working... - repo: https://github.com/codespell-project/codespell - rev: v2.3.0 + rev: v2.4.2 hooks: - id: codespell args: ['--write-changes'] exclude: CHANGELOG\.rst|\.(svg|pyc)$ - repo: https://github.com/python-jsonschema/check-jsonschema - rev: 0.30.0 + rev: 0.37.0 hooks: - id: check-github-workflows args: ["--verbose"] diff --git a/src/standard_robot_pp_ros2.cpp b/src/standard_robot_pp_ros2.cpp index 07f0b34..5048cf5 100644 --- a/src/standard_robot_pp_ros2.cpp +++ b/src/standard_robot_pp_ros2.cpp @@ -295,7 +295,7 @@ void StandardRobotPpRos2Node::receiveData() // sof[0] == SOF_RECEIVE 后读取剩余 header_frame 内容 std::vector header_frame_buf(3); // sof 在读取完数据后添加 - serial_driver_->port()->receive(header_frame_buf); // 读取除 sof 外剩下的数据 + serial_driver_->port()->receive(header_frame_buf); // 读取除 sof 外剩下的数据 header_frame_buf.insert(header_frame_buf.begin(), sof[0]); // 添加 sof HeaderFrame header_frame = fromVector(header_frame_buf);