@@ -1605,13 +1605,21 @@ msgid ""
1605
1605
"module. ``find_spec()`` returns a fully populated spec for the module. This "
1606
1606
"spec will always have \" loader\" set (with one exception)."
1607
1607
msgstr ""
1608
+ ":meth:`~importlib.abc.PathEntryFinder.find_spec` は 2 つの引数を取ります。イ"
1609
+ "ンポートしようとしているモジュールの完全修飾名と、 (オプションの) 対象モ"
1610
+ "ジュールです。 `find_spec()` はモジュールに対応する完全に初期化 (populated) "
1611
+ "された仕様を返します。この仕様は (1つの例外を除いて) 常に \" loader\" セットを"
1612
+ "持っています。"
1608
1613
1609
1614
#: ../../reference/import.rst:859
1610
1615
msgid ""
1611
1616
"To indicate to the import machinery that the spec represents a namespace :"
1612
1617
"term:`portion`, the path entry finder sets \" submodule_search_locations\" to "
1613
1618
"a list containing the portion."
1614
1619
msgstr ""
1620
+ "モジュール仕様が名前空間 :term:`ポーション <portion>` を表していることをイン"
1621
+ "ポート機構に示すために、パスエントリ・ファインダーはモジュール仕様の "
1622
+ "\" submodule_search_locations\" を名前空間ポーションを含むリストに設定します。"
1615
1623
1616
1624
#: ../../reference/import.rst:863
1617
1625
msgid ""
@@ -1713,6 +1721,12 @@ msgid ""
1713
1721
"latter indicates that the meta path search should continue, while raising an "
1714
1722
"exception terminates it immediately."
1715
1723
msgstr ""
1724
+ "(標準のインポートシステム全体を停止するのではなく) すでにメタパスにいるフック"
1725
+ "からあるモジュールのインポートを選択的に防ぐためには、 :meth:`~importlib.abc."
1726
+ "MetaPathFinder.find_spec` から ``None`` を返す代わりに、直接 :exc:"
1727
+ "`ModuleNotFoundError` を送出するだけで十分です。 ``None`` を返すのはメタパス"
1728
+ "の走査を続けるべきであることを意味しますが、例外を送出するとすぐに走査を打ち"
1729
+ "切ります。"
1716
1730
1717
1731
#: ../../reference/import.rst:916
1718
1732
msgid "Package Relative Imports"
0 commit comments