Python 2.7 はサポートが終了しており、2026 年 1 月 31 日に
非推奨になります。非推奨になると、過去に組織のポリシーを使用して以前のランタイムのデプロイを再度有効にしていた場合でも、Python 2.7 アプリケーションをデプロイできなくなります。既存の Python 2.7 アプリケーションは、
非推奨日以降も引き続き実行され、トラフィックを受信します。
サポートされている最新バージョンの Python に移行することをおすすめします。
メッセージ モジュールの例外
コレクションでコンテンツを整理
必要に応じて、コンテンツの保存と分類を行います。
protorpc.messages
パッケージは、次の例外クラスを提供します。
- class DecodeError()
- エンコードされたメッセージのデコード中にエラーが発生した場合に送出されます。
- class DefinitionNotFoundError()
- 定義が見つからない場合に送出されます。
- class DuplicateNumberError()
- フィールドに重複した番号が割り当てられている場合に送出されます。
- class EnumDefinitionError()
- Enum 定義にエラーがある場合に送出されます。
- class FieldDefinitionError()
- フィールド定義にエラーがある場合に送出されます。
- class InvalidDefaultError()
- フィールドに無効なデフォルト値が指定された場合に送出されます。
- class InvalidNumberError()
- フィールドに無効な番号が指定された場合に送出されます。
- class InvalidVariantError()
- フィールドに無効なバリアントが指定された場合に送出されます。
- class MessageDefinitionError()
- メッセージ定義にエラーがある場合に送出されます。
- class ValidationError()
- メッセージに無効な値がある場合に送出されます。
特に記載のない限り、このページのコンテンツはクリエイティブ・コモンズの表示 4.0 ライセンスにより使用許諾されます。コードサンプルは Apache 2.0 ライセンスにより使用許諾されます。詳しくは、Google Developers サイトのポリシーをご覧ください。Java は Oracle および関連会社の登録商標です。
最終更新日 2025-09-04 UTC。
[[["わかりやすい","easyToUnderstand","thumb-up"],["問題の解決に役立った","solvedMyProblem","thumb-up"],["その他","otherUp","thumb-up"]],[["わかりにくい","hardToUnderstand","thumb-down"],["情報またはサンプルコードが不正確","incorrectInformationOrSampleCode","thumb-down"],["必要な情報 / サンプルがない","missingTheInformationSamplesINeed","thumb-down"],["翻訳に関する問題","translationIssue","thumb-down"],["その他","otherDown","thumb-down"]],["最終更新日 2025-09-04 UTC。"],[[["\u003cp\u003eThe \u003ccode\u003eprotorpc.messages\u003c/code\u003e package defines various exception classes for handling errors related to message encoding and decoding.\u003c/p\u003e\n"],["\u003cp\u003e\u003ccode\u003eDefinitionNotFoundError\u003c/code\u003e is raised when a necessary definition is missing.\u003c/p\u003e\n"],["\u003cp\u003eMultiple exceptions exist for errors in defining messages, fields, and enums, including \u003ccode\u003eMessageDefinitionError\u003c/code\u003e, \u003ccode\u003eFieldDefinitionError\u003c/code\u003e, and \u003ccode\u003eEnumDefinitionError\u003c/code\u003e.\u003c/p\u003e\n"],["\u003cp\u003eIssues with field numbers, default values, and variants raise \u003ccode\u003eDuplicateNumberError\u003c/code\u003e, \u003ccode\u003eInvalidDefaultError\u003c/code\u003e, and \u003ccode\u003eInvalidVariantError\u003c/code\u003e respectively.\u003c/p\u003e\n"],["\u003cp\u003e\u003ccode\u003eValidationError\u003c/code\u003e indicates that a message contains an invalid value.\u003c/p\u003e\n"]]],[],null,["# Messages Module Exceptions\n\nThe `protorpc.messages` package provides the following exception classes:\n\nclass DecodeError()\n: Raised when there is an error decoding an encoded message.\n\nclass DefinitionNotFoundError()\n: Raised when a definition is not found.\n\nclass DuplicateNumberError()\n: Raised when a duplicate number is assigned to a field.\n\nclass EnumDefinitionError()\n: Raised when there are errors in Enum definitions.\n\nclass FieldDefinitionError()\n: Raised when there are errors in field definitions.\n\nclass InvalidDefaultError()\n: Raised when an invalid default value is provided to a field.\n\nclass InvalidNumberError()\n: Raised when an invalid number is provided to a field.\n\nclass InvalidVariantError()\n: Raised when an invalid variant is provided to a field.\n\nclass MessageDefinitionError()\n: Raised when there are errors in Message definitions.\n\nclass ValidationError()\n: Raised when a message has an invalid value."]]