Results of 1 - 10 of about 388 for raise (0.048 sec.)
- 変更履歴 — Python 3.14.8 ドキュメント 11659
- ナビゲーション 索引 モジュール | 次へ | 前へ | Python » 3.14.8 Documentation » What's New in Python » 変更履歴 テーマ 自動 ライト ダーク | 変更履歴 ¶ Python next ¶ Release date: XXXX-XX-XX セキュリティ ¶ gh-157265 : In tarfile , when extrac
...ld occur when formatting a float or complex with a precision close to the platform's INT_MAX . PyOS_double_to_string() now raises ValueError for any precision of that magnitude, regardless of presentation type or value, as the format string parsers al...ntext.wrap_socket() . In particular, a context with check_hostname enabled and no server_hostname passed to wrap_bio() now raises ValueError instead of completing a handshake that verified the certificate chain without verifying the peer's identity, w...t_exceptions() is called while another interpreter is running. gh-158254 : Reverse iterators over a dict and its views now raise RuntimeError if the dictionary's keys change during iteration, like forward iterators, instead of yielding entries for the... - https://man.mtool.work/python/3.14/whatsnew/changelog.html
- 8. エラーと例外 — Python 3.14.8 ドキュメント 11381
- ナビゲーション 索引 モジュール | 次へ | 前へ | Python » 3.14.8 Documentation » Python チュートリアル » 8. エラーと例外 テーマ 自動 ライト ダーク | 8. エラーと例外 ¶ これまでエラーメッセージについては簡単に触れるだけでしたが、チュートリアル中
...D の順に出力されます: class B ( Exception ): pass class C ( B ): pass class D ( C ): pass for cls in [ B , C , D ]: try : raise cls () except D : print ( "D" ) except C : print ( "C" ) except B : print ( "B" ) except 節 が逆に並んでいた場合 ( except...め、組み込み例外型には __str__() が定義されており、明示的に .args を参照せずとも すべての引数を表示できます。 >>> try : ... raise Exception ( 'spam' , 'eggs' ) ... except Exception as inst : ... print ( type ( inst )) # 例外の型 ... print ( inst . args...( "データを整数に変換できません。" ) except Exception as err : print ( f "予期せぬエラー { err =} , { type ( err ) =} " ) raise try ... except 文には、オプションで else 節 (else clause) を設けることができます。 else 節を設ける場合、全ての except 節よ... - https://man.mtool.work/python/3.14/tutorial/errors.html
- 8. エラーと例外 — Python 3.14.8 ドキュメント 11381
- ナビゲーション 索引 モジュール | 次へ | 前へ | Python » 3.14.8 Documentation » Python チュートリアル » 8. エラーと例外 テーマ 自動 ライト ダーク | 8. エラーと例外 ¶ これまでエラーメッセージについては簡単に触れるだけでしたが、チュートリアル中
...D の順に出力されます: class B ( Exception ): pass class C ( B ): pass class D ( C ): pass for cls in [ B , C , D ]: try : raise cls () except D : print ( "D" ) except C : print ( "C" ) except B : print ( "B" ) except 節 が逆に並んでいた場合 ( except...め、組み込み例外型には __str__() が定義されており、明示的に .args を参照せずとも すべての引数を表示できます。 >>> try : ... raise Exception ( 'spam' , 'eggs' ) ... except Exception as inst : ... print ( type ( inst )) # 例外の型 ... print ( inst . args...( "データを整数に変換できません。" ) except Exception as err : print ( f "予期せぬエラー { err =} , { type ( err ) =} " ) raise try ... except 文には、オプションで else 節 (else clause) を設けることができます。 else 節を設ける場合、全ての except 節よ... - https://man.mtool.work/python/3.14/tutorial/errors.html
- sys.monitoring --- 実行イベントモニタリング — Python 3.14.8 ドキュメント 7376
- ナビゲーション 索引 モジュール | 次へ | 前へ | Python » 3.14.8 Documentation » The Python standard library » Python ランタイムサービス » sys.monitoring --- 実行イベントモニタリング テーマ 自動 ライト ダーク | sys.monitoring --- 実行イベント
...int , name : str , / ) → None ¶ Must be called before tool_id can be used. tool_id must be in the range 0 to 5 inclusive. Raises a ValueError if tool_id is in use. sys.monitoring. clear_tool_id ( tool_id : int , / ) → None ¶ Unregister all events and...h goes right. sys.monitoring.events. CALL ¶ A call in Python code (event occurs before the call). sys.monitoring.events. C_RAISE ¶ An exception raised from any callable, except for Python functions (event occurs after the exit). sys.monitoring.events....call. sys.monitoring.events. PY_UNWIND ¶ Exit from a Python function during exception unwinding. This includes exceptions raised directly within the function and that are allowed to continue to propagate. sys.monitoring.events. PY_YIELD ¶ Yield from... - https://man.mtool.work/python/3.14/library/sys.monitoring.html
- sys.monitoring --- 実行イベントモニタリング — Python 3.14.8 ドキュメント 7376
- ナビゲーション 索引 モジュール | 次へ | 前へ | Python » 3.14.8 Documentation » The Python standard library » Python ランタイムサービス » sys.monitoring --- 実行イベントモニタリング テーマ 自動 ライト ダーク | sys.monitoring --- 実行イベント
...int , name : str , / ) → None ¶ Must be called before tool_id can be used. tool_id must be in the range 0 to 5 inclusive. Raises a ValueError if tool_id is in use. sys.monitoring. clear_tool_id ( tool_id : int , / ) → None ¶ Unregister all events and...h goes right. sys.monitoring.events. CALL ¶ A call in Python code (event occurs before the call). sys.monitoring.events. C_RAISE ¶ An exception raised from any callable, except for Python functions (event occurs after the exit). sys.monitoring.events....call. sys.monitoring.events. PY_UNWIND ¶ Exit from a Python function during exception unwinding. This includes exceptions raised directly within the function and that are allowed to continue to propagate. sys.monitoring.events. PY_YIELD ¶ Yield from... - https://man.mtool.work/python/3.14/library/sys.monitoring.html
- email.contentmanager: Managing MIME Content — Python 3.14.8 ドキュメント 7099
- ナビゲーション 索引 モジュール | 次へ | 前へ | Python » 3.14.8 Documentation » The Python standard library » インターネット上のデータの操作 » email --- 電子メールと MIME 処理のためのパッケージ » email.contentmanager : Managing MIME Content
...完全な MIME 型を表す文字列 ( maintype/subtype ) maintype を表す文字列 空の文字列 If none of these keys produce a handler, raise a KeyError for the full MIME type. set_content ( msg , obj , * args , ** kw ) ¶ If the maintype is multipart , raise a Typ...o__ ). Finally, if no other key yields a handler, check for a handler for the key None . If there is no handler for None , raise a KeyError for the fully qualified name of the type. Also add a MIME-Version header if one is not present (see also MIMEPa...for text parts), an EmailMessage object (for message/rfc822 parts), or a bytes object (for all other non-multipart types). Raise a KeyError if called on a multipart . If the part is a text part and errors is specified, use it as the error handler when... - https://man.mtool.work/python/3.14/library/email.contentmanager.html
- email.contentmanager: Managing MIME Content — Python 3.14.8 ドキュメント 7030
- ナビゲーション 索引 モジュール | 次へ | 前へ | Python » 3.14.8 Documentation » The Python standard library » インターネット上のデータの操作 » email --- 電子メールと MIME 処理のためのパッケージ » email.contentmanager : Managing MIME Content
...完全な MIME 型を表す文字列 ( maintype/subtype ) maintype を表す文字列 空の文字列 If none of these keys produce a handler, raise a KeyError for the full MIME type. set_content ( msg , obj , * args , ** kw ) ¶ If the maintype is multipart , raise a Typ...o__ ). Finally, if no other key yields a handler, check for a handler for the key None . If there is no handler for None , raise a KeyError for the fully qualified name of the type. Also add a MIME-Version header if one is not present (see also MIMEPa...for text parts), an EmailMessage object (for message/rfc822 parts), or a bytes object (for all other non-multipart types). Raise a KeyError if called on a multipart . If the part is a text part and errors is specified, use it as the error handler when... - https://man.mtool.work/python/3.14/library/email.contentmanager.html
- 7. 単純文 (simple statement) — Python 3.14.8 ドキュメント 6692
- ナビゲーション 索引 モジュール | 次へ | 前へ | Python » 3.14.8 Documentation » Python 言語リファレンス » 7. 単純文 (simple statement) テーマ 自動 ライト ダーク | 7. 単純文 (simple statement) ¶ 単純文とは、単一の論理行内に収められる文です。単
...ssignment_stmt | augmented_assignment_stmt | annotated_assignment_stmt | pass_stmt | del_stmt | return_stmt | yield_stmt | raise_stmt | break_stmt | continue_stmt | import_stmt | future_stmt | global_stmt | nonlocal_stmt | type_stmt 7.1. 式文 (express...ference or subscription), the mutable object must ultimately perform the assignment and decide about its validity, and may raise an exception if the assignment is unacceptable. The rules observed by various types and the exceptions raised are given wi...す: assert_stmt : "assert" expression [ "," expression ] 単純な形式 assert expression は if __debug__ : if not expression : raise AssertionError と等価です。拡張形式 assert expression1, expression2 は、これと等価です if __debug__ : if not expression1 :... - https://man.mtool.work/python/3.14/reference/simple_stmts.html
- 7. 単純文 (simple statement) — Python 3.14.8 ドキュメント 6692
- ナビゲーション 索引 モジュール | 次へ | 前へ | Python » 3.14.8 Documentation » Python 言語リファレンス » 7. 単純文 (simple statement) テーマ 自動 ライト ダーク | 7. 単純文 (simple statement) ¶ 単純文とは、単一の論理行内に収められる文です。単
...ssignment_stmt | augmented_assignment_stmt | annotated_assignment_stmt | pass_stmt | del_stmt | return_stmt | yield_stmt | raise_stmt | break_stmt | continue_stmt | import_stmt | future_stmt | global_stmt | nonlocal_stmt | type_stmt 7.1. 式文 (express...ference or subscription), the mutable object must ultimately perform the assignment and decide about its validity, and may raise an exception if the assignment is unacceptable. The rules observed by various types and the exceptions raised are given wi...す: assert_stmt : "assert" expression [ "," expression ] 単純な形式 assert expression は if __debug__ : if not expression : raise AssertionError と等価です。拡張形式 assert expression1, expression2 は、これと等価です if __debug__ : if not expression1 :... - https://man.mtool.work/python/3.14/reference/simple_stmts.html
- デスクリプタ ガイド — Python 3.14.8 ドキュメント 6276
- ナビゲーション 索引 モジュール | 次へ | 前へ | Python » 3.14.8 Documentation » Python HOWTO » デスクリプタ ガイド テーマ 自動 ライト ダーク | デスクリプタ ガイド ¶ Author : Raymond Hettinger Contact : <python at rcn dot com> デスクリプタ を
...t__ ( self , * options ): self . options = set ( options ) def validate ( self , value ): if value not in self . options : raise ValueError ( f 'Expected { value !r} to be one of { self . options !r} ' ) class Number ( Validator ): def __init__ ( self...invalue = minvalue self . maxvalue = maxvalue def validate ( self , value ): if not isinstance ( value , ( int , float )): raise TypeError ( f 'Expected { value !r} to be an int or float' ) if self . minvalue is not None and value < self . minvalue :...Expected { value !r} to be at least { self . minvalue !r} ' ) if self . maxvalue is not None and value > self . maxvalue : raise ValueError ( f 'Expected { value !r} to be no more than { self . maxvalue !r} ' ) class String ( Validator ): def __init__... - https://man.mtool.work/python/3.14/howto/descriptor.html