- 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 Dec 28 07:19:09 GMT 2025 - Last Modified: Sat Dec 27 12:54:56 GMT 2025 - 5.1K 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 Dec 28 07:19:09 GMT 2025 - Last Modified: Sat Dec 27 12:54:56 GMT 2025 - 23.2K bytes - Click Count (0) -
docs/zh/docs/tutorial/handling-errors.md
某些情况下,需要向客户端返回错误提示。 这里所谓的客户端包括前端浏览器、其他应用程序、物联网设备等。 需要向客户端返回错误提示的场景主要如下: - 客户端没有执行操作的权限 - 客户端没有访问资源的权限 - 客户端要访问的项目不存在 - 等等 ... 遇到这些情况时,通常要返回 **4XX**(400 至 499)**HTTP 状态码**。 **4XX** 状态码与表示请求成功的 **2XX**(200 至 299) HTTP 状态码类似。 只不过,**4XX** 状态码表示客户端发生的错误。 大家都知道**「404 Not Found」**错误,还有调侃这个错误的笑话吧? ## 使用 `HTTPException` 向客户端返回 HTTP 错误响应,可以使用 `HTTPException`。 ### 导入 `HTTPException`
Created: Sun Dec 28 07:19:09 GMT 2025 - Last Modified: Sat Oct 11 17:48:49 GMT 2025 - 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 Dec 28 19:28:13 GMT 2025 - Last Modified: Sun Sep 28 20:59:21 GMT 2025 - 99.7K bytes - Click Count (0) -
docs/en/docs/release-notes.md
Created: Sun Dec 28 07:19:09 GMT 2025 - Last Modified: Sat Dec 27 19:06:15 GMT 2025 - 586.7K bytes - Click Count (0)