per page, with , order by , clip by
Results of 1 - 10 of about 94 for exception (0.002 sec.)
Django の例外 17158
Django の例外 Django は普通の Python の例外の他に、いくつか独自の例外も起こします。 Django Core 例外 Django core 例外クラスは django.core.exceptions で定義されています。 AppRegistryNotReady exception AppRegistryNotReady [ソース] この例外は、 ... を初期化する アプリケーション読み込みプロセス が完了する前にモデルを使用しようとしたときに発生します。 ObjectDoesNotExist exception ObjectDoesNotExist [ソース] Model.DoesNotExist 例外の基底クラスです。 ObjectDoesNotExist のための try/except は、すべてのモ ... デルの DoesNotExist 例外をキャッチします。 get() を参照してください。 ObjectNotUpdated New in Django 6.0. exception ObjectNotUpdated [ソース] The base class for Model.NotUpdated exceptions. A try/except for ObjectNotUpdated will catch Not ... Updated exceptions for all models. save() を参照してください。 EmptyResultSet exception EmptyResultSet [ソース] EmptyResultSet は、クエリが何 ...
https://man.mtool.work/django/6.1/ref/exceptions.html
Model クラスのリファレンス 9793
Model クラスのリファレンス このドキュメントでは Model クラスの機能を扱います。モデルについての詳細は モデルのリファレンスガイドの完全なリスト を参照してください。 属性 DoesNotExist exception Model. DoesNotExist この例外は、期待したオブジェク ... らなかったオブジェクトのクラスを特定することで、特定のモデルクラスの例外をキャッチできるようにします。この例外は django.core.exceptions.ObjectDoesNotExist のサブクラスです。 MultipleObjectsReturned exception Model. MultipleObjectsReturned この例外は、 Query ... が見つかったオブジェクトクラスを特定することで、特定のモデルクラスの例外をキャッチできるようにします。この例外は django.core.exceptions.MultipleObjectsReturned のサブクラスです。 NotUpdated New in Django 6.0. exception Model. NotUpdated This exception is ra ... ised when a forced update of a Model instance does not affect any rows. Django provides a NotUpdated exception as an attribute of each model class to identify the class of object that could not be updated, allowing you to catch excep ...
https://man.mtool.work/django/6.1/ref/models/class.html
Tasks 9212
Tasks New in Django 6.0. The Task framework provides the contract and plumbing for background work, not the engine that runs it. The Tasks API defines how work is described, queued, and tracked, but leaves actual execution to external infra ... t been enqueued, or is ready to be executed again. RUNNING The Task is currently being executed. FAILED The Task raised an exception during execution, or was unable to start. SUCCESSFUL The Task has finished executing successfully. class TaskResult [ソース ... information about the error raised during the execution of a Task . traceback The traceback (as a string) from the raised exception when the Task failed. exception_class The exception class raised when executing the Task . Backends Backends handle how Ta ... results for the enqueued Tasks, in the order they were enqueued. clear () [ソース] Clears the list of stored results. 例外 exception InvalidTask [ソース] Raised when the Task attempting to be enqueued is invalid. exception InvalidTaskBackend [ソース] Rais ...
https://man.mtool.work/django/6.1/ref/tasks.html
ミドルウェア (Middleware) 8539
ミドルウェア (Middleware) ミドルウェアは、Django のリクエスト/レスポンス処理にフックを加えるためのフレームワークです。これは、Django の入力あるいは出力をグローバルに置き換えるための、軽量で低レベルの「プラグイン」システムです。 各ミドルウェ ... 用意されていて、このデコレータを使えば、CSRF の検証が必要になったどの時点でも、明示的にビューを制御できるからです。 process_exception() process_exception ( request , exception ) request は HttpRequest オブジェクトです。 exception は、ビュー関数から投げられ ... た Exception オブジェクトです。 Django は、ビューが例外を起こした時に process_exception() を呼び出します。 process_exception() は None ... ブラウザに返されます。そうでなければ、 デフォルトの例外のハンドリング が行われます。 繰り返しますが、ミドルウェアは process_exception を含むレスポンスフェーズで逆順に実行されます。例外ミドルウェアがレスポンスを返した場合、そのミドルウェアの上のミドルウェア ...
https://man.mtool.work/django/6.1/topics/http/middleware.html
エラーレポートの管理 8288
エラーレポートの管理 サイトを公開している場合、 DEBUG 設定は常にオフにしておかなければなりません。これにより、サーバー動作は高速になり、エラーページによって明らかになるアプリケーションの詳細が悪意あるユーザーに漏れるのを防ぎます。 しかし、 ... ータ名をアノテートするだけです。実際のフィルタリングは Django のデフォルトのエラーレポートフィルタ ( django.views.debug.SafeExceptionReporterFilter ) で行われます。このフィルタはデコレータのアノテーションを使い、エラーレポートが生成される際に、対応する値を ... き換えます。このデフォルトの動作を上書きしたり、サイト全体でカスタマイズしたい場合は、独自のフィルタクラスを定義し、 DEFAULT_EXCEPTION_REPORTER_FILTER 設定でそれを使うように Django に指示する必要があります: DEFAULT_EXCEPTION_REPORTER_FILTER = "path.to.your. ... CustomExceptionReporterFilter" また、 HttpRequest の exception_reporter_filter 属性を指定することで、任意のビューで使用するフィルタをより細 ...
https://man.mtool.work/django/6.1/howto/error-reporting.html
組み込みのビュー 8196
組み込みのビュー Django の組み込みビューのいくつかは、 ビューを記述する や他のドキュメントで説明されています。 開発中のファイルの配信 static. serve ( request , path , document_root , show_indexes = False ) プロジェクトの静的アセット以外にも ... には、 エラービューをカスタマイズする を参照してください。 404 (page not found) ビュー defaults. page_not_found ( request , exception , template_name = '404.html' ) ビュー内で Http404 を発生させると、 Django は 404 エラーの処理に特化した特別なビューを読み込 ... レンダリングします。 デフォルトの404ビューはテンプレートに2つの変数を渡します。 request_path はエラーの原因となった URL で、 exception はビューのトリガーとなった例外の有用な表現です (たとえば、特定の Http404 インスタンスに渡されたメッセージなど)。 404ビュー ... 代わりにトレースバックがデバッグ情報と共に表示されます。 403 (HTTP Forbidden) ビュー defaults. permission_denied ( request , exception , template_name = '403.html' ) 404 や 500 のビューと同じように、 Django には 403 Forbidden エラーを扱うビューがあります。ビ ...
https://man.mtool.work/django/6.1/ref/views.html
Django 1.1.4 リリースノート 7945
Django 1.1.4 リリースノート Django 1.1.4 へようこそ! This is the fourth "bugfix" release in the Django 1.1 series, improving the stability and performance of the Django 1.1 codebase. With one exception, Django 1.1.4 maintains backwards comp ... lities, and deprecated features in the 1.1 branch, see the Django 1.1 リリースノート . Backwards incompatible changes CSRF exception for AJAX requests Django includes a CSRF-protection mechanism, which makes use of a token inserted into outgoing forms. Mi ... n checks for the token's presence on form submission, and validates it. Prior to Django 1.2.5, our CSRF protection made an exception for AJAX requests, on the following basis: Many AJAX toolkits add an X-Requested-With header when using XMLHttpRequest. Br ...
https://man.mtool.work/django/6.1/releases/1.1.4.html
データベースの計測 7694
データベースの計測 コードから発行されたクエリを理解して制御するために、Django は、データベースクエリの実行周辺にラッパー関数をインストールするためのフックを提供しています。たとえば、ラッパーは、クエリのカウント、クエリの実行時間の測定、クエ ... 化したものです。 前述したように、ラッパーの例はクエリ実行ブロッカーです。以下のようなものです: def blocker ( * args ): raise Exception ( "No database access allowed here." ) そして、テンプレートからのクエリをブロックするには、ビューでこのように使用します: f ... めることができます。 def blocker ( execute , sql , params , many , context ): alias = context [ "connection" ] . alias raise Exception ( "Access to database ' {} ' blocked here" . format ( alias )) より完全な例として、クエリロガーは次のようになります。 impo ... ms" : params , "many" : many } start = time . monotonic () try : result = execute ( sql , params , many , context ) except Exception as e : current_query [ "status" ] = "error" current_query [ "exception" ] = e raise else : current_query [ "status" ] = "o ...
https://man.mtool.work/django/6.1/topics/db/instrumentation.html
Django 1.5.4リリースノート 7615
Django 1.5.4リリースノート September 14, 2013 This is Django 1.5.4, the fourth release in the Django 1.5 series. It addresses two security issues and one bug. Denial-of-service via password hashers In previous versions of Django, no limit w ... g in the decorator not being properly applied. This usage has been fixed and sensitive_post_parameters() will now throw an exception if it's improperly used. バグ修正 Fixed a bug that prevented a QuerySet that uses prefetch_related() from being pickled an ... d unpickled more than once (the second pickling attempt raised an exception) (#21102). ...
https://man.mtool.work/django/6.1/releases/1.5.4.html
Django 3.1 リリースノート 7444
Django 3.1 リリースノート August 4, 2020 Django 3.1 へようこそ! このリリースノートでは、 バージョン 3.1 の新機能 と、Django 3.0 以前からアップグレードする際に注意すべき、 後方互換性のない変更 について説明します。 非推奨サイクルが終了した機能 ... he EMAIL_FILE_PATH setting, used by the file email backend , now supports pathlib.Path . エラー報告 django.views.debug.SafeExceptionReporterFilter now filters sensitive values from request.META in exception reports. The new SafeExceptionReporterFilter.cle ... ansed_substitute and SafeExceptionReporterFilter.hidden_settings attributes allow customization of sensitive settings and request.META filtering in exception ... reports. The technical 404 debug view now respects DEFAULT_EXCEPTION_REPORTER_FILTER when applying settings filtering. The new DEFAULT_EXCEPTION_REPORTER allows providing a django.views.debug ...
https://man.mtool.work/django/6.1/releases/3.1.html
PREV 1 2 3 4 5 6 7 8 9 10 NEXT