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

New tagged union validation errors are basically unreadable

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

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

評価

難易度
4/5
見積もり時間
3〜5日
初心者へのやさしさ
42/100
issue の種類
バグ
明瞭さ
おおむね明確
活発さ
停滞
技術スタック
python
領域
backend

調査の方向性

The issue includes a long Pydantic validation traceback for crafting pages and recipes, but does not name source files or tests. Start by locating the tagged-union validation error handling and its tests, then reproduce the reported failure. Done means the validation errors are substantially more readable without losing useful detail.

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

説明

bug
pydantic_core._pydantic_core.ValidationError: 4 validation errors for Entry
pages.0.Page
  Failed to match tagged union <class 'hexdoc.patchouli.page.abstract_pages.Page'>: No match found
  Tag: type=patchouli:crafting
  Types: <class 'hexdoc.patchouli.page.pages.CraftingPage'>
  Data: {'type': 'patchouli:crafting', 'recipe': 'hexgloop:slate_chest', 'text': 'hexgloop.page.chests.normal', '__resolved': True} [type=TaggedUnionMatchErrorGroup, input_value={'type': 'patchouli:craft...oop.page.chests.normal'}, input_type=dict]
pages.0.Page.CraftingPage
  Failed to match tagged union: 2 validation errors for CraftingPage
recipe.CraftingRecipe
  Failed to match tagged union <class 'hexdoc.minecraft.recipe.abstract_recipes.CraftingRecipe'>: No match found
  Tag: type=minecraft:crafting_shaped
  Types: <class 'hexdoc.minecraft.recipe.recipes.CraftingShapedRecipe'>
  Data: {'type': 'minecraft:crafting_shaped', 'pattern': [' S ', 'SCS', ' S '], 'key': {'S': {'item': 'hexcasting:slate', '__resolved': True}, 'C': {'item': 'minecraft:chest'}}, 'result': {'item': 'hexgloop:slate_chest'}, 'id': hexgloop:slate_chest, 'resource_dir': PathResourceDir(external=True, reexport=False, path=WindowsPath('C:/Users/.../Git/HexBug/venv/Lib/site-packages/hexdoc_hexgloop/_export/generated'), required=True), '__resolved': True} [type=TaggedUnionMatchErrorGroup, input_value={'type': 'minecraft:craft...rated'), required=True)}, input_type=dict]
recipe.CraftingRecipe.CraftingShapedRecipe
  Failed to match tagged union: 3 validation errors for CraftingShapedRecipe
key.C.0.ItemIngredient
  Failed to match tagged union <class 'hexdoc.minecraft.recipe.ingredients.ItemIngredient'>: No match found
  Tag: type=NoValue
  Types: <class 'hexdoc.minecraft.recipe.ingredients.MinecraftItemTagIngredient'>, <class 'hexdoc.minecraft.recipe.ingredients.MinecraftItemIdIngredient'>
  Data: {'item': 'minecraft:chest', '__resolved': True} [type=TaggedUnionMatchErrorGroup, input_value={'item': 'minecraft:chest'}, input_type=dict]
key.C.0.ItemIngredient.MinecraftItemTagIngredient
  Failed to match tagged union: 2 validation errors for MinecraftItemTagIngredient
tag
  Field required [type=missing, input_value={'item': 'minecraft:chest'}, input_type=dict]
    For further information visit https://errors.pydantic.dev/2.5/v/missing
item
  Extra inputs are not permitted [type=extra_forbidden, input_value='minecraft:chest', input_type=str]
    For further information visit https://errors.pydantic.dev/2.5/v/extra_forbidden [type=TaggedUnionMatchError, input_value={'item': 'minecraft:chest'}, input_type=dict]
key.C.0.ItemIngredient.MinecraftItemIdIngredient
  Failed to match tagged union: 4 validation errors for MinecraftItemIdIngredient
item.texture.function-wrap[_wrap_root_load_from_id()]
  Value error, No PNGTexture for minecraft:chest [type=value_error, input_value=minecraft:chest, input_type=ResourceLocation]
    For further information visit https://errors.pydantic.dev/2.5/v/value_error
item.texture.function-wrap[_wrap_root_load_from_id()]
  Value error, No AnimatedTexture for minecraft:chest [type=value_error, input_value=minecraft:chest, input_type=ResourceLocation]
    For further information visit https://errors.pydantic.dev/2.5/v/value_error
item.texture.function-wrap[_wrap_root_load_from_id()]
  Value error, No SingleItemTexture for minecraft:chest [type=value_error, input_value=minecraft:chest, input_type=ResourceLocation]
    For further information visit https://errors.pydantic.dev/2.5/v/value_error
item.texture.function-wrap[_wrap_root_load_from_id()]
  Value error, No MultiItemTexture for minecraft:chest [type=value_error, input_value=minecraft:chest, input_type=ResourceLocation]
    For further information visit https://errors.pydantic.dev/2.5/v/value_error [type=TaggedUnionMatchError, input_value={'item': 'minecraft:chest'}, input_type=dict] [type=TaggedUnionMatchError, input_value={'type': 'minecraft:craft...rated'), required=True)}, input_type=dict] [type=TaggedUnionMatchError, input_value={'type': 'patchouli:craft...oop.page.chests.normal'}, input_type=dict]
pages.1.Page
  Failed to match tagged union <class 'hexdoc.patchouli.page.abstract_pages.Page'>: No match found
  Tag: type=patchouli:crafting
  Types: <class 'hexdoc.patchouli.page.pages.CraftingPage'>
  Data: {'type': 'patchouli:crafting', 'recipe': 'hexgloop:gloopy_slate_chest', 'text': 'hexgloop.page.chests.gloopy', '__resolved': True} [type=TaggedUnionMatchErrorGroup, input_value={'type': 'patchouli:craft...oop.page.chests.gloopy'}, input_type=dict]
pages.1.Page.CraftingPage
  Failed to match tagged union: 2 validation errors for CraftingPage
recipe.CraftingRecipe
  Failed to match tagged union <class 'hexdoc.minecraft.recipe.abstract_recipes.CraftingRecipe'>: No match found
  Tag: type=minecraft:crafting_shaped
  Types: <class 'hexdoc.minecraft.recipe.recipes.CraftingShapedRecipe'>
  Data: {'type': 'minecraft:crafting_shaped', 'pattern': [' S ', 'SCS', ' G '], 'key': {'S': {'item': 'hexcasting:slate', '__resolved': True}, 'C': {'item': 'minecraft:chest'}, 'G': {'item': 'hexgloop:gloop', '__resolved': True}}, 'result': {'item': 'hexgloop:gloopy_slate_chest'}, 'id': hexgloop:gloopy_slate_chest, 'resource_dir': PathResourceDir(external=True, reexport=False, path=WindowsPath('C:/Users/.../Git/HexBug/venv/Lib/site-packages/hexdoc_hexgloop/_export/generated'), required=True), '__resolved': True} [type=TaggedUnionMatchErrorGroup, input_value={'type': 'minecraft:craft...rated'), required=True)}, input_type=dict]
recipe.CraftingRecipe.CraftingShapedRecipe
  Failed to match tagged union: 3 validation errors for CraftingShapedRecipe
key.C.0.ItemIngredient
  Failed to match tagged union <class 'hexdoc.minecraft.recipe.ingredients.ItemIngredient'>: No match found
  Tag: type=NoValue
  Types: <class 'hexdoc.minecraft.recipe.ingredients.MinecraftItemTagIngredient'>, <class 'hexdoc.minecraft.recipe.ingredients.MinecraftItemIdIngredient'>
  Data: {'item': 'minecraft:chest', '__resolved': True} [type=TaggedUnionMatchErrorGroup, input_value={'item': 'minecraft:chest'}, input_type=dict]
key.C.0.ItemIngredient.MinecraftItemTagIngredient
  Failed to match tagged union: 2 validation errors for MinecraftItemTagIngredient
tag
  Field required [type=missing, input_value={'item': 'minecraft:chest'}, input_type=dict]
    For further information visit https://errors.pydantic.dev/2.5/v/missing
item
  Extra inputs are not permitted [type=extra_forbidden, input_value='minecraft:chest', input_type=str]
    For further information visit https://errors.pydantic.dev/2.5/v/extra_forbidden [type=TaggedUnionMatchError, input_value={'item': 'minecraft:chest'}, input_type=dict]
key.C.0.ItemIngredient.MinecraftItemIdIngredient
  Failed to match tagged union: 4 validation errors for MinecraftItemIdIngredient
item.texture.function-wrap[_wrap_root_load_from_id()]
  Value error, No PNGTexture for minecraft:chest [type=value_error, input_value=minecraft:chest, input_type=ResourceLocation]
    For further information visit https://errors.pydantic.dev/2.5/v/value_error
item.texture.function-wrap[_wrap_root_load_from_id()]
  Value error, No AnimatedTexture for minecraft:chest [type=value_error, input_value=minecraft:chest, input_type=ResourceLocation]
    For further information visit https://errors.pydantic.dev/2.5/v/value_error
item.texture.function-wrap[_wrap_root_load_from_id()]
  Value error, No SingleItemTexture for minecraft:chest [type=value_error, input_value=minecraft:chest, input_type=ResourceLocation]
    For further information visit https://errors.pydantic.dev/2.5/v/value_error
item.texture.function-wrap[_wrap_root_load_from_id()]
  Value error, No MultiItemTexture for minecraft:chest [type=value_error, input_value=minecraft:chest, input_type=ResourceLocation]
    For further information visit https://errors.pydantic.dev/2.5/v/value_error [type=TaggedUnionMatchError, input_value={'item': 'minecraft:chest'}, input_type=dict] [type=TaggedUnionMatchError, input_value={'type': 'minecraft:craft...rated'), required=True)}, input_type=dict] [type=TaggedUnionMatchError, input_value={'type': 'patchouli:craft...oop.page.chests.gloopy'}, input_type=dict]
主要言語
Python
スター
7
フォーク
10
PR マージ指標
30日以内にマージされた PR はありません

環境構築

このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。

はじめの一歩

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

hexdoc-dev/hexdoc のほかの issue

hexdoc-dev/hexdoc の issue をすべて見る

似ている issue

Python の issue をもっと見る

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

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