Gabriel Luiz Freitas Almeida
b33878088e
🐛 fix(service.py): handle case when response is None to prevent UnboundLocalError
...
🐛 fix(service.py): handle case when response is None to prevent UnboundLocalError and raise ValueError with error message from response if available
2023-10-23 23:46:07 -03:00
Gabriel Luiz Freitas Almeida
8b9267b2e8
🐛 fix(store.py): import missing schema classes in store.py to fix NameError
...
✨ feat(store.py): change response models for list_components and read_component endpoints to use new schema classes for improved consistency and clarity
🐛 fix(schema.py): add missing ListComponentResponse and DownloadComponentResponse classes to schema.py to fix NameError
✨ feat(service.py): change return types of list_components and download methods in StoreService to use new schema classes for improved consistency and clarity
2023-10-23 23:37:08 -03:00
Gabriel Luiz Freitas Almeida
2b9ac7c3ac
🔧 chore(store.py): add status code 201 to the response of create_component endpoint for better HTTP semantics
2023-10-23 23:07:11 -03:00
Gabriel Luiz Freitas Almeida
e6ae03105f
🐛 fix(store.py): pass component object instead of dict to store_service.upload() to fix data type mismatch
...
🐛 fix(service.py): convert parent UUID to string before sending to store in upload() method to fix data type mismatch
2023-10-23 22:56:15 -03:00
Gabriel Luiz Freitas Almeida
ab86ddc38a
🐛 fix(service.py): fix index out of range error when getting component in download method
2023-10-23 22:09:01 -03:00
Gabriel Luiz Freitas Almeida
88203b9178
🐛 fix(store.py): change method name from get to download in store_service to improve clarity and consistency
2023-10-23 21:29:53 -03:00
Gabriel Luiz Freitas Almeida
464ba02de8
🔄 refactor(schema.py): rename 'user_created' field to 'user_name' for better clarity and consistency
2023-10-23 21:25:20 -03:00
Gabriel Luiz Freitas Almeida
c695a4fd61
🔧 chore(store.py): add "user_created.name" and "is_component" fields to the list of fields returned by list_components() function
...
🔒 refactor(store.py): refactor the logic to handle the case when store_api_Key is not provided
2023-10-23 21:19:28 -03:00
Gabriel Luiz Freitas Almeida
6e8a98d6e3
🔧 chore(schema.py): add 'is_component' field to StoreComponentCreate schema for better data modeling and flexibility
2023-10-23 20:43:13 -03:00
Gabriel Luiz Freitas Almeida
b968fae19e
🔥 refactor(store.py): remove unused code and endpoint 'fork_component' to improve code readability and maintainability
2023-10-23 20:42:45 -03:00
Gabriel Luiz Freitas Almeida
ee0c11b4a6
🐛 fix(store.py): add missing import for FlowCreate and FlowRead models
...
✨ feat(store.py): add support for fetching specific fields when listing components
✨ feat(store.py): add support for forking components from the store
✨ feat(store.py): add support for searching components with various filters and sorting options
🐛 fix(schema.py): add missing parent field to ComponentResponse and StoreComponentCreate models
2023-10-23 17:15:19 -03:00
Gabriel Luiz Freitas Almeida
f060155fe6
🔧 chore(utils.py): refactor setup_superuser and teardown_superuser functions to improve readability and remove unnecessary code duplication
...
🔧 chore(utils.py): update teardown_superuser function to only remove default superuser if AUTO_LOGIN is set to False
2023-10-20 18:25:42 -03:00
Gabriel Luiz Freitas Almeida
09d4ee43cf
🔧 fix(store.py): remove duplicate list_components endpoint to avoid conflicts and improve code organization
...
✨ feat(store.py): add new list_components endpoint to retrieve a paginated list of components from the store
2023-10-20 11:26:08 -03:00
Gabriel Luiz Freitas Almeida
4c8550579d
🐛 fix(service.py): remove unnecessary try-except block and improve error handling in GET request
2023-10-20 11:08:38 -03:00
Gabriel Luiz Freitas Almeida
3b14cdbe9f
🐛 fix(service.py): catch all exceptions when raising ValueError in the search method to provide more informative error message
2023-10-20 11:06:16 -03:00
Gabriel Luiz Freitas Almeida
b7aa3274f8
🐛 fix(service.py): improve error handling in StoreService search method
...
✨ feat(service.py): change default sort parameter in StoreService search method to sort by likes in descending order
2023-10-20 11:02:38 -03:00
Gabriel Luiz Freitas Almeida
5667dd4540
🐛 fix(service.py): remove redundant assignment to params variable to fix incorrect behavior
2023-10-20 07:54:19 -03:00
Gabriel Luiz Freitas Almeida
51929df2b0
🐛 fix(service.py): remove redundant assignment to params variable
...
The redundant assignment to the params variable was removed to prevent overwriting the initial assignment.
2023-10-20 07:53:11 -03:00
Gabriel Luiz Freitas Almeida
4c6dc748a0
updates to colliding endpoints and search
2023-10-19 22:52:38 -03:00
Gabriel Luiz Freitas Almeida
09a1e332a5
update download method
2023-10-19 22:15:44 -03:00
Gabriel Luiz Freitas Almeida
54c2535b95
update schema for store endpoints
2023-10-19 22:14:45 -03:00
Gabriel Luiz Freitas Almeida
717334841f
add guard in case api key is a str
2023-10-19 22:14:11 -03:00
Gabriel Luiz Freitas Almeida
062a709151
fix fields and likes count
2023-10-19 22:13:39 -03:00
Gabriel Luiz Freitas Almeida
a3bede0187
Add store schema
2023-10-19 22:12:49 -03:00
Gabriel Luiz Freitas Almeida
5aed852bb0
🔧 chore(service.py): add aggregation parameter to store service API call to retrieve count of likes for each component
2023-10-19 18:14:56 -03:00
Gabriel Luiz Freitas Almeida
242f741567
🔧 refactor(store.py): remove unused imports and variables to improve code readability and maintainability
...
🔒 chore(store.py): add dependency injection for store API key retrieval to improve code modularity and testability
🔒 chore(store.py): add error handling for missing store API key to provide better user feedback
🔒 chore(store.py): refactor create_component, read_component, and list_components to use store API key from dependency injection instead of user object
2023-10-19 18:14:56 -03:00
Gabriel Luiz Freitas Almeida
cc6da7626e
🐛 fix(store.py): add validation to check if user has a store API key set before creating a component
2023-10-19 16:40:15 -03:00
Gabriel Luiz Freitas Almeida
ce955a82fe
🔨 refactor(store.py): change parameter name from 'component' to 'component_create' for clarity and consistency
...
🔨 refactor(store.py): change type annotation of 'component' parameter from 'Flow' to 'FlowCreate' to match the expected type
2023-10-19 16:34:19 -03:00
Gabriel Luiz Freitas Almeida
2a25865340
🐛 fix(flow.py): make 'is_component' field nullable to allow for optional values
2023-10-19 16:05:54 -03:00
anovazzi1
9c6930bd0f
Merge remote-tracking branch 'origin/dev' into saveComponent
2023-10-19 15:17:12 -03:00
Gabriel Luiz Freitas Almeida
b19c75dc3c
🐛 fix(api_key.py): rename api_key parameter to api_key_request in save_store_api_key function for clarity and consistency
2023-10-19 14:28:48 -03:00
Gabriel Luiz Freitas Almeida
c5262f39f2
🔒 refactor(api_key.py): update encrypt_api_key function call to pass settings_service as a keyword argument for clarity and maintainability
2023-10-19 14:08:51 -03:00
Gabriel Luiz Freitas Almeida
68e5cb4cce
Merge remote-tracking branch 'origin/main' into dev
2023-10-19 11:04:09 -03:00
Gabriel Luiz Freitas Almeida
f080c75d6a
🐛 fix(utils.py): add padding to SECRET_KEY before initializing Fernet to ensure it has the correct length
2023-10-19 10:57:52 -03:00
Gabriel Luiz Freitas Almeida
0286353695
🐛 fix(base.py): include vertex ID in error message to provide more context when building a node fails
2023-10-19 09:25:53 -03:00
Gabriel Luiz Freitas Almeida
d66944ae7e
🔧 chore(alembic): add store updates migration script
...
🔧 chore(alembic): add user id can be null in flow migration script
🔧 chore(flow.py): make is_component field nullable in Flow model
🔧 chore(flow.py): make user_id field nullable in Flow model
🔧 chore(service.py): add schema health check after running migrations and handle autogenerate diffs detected case
2023-10-18 23:23:10 -03:00
Gabriel Luiz Freitas Almeida
08bd16b8f2
🔧 chore(OpenAIConversationalAgent.py): enable handling of parsing errors in ConversationalAgent class
2023-10-18 22:14:14 -03:00
anovazzi1
8cc955c147
code format
2023-10-18 20:10:51 -03:00
Gabriel Luiz Freitas Almeida
a497eebab1
🔧 fix(__main__.py): set "no_proxy" environment variable to "*" to avoid error with gunicorn in macos
2023-10-18 19:57:28 -03:00
Gabriel Luiz Freitas Almeida
a65086c8e4
🐛 fix(alembic): add exception handling to prevent migration failure if columns already exist
2023-10-18 18:30:10 -03:00
anovazzi1
92a109b65c
Merge remote-tracking branch 'origin/dev' into saveComponent
2023-10-18 18:23:34 -03:00
Gabriel Luiz Freitas Almeida
52900503de
🔧 chore(alembic): make changes for the store
...
🔧 chore(api_key.py): remove unused imports and update save_store_api_key endpoint to use ApiKeyCreateRequest model
🔧 chore(schemas.py): add ApiKeyCreateRequest model
🔧 chore(store.py): remove unused imports and update imports in store.py
2023-10-18 18:09:24 -03:00
Gabriel Luiz Freitas Almeida
986f7202d2
🔧 chore(api_key.py): remove unused import 'httpx.get' to improve code cleanliness and reduce potential confusion
...
🐛 fix(api_key.py): fix import statement for 'get_current_active_user' function in 'auth_utils' module to resolve import error
2023-10-18 17:47:32 -03:00
Gabriel Luiz Freitas Almeida
f3c9e20bcc
🔧 refactor(store.py): remove unnecessary import and type hinting for StoreService
...
🔧 refactor(store.py): remove unnecessary type hinting for StoreService in create_component function signature
2023-10-18 17:46:56 -03:00
Gabriel Luiz Freitas Almeida
c30bb79d64
🐛 fix(deps.py): fix typo in get_store_service function to return the correct service type
2023-10-18 17:46:38 -03:00
Gabriel Luiz Freitas Almeida
215bc0d079
🔄 refactor(schema.py): rename MARKETPLACE_SERVICE enum value to STORE_SERVICE for consistency and clarity
2023-10-18 17:46:13 -03:00
Gabriel Luiz Freitas Almeida
67dddd7d75
🔧 fix(base.py): rename MARKETPLACE_URL to STORE_URL for better clarity and consistency in settings
...
🔧 fix(service.py): update reference to MARKETPLACE_URL to STORE_URL in StoreService class to reflect the change in settings
2023-10-18 17:44:57 -03:00
Gabriel Luiz Freitas Almeida
0fadad6f7d
🔧 fix(utils.py): import and add store_factory to the list of factories and dependencies
2023-10-18 17:16:42 -03:00
Gabriel Luiz Freitas Almeida
596fc8ed41
🔧 fix(api_key.py): import missing dependencies and fix import paths for auth_utils and get_current_active_user
...
✨ feat(api_key.py): add new route to save store API key for a user
2023-10-18 17:03:53 -03:00
Gabriel Luiz Freitas Almeida
878e158ac8
🔧 chore(alembic): add migration script for changes related to the store
...
🔧 chore(flow.py): add new field 'is_component' to the Flow model to support store functionality
🔧 chore(user.py): add new field 'store_api_key' to the User model to support store functionality
2023-10-18 17:03:15 -03:00