Results of 1 - 8 of about 8 for command (0.004 sec.)
- Virtual Environments 11983
- Virtual Environments Warning The current page still doesn't have a translation for this language. But you can help translating it: Contributing . When you work in Python projects you probably should use a virtual environment (or a similar m
...v uv To create a virtual environment, you can use the venv module that comes with Python. $ python -m venv .venv What that command means python : use the program called python -m : call a module as a script, we'll tell it which module next venv : use th...ment in a directory called .venv . But you could customize it passing an additional argument with the directory name. That command creates a new virtual environment in a directory called .venv . .venv or other name You could create the virtual environme...convention of calling it .venv . Activate the Virtual Environment Activate the new virtual environment so that any Python command you run or package you install uses it. Tip Do this every time you start a new terminal session to work on the project. Li... - https://man.mtool.work/fastapi/0.115/virtual-environments/
- Development - Contributing 11893
- 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
...that you can run locally to test all the code and generate coverage reports in HTML: $ bash scripts/test-cov-html.sh This command generates a directory ./htmlcov/ , if you open the file ./htmlcov/index.html in your browser, you can explore interactivel...ith the python program directly. But you can also use Typer CLI , and you will get autocompletion in your terminal for the commands after installing completion. If you install Typer CLI, you can install completion with: $ typer --install-completion zsh...andle translations in ./scripts/docs.py . Tip You don't need to see the code in ./scripts/docs.py , you just use it in the command line. All the documentation is in Markdown format in the directory ./docs/en/ . Many of the tutorials have blocks of code.... - https://man.mtool.work/fastapi/0.115/contributing/
- FastAPI CLI 9489
- 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
...(e.g. with pip install "fastapi[standard]" ), it includes a package called fastapi-cli , this package provides the fastapi command in the terminal. To run your FastAPI app for development, you can use the fastapi dev command: $ <font color = "#4E9A06" >...artup. <span style="background-color:#007166"><font color="#D3D7CF"> INFO </font></span> Application startup complete. The command line program called fastapi is FastAPI CLI . FastAPI CLI takes the path to your Python program (e.g. main.py ) and automat... - https://man.mtool.work/fastapi/0.115/fastapi-cli/
- Behind a Proxy 8513
- 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
...like FastAPI CLI with Uvicorn , running your FastAPI application. Providing the root_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 r...e option --root-path . Technical Details The ASGI specification defines a root_path for this use case. And the --root-path command line option provides that root_path . Checking the current root_path You can get the current root_path used by your applic..." , "root_path" : "/api/v1" } Setting the root_path in the FastAPI app Alternatively, if you don't have a way to provide a command line option like --root-path or equivalent, you can set the root_path parameter when creating your FastAPI app: Python 3.8... - https://man.mtool.work/fastapi/0.115/advanced/behind-a-proxy/
- Generate Clients 8079
- Generate Clients Warning The current page still doesn't have a translation for this language. But you can help translating it: Contributing . As FastAPI is based on the OpenAPI specification, you get automatic compatibility with many tools,
...h: $ npm install @hey-api/openapi-ts --save-dev ---> 100% Generate Client Code To generate the client code you can use the command line application openapi-ts that would now be installed. Because it is installed in the local project, you probably wouldn...'t be able to call that command directly, but you would put it on your package.json file. It could look like this: { "name" : "frontend-app" , "version" :...e/user/code/frontend-app > openapi-ts --input http://localhost:8000/openapi.json --output ./src/client --client axios That command will generate code in ./src/client and will use axios (the frontend HTTP library) internally. Try Out the Client Code Now... - https://man.mtool.work/fastapi/0.115/advanced/generate-clients/
- Sub Applications - Mounts 7627
- 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
...ssage" : "Hello World from sub API" } app . mount ( "/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 (P... - https://man.mtool.work/fastapi/0.115/advanced/sub-applications/
- Settings and Environment Variables 7537
- Settings and Environment Variables Warning The current page still doesn't have a translation for this language. But you can help translating it: Contributing . In many cases your application could need some external settings or configuratio
...n;">INFO</span>: Uvicorn running on http://127.0.0.1:8000 (Press CTRL+C to quit) Tip To set multiple env vars for a single command just separate them with a space, and put them all before the command. And then the admin_email setting would be set to "de... - https://man.mtool.work/fastapi/0.115/advanced/settings/
- Release Notes 7103
- Release Notes Latest Changes 0.115.11 Fixes ? Add docs examples and tests (support) for Annotated custom validations, like AfterValidator , revert #13440 . PR #13442 by @tiangolo . New docs: Query Parameters and String Validations - Custom
...11549 by @tiangolo . ? Update FastAPI People. PR #11511 by @tiangolo . 0.111.0 Features ✨ Add FastAPI CLI, the new fastapi command. PR #11522 by @tiangolo . New docs: FastAPI CLI . Try it out with: $ pip install --upgrade fastapi $ fastapi dev main.py ╭...ntic migration guide . For the things that need changes in your Pydantic models, the Pydantic team built bump-pydantic . A command line tool that will process your code and update most of the things automatically for you. Make sure you have your code in... - https://man.mtool.work/fastapi/0.115/release-notes/
PREV
1
NEXT