- Sort Score
- Num 10 results
- Language All
Results 1 - 5 of 5 for 2XX (0.02 seconds)
-
fastapi/utils.py
if status_code is None: return True # Ref: https://github.com/OAI/OpenAPI-Specification/blob/main/versions/3.1.0.md#patterned-fields-1 if status_code in { "default", "1XX", "2XX", "3XX", "4XX", "5XX", }: return True current_status_code = int(status_code) return not (current_status_code < 200 or current_status_code in {204, 205, 304})Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Wed Feb 11 18:41:21 GMT 2026 - 4.2K bytes - Click Count (0) -
fastapi/openapi/utils.py
"type": "array", "items": {"$ref": REF_PREFIX + "ValidationError"}, } }, } status_code_ranges: dict[str, str] = { "1XX": "Information", "2XX": "Success", "3XX": "Redirection", "4XX": "Client Error", "5XX": "Server Error", "DEFAULT": "Default Response", } def get_openapi_security_definitions( flat_dependant: Dependant,
Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Sun Mar 15 11:44:39 GMT 2026 - 25.6K bytes - Click Count (0) -
docs/zh/docs/tutorial/handling-errors.md
某些情况下,需要向使用你的 API 的客户端返回错误提示。 这里所谓的客户端包括前端浏览器、他人的代码、物联网设备等。 你可能需要告诉客户端: - 客户端没有执行该操作的权限 - 客户端没有访问该资源的权限 - 客户端要访问的项目不存在 - 等等 遇到这些情况时,通常要返回 **4XX**(400 至 499)**HTTP 状态码**。 这与表示请求成功的 **2XX**(200 至 299)HTTP 状态码类似。那些“200”状态码表示某种程度上的“成功”。 而 **4XX** 状态码表示客户端发生了错误。 大家都知道**「404 Not Found」**错误,还有调侃这个错误的笑话吧? ## 使用 `HTTPException` { #use-httpexception } 向客户端返回 HTTP 错误响应,可以使用 `HTTPException`。Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Fri Mar 20 17:06:37 GMT 2026 - 8.2K bytes - Click Count (0) -
cmd/admin-handlers.go
) // Returns true if the madmin.TraceInfo should be traced, // false if certain conditions are not met. // - input entry is not of the type *madmin.TraceInfo* // - errOnly entries are to be traced, not status code 2xx, 3xx. // - madmin.TraceInfo type is asked by opts func shouldTrace(trcInfo madmin.TraceInfo, opts madmin.ServiceTraceOpts) (shouldTrace bool) { // Reject all unwanted types. want := opts.TraceTypes()
Created: Sun Apr 05 19:28:12 GMT 2026 - Last Modified: Sun Sep 28 20:59:21 GMT 2025 - 99.7K bytes - Click Count (0) -
docs/en/docs/release-notes.md
Created: Sun Apr 05 07:19:11 GMT 2026 - Last Modified: Fri Apr 03 12:07:04 GMT 2026 - 631K bytes - Click Count (0)