Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

[K-Bug] AssertionError for incomplete rule

オープン
#4,613 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

評価

難易度
3/5
見積もり時間
1〜2日
初心者へのやさしさ
45/100
issue の種類
バグ
明瞭さ
明確に書かれている
活発さ
停滞
技術スタック
java
領域
cli, compilers

調査の方向性

Reproduce the failure with kompile a.k using the definition shown in the issue. Start at Outer.offsetLine, following the stack through Outer.makeStringSentence and Outer.Bubble, and inspect how the end-of-stream IOException is handled. Done means incomplete rules produce a reasonable error containing the relevant line and column instead of an AssertionError.

索引モデルが issue の本文から書いたものです。

説明

What component is the issue in?

Front-End

Which command
  • kompile
  • kast
  • krun
  • kprove
  • kprovex
  • ksearch
What K Version?

v7.1.121-0-g894298664c

Operating System

Linux

K Definitions (If Possible)

a.k:

module A
  imports INT

  rule [my-rule]:
  rule 1 => 2
endmodule
Steps to Reproduce
kompile a.k

This produces the following error:

[Error] Internal: Uncaught exception thrown of type AssertionError.
Please rerun your program with the --debug flag to generate a stack trace, and
file a bug report at https://github.com/runtimeverification/k/issues
(AssertionError: did not expect IOException)

If I run kompile with --debug:

java.lang.AssertionError: did not expect IOException
        at org.kframework.parser.outer.Outer.offsetLine(Outer.java:270)
        at org.kframework.parser.outer.Outer.makeStringSentence(Outer.java:223)
        at org.kframework.parser.outer.Outer.Bubble(Outer.java:442)
        at org.kframework.parser.outer.Outer.Sentence(Outer.java:749)
        at org.kframework.parser.outer.Outer.Module(Outer.java:661)
        at org.kframework.parser.outer.Outer.Start(Outer.java:607)
        at org.kframework.parser.outer.Outer.parse(Outer.java:79)
        at org.kframework.parser.ParserUtils.slurp(ParserUtils.java:117)
        at org.kframework.parser.ParserUtils.loadModules(ParserUtils.java:220)
        at org.kframework.parser.ParserUtils.loadDefinition(ParserUtils.java:393)
        at org.kframework.parser.ParserUtils.loadDefinition(ParserUtils.java:355)
        at org.kframework.kompile.DefinitionParsing.parseDefinition(DefinitionParsing.java:308)
        at org.kframework.kompile.DefinitionParsing.parseDefinitionAndResolveBubbles(DefinitionParsing.java:231)
        at org.kframework.kompile.Kompile.parseDefinition(Kompile.java:389)
        at org.kframework.kompile.Kompile.run(Kompile.java:212)
        at org.kframework.kompile.KompileFrontEnd.run(KompileFrontEnd.java:91)
        at org.kframework.main.FrontEnd.main(FrontEnd.java:60)
        at org.kframework.main.Main.runApplication(Main.java:127)
        at org.kframework.main.Main.runApplication(Main.java:117)
        at org.kframework.main.Main.main(Main.java:58)
Caused by: java.io.IOException: PGCC end of stream
        at org.kframework.parser.outer.AbstractCharStream.fillBuff(AbstractCharStream.java:278)
        at org.kframework.parser.outer.AbstractCharStream.readChar(AbstractCharStream.java:367)
        at org.kframework.parser.outer.Outer.offsetLine(Outer.java:269)
        ... 19 more
[Error] Internal: Uncaught exception thrown of type AssertionError
(AssertionError: did not expect IOException)
Expected Results

A reasonable error containing the line and column where the error occurred.

主要言語
Python
スター
598
フォーク
164
PR マージ指標
30日以内にマージされた PR はありません

環境構築

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

runtimeverification/k のほかの issue

runtimeverification/k の issue をすべて見る

似ている issue

Python の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。