Commit graph

4,743 commits

Author SHA1 Message Date
Gabriel Luiz Freitas Almeida
e8846fc568
Merge branch 'dev' into implement_loguru 2023-09-04 19:17:21 +00:00
Gabriel Luiz Freitas Almeida
28b487dc33 🔧 fix(manager.py): change logger.warn to logger.warning for consistency and clarity
🔧 fix(logger.py): change log_file parameter type annotation to Optional[Path] to indicate that it is an optional argument
2023-09-04 16:15:41 -03:00
Gabriel Luiz Freitas Almeida
7e336bbee6 🐛 fix(logger.py): change log_level variable to uppercase to improve consistency and semantics 2023-09-04 16:13:01 -03:00
Gabriel Luiz Freitas Almeida
3c153c8b1b
Improves endpoint dependency usage (#862) 2023-09-04 19:06:31 +00:00
Gabriel Luiz Freitas Almeida
58c3e5e9dc refactor: replace loggers with loguru 2023-09-04 11:38:39 -03:00
Gabriel Luiz Freitas Almeida
87eb8b1a95 🔧 chore(logger.py): refactor logger configuration to use loguru library and improve log formatting 2023-09-04 11:35:22 -03:00
Gabriel Luiz Freitas Almeida
5f98f0bbd9 📦 chore(pyproject.toml): add loguru package as a dependency for improved logging capabilities 2023-09-04 11:34:38 -03:00
Gabriel Luiz Freitas Almeida
2ab3fcb28a 🐛 fix(base.py): set default value of frontend_node to None in ValidatePromptRequest class to avoid potential NoneType errors
🐛 fix(validate.py): set frontend_node to None instead of an empty dictionary in post_validate_prompt function to align with the default value in ValidatePromptRequest class
2023-09-04 10:04:21 -03:00
Gabriel Luiz Freitas Almeida
dc1a5c81a1
added missing backslashes to api key request definition and bugfix to migration script (#858) 2023-09-04 12:36:17 +00:00
root
b1c24054c6 added indent to index dropping on non-existing table 2023-09-04 11:41:34 +00:00
Gabriel Luiz Freitas Almeida
53c5a3ccde 🐛 fix(base.py): make frontend_node field in PromptValidationResponse optional to handle cases where it is not provided 2023-09-04 07:05:10 -03:00
Gabriel Luiz Freitas Almeida
833fb4ad8f 🔀 chore(utils.py): add type hint for get_session() function to indicate it returns a generator instead of a Session object 2023-09-04 07:01:05 -03:00
Gabriel Luiz Freitas Almeida
43864904ef 🔧 chore(Makefile): update mypy command to only check files in src/backend/langflow directory to improve performance and reduce noise in the output 2023-09-04 07:00:38 -03:00
Gabriel Luiz Freitas Almeida
37ebbf4e65 Formatting 2023-09-04 06:42:41 -03:00
Gabriel Luiz Freitas Almeida
84a0d3acb3 🔧 fix(chat.py): remove unused imports and type hints to improve code readability
 feat(chat.py): add dependency injection for ChatManager in chat and init_build routes to improve modularity and testability
🔧 fix(chat.py): remove duplicate instantiation of ChatManager in chat and init_build routes to improve efficiency
🔧 fix(chat.py): remove duplicate instantiation of ChatManager in stream_build route to improve efficiency
🔧 fix(utils.py): add missing import for ChatManager in get_chat_manager function
2023-09-04 06:42:01 -03:00
Gabriel Luiz Freitas Almeida
2bbbf44b39 🐛 fix(endpoints.py): change get_all function signature to include settings_manager as a dependency to improve code readability
🐛 fix(flows.py): change update_flow function signature to include settings_manager as a dependency to improve code readability
🐛 fix(login.py): change auto_login function signature to include settings_manager as a dependency to improve code readability
🐛 fix(users.py): change add_user function signature to include session as a dependency to improve code readability
🐛 fix(users.py): change read_all_users function signature to include session as a dependency to improve code readability
🐛 fix(users.py): change patch_user function signature to include session as a dependency to improve code readability
🐛 fix(users.py): change delete_user function signature to include session as a dependency to improve code readability
🐛 fix(users.py): change add_super_user_for_testing_purposes_delete_me_before_merge_into_dev function signature to include session as a dependency to improve code readability
2023-09-04 06:41:34 -03:00
root
6d6ab9a874 added missing backslashes to api key request definition 2023-09-02 21:36:49 +00:00
Cristhian Zanforlin Lousa
1b317ee4c9 Merge branch 'dev' of https://github.com/logspace-ai/langflow into dev 2023-08-31 16:07:53 -03:00
Cristhian Zanforlin Lousa
d16456d795 🎨 style(headerComponent): add cursor-pointer class to admin page and logout menu items for better user experience 2023-08-31 16:07:48 -03:00
Gabriel Luiz Freitas Almeida
cde00160b8
Adds teardown logic for database and other services (#852) 2023-08-31 14:51:44 +00:00
Gabriel Luiz Freitas Almeida
594dfb13c1 🔀 chore(manager.py): ignore type error for session_manager_factory import to prevent linting errors 2023-08-31 11:49:51 -03:00
Lucas Oliveira
06e5e7dc4c Formatting issues 2023-08-31 11:49:00 -03:00
Lucas Oliveira
d9323cb9a7 pre-commit make init fix 2023-08-31 11:49:00 -03:00
Gabriel Luiz Freitas Almeida
156d8bb089 🔧 chore(auth.py): remove unnecessary comments and fields in AuthSettings class
🔧 chore(manager.py): remove unnecessary arguments in AuthSettings instantiation
2023-08-31 11:43:41 -03:00
Lucas Oliveira
fc96c1c728
Feat: Create Dropdown Button component (#840)
This PR introduces a new **DropdownButton** component that enables the
creation of interactive dropdown buttons in our application. The
dropdown button provides a user-friendly way to present multiple options
while maintaining a clean and compact interface.
2023-08-31 11:42:27 -03:00
Lucas Oliveira
8fedf9562f Fixed usability issues on import json method 2023-08-31 11:38:40 -03:00
Gabriel Luiz Freitas Almeida
c7b500dd5c 🔧 fix(base.py): fix comment indentation for better readability
🔧 fix(users.py): fix code formatting and indentation for better readability
2023-08-31 11:27:45 -03:00
Gabriel Luiz Freitas Almeida
4010f5669e 🔧 chore(pyproject.toml): add types-pywin32 as a dependency to support Windows-specific functionality 2023-08-31 11:17:38 -03:00
Gabriel Luiz Freitas Almeida
942c489552 🐛 fix(utils.py): change file mode from "rb" to "r" when reading secret from file to fix incorrect file mode 2023-08-31 11:17:28 -03:00
Gabriel Luiz Freitas Almeida
9eca124b17 🐛 fix(utils.py): raise HTTPException with status code 400 and detail message when FIRST_SUPERUSER credentials are missing in api_key_security function
🐛 fix(utils.py): raise credentials_exception when SECRET_KEY is None in get_current_user function
🐛 fix(utils.py): raise HTTPException with status code 400 and detail message when FIRST_SUPERUSER credentials are missing in create_user_longterm_token function
🐛 fix(auth.py): set SECRET_KEY default value to empty string and disallow mutation in AuthSettings class
🐛 fix(auth.py): set FIRST_SUPERUSER and FIRST_SUPERUSER_PASSWORD as optional fields with default values and disallow mutation in AuthSettings class
🐛 fix(manager.py): raise ValueError when CONFIG_DIR is not set in settings
2023-08-31 11:17:16 -03:00
Gabriel Luiz Freitas Almeida
8429f3fe72 🐛 fix(chat.py): fix typo in variable name 'messsage' to 'message' for better readability
🔧 chore(chat.py): refactor error handling in chat websocket to improve code clarity and maintainability
2023-08-31 11:16:52 -03:00
Gabriel Luiz Freitas Almeida
269cb9bc53 🐛 fix(__main__.py): pass the session as a keyword argument 'db' to the create_super_user function for clarity and consistency
🐛 fix(test_user.py): pass the session as a keyword argument 'db' to the create_super_user function for clarity and consistency
2023-08-31 11:16:39 -03:00
Lucas Oliveira
fc0e868515 Fixed UI of Dropdown Button 2023-08-31 11:15:12 -03:00
Gabriel Luiz Freitas Almeida
d8c7450576 🔧 chore(test_user.py): refactor super_user fixture to use auth settings from settings manager for username and password
🔧 chore(test_user.py): refactor super_user fixture to use auth settings from settings manager for username and password in create_super_user function call
2023-08-31 10:55:04 -03:00
Lucas Oliveira
d2eb87d44b Merge remote-tracking branch 'origin/dev' into dropdownButton_component 2023-08-31 10:43:28 -03:00
Lucas Oliveira
66752b61ea Merge branch 'dev' into dropdownButton_component 2023-08-31 10:42:19 -03:00
Lucas Oliveira
a9f3588651
Reset flows cache when logged out (#844) 2023-08-31 10:42:12 -03:00
Lucas Oliveira
59bbad7db1
UI Fixes for branch Login (#849) 2023-08-31 10:41:51 -03:00
Gabriel Luiz Freitas Almeida
8d96c32c2b 🔧 chore(manager.py): add teardown method to DatabaseManager class for cleaning up the database
🔧 chore(manager.py): remove default superuser if auto_login is enabled during teardown to ensure clean database state
2023-08-31 10:21:03 -03:00
Gabriel Luiz Freitas Almeida
29a616bc77 🐛 fix(utils.py): remove unnecessary code and simplify create_super_user function
 feat(utils.py): refactor create_user_longterm_token to use settings_manager for username and password
2023-08-31 10:20:53 -03:00
Gabriel Luiz Freitas Almeida
91ea879e50 🔧 fix(base.py): make Service class inherit from ABC to make it an abstract base class
 feat(manager.py): add debug log messages for service creation and update to improve debugging
 feat(manager.py): add teardown method to ServiceManager to teardown all services and clear state
 feat(manager.py): add teardown_services function to teardown all services and clear state
2023-08-31 10:20:40 -03:00
Gabriel Luiz Freitas Almeida
08407abe9a 🔧 chore(main.py): add teardown_services function to be called on app shutdown event to properly clean up resources 2023-08-31 10:20:20 -03:00
Lucas Oliveira
03599541c2 Added user dropdown instead of buttons 2023-08-31 08:20:23 -03:00
Lucas Oliveira
ee27839009 Added skeleton when loading all flows 2023-08-30 22:56:43 -03:00
anovazzi1
19dd994c12 chore(frontend): update dependencies in package.json
- Update "@emotion/react" to version "^11.11.1"
- Update "@emotion/styled" to version "^11.11.0"
- Update "@headlessui/react" to version "^1.7.17"
- Update "@heroicons/react" to version "^2.0.18"
- Update "@mui/material" to version "^5.14.7"
- Update "@tabler/icons-react" to version "^2.32.0"
- Update "@tailwindcss/forms" to version "^0.5.6"
- Update "ace-builds" to version "^1.24.1"
- Update "axios" to version "^1.5.0"
- Update "class-variance-authority" to version "^0.6.1"
- Update "dompurify" to version "^3.0.5"
- Update "esbuild" to version "^0.17.19"
- Update "react-error-boundary" to version "^4.0.11"
- Update "react-icons" to version "^4.10.1"
- Update "react-router-dom" to version "^6.15.0"
- Update "react-tabs" to version "^6.0.2"
- Update "react-tooltip" to version "^5.21.1"
- Update "rehype-mathjax" to version "^4.0.3"
- Update "shadcn-ui" to version "^0.2.3"
- Update "tailwind-merge" to version "^1.14.0"
- Update "tailwindcss-animate" to version "^1.0.7"

chore(frontend): update devDependencies in package.json

- Update "@swc/cli" to version "^0.1.62"
- Update "@swc/core" to version "^1.3.80"
- Update "@tailwindcss/typography" to version "^0.5.9"
- Update "@testing-library/jest-dom" to version "^5.17.0"
- Update "@testing-library/react" to version "^13.4.0"
- Update "@testing-library/user-event" to version "^13.5.0"
- Update "@types/lodash" to version "^4.14.197"
- Update "@types/node" to version "^16.18.46"
- Update "@types/react
2023-08-30 19:12:28 -03:00
anovazzi1
f30c818053
Improves secret key implementation (#846)
Secret key is now set once if not passed using the env variable and
saved into the CONFIG_DIR.
There are separate implementations depending on the OS
2023-08-30 19:08:19 -03:00
Cristhian Zanforlin Lousa
c06cfce385 🐛 fix(api.tsx): handle null values when calling login function to prevent potential errors 2023-08-30 19:02:52 -03:00
Gabriel Luiz Freitas Almeida
98dfc01934 🔒 refactor(auth.py): move SECRET_KEY logic to AuthSettings class to improve code organization and reusability
🔒 refactor(base.py): remove SECRET_KEY field from Settings class since it is now handled by AuthSettings class
🔒 refactor(manager.py): pass CONFIG_DIR to AuthSettings constructor when creating an instance
2023-08-30 18:58:12 -03:00
anovazzi1
60945ce883 added check to onCloseWebsocket event 2023-08-30 18:49:41 -03:00
Gabriel Luiz Freitas Almeida
3a90b07235 fix exception 2023-08-30 18:18:22 -03:00