version::qv stringification incorrectly adds a leading v
メンテナーはふだん 1 日以内に返信
まだ誰も着手していません。
評価
調査の方向性
Start in src/main/java/org/perlonjava/runtime/perlmodule/Version.java: read the forceQv branch of parseInternal and stringify(), which returns original after the branch stored a v-prefixed value there. Re-run the four-line qv reproducer against system Perl and PerlOnJava to confirm the divergence, and check how is_qv and version comparison consume the same fields so they keep working. Done looks like qv("1.2.31") printing 1.2.31 while comparison semantics stay unchanged; the Test::ConsistentVersion suite is the wider check.
索引モデルが issue の本文から書いたものです。
説明
Summary
version::qv("1.2.31") stringifies as v1.2.31 in PerlOnJava, while system Perl stringifies it as 1.2.31. This breaks consumers that use the stringified value as the declared distribution version. For example, Test::ConsistentVersion v0.3.1 fails changelog and README version checks under PerlOnJava, while its suite passes under system Perl.
Reproduction
use version;
my $v = qv("1.2.31");
print "$v\n";
Observed: PerlOnJava JVM backend and interpreter print v1.2.31; system Perl 5.42.2 prints 1.2.31.
Root cause
Version.qv() calls parseInternal(..., true). In the forceQv branch, parseInternal prepends v to the input and stores the prefixed value in the object’s original field. Version.stringify() returns original directly, making the implementation’s internal dotted-decimal representation visible during stringification.
The behavior appears in src/main/java/org/perlonjava/runtime/perlmodule/Version.java, in the forceQv handling and stringify() implementation.
Impact / evidence
The archived CPAN run reports 3 of 8 test programs failing. Failures come from Test::ConsistentVersion checks that compare the distribution version against changelog and README text. The package’s full test suite passes on system Perl. The missing optional Test::Pod::Content module is also absent on system Perl and is not the cause.
Expected behavior
Match system Perl’s stringification for qv("1.2.31") while retaining dotted-decimal / is_qv semantics for version comparison and normalization.
- 主要言語
- Perl
- スター
- 67
- フォーク
- 8
- 平均マージ
- 5時間 12分
- マージ済み PR(30日)
- 131
環境構築
- Dockerfile または Docker Compose ファイルあり
- プルリクエストのテンプレートなし
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
fglock/PerlOnJava のほかの issue
-
area:cpan-port bug
難易度 2/5 1〜3時間 初心者へのやさしさ 70/100
fglock/PerlOnJava#2153 ·
メンテナーはふだん 1 日以内に返信
-
area:cpan-port area:parser bug
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
fglock/PerlOnJava#2137 ·
メンテナーはふだん 1 日以内に返信
-
area:backend area:cpan-port area:runtime bug
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
fglock/PerlOnJava#2071 ·
メンテナーはふだん 1 日以内に返信
-
area:runtime documentation enhancement
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
fglock/PerlOnJava#1579 ·
メンテナーはふだん 1 日以内に返信
-
area:cpan-port bug
難易度 3/5 1〜2日 初心者へのやさしさ 62/100
fglock/PerlOnJava#2157 ·
メンテナーはふだん 1 日以内に返信
fglock/PerlOnJava の issue をすべて見る
似ている issue
-
Dev-output directory preparation accepts file-valued lib/include paths and fails on dangling linksオープンteam-cli
難易度 2/5 1〜3時間 初心者へのやさしさ 70/100
メンテナーはふだん 2 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 66/100
-
難易度 1/5 1時間未満 初心者へのやさしさ 93/100
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 73/100
inverse-inc/packetfence#9728 ·
メンテナーはふだん 1 日以内に返信
-
fix(char-create): show the real reason a character is refused対応中かも @baphomello が 1 日前に担当しました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 84/100
メンテナーはふだん 1 日以内に返信