Hacktoberfest 2026: những issue maintainer đã đánh dấu cho tháng Mười, đang mở và phù hợp người mới. Xem issue Hacktoberfest

Data::Dumper::Simple 0.11 fails because Filter::Simple source filtering is not applied correctly

Đang mở
#1,375 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Chưa có ai nhận issue này.

Đánh giá

Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức phù hợp với người mới
52/100
Loại issue
Lỗi
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
perl
Lĩnh vực
compilers

Hướng nghiên cứu

Bắt đầu bằng cách chạy jperl -Ilib t/10dump.t và lệnh --interpreter tương ứng, sau đó so sánh các upstream test đang thất bại t/20import.t, t/30autowarn.t và t/40noparens.t. Đọc phần đăng ký và áp dụng source-filter sau các câu lệnh use, đặc biệt là phần tích hợp Filter::Util::Call/Filter::Simple và việc token hóa lại phần mã nguồn còn lại. Công việc được xem là hoàn tất khi cả bốn test đều pass trên cả hai backend và một regression test tập trung, do dự án sở hữu, bao quát hành vi của filter.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

bug

Summary

Data::Dumper::Simple v0.11 fails its upstream test suite under PerlOnJava because its Filter::Simple source filter does not transform calls made after the module is imported.

This was observed in CPAN random tester run 20260913-205737-64746.

Reproduction

The upstream test suite passes under system Perl:

  • 4 substantive test programs passed
  • 35 tests passed in total
  • The optional POD tests were skipped because their optional dependencies/files were unavailable

The same upstream tests fail under both PerlOnJava backends:

  • JVM backend: t/10dump.t, t/20import.t, t/30autowarn.t, and t/40noparens.t fail
  • Interpreter backend: the same four tests fail

Representative commands:

jperl -Ilib t/10dump.t
jperl --interpreter -Ilib t/10dump.t

Observed failures

  • t/10dump.t: Undefined subroutine &main::Dumper
  • t/20import.t: Undefined subroutine &main::frobnitz
  • t/30autowarn.t: Undefined subroutine &main::Dumper
  • t/40noparens.t: Global symbol "$hash" requires explicit package name

Each failing test reports that it ran only its initial use_ok test before aborting.

Expected behavior

use Data::Dumper::Simple installs a Filter::Simple source filter. Calls such as:

Dumper($scalar, @array, %hash)

should be rewritten at compile time to an equivalent Data::Dumper->Dump call. The as => 'frobnitz' and autowarn options, as well as no-parentheses syntax, should work as they do under system Perl.

Initial diagnosis

The distribution is pure Perl and has no XS, native-library, display, network-service, or other platform prerequisite involved in these tests. The failures occur identically on the JVM and interpreter backends, indicating a shared frontend/source-filter compatibility problem rather than a backend-specific runtime issue.

The module uses Filter::Simple with FILTER_ONLY executable. The missing generated subroutine calls indicate that the filter is either not being applied to the remaining source after the import or its transformed source is not being correctly re-tokenized/compiled. The strict-vars error in t/40noparens.t is consistent with the no-parentheses source-filter path failing to produce the expected transformed expression.

Relevant implementation areas include source-filter registration and application after use statements, especially the Filter::Util::Call/Filter::Simple integration and remaining-source re-tokenization in the frontend.

Acceptance criteria

  • All four substantive Data::Dumper::Simple test programs pass on the JVM backend.
  • The same tests pass on the interpreter backend.
  • as => 'frobnitz', autowarn, and no-parentheses calls are covered.
  • Add a project-owned focused regression test for the underlying source-filter behavior; retain the upstream distribution tests as integration coverage.

Environment

  • CPAN random tester run: 20260913-205737-64746
  • Distribution: Data-Dumper-Simple-0.11
  • Affected backends: JVM and interpreter
  • System Perl: full substantive suite passes
Ngôn ngữ chính
Perl
Star
64
Fork
6
Merge trung bình
5 giờ 38 phút
Pull request đã merge (30 ngày)
170

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của fglock/PerlOnJava

Tất cả issue của fglock/PerlOnJava

Issue tương tự

Thêm issue về Perl

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.