Results of 1 - 10 of about 14 for span (0.002 sec.)
- FastAPI CLI 13688
- FastAPI CLI Warning The current page still doesn't have a translation for this language. But you can help translating it: Contributing . FastAPI CLI is a command line program that you can use to serve your FastAPI app, manage your FastAPI p
...fastapi dev command: $ <font color = "#4E9A06" >fastapi</font> dev <u style = "text-decoration-style:solid" >main.py</u> <span style="background-color:#009485"><font color="#D3D7CF"> FastAPI </font></span> Starting development server ? Searching for...nit__.py</font> files Importing from <font color="#75507B">/home/user/code/</font><font color="#AD7FA8">awesomeapp</font> <span style="background-color:#007166"><font color="#D3D7CF"> module </font></span> ? main.py <span style="background-color:#007...166"><font color="#D3D7CF"> code </font></span> Importing the FastAPI app object from the module with the following code: <u style="text-decoration-style:solid">from </u... - https://man.mtool.work/fastapi/0.115/fastapi-cli/
- チュートリアル - ユーザーガイド 10625
- チュートリアル - ユーザーガイド このチュートリアルは FastAPI のほぼすべての機能の使い方を段階的に紹介します。 各セクションは前のセクションを踏まえた内容になっています。しかし、トピックごとに分割されているので、特定のAPIの要求を満たすようなト
...ずれかの例を実行するには、コードを main.py ファイルにコピーし、 uvicorn を次のように起動します: $ uvicorn main:app --reload <span style="color: green;">INFO</span>: Uvicorn running on http://127.0.0.1:8000 (Press CTRL+C to quit) <span style="color: gre...en;">INFO</span>: Started reloader process [28720] <span style="color: green;">INFO</span>: Started server process [28722] <span style="co...lor: green;">INFO</span>: Waiting for application startup. <span style="color: green;">INFO</span>: Application startup complete. コードを記述また... - https://man.mtool.work/fastapi/0.115/tutorial/
- Development - Contributing 10397
- Development - Contributing Warning The current page still doesn't have a translation for this language. But you can help translating it: Contributing . First, you might want to see the basic ways to help FastAPI and get help . Developing If
...pment, there is a script that builds the site and checks for any changes, live-reloading: $ python ./scripts/docs.py live <span style="color: green;">[INFO]</span> Serving on http://127.0.0.1:8008 <span style="color: green;">[INFO]</span> Start watch...ing changes <span style="color: green;">[INFO]</span> Start detecting changes It will serve the documentation on http://127.0.0.1:8008 . Tha...ensured by test coverage. Apps and docs at the same time If you run the examples with, e.g.: $ fastapi dev tutorial001.py <span style="color: green;">INFO</span>: Uvicorn running on http://127.0.0.1:8000 (Press CTRL+C to quit) as Uvicorn by default w... - https://man.mtool.work/fastapi/0.115/contributing/
- 最初のステップ 9977
- 最初のステップ 最もシンプルなFastAPIファイルは以下のようになります: Python 3.8+ from fastapi import FastAPI app = FastAPI () @app . get ( "/" ) async def root (): return { "message" : "Hello World" } これを main.py にコピーします。 ライブサ
...ーバーを実行します: $ uvicorn main:app --reload <span style="color: green;">INFO</span>: Uvicorn running on http://127.0.0.1:8000 (Press CTRL+C to quit) <span style="color: gre...en;">INFO</span>: Started reloader process [28720] <span style="color: green;">INFO</span>: Started server process [28722] <span style="co...lor: green;">INFO</span>: Waiting for application startup. <span style="color: green;">INFO</span>: Application startup complete. 備考 uvicorn mai... - https://man.mtool.work/fastapi/0.115/tutorial/first-steps/
- Behind a Proxy 8384
- Behind a Proxy Warning The current page still doesn't have a translation for this language. But you can help translating it: Contributing . In some situations, you might need to use a proxy server like Traefik or Nginx with a configuration
...oot_path To achieve this, you can use the command line option --root-path like: $ fastapi run main.py --root-path /api/v1 <span style="color: green;">INFO</span>: Uvicorn running on http://127.0.0.1:8000 (Press CTRL+C to quit) If you use Hypercorn, i...path" : request . scope . get ( "root_path" )} Then, if you start Uvicorn with: $ fastapi run main.py --root-path /api/v1 <span style="color: green;">INFO</span>: Uvicorn running on http://127.0.0.1:8000 (Press CTRL+C to quit) The response would be s...r/awesomeapi/traefik.toml And now start your app, using the --root-path option: $ fastapi run main.py --root-path /api/v1 <span style="color: green;">INFO</span>: Uvicorn running on http://127.0.0.1:8000 (Press CTRL+C to quit) Check the responses Now... - https://man.mtool.work/fastapi/0.115/advanced/behind-a-proxy/
- WebSocket 8244
- WebSocket FastAPI で WebSocket が使用できます。 WebSockets のインストール まず WebSockets のインストールが必要です。 $ pip install websockets ---> 100% WebSocket クライアント 本番環境 本番環境では、React、Vue.js、Angularなどの最新のフレーム
...きます。 試してみる ファイル名が main.py である場合、以下の方法でアプリケーションを実行します。 $ uvicorn main:app --reload <span style="color: green;">INFO</span>: Uvicorn running on http://127.0.0.1:8000 (Press CTRL+C to quit) ブラウザで http://127.0...cketsを試してみる ファイル名が main.py である場合、以下の方法でアプリケーションを実行します。 $ uvicorn main:app --reload <span style="color: green;">INFO</span>: Uvicorn running on http://127.0.0.1:8000 (Press CTRL+C to quit) ブラウザで http://127.0...stAPI () html = """ <!DOCTYPE html> <html> <head> <title>Chat</title> </head> <body> <h1>WebSocket Chat</h1> <h2>Your ID: <span id="ws-id"></span></h2> <form action="" onsubmit="sendMessage(event)"> <input type="text" id="messageText" autocomplete="o... - https://man.mtool.work/fastapi/0.115/advanced/websockets/
- 手動デプロイ 8017
- 手動デプロイ FastAPI を手動でデプロイすることもできます。 以下の様なASGI対応のサーバをインストールする必要があります: Uvicorn Uvicorn , uvloopとhttptoolsを基にした高速なASGIサーバ。 $ pip install "uvicorn[standard]" ---> 100% 豆知識 standar
...ただし、以下の様に --reload オプションは使用しないで下さい: Uvicorn Hypercorn $ uvicorn main:app --host 0 .0.0.0 --port 80 <span style="color: green;">INFO</span>: Uvicorn running on http://0.0.0.0:80 (Press CTRL+C to quit) $ hypercorn main:app --bind... - https://man.mtool.work/fastapi/0.115/deployment/manually/
- Sub Applications - Mounts 7912
- Sub Applications - Mounts Warning The current page still doesn't have a translation for this language. But you can help translating it: Contributing . If you need to have two independent FastAPI applications, with their own independent Open
...nt ( "/subapi" , subapi ) Check the automatic API docs Now, run the fastapi command with your file: $ fastapi dev main.py <span style="color: green;">INFO</span>: Uvicorn running on http://127.0.0.1:8000 (Press CTRL+C to quit) And open the docs at ht... - https://man.mtool.work/fastapi/0.115/advanced/sub-applications/
- 条件付き OpenAPI 7824
- 条件付き OpenAPI 必要であれば、設定と環境変数を利用して、環境に応じて条件付きでOpenAPIを構成することが可能です。また、完全にOpenAPIを無効にすることもできます。 セキュリティとAPI、およびドキュメントについて 本番環境においてドキュメントのUIを
...空文字列に設定することによってOpenAPI (UIドキュメントを含む) を無効化することができます。 $ OPENAPI_URL = uvicorn main:app <span style="color: green;">INFO</span>: Uvicorn running on http://127.0.0.1:8000 (Press CTRL+C to quit) すると、以下のように /o... - https://man.mtool.work/fastapi/0.115/how-to/conditional-openapi/
- テスト 7737
- テスト Starlette のおかげで、 FastAPI アプリケーションのテストは簡単で楽しいものになっています。 HTTPX がベースなので、非常に使いやすく直感的です。 これを使用すると、 FastAPI と共に pytest を直接利用できます。 TestClient を使用 TestClient を
...me/user/code/superawesome-cli/app plugins: forked-1.1.3, xdist-1.31.0, cov-2.8.1 collected 6 items ---> 100% test_main.py <span style="color: green; white-space: pre;">...... [100%]</span> <span style="color: green;">================= 1 passed in 0.0...3s =================</span>... - https://man.mtool.work/fastapi/0.115/tutorial/testing/