oracle / oracle/graalpython

Using the maven plugin with the default VirtualFileSystem leads to pathlib.Path.exists not working

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

@tstupka がすでに取り組んでいます。

2024年6月21日 から。

good first issue
主要言語
Python
スター
1.6k
フォーク
155
平均マージ
9時間 42分
マージ済み PR(30日)
36

説明

This can be observed when using pyfiglet with the maven plugin. The code of pyfiglet has this

path = importlib.resources.files('pyfiglet.fonts').joinpath(fn)
if path.exists():
    ...

path.exists() uses a stat call, and we raise (correctly) OSError for non-existing paths. But pathlib checks that the errno of that error is in a list of allowed errors, and otherwise just throws the exception upwards. The OSError raised from the VirtualFileSystem is errno 5: EIO, it should probably be errno 2: ENOENT.

コントリビューションガイド

コントリビューションガイドを開く

はじめの一歩

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

評価

この issue はまだ評価されていません。

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

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