Replies: 2 comments 1 reply
-
The error in Docker version 1.0.0a53 of Langflow is due to a permission issue with the To resolve this, you need to ensure that the For the Dockerfile, add the following: RUN mkdir -p /app/langflow && chown -R 1000:1000 /app/langflow For the Docker Compose file, you can add a command to set the permissions: services:
langflow:
image: langflowai/langflow:latest
ports:
- "7860:7860"
environment:
- LANGFLOW_CONFIG_DIR=/app/langflow
volumes:
- langflow-data:/app/langflow
command: >
sh -c "chown -R 1000:1000 /app/langflow && your_start_command_here" Replace |
Beta Was this translation helpful? Give feedback.
-
If I remove the following parameter in the Dockercompose file, it works |
Beta Was this translation helpful? Give feedback.
-
Dear all
I do not know if it is usefull for you but each time you release a version in direction of 1.0, I am testing it in my environment.
The actual version 1.0.0a53 seems to have an error and do not start due to
langflow | PermissionError: [Errno 13] Permission denied: '/app/langflow/secret_key'
previous version 1.0.0a29 was working fine.
docker compose --env-file local.env up --build [+] Building 0.3s (5/5) FINISHED docker:default => [langflow internal] load build definition from Dockerfile 0.0s => => transferring dockerfile: 790B 0.0s => [langflow internal] load metadata for docker.io/langflowai/langflow:1.0.0a53 0.3s => [langflow internal] load .dockerignore 0.0s => => transferring context: 2B 0.0s => CACHED [langflow 1/1] FROM docker.io/langflowai/langflow:1.0.0a53@sha256:13d9c4342d5b11a35ddd747401992697513d8dc8b2c5ad9a4f41f2ff620a6fa4 0.0s => [langflow] exporting to image 0.0s => => exporting layers 0.0s => => writing image sha256:5329064331a83a64648f13ab43c63e2ddb833e0417062319f19e4f71d5d8c673 0.0s => => naming to docker.io/library/langflow-langflow 0.0s [+] Running 1/0 ✔ Container langflow Recreated 0.0s Attaching to langflow langflow | /app/.venv/lib/python3.12/site-packages/langchain/agents/json_chat/base.py:22: SyntaxWarning: invalid escape sequence '\ ' langflow | """Create an agent that uses JSON to format its logic, build for Chat Models. langflow | ╭───────────────────── Traceback (most recent call last) ──────────────────────╮ langflow | │ /app/.venv/lib/python3.12/site-packages/langflow/__main__.py:134 in run │ langflow | │ │ langflow | │ 131 │ if env_file: │ langflow | │ 132 │ │ load_dotenv(env_file, override=True) │ langflow | │ 133 │ │ langflow | │ ❱ 134 │ update_settings( │ langflow | │ 135 │ │ dev=dev, │ langflow | │ 136 │ │ remove_api_keys=remove_api_keys, │ langflow | │ 137 │ │ cache=cache, │ langflow | │ │ langflow | │ ╭───────────────────────────────── locals ─────────────────────────────────╮ │ langflow | │ │ backend_only = False │ │ langflow | │ │ cache = None │ │ langflow | │ │ components_path = PosixPath('/app/.venv/lib/python3.12/site-packages/la… │ │ langflow | │ │ dev = False │ │ langflow | │ │ env_file = None │ │ langflow | │ │ host = '0.0.0.0' │ │ langflow | │ │ log_file = PosixPath('logs/langflow.log') │ │ langflow | │ │ log_level = 'critical' │ │ langflow | │ │ open_browser = True │ │ langflow | │ │ path = None │ │ langflow | │ │ port = 7860 │ │ langflow | │ │ remove_api_keys = False │ │ langflow | │ │ store = True │ │ langflow | │ │ timeout = 300 │ │ langflow | │ │ workers = 1 │ │ langflow | │ ╰──────────────────────────────────────────────────────────────────────────╯ │ langflow | │ │ langflow | │ /app/.venv/lib/python3.12/site-packages/langflow/utils/util.py:435 in │ langflow | │ update_settings │ langflow | │ │ langflow | │ 432 │ │ langflow | │ 433 │ # Check for database_url in the environment variables │ langflow | │ 434 │ │ langflow | │ ❱ 435 │ initialize_settings_service() │ langflow | │ 436 │ settings_service = get_settings_service() │ langflow | │ 437 │ if config: │ langflow | │ 438 │ │ logger.debug(f"Loading settings from {config}") │ langflow | │ │ langflow | │ ╭───────────────────────────────── locals ─────────────────────────────────╮ │ langflow | │ │ cache = None │ │ langflow | │ │ components_path = PosixPath('/app/.venv/lib/python3.12/site… │ │ langflow | │ │ config = None │ │ langflow | │ │ dev = False │ │ langflow | │ │ initialize_settings_service = <function initialize_settings_service at │ │ langflow | │ │ 0x71fa3c059a80> │ │ langflow | │ │ remove_api_keys = False │ │ langflow | │ │ store = True │ │ langflow | │ ╰──────────────────────────────────────────────────────────────────────────╯ │ langflow | │ │ langflow | │ /app/.venv/lib/python3.12/site-packages/langflow/services/utils.py:133 in │ langflow | │ initialize_settings_service │ langflow | │ │ langflow | │ 130 │ """ │ langflow | │ 131 │ from langflow.services.settings import factory as settings_factory │ langflow | │ 132 │ │ langflow | │ ❱ 133 │ get_service(ServiceType.SETTINGS_SERVICE, settings_factory.Setting │ langflow | │ 134 │ langflow | │ 135 │ langflow | │ 136 def initialize_session_service(): │ langflow | │ │ langflow | │ ╭───────────────────────────────── locals ─────────────────────────────────╮ │ langflow | │ │ settings_factory = <module 'langflow.services.settings.factory' from │ │ langflow | │ │ '/app/.venv/lib/python3.12/site-packages/langflow/se… │ │ langflow | │ ╰──────────────────────────────────────────────────────────────────────────╯ │ langflow | │ │ langflow | │ /app/.venv/lib/python3.12/site-packages/langflow/services/deps.py:41 in │ langflow | │ get_service │ langflow | │ │ langflow | │ 38 │ │ #! This is a workaround to ensure that the service manager is │ langflow | │ 39 │ │ #! Not optimal, but it works for now │ langflow | │ 40 │ │ service_manager.register_factories() │ langflow | │ ❱ 41 │ return service_manager.get(service_type, default) # type: ignore │ langflow | │ 42 │ langflow | │ 43 │ langflow | │ 44 def get_state_service() -> "StateService": │ langflow | │ │ langflow | │ ╭───────────────────────────────── locals ─────────────────────────────────╮ │ langflow | │ │ default = <langflow.services.settings.factory.SettingsServiceFa… │ │ langflow | │ │ object at 0x71fa3bfb3020> │ │ langflow | │ │ service_manager = <langflow.services.manager.ServiceManager object at │ │ langflow | │ │ 0x71fa3dd81e50> │ │ langflow | │ │ service_type = <ServiceType.SETTINGS_SERVICE: 'settings_service'> │ │ langflow | │ ╰──────────────────────────────────────────────────────────────────────────╯ │ langflow | │ │ langflow | │ /app/.venv/lib/python3.12/site-packages/langflow/services/manager.py:53 in │ langflow | │ get │ langflow | │ │ langflow | │ 50 │ │ """ │ langflow | │ 51 │ │ │ langflow | │ 52 │ │ if service_name not in self.services: │ langflow | │ ❱ 53 │ │ │ self._create_service(service_name, default) │ langflow | │ 54 │ │ │ langflow | │ 55 │ │ return self.services[service_name] │ langflow | │ 56 │ langflow | │ │ langflow | │ ╭───────────────────────────────── locals ─────────────────────────────────╮ │ langflow | │ │ default = <langflow.services.settings.factory.SettingsServiceFacto… │ │ langflow | │ │ object at 0x71fa3bfb3020> │ │ langflow | │ │ self = <langflow.services.manager.ServiceManager object at │ │ langflow | │ │ 0x71fa3dd81e50> │ │ langflow | │ │ service_name = <ServiceType.SETTINGS_SERVICE: 'settings_service'> │ │ langflow | │ ╰──────────────────────────────────────────────────────────────────────────╯ │ langflow | │ │ langflow | │ /app/.venv/lib/python3.12/site-packages/langflow/services/manager.py:77 in │ langflow | │ _create_service │ langflow | │ │ langflow | │ 74 │ │ dependent_services = {dep.value: self.services[dep] for dep in │ langflow | │ 75 │ │ │ langflow | │ 76 │ │ # Create the actual service │ langflow | │ ❱ 77 │ │ self.services[service_name] = self.factories[service_name].cre │ langflow | │ 78 │ │ self.services[service_name].set_ready() │ langflow | │ 79 │ │ langflow | │ 80 │ def _validate_service_creation(self, service_name: "ServiceType", │ langflow | │ │ langflow | │ ╭───────────────────────────────── locals ─────────────────────────────────╮ │ langflow | │ │ default = <langflow.services.settings.factory.SettingsServic… │ │ langflow | │ │ object at 0x71fa3bfb3020> │ │ langflow | │ │ dependent_services = {} │ │ langflow | │ │ factory = <langflow.services.settings.factory.SettingsServic… │ │ langflow | │ │ object at 0x71fa3d330380> │ │ langflow | │ │ self = <langflow.services.manager.ServiceManager object at │ │ langflow | │ │ 0x71fa3dd81e50> │ │ langflow | │ │ service_name = <ServiceType.SETTINGS_SERVICE: 'settings_service'> │ │ langflow | │ ╰──────────────────────────────────────────────────────────────────────────╯ │ langflow | │ │ langflow | │ /app/.venv/lib/python3.12/site-packages/langflow/services/settings/factory.p │ langflow | │ y:14 in create │ langflow | │ │ langflow | │ 11 │ def create(self): │ langflow | │ 12 │ │ # Here you would have logic to create and configure a SettingsS │ langflow | │ 13 │ │ langflow_dir = Path(__file__).parent.parent.parent │ langflow | │ ❱ 14 │ │ return SettingsService.load_settings_from_yaml(str(langflow_dir │ langflow | │ 15 │ langflow | │ │ langflow | │ ╭───────────────────────────────── locals ─────────────────────────────────╮ │ langflow | │ │ langflow_dir = PosixPath('/app/.venv/lib/python3.12/site-packages/langf… │ │ langflow | │ │ self = <langflow.services.settings.factory.SettingsServiceFacto… │ │ langflow | │ │ object at 0x71fa3d330380> │ │ langflow | │ ╰──────────────────────────────────────────────────────────────────────────╯ │ langflow | │ │ langflow | │ /app/.venv/lib/python3.12/site-packages/langflow/services/settings/service.p │ langflow | │ y:40 in load_settings_from_yaml │ langflow | │ │ langflow | │ 37 │ │ if not settings.config_dir: │ langflow | │ 38 │ │ │ raise ValueError("CONFIG_DIR must be set in settings") │ langflow | │ 39 │ │ │ langflow | │ ❱ 40 │ │ auth_settings = AuthSettings( │ langflow | │ 41 │ │ │ CONFIG_DIR=settings.config_dir, │ langflow | │ 42 │ │ ) │ langflow | │ 43 │ │ return cls(settings, auth_settings) │ langflow | │ │ langflow | │ ╭───────────────────────────────── locals ─────────────────────────────────╮ │ langflow | │ │ cls = <class │ │ langflow | │ │ 'langflow.services.settings.service.SettingsService'> │ │ langflow | │ │ f = <_io.TextIOWrapper │ │ langflow | │ │ name='/app/.venv/lib/python3.12/site-packages/langflow/… │ │ langflow | │ │ mode='r' encoding='UTF-8'> │ │ langflow | │ │ file_path = '/app/.venv/lib/python3.12/site-packages/langflow/confi… │ │ langflow | │ │ key = 'custom_components' │ │ langflow | │ │ settings = Settings( │ │ langflow | │ │ │ config_dir='/app/langflow', │ │ langflow | │ │ │ save_db_in_config_dir=False, │ │ langflow | │ │ │ dev=False, │ │ langflow | │ │ │ │ │ langflow | │ │ database_url='postgresql://postgres:postgres@postgres:5… │ │ langflow | │ │ │ pool_size=10, │ │ langflow | │ │ │ max_overflow=20, │ │ langflow | │ │ │ cache_type='async', │ │ langflow | │ │ │ remove_api_keys=False, │ │ langflow | │ │ │ components_path=[ │ │ langflow | │ │ │ │ │ │ langflow | │ │ '/app/.venv/lib/python3.12/site-packages/langflow/compo… │ │ langflow | │ │ │ ], │ │ langflow | │ │ │ langchain_cache='InMemoryCache', │ │ langflow | │ │ │ load_flows_path=None, │ │ langflow | │ │ │ redis_host='localhost', │ │ langflow | │ │ │ redis_port=6379, │ │ langflow | │ │ │ redis_db=0, │ │ langflow | │ │ │ redis_url=None, │ │ langflow | │ │ │ redis_cache_expire=3600, │ │ langflow | │ │ │ │ │ langflow | │ │ langfuse_secret_key='sk-lf-01488652-3937-44c4-8b5a-fa3b… │ │ langflow | │ │ │ │ │ langflow | │ │ langfuse_public_key='pk-lf-901df19d-d0d3-43de-8ec5-f398… │ │ langflow | │ │ │ langfuse_host='http://langfuse:3000', │ │ langflow | │ │ │ store=True, │ │ langflow | │ │ │ store_url='https://api.langflow.store', │ │ langflow | │ │ │ │ │ langflow | │ │ download_webhook_url='https://api.langflow.store/flows/… │ │ langflow | │ │ │ │ │ langflow | │ │ like_webhook_url='https://api.langflow.store/flows/trig… │ │ langflow | │ │ │ storage_type='local', │ │ langflow | │ │ │ celery_enabled=False, │ │ langflow | │ │ │ fallback_to_env_var=True, │ │ langflow | │ │ │ store_environment_variables=True, │ │ langflow | │ │ │ variables_to_get_from_environment=[ │ │ langflow | │ │ │ │ 'OPENAI_API_KEY', │ │ langflow | │ │ │ │ 'ANTHROPIC_API_KEY', │ │ langflow | │ │ │ │ 'GOOGLE_API_KEY', │ │ langflow | │ │ │ │ 'AZURE_OPENAI_API_KEY', │ │ langflow | │ │ │ │ 'AZURE_OPENAI_API_VERSION', │ │ langflow | │ │ │ │ 'AZURE_OPENAI_API_INSTANCE_NAME', │ │ langflow | │ │ │ │ 'AZURE_OPENAI_API_DEPLOYMENT_NAME', │ │ langflow | │ │ │ │ 'AZURE_OPENAI_API_EMBEDDINGS_DEPLOYMENT_NAME', │ │ langflow | │ │ │ │ 'ASTRA_DB_APPLICATION_TOKEN', │ │ langflow | │ │ │ │ 'ASTRA_DB_API_ENDPOINT', │ │ langflow | │ │ │ │ ... +11 │ │ langflow | │ │ │ ], │ │ langflow | │ │ │ worker_timeout=300, │ │ langflow | │ │ │ frontend_timeout=0 │ │ langflow | │ │ ) │ │ langflow | │ │ settings_dict = { │ │ langflow | │ │ │ 'agents': { │ │ langflow | │ │ │ │ 'ZeroShotAgent': { │ │ langflow | │ │ │ │ │ 'documentation': │ │ langflow | │ │ 'https://python.langchain.com/docs/modules/agents/how_t… │ │ langflow | │ │ │ │ }, │ │ langflow | │ │ │ │ 'JsonAgent': { │ │ langflow | │ │ │ │ │ 'documentation': │ │ langflow | │ │ 'https://python.langchain.com/docs/modules/agents/toolk… │ │ langflow | │ │ │ │ }, │ │ langflow | │ │ │ │ 'CSVAgent': { │ │ langflow | │ │ │ │ │ 'documentation': │ │ langflow | │ │ 'https://python.langchain.com/docs/modules/agents/toolk… │ │ langflow | │ │ │ │ }, │ │ langflow | │ │ │ │ 'VectorStoreAgent': {'documentation': ''}, │ │ langflow | │ │ │ │ 'VectorStoreRouterAgent': { │ │ langflow | │ │ │ │ │ 'documentation': '' │ │ langflow | │ │ │ │ }, │ │ langflow | │ │ │ │ 'SQLAgent': {'documentation': ''} │ │ langflow | │ │ │ }, │ │ langflow | │ │ │ 'documentloaders': { │ │ langflow | │ │ │ │ 'AirbyteJSONLoader': { │ │ langflow | │ │ │ │ │ 'documentation': │ │ langflow | │ │ 'https://python.langchain.com/docs/modules/data_connect… │ │ langflow | │ │ │ │ }, │ │ langflow | │ │ │ │ 'CoNLLULoader': { │ │ langflow | │ │ │ │ │ 'documentation': │ │ langflow | │ │ 'https://python.langchain.com/docs/modules/data_connect… │ │ langflow | │ │ │ │ }, │ │ langflow | │ │ │ │ 'CSVLoader': { │ │ langflow | │ │ │ │ │ 'documentation': │ │ langflow | │ │ 'https://python.langchain.com/docs/modules/data_connect… │ │ langflow | │ │ │ │ }, │ │ langflow | │ │ │ │ 'UnstructuredEmailLoader': { │ │ langflow | │ │ │ │ │ 'documentation': │ │ langflow | │ │ 'https://python.langchain.com/docs/modules/data_connect… │ │ langflow | │ │ │ │ }, │ │ langflow | │ │ │ │ 'EverNoteLoader': { │ │ langflow | │ │ │ │ │ 'documentation': │ │ langflow | │ │ 'https://python.langchain.com/docs/modules/data_connect… │ │ langflow | │ │ │ │ }, │ │ langflow | │ │ │ │ 'FacebookChatLoader': { │ │ langflow | │ │ │ │ │ 'documentation': │ │ langflow | │ │ 'https://python.langchain.com/docs/modules/data_connect… │ │ langflow | │ │ │ │ }, │ │ langflow | │ │ │ │ 'GutenbergLoader': { │ │ langflow | │ │ │ │ │ 'documentation': │ │ langflow | │ │ 'https://python.langchain.com/docs/modules/data_connect… │ │ langflow | │ │ │ │ }, │ │ langflow | │ │ │ │ 'BSHTMLLoader': { │ │ langflow | │ │ │ │ │ 'documentation': │ │ langflow | │ │ 'https://python.langchain.com/docs/modules/data_connect… │ │ langflow | │ │ │ │ }, │ │ langflow | │ │ │ │ 'UnstructuredHTMLLoader': { │ │ langflow | │ │ │ │ │ 'documentation': │ │ langflow | │ │ 'https://python.langchain.com/docs/modules/data_connect… │ │ langflow | │ │ │ │ }, │ │ langflow | │ │ │ │ 'UnstructuredMarkdownLoader': { │ │ langflow | │ │ │ │ │ 'documentation': │ │ langflow | │ │ 'https://python.langchain.com/docs/modules/data_connect… │ │ langflow | │ │ │ │ }, │ │ langflow | │ │ │ │ ... +19 │ │ langflow | │ │ │ }, │ │ langflow | │ │ │ 'embeddings': { │ │ langflow | │ │ │ │ 'OpenAIEmbeddings': { │ │ langflow | │ │ │ │ │ 'documentation': │ │ langflow | │ │ 'https://python.langchain.com/docs/modules/data_connect… │ │ langflow | │ │ │ │ }, │ │ langflow | │ │ │ │ 'HuggingFaceEmbeddings': { │ │ langflow | │ │ │ │ │ 'documentation': │ │ langflow | │ │ 'https://python.langchain.com/docs/modules/data_connect… │ │ langflow | │ │ │ │ }, │ │ langflow | │ │ │ │ 'CohereEmbeddings': { │ │ langflow | │ │ │ │ │ 'documentation': │ │ langflow | │ │ 'https://python.langchain.com/docs/modules/data_connect… │ │ langflow | │ │ │ │ }, │ │ langflow | │ │ │ │ 'VertexAIEmbeddings': { │ │ langflow | │ │ │ │ │ 'documentation': │ │ langflow | │ │ 'https://python.langchain.com/docs/modules/data_connect… │ │ langflow | │ │ │ │ }, │ │ langflow | │ │ │ │ 'AmazonBedrockEmbeddings': { │ │ langflow | │ │ │ │ │ 'documentation': │ │ langflow | │ │ 'https://python.langchain.com/docs/modules/data_connect… │ │ langflow | │ │ │ │ }, │ │ langflow | │ │ │ │ 'OllamaEmbeddings': { │ │ langflow | │ │ │ │ │ 'documentation': │ │ langflow | │ │ 'https://python.langchain.com/docs/modules/data_connect… │ │ langflow | │ │ │ │ } │ │ langflow | │ │ │ }, │ │ langflow | │ │ │ 'memories': { │ │ langflow | │ │ │ │ 'ConversationEntityMemory': { │ │ langflow | │ │ │ │ │ 'documentation': │ │ langflow | │ │ 'https://python.langchain.com/docs/modules/memory/integ… │ │ langflow | │ │ │ │ }, │ │ langflow | │ │ │ │ 'PostgresChatMessageHistory': { │ │ langflow | │ │ │ │ │ 'documentation': │ │ langflow | │ │ 'https://python.langchain.com/docs/modules/memory/integ… │ │ langflow | │ │ │ │ }, │ │ langflow | │ │ │ │ 'ConversationBufferMemory': { │ │ langflow | │ │ │ │ │ 'documentation': │ │ langflow | │ │ 'https://python.langchain.com/docs/modules/memory/how_t… │ │ langflow | │ │ │ │ }, │ │ langflow | │ │ │ │ 'ConversationSummaryMemory': { │ │ langflow | │ │ │ │ │ 'documentation': │ │ langflow | │ │ 'https://python.langchain.com/docs/modules/memory/how_t… │ │ langflow | │ │ │ │ }, │ │ langflow | │ │ │ │ 'ConversationKGMemory': { │ │ langflow | │ │ │ │ │ 'documentation': │ │ langflow | │ │ 'https://python.langchain.com/docs/modules/memory/how_t… │ │ langflow | │ │ │ │ }, │ │ langflow | │ │ │ │ 'ConversationBufferWindowMemory': { │ │ langflow | │ │ │ │ │ 'documentation': │ │ langflow | │ │ 'https://python.langchain.com/docs/modules/memory/how_t… │ │ langflow | │ │ │ │ }, │ │ langflow | │ │ │ │ 'VectorStoreRetrieverMemory': { │ │ langflow | │ │ │ │ │ 'documentation': │ │ langflow | │ │ 'https://python.langchain.com/docs/modules/memory/how_t… │ │ langflow | │ │ │ │ }, │ │ langflow | │ │ │ │ 'MongoDBChatMessageHistory': { │ │ langflow | │ │ │ │ │ 'documentation': │ │ langflow | │ │ 'https://python.langchain.com/docs/modules/memory/integ… │ │ langflow | │ │ │ │ }, │ │ langflow | │ │ │ │ 'MotorheadMemory': { │ │ langflow | │ │ │ │ │ 'documentation': │ │ langflow | │ │ 'https://python.langchain.com/docs/integrations/memory/… │ │ langflow | │ │ │ │ } │ │ langflow | │ │ │ }, │ │ langflow | │ │ │ 'prompts': { │ │ langflow | │ │ │ │ 'ChatMessagePromptTemplate': { │ │ langflow | │ │ │ │ │ 'documentation': │ │ langflow | │ │ 'https://python.langchain.com/docs/modules/model_io/pro… │ │ langflow | │ │ │ │ }, │ │ langflow | │ │ │ │ 'HumanMessagePromptTemplate': { │ │ langflow | │ │ │ │ │ 'documentation': │ │ langflow | │ │ 'https://python.langchain.com/docs/modules/model_io/mod… │ │ langflow | │ │ │ │ }, │ │ langflow | │ │ │ │ 'SystemMessagePromptTemplate': { │ │ langflow | │ │ │ │ │ 'documentation': │ │ langflow | │ │ 'https://python.langchain.com/docs/modules/model_io/mod… │ │ langflow | │ │ │ │ }, │ │ langflow | │ │ │ │ 'ChatPromptTemplate': { │ │ langflow | │ │ │ │ │ 'documentation': │ │ langflow | │ │ 'https://python.langchain.com/docs/modules/model_io/mod… │ │ langflow | │ │ │ │ }, │ │ langflow | │ │ │ │ 'PromptTemplate': { │ │ langflow | │ │ │ │ │ 'documentation': │ │ langflow | │ │ 'https://python.langchain.com/docs/modules/model_io/pro… │ │ langflow | │ │ │ │ } │ │ langflow | │ │ │ }, │ │ langflow | │ │ │ 'textsplitters': { │ │ langflow | │ │ │ │ 'CharacterTextSplitter': { │ │ langflow | │ │ │ │ │ 'documentation': │ │ langflow | │ │ 'https://python.langchain.com/docs/modules/data_connect… │ │ langflow | │ │ │ │ }, │ │ langflow | │ │ │ │ 'RecursiveCharacterTextSplitter': { │ │ langflow | │ │ │ │ │ 'documentation': │ │ langflow | │ │ 'https://python.langchain.com/docs/modules/data_connect… │ │ langflow | │ │ │ │ } │ │ langflow | │ │ │ }, │ │ langflow | │ │ │ 'toolkits': { │ │ langflow | │ │ │ │ 'OpenAPIToolkit': {'documentation': ''}, │ │ langflow | │ │ │ │ 'JsonToolkit': {'documentation': ''}, │ │ langflow | │ │ │ │ 'VectorStoreInfo': {'documentation': ''}, │ │ langflow | │ │ │ │ 'VectorStoreRouterToolkit': { │ │ langflow | │ │ │ │ │ 'documentation': '' │ │ langflow | │ │ │ │ }, │ │ langflow | │ │ │ │ 'VectorStoreToolkit': {'documentation': ''} │ │ langflow | │ │ │ }, │ │ langflow | │ │ │ 'tools': { │ │ langflow | │ │ │ │ 'Search': {'documentation': ''}, │ │ langflow | │ │ │ │ 'PAL-MATH': {'documentation': ''}, │ │ langflow | │ │ │ │ 'Calculator': {'documentation': ''}, │ │ langflow | │ │ │ │ 'Serper Search': {'documentation': ''}, │ │ langflow | │ │ │ │ 'Tool': {'documentation': ''}, │ │ langflow | │ │ │ │ 'PythonFunctionTool': {'documentation': ''}, │ │ langflow | │ │ │ │ 'PythonFunction': {'documentation': ''}, │ │ langflow | │ │ │ │ 'JsonSpec': {'documentation': ''}, │ │ langflow | │ │ │ │ 'News API': {'documentation': ''}, │ │ langflow | │ │ │ │ 'TMDB API': {'documentation': ''}, │ │ langflow | │ │ │ │ ... +19 │ │ langflow | │ │ │ }, │ │ langflow | │ │ │ 'utilities': { │ │ langflow | │ │ │ │ 'BingSearchAPIWrapper': {'documentation': ''}, │ │ langflow | │ │ │ │ 'GoogleSearchAPIWrapper': { │ │ langflow | │ │ │ │ │ 'documentation': '' │ │ langflow | │ │ │ │ }, │ │ langflow | │ │ │ │ 'GoogleSerperAPIWrapper': { │ │ langflow | │ │ │ │ │ 'documentation': '' │ │ langflow | │ │ │ │ }, │ │ langflow | │ │ │ │ 'SearxResults': {'documentation': ''}, │ │ langflow | │ │ │ │ 'SearxSearchWrapper': {'documentation': ''}, │ │ langflow | │ │ │ │ 'SerpAPIWrapper': {'documentation': ''}, │ │ langflow | │ │ │ │ 'WikipediaAPIWrapper': {'documentation': ''}, │ │ langflow | │ │ │ │ 'WolframAlphaAPIWrapper': { │ │ langflow | │ │ │ │ │ 'documentation': '' │ │ langflow | │ │ │ │ } │ │ langflow | │ │ │ }, │ │ langflow | │ │ │ 'retrievers': { │ │ langflow | │ │ │ │ 'MultiQueryRetriever': { │ │ langflow | │ │ │ │ │ 'documentation': │ │ langflow | │ │ 'https://python.langchain.com/docs/modules/data_connect… │ │ langflow | │ │ │ │ } │ │ langflow | │ │ │ }, │ │ langflow | │ │ │ ... +2 │ │ langflow | │ │ } │ │ langflow | │ ╰──────────────────────────────────────────────────────────────────────────╯ │ langflow | │ │ langflow | │ /app/.venv/lib/python3.12/site-packages/pydantic_settings/main.py:140 in │ langflow | │ __init__ │ langflow | │ │ langflow | │ 137 │ │ **values: Any, │ langflow | │ 138 │ ) -> None: │ langflow | │ 139 │ │ # Uses something other than
selfthe first arg to allow "sel │ langflow | │ ❱ 140 │ │ super().__init__( │ langflow | │ 141 │ │ │ **__pydantic_self__._settings_build_values( │ langflow | │ 142 │ │ │ │ values, │ langflow | │ 143 │ │ │ │ _case_sensitive=_case_sensitive, │ langflow | │ │ langflow | │ ╭───────────────────────────── locals ─────────────────────────────╮ │ langflow | │ │ _case_sensitive = None │ │ langflow | │ │ _cli_avoid_json = None │ │ langflow | │ │ _cli_enforce_required = None │ │ langflow | │ │ _cli_hide_none_type = None │ │ langflow | │ │ _cli_parse_args = None │ │ langflow | │ │ _cli_parse_none_str = None │ │ langflow | │ │ _cli_prefix = None │ │ langflow | │ │ _cli_prog_name = None │ │ langflow | │ │ _cli_settings_source = None │ │ langflow | │ │ _cli_use_class_docs_for_groups = None │ │ langflow | │ │ _env_file = PosixPath('.') │ │ langflow | │ │ _env_file_encoding = None │ │ langflow | │ │ _env_ignore_empty = None │ │ langflow | │ │ _env_nested_delimiter = None │ │ langflow | │ │ _env_parse_enums = None │ │ langflow | │ │ _env_parse_none_str = None │ │ langflow | │ │ _env_prefix = None │ │ langflow | │ │ _secrets_dir = None │ │ langflow | │ │ values = {'CONFIG_DIR': '/app/langflow'} │ │ langflow | │ ╰──────────────────────────────────────────────────────────────────╯ │ langflow | │ │ langflow | │ /app/.venv/lib/python3.12/site-packages/pydantic/main.py:176 in __init__ │ langflow | │ │ langflow | │ 173 │ │ """ │ langflow | │ 174 │ │ #
tracebackhidetells pytest and some other tools to om │ langflow | │ 175 │ │ __tracebackhide__ = True │ langflow | │ ❱ 176 │ │ self.__pydantic_validator__.validate_python(data, self_instan │ langflow | │ 177 │ │ langflow | │ 178 │ # The following line sets a flag that we use to determine when
_ │langflow | │ 179 │ init.pydantic_base_init = True # pyright: ignore[reportF │
langflow | │ │
langflow | │ ╭───────────────── locals ──────────────────╮ │
langflow | │ │ data = { │ │
langflow | │ │ │ 'CONFIG_DIR': '/app/langflow', │ │
langflow | │ │ │ 'AUTO_LOGIN': 'false', │ │
langflow | │ │ │ 'NEW_USER_IS_ACTIVE': 'false', │ │
langflow | │ │ │ 'SUPERUSER': 'admin', │ │
langflow | │ │ │ 'SUPERUSER_PASSWORD': '123456' │ │
langflow | │ │ } │ │
langflow | │ │ self = AuthSettings() │ │
langflow | │ ╰───────────────────────────────────────────╯ │
langflow | │ │
langflow | │ /app/.venv/lib/python3.12/site-packages/langflow/services/settings/auth.py:1 │
langflow | │ 02 in get_secret_key │
langflow | │ │
langflow | │ 99 │ │ │ logger.debug("No secret key provided, generating a random │
langflow | │ 100 │ │ │ │
langflow | │ 101 │ │ │ if secret_key_path.exists(): │
langflow | │ ❱ 102 │ │ │ │ value = read_secret_from_file(secret_key_path) │
langflow | │ 103 │ │ │ │ logger.debug("Loaded secret key") │
langflow | │ 104 │ │ │ │ if not value: │
langflow | │ 105 │ │ │ │ │ value = secrets.token_urlsafe(32) │
langflow | │ │
langflow | │ ╭───────────────────────────────── locals ─────────────────────────────────╮ │
langflow | │ │ cls = <class 'langflow.services.settings.auth.AuthSettings'> │ │
langflow | │ │ config_dir = '/app/langflow' │ │
langflow | │ │ info = ValidationInfo(config={'title': 'AuthSettings', │ │
langflow | │ │ 'extra_fields_behavior': 'ignore', 'validate_default': │ │
langflow | │ │ True}, context=None, data={'CONFIG_DIR': │ │
langflow | │ │ '/app/langflow'}, field_name='SECRET_KEY') │ │
langflow | │ │ secret_key_path = PosixPath('/app/langflow/secret_key') │ │
langflow | │ │ value = SecretStr('') │ │
langflow | │ ╰──────────────────────────────────────────────────────────────────────────╯ │
langflow | │ │
langflow | │ /app/.venv/lib/python3.12/site-packages/langflow/services/settings/utils.py: │
langflow | │ 42 in read_secret_from_file │
langflow | │ │
langflow | │ 39 │
langflow | │ 40 │
langflow | │ 41 def read_secret_from_file(path: Path) -> str: │
langflow | │ ❱ 42 │ with path.open("r") as f: │
langflow | │ 43 │ │ return f.read() │
langflow | │ 44 │
langflow | │ │
langflow | │ ╭─────────────────── locals ───────────────────╮ │
langflow | │ │ path = PosixPath('/app/langflow/secret_key') │ │
langflow | │ ╰──────────────────────────────────────────────╯ │
langflow | │ │
langflow | │ /usr/local/lib/python3.12/pathlib.py:1013 in open │
langflow | │ │
langflow | │ 1010 │ │ """ │
langflow | │ 1011 │ │ if "b" not in mode: │
langflow | │ 1012 │ │ │ encoding = io.text_encoding(encoding) │
langflow | │ ❱ 1013 │ │ return io.open(self, mode, buffering, encoding, errors, newli │
langflow | │ 1014 │ │
langflow | │ 1015 │ def read_bytes(self): │
langflow | │ 1016 │ │ """ │
langflow | │ │
langflow | │ ╭───────────────────── locals ──────────────────────╮ │
langflow | │ │ buffering = -1 │ │
langflow | │ │ encoding = 'locale' │ │
langflow | │ │ errors = None │ │
langflow | │ │ mode = 'r' │ │
langflow | │ │ newline = None │ │
langflow | │ │ self = PosixPath('/app/langflow/secret_key') │ │
langflow | │ ╰───────────────────────────────────────────────────╯ │
langflow | ╰──────────────────────────────────────────────────────────────────────────────╯
langflow | PermissionError: [Errno 13] Permission denied: '/app/langflow/secret_key'
langflow exited with code 0
`
Beta Was this translation helpful? Give feedback.
All reactions