Skip to content

Defer annotation evaluation to fix RHEL import. (backport #309)#317

Open
mergify[bot] wants to merge 1 commit into
kiltedfrom
mergify/bp/kilted/pr-309
Open

Defer annotation evaluation to fix RHEL import. (backport #309)#317
mergify[bot] wants to merge 1 commit into
kiltedfrom
mergify/bp/kilted/pr-309

Conversation

@mergify

@mergify mergify Bot commented Jun 22, 2026

Copy link
Copy Markdown

Description

message_filters annotates callback parameters with typing.Concatenate which was only added in Python 3.10. On Python 3.9 (RHEL 9) importing message_filters raises:

      AttributeError: module 'typing' has no attribute 'Concatenate'

This fails every message_filters Python test at collection time on the jazzy

Adding from __future__ import annotations (PEP 563) to the two affected modules stores these annotations as strings, so typing.Concatenate is never evaluated at import, restoring Python 3.9 compatibility.

Is this user-facing behavior change?

No. Annotations aren't introspected at runtime and @dataclass works with string annotations. No API/ABI change.

Did you use Generative AI?

Yes, Claude Opus 4.8 was used for the fix.

Additional Information


This is an automatic backport of pull request #309 done by [Mergify](https://mergify.com).

Signed-off-by: Marco A. Gutierrez <marcogg@marcogg.com>
(cherry picked from commit d1b4e46)
@mergify

mergify Bot commented Jun 22, 2026

Copy link
Copy Markdown
Author

Tick the box to add this pull request to the merge queue (same as @mergifyio queue).

  • Queue this pull request

@ahcorde

ahcorde commented Jun 22, 2026

Copy link
Copy Markdown
Contributor

Pulls: #317
Gist: https://gist.githubusercontent.com/ahcorde/4e82b27bdd41bf94ab5b2ad8c6390ab7/raw/d6cb67482f9605635b5e3c315fd59c73f83f1d96/ros2.repos
BUILD args: --packages-above-and-dependencies message_filters
TEST args: --packages-above message_filters
ROS Distro: kilted
Job: ci_launcher
ci_launcher ran: https://ci.ros2.org/job/ci_launcher/19622

  • Linux Build Status
  • Linux-aarch64 Build Status
  • Linux-rhel Build Status
  • Windows Build Status

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.

2 participants