per page, with , order by , clip by
Results of 1 - 10 of about 84 for raise (0.004 sec.)
Fetch modes 10852
Fetch modes New in Django 6.1. When accessing model fields that were not loaded as part of the original query, Django will fetch that field's data from the database. You can customize the behavior of this fetching with a fetch mode , making ... " instances are tracked in a list of weak references, to avoid memory leaks where some peer instances are discarded. FETCH_RAISE Raises a FieldFetchBlocked exception. Using FETCH_RAISE for the above example would raise an exception at the access of bo ...
https://man.mtool.work/django/6.1/topics/db/fetch-modes.html
Django の機能廃止のタイムライン 10391
Django の機能廃止のタイムライン このドキュメントは、 非推奨化ポリシー に従って、Django の様々なパーツが互換性を伴わない方法で変更または削除されるタイミングについて概説しています。各項目についての詳細は、多くの場合 2 つ前のバージョンのリリー ... S. The URLIZE_ASSUME_HTTPS transitional setting will be removed. Using a percent sign in a column alias or annotation will raise ValueError . Support for setting the ADMINS or MANAGERS settings to a list of (name, address) tuples will be removed. The ... 6.1 release notes for more details on these changes. Calling QuerySet.values_list() with flat=True and no field name will raise TypeError . The use of None when querying a JSONField top-level value will compile to SQL IS NULL . Use JSONNull to query ... ome unsupported, and the class documentation for that backend will be removed. The BaseEmailBackend.__init__() method will raise errors for unknown keyword arguments and will remove support for fail_silently . The email_backend argument of log.AdminEm ...
https://man.mtool.work/django/6.1/internals/deprecation.html
Djangoの認証システムを使用する 9917
Djangoの認証システムを使用する このドキュメントでは、デフォルト設定でのDjangoの認証システムの使用方法を説明します。この設定は、タスクの適切な範囲を管理することで、最も一般的なプロジェクトのニーズにかなうよう徐々に発展してきました。そして、パ ... mission with the new codename already exists (for example, due to a leftover permission from a previous migration), Django raises an error with next steps. Changed in Django 6.1: Updating permissions when models are renamed was added. app_label が foo ... いユーザによるすべてのリクエストは、ログインページにリダイレクトされるか、HTTP 403 Forbidden エラー表示となります。これは、 raise_exception パラメータにて設定します。 次のように AccessMixin のパラメータを設定することで、認可されていないユーザの処理をカ ... n1 はスタンドアロンでは動作しなくなります。 permission_required デコレータ permission_required ( perm , login_url = None , raise_exception = False ) [ソース] It's a relatively common task to check whether a user has a particular permission. For that r ...
https://man.mtool.work/django/6.1/topics/auth/default.html
Django 1.3 リリースノート 9456
Django 1.3 リリースノート March 23, 2011 Django 1.3 へようこそ! Nearly a year in the making, Django 1.3 includes quite a few new features and plenty of bug fixes and improvements to existing features. These release notes cover the new featu ... prior to Django 1.2, Django supported any 2.x version of Python from 2.3 up. As of Django 1.2, the minimum requirement was raised to Python 2.4. Django 1.3 continues to support Python 2.4, but will be the final Django release series to do so; beginnin ... ay to combine paths in templates. Project settings which provide either of both settings without a trailing slash will now raise a PendingDeprecationWarning . In Django 1.4 this same condition will raise DeprecationWarning , and in Django 1.5 will rai ... nsistent with behavior in other parts of the framework. Starting with 1.3 if you pass in empty dictionary the FormSet will raise a ValidationError . 以下は FormSet を使用した例です。 >>> class ArticleForm ( Form ): ... title = CharField () ... pub_dat ...
https://man.mtool.work/django/6.1/releases/1.3.html
データベースの計測 9456
データベースの計測 コードから発行されたクエリを理解して制御するために、Django は、データベースクエリの実行周辺にラッパー関数をインストールするためのフックを提供しています。たとえば、ラッパーは、クエリのカウント、クエリの実行時間の測定、クエ ... ーに特化したものです。 前述したように、ラッパーの例はクエリ実行ブロッカーです。以下のようなものです: def blocker ( * args ): raise Exception ( "No database access allowed here." ) そして、テンプレートからのクエリをブロックするには、ビューでこのように使用 ... 名を含めることができます。 def blocker ( execute , sql , params , many , context ): alias = context [ "connection" ] . alias raise Exception ( "Access to database ' {} ' blocked here" . format ( alias )) より完全な例として、クエリロガーは次のようになりま ... , params , many , context ) except Exception as e : current_query [ "status" ] = "error" current_query [ "exception" ] = e raise else : current_query [ "status" ] = "ok" return result finally : duration = time . monotonic () - start current_query [ "d ...
https://man.mtool.work/django/6.1/topics/db/instrumentation.html
テンプレートのバックエンドをカスタマイズする 9213
テンプレートのバックエンドをカスタマイズする カスタムのバックエンド ここでは、他のテンプレートシステムを使用するために、カスタムテンプレートバックエンドを実装する方法を説明します。テンプレートバックエンドは django.template.backends.base.Bas ... try : return Template ( self . engine . from_string ( template_code )) except foobar . TemplateCompilationFailed as exc : raise TemplateSyntaxError ( exc . args ) def get_template ( self , template_name ): try : return Template ( self . engine . get_ ... template ( template_name )) except foobar . TemplateNotFound as exc : raise TemplateDoesNotExist ( exc . args , backend = self ) except foobar . TemplateCompilationFailed as exc : raise TemplateSynt ...
https://man.mtool.work/django/6.1/howto/custom-template-backend.html
Django 2.2.23 リリースノート 9213
Django 2.2.23 リリースノート May 13, 2021 Django 2.2.23 fixes a regression in 2.2.21. バグ修正 Fixed a regression in Django 2.2.21 where saving FileField would raise a SuspiciousFileOperation even when a custom upload_to returns a valid fil ...
https://man.mtool.work/django/6.1/releases/2.2.23.html
Django 3.1.11 リリースノート 9213
Django 3.1.11 リリースノート May 13, 2021 Django 3.1.11 fixes a regression in 3.1.9. バグ修正 Fixed a regression in Django 3.1.9 where saving FileField would raise a SuspiciousFileOperation even when a custom upload_to returns a valid file ...
https://man.mtool.work/django/6.1/releases/3.1.11.html
フォームとフィールドのバリデーション 8982
フォームとフィールドのバリデーション フォームのバリデーションは、データがクリーニング (clean) されるときに実行されます。このプロセスをカスタムしたい場合は、様々な箇所に変更を加えることができ、それぞれが違う目的を持っています。クリーニング方 ... もアクセスできるようになります。これは各フィールドのクリーニングによって発生した例外をすべて含みます。 Note that any errors raised by your Form.clean() override will not be associated with any field in particular. They go into a special "field" (called ... ds are run for every field, the Form.clean() method, or its override, is executed whether or not the previous methods have raised errors. 各メソッドの例は後述します。 上述の通り、どのメソッドでも ValidationError が発生する可能性があります。どのフィール ... dationError ( _ ( "Invalid value" )) # Bad ValidationError ( "Invalid value" ) 全てを一緒に記述すると以下のようになります: raise ValidationError ( _ ( "Invalid value: %(value)s " ), code = "invalid" , params = { "value" : "42" }, ) 再利用可能なフォーム ...
https://man.mtool.work/django/6.1/ref/forms/validation.html
Django 3.2.3 リリースノート 8752
Django 3.2.3 リリースノート May 13, 2021 Django 3.2.3 では、3.2.2 におけるいくつかのバグを修正しました。 バグ修正 Prepared for mysqlclient > 2.0.3 support ( #32732 ). Fixed a regression in Django 3.2 that caused the incorrect filtering of q ... uerysets combined with the | operator ( #32717 ). Fixed a regression in Django 3.2.1 where saving FileField would raise a SuspiciousFileOperation even when a custom upload_to returns a valid file path ( #32718 ). ...
https://man.mtool.work/django/6.1/releases/3.2.3.html
PREV 1 2 3 4 5 6 7 8 9 NEXT