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

[BUG] Promptflow may not installed correctly #3904

Open
nihadtz opened this issue Jan 7, 2025 · 3 comments
Open

[BUG] Promptflow may not installed correctly #3904

nihadtz opened this issue Jan 7, 2025 · 3 comments
Labels
bug Something isn't working

Comments

@nihadtz
Copy link

nihadtz commented Jan 7, 2025

Describe the bug
With 1.17 released I am not able to run promptflow in Docker environment

How To Reproduce the bug
Build cocker images with 1.14 or 1.17 promptflow, no matter if it is locally or on existing pipelines, which worked yesterday.

Expected behavior
backend-container | Traceback (most recent call last):
backend-container | File "/usr/local/lib/python3.10/site-packages/promptflow/init.py", line 17, in
backend-container | from promptflow._sdk._load_functions import load_flow as _load_flow
backend-container | File "/usr/local/lib/python3.10/site-packages/promptflow/_sdk/_load_functions.py", line 15, in
backend-container | from .entities import Run
backend-container | File "/usr/local/lib/python3.10/site-packages/promptflow/_sdk/entities/init.py", line 8, in
backend-container | from ._connection import (
backend-container | File "/usr/local/lib/python3.10/site-packages/promptflow/_sdk/entities/_connection.py", line 33, in
backend-container | from promptflow._sdk.schemas._connection import (
backend-container | File "/usr/local/lib/python3.10/site-packages/promptflow/_sdk/schemas/_connection.py", line 11, in
backend-container | from promptflow._sdk.schemas._fields import StringTransformedEnum
backend-container | File "/usr/local/lib/python3.10/site-packages/promptflow/_sdk/schemas/_fields.py", line 10, in
backend-container | from marshmallow.fields import _T, Field, Nested
backend-container | ImportError: cannot import name '_T' from 'marshmallow.fields' (/usr/local/lib/python3.10/site-packages/marshmallow/fields.py)
backend-container |
backend-container | The above exception was the direct cause of the following exception:
backend-container |
backend-container | Traceback (most recent call last):
backend-container | File "/usr/local/lib/python3.10/site-packages/gunicorn/arbiter.py", line 589, in spawn_worker
backend-container | worker.init_process()
backend-container | File "/usr/local/lib/python3.10/site-packages/gunicorn/workers/gthread.py", line 92, in init_process
backend-container | super().init_process()
backend-container | File "/usr/local/lib/python3.10/site-packages/gunicorn/workers/base.py", line 134, in init_process
backend-container | self.load_wsgi()
backend-container | File "/usr/local/lib/python3.10/site-packages/gunicorn/workers/base.py", line 146, in load_wsgi
backend-container | self.wsgi = self.app.wsgi()
backend-container | File "/usr/local/lib/python3.10/site-packages/gunicorn/app/base.py", line 67, in wsgi
backend-container | self.callable = self.load()
backend-container | File "/usr/local/lib/python3.10/site-packages/gunicorn/app/wsgiapp.py", line 58, in load
backend-container | return self.load_wsgiapp()
backend-container | File "/usr/local/lib/python3.10/site-packages/gunicorn/app/wsgiapp.py", line 48, in load_wsgiapp
backend-container | return util.import_app(self.app_uri)
backend-container | File "/usr/local/lib/python3.10/site-packages/gunicorn/util.py", line 359, in import_app
backend-container | mod = importlib.import_module(module)
backend-container | File "/usr/local/lib/python3.10/importlib/init.py", line 126, in import_module
backend-container | return _bootstrap._gcd_import(name[level:], package, level)
backend-container | File "", line 1050, in _gcd_import
backend-container | File "", line 1027, in _find_and_load
backend-container | File "", line 992, in _find_and_load_unlocked
backend-container | File "", line 241, in _call_with_frames_removed
backend-container | File "", line 1050, in _gcd_import
backend-container | File "", line 1027, in _find_and_load
backend-container | File "", line 992, in _find_and_load_unlocked
backend-container | File "", line 241, in _call_with_frames_removed
backend-container | File "", line 1050, in _gcd_import
backend-container | File "", line 1027, in _find_and_load
backend-container | File "", line 992, in _find_and_load_unlocked
backend-container | File "", line 241, in _call_with_frames_removed
backend-container | File "", line 1050, in _gcd_import
backend-container | File "", line 1027, in _find_and_load
backend-container | File "", line 1006, in _find_and_load_unlocked
backend-container | File "", line 688, in _load_unlocked
backend-container | File "", line 883, in exec_module
backend-container | File "", line 241, in _call_with_frames_removed
backend-container | File "/usr/local/lib/python3.10/site-packages/promptflow/init.py", line 21, in
backend-container | raise Exception(
backend-container | Exception: Promptflow may not installed correctly. If you are upgrading from 'promptflow<1.8.0' to 'promptflow>=1.8.0', please run 'pip uninstall -y promptflow promptflow-core promptflow-devkit promptflow-azure', then 'pip install promptflow>=1.8.0'. Reach https://microsoft.github.io/promptflow/how-to-guides/faq.html#promptflow-1-8-0-upgrade-guide for more information.

@nihadtz nihadtz added the bug Something isn't working label Jan 7, 2025
@nihadtz
Copy link
Author

nihadtz commented Jan 7, 2025

FIX:

Add marshmallow==3.22.0 to requirements.txt

@aaronjolson
Copy link

Why this works, we may never know. But thank you for this @nihadtz !

@Huyueeer
Copy link

Huyueeer commented Jan 9, 2025

FIX:

Add marshmallow==3.22.0 to requirements.txt

Yes, it works

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants