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

version 1.1.0 fresh reinstall issue #4593

Open
severfire opened this issue Nov 14, 2024 · 25 comments
Open

version 1.1.0 fresh reinstall issue #4593

severfire opened this issue Nov 14, 2024 · 25 comments
Assignees
Labels
bug Something isn't working

Comments

@severfire
Copy link

severfire commented Nov 14, 2024

Bug Description

Hello,

I totally removed and reinstalled langflow, to update to new 1.1.0 version, while doing that i got very bad error...

while running:
python3 -m langflow run --env-file ./.env --no-open-browser --auto-saving --host localhost

got error:

> RuntimeError: There's a mismatch between the models and the database.
                             New upgrade operations detected: [('remove_table', Table('_alembic_tmp_apikey', MetaData(), Column('name', VARCHAR(), table=<_alembic_tmp_apikey>, nullable=False),
                             Column('last_used_at', DATETIME(), table=<_alembic_tmp_apikey>), Column('total_uses', INTEGER(), table=<_alembic_tmp_apikey>, nullable=False), Column('is_active',
                             BOOLEAN(), table=<_alembic_tmp_apikey>, nullable=False), Column('id', CHAR(length=32), table=<_alembic_tmp_apikey>, primary_key=True, nullable=False),
                             Column('created_at', DATETIME(), table=<_alembic_tmp_apikey>, nullable=False, server_default=DefaultClause(<sqlalchemy.sql.elements.TextClause object at
                             0x7fb62c5d5450>, for_update=False)), Column('api_key', VARCHAR(), table=<_alembic_tmp_apikey>, nullable=False), Column('user_id', CHAR(length=32),
                             ForeignKey('user.id'), table=<_alembic_tmp_apikey>, nullable=False), schema=None)), ('remove_table', Table('_alembic_tmp_flow', MetaData(), Column('name', VARCHAR(),
                             table=<_alembic_tmp_flow>, nullable=False), Column('description', TEXT(), table=<_alembic_tmp_flow>), Column('icon_bg_color', VARCHAR(), table=<_alembic_tmp_flow>),
                             Column('gradient', VARCHAR(), table=<_alembic_tmp_flow>), Column('is_component', BOOLEAN(), table=<_alembic_tmp_flow>), Column('updated_at', DATETIME(),
                             table=<_alembic_tmp_flow>), Column('webhook', BOOLEAN(), table=<_alembic_tmp_flow>), Column('endpoint_name', VARCHAR(), table=<_alembic_tmp_flow>), Column('id',
                             CHAR(length=32), table=<_alembic_tmp_flow>, primary_key=True, nullable=False), Column('data', JSON(), table=<_alembic_tmp_flow>), Column('user_id', CHAR(length=32),
                             ForeignKey('user.id'), table=<_alembic_tmp_flow>), Column('icon', VARCHAR(), table=<_alembic_tmp_flow>), Column('tags', JSON(), table=<_alembic_tmp_flow>),
                             Column('folder_id', CHAR(length=32), ForeignKey('folder.id'), table=<_alembic_tmp_flow>), Column('folder', VARCHAR(), table=<_alembic_tmp_flow>), schema=None))]

Reproduction

  1. total removal of langflow 1.0.18 with directory deletion
  2. totally new installation of 1.1.0

Expected behavior

it should start without problems

Who can help?

No response

Operating System

Ubuntu 22.04

Langflow Version

1.1.00

Python Version

3.10

Screenshot

No response

Flow File

No response

@severfire severfire added the bug Something isn't working label Nov 14, 2024
Copy link

dosubot bot commented Nov 14, 2024

To resolve the RuntimeError related to a mismatch between models and the database when reinstalling Langflow version 1.0.10, you can use the run_migrations method with the fix parameter set to True. This will attempt to downgrade and upgrade the database schema until the mismatch is resolved.

Here's how you can do it:

database_service = DatabaseService(settings_service)
database_service.run_migrations(fix=True)

This code snippet initializes the DatabaseService and runs the migrations with the fix option enabled, which will handle any mismatches by downgrading and upgrading the database schema until successful [1].

Additionally, there is a similar unsolved discussion about a large list of errors after running langflow migration --fix, which might be related to your issue. You can find more details in this discussion [2].

To continue talking to Dosu, mention @dosu.

@severfire
Copy link
Author

severfire commented Nov 14, 2024

did not work

~$ langflow migration --fix

This will delete all data necessary to fix migrations. Are you sure you want to continue? [y/N]: y
2024-11-14 10:26:18.968 | DEBUG    | langflow.services.manager:_create_service:55 - Create service cache_service
2024-11-14 10:26:18.968 | DEBUG    | langflow.services.manager:_create_service:55 - Create service settings_service
2024-11-14 10:26:18.972 | DEBUG    | langflow.services.settings.base:set_database_url:238 - No database_url provided, trying LANGFLOW_DATABASE_URL env variable
2024-11-14 10:26:18.973 | DEBUG    | langflow.services.settings.base:set_database_url:243 - No database_url env variable, using sqlite database
2024-11-14 10:26:18.973 | DEBUG    | langflow.services.settings.base:set_database_url:262 - Saving database to langflow directory: /home/langflow/.local/lib/python3.10/site-packages/langflow
2024-11-14 10:26:18.973 | DEBUG    | langflow.services.settings.base:set_database_url:285 - Database already exists at /home/langflow/.local/lib/python3.10/site-packages/langflow/langflow.db, using it
2024-11-14 10:26:18.973 | DEBUG    | langflow.services.settings.base:set_components_path:323 - Setting default components path to components_path
2024-11-14 10:26:18.973 | DEBUG    | langflow.services.settings.base:set_components_path:328 - Components path: ['/home/langflow/.local/lib/python3.10/site-packages/langflow/components']
2024-11-14 10:26:18.974 | DEBUG    | langflow.services.settings.base:set_user_agent:193 - Setting user agent to langflow
2024-11-14 10:26:18.977 | DEBUG    | langflow.services.settings.auth:get_secret_key:99 - No secret key provided, generating a random one
2024-11-14 10:26:18.977 | DEBUG    | langflow.services.settings.auth:get_secret_key:103 - Loaded secret key
2024-11-14 10:26:18.978 | DEBUG    | langflow.services.settings.auth:validate_superuser:77 - Resetting superuser password to default value
2024-11-14 10:26:18.978 | DEBUG    | langflow.services.database.utils:initialize_database:16 - Initializing database
2024-11-14 10:26:18.978 | DEBUG    | langflow.services.manager:_create_service:55 - Create service database_service
2024-11-14 10:26:18.989 | INFO     | langflow.services.database.service:on_connection:127 - sqlite connection, setting pragmas: ['PRAGMA synchronous = NORMAL', 'PRAGMA journal_mode = WAL']
2024-11-14 10:26:18.992 | DEBUG    | langflow.services.database.service:create_db_and_tables:323 - Database and tables already exist
2024-11-14 10:26:18.995 | INFO     | langflow.services.database.service:run_migrations:244 - Alembic already initialized
2024-11-14 10:26:18.995 | INFO     | langflow.services.database.service:run_migrations:246 - Running DB migrations in /home/langflow/.local/lib/python3.10/site-packages/langflow/alembic
2024-11-14 10:26:19.000 | INFO     | langflow.services.database.service:on_connection:127 - sqlite connection, setting pragmas: ['PRAGMA synchronous = NORMAL', 'PRAGMA journal_mode = WAL']
2024-11-14 10:26:19.070 | DEBUG    | langflow.services.database.service:run_migrations:252 - Error checking migrations
Traceback (most recent call last):

  File "/home/langflow/.local/bin/langflow", line 8, in <module>
    sys.exit(main())
    │   │    └ <function main at 0x7fdd70ea8b80>
    │   └ <built-in function exit>
    └ <module 'sys' (built-in)>
  File "/home/langflow/.local/lib/python3.10/site-packages/langflow/__main__.py", line 598, in main
    app()
    └ <typer.main.Typer object at 0x7fdd9c32b1c0>
  File "/home/langflow/.local/lib/python3.10/site-packages/typer/main.py", line 325, in __call__
    return get_command(self)(*args, **kwargs)
           │           │      │       └ {}
           │           │      └ ()
           │           └ <typer.main.Typer object at 0x7fdd9c32b1c0>
           └ <function get_command at 0x7fdd9c427250>
  File "/home/langflow/.local/lib/python3.10/site-packages/click/core.py", line 1157, in __call__
    return self.main(*args, **kwargs)
           │    │     │       └ {}
           │    │     └ ()
           │    └ <function TyperGroup.main at 0x7fdd9c425a20>
           └ <TyperGroup version-option>
  File "/home/langflow/.local/lib/python3.10/site-packages/typer/core.py", line 728, in main
    return _main(
           └ <function _main at 0x7fdd9c424dc0>
  File "/home/langflow/.local/lib/python3.10/site-packages/typer/core.py", line 197, in _main
    rv = self.invoke(ctx)
         │    │      └ <click.core.Context object at 0x7fdd9de2ffd0>
         │    └ <function MultiCommand.invoke at 0x7fdd9d3e04c0>
         └ <TyperGroup version-option>
  File "/home/langflow/.local/lib/python3.10/site-packages/click/core.py", line 1688, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
           │               │       │       │      └ <click.core.Context object at 0x7fdd70d3e5f0>
           │               │       │       └ <function Command.invoke at 0x7fdd9d3cff40>
           │               │       └ <TyperCommand migration>
           │               └ <click.core.Context object at 0x7fdd70d3e5f0>
           └ <function MultiCommand.invoke.<locals>._process_result at 0x7fdd7101fd90>
  File "/home/langflow/.local/lib/python3.10/site-packages/click/core.py", line 1434, in invoke
    return ctx.invoke(self.callback, **ctx.params)
           │   │      │    │           │   └ {'fix': True, 'test': True}
           │   │      │    │           └ <click.core.Context object at 0x7fdd70d3e5f0>
           │   │      │    └ <function migration at 0x7fdd70ea8ca0>
           │   │      └ <TyperCommand migration>
           │   └ <function Context.invoke at 0x7fdd9d3cecb0>
           └ <click.core.Context object at 0x7fdd70d3e5f0>
  File "/home/langflow/.local/lib/python3.10/site-packages/click/core.py", line 783, in invoke
    return __callback(*args, **kwargs)
                       │       └ {'fix': True, 'test': True}
                       └ ()
  File "/home/langflow/.local/lib/python3.10/site-packages/typer/main.py", line 707, in wrapper
    return callback(**use_params)
           │          └ {'test': True, 'fix': True}
           └ <function migration at 0x7fdd70ea8700>
  File "/home/langflow/.local/lib/python3.10/site-packages/langflow/__main__.py", line 497, in migration
    initialize_services(fix_migration=fix)
    │                                 └ True
    └ <function initialize_services at 0x7fdd82cbdd80>
  File "/home/langflow/.local/lib/python3.10/site-packages/langflow/services/utils.py", line 164, in initialize_services
    initialize_database(fix_migration=fix_migration)
    │                                 └ True
    └ <function initialize_database at 0x7fdd839eb250>
  File "/home/langflow/.local/lib/python3.10/site-packages/langflow/services/database/utils.py", line 36, in initialize_database
    database_service.run_migrations(fix=fix_migration)
    │                │                  └ True
    │                └ <function DatabaseService.run_migrations at 0x7fdd82cbe5f0>
    └ <langflow.services.database.service.DatabaseService object at 0x7fdd70d685b0>
> File "/home/langflow/.local/lib/python3.10/site-packages/langflow/services/database/service.py", line 250, in run_migrations
    command.check(alembic_cfg)
    │       │     └ <alembic.config.Config object at 0x7fdd70d685e0>
    │       └ <function check at 0x7fdd83c2d870>
    └ <module 'alembic.command' from '/home/langflow/.local/lib/python3.10/site-packages/alembic/command.py'>
  File "/home/langflow/.local/lib/python3.10/site-packages/alembic/command.py", line 300, in check
    raise util.AutogenerateDiffsDetected(
          │    └ <class 'alembic.util.exc.AutogenerateDiffsDetected'>
          └ <module 'alembic.util' from '/home/langflow/.local/lib/python3.10/site-packages/alembic/util/__init__.py'>

alembic.util.exc.AutogenerateDiffsDetected: New upgrade operations detected: [('remove_table', Table('_alembic_tmp_apikey', MetaData(), Column('name', VARCHAR(), table=<_alembic_tmp_apikey>, nullable=False), Column('last_used_at', DATETIME(), table=<_alembic_tmp_apikey>), Column('total_uses', INTEGER(), table=<_alembic_tmp_apikey>, nullable=False), Column('is_active', BOOLEAN(), table=<_alembic_tmp_apikey>, nullable=False), Column('id', CHAR(length=32), table=<_alembic_tmp_apikey>, primary_key=True, nullable=False), Column('created_at', DATETIME(), table=<_alembic_tmp_apikey>, nullable=False, server_default=DefaultClause(<sqlalchemy.sql.elements.TextClause object at 0x7fdd70cae170>, for_update=False)), Column('api_key', VARCHAR(), table=<_alembic_tmp_apikey>, nullable=False), Column('user_id', CHAR(length=32), ForeignKey('user.id'), table=<_alembic_tmp_apikey>, nullable=False), schema=None)), ('remove_table', Table('_alembic_tmp_flow', MetaData(), Column('name', VARCHAR(), table=<_alembic_tmp_flow>, nullable=False), Column('description', TEXT(), table=<_alembic_tmp_flow>), Column('icon_bg_color', VARCHAR(), table=<_alembic_tmp_flow>), Column('gradient', VARCHAR(), table=<_alembic_tmp_flow>), Column('is_component', BOOLEAN(), table=<_alembic_tmp_flow>), Column('updated_at', DATETIME(), table=<_alembic_tmp_flow>), Column('webhook', BOOLEAN(), table=<_alembic_tmp_flow>), Column('endpoint_name', VARCHAR(), table=<_alembic_tmp_flow>), Column('id', CHAR(length=32), table=<_alembic_tmp_flow>, primary_key=True, nullable=False), Column('data', JSON(), table=<_alembic_tmp_flow>), Column('user_id', CHAR(length=32), ForeignKey('user.id'), table=<_alembic_tmp_flow>), Column('icon', VARCHAR(), table=<_alembic_tmp_flow>), Column('tags', JSON(), table=<_alembic_tmp_flow>), Column('folder_id', CHAR(length=32), ForeignKey('folder.id'), table=<_alembic_tmp_flow>), Column('folder', VARCHAR(), table=<_alembic_tmp_flow>), schema=None))]
2024-11-14 10:26:19.075 | INFO     | langflow.services.database.service:on_connection:127 - sqlite connection, setting pragmas: ['PRAGMA synchronous = NORMAL', 'PRAGMA journal_mode = WAL']
2024-11-14 10:26:22.093 | INFO     | langflow.services.database.service:on_connection:127 - sqlite connection, setting pragmas: ['PRAGMA synchronous = NORMAL', 'PRAGMA journal_mode = WAL']
2024-11-14 10:26:22.157 | ERROR    | langflow.services.database.service:run_migrations:261 - Error checking migrations

@severfire severfire changed the title version 1.10 fresh reinstall issue version 1.0.10 fresh reinstall issue Nov 14, 2024
@severfire
Copy link
Author

severfire commented Nov 14, 2024

seems like removing db files from ~/.local/lib/python3.10/site-packages/langflow and running again langflow migration --fix worked out... now langflow starts, but with errors

 'langflow@server:~$ python3 -m langflow run --env-file ./.env --no-open-browser --auto-saving --host localhost
Starting Langflow v1.1.0...

[11/14/24 11:09:17] ERROR    2024-11-14 11:09:17 - ERROR    - directory_reader - Error while getting output types from code                                                               directory_reader.py:316
                             Traceback (most recent call last):

                               File "/usr/lib/python3.10/runpy.py", line 196, in _run_module_as_main
                                 return _run_code(code, main_globals, None,
                                        |         |     -> {'__name__': '__main__', '__doc__': None, '__package__': 'langflow', '__loader__':
                             <_frozen_importlib_external.SourceFileLoad...
                                        |         -> <code object <module> at 0x7fe3dd437940, file "/home/langflow/.local/lib/python3.10/site-packages/langflow/__main__.py", line 1>
                                        -> <function _run_code at 0x7fe3dd449120>
                               File "/usr/lib/python3.10/runpy.py", line 86, in _run_code
                                 exec(code, run_globals)
                                      |     -> {'__name__': '__main__', '__doc__': None, '__package__': 'langflow', '__loader__': <_frozen_importlib_external.SourceFileLoad...
                                      -> <code object <module> at 0x7fe3dd437940, file "/home/langflow/.local/lib/python3.10/site-packages/langflow/__main__.py", line 1>
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/__main__.py", line 603, in <module>
                                 main()
                                 -> <function main at 0x7fe3b05ed2d0>
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/__main__.py", line 598, in main
                                 app()
                                 -> <typer.main.Typer object at 0x7fe3dbaa6fb0>
                               File "/home/langflow/.local/lib/python3.10/site-packages/typer/main.py", line 325, in __call__
                                 return get_command(self)(*args, **kwargs)
                                        |           |      |       -> {}
                                        |           |      -> ()
                                        |           -> <typer.main.Typer object at 0x7fe3dbaa6fb0>
                                        -> <function get_command at 0x7fe3dbb9fb50>
                               File "/home/langflow/.local/lib/python3.10/site-packages/click/core.py", line 1157, in __call__
                                 return self.main(*args, **kwargs)
                                        |    |     |       -> {}
                                        |    |     -> ()
                                        |    -> <function TyperGroup.main at 0x7fe3dbb9e320>
                                        -> <TyperGroup version-option>
                               File "/home/langflow/.local/lib/python3.10/site-packages/typer/core.py", line 728, in main
                                 return _main(
                                        -> <function _main at 0x7fe3dbb9d6c0>
                               File "/home/langflow/.local/lib/python3.10/site-packages/typer/core.py", line 197, in _main
                                 rv = self.invoke(ctx)
                                      |    |      -> <click.core.Context object at 0x7fe3b049b370>
                                      |    -> <function MultiCommand.invoke at 0x7fe3dcb52a70>
                                      -> <TyperGroup version-option>
                               File "/home/langflow/.local/lib/python3.10/site-packages/click/core.py", line 1688, in invoke
                                 return _process_result(sub_ctx.command.invoke(sub_ctx))
                                        |               |       |       |      -> <click.core.Context object at 0x7fe3b049a350>
                                        |               |       |       -> <function Command.invoke at 0x7fe3dcb52560>
                                        |               |       -> <TyperCommand run>
                                        |               -> <click.core.Context object at 0x7fe3b049a350>
                                        -> <function MultiCommand.invoke.<locals>._process_result at 0x7fe3b0772f80>
                               File "/home/langflow/.local/lib/python3.10/site-packages/click/core.py", line 1434, in invoke
                                 return ctx.invoke(self.callback, **ctx.params)
                                        |   |      |    |           |   -> {'env_file': './.env', 'open_browser': False, 'auto_saving': True, 'host': 'localhost', 'workers': None,
                             'worker_timeout': No...
                                        |   |      |    |           -> <click.core.Context object at 0x7fe3b049a350>
                                        |   |      |    -> <function run at 0x7fe3b05ed510>
                                        |   |      -> <TyperCommand run>
                                        |   -> <function Context.invoke at 0x7fe3dcb512d0>
                                        -> <click.core.Context object at 0x7fe3b049a350>
                               File "/home/langflow/.local/lib/python3.10/site-packages/click/core.py", line 783, in invoke
                                 return __callback(*args, **kwargs)
                                                    |       -> {'env_file': './.env', 'open_browser': False, 'auto_saving': True, 'host': 'localhost', 'workers': None, 'worker_timeout':
                             No...
                                                    -> ()
                               File "/home/langflow/.local/lib/python3.10/site-packages/typer/main.py", line 707, in wrapper
                                 return callback(**use_params)
                                        |          -> {'host': 'localhost', 'workers': None, 'worker_timeout': None, 'port': None, 'components_path': PosixPath('/home/langflow/.lo...
                                        -> <function run at 0x7fe3b05ec790>
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/__main__.py", line 218, in run
                                 process = run_on_mac_or_linux(host, port, log_level, options, app)
                                           |                   |     |     |          |        -> <fastapi.applications.FastAPI object at 0x7fe3b04c4c10>
                                           |                   |     |     |          -> {'bind': 'localhost:7860', 'workers': 1, 'timeout': 300, 'worker_class':
                             'langflow.server.LangflowUvicornWorker', 'logger_cla...
                                           |                   |     |     -> 'critical'
                                           |                   |     -> 7860
                                           |                   -> 'localhost'
                                           -> <function run_on_mac_or_linux at 0x7fe3b05edcf0>
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/__main__.py", line 254, in run_on_mac_or_linux
                                 webapp_process.start()
                                 |              -> <function BaseProcess.start at 0x7fe3dbbb7400>
                                 -> <Process name='Process-1' parent=88579 started>
                               File "/home/langflow/.local/lib/python3.10/site-packages/multiprocess/process.py", line 121, in start
                                 self._popen = self._Popen(self)
                                 |    |        |    |      -> <Process name='Process-1' parent=88579 started>
                                 |    |        |    -> <staticmethod(<function Process._Popen at 0x7fe3dbaa3490>)>
                                 |    |        -> <Process name='Process-1' parent=88579 started>
                                 |    -> None
                                 -> <Process name='Process-1' parent=88579 started>
                               File "/home/langflow/.local/lib/python3.10/site-packages/multiprocess/context.py", line 224, in _Popen
                                 return _default_context.get_context().Process._Popen(process_obj)
                                        |                |                            -> <Process name='Process-1' parent=88579 started>
                                        |                -> <function DefaultContext.get_context at 0x7fe3dbaa3640>
                                        -> <multiprocess.context.DefaultContext object at 0x7fe3dbbd2170>
                               File "/home/langflow/.local/lib/python3.10/site-packages/multiprocess/context.py", line 281, in _Popen
                                 return Popen(process_obj)
                                        |     -> <Process name='Process-1' parent=88579 started>
                                        -> <class 'multiprocess.popen_fork.Popen'>
                               File "/home/langflow/.local/lib/python3.10/site-packages/multiprocess/popen_fork.py", line 19, in __init__
                                 self._launch(process_obj)
                                 |    |       -> <Process name='Process-1' parent=88579 started>
                                 |    -> <function Popen._launch at 0x7fe3afaf3010>
                                 -> <multiprocess.popen_fork.Popen object at 0x7fe3af98fd00>
                               File "/home/langflow/.local/lib/python3.10/site-packages/multiprocess/popen_fork.py", line 71, in _launch
                                 code = process_obj._bootstrap(parent_sentinel=child_r)
                                        |           |                          -> 6
                                        |           -> <function BaseProcess._bootstrap at 0x7fe3dbbb7d00>
                                        -> <Process name='Process-1' parent=88579 started>
                               File "/home/langflow/.local/lib/python3.10/site-packages/multiprocess/process.py", line 314, in _bootstrap
                                 self.run()
                                 |    -> <function BaseProcess.run at 0x7fe3dbbb7370>
                                 -> <Process name='Process-1' parent=88579 started>
                               File "/home/langflow/.local/lib/python3.10/site-packages/multiprocess/process.py", line 108, in run
                                 self._target(*self._args, **self._kwargs)
                                 |    |        |    |        |    -> {}
                                 |    |        |    |        -> <Process name='Process-1' parent=88579 started>
                                 |    |        |    -> ('localhost', 7860, 'critical', {'bind': 'localhost:7860', 'workers': 1, 'timeout': 300, 'worker_class': 'langflow.server.Lan...
                                 |    |        -> <Process name='Process-1' parent=88579 started>
                                 |    -> <function run_langflow at 0x7fe3b05ecb80>
                                 -> <Process name='Process-1' parent=88579 started>
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/__main__.py", line 408, in run_langflow
                                 server.run()
                                 |      -> <function BaseApplication.run at 0x7fe3d5b49870>
                                 -> <langflow.server.LangflowApplication object at 0x7fe3dbbaf8e0>
                               File "/home/langflow/.local/lib/python3.10/site-packages/gunicorn/app/base.py", line 71, in run
                                 Arbiter(self).run()
                                 |       -> <langflow.server.LangflowApplication object at 0x7fe3dbbaf8e0>
                                 -> <class 'gunicorn.arbiter.Arbiter'>
                               File "/home/langflow/.local/lib/python3.10/site-packages/gunicorn/arbiter.py", line 201, in run
                                 self.manage_workers()
                                 |    -> <function Arbiter.manage_workers at 0x7fe3d5b148b0>
                                 -> <gunicorn.arbiter.Arbiter object at 0x7fe3af9e2710>
                               File "/home/langflow/.local/lib/python3.10/site-packages/gunicorn/arbiter.py", line 570, in manage_workers
                                 self.spawn_workers()
                                 |    -> <function Arbiter.spawn_workers at 0x7fe3d5b149d0>
                                 -> <gunicorn.arbiter.Arbiter object at 0x7fe3af9e2710>
                               File "/home/langflow/.local/lib/python3.10/site-packages/gunicorn/arbiter.py", line 641, in spawn_workers
                                 self.spawn_worker()
                                 |    -> <function Arbiter.spawn_worker at 0x7fe3d5b14940>
                                 -> <gunicorn.arbiter.Arbiter object at 0x7fe3af9e2710>
                               File "/home/langflow/.local/lib/python3.10/site-packages/gunicorn/arbiter.py", line 608, in spawn_worker
                                 worker.init_process()
                                 |      -> <function UvicornWorker.init_process at 0x7fe3d5bfc670>
                                 -> <langflow.server.LangflowUvicornWorker object at 0x7fe3d5bbc100>
                               File "/home/langflow/.local/lib/python3.10/site-packages/uvicorn/workers.py", line 75, in init_process
                                 super().init_process()
                               File "/home/langflow/.local/lib/python3.10/site-packages/gunicorn/workers/base.py", line 143, in init_process
                                 self.run()
                                 |    -> <function UvicornWorker.run at 0x7fe3d5bfc8b0>
                                 -> <langflow.server.LangflowUvicornWorker object at 0x7fe3d5bbc100>
                               File "/home/langflow/.local/lib/python3.10/site-packages/uvicorn/workers.py", line 107, in run
                                 return asyncio.run(self._serve())
                                        |       |   |    -> <function LangflowUvicornWorker._serve at 0x7fe3d5bfc9d0>
                                        |       |   -> <langflow.server.LangflowUvicornWorker object at 0x7fe3d5bbc100>
                                        |       -> <function run at 0x7fe3dd602710>
                                        -> <module 'asyncio' from '/usr/lib/python3.10/asyncio/__init__.py'>
                               File "/usr/lib/python3.10/asyncio/runners.py", line 44, in run
                                 return loop.run_until_complete(main)
                                        |    |                  -> <coroutine object LangflowUvicornWorker._serve at 0x7fe3d5b92110>
                                        |    -> <function BaseEventLoop.run_until_complete at 0x7fe3dcc02320>
                                        -> <_UnixSelectorEventLoop running=True closed=False debug=False>
                               File "/usr/lib/python3.10/asyncio/base_events.py", line 636, in run_until_complete
                                 self.run_forever()
                                 |    -> <function BaseEventLoop.run_forever at 0x7fe3dcc02290>
                                 -> <_UnixSelectorEventLoop running=True closed=False debug=False>
                               File "/usr/lib/python3.10/asyncio/base_events.py", line 603, in run_forever
                                 self._run_once()
                                 |    -> <function BaseEventLoop._run_once at 0x7fe3dcc03d90>
                                 -> <_UnixSelectorEventLoop running=True closed=False debug=False>
                               File "/usr/lib/python3.10/asyncio/base_events.py", line 1909, in _run_once
                                 handle._run()
                                 |      -> <function Handle._run at 0x7fe3dcd5b760>
                                 -> <Handle Task.task_wakeup(<Future finis...-guarantee.')>)>
                               File "/usr/lib/python3.10/asyncio/events.py", line 80, in _run
                                 self._context.run(self._callback, *self._args)
                                 |    |            |    |           |    -> <member '_args' of 'Handle' objects>
                                 |    |            |    |           -> <Handle Task.task_wakeup(<Future finis...-guarantee.')>)>
                                 |    |            |    -> <member '_callback' of 'Handle' objects>
                                 |    |            -> <Handle Task.task_wakeup(<Future finis...-guarantee.')>)>
                                 |    -> <member '_context' of 'Handle' objects>
                                 -> <Handle Task.task_wakeup(<Future finis...-guarantee.')>)>
                               File "/home/langflow/.local/lib/python3.10/site-packages/uvicorn/lifespan/on.py", line 86, in main
                                 await app(scope, self.receive, self.send)
                                       |   |      |    |        |    -> <function LifespanOn.send at 0x7fe3d59e04c0>
                                       |   |      |    |        -> <uvicorn.lifespan.on.LifespanOn object at 0x7fe3dbecb280>
                                       |   |      |    -> <function LifespanOn.receive at 0x7fe3d59e0550>
                                       |   |      -> <uvicorn.lifespan.on.LifespanOn object at 0x7fe3dbecb280>
                                       |   -> {'type': 'lifespan', 'asgi': {'version': '3.0', 'spec_version': '2.0'}, 'state': {}, 'app': <fastapi.applications.FastAPI obj...
                                       -> <uvicorn.middleware.proxy_headers.ProxyHeadersMiddleware object at 0x7fe3d9c33970>
                               File "/home/langflow/.local/lib/python3.10/site-packages/uvicorn/middleware/proxy_headers.py", line 29, in __call__
                                 return await self.app(scope, receive, send)
                                              |    |   |      |        -> <bound method LifespanOn.send of <uvicorn.lifespan.on.LifespanOn object at 0x7fe3dbecb280>>
                                              |    |   |      -> <bound method LifespanOn.receive of <uvicorn.lifespan.on.LifespanOn object at 0x7fe3dbecb280>>
                                              |    |   -> {'type': 'lifespan', 'asgi': {'version': '3.0', 'spec_version': '2.0'}, 'state': {}, 'app': <fastapi.applications.FastAPI
                             obj...
                                              |    -> <fastapi.applications.FastAPI object at 0x7fe3b04c4c10>
                                              -> <uvicorn.middleware.proxy_headers.ProxyHeadersMiddleware object at 0x7fe3d9c33970>
                               File "/home/langflow/.local/lib/python3.10/site-packages/fastapi/applications.py", line 1054, in __call__
                                 await super().__call__(scope, receive, send)
                                                        |      |        -> <bound method LifespanOn.send of <uvicorn.lifespan.on.LifespanOn object at 0x7fe3dbecb280>>
                                                        |      -> <bound method LifespanOn.receive of <uvicorn.lifespan.on.LifespanOn object at 0x7fe3dbecb280>>
                                                        -> {'type': 'lifespan', 'asgi': {'version': '3.0', 'spec_version': '2.0'}, 'state': {}, 'app': <fastapi.applications.FastAPI
                             obj...
                               File "/home/langflow/.local/lib/python3.10/site-packages/starlette/applications.py", line 113, in __call__
                                 await self.middleware_stack(scope, receive, send)
                                       |    |                |      |        -> <bound method LifespanOn.send of <uvicorn.lifespan.on.LifespanOn object at 0x7fe3dbecb280>>
                                       |    |                |      -> <bound method LifespanOn.receive of <uvicorn.lifespan.on.LifespanOn object at 0x7fe3dbecb280>>
                                       |    |                -> {'type': 'lifespan', 'asgi': {'version': '3.0', 'spec_version': '2.0'}, 'state': {}, 'app': <fastapi.applications.FastAPI
                             obj...
                                       |    -> <starlette.middleware.errors.ServerErrorMiddleware object at 0x7fe3d59d0d90>
                                       -> <fastapi.applications.FastAPI object at 0x7fe3b04c4c10>
                               File "/home/langflow/.local/lib/python3.10/site-packages/starlette/middleware/errors.py", line 152, in __call__
                                 await self.app(scope, receive, send)
                                       |    |   |      |        -> <bound method LifespanOn.send of <uvicorn.lifespan.on.LifespanOn object at 0x7fe3dbecb280>>
                                       |    |   |      -> <bound method LifespanOn.receive of <uvicorn.lifespan.on.LifespanOn object at 0x7fe3dbecb280>>
                                       |    |   -> {'type': 'lifespan', 'asgi': {'version': '3.0', 'spec_version': '2.0'}, 'state': {}, 'app': <fastapi.applications.FastAPI obj...
                                       |    -> <opentelemetry.instrumentation.asgi.OpenTelemetryMiddleware object at 0x7fe3d59d1060>
                                       -> <starlette.middleware.errors.ServerErrorMiddleware object at 0x7fe3d59d0d90>
                               File "/home/langflow/.local/lib/python3.10/site-packages/opentelemetry/instrumentation/asgi/__init__.py", line 681, in __call__
                                 return await self.app(scope, receive, send)
                                              |    |   |      |        -> <bound method LifespanOn.send of <uvicorn.lifespan.on.LifespanOn object at 0x7fe3dbecb280>>
                                              |    |   |      -> <bound method LifespanOn.receive of <uvicorn.lifespan.on.LifespanOn object at 0x7fe3dbecb280>>
                                              |    |   -> {'type': 'lifespan', 'asgi': {'version': '3.0', 'spec_version': '2.0'}, 'state': {}, 'app': <fastapi.applications.FastAPI
                             obj...
                                              |    -> <starlette.middleware.base.BaseHTTPMiddleware object at 0x7fe3d59d10c0>
                                              -> <opentelemetry.instrumentation.asgi.OpenTelemetryMiddleware object at 0x7fe3d59d1060>
                               File "/home/langflow/.local/lib/python3.10/site-packages/starlette/middleware/base.py", line 101, in __call__
                                 await self.app(scope, receive, send)
                                       |    |   |      |        -> <bound method LifespanOn.send of <uvicorn.lifespan.on.LifespanOn object at 0x7fe3dbecb280>>
                                       |    |   |      -> <bound method LifespanOn.receive of <uvicorn.lifespan.on.LifespanOn object at 0x7fe3dbecb280>>
                                       |    |   -> {'type': 'lifespan', 'asgi': {'version': '3.0', 'spec_version': '2.0'}, 'state': {}, 'app': <fastapi.applications.FastAPI obj...
                                       |    -> <starlette.middleware.base.BaseHTTPMiddleware object at 0x7fe3d59d1120>
                                       -> <starlette.middleware.base.BaseHTTPMiddleware object at 0x7fe3d59d10c0>
                               File "/home/langflow/.local/lib/python3.10/site-packages/starlette/middleware/base.py", line 101, in __call__
                                 await self.app(scope, receive, send)
                                       |    |   |      |        -> <bound method LifespanOn.send of <uvicorn.lifespan.on.LifespanOn object at 0x7fe3dbecb280>>
                                       |    |   |      -> <bound method LifespanOn.receive of <uvicorn.lifespan.on.LifespanOn object at 0x7fe3dbecb280>>
                                       |    |   -> {'type': 'lifespan', 'asgi': {'version': '3.0', 'spec_version': '2.0'}, 'state': {}, 'app': <fastapi.applications.FastAPI obj...
                                       |    -> <langflow.main.JavaScriptMIMETypeMiddleware object at 0x7fe3d59d1150>
                                       -> <starlette.middleware.base.BaseHTTPMiddleware object at 0x7fe3d59d1120>
                               File "/home/langflow/.local/lib/python3.10/site-packages/starlette/middleware/base.py", line 101, in __call__
                                 await self.app(scope, receive, send)
                                       |    |   |      |        -> <bound method LifespanOn.send of <uvicorn.lifespan.on.LifespanOn object at 0x7fe3dbecb280>>
                                       |    |   |      -> <bound method LifespanOn.receive of <uvicorn.lifespan.on.LifespanOn object at 0x7fe3dbecb280>>
                                       |    |   -> {'type': 'lifespan', 'asgi': {'version': '3.0', 'spec_version': '2.0'}, 'state': {}, 'app': <fastapi.applications.FastAPI obj...
                                       |    -> <starlette.middleware.cors.CORSMiddleware object at 0x7fe3d59d1360>
                                       -> <langflow.main.JavaScriptMIMETypeMiddleware object at 0x7fe3d59d1150>
                               File "/home/langflow/.local/lib/python3.10/site-packages/starlette/middleware/cors.py", line 77, in __call__
                                 await self.app(scope, receive, send)
                                       |    |   |      |        -> <bound method LifespanOn.send of <uvicorn.lifespan.on.LifespanOn object at 0x7fe3dbecb280>>
                                       |    |   |      -> <bound method LifespanOn.receive of <uvicorn.lifespan.on.LifespanOn object at 0x7fe3dbecb280>>
                                       |    |   -> {'type': 'lifespan', 'asgi': {'version': '3.0', 'spec_version': '2.0'}, 'state': {}, 'app': <fastapi.applications.FastAPI obj...
                                       |    -> <starlette.middleware.exceptions.ExceptionMiddleware object at 0x7fe3d59d1180>
                                       -> <starlette.middleware.cors.CORSMiddleware object at 0x7fe3d59d1360>
                               File "/home/langflow/.local/lib/python3.10/site-packages/starlette/middleware/exceptions.py", line 48, in __call__
                                 await self.app(scope, receive, send)
                                       |    |   |      |        -> <bound method LifespanOn.send of <uvicorn.lifespan.on.LifespanOn object at 0x7fe3dbecb280>>
                                       |    |   |      -> <bound method LifespanOn.receive of <uvicorn.lifespan.on.LifespanOn object at 0x7fe3dbecb280>>
                                       |    |   -> {'type': 'lifespan', 'asgi': {'version': '3.0', 'spec_version': '2.0'}, 'state': {}, 'app': <fastapi.applications.FastAPI obj...
                                       |    -> <fastapi.routing.APIRouter object at 0x7fe3b04c5960>
                                       -> <starlette.middleware.exceptions.ExceptionMiddleware object at 0x7fe3d59d1180>
                               File "/home/langflow/.local/lib/python3.10/site-packages/starlette/routing.py", line 715, in __call__
                                 await self.middleware_stack(scope, receive, send)
                                       |    |                |      |        -> <bound method LifespanOn.send of <uvicorn.lifespan.on.LifespanOn object at 0x7fe3dbecb280>>
                                       |    |                |      -> <bound method LifespanOn.receive of <uvicorn.lifespan.on.LifespanOn object at 0x7fe3dbecb280>>
                                       |    |                -> {'type': 'lifespan', 'asgi': {'version': '3.0', 'spec_version': '2.0'}, 'state': {}, 'app': <fastapi.applications.FastAPI
                             obj...
                                       |    -> <bound method Router.app of <fastapi.routing.APIRouter object at 0x7fe3b04c5960>>
                                       -> <fastapi.routing.APIRouter object at 0x7fe3b04c5960>
                               File "/home/langflow/.local/lib/python3.10/site-packages/starlette/routing.py", line 724, in app
                                 await self.lifespan(scope, receive, send)
                                       |    |        |      |        -> <bound method LifespanOn.send of <uvicorn.lifespan.on.LifespanOn object at 0x7fe3dbecb280>>
                                       |    |        |      -> <bound method LifespanOn.receive of <uvicorn.lifespan.on.LifespanOn object at 0x7fe3dbecb280>>
                                       |    |        -> {'type': 'lifespan', 'asgi': {'version': '3.0', 'spec_version': '2.0'}, 'state': {}, 'app': <fastapi.applications.FastAPI obj...
                                       |    -> <function Router.lifespan at 0x7fe3da0ed480>
                                       -> <fastapi.routing.APIRouter object at 0x7fe3b04c5960>
                               File "/home/langflow/.local/lib/python3.10/site-packages/starlette/routing.py", line 693, in lifespan
                                 async with self.lifespan_context(app) as maybe_state:
                                            |    |                -> <fastapi.applications.FastAPI object at 0x7fe3b04c4c10>
                                            |    -> <function _merge_lifespan_context.<locals>.merged_lifespan at 0x7fe3afaf1d80>
                                            -> <fastapi.routing.APIRouter object at 0x7fe3b04c5960>
                               File "/home/langflow/.local/lib/python3.10/site-packages/fastapi/routing.py", line 133, in merged_lifespan
                                 async with original_context(app) as maybe_original_state:
                                            |                -> <fastapi.applications.FastAPI object at 0x7fe3b04c4c10>
                                            -> <function _merge_lifespan_context.<locals>.merged_lifespan at 0x7fe3afaf0e50>
                               File "/home/langflow/.local/lib/python3.10/site-packages/fastapi/routing.py", line 133, in merged_lifespan
                                 async with original_context(app) as maybe_original_state:
                                            |                -> <fastapi.applications.FastAPI object at 0x7fe3b04c4c10>
                                            -> <function _merge_lifespan_context.<locals>.merged_lifespan at 0x7fe3b03a5e10>
                               File "/home/langflow/.local/lib/python3.10/site-packages/fastapi/routing.py", line 133, in merged_lifespan
                                 async with original_context(app) as maybe_original_state:
                                            |                -> <fastapi.applications.FastAPI object at 0x7fe3b04c4c10>
                                            -> <function get_lifespan.<locals>.lifespan at 0x7fe3b05ee4d0>
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/main.py", line 108, in lifespan
                                 all_types_dict = await get_and_cache_all_types_dict(get_settings_service())
                                                        |                            -> <function get_settings_service at 0x7fe3c2cd4670>
                                                        -> <function get_and_cache_all_types_dict at 0x7fe3b05ee200>
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/interface/types.py", line 67, in get_and_cache_all_types_dict
                                 all_types_dict_cache = await aget_all_types_dict(settings_service.settings.components_path)
                                                              |                   |                |        -> ['/home/langflow/.local/lib/python3.10/site-packages/langflow/components']
                                                              |                   |                -> Settings(config_dir='/home/langflow/.cache/langflow', save_db_in_config_dir=False,
                             dev=False, database_url='sqlite:////home/l...
                                                              |                   -> <langflow.services.settings.service.SettingsService object at 0x7fe3b04c4fd0>
                                                              -> <function aget_all_types_dict at 0x7fe3b063f0a0>
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/interface/types.py", line 16, in aget_all_types_dict
                                 return await abuild_custom_components(components_paths=components_paths)
                                              |                                         -> ['/home/langflow/.local/lib/python3.10/site-packages/langflow/components']
                                              -> <function abuild_custom_components at 0x7fe3b0a54160>
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/custom/utils.py", line 497, in abuild_custom_components
                                 custom_component_dict = await abuild_custom_component_list_from_path(path_str)
                                                               |                                      -> '/home/langflow/.local/lib/python3.10/site-packages/langflow/components'
                                                               -> <function abuild_custom_component_list_from_path at 0x7fe3b0ca2680>
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/custom/directory_reader/utils.py", line 89, in abuild_custom_component_list_from_path
                                 valid_components, invalid_components = await abuild_and_validate_all_files(reader, file_list)
                                                                              |                             |       ->
                             ['/home/langflow/.local/lib/python3.10/site-packages/langflow/components/retrievers/multi_query.py', '/home/langflow/.local/l...
                                                                              |                             -> <langflow.custom.directory_reader.directory_reader.DirectoryReader object
                             at 0x7fe3d5745e10>
                                                                              -> <function abuild_and_validate_all_files at 0x7fe3b0ca1f30>
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/custom/directory_reader/utils.py", line 56, in abuild_and_validate_all_files
                                 data = await reader.abuild_component_menu_list(file_list)
                                              |      |                          -> ['/home/langflow/.local/lib/python3.10/site-packages/langflow/components/retrievers/multi_query.py',
                             '/home/langflow/.local/l...
                                              |      -> <function DirectoryReader.abuild_component_menu_list at 0x7fe3b0ca1ea0>
                                              -> <langflow.custom.directory_reader.directory_reader.DirectoryReader object at 0x7fe3d5745e10>
                             > File "/home/langflow/.local/lib/python3.10/site-packages/langflow/custom/directory_reader/directory_reader.py", line 314, in abuild_component_menu_list
                                 output_types = await self.get_output_types_from_code_async(result_content)
                                                      |    |                                -> 'import weaviate\nfrom langchain_community.vectorstores import Weaviate\n\nfrom
                             langflow.base.vectorstores.model import LCVec...
                                                      |    -> <function DirectoryReader.get_output_types_from_code_async at 0x7fe3b0ca1b40>
                                                      -> <langflow.custom.directory_reader.directory_reader.DirectoryReader object at 0x7fe3d5745e10>
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/custom/directory_reader/directory_reader.py", line 283, in
                             get_output_types_from_code_async
                                 return await asyncio.to_thread(self.get_output_types_from_code, code)
                                              |       |         |    |                           -> 'import weaviate\nfrom langchain_community.vectorstores import Weaviate\n\nfrom
                             langflow.base.vectorstores.model import LCVec...
                                              |       |         |    -> <staticmethod(<function DirectoryReader.get_output_types_from_code at 0x7fe3b0ca1cf0>)>
                                              |       |         -> <langflow.custom.directory_reader.directory_reader.DirectoryReader object at 0x7fe3d5745e10>
                                              |       -> <function to_thread at 0x7fe3dcc0eb90>
                                              -> <module 'asyncio' from '/usr/lib/python3.10/asyncio/__init__.py'>
                               File "/usr/lib/python3.10/asyncio/threads.py", line 25, in to_thread
                                 return await loop.run_in_executor(None, func_call)
                                              |    |                     -> functools.partial(<built-in method run of _contextvars.Context object at 0x7fe3d5584900>, <function
                             DirectoryReader.get_outpu...
                                              |    -> <function BaseEventLoop.run_in_executor at 0x7fe3dcc02b00>
                                              -> <_UnixSelectorEventLoop running=True closed=False debug=False>
                               File "/usr/lib/python3.10/concurrent/futures/thread.py", line 58, in run
                                 result = self.fn(*self.args, **self.kwargs)
                                          |        |            -> None
                                          |        -> None
                                          -> None
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/custom/directory_reader/directory_reader.py", line 340, in get_output_types_from_code
                                 types_list = custom_component._get_function_entrypoint_return_type
                                              |                -> <property object at 0x7fe3b0c709a0>
                                              -> <langflow.custom.custom_component.component.Component object at 0x7fe3ac3ee500>
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/custom/custom_component/custom_component.py", line 374, in
                             _get_function_entrypoint_return_type
                                 return self.get_method_return_type(self._function_entrypoint_name)
                                        |    |                      |    -> 'build'
                                        |    |                      -> <langflow.custom.custom_component.component.Component object at 0x7fe3ac3ee500>
                                        |    -> <function CustomComponent.get_method_return_type at 0x7fe3b0c6e7a0>
                                        -> <langflow.custom.custom_component.component.Component object at 0x7fe3ac3ee500>
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/custom/custom_component/custom_component.py", line 301, in get_method_return_type
                                 build_method = self.get_method(method_name)
                                                |    |          -> 'build'
                                                |    -> <function CustomComponent.get_method at 0x7fe3b0c6e950>
                                                -> <langflow.custom.custom_component.component.Component object at 0x7fe3ac3ee500>
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/custom/custom_component/custom_component.py", line 356, in get_method
                                 cls for cls in self.tree["classes"] if "Component" in cls["bases"] or "CustomComponent" in cls["bases"]
                                                |    -> <property object at 0x7fe3b0c70900>
                                                -> <langflow.custom.custom_component.component.Component object at 0x7fe3ac3ee500>
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/custom/custom_component/custom_component.py", line 243, in tree
                                 return self.get_code_tree(self._code or "")
                                        |    |             |    -> 'import weaviate\nfrom langchain_community.vectorstores import Weaviate\n\nfrom langflow.base.vectorstores.model
                             import LCVec...
                                        |    |             -> <langflow.custom.custom_component.component.Component object at 0x7fe3ac3ee500>
                                        |    -> <function BaseComponent.get_code_tree at 0x7fe3b0c6d000>
                                        -> <langflow.custom.custom_component.component.Component object at 0x7fe3ac3ee500>
                               File "/home/langflow/.local/lib/python3.10/site-packages/cachetools/__init__.py", line 814, in wrapper
                                 v = method(self, *args, **kwargs)
                                     |      |      |       -> {}
                                     |      |      -> ('import weaviate\nfrom langchain_community.vectorstores import Weaviate\n\nfrom langflow.base.vectorstores.model import LCVe...
                                     |      -> <langflow.custom.custom_component.component.Component object at 0x7fe3ac3ee500>
                                     -> <function BaseComponent.get_code_tree at 0x7fe3b0c6cf70>
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/custom/custom_component/base_component.py", line 50, in get_code_tree
                                 return parser.parse_code()
                                        |      -> <function CodeParser.parse_code at 0x7fe3b0c6cee0>
                                        -> <langflow.custom.code_parser.code_parser.CodeParser object at 0x7fe37d063820>
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/custom/code_parser/code_parser.py", line 360, in parse_code
                                 self.parse_node(node)
                                 |    |          -> <ast.ClassDef object at 0x7fe37edc9870>
                                 |    -> <function CodeParser.parse_node at 0x7fe3b0c6c310>
                                 -> <langflow.custom.code_parser.code_parser.CodeParser object at 0x7fe37d063820>
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/custom/code_parser/code_parser.py", line 104, in parse_node
                                 handler(node)  # type: ignore
                                 |       -> <ast.ClassDef object at 0x7fe37edc9870>
                                 -> <bound method CodeParser.parse_classes of <langflow.custom.code_parser.code_parser.CodeParser object at 0x7fe37d063820>>
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/custom/code_parser/code_parser.py", line 294, in parse_classes
                                 bases = self.get_base_classes()
                                         |    -> <function CodeParser.get_base_classes at 0x7fe3b0c6cc10>
                                         -> <langflow.custom.code_parser.code_parser.CodeParser object at 0x7fe37d063820>
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/custom/code_parser/code_parser.py", line 285, in get_base_classes
                                 bases = self.execute_and_inspect_classes(self.code)
                                         |    |                           |    -> 'import weaviate\nfrom langchain_community.vectorstores import Weaviate\n\nfrom
                             langflow.base.vectorstores.model import LCVec...
                                         |    |                           -> <langflow.custom.code_parser.code_parser.CodeParser object at 0x7fe37d063820>
                                         |    -> <function CodeParser.execute_and_inspect_classes at 0x7fe3b0c6ce50>
                                         -> <langflow.custom.code_parser.code_parser.CodeParser object at 0x7fe37d063820>
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/custom/code_parser/code_parser.py", line 345, in execute_and_inspect_classes
                                 custom_component_class = eval_custom_component_code(code)
                                                          |                          -> 'import weaviate\nfrom langchain_community.vectorstores import Weaviate\n\nfrom
                             langflow.base.vectorstores.model import LCVec...
                                                          -> <function eval_custom_component_code at 0x7fe3b0c5eb00>
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/custom/eval.py", line 12, in eval_custom_component_code
                                 return validate.create_class(code, class_name)
                                        |        |            |     -> 'WeaviateVectorStoreComponent'
                                        |        |            -> 'import weaviate\nfrom langchain_community.vectorstores import Weaviate\n\nfrom langflow.base.vectorstores.model import
                             LCVec...
                                        |        -> <function create_class at 0x7fe3b0c5f0a0>
                                        -> <module 'langflow.utils.validate' from '/home/langflow/.local/lib/python3.10/site-packages/langflow/utils/validate.py'>
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/utils/validate.py", line 187, in create_class
                                 exec_globals = prepare_global_scope(code, module)
                                                |                    |     -> <ast.Module object at 0x7fe37d06ae60>
                                                |                    -> 'import weaviate\nfrom langchain_community.vectorstores import Weaviate\n\nfrom langflow.base.vectorstores.model
                             import LCVec...
                                                -> <function prepare_global_scope at 0x7fe3b0c5f1c0>
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/utils/validate.py", line 223, in prepare_global_scope
                                 exec_globals = importlib.import_module(alias.name)
                                 |            |     |         |     |       |         |             |     -> 'weaviate'
                                 |            |     |         |     |       |         |             -> <ast.alias object at 0x7fe37d06ae90>
                                 |            |     |         |     |       |         -> <function import_module at 0x7fe3dd6008b0>
                                 |            |     |         |     |       -> <module 'importlib' from '/usr/lib/python3.10/importlib/__init__.py'>
                                 |            |     |         |     -> 'weaviate'
                                 |            |     |         -> <ast.alias object at 0x7fe37d06ae90>
                                 |            |     -> None
                                 |            -> <ast.alias object at 0x7fe37d06ae90>
                                 -> {'__name__': 'langflow.utils.validate', '__doc__': None, '__package__': 'langflow.utils', '__loader__': <_frozen_importlib_ex...
                               File "/usr/lib/python3.10/importlib/__init__.py", line 126, in import_module
                                 return _bootstrap._gcd_import(name, package, level)
                                        |          |           |    |        |        -> 0
                                        |          |           |    |        -> None
                                        |          |           |    -> 0
                                        |          |           -> 'weaviate'
                                        |          -> <function _gcd_import at 0x7fe3dd713400>
                                        -> <module '_frozen_importlib' (frozen)>
                               File "<frozen importlib._bootstrap>", line 1050, in _gcd_import
                               File "<frozen importlib._bootstrap>", line 1027, in _find_and_load
                               File "<frozen importlib._bootstrap>", line 1006, in _find_and_load_unlocked
                               File "<frozen importlib._bootstrap>", line 688, in _load_unlocked
                               File "<frozen importlib._bootstrap_external>", line 883, in exec_module
                               File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
                               File "/home/langflow/.local/lib/python3.10/site-packages/weaviate/__init__.py", line 15, in <module>
                                 from .client import Client, WeaviateAsyncClient, WeaviateClient
                               File "/home/langflow/.local/lib/python3.10/site-packages/weaviate/client.py", line 13, in <module>
                                 from weaviate.backup.backup import _BackupAsync
                               File "/home/langflow/.local/lib/python3.10/site-packages/weaviate/backup/__init__.py", line 7, in <module>
                                 from weaviate.backup.backup import Backup
                               File "/home/langflow/.local/lib/python3.10/site-packages/weaviate/backup/backup.py", line 12, in <module>
                                 from weaviate.connect import Connection, ConnectionV4
                               File "/home/langflow/.local/lib/python3.10/site-packages/weaviate/connect/__init__.py", line 8, in <module>
                                 from .v4 import ConnectionV4
                               File "/home/langflow/.local/lib/python3.10/site-packages/weaviate/connect/v4.py", line 16, in <module>
                                 from grpc_health.v1 import health_pb2  # type: ignore
                               File "/home/langflow/.local/lib/python3.10/site-packages/grpc_health/v1/health_pb2.py", line 12, in <module>
                                 _runtime_version.ValidateProtobufRuntimeVersion(
                                 |                -> <function ValidateProtobufRuntimeVersion at 0x7fe3ac122c20>
                                 -> <module 'google.protobuf.runtime_version' from '/home/langflow/.local/lib/python3.10/site-packages/google/protobuf/runtime_ve...
                               File "/home/langflow/.local/lib/python3.10/site-packages/google/protobuf/runtime_version.py", line 120, in ValidateProtobufRuntimeVersion
                                 _ReportVersionError(
                                 -> <function _ReportVersionError at 0x7fe3ac122b90>
                               File "/home/langflow/.local/lib/python3.10/site-packages/google/protobuf/runtime_version.py", line 50, in _ReportVersionError
                                 raise VersionError(msg)
                                       |            -> 'Detected mismatched Protobuf Gencode/Runtime version suffixes when loading grpc_health/v1/health.proto: gencode 5.28.1 runti...
                                       -> <class 'google.protobuf.runtime_version.VersionError'>

                             google.protobuf.runtime_version.VersionError: Detected mismatched Protobuf Gencode/Runtime version suffixes when loading grpc_health/v1/health.proto:
                             gencode 5.28.1 runtime 5.29.0-rc2. Version suffixes must be the same. See Protobuf version guarantees at
                             https://protobuf.dev/support/cross-version-runtime-guarantee.

                             ╭─────────────────────────────────────────────────────────── Traceback (most recent call last) ────────────────────────────────────────────────────────────╮
                             │ /home/langflow/.local/lib/python3.10/site-packages/langflow/custom/directory_reader/directory_reader.py:314 in abuild_component_menu_list                │
                             │                                                                                                                                                          │
                             │   311 │   │   │                                                                                                                                          │
                             │   312 │   │   │   if validation_result:                                                                                                                  │
                             │   313 │   │   │   │   try:                                                                                                                               │
                             │ ❱ 314 │   │   │   │   │   output_types = await                                                                                                           │
                             │       self.get_output_types_from_code_async(result_content)                                                                                              │
                             │   315 │   │   │   │   except Exception:  # noqa: BLE001                                                                                                  │
                             │   316 │   │   │   │   │   logger.exception("Error while getting output types from code")                                                                 │
                             │   317 │   │   │   │   │   output_types = [component_name_camelcase]                                                                                      │
                             │                                                                                                                                                          │
                             │ /home/langflow/.local/lib/python3.10/site-packages/langflow/custom/directory_reader/directory_reader.py:283 in get_output_types_from_code_async          │
                             │                                                                                                                                                          │
                             │   280 │   │   return True, file_content                                                                                                                  │
                             │   281 │                                                                                                                                                  │
                             │   282 │   async def get_output_types_from_code_async(self, code: str):                                                                                   │
                             │ ❱ 283 │   │   return await asyncio.to_thread(self.get_output_types_from_code, code)                                                                      │
                             │   284 │                                                                                                                                                  │
                             │   285 │   async def abuild_component_menu_list(self, file_paths):                                                                                        │
                             │   286 │   │   response = {"menu": []}                                                                                                                    │
                             │                                                                                                                                                          │
                             │ /usr/lib/python3.10/asyncio/threads.py:25 in to_thread                                                                                                   │
                             │                                                                                                                                                          │
                             │   22 │   loop = events.get_running_loop()                                                                                                                │
                             │   23 │   ctx = contextvars.copy_context()                                                                                                                │
                             │   24 │   func_call = functools.partial(ctx.run, func, *args, **kwargs)                                                                                   │
                             │ ❱ 25 │   return await loop.run_in_executor(None, func_call)                                                                                              │
                             │   26                                                                                                                                                     │
                             │                                                                                                                                                          │
                             │ /usr/lib/python3.10/concurrent/futures/thread.py:58 in run                                                                                               │
                             │                                                                                                                                                          │
                             │    55 │   │   │   return                                                                                                                                 │
                             │    56 │   │                                                                                                                                              │
                             │    57 │   │   try:                                                                                                                                       │
                             │ ❱  58 │   │   │   result = self.fn(*self.args, **self.kwargs)                                                                                            │
                             │    59 │   │   except BaseException as exc:                                                                                                               │
                             │    60 │   │   │   self.future.set_exception(exc)                                                                                                         │
                             │    61 │   │   │   # Break a reference cycle with the exception 'exc'                                                                                     │
                             │                                                                                                                                                          │
                             │ /home/langflow/.local/lib/python3.10/site-packages/langflow/custom/directory_reader/directory_reader.py:340 in get_output_types_from_code                │
                             │                                                                                                                                                          │
                             │   337 │   def get_output_types_from_code(code: str) -> list:                                                                                             │
                             │   338 │   │   """Get the output types from the code."""                                                                                                  │
                             │   339 │   │   custom_component = Component(_code=code)                                                                                                   │
                             │ ❱ 340 │   │   types_list = custom_component._get_function_entrypoint_return_type                                                                         │
                             │   341 │   │                                                                                                                                              │
                             │   342 │   │   # Get the name of types classes                                                                                                            │
                             │   343 │   │   return [type_.__name__ for type_ in types_list if hasattr(type_, "__name__")]                                                              │
                             │                                                                                                                                                          │
                             │ /home/langflow/.local/lib/python3.10/site-packages/langflow/custom/custom_component/custom_component.py:374 in _get_function_entrypoint_return_type      │
                             │                                                                                                                                                          │
                             │   371 │   │   Returns:                                                                                                                                   │
                             │   372 │   │   │   List[Any]: The return type of the function entrypoint.                                                                                 │
                             │   373 │   │   """                                                                                                                                        │
                             │ ❱ 374 │   │   return self.get_method_return_type(self._function_entrypoint_name)                                                                         │
                             │   375 │                                                                                                                                                  │
                             │   376 │   def _extract_return_type(self, return_type: Any) -> list[Any]:                                                                                 │
                             │   377 │   │   return post_process_type(return_type)                                                                                                      │
                             │                                                                                                                                                          │
                             │ /home/langflow/.local/lib/python3.10/site-packages/langflow/custom/custom_component/custom_component.py:301 in get_method_return_type                    │
                             │                                                                                                                                                          │
                             │   298 │   │   return data_objects                                                                                                                        │
                             │   299 │                                                                                                                                                  │
                             │   300 │   def get_method_return_type(self, method_name: str):                                                                                            │
                             │ ❱ 301 │   │   build_method = self.get_method(method_name)                                                                                                │
                             │   302 │   │   if not build_method or not build_method.get("has_return"):                                                                                 │
                             │   303 │   │   │   return []                                                                                                                              │
                             │   304 │   │   return_type = build_method["return_type"]                                                                                                  │
                             │                                                                                                                                                          │
                             │ /home/langflow/.local/lib/python3.10/site-packages/langflow/custom/custom_component/custom_component.py:356 in get_method                                │
                             │                                                                                                                                                          │
                             │   353 │   │   │   return {}                                                                                                                              │
                             │   354 │   │                                                                                                                                              │
                             │   355 │   │   component_classes = [                                                                                                                      │
                             │ ❱ 356 │   │   │   cls for cls in self.tree["classes"] if "Component" in cls["bases"] or                                                                  │
                             │       "CustomComponent" in cls["bases"]                                                                                                                  │
                             │   357 │   │   ]                                                                                                                                          │
                             │   358 │   │   if not component_classes:                                                                                                                  │
                             │   359 │   │   │   return {}                                                                                                                              │
                             │                                                                                                                                                          │
                             │ /home/langflow/.local/lib/python3.10/site-packages/langflow/custom/custom_component/custom_component.py:243 in tree                                      │
                             │                                                                                                                                                          │
                             │   240 │   │   Returns:                                                                                                                                   │
                             │   241 │   │   │   dict: The code tree of the custom component.                                                                                           │
                             │   242 │   │   """                                                                                                                                        │
                             │ ❱ 243 │   │   return self.get_code_tree(self._code or "")                                                                                                │
                             │   244 │                                                                                                                                                  │
                             │   245 │   def to_data(self, data: Any, *, keys: list[str] | None = None, silent_errors: bool =                                                           │
                             │       False) -> list[Data]:                                                                                                                              │
                             │   246 │   │   """Converts input data into a list of Data objects.                                                                                        │
                             │                                                                                                                                                          │
                             │ /home/langflow/.local/lib/python3.10/site-packages/cachetools/__init__.py:814 in wrapper                                                                 │
                             │                                                                                                                                                          │
                             │   811 │   │   │   │   │   return c[k]                                                                                                                    │
                             │   812 │   │   │   │   except KeyError:                                                                                                                   │
                             │   813 │   │   │   │   │   pass  # key not found                                                                                                          │
                             │ ❱ 814 │   │   │   │   v = method(self, *args, **kwargs)                                                                                                  │
                             │   815 │   │   │   │   try:                                                                                                                               │
                             │   816 │   │   │   │   │   c[k] = v                                                                                                                       │
                             │   817 │   │   │   │   except ValueError:                                                                                                                 │
                             │                                                                                                                                                          │
                             │ /home/langflow/.local/lib/python3.10/site-packages/langflow/custom/custom_component/base_component.py:50 in get_code_tree                                │
                             │                                                                                                                                                          │
                             │    47 │   @cachedmethod(cache=operator.attrgetter("cache"))                                                                                              │
                             │    48 │   def get_code_tree(self, code: str):                                                                                                            │
                             │    49 │   │   parser = CodeParser(code)                                                                                                                  │
                             │ ❱  50 │   │   return parser.parse_code()                                                                                                                 │
                             │    51 │                                                                                                                                                  │
                             │    52 │   def get_function(self):                                                                                                                        │
                             │    53 │   │   if not self._code:                                                                                                                         │
                             │                                                                                                                                                          │
                             │ /home/langflow/.local/lib/python3.10/site-packages/langflow/custom/code_parser/code_parser.py:360 in parse_code                                          │
                             │                                                                                                                                                          │
                             │   357 │   │   tree = self.get_tree()                                                                                                                     │
                             │   358 │   │                                                                                                                                              │
                             │   359 │   │   for node in ast.walk(tree):                                                                                                                │
                             │ ❱ 360 │   │   │   self.parse_node(node)                                                                                                                  │
                             │   361 │   │   return self.data                                                                                                                           │
                             │   362                                                                                                                                                    │
                             │                                                                                                                                                          │
                             │ /home/langflow/.local/lib/python3.10/site-packages/langflow/custom/code_parser/code_parser.py:104 in parse_node                                          │
                             │                                                                                                                                                          │
                             │   101 │   def parse_node(self, node: ast.stmt | ast.AST) -> None:                                                                                        │
                             │   102 │   │   """Parses an AST node and updates the data dictionary with the relevant                                                                    │
                             │       information."""                                                                                                                                    │
                             │   103 │   │   if handler := self.handlers.get(type(node)):                                                                                               │
                             │ ❱ 104 │   │   │   handler(node)  # type: ignore[operator]                                                                                                │
                             │   105 │                                                                                                                                                  │
                             │   106 │   def parse_imports(self, node: ast.Import | ast.ImportFrom) -> None:                                                                            │
                             │   107 │   │   """Extracts "imports" from the code, including aliases."""                                                                                 │
                             │                                                                                                                                                          │
                             │ /home/langflow/.local/lib/python3.10/site-packages/langflow/custom/code_parser/code_parser.py:294 in parse_classes                                       │
                             │                                                                                                                                                          │
                             │   291 │                                                                                                                                                  │
                             │   292 │   def parse_classes(self, node: ast.ClassDef) -> None:                                                                                           │
                             │   293 │   │   """Extracts "classes" from the code, including inheritance and init methods."""                                                            │
                             │ ❱ 294 │   │   bases = self.get_base_classes()                                                                                                            │
                             │   295 │   │   nodes = []                                                                                                                                 │
                             │   296 │   │   for base in bases:                                                                                                                         │
                             │   297 │   │   │   if base.__name__ == node.name or base.__name__ in {"CustomComponent",                                                                  │
                             │       "Component", "BaseComponent"}:                                                                                                                     │
                             │                                                                                                                                                          │
                             │ /home/langflow/.local/lib/python3.10/site-packages/langflow/custom/code_parser/code_parser.py:285 in get_base_classes                                    │
                             │                                                                                                                                                          │
                             │   282 │   def get_base_classes(self):                                                                                                                    │
                             │   283 │   │   """Returns the base classes of the custom component class."""                                                                              │
                             │   284 │   │   try:                                                                                                                                       │
                             │ ❱ 285 │   │   │   bases = self.execute_and_inspect_classes(self.code)                                                                                    │
                             │   286 │   │   except Exception:                                                                                                                          │
                             │   287 │   │   │   # If the code cannot be executed, return an empty list                                                                                 │
                             │   288 │   │   │   bases = []                                                                                                                             │
                             │                                                                                                                                                          │
                             │ /home/langflow/.local/lib/python3.10/site-packages/langflow/custom/code_parser/code_parser.py:345 in execute_and_inspect_classes                         │
                             │                                                                                                                                                          │
                             │   342 │   │   self.data["global_vars"].append(global_var)                                                                                                │
                             │   343 │                                                                                                                                                  │
                             │   344 │   def execute_and_inspect_classes(self, code: str):                                                                                              │
                             │ ❱ 345 │   │   custom_component_class = eval_custom_component_code(code)                                                                                  │
                             │   346 │   │   custom_component = custom_component_class(_code=code)                                                                                      │
                             │   347 │   │   dunder_class = custom_component.__class__                                                                                                  │
                             │   348 │   │   # Get the base classes at two levels of inheritance                                                                                        │
                             │                                                                                                                                                          │
                             │ /home/langflow/.local/lib/python3.10/site-packages/langflow/custom/eval.py:12 in eval_custom_component_code                                              │
                             │                                                                                                                                                          │
                             │    9 def eval_custom_component_code(code: str) -> type["CustomComponent"]:                                                                               │
                             │   10 │   """Evaluate custom component code."""                                                                                                           │
                             │   11 │   class_name = validate.extract_class_name(code)                                                                                                  │
                             │ ❱ 12 │   return validate.create_class(code, class_name)                                                                                                  │
                             │   13                                                                                                                                                     │
                             │                                                                                                                                                          │
                             │ /home/langflow/.local/lib/python3.10/site-packages/langflow/utils/validate.py:187 in create_class                                                        │
                             │                                                                                                                                                          │
                             │   184 │   │   "from langflow.custom import CustomComponent",                                                                                             │
                             │   185 │   )                                                                                                                                              │
                             │   186 │   module = ast.parse(code)                                                                                                                       │
                             │ ❱ 187 │   exec_globals = prepare_global_scope(code, module)                                                                                              │
                             │   188 │                                                                                                                                                  │
                             │   189 │   class_code = extract_class_code(module, class_name)                                                                                            │
                             │   190 │   compiled_class = compile_class_code(class_code)                                                                                                │
                             │                                                                                                                                                          │
                             │ /home/langflow/.local/lib/python3.10/site-packages/langflow/utils/validate.py:223 in prepare_global_scope                                                │
                             │                                                                                                                                                          │
                             │   220 │   │   if isinstance(node, ast.Import):                                                                                                           │
                             │   221 │   │   │   for alias in node.names:                                                                                                               │
                             │   222 │   │   │   │   try:                                                                                                                               │
                             │ ❱ 223 │   │   │   │   │   exec_globals[alias.asname or alias.name] =                                                                                     │
                             │       importlib.import_module(alias.name)                                                                                                                │
                             │   224 │   │   │   │   except ModuleNotFoundError as e:                                                                                                   │
                             │   225 │   │   │   │   │   msg = f"Module {alias.name} not found. Please install it and try                                                               │
                             │       again."                                                                                                                                            │
                             │   226 │   │   │   │   │   raise ModuleNotFoundError(msg) from e                                                                                          │
                             │                                                                                                                                                          │
                             │ /usr/lib/python3.10/importlib/__init__.py:126 in import_module                                                                                           │
                             │                                                                                                                                                          │
                             │   123 │   │   │   if character != '.':                                                                                                                   │
                             │   124 │   │   │   │   break                                                                                                                              │
                             │   125 │   │   │   level += 1                                                                                                                             │
                             │ ❱ 126 │   return _bootstrap._gcd_import(name[level:], package, level)                                                                                    │
                             │   127                                                                                                                                                    │
                             │   128                                                                                                                                                    │
                             │   129 _RELOADING = {}                                                                                                                                    │
                             │ in _gcd_import:1050                                                                                                                                      │
                             │ in _find_and_load:1027                                                                                                                                   │
                             │ in _find_and_load_unlocked:1006                                                                                                                          │
                             │ in _load_unlocked:688                                                                                                                                    │
                             │ in exec_module:883                                                                                                                                       │
                             │ in _call_with_frames_removed:241                                                                                                                         │
                             │                                                                                                                                                          │
                             │ /home/langflow/.local/lib/python3.10/site-packages/weaviate/__init__.py:15 in <module>                                                                   │
                             │                                                                                                                                                          │
                             │    12 except PackageNotFoundError:                                                                                                                       │
                             │    13 │   __version__ = "unknown version"                                                                                                                │
                             │    14                                                                                                                                                    │
                             │ ❱  15 from .client import Client, WeaviateAsyncClient, WeaviateClient                                                                                    │
                             │    16 from .collections.batch.client import BatchClient, ClientBatchingContextManager                                                                    │
                             │    17 from .connect.helpers import (                                                                                                                     │
                             │    18 │   connect_to_custom,                                                                                                                             │
                             │                                                                                                                                                          │
                             │ /home/langflow/.local/lib/python3.10/site-packages/weaviate/client.py:13 in <module>                                                                     │
                             │                                                                                                                                                          │
                             │    10 from typing_extensions import deprecated                                                                                                           │
                             │    11                                                                                                                                                    │
                             │    12 from weaviate import syncify                                                                                                                       │
                             │ ❱  13 from weaviate.backup.backup import _BackupAsync                                                                                                    │
                             │    14 from weaviate.backup.sync import _Backup                                                                                                           │
                             │    15 from weaviate.event_loop import _EventLoopSingleton, _EventLoop                                                                                    │
                             │    16 from .auth import AuthCredentials                                                                                                                  │
                             │                                                                                                                                                          │
                             │ /home/langflow/.local/lib/python3.10/site-packages/weaviate/backup/__init__.py:7 in <module>                                                             │
                             │                                                                                                                                                          │
                             │   4                                                                                                                                                      │
                             │   5 __all__ = ["Backup", "BackupStorage"]                                                                                                                │
                             │   6                                                                                                                                                      │
                             │ ❱ 7 from weaviate.backup.backup import Backup                                                                                                            │
                             │   8 from weaviate.backup.backup import BackupStorage                                                                                                     │
                             │   9                                                                                                                                                      │
                             │                                                                                                                                                          │
                             │ /home/langflow/.local/lib/python3.10/site-packages/weaviate/backup/backup.py:12 in <module>                                                              │
                             │                                                                                                                                                          │
                             │     9 from pydantic import BaseModel, Field                                                                                                              │
                             │    10 from requests.exceptions import ConnectionError as RequestsConnectionError                                                                         │
                             │    11                                                                                                                                                    │
                             │ ❱  12 from weaviate.connect import Connection, ConnectionV4                                                                                              │
                             │    13 from weaviate.connect.v4 import _ExpectedStatusCodes                                                                                               │
                             │    14 from weaviate.exceptions import (                                                                                                                  │
                             │    15 │   WeaviateInvalidInputError,                                                                                                                     │
                             │                                                                                                                                                          │
                             │ /home/langflow/.local/lib/python3.10/site-packages/weaviate/connect/__init__.py:8 in <module>                                                            │
                             │                                                                                                                                                          │
                             │    5                                                                                                                                                     │
                             │    6 from .base import ConnectionParams, ProtocolParams                                                                                                  │
                             │    7 from .v3 import Connection                                                                                                                          │
                             │ ❱  8 from .v4 import ConnectionV4                                                                                                                        │
                             │    9                                                                                                                                                     │
                             │   10 __all__ = [                                                                                                                                         │
                             │   11 │   "Connection",                                                                                                                                   │
                             │                                                                                                                                                          │
                             │ /home/langflow/.local/lib/python3.10/site-packages/weaviate/connect/v4.py:16 in <module>                                                                 │
                             │                                                                                                                                                          │
                             │    13 │   OAuth2Client,                                                                                                                                  │
                             │    14 )                                                                                                                                                  │
                             │    15 from grpc.aio import Channel  # type: ignore                                                                                                       │
                             │ ❱  16 from grpc_health.v1 import health_pb2  # type: ignore                                                                                              │
                             │    17                                                                                                                                                    │
                             │    18 # from grpclib.client import Channel                                                                                                               │
                             │    19 from httpx import (                                                                                                                                │
                             │                                                                                                                                                          │
                             │ /home/langflow/.local/lib/python3.10/site-packages/grpc_health/v1/health_pb2.py:12 in <module>                                                           │
                             │                                                                                                                                                          │
                             │    9 from google.protobuf import runtime_version as _runtime_version                                                                                     │
                             │   10 from google.protobuf import symbol_database as _symbol_database                                                                                     │
                             │   11 from google.protobuf.internal import builder as _builder                                                                                            │
                             │ ❱ 12 _runtime_version.ValidateProtobufRuntimeVersion(                                                                                                    │
                             │   13 │   _runtime_version.Domain.PUBLIC,                                                                                                                 │
                             │   14 │   5,                                                                                                                                              │
                             │   15 │   28,                                                                                                                                             │
                             │                                                                                                                                                          │
                             │ /home/langflow/.local/lib/python3.10/site-packages/google/protobuf/runtime_version.py:120 in ValidateProtobufRuntimeVersion                              │
                             │                                                                                                                                                          │
                             │   117 │   )                                                                                                                                              │
                             │   118                                                                                                                                                    │
                             │   119   if gen_suffix != SUFFIX:                                                                                                                         │
                             │ ❱ 120 │   _ReportVersionError(                                                                                                                           │
                             │   121 │   │   'Detected mismatched Protobuf Gencode/Runtime version suffixes when'                                                                       │
                             │   122 │   │   f' loading {location}: gencode {gen_version} runtime {version}.'                                                                           │
                             │   123 │   │   f' Version suffixes must be the same. {error_prompt}'                                                                                      │
                             │                                                                                                                                                          │
                             │ /home/langflow/.local/lib/python3.10/site-packages/google/protobuf/runtime_version.py:50 in _ReportVersionError                                          │
                             │                                                                                                                                                          │
                             │    47                                                                                                                                                    │
                             │    48                                                                                                                                                    │
                             │    49 def _ReportVersionError(msg):                                                                                                                      │
                             │ ❱  50   raise VersionError(msg)                                                                                                                          │
                             │    51                                                                                                                                                    │
                             │    52                                                                                                                                                    │
                             │    53 def ValidateProtobufRuntimeVersion(                                                                                                                │
                             ╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯
                             VersionError: Detected mismatched Protobuf Gencode/Runtime version suffixes when loading grpc_health/v1/health.proto: gencode 5.28.1 runtime 5.29.0-rc2.
                             Version suffixes must be the same. See Protobuf version guarantees at https://protobuf.dev/support/cross-version-runtime-guarantee.
[11/14/24 11:09:19] ERROR    2024-11-14 11:09:19 - ERROR    - directory_reader - Error while getting output types from code                                                               directory_reader.py:316'

@severfire
Copy link
Author

after that, seems like i can't login with password set insite .env file :-/ hmmm

@severfire
Copy link
Author

severfire commented Nov 14, 2024

now i see why...

This will delete all data necessary to fix migrations. Are you sure you want to continue? [y/N]: y
2024-11-14 11:28:19.179 | DEBUG    | langflow.services.manager:_create_service:55 - Create service cache_service
2024-11-14 11:28:19.180 | DEBUG    | langflow.services.manager:_create_service:55 - Create service settings_service
2024-11-14 11:28:19.184 | DEBUG    | langflow.services.settings.base:set_database_url:238 - No database_url provided, trying LANGFLOW_DATABASE_URL env variable
2024-11-14 11:28:19.184 | DEBUG    | langflow.services.settings.base:set_database_url:243 - No database_url env variable, using sqlite database
2024-11-14 11:28:19.184 | DEBUG    | langflow.services.settings.base:set_database_url:262 - Saving database to langflow directory: /home/langflow/.local/lib/python3.10/site-packages/langflow
2024-11-14 11:28:19.184 | DEBUG    | langflow.services.settings.base:set_database_url:285 - Database already exists at /home/langflow/.local/lib/python3.10/site-packages/langflow/langflow.db, using it
2024-11-14 11:28:19.185 | DEBUG    | langflow.services.settings.base:set_components_path:323 - Setting default components path to components_path
2024-11-14 11:28:19.185 | DEBUG    | langflow.services.settings.base:set_components_path:328 - Components path: ['/home/langflow/.local/lib/python3.10/site-packages/langflow/components']
2024-11-14 11:28:19.185 | DEBUG    | langflow.services.settings.base:set_user_agent:193 - Setting user agent to langflow
2024-11-14 11:28:19.188 | DEBUG    | langflow.services.settings.auth:get_secret_key:99 - No secret key provided, generating a random one
2024-11-14 11:28:19.189 | DEBUG    | langflow.services.settings.auth:get_secret_key:103 - Loaded secret key
2024-11-14 11:28:19.189 | DEBUG    | langflow.services.settings.auth:validate_superuser:77 - Resetting superuser password to default value
2024-11-14 11:28:19.189 | DEBUG    | langflow.services.database.utils:initialize_database:16 - Initializing database
2024-11-14 11:28:19.190 | DEBUG    | langflow.services.manager:_create_service:55 - Create service database_service
2024-11-14 11:28:19.201 | INFO     | langflow.services.database.service:on_connection:127 - sqlite connection, setting pragmas: ['PRAGMA synchronous = NORMAL', 'PRAGMA journal_mode = WAL']
2024-11-14 11:28:19.203 | DEBUG    | langflow.services.database.service:create_db_and_tables:323 - Database and tables already exist
2024-11-14 11:28:19.206 | INFO     | langflow.services.database.service:run_migrations:244 - Alembic already initialized
2024-11-14 11:28:19.206 | INFO     | langflow.services.database.service:run_migrations:246 - Running DB migrations in /home/langflow/.local/lib/python3.10/site-packages/langflow/alembic
2024-11-14 11:28:19.211 | INFO     | langflow.services.database.service:on_connection:127 - sqlite connection, setting pragmas: ['PRAGMA synchronous = NORMAL', 'PRAGMA journal_mode = WAL']
2024-11-14 11:28:19.269 | INFO     | langflow.services.database.service:on_connection:127 - sqlite connection, setting pragmas: ['PRAGMA synchronous = NORMAL', 'PRAGMA journal_mode = WAL']
2024-11-14 11:28:19.317 | INFO     | langflow.services.database.service:on_connection:127 - sqlite connection, setting pragmas: ['PRAGMA synchronous = NORMAL', 'PRAGMA journal_mode = WAL']
2024-11-14 11:28:19.364 | DEBUG    | langflow.services.database.utils:initialize_database:57 - Database initialized
2024-11-14 11:28:19.365 | DEBUG    | langflow.services.utils:setup_superuser:67 - AUTO_LOGIN is set to True. Creating default superuser.
2024-11-14 11:28:19.404 | DEBUG    | langflow.services.utils:get_or_create_super_user:50 - Creating default superuser.
2024-11-14 11:28:19.738 | DEBUG    | langflow.services.utils:get_or_create_super_user:62 - Error creating superuser.
Traceback (most recent call last):

  File "/home/langflow/.local/bin/langflow", line 8, in <module>
    sys.exit(main())
    │   │    └ <function main at 0x7f22790d4b80>
    │   └ <built-in function exit>
    └ <module 'sys' (built-in)>
  File "/home/langflow/.local/lib/python3.10/site-packages/langflow/__main__.py", line 598, in main
    app()
    └ <typer.main.Typer object at 0x7f22a455b1c0>
  File "/home/langflow/.local/lib/python3.10/site-packages/typer/main.py", line 325, in __call__
    return get_command(self)(*args, **kwargs)
           │           │      │       └ {}
           │           │      └ ()
           │           └ <typer.main.Typer object at 0x7f22a455b1c0>
           └ <function get_command at 0x7f22a4657250>
  File "/home/langflow/.local/lib/python3.10/site-packages/click/core.py", line 1157, in __call__
    return self.main(*args, **kwargs)
           │    │     │       └ {}
           │    │     └ ()
           │    └ <function TyperGroup.main at 0x7f22a4655a20>
           └ <TyperGroup version-option>
  File "/home/langflow/.local/lib/python3.10/site-packages/typer/core.py", line 728, in main
    return _main(
           └ <function _main at 0x7f22a4654dc0>
  File "/home/langflow/.local/lib/python3.10/site-packages/typer/core.py", line 197, in _main
    rv = self.invoke(ctx)
         │    │      └ <click.core.Context object at 0x7f22a607ffd0>
         │    └ <function MultiCommand.invoke at 0x7f22a56284c0>
         └ <TyperGroup version-option>
  File "/home/langflow/.local/lib/python3.10/site-packages/click/core.py", line 1688, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
           │               │       │       │      └ <click.core.Context object at 0x7f2278f6a560>
           │               │       │       └ <function Command.invoke at 0x7f22a5617f40>
           │               │       └ <TyperCommand migration>
           │               └ <click.core.Context object at 0x7f2278f6a560>
           └ <function MultiCommand.invoke.<locals>._process_result at 0x7f227924bd90>
  File "/home/langflow/.local/lib/python3.10/site-packages/click/core.py", line 1434, in invoke
    return ctx.invoke(self.callback, **ctx.params)
           │   │      │    │           │   └ {'fix': True, 'test': True}
           │   │      │    │           └ <click.core.Context object at 0x7f2278f6a560>
           │   │      │    └ <function migration at 0x7f22790d4ca0>
           │   │      └ <TyperCommand migration>
           │   └ <function Context.invoke at 0x7f22a5616cb0>
           └ <click.core.Context object at 0x7f2278f6a560>
  File "/home/langflow/.local/lib/python3.10/site-packages/click/core.py", line 783, in invoke
    return __callback(*args, **kwargs)
                       │       └ {'fix': True, 'test': True}
                       └ ()
  File "/home/langflow/.local/lib/python3.10/site-packages/typer/main.py", line 707, in wrapper
    return callback(**use_params)
           │          └ {'test': True, 'fix': True}
           └ <function migration at 0x7f22790d4700>
  File "/home/langflow/.local/lib/python3.10/site-packages/langflow/__main__.py", line 497, in migration
    initialize_services(fix_migration=fix)
    │                                 └ True
    └ <function initialize_services at 0x7f228aeb1d80>
  File "/home/langflow/.local/lib/python3.10/site-packages/langflow/services/utils.py", line 165, in initialize_services
    setup_superuser(get_service(ServiceType.SETTINGS_SERVICE), next(get_session()))
    │               │           │           │                       └ <function get_session at 0x7f228bcdbe20>
    │               │           │           └ <ServiceType.SETTINGS_SERVICE: 'settings_service'>
    │               │           └ <enum 'ServiceType'>
    │               └ <function get_service at 0x7f228bcdb400>
    └ <function setup_superuser at 0x7f228aeb1a20>
  File "/home/langflow/.local/lib/python3.10/site-packages/langflow/services/utils.py", line 78, in setup_superuser
    user = get_or_create_super_user(session=session, username=username, password=password, is_default=is_default)
           │                                │                 │                  │                    └ True
           │                                │                 │                  └ 'langflow'
           │                                │                 └ 'langflow'
           │                                └ <sqlmodel.orm.session.Session object at 0x7f2278e3a6e0>
           └ <function get_or_create_super_user at 0x7f228b7d05e0>
> File "/home/langflow/.local/lib/python3.10/site-packages/langflow/services/utils.py", line 54, in get_or_create_super_user
    return create_super_user(username, password, db=session)
           │                 │         │            └ <sqlmodel.orm.session.Session object at 0x7f2278e3a6e0>
           │                 │         └ 'langflow'
           │                 └ 'langflow'
           └ <function create_super_user at 0x7f228aeb1360>
  File "/home/langflow/.local/lib/python3.10/site-packages/langflow/services/auth/utils.py", line 218, in create_super_user
    super_user = User(
                 └ <class 'langflow.services.database.models.user.model.User'>
  File "<string>", line 4, in __init__
  File "/home/langflow/.local/lib/python3.10/site-packages/sqlalchemy/orm/state.py", line 571, in _initialize_instance
    with util.safe_reraise():
         │    └ <class 'sqlalchemy.util.langhelpers.safe_reraise'>
         └ <module 'sqlalchemy.util' from '/home/langflow/.local/lib/python3.10/site-packages/sqlalchemy/util/__init__.py'>
  File "/home/langflow/.local/lib/python3.10/site-packages/sqlalchemy/util/langhelpers.py", line 146, in __exit__
    raise exc_value.with_traceback(exc_tb)
          │         │              └ <traceback object at 0x7f2278d06d40>
          │         └ <method 'with_traceback' of 'BaseException' objects>
          └ ValueError("'validated_data' must be provided if 'call_default_factory' is True.")
  File "/home/langflow/.local/lib/python3.10/site-packages/sqlalchemy/orm/state.py", line 569, in _initialize_instance
    manager.original_init(*mixed[1:], **kwargs)
    │       │              │            └ {'username': 'langflow', 'password': '$2b$12$DEuLSfGto1YTVUSFHbGcW.R23dMFdJlhz/htwgowL52L7YHmvLXpi', 'is_superuser': True, 'i...
    │       │              └ (<sqlalchemy.orm.state.InstanceState object at 0x7f2278e4aaa0>, User())
    │       └ <function SQLModel.__init__ at 0x7f22a30916c0>
    └ <ClassManager of <class 'langflow.services.database.models.user.model.User'> at 7f228be921b0>
  File "/home/langflow/.local/lib/python3.10/site-packages/sqlmodel/main.py", line 723, in __init__
    sqlmodel_init(self=__pydantic_self__, data=data)
    │                  │                       └ {'username': 'langflow', 'password': '$2b$12$DEuLSfGto1YTVUSFHbGcW.R23dMFdJlhz/htwgowL52L7YHmvLXpi', 'is_superuser': True, 'i...
    │                  └ User()
    └ <function sqlmodel_init at 0x7f22a334df30>
  File "/home/langflow/.local/lib/python3.10/site-packages/sqlmodel/_compat.py", line 348, in sqlmodel_init
    sqlmodel_table_construct(
    └ <function sqlmodel_table_construct at 0x7f22a334de10>
  File "/home/langflow/.local/lib/python3.10/site-packages/sqlmodel/_compat.py", line 248, in sqlmodel_table_construct
    defaults[name] = field.get_default(call_default_factory=True)
    │        │       │     └ <function FieldInfo.get_default at 0x7f22a35e1510>
    │        │       └ FieldInfo(annotation=UUID, required=False, default_factory=uuid4)
    │        └ 'id'
    └ {}
  File "/home/langflow/.local/lib/python3.10/site-packages/pydantic/fields.py", line 596, in get_default
    raise ValueError("'validated_data' must be provided if 'call_default_factory' is True.")

ValueError: 'validated_data' must be provided if 'call_default_factory' is True.
2024-11-14 11:28:19.745 | DEBUG    | langflow.services.settings.auth:validate_superuser:77 - Resetting superuser password to default value
2024-11-14 11:28:19.746 | INFO     | langflow.services.database.service:on_connection:127 - sqlite connection, setting pragmas: ['PRAGMA synchronous = NORMAL', 'PRAGMA journal_mode = WAL']

@severfire
Copy link
Author

okay, anyhow, installation yet ignores my admin user and password set in .env hmmm

@severfire severfire changed the title version 1.0.10 fresh reinstall issue version 1.1.00 fresh reinstall issue Nov 14, 2024
@severfire
Copy link
Author

severfire commented Nov 14, 2024

reinstalled again, similar errors. seems 1.1.0 is broken :-(

@severfire
Copy link
Author

severfire commented Nov 14, 2024

another error, after total reinstall

ERROR    2024-11-14 13:43:41 - ERROR    - main - 'validated_data' must be provided if 'call_default_factory' is True.                                                             main.py:117
                             Traceback (most recent call last):

                               File "/usr/lib/python3.10/runpy.py", line 196, in _run_module_as_main
                                 return _run_code(code, main_globals, None,
                                        |         |     -> {'__name__': '__main__', '__doc__': None, '__package__': 'langflow', '__loader__': <_frozen_importlib_external.SourceFileLoad...
                                        |         -> <code object <module> at 0x7fd543a6b940, file "/home/langflow/.local/lib/python3.10/site-packages/langflow/__main__.py", line 1>
                                        -> <function _run_code at 0x7fd543a7d120>
                               File "/usr/lib/python3.10/runpy.py", line 86, in _run_code
                                 exec(code, run_globals)
                                      |     -> {'__name__': '__main__', '__doc__': None, '__package__': 'langflow', '__loader__': <_frozen_importlib_external.SourceFileLoad...
                                      -> <code object <module> at 0x7fd543a6b940, file "/home/langflow/.local/lib/python3.10/site-packages/langflow/__main__.py", line 1>
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/__main__.py", line 603, in <module>
                                 main()
                                 -> <function main at 0x7fd516c08dc0>
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/__main__.py", line 598, in main
                                 app()
                                 -> <typer.main.Typer object at 0x7fd5420cefe0>
                               File "/home/langflow/.local/lib/python3.10/site-packages/typer/main.py", line 325, in __call__
                                 return get_command(self)(*args, **kwargs)
                                        |           |      |       -> {}
                                        |           |      -> ()
                                        |           -> <typer.main.Typer object at 0x7fd5420cefe0>
                                        -> <function get_command at 0x7fd5421c7b50>
                               File "/home/langflow/.local/lib/python3.10/site-packages/click/core.py", line 1157, in __call__
                                 return self.main(*args, **kwargs)
                                        |    |     |       -> {}
                                        |    |     -> ()
                                        |    -> <function TyperGroup.main at 0x7fd5421c6320>
                                        -> <TyperGroup version-option>
                               File "/home/langflow/.local/lib/python3.10/site-packages/typer/core.py", line 728, in main
                                 return _main(
                                        -> <function _main at 0x7fd5421c56c0>
                               File "/home/langflow/.local/lib/python3.10/site-packages/typer/core.py", line 197, in _main
                                 rv = self.invoke(ctx)
                                      |    |      -> <click.core.Context object at 0x7fd516a9b370>
                                      |    -> <function MultiCommand.invoke at 0x7fd54317aa70>
                                      -> <TyperGroup version-option>
                               File "/home/langflow/.local/lib/python3.10/site-packages/click/core.py", line 1688, in invoke
                                 return _process_result(sub_ctx.command.invoke(sub_ctx))
                                        |               |       |       |      -> <click.core.Context object at 0x7fd516a9a350>
                                        |               |       |       -> <function Command.invoke at 0x7fd54317a560>
                                        |               |       -> <TyperCommand run>
                                        |               -> <click.core.Context object at 0x7fd516a9a350>
                                        -> <function MultiCommand.invoke.<locals>._process_result at 0x7fd516cdd990>
                               File "/home/langflow/.local/lib/python3.10/site-packages/click/core.py", line 1434, in invoke
                                 return ctx.invoke(self.callback, **ctx.params)
                                        |   |      |    |           |   -> {'env_file': './.env', 'open_browser': False, 'auto_saving': True, 'host': 'localhost', 'workers': None, 'worker_timeout':
                             No...
                                        |   |      |    |           -> <click.core.Context object at 0x7fd516a9a350>
                                        |   |      |    -> <function run at 0x7fd516c08f70>
                                        |   |      -> <TyperCommand run>
                                        |   -> <function Context.invoke at 0x7fd5431792d0>
                                        -> <click.core.Context object at 0x7fd516a9a350>
                               File "/home/langflow/.local/lib/python3.10/site-packages/click/core.py", line 783, in invoke
                                 return __callback(*args, **kwargs)
                                                    |       -> {'env_file': './.env', 'open_browser': False, 'auto_saving': True, 'host': 'localhost', 'workers': None, 'worker_timeout': No...
                                                    -> ()
                               File "/home/langflow/.local/lib/python3.10/site-packages/typer/main.py", line 707, in wrapper
                                 return callback(**use_params)
                                        |          -> {'host': 'localhost', 'workers': None, 'worker_timeout': None, 'port': None, 'components_path': PosixPath('/home/langflow/.lo...
                                        -> <function run at 0x7fd516c09510>
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/__main__.py", line 218, in run
                                 process = run_on_mac_or_linux(host, port, log_level, options, app)
                                           |                   |     |     |          |        -> <fastapi.applications.FastAPI object at 0x7fd516ac4c10>
                                           |                   |     |     |          -> {'bind': 'localhost:7860', 'workers': 1, 'timeout': 300, 'worker_class':
                             'langflow.server.LangflowUvicornWorker', 'logger_cla...
                                           |                   |     |     -> 'critical'
                                           |                   |     -> 7860
                                           |                   -> 'localhost'
                                           -> <function run_on_mac_or_linux at 0x7fd516c09360>
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/__main__.py", line 254, in run_on_mac_or_linux
                                 webapp_process.start()
                                 |              -> <function BaseProcess.start at 0x7fd5421df400>
                                 -> <Process name='Process-1' parent=109679 started>
                               File "/home/langflow/.local/lib/python3.10/site-packages/multiprocess/process.py", line 121, in start
                                 self._popen = self._Popen(self)
                                 |    |        |    |      -> <Process name='Process-1' parent=109679 started>
                                 |    |        |    -> <staticmethod(<function Process._Popen at 0x7fd5420cb490>)>
                                 |    |        -> <Process name='Process-1' parent=109679 started>
                                 |    -> None
                                 -> <Process name='Process-1' parent=109679 started>
                               File "/home/langflow/.local/lib/python3.10/site-packages/multiprocess/context.py", line 224, in _Popen
                                 return _default_context.get_context().Process._Popen(process_obj)
                                        |                |                            -> <Process name='Process-1' parent=109679 started>
                                        |                -> <function DefaultContext.get_context at 0x7fd5420cb640>
                                        -> <multiprocess.context.DefaultContext object at 0x7fd5421fa1a0>
                               File "/home/langflow/.local/lib/python3.10/site-packages/multiprocess/context.py", line 281, in _Popen
                                 return Popen(process_obj)
                                        |     -> <Process name='Process-1' parent=109679 started>
                                        -> <class 'multiprocess.popen_fork.Popen'>
                               File "/home/langflow/.local/lib/python3.10/site-packages/multiprocess/popen_fork.py", line 19, in __init__
                                 self._launch(process_obj)
                                 |    |       -> <Process name='Process-1' parent=109679 started>
                                 |    -> <function Popen._launch at 0x7fd5160f2b90>
                                 -> <multiprocess.popen_fork.Popen object at 0x7fd515f8bd00>
                               File "/home/langflow/.local/lib/python3.10/site-packages/multiprocess/popen_fork.py", line 71, in _launch
                                 code = process_obj._bootstrap(parent_sentinel=child_r)
                                        |           |                          -> 6
                                        |           -> <function BaseProcess._bootstrap at 0x7fd5421dfd00>
                                        -> <Process name='Process-1' parent=109679 started>
                               File "/home/langflow/.local/lib/python3.10/site-packages/multiprocess/process.py", line 314, in _bootstrap
                                 self.run()
                                 |    -> <function BaseProcess.run at 0x7fd5421df370>
                                 -> <Process name='Process-1' parent=109679 started>
                               File "/home/langflow/.local/lib/python3.10/site-packages/multiprocess/process.py", line 108, in run
                                 self._target(*self._args, **self._kwargs)
                                 |    |        |    |        |    -> {}
                                 |    |        |    |        -> <Process name='Process-1' parent=109679 started>
                                 |    |        |    -> ('localhost', 7860, 'critical', {'bind': 'localhost:7860', 'workers': 1, 'timeout': 300, 'worker_class': 'langflow.server.Lan...
                                 |    |        -> <Process name='Process-1' parent=109679 started>
                                 |    -> <function run_langflow at 0x7fd516c08af0>
                                 -> <Process name='Process-1' parent=109679 started>
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/__main__.py", line 408, in run_langflow
                                 server.run()
                                 |      -> <function BaseApplication.run at 0x7fd53c1153f0>
                                 -> <langflow.server.LangflowApplication object at 0x7fd5421d7910>
                               File "/home/langflow/.local/lib/python3.10/site-packages/gunicorn/app/base.py", line 71, in run
                                 Arbiter(self).run()
                                 |       -> <langflow.server.LangflowApplication object at 0x7fd5421d7910>
                                 -> <class 'gunicorn.arbiter.Arbiter'>
                               File "/home/langflow/.local/lib/python3.10/site-packages/gunicorn/arbiter.py", line 210, in run
                                 self.manage_workers()
                                 |    -> <function Arbiter.manage_workers at 0x7fd516048430>
                                 -> <gunicorn.arbiter.Arbiter object at 0x7fd515fde710>
                               File "/home/langflow/.local/lib/python3.10/site-packages/gunicorn/arbiter.py", line 570, in manage_workers
                                 self.spawn_workers()
                                 |    -> <function Arbiter.spawn_workers at 0x7fd516048550>
                                 -> <gunicorn.arbiter.Arbiter object at 0x7fd515fde710>
                               File "/home/langflow/.local/lib/python3.10/site-packages/gunicorn/arbiter.py", line 641, in spawn_workers
                                 self.spawn_worker()
                                 |    -> <function Arbiter.spawn_worker at 0x7fd5160484c0>
                                 -> <gunicorn.arbiter.Arbiter object at 0x7fd515fde710>
                               File "/home/langflow/.local/lib/python3.10/site-packages/gunicorn/arbiter.py", line 608, in spawn_worker
                                 worker.init_process()
                                 |      -> <function UvicornWorker.init_process at 0x7fd53c1b81f0>
                                 -> <langflow.server.LangflowUvicornWorker object at 0x7fd53c1aa950>
                               File "/home/langflow/.local/lib/python3.10/site-packages/uvicorn/workers.py", line 75, in init_process
                                 super().init_process()
                               File "/home/langflow/.local/lib/python3.10/site-packages/gunicorn/workers/base.py", line 143, in init_process
                                 self.run()
                                 |    -> <function UvicornWorker.run at 0x7fd53c1b8430>
                                 -> <langflow.server.LangflowUvicornWorker object at 0x7fd53c1aa950>
                               File "/home/langflow/.local/lib/python3.10/site-packages/uvicorn/workers.py", line 107, in run
                                 return asyncio.run(self._serve())
                                        |       |   |    -> <function LangflowUvicornWorker._serve at 0x7fd53c1b8550>
                                        |       |   -> <langflow.server.LangflowUvicornWorker object at 0x7fd53c1aa950>
                                        |       -> <function run at 0x7fd543c3a710>
                                        -> <module 'asyncio' from '/usr/lib/python3.10/asyncio/__init__.py'>
                               File "/usr/lib/python3.10/asyncio/runners.py", line 44, in run
                                 return loop.run_until_complete(main)
                                        |    |                  -> <coroutine object LangflowUvicornWorker._serve at 0x7fd53c13e490>
                                        |    -> <function BaseEventLoop.run_until_complete at 0x7fd54322e320>
                                        -> <_UnixSelectorEventLoop running=True closed=False debug=False>
                               File "/usr/lib/python3.10/asyncio/base_events.py", line 636, in run_until_complete
                                 self.run_forever()
                                 |    -> <function BaseEventLoop.run_forever at 0x7fd54322e290>
                                 -> <_UnixSelectorEventLoop running=True closed=False debug=False>
                               File "/usr/lib/python3.10/asyncio/base_events.py", line 603, in run_forever
                                 self._run_once()
                                 |    -> <function BaseEventLoop._run_once at 0x7fd54322fd90>
                                 -> <_UnixSelectorEventLoop running=True closed=False debug=False>
                               File "/usr/lib/python3.10/asyncio/base_events.py", line 1909, in _run_once
                                 handle._run()
                                 |      -> <function Handle._run at 0x7fd543387760>
                                 -> <Handle Task.task_wakeup(<Future finis...y' is True.")>)>
                               File "/usr/lib/python3.10/asyncio/events.py", line 80, in _run
                                 self._context.run(self._callback, *self._args)
                                 |    |            |    |           |    -> <member '_args' of 'Handle' objects>
                                 |    |            |    |           -> <Handle Task.task_wakeup(<Future finis...y' is True.")>)>
                                 |    |            |    -> <member '_callback' of 'Handle' objects>
                                 |    |            -> <Handle Task.task_wakeup(<Future finis...y' is True.")>)>
                                 |    -> <member '_context' of 'Handle' objects>
                                 -> <Handle Task.task_wakeup(<Future finis...y' is True.")>)>
                               File "/home/langflow/.local/lib/python3.10/site-packages/uvicorn/lifespan/on.py", line 86, in main
                                 await app(scope, self.receive, self.send)
                                       |   |      |    |        |    -> <function LifespanOn.send at 0x7fd53bf54040>
                                       |   |      |    |        -> <uvicorn.lifespan.on.LifespanOn object at 0x7fd5423a0400>
                                       |   |      |    -> <function LifespanOn.receive at 0x7fd53bf540d0>
                                       |   |      -> <uvicorn.lifespan.on.LifespanOn object at 0x7fd5423a0400>
                                       |   -> {'type': 'lifespan', 'asgi': {'version': '3.0', 'spec_version': '2.0'}, 'state': {}, 'app': <fastapi.applications.FastAPI obj...
                                       -> <uvicorn.middleware.proxy_headers.ProxyHeadersMiddleware object at 0x7fd542cd0160>
                               File "/home/langflow/.local/lib/python3.10/site-packages/uvicorn/middleware/proxy_headers.py", line 29, in __call__
                                 return await self.app(scope, receive, send)
                                              |    |   |      |        -> <bound method LifespanOn.send of <uvicorn.lifespan.on.LifespanOn object at 0x7fd5423a0400>>
                                              |    |   |      -> <bound method LifespanOn.receive of <uvicorn.lifespan.on.LifespanOn object at 0x7fd5423a0400>>
                                              |    |   -> {'type': 'lifespan', 'asgi': {'version': '3.0', 'spec_version': '2.0'}, 'state': {}, 'app': <fastapi.applications.FastAPI obj...
                                              |    -> <fastapi.applications.FastAPI object at 0x7fd516ac4c10>
                                              -> <uvicorn.middleware.proxy_headers.ProxyHeadersMiddleware object at 0x7fd542cd0160>
                               File "/home/langflow/.local/lib/python3.10/site-packages/fastapi/applications.py", line 1054, in __call__
                                 await super().__call__(scope, receive, send)
                                                        |      |        -> <bound method LifespanOn.send of <uvicorn.lifespan.on.LifespanOn object at 0x7fd5423a0400>>
                                                        |      -> <bound method LifespanOn.receive of <uvicorn.lifespan.on.LifespanOn object at 0x7fd5423a0400>>
                                                        -> {'type': 'lifespan', 'asgi': {'version': '3.0', 'spec_version': '2.0'}, 'state': {}, 'app': <fastapi.applications.FastAPI obj...
                               File "/home/langflow/.local/lib/python3.10/site-packages/starlette/applications.py", line 113, in __call__
                                 await self.middleware_stack(scope, receive, send)
                                       |    |                |      |        -> <bound method LifespanOn.send of <uvicorn.lifespan.on.LifespanOn object at 0x7fd5423a0400>>
                                       |    |                |      -> <bound method LifespanOn.receive of <uvicorn.lifespan.on.LifespanOn object at 0x7fd5423a0400>>
                                       |    |                -> {'type': 'lifespan', 'asgi': {'version': '3.0', 'spec_version': '2.0'}, 'state': {}, 'app': <fastapi.applications.FastAPI obj...
                                       |    -> <starlette.middleware.errors.ServerErrorMiddleware object at 0x7fd53bf48d90>
                                       -> <fastapi.applications.FastAPI object at 0x7fd516ac4c10>
                               File "/home/langflow/.local/lib/python3.10/site-packages/starlette/middleware/errors.py", line 152, in __call__
                                 await self.app(scope, receive, send)
                                       |    |   |      |        -> <bound method LifespanOn.send of <uvicorn.lifespan.on.LifespanOn object at 0x7fd5423a0400>>
                                       |    |   |      -> <bound method LifespanOn.receive of <uvicorn.lifespan.on.LifespanOn object at 0x7fd5423a0400>>
                                       |    |   -> {'type': 'lifespan', 'asgi': {'version': '3.0', 'spec_version': '2.0'}, 'state': {}, 'app': <fastapi.applications.FastAPI obj...
                                       |    -> <opentelemetry.instrumentation.asgi.OpenTelemetryMiddleware object at 0x7fd53bf49060>
                                       -> <starlette.middleware.errors.ServerErrorMiddleware object at 0x7fd53bf48d90>
                               File "/home/langflow/.local/lib/python3.10/site-packages/opentelemetry/instrumentation/asgi/__init__.py", line 681, in __call__
                                 return await self.app(scope, receive, send)
                                              |    |   |      |        -> <bound method LifespanOn.send of <uvicorn.lifespan.on.LifespanOn object at 0x7fd5423a0400>>
                                              |    |   |      -> <bound method LifespanOn.receive of <uvicorn.lifespan.on.LifespanOn object at 0x7fd5423a0400>>
                                              |    |   -> {'type': 'lifespan', 'asgi': {'version': '3.0', 'spec_version': '2.0'}, 'state': {}, 'app': <fastapi.applications.FastAPI obj...
                                              |    -> <starlette.middleware.base.BaseHTTPMiddleware object at 0x7fd53bf490c0>
                                              -> <opentelemetry.instrumentation.asgi.OpenTelemetryMiddleware object at 0x7fd53bf49060>
                               File "/home/langflow/.local/lib/python3.10/site-packages/starlette/middleware/base.py", line 101, in __call__
                                 await self.app(scope, receive, send)
                                       |    |   |      |        -> <bound method LifespanOn.send of <uvicorn.lifespan.on.LifespanOn object at 0x7fd5423a0400>>
                                       |    |   |      -> <bound method LifespanOn.receive of <uvicorn.lifespan.on.LifespanOn object at 0x7fd5423a0400>>
                                       |    |   -> {'type': 'lifespan', 'asgi': {'version': '3.0', 'spec_version': '2.0'}, 'state': {}, 'app': <fastapi.applications.FastAPI obj...
                                       |    -> <starlette.middleware.base.BaseHTTPMiddleware object at 0x7fd53bf49120>
                                       -> <starlette.middleware.base.BaseHTTPMiddleware object at 0x7fd53bf490c0>
                               File "/home/langflow/.local/lib/python3.10/site-packages/starlette/middleware/base.py", line 101, in __call__
                                 await self.app(scope, receive, send)
                                       |    |   |      |        -> <bound method LifespanOn.send of <uvicorn.lifespan.on.LifespanOn object at 0x7fd5423a0400>>
                                       |    |   |      -> <bound method LifespanOn.receive of <uvicorn.lifespan.on.LifespanOn object at 0x7fd5423a0400>>
                                       |    |   -> {'type': 'lifespan', 'asgi': {'version': '3.0', 'spec_version': '2.0'}, 'state': {}, 'app': <fastapi.applications.FastAPI obj...
                                       |    -> <langflow.main.JavaScriptMIMETypeMiddleware object at 0x7fd53bf49150>
                                       -> <starlette.middleware.base.BaseHTTPMiddleware object at 0x7fd53bf49120>
                               File "/home/langflow/.local/lib/python3.10/site-packages/starlette/middleware/base.py", line 101, in __call__
                                 await self.app(scope, receive, send)
                                       |    |   |      |        -> <bound method LifespanOn.send of <uvicorn.lifespan.on.LifespanOn object at 0x7fd5423a0400>>
                                       |    |   |      -> <bound method LifespanOn.receive of <uvicorn.lifespan.on.LifespanOn object at 0x7fd5423a0400>>
                                       |    |   -> {'type': 'lifespan', 'asgi': {'version': '3.0', 'spec_version': '2.0'}, 'state': {}, 'app': <fastapi.applications.FastAPI obj...
                                       |    -> <starlette.middleware.cors.CORSMiddleware object at 0x7fd53bf49360>
                                       -> <langflow.main.JavaScriptMIMETypeMiddleware object at 0x7fd53bf49150>
                               File "/home/langflow/.local/lib/python3.10/site-packages/starlette/middleware/cors.py", line 77, in __call__
                                 await self.app(scope, receive, send)
                                       |    |   |      |        -> <bound method LifespanOn.send of <uvicorn.lifespan.on.LifespanOn object at 0x7fd5423a0400>>
                                       |    |   |      -> <bound method LifespanOn.receive of <uvicorn.lifespan.on.LifespanOn object at 0x7fd5423a0400>>
                                       |    |   -> {'type': 'lifespan', 'asgi': {'version': '3.0', 'spec_version': '2.0'}, 'state': {}, 'app': <fastapi.applications.FastAPI obj...
                                       |    -> <starlette.middleware.exceptions.ExceptionMiddleware object at 0x7fd53bf49180>
                                       -> <starlette.middleware.cors.CORSMiddleware object at 0x7fd53bf49360>
                               File "/home/langflow/.local/lib/python3.10/site-packages/starlette/middleware/exceptions.py", line 48, in __call__
                                 await self.app(scope, receive, send)
                                       |    |   |      |        -> <bound method LifespanOn.send of <uvicorn.lifespan.on.LifespanOn object at 0x7fd5423a0400>>
                                       |    |   |      -> <bound method LifespanOn.receive of <uvicorn.lifespan.on.LifespanOn object at 0x7fd5423a0400>>
                                       |    |   -> {'type': 'lifespan', 'asgi': {'version': '3.0', 'spec_version': '2.0'}, 'state': {}, 'app': <fastapi.applications.FastAPI obj...
                                       |    -> <fastapi.routing.APIRouter object at 0x7fd516ac5960>
                                       -> <starlette.middleware.exceptions.ExceptionMiddleware object at 0x7fd53bf49180>
                               File "/home/langflow/.local/lib/python3.10/site-packages/starlette/routing.py", line 715, in __call__
                                 await self.middleware_stack(scope, receive, send)
                                       |    |                |      |        -> <bound method LifespanOn.send of <uvicorn.lifespan.on.LifespanOn object at 0x7fd5423a0400>>
                                       |    |                |      -> <bound method LifespanOn.receive of <uvicorn.lifespan.on.LifespanOn object at 0x7fd5423a0400>>
                                       |    |                -> {'type': 'lifespan', 'asgi': {'version': '3.0', 'spec_version': '2.0'}, 'state': {}, 'app': <fastapi.applications.FastAPI obj...
                                       |    -> <bound method Router.app of <fastapi.routing.APIRouter object at 0x7fd516ac5960>>
                                       -> <fastapi.routing.APIRouter object at 0x7fd516ac5960>
                               File "/home/langflow/.local/lib/python3.10/site-packages/starlette/routing.py", line 724, in app
                                 await self.lifespan(scope, receive, send)
                                       |    |        |      |        -> <bound method LifespanOn.send of <uvicorn.lifespan.on.LifespanOn object at 0x7fd5423a0400>>
                                       |    |        |      -> <bound method LifespanOn.receive of <uvicorn.lifespan.on.LifespanOn object at 0x7fd5423a0400>>
                                       |    |        -> {'type': 'lifespan', 'asgi': {'version': '3.0', 'spec_version': '2.0'}, 'state': {}, 'app': <fastapi.applications.FastAPI obj...
                                       |    -> <function Router.lifespan at 0x7fd540711360>
                                       -> <fastapi.routing.APIRouter object at 0x7fd516ac5960>
                               File "/home/langflow/.local/lib/python3.10/site-packages/starlette/routing.py", line 693, in lifespan
                                 async with self.lifespan_context(app) as maybe_state:
                                            |    |                -> <fastapi.applications.FastAPI object at 0x7fd516ac4c10>
                                            |    -> <function _merge_lifespan_context.<locals>.merged_lifespan at 0x7fd5160f17e0>
                                            -> <fastapi.routing.APIRouter object at 0x7fd516ac5960>
                               File "/home/langflow/.local/lib/python3.10/site-packages/fastapi/routing.py", line 133, in merged_lifespan
                                 async with original_context(app) as maybe_original_state:
                                            |                -> <fastapi.applications.FastAPI object at 0x7fd516ac4c10>
                                            -> <function _merge_lifespan_context.<locals>.merged_lifespan at 0x7fd5160f1bd0>
                               File "/home/langflow/.local/lib/python3.10/site-packages/fastapi/routing.py", line 133, in merged_lifespan
                                 async with original_context(app) as maybe_original_state:
                                            |                -> <fastapi.applications.FastAPI object at 0x7fd516ac4c10>
                                            -> <function _merge_lifespan_context.<locals>.merged_lifespan at 0x7fd5161a9f30>
                               File "/home/langflow/.local/lib/python3.10/site-packages/fastapi/routing.py", line 133, in merged_lifespan
                                 async with original_context(app) as maybe_original_state:
                                            |                -> <fastapi.applications.FastAPI object at 0x7fd516ac4c10>
                                            -> <function get_lifespan.<locals>.lifespan at 0x7fd516c0a050>
                             > File "/home/langflow/.local/lib/python3.10/site-packages/langflow/main.py", line 107, in lifespan
                                 await asyncio.to_thread(_initialize)
                                       |       |         -> <function get_lifespan.<locals>._initialize at 0x7fd516c09f30>
                                       |       -> <function to_thread at 0x7fd54323ab90>
                                       -> <module 'asyncio' from '/usr/lib/python3.10/asyncio/__init__.py'>
                               File "/usr/lib/python3.10/asyncio/threads.py", line 25, in to_thread
                                 return await loop.run_in_executor(None, func_call)
                                              |    |                     -> functools.partial(<built-in method run of _contextvars.Context object at 0x7fd540a86a00>, <function
                             get_lifespan.<locals>._in...
                                              |    -> <function BaseEventLoop.run_in_executor at 0x7fd54322eb00>
                                              -> <_UnixSelectorEventLoop running=True closed=False debug=False>
                               File "/usr/lib/python3.10/concurrent/futures/thread.py", line 58, in run
                                 result = self.fn(*self.args, **self.kwargs)
                                          |        |            -> None
                                          |        -> None
                                          -> None
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/main.py", line 95, in _initialize
                                 initialize_super_user_if_needed()
                                 -> <function initialize_super_user_if_needed at 0x7fd5170cdcf0>
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/initial_setup/setup.py", line 659, in initialize_super_user_if_needed
                                 super_user = create_super_user(db=session, username=username, password=password)
                                              |                    |                 |                  -> 'langflow'
                                              |                    |                 -> 'langflow'
                                              |                    -> <sqlmodel.orm.session.Session object at 0x7fd53bec1bd0>
                                              -> <function create_super_user at 0x7fd5289a96c0>
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/services/auth/utils.py", line 218, in create_super_user
                                 super_user = User(
                                              -> <class 'langflow.services.database.models.user.model.User'>
                               File "<string>", line 4, in __init__
                               File "/home/langflow/.local/lib/python3.10/site-packages/sqlalchemy/orm/state.py", line 571, in _initialize_instance
                                 with util.safe_reraise():
                                      |    -> <class 'sqlalchemy.util.langhelpers.safe_reraise'>
                                      -> <module 'sqlalchemy.util' from '/home/langflow/.local/lib/python3.10/site-packages/sqlalchemy/util/__init__.py'>
                               File "/home/langflow/.local/lib/python3.10/site-packages/sqlalchemy/util/langhelpers.py", line 146, in __exit__
                                 raise exc_value.with_traceback(exc_tb)
                                       |         |              -> <traceback object at 0x7fd53bc6ffc0>
                                       |         -> <method 'with_traceback' of 'BaseException' objects>
                                       -> ValueError("'validated_data' must be provided if 'call_default_factory' is True.")
                               File "/home/langflow/.local/lib/python3.10/site-packages/sqlalchemy/orm/state.py", line 569, in _initialize_instance
                                 manager.original_init(*mixed[1:], **kwargs)
                                 |       |              |            -> {'username': 'langflow', 'password': '$2b$12$mXTPA7Qkxsi2S3Z5Sb59ROGwOclTQeVkoRTHM9.OGwnwAjl0VapPO', 'is_superuser': True,
                             'i...
                                 |       |              -> (<sqlalchemy.orm.state.InstanceState object at 0x7fd53bd959c0>, User())
                                 |       -> <function SQLModel.__init__ at 0x7fd540c01fc0>
                                 -> <ClassManager of <class 'langflow.services.database.models.user.model.User'> at 7fd52948a750>
                               File "/home/langflow/.local/lib/python3.10/site-packages/sqlmodel/main.py", line 723, in __init__
                                 sqlmodel_init(self=__pydantic_self__, data=data)
                                 |                  |                       -> {'username': 'langflow', 'password': '$2b$12$mXTPA7Qkxsi2S3Z5Sb59ROGwOclTQeVkoRTHM9.OGwnwAjl0VapPO', 'is_superuser':
                             True, 'i...
                                 |                  -> User()
                                 -> <function sqlmodel_init at 0x7fd540ebe830>
                               File "/home/langflow/.local/lib/python3.10/site-packages/sqlmodel/_compat.py", line 348, in sqlmodel_init
                                 sqlmodel_table_construct(
                                 -> <function sqlmodel_table_construct at 0x7fd540ebe710>
                               File "/home/langflow/.local/lib/python3.10/site-packages/sqlmodel/_compat.py", line 248, in sqlmodel_table_construct
                                 defaults = field.get_default(call_default_factory=True)
                                 |        |       |     -> <function FieldInfo.get_default at 0x7fd54114de10>
                                 |        |       -> FieldInfo(annotation=UUID, required=False, default_factory=uuid4)
                                 |        -> 'id'
                                 -> {}
                               File "/home/langflow/.local/lib/python3.10/site-packages/pydantic/fields.py", line 596, in get_default
                                 raise ValueError("'validated_data' must be provided if 'call_default_factory' is True.")

@severfire
Copy link
Author

severfire commented Nov 14, 2024 via email

@italojohnny
Copy link
Member

italojohnny commented Nov 14, 2024

Right! I'm trying to reproduce the issue!

@severfire
Copy link
Author

severfire commented Nov 14, 2024 via email

@greenmotion
Copy link

greenmotion commented Nov 14, 2024

I upgraded from 1.0.19Post 2 to 1.1.0 and got thousands of lines of stack trace logs flooding my screen. I can't keep up with the errors and langflow never successfully launches:

[11/14/24 11:47:19] ERROR    2024-11-14 11:47:19 - ERROR    - utils  utils.py:27
                             - Error creating DB and tables
                             Traceback (most recent call last):
                             python[251520]:
                               File
                             "/usr/lib/python3.12/threading.py",
                             line 1030, in _bootstrap
                                 self._bootstrap_inner()
                                 |    -> <function
                             Thread._bootstrap_inner at
                             0x7517dcdaede0>
                                 -> <Thread(asyncio_0, started
                             128742099781312)>
                               File
                             "/usr/lib/python3.12/threading.py",
                             line 1073, in _bootstrap_inner
                                 self.run()
                                 |    -> <function Thread.run at
                             0x7517dcdaeac0>
                                 -> <Thread(asyncio_0, started
                             128742099781312)>
                               File
                             "/usr/lib/python3.12/threading.py",
                             line 1010, in run
                                 self._target(*self._args,
                             **self._kwargs)
                                 |    |        |    |        |    ->
                             {}
                                 |    |        |    |        ->
                             <Thread(asyncio_0, started
                             128742099781312)>
                                 |    |        |    -> (<weakref at
                             0x7517d43e8220; to 'ThreadPoolExecutor'
                             at 0x7517d45b6750>, <_queue.SimpleQueue
                             object at 0x7517d43e88b0>, None,...
                                 |    |        -> <Thread(asyncio_0,
                             started 128742099781312)>
                                 |    -> <function _worker at
                             0x7517d94c3740>
                                 -> <Thread(asyncio_0, started
                             128742099781312)>
                               File
                             "/usr/lib/python3.12/concurrent/futures
                             /thread.py", line 92, in _worker
                                 work_item.run()
                                 |         -> <function
                             _WorkItem.run at 0x7517d94c3880>
                                 ->
                             <concurrent.futures.thread._WorkItem
                             object at 0x7517d43d98b0>
                               File
                             "/usr/lib/python3.12/concurrent/futures
                             /thread.py", line 58, in run
                                 result = self.fn(*self.args,
                             **self.kwargs)
                                          |    |   |    |       |
                             -> {}
                                          |    |   |    |       ->
                             <concurrent.futures.thread._WorkItem
                             object at 0x7517d43d98b0>
                                          |    |   |    -> ()
                                          |    |   ->
                             <concurrent.futures.thread._WorkItem
                             object at 0x7517d43d98b0>
                                          |    ->
                             functools.partial(<built-in method run
                             of _contextvars.Context object at
                             0x7517d9814080>, <function
                             get_lifespan.<locals>._in...
                                          ->
                             <concurrent.futures.thread._WorkItem
                             object at 0x7517d43d98b0>
                               File
                             "/apps/langflow/lib/python3.1
                             2/site-packages/langflow/main.py", line
                             93, in _initialize
                                 initialize_services(fix_migration=f
                             ix_migration)
                                 |
                             -> False
                                 -> <function initialize_services at
                             0x7517b6fa53a0>
                               File
                             "/apps/langflow/lib/python3.1
                             2/site-packages/langflow/services/utils
                             .py", line 164, in initialize_services
                                 initialize_database(fix_migration=f
                             ix_migration)
                                 |
                             -> False
                                 -> <function initialize_database at
                             0x7517c37d60c0>
                             > File
                             "/apps/langflow/lib/python3.1
                             2/site-packages/langflow/services/datab
                             ase/utils.py", line 21, in
                             initialize_database
                                 database_service.create_db_and_tabl
                             es()
                                 |                -> <function
                             DatabaseService.create_db_and_tables at
                             0x7517b6fa5e40>
                                 ->
                             <langflow.services.database.service.Dat
                             abaseService object at 0x75172f1abe60>
                               File
                             "/apps/langflow/lib/python3.1
                             2/site-packages/langflow/services/datab
                             ase/service.py", line 318, in
                             create_db_and_tables
                                 inspector = inspect(self.engine)
                                             |       |    ->
                             Engine(postgresql://langflow:***@localh
                             ost:5432/langflow)
                                             |       ->
                             <langflow.services.database.service.Dat
                             abaseService object at 0x75172f1abe60>
                                             -> <function inspect at
                             0x7517dad8fce0>
                               File
                             "/apps/langflow/lib/python3.1
                             2/site-packages/sqlalchemy/inspection.p
                             y", line 140, in inspect
                                 ret = reg(subject)
                                       |   ->
                             Engine(postgresql://langflow:***@localh
                             ost:5432/langflow)
                                       -> <function
                             Inspector._engine_insp at
                             0x7517da51b2e0>
                               File
                             "/apps/langflow/lib/python3.1
                             2/site-packages/sqlalchemy/engine/refle
                             ction.py", line 312, in _engine_insp
                                 return
                             Inspector._construct(Inspector._init_en
                             gine, bind)
                                        |         |          |
                             |             ->
                             Engine(postgresql://langflow:***@localh
                             ost:5432/langflow)
                                        |         |          |
                             -> <function Inspector._init_engine at
                             0x7517da51af20>
                                        |         |          ->
                             <class
                             'sqlalchemy.engine.reflection.Inspector
                             '>
                                        |         ->
                             <classmethod(<function
                             Inspector._construct at
                             0x7517da51ab60>)>
                                        -> <class
                             'sqlalchemy.engine.reflection.Inspector
                             '>
                               File
                             "/apps/langflow/lib/python3.1
                             2/site-packages/sqlalchemy/engine/refle
                             ction.py", line 245, in _construct
                                 init(self, bind)
                                 |    |     ->
                             Engine(postgresql://langflow:***@localh
                             ost:5432/langflow)
                                 |    ->
                             <sqlalchemy.dialects.postgresql.base.PG
                             Inspector object at 0x7517d99e0f20>
                                 -> <function Inspector._init_engine
                             at 0x7517da51af20>
                               File
                             "/apps/langflow/lib/python3.1
                             2/site-packages/sqlalchemy/engine/refle
                             ction.py", line 256, in _init_engine
                                 engine.connect().close()
                                 |      -> <function Engine.connect
                             at 0x7517da694180>
                                 ->
                             Engine(postgresql://langflow:***@localh
                             ost:5432/langflow)
                               File
                             "/apps/langflow/lib/python3.1
                             2/site-packages/sqlalchemy/engine/base.
                             py", line 3278, in connect
                                 return self._connection_cls(self)
                                        |    |               ->
                             Engine(postgresql://langflow:***@localh
                             ost:5432/langflow)
                                        |    -> <class
                             'sqlalchemy.engine.base.Connection'>
                                        ->
                             Engine(postgresql://langflow:***@localh
                             ost:5432/langflow)
                               File
                             "/apps/langflow/lib/python3.1
                             2/site-packages/sqlalchemy/engine/base.
                             py", line 146, in __init__
                                 self._dbapi_connection =
                             engine.raw_connection()
                                 |                        |      ->
                             <function Engine.raw_connection at
                             0x7517da694220>
                                 |                        ->
                             Engine(postgresql://langflow:***@localh
                             ost:5432/langflow)
                                 ->
                             <sqlalchemy.engine.base.Connection
                             object at 0x7517d43d9dc0>
                               File
                             "/apps/langflow/lib/python3.1
                             2/site-packages/sqlalchemy/engine/base.

@severfire
Copy link
Author

severfire commented Nov 15, 2024

Yes, i reinstalled it again, and now I langflow even can't start, giving errors. so it is easier to see
image
image
image

ERROR    2024-11-15 11:54:35 - ERROR    - service - Error stopping tracing serviceTraceback (most recent call last):
         service.py:162

                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/main.py", line 107, in lifespan
                                 await asyncio.to_thread(_initialize)
                                       |       |         -> <function get_lifespan.<locals>._initialize at 0x7f4a6e315fc0>
                                       |       -> <function to_thread at 0x7f4a9a826b90>
                                       -> <module 'asyncio' from '/usr/lib/python3.10/asyncio/__init__.py'>
                               File "/usr/lib/python3.10/asyncio/threads.py", line 25, in to_thread
                                 return await loop.run_in_executor(None, func_call)
                                              |    |                     -> functools.partial(<built-in method run of _contextvars.Context object at 0x7f4a98042900>, <function
                             get_lifespan.<locals>._in...
                                              |    -> <function BaseEventLoop.run_in_executor at 0x7f4a9a81ab00>
                                              -> <_UnixSelectorEventLoop running=True closed=False debug=False>
                               File "/usr/lib/python3.10/concurrent/futures/thread.py", line 58, in run
                                 result = self.fn(*self.args, **self.kwargs)
                                          |        |            -> None
                                          |        -> None
                                          -> None
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/main.py", line 95, in _initialize
                                 initialize_super_user_if_needed()
                                 -> <function initialize_super_user_if_needed at 0x7f4a6e6f1cf0>
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/initial_setup/setup.py", line 659, in initialize_super_user_if_needed
                                 super_user = create_super_user(db=session, username=username, password=password)
                                              |                    |                 |                  -> 'langflow'
                                              |                    |                 -> 'langflow'
                                              |                    -> <sqlmodel.orm.session.Session object at 0x7f4a93435480>
                                              -> <function create_super_user at 0x7f4a7fff56c0>
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/services/auth/utils.py", line 218, in create_super_user
                                 super_user = User(
                                              -> <class 'langflow.services.database.models.user.model.User'>
                               File "<string>", line 4, in __init__
                               File "/home/langflow/.local/lib/python3.10/site-packages/sqlalchemy/orm/state.py", line 571, in _initialize_instance
                                 with util.safe_reraise():
                                      |    -> <class 'sqlalchemy.util.langhelpers.safe_reraise'>
                                      -> <module 'sqlalchemy.util' from '/home/langflow/.local/lib/python3.10/site-packages/sqlalchemy/util/__init__.py'>
                               File "/home/langflow/.local/lib/python3.10/site-packages/sqlalchemy/util/langhelpers.py", line 146, in __exit__
                                 raise exc_value.with_traceback(exc_tb)
                                       |         |              -> <traceback object at 0x7f4a9344b880>
                                       |         -> <method 'with_traceback' of 'BaseException' objects>
                                       -> ValueError("'validated_data' must be provided if 'call_default_factory' is True.")
                               File "/home/langflow/.local/lib/python3.10/site-packages/sqlalchemy/orm/state.py", line 569, in _initialize_instance
                                 manager.original_init(*mixed[1:], **kwargs)
                                 |       |              |            -> {'username': 'langflow', 'password': '$2b$12$gBZxP4.jFwioKGu0XcT2he..WA.F8RN.86MuQkhrbCxgGA.SVIYD.', 'is_superuser': True,
                             'i...
                                 |       |              -> (<sqlalchemy.orm.state.InstanceState object at 0x7f4a9357f460>, User())
                                 |       -> <function SQLModel.__init__ at 0x7f4a98219fc0>
                                 -> <ClassManager of <class 'langflow.services.database.models.user.model.User'> at 7f4a808dba60>
                               File "/home/langflow/.local/lib/python3.10/site-packages/sqlmodel/main.py", line 723, in __init__
                                 sqlmodel_init(self=__pydantic_self__, data=data)
                                 |                  |                       -> {'username': 'langflow', 'password': '$2b$12$gBZxP4.jFwioKGu0XcT2he..WA.F8RN.86MuQkhrbCxgGA.SVIYD.',
                             'is_superuser': True, 'i...
                                 |                  -> User()
                                 -> <function sqlmodel_init at 0x7f4a982d2830>
                               File "/home/langflow/.local/lib/python3.10/site-packages/sqlmodel/_compat.py", line 348, in sqlmodel_init
                                 sqlmodel_table_construct(
                                 -> <function sqlmodel_table_construct at 0x7f4a982d2710>
                               File "/home/langflow/.local/lib/python3.10/site-packages/sqlmodel/_compat.py", line 248, in sqlmodel_table_construct
                                 defaults = field.get_default(call_default_factory=True)
                                 |        |       |     -> <function FieldInfo.get_default at 0x7f4a98751e10>
                                 |        |       -> FieldInfo(annotation=UUID, required=False, default_factory=uuid4)
                                 |        -> 'id'
                                 -> {}
                               File "/home/langflow/.local/lib/python3.10/site-packages/pydantic/fields.py", line 596, in get_default
                                 raise ValueError("'validated_data' must be provided if 'call_default_factory' is True.")

                             ValueError: 'validated_data' must be provided if 'call_default_factory' is True.


                             During handling of the above exception, another exception occurred:



                             Traceback (most recent call last):

                               File "/usr/lib/python3.10/runpy.py", line 196, in _run_module_as_main
                                 return _run_code(code, main_globals, None,
                                        |         |     -> {'__name__': '__main__', '__doc__': None, '__package__': 'langflow', '__loader__': <_frozen_importlib_external.SourceFileLoad...
                                        |         -> <code object <module> at 0x7f4a9b04f940, file "/home/langflow/.local/lib/python3.10/site-packages/langflow/__main__.py", line 1>
                                        -> <function _run_code at 0x7f4a9b061120>
                               File "/usr/lib/python3.10/runpy.py", line 86, in _run_code
                                 exec(code, run_globals)
                                      |     -> {'__name__': '__main__', '__doc__': None, '__package__': 'langflow', '__loader__': <_frozen_importlib_external.SourceFileLoad...
                                      -> <code object <module> at 0x7f4a9b04f940, file "/home/langflow/.local/lib/python3.10/site-packages/langflow/__main__.py", line 1>
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/__main__.py", line 603, in <module>
                                 main()
                                 -> <function main at 0x7f4a6e048dc0>
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/__main__.py", line 598, in main
                                 app()
                                 -> <typer.main.Typer object at 0x7f4a996cef80>
                               File "/home/langflow/.local/lib/python3.10/site-packages/typer/main.py", line 325, in __call__
                                 return get_command(self)(*args, **kwargs)
                                        |           |      |       -> {}
                                        |           |      -> ()
                                        |           -> <typer.main.Typer object at 0x7f4a996cef80>
                                        -> <function get_command at 0x7f4a997c7b50>
                               File "/home/langflow/.local/lib/python3.10/site-packages/click/core.py", line 1157, in __call__
                                 return self.main(*args, **kwargs)
                                        |    |     |       -> {}
                                        |    |     -> ()
                                        |    -> <function TyperGroup.main at 0x7f4a997c6320>
                                        -> <TyperGroup version-option>
                               File "/home/langflow/.local/lib/python3.10/site-packages/typer/core.py", line 728, in main
                                 return _main(
                                        -> <function _main at 0x7f4a997c56c0>
                               File "/home/langflow/.local/lib/python3.10/site-packages/typer/core.py", line 197, in _main
                                 rv = self.invoke(ctx)
                                      |    |      -> <click.core.Context object at 0x7f4a6e0db340>
                                      |    -> <function MultiCommand.invoke at 0x7f4a9a766a70>
                                      -> <TyperGroup version-option>
                               File "/home/langflow/.local/lib/python3.10/site-packages/click/core.py", line 1688, in invoke
                                 return _process_result(sub_ctx.command.invoke(sub_ctx))
                                        |               |       |       |      -> <click.core.Context object at 0x7f4a6e0da4d0>
                                        |               |       |       -> <function Command.invoke at 0x7f4a9a766560>
                                        |               |       -> <TyperCommand run>
                                        |               -> <click.core.Context object at 0x7f4a6e0da4d0>
                                        -> <function MultiCommand.invoke.<locals>._process_result at 0x7f4a6e315990>
                               File "/home/langflow/.local/lib/python3.10/site-packages/click/core.py", line 1434, in invoke
                                 return ctx.invoke(self.callback, **ctx.params)
                                        |   |      |    |           |   -> {'host': None, 'workers': None, 'worker_timeout': None, 'port': None, 'components_path':
                             PosixPath('/home/langflow/.local/lib...
                                        |   |      |    |           -> <click.core.Context object at 0x7f4a6e0da4d0>
                                        |   |      |    -> <function run at 0x7f4a6e048f70>
                                        |   |      -> <TyperCommand run>
                                        |   -> <function Context.invoke at 0x7f4a9a7652d0>
                                        -> <click.core.Context object at 0x7f4a6e0da4d0>
                               File "/home/langflow/.local/lib/python3.10/site-packages/click/core.py", line 783, in invoke
                                 return __callback(*args, **kwargs)
                                                    |       -> {'host': None, 'workers': None, 'worker_timeout': None, 'port': None, 'components_path': PosixPath('/home/langflow/.local/lib...
                                                    -> ()
                               File "/home/langflow/.local/lib/python3.10/site-packages/typer/main.py", line 707, in wrapper
                                 return callback(**use_params)
                                        |          -> {'host': None, 'workers': None, 'worker_timeout': None, 'port': None, 'components_path': PosixPath('/home/langflow/.local/lib...
                                        -> <function run at 0x7f4a6e049510>
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/__main__.py", line 218, in run
                                 process = run_on_mac_or_linux(host, port, log_level, options, app)
                                           |                   |     |     |          |        -> <fastapi.applications.FastAPI object at 0x7f4a6e100d90>
                                           |                   |     |     |          -> {'bind': '127.0.0.1:7860', 'workers': 1, 'timeout': 300, 'worker_class':
                             'langflow.server.LangflowUvicornWorker', 'logger_cla...
                                           |                   |     |     -> 'critical'
                                           |                   |     -> 7860
                                           |                   -> '127.0.0.1'
                                           -> <function run_on_mac_or_linux at 0x7f4a6e049360>
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/__main__.py", line 254, in run_on_mac_or_linux
                                 webapp_process.start()
                                 |              -> <function BaseProcess.start at 0x7f4a997df400>
                                 -> <Process name='Process-1' parent=625335 started>
                               File "/home/langflow/.local/lib/python3.10/site-packages/multiprocess/process.py", line 121, in start
                                 self._popen = self._Popen(self)
                                 |    |        |    |      -> <Process name='Process-1' parent=625335 started>
                                 |    |        |    -> <staticmethod(<function Process._Popen at 0x7f4a996cb490>)>
                                 |    |        -> <Process name='Process-1' parent=625335 started>
                                 |    -> None
                                 -> <Process name='Process-1' parent=625335 started>
                               File "/home/langflow/.local/lib/python3.10/site-packages/multiprocess/context.py", line 224, in _Popen
                                 return _default_context.get_context().Process._Popen(process_obj)
                                        |                |                            -> <Process name='Process-1' parent=625335 started>
                                        |                -> <function DefaultContext.get_context at 0x7f4a996cb640>
                                        -> <multiprocess.context.DefaultContext object at 0x7f4a997fa140>
                               File "/home/langflow/.local/lib/python3.10/site-packages/multiprocess/context.py", line 281, in _Popen
                                 return Popen(process_obj)
                                        |     -> <Process name='Process-1' parent=625335 started>
                                        -> <class 'multiprocess.popen_fork.Popen'>
                               File "/home/langflow/.local/lib/python3.10/site-packages/multiprocess/popen_fork.py", line 19, in __init__
                                 self._launch(process_obj)
                                 |    |       -> <Process name='Process-1' parent=625335 started>
                                 |    -> <function Popen._launch at 0x7f4a6d73a710>
                                 -> <multiprocess.popen_fork.Popen object at 0x7f4a6d5e7f10>
                               File "/home/langflow/.local/lib/python3.10/site-packages/multiprocess/popen_fork.py", line 71, in _launch
                                 code = process_obj._bootstrap(parent_sentinel=child_r)
                                        |           |                          -> 6
                                        |           -> <function BaseProcess._bootstrap at 0x7f4a997dfd00>
                                        -> <Process name='Process-1' parent=625335 started>
                               File "/home/langflow/.local/lib/python3.10/site-packages/multiprocess/process.py", line 314, in _bootstrap
                                 self.run()
                                 |    -> <function BaseProcess.run at 0x7f4a997df370>
                                 -> <Process name='Process-1' parent=625335 started>
                               File "/home/langflow/.local/lib/python3.10/site-packages/multiprocess/process.py", line 108, in run
                                 self._target(*self._args, **self._kwargs)
                                 |    |        |    |        |    -> {}
                                 |    |        |    |        -> <Process name='Process-1' parent=625335 started>
                                 |    |        |    -> ('127.0.0.1', 7860, 'critical', {'bind': '127.0.0.1:7860', 'workers': 1, 'timeout': 300, 'worker_class': 'langflow.server.Lan...
                                 |    |        -> <Process name='Process-1' parent=625335 started>
                                 |    -> <function run_langflow at 0x7f4a6e048af0>
                                 -> <Process name='Process-1' parent=625335 started>
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/__main__.py", line 408, in run_langflow
                                 server.run()
                                 |      -> <function BaseApplication.run at 0x7f4a6d4c4f70>
                                 -> <langflow.server.LangflowApplication object at 0x7f4a997d78b0>
                               File "/home/langflow/.local/lib/python3.10/site-packages/gunicorn/app/base.py", line 71, in run
                                 Arbiter(self).run()
                                 |       -> <langflow.server.LangflowApplication object at 0x7f4a997d78b0>
                                 -> <class 'gunicorn.arbiter.Arbiter'>
                               File "/home/langflow/.local/lib/python3.10/site-packages/gunicorn/arbiter.py", line 210, in run
                                 self.manage_workers()
                                 |    -> <function Arbiter.manage_workers at 0x7f4a6d483f40>
                                 -> <gunicorn.arbiter.Arbiter object at 0x7f4a6d626470>
                               File "/home/langflow/.local/lib/python3.10/site-packages/gunicorn/arbiter.py", line 570, in manage_workers
                                 self.spawn_workers()
                                 |    -> <function Arbiter.spawn_workers at 0x7f4a6d4900d0>
                                 -> <gunicorn.arbiter.Arbiter object at 0x7f4a6d626470>
                               File "/home/langflow/.local/lib/python3.10/site-packages/gunicorn/arbiter.py", line 641, in spawn_workers
                                 self.spawn_worker()
                                 |    -> <function Arbiter.spawn_worker at 0x7f4a6d490040>
                                 -> <gunicorn.arbiter.Arbiter object at 0x7f4a6d626470>
                               File "/home/langflow/.local/lib/python3.10/site-packages/gunicorn/arbiter.py", line 608, in spawn_worker
                                 worker.init_process()
                                 |      -> <function UvicornWorker.init_process at 0x7f4a6d543d00>
                                 -> <langflow.server.LangflowUvicornWorker object at 0x7f4a6e100370>
                               File "/home/langflow/.local/lib/python3.10/site-packages/uvicorn/workers.py", line 75, in init_process
                                 super().init_process()
                               File "/home/langflow/.local/lib/python3.10/site-packages/gunicorn/workers/base.py", line 143, in init_process
                                 self.run()
                                 |    -> <function UvicornWorker.run at 0x7f4a6d543f40>
                                 -> <langflow.server.LangflowUvicornWorker object at 0x7f4a6e100370>
                               File "/home/langflow/.local/lib/python3.10/site-packages/uvicorn/workers.py", line 107, in run
                                 return asyncio.run(self._serve())
                                        |       |   |    -> <function LangflowUvicornWorker._serve at 0x7f4a936680d0>
                                        |       |   -> <langflow.server.LangflowUvicornWorker object at 0x7f4a6e100370>
                                        |       -> <function run at 0x7f4a9b21e710>
                                        -> <module 'asyncio' from '/usr/lib/python3.10/asyncio/__init__.py'>
                               File "/usr/lib/python3.10/asyncio/runners.py", line 44, in run
                                 return loop.run_until_complete(main)
                                        |    |                  -> <coroutine object LangflowUvicornWorker._serve at 0x7f4a6d4ee3b0>
                                        |    -> <function BaseEventLoop.run_until_complete at 0x7f4a9a81a320>
                                        -> <_UnixSelectorEventLoop running=True closed=False debug=False>
                               File "/usr/lib/python3.10/asyncio/base_events.py", line 636, in run_until_complete
                                 self.run_forever()
                                 |    -> <function BaseEventLoop.run_forever at 0x7f4a9a81a290>
                                 -> <_UnixSelectorEventLoop running=True closed=False debug=False>
                               File "/usr/lib/python3.10/asyncio/base_events.py", line 603, in run_forever
                                 self._run_once()
                                 |    -> <function BaseEventLoop._run_once at 0x7f4a9a81bd90>
                                 -> <_UnixSelectorEventLoop running=True closed=False debug=False>
                               File "/usr/lib/python3.10/asyncio/base_events.py", line 1909, in _run_once
                                 handle._run()
                                 |      -> <function Handle._run at 0x7f4a9a973760>
                                 -> <Handle Task.task_wakeup(<Future finished result=None>)>
                               File "/usr/lib/python3.10/asyncio/events.py", line 80, in _run
                                 self._context.run(self._callback, *self._args)
                                 |    |            |    |           |    -> <member '_args' of 'Handle' objects>
                                 |    |            |    |           -> <Handle Task.task_wakeup(<Future finished result=None>)>
                                 |    |            |    -> <member '_callback' of 'Handle' objects>
                                 |    |            -> <Handle Task.task_wakeup(<Future finished result=None>)>
                                 |    -> <member '_context' of 'Handle' objects>
                                 -> <Handle Task.task_wakeup(<Future finished result=None>)>
                               File "/home/langflow/.local/lib/python3.10/site-packages/uvicorn/lifespan/on.py", line 86, in main
                                 await app(scope, self.receive, self.send)
                                       |   |      |    |        |    -> <function LifespanOn.send at 0x7f4a936ffac0>
                                       |   |      |    |        -> <uvicorn.lifespan.on.LifespanOn object at 0x7f4a984595a0>
                                       |   |      |    -> <function LifespanOn.receive at 0x7f4a936ffb50>
                                       |   |      -> <uvicorn.lifespan.on.LifespanOn object at 0x7f4a984595a0>
                                       |   -> {'type': 'lifespan', 'asgi': {'version': '3.0', 'spec_version': '2.0'}, 'state': {}, 'app': <fastapi.applications.FastAPI obj...
                                       -> <uvicorn.middleware.proxy_headers.ProxyHeadersMiddleware object at 0x7f4a99b13280>
                               File "/home/langflow/.local/lib/python3.10/site-packages/uvicorn/middleware/proxy_headers.py", line 29, in __call__
                                 return await self.app(scope, receive, send)
                                              |    |   |      |        -> <bound method LifespanOn.send of <uvicorn.lifespan.on.LifespanOn object at 0x7f4a984595a0>>
                                              |    |   |      -> <bound method LifespanOn.receive of <uvicorn.lifespan.on.LifespanOn object at 0x7f4a984595a0>>
                                              |    |   -> {'type': 'lifespan', 'asgi': {'version': '3.0', 'spec_version': '2.0'}, 'state': {}, 'app': <fastapi.applications.FastAPI obj...
                                              |    -> <fastapi.applications.FastAPI object at 0x7f4a6e100d90>
                                              -> <uvicorn.middleware.proxy_headers.ProxyHeadersMiddleware object at 0x7f4a99b13280>
                               File "/home/langflow/.local/lib/python3.10/site-packages/fastapi/applications.py", line 1054, in __call__
                                 await super().__call__(scope, receive, send)
                                                        |      |        -> <bound method LifespanOn.send of <uvicorn.lifespan.on.LifespanOn object at 0x7f4a984595a0>>
                                                        |      -> <bound method LifespanOn.receive of <uvicorn.lifespan.on.LifespanOn object at 0x7f4a984595a0>>
                                                        -> {'type': 'lifespan', 'asgi': {'version': '3.0', 'spec_version': '2.0'}, 'state': {}, 'app': <fastapi.applications.FastAPI obj...
                               File "/home/langflow/.local/lib/python3.10/site-packages/starlette/applications.py", line 113, in __call__
                                 await self.middleware_stack(scope, receive, send)
                                       |    |                |      |        -> <bound method LifespanOn.send of <uvicorn.lifespan.on.LifespanOn object at 0x7f4a984595a0>>
                                       |    |                |      -> <bound method LifespanOn.receive of <uvicorn.lifespan.on.LifespanOn object at 0x7f4a984595a0>>
                                       |    |                -> {'type': 'lifespan', 'asgi': {'version': '3.0', 'spec_version': '2.0'}, 'state': {}, 'app': <fastapi.applications.FastAPI obj...
                                       |    -> <starlette.middleware.errors.ServerErrorMiddleware object at 0x7f4a936f8a90>
                                       -> <fastapi.applications.FastAPI object at 0x7f4a6e100d90>
                               File "/home/langflow/.local/lib/python3.10/site-packages/starlette/middleware/errors.py", line 152, in __call__
                                 await self.app(scope, receive, send)
                                       |    |   |      |        -> <bound method LifespanOn.send of <uvicorn.lifespan.on.LifespanOn object at 0x7f4a984595a0>>
                                       |    |   |      -> <bound method LifespanOn.receive of <uvicorn.lifespan.on.LifespanOn object at 0x7f4a984595a0>>
                                       |    |   -> {'type': 'lifespan', 'asgi': {'version': '3.0', 'spec_version': '2.0'}, 'state': {}, 'app': <fastapi.applications.FastAPI obj...
                                       |    -> <opentelemetry.instrumentation.asgi.OpenTelemetryMiddleware object at 0x7f4a936f8d60>
                                       -> <starlette.middleware.errors.ServerErrorMiddleware object at 0x7f4a936f8a90>
                               File "/home/langflow/.local/lib/python3.10/site-packages/opentelemetry/instrumentation/asgi/__init__.py", line 681, in __call__
                                 return await self.app(scope, receive, send)
                                              |    |   |      |        -> <bound method LifespanOn.send of <uvicorn.lifespan.on.LifespanOn object at 0x7f4a984595a0>>
                                              |    |   |      -> <bound method LifespanOn.receive of <uvicorn.lifespan.on.LifespanOn object at 0x7f4a984595a0>>
                                              |    |   -> {'type': 'lifespan', 'asgi': {'version': '3.0', 'spec_version': '2.0'}, 'state': {}, 'app': <fastapi.applications.FastAPI obj...
                                              |    -> <starlette.middleware.base.BaseHTTPMiddleware object at 0x7f4a936f8dc0>
                                              -> <opentelemetry.instrumentation.asgi.OpenTelemetryMiddleware object at 0x7f4a936f8d60>
                               File "/home/langflow/.local/lib/python3.10/site-packages/starlette/middleware/base.py", line 101, in __call__
                                 await self.app(scope, receive, send)
                                       |    |   |      |        -> <bound method LifespanOn.send of <uvicorn.lifespan.on.LifespanOn object at 0x7f4a984595a0>>
                                       |    |   |      -> <bound method LifespanOn.receive of <uvicorn.lifespan.on.LifespanOn object at 0x7f4a984595a0>>
                                       |    |   -> {'type': 'lifespan', 'asgi': {'version': '3.0', 'spec_version': '2.0'}, 'state': {}, 'app': <fastapi.applications.FastAPI obj...
                                       |    -> <starlette.middleware.base.BaseHTTPMiddleware object at 0x7f4a936f8e20>
                                       -> <starlette.middleware.base.BaseHTTPMiddleware object at 0x7f4a936f8dc0>
                               File "/home/langflow/.local/lib/python3.10/site-packages/starlette/middleware/base.py", line 101, in __call__
                                 await self.app(scope, receive, send)
                                       |    |   |      |        -> <bound method LifespanOn.send of <uvicorn.lifespan.on.LifespanOn object at 0x7f4a984595a0>>
                                       |    |   |      -> <bound method LifespanOn.receive of <uvicorn.lifespan.on.LifespanOn object at 0x7f4a984595a0>>
                                       |    |   -> {'type': 'lifespan', 'asgi': {'version': '3.0', 'spec_version': '2.0'}, 'state': {}, 'app': <fastapi.applications.FastAPI obj...
                                       |    -> <langflow.main.JavaScriptMIMETypeMiddleware object at 0x7f4a936f8e80>
                                       -> <starlette.middleware.base.BaseHTTPMiddleware object at 0x7f4a936f8e20>
                               File "/home/langflow/.local/lib/python3.10/site-packages/starlette/middleware/base.py", line 101, in __call__
                                 await self.app(scope, receive, send)
                                       |    |   |      |        -> <bound method LifespanOn.send of <uvicorn.lifespan.on.LifespanOn object at 0x7f4a984595a0>>
                                       |    |   |      -> <bound method LifespanOn.receive of <uvicorn.lifespan.on.LifespanOn object at 0x7f4a984595a0>>
                                       |    |   -> {'type': 'lifespan', 'asgi': {'version': '3.0', 'spec_version': '2.0'}, 'state': {}, 'app': <fastapi.applications.FastAPI obj...
                                       |    -> <starlette.middleware.cors.CORSMiddleware object at 0x7f4a936f8ee0>
                                       -> <langflow.main.JavaScriptMIMETypeMiddleware object at 0x7f4a936f8e80>
                               File "/home/langflow/.local/lib/python3.10/site-packages/starlette/middleware/cors.py", line 77, in __call__
                                 await self.app(scope, receive, send)
                                       |    |   |      |        -> <bound method LifespanOn.send of <uvicorn.lifespan.on.LifespanOn object at 0x7f4a984595a0>>
                                       |    |   |      -> <bound method LifespanOn.receive of <uvicorn.lifespan.on.LifespanOn object at 0x7f4a984595a0>>
                                       |    |   -> {'type': 'lifespan', 'asgi': {'version': '3.0', 'spec_version': '2.0'}, 'state': {}, 'app': <fastapi.applications.FastAPI obj...
                                       |    -> <starlette.middleware.exceptions.ExceptionMiddleware object at 0x7f4a936f9090>
                                       -> <starlette.middleware.cors.CORSMiddleware object at 0x7f4a936f8ee0>
                               File "/home/langflow/.local/lib/python3.10/site-packages/starlette/middleware/exceptions.py", line 48, in __call__
                                 await self.app(scope, receive, send)
                                       |    |   |      |        -> <bound method LifespanOn.send of <uvicorn.lifespan.on.LifespanOn object at 0x7f4a984595a0>>
                                       |    |   |      -> <bound method LifespanOn.receive of <uvicorn.lifespan.on.LifespanOn object at 0x7f4a984595a0>>
                                       |    |   -> {'type': 'lifespan', 'asgi': {'version': '3.0', 'spec_version': '2.0'}, 'state': {}, 'app': <fastapi.applications.FastAPI obj...
                                       |    -> <fastapi.routing.APIRouter object at 0x7f4a6e101660>
                                       -> <starlette.middleware.exceptions.ExceptionMiddleware object at 0x7f4a936f9090>
                               File "/home/langflow/.local/lib/python3.10/site-packages/starlette/routing.py", line 715, in __call__
                                 await self.middleware_stack(scope, receive, send)
                                       |    |                |      |        -> <bound method LifespanOn.send of <uvicorn.lifespan.on.LifespanOn object at 0x7f4a984595a0>>
                                       |    |                |      -> <bound method LifespanOn.receive of <uvicorn.lifespan.on.LifespanOn object at 0x7f4a984595a0>>
                                       |    |                -> {'type': 'lifespan', 'asgi': {'version': '3.0', 'spec_version': '2.0'}, 'state': {}, 'app': <fastapi.applications.FastAPI obj...
                                       |    -> <bound method Router.app of <fastapi.routing.APIRouter object at 0x7f4a6e101660>>
                                       -> <fastapi.routing.APIRouter object at 0x7f4a6e101660>
                               File "/home/langflow/.local/lib/python3.10/site-packages/starlette/routing.py", line 724, in app
                                 await self.lifespan(scope, receive, send)
                                       |    |        |      |        -> <bound method LifespanOn.send of <uvicorn.lifespan.on.LifespanOn object at 0x7f4a984595a0>>
                                       |    |        |      -> <bound method LifespanOn.receive of <uvicorn.lifespan.on.LifespanOn object at 0x7f4a984595a0>>
                                       |    |        -> {'type': 'lifespan', 'asgi': {'version': '3.0', 'spec_version': '2.0'}, 'state': {}, 'app': <fastapi.applications.FastAPI obj...
                                       |    -> <function Router.lifespan at 0x7f4a97d35360>
                                       -> <fastapi.routing.APIRouter object at 0x7f4a6e101660>
                               File "/home/langflow/.local/lib/python3.10/site-packages/starlette/routing.py", line 693, in lifespan
                                 async with self.lifespan_context(app) as maybe_state:
                                            |    |                -> <fastapi.applications.FastAPI object at 0x7f4a6e100d90>
                                            |    -> <function _merge_lifespan_context.<locals>.merged_lifespan at 0x7f4a6d739360>
                                            -> <fastapi.routing.APIRouter object at 0x7f4a6e101660>
                               File "/usr/lib/python3.10/contextlib.py", line 199, in __aenter__
                                 return await anext(self.gen)
                                                    |    -> <async_generator object _merge_lifespan_context.<locals>.merged_lifespan at 0x7f4a936cdac0>
                                                    -> <contextlib._AsyncGeneratorContextManager object at 0x7f4a936f9690>
                               File "/home/langflow/.local/lib/python3.10/site-packages/fastapi/routing.py", line 133, in merged_lifespan
                                 async with original_context(app) as maybe_original_state:
                                            |                -> <fastapi.applications.FastAPI object at 0x7f4a6e100d90>
                                            -> <function _merge_lifespan_context.<locals>.merged_lifespan at 0x7f4a6d739c60>
                               File "/usr/lib/python3.10/contextlib.py", line 199, in __aenter__
                                 return await anext(self.gen)
                                                    |    -> <async_generator object _merge_lifespan_context.<locals>.merged_lifespan at 0x7f4a936cddc0>
                                                    -> <contextlib._AsyncGeneratorContextManager object at 0x7f4a936f96c0>
                               File "/home/langflow/.local/lib/python3.10/site-packages/fastapi/routing.py", line 133, in merged_lifespan
                                 async with original_context(app) as maybe_original_state:
                                            |                -> <fastapi.applications.FastAPI object at 0x7f4a6e100d90>
                                            -> <function _merge_lifespan_context.<locals>.merged_lifespan at 0x7f4a6e0064d0>
                               File "/usr/lib/python3.10/contextlib.py", line 199, in __aenter__
                                 return await anext(self.gen)
                                                    |    -> <async_generator object _merge_lifespan_context.<locals>.merged_lifespan at 0x7f4a936cde40>
                                                    -> <contextlib._AsyncGeneratorContextManager object at 0x7f4a936f96f0>
                               File "/home/langflow/.local/lib/python3.10/site-packages/fastapi/routing.py", line 133, in merged_lifespan
                                 async with original_context(app) as maybe_original_state:
                                            |                -> <fastapi.applications.FastAPI object at 0x7f4a6e100d90>
                                            -> <function get_lifespan.<locals>.lifespan at 0x7f4a6e3167a0>
                               File "/usr/lib/python3.10/contextlib.py", line 199, in __aenter__
                                 return await anext(self.gen)
                                                    |    -> <async_generator object get_lifespan.<locals>.lifespan at 0x7f4a936cdec0>
                                                    -> <contextlib._AsyncGeneratorContextManager object at 0x7f4a936f9720>
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/main.py", line 122, in lifespan
                                 await teardown_services()
                                       -> <function teardown_services at 0x7f4a7fff5f30>
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/services/utils.py", line 129, in teardown_services
                                 await service_manager.teardown()
                                       |               -> <function ServiceManager.teardown at 0x7f4a81519990>
                                       -> <langflow.services.manager.ServiceManager object at 0x7f4a81ec6b60>
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/services/manager.py", line 97, in teardown
                                 await service.teardown()
                                       |       -> <function TelemetryService.teardown at 0x7f4a7fd98d30>
                                       -> <langflow.services.telemetry.service.TelemetryService object at 0x7f4a6e100df0>
                               File "/home/langflow/.local/lib/python3.10/site-packages/langflow/services/telemetry/service.py", line 165, in teardown
                                 await self.stop()
                                       |    -> <function TelemetryService.stop at 0x7f4a7fd98ca0>
                                       -> <langflow.services.telemetry.service.TelemetryService object at 0x7f4a6e100df0>
                             > File "/home/langflow/.local/lib/python3.10/site-packages/langflow/services/telemetry/service.py", line 156, in stop
                                 if self.worker_task:
                                    -> <langflow.services.telemetry.service.TelemetryService object at 0x7f4a6e100df0>

@KevinMichaelSchindler
Copy link

I think I fixed it. It has something to do with the psycopg2 dependency. The current version uses sqlalchemy and the prior versions uses psycopg directly.
"psycopg2-binary>=2.9.6",
"psycopg>=3.1.9",
#"sqlalchemy[aiosqlite,postgresql_psycopgbinary]>=2.0.36",

Also I made some changes to the service.py to always define the driver for postgres. I will need to double check what was doing the trick but then I can probably give an update.

@severfire
Copy link
Author

@KevinMichaelSchindler awesome! @italojohnny If that would be the issue, I wonder if the hotfix for langflow could be released? I am also using sqlite version

@KevinMichaelSchindler
Copy link

@KevinMichaelSchindler awesome! @italojohnny If that would be the issue, I wonder if the hotfix for langflow could be released? I am also using sqlite version

The previous langflow version worked without the sqlalchemy dependency but probably there is a reason for adding it so it might be that some specific component or scenario breaks when reverting the dependencies. The default docker image uses postgres so I haven't tested the sqlite version. The tests definitely break for the sqlite stuff so more tinkering needs to be done to get the sqlite stuff to work. I assume the langflow team will bring out a proper fix soon but I thought I'll share this for the folks who are currently struggling with it.

P.S. I confirmed that when I change just the dependency to:
"psycopg2-binary>=2.9.6",
"psycopg>=3.1.9",
#"sqlalchemy[aiosqlite,postgresql_psycopgbinary]>=2.0.36",

It seems to work for the default docker yml, so no changes to service.py are required it seems.

@KevinMichaelSchindler
Copy link

I tried to add the aiosqlite manually:
"aiosqlite>=0.19.0",

But there are still unresolved errors:
FAILED src/backend/tests/unit/api/v1/test_users.py::test_add_user - RuntimeError: There's a mismatch between the models and the database.

Results (312.75s (0:05:12)):
582 passed
2 failed
- src/backend/tests/performance/test_server_init.py:22 test_initialize_services
- src/backend/tests/unit/test_cli.py:14 test_components_path
161 error
5 skipped
make[1]: *** [Makefile:133: unit_tests] Error 1
make[1]: Leaving directory '/mnt/b/Dokumente/langflow2/langflow'
make: *** [Makefile:164: tests] Error 2

So currently the dependency update fixes the postgres issues but not the sqlite stuff as it seems.

@severfire
Copy link
Author

@KevinMichaelSchindler that was the error i was getting at the beginning, mismatch between the models and the database... after next reinstall i got #4593 (comment)

@KevinMichaelSchindler
Copy link

You are using sqlite in your .env right? (python3 -m langflow run --env-file ./.env --no-open-browser --auto-saving --host localhost)

I just tested it for the "make init" locally and the docker-compose.yml in the docker-example. These use postgres out of the box but the docker image was showing the same error regarding sqlalchemy, so that is what I fixed.

As said if you are using sqlite there might be some additional fixing required, I am sorry :(

@severfire
Copy link
Author

severfire commented Nov 17, 2024

@KevinMichaelSchindler Yes, I am. I used pip installation. I am not using docker installation here.
Hmm... I wonder how many people have similar problem... its not small thing I guess...
@italojohnny were you able to replicate the issue?

@severfire
Copy link
Author

I found the issue is with dependencies, especially Pydantic, used AI to help me a bit...

Final Codebase Context
Based on the provided codebase, Langflow uses both Pydantic v1 and v2. This can be seen in several places:
In the dependencies from pyproject.toml:
Shows "pydantic>=2.7.0" and "pydantic-settings>=2.2.0" as dependencies.

However, there are also explicit imports from pydantic.v1 in several files, for example in the flow model:
This dual usage pattern suggests that Langflow is in a transition period between Pydantic v1 and v2, likely maintaining compatibility with both versions. This is a common pattern for libraries that are migrating from Pydantic v1 to v2 while maintaining backward compatibility.

The main version requirement is Pydantic 2.x (>=2.7.0), but the codebase still uses some v1 imports for specific functionality that might not have been migrated yet or requires v1 compatibility.

@severfire
Copy link
Author

severfire commented Nov 18, 2024

therefore...

langflow@server:~$ python3.10 -m langflow run --env-file ./.env --no-open-browser --auto-saving --host localhost
Starting Langflow v1.1.0...
/home/langflow/.local/lib/python3.10/site-packages/pydantic/_internal/_generate_schema.py:260: PydanticDeprecatedSince20: `json_encoders` is deprecated. See https://docs.pydantic.dev/2.7/concepts/serialization/#custom-serializers for alternatives. Deprecated in Pydantic V2.0 to be removed in V3.0. See Pydantic V2 Migration Guide at https://errors.pydantic.dev/2.7/migration/
  warnings.warn(
/home/langflow/.local/lib/python3.10/site-packages/composio/client/http.py:20: DeprecationWarning: Inheritance class AsyncHttpClient from ClientSession is discouraged
  class AsyncHttpClient(AsyncSession, logging.WithLogger):
/home/langflow/.local/lib/python3.10/site-packages/crewai/tools/base_tool.py:28: PydanticDeprecatedSince20: Pydantic V1 style `@validator` validators are deprecated. You should migrate to Pydantic V2 style `@field_validator` validators, see the migration guide for more details. Deprecated in Pydantic V2.0 to be removed in V3.0. See Pydantic V2 Migration Guide at https://errors.pydantic.dev/2.7/migration/
  @validator("args_schema", always=True, pre=True)
/home/langflow/.local/lib/python3.10/site-packages/pydantic/_internal/_config.py:284: PydanticDeprecatedSince20: Support for class-based `config` is deprecated, use ConfigDict instead. Deprecated in Pydantic V2.0 to be removed in V3.0. See Pydantic V2 Migration Guide at https://errors.pydantic.dev/2.7/migration/
  warnings.warn(DEPRECATION_MESSAGE, DeprecationWarning)

@italojohnny italojohnny changed the title version 1.1.00 fresh reinstall issue version 1.1.0 fresh reinstall issue Nov 18, 2024
@italojohnny
Copy link
Member

Hello @severfire, @KevinMichaelSchindler and @greenmotion ,

First of all, I want to express our deep gratitude for everyone’s help in making Langflow a better tool. Your support means a lot to us!

Secondly, I apologize for the delay in responding. This particular issue has been quite challenging to reproduce. In addition to myself, others are also working to address it.

The tracebacks point to a migration issue, but the exact cause remains unclear. There is a possibility that fix #4599 resolved the problem. However, since we haven’t been able to reproduce the issue consistently, we cannot guarantee this with 100% certainty yet.

For this reason, I would recommend, as an alternative, trying out the nightly version, which already includes this fix along with others. This might serve as a temporary solution until we can confirm the fix and proceed with the next official release.

Thank you for your patience and understanding

@severfire
Copy link
Author

severfire commented Nov 18, 2024

@italojohnny I have feeling it is python dependency issue. (I was playing with reinstalling different versions of Pydantic, staying with latest version, and also with pip install grpcio==1.59.0 grpcio-tools==1.59.0) Anyhow today my morning - like 12h ago I was able to run langflow, but it did not load .env config, I had to use exports. next week or later this week I will check your fixes, as right now my installation seems stable (with workarounds), and I have to do different tasks) thank you for all your help!

@greenmotion
Copy link

@italojohnny: I'd be more than happy to test your nightly build, but I must admit I'm relatively new to Python and have been running Langflow in a venv and not a docker container. How would I update my langflow instance to a nightly build version?

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

4 participants