Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

web-ontogpt requires python-multipart #477

Closed
caufieldjh opened this issue Nov 12, 2024 · 0 comments · Fixed by #478
Closed

web-ontogpt requires python-multipart #477

caufieldjh opened this issue Nov 12, 2024 · 0 comments · Fixed by #478

Comments

@caufieldjh
Copy link
Member

After fixing #475, web-ontogpt raises this error:

~/ontogpt$ web-ontogpt
ERROR:fastapi:Form data requires "python-multipart" to be installed.
You can install "python-multipart" with:

pip install python-multipart

Traceback (most recent call last):
  File "/home/harry/ontogpt/.venv/bin/web-ontogpt", line 3, in <module>
    from ontogpt.webapp.main import start
  File "/home/harry/ontogpt/src/ontogpt/webapp/main.py", line 71, in <module>
    def form_post(
  File "/home/harry/ontogpt/.venv/lib/python3.10/site-packages/fastapi/routing.py", line 994, in decorator
    self.add_api_route(
  File "/home/harry/ontogpt/.venv/lib/python3.10/site-packages/fastapi/routing.py", line 933, in add_api_route
    route = route_class(
  File "/home/harry/ontogpt/.venv/lib/python3.10/site-packages/fastapi/routing.py", line 554, in __init__
    self.dependant = get_dependant(path=self.path_format, call=self.endpoint)
  File "/home/harry/ontogpt/.venv/lib/python3.10/site-packages/fastapi/dependencies/utils.py", line 285, in get_dependant
    param_details = analyze_param(
  File "/home/harry/ontogpt/.venv/lib/python3.10/site-packages/fastapi/dependencies/utils.py", line 482, in analyze_param
    ensure_multipart_is_installed()
  File "/home/harry/ontogpt/.venv/lib/python3.10/site-packages/fastapi/dependencies/utils.py", line 115, in ensure_multipart_is_installed
    raise RuntimeError(multipart_not_installed_error) from None
RuntimeError: Form data requires "python-multipart" to be installed.
You can install "python-multipart" with:

pip install python-multipart

This may be because multipart used to import python-multipart but this has changed (see fastapi/fastapi#5144 (comment)).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant