-
Notifications
You must be signed in to change notification settings - Fork 79
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
Fixed - Collection is getting deleted even after it is attached to prompt action. #1070
Fixed - Collection is getting deleted even after it is attached to prompt action. #1070
Conversation
nupur-khare
commented
Oct 31, 2023
- Added unit and integration test cases.
- Fixed test cases.
…ompt action. 1. Added unit and integration test cases. 2. Fixed test cases.
…ompt action. 1. Added unit and integration test cases. 2. Fixed test cases.
@@ -949,7 +949,7 @@ def check(cls, values): | |||
|
|||
class CognitionSchemaRequest(BaseModel): | |||
metadata: List[ColumnMetadata] = None | |||
collection_name: str | |||
collection_name: constr(to_lower=True, strip_whitespace=True) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this change must also go for collection field in CognitiveDataRequest
@@ -1893,14 +2004,15 @@ def _mock_get_bot_settings(*args, **kwargs): | |||
payload = { | |||
"data": {"details": "AWS"}, | |||
"content_type": "json", | |||
"collection": "Details" | |||
"collection": "details" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the code must handle it, why was it changed explicitly?
…ompt action. 1. Added unit and integration test cases. 2. Fixed test cases.
…ompt action. 1. Added unit and integration test cases. 2. Fixed test cases.
…ompt action. 1. Added unit and integration test cases. 2. Fixed test cases.
@@ -1272,25 +1273,36 @@ def _mock_get_bot_settings(*args, **kwargs): | |||
assert actual["data"]["_id"] | |||
assert actual["error_code"] == 0 | |||
|
|||
cognition_schema = CognitionSchema.objects(bot=pytest.bot, id=pytest.schema_id).get() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why was list schema api called here?
please call rest api
…ompt action. 1. Added unit and integration test cases. 2. Fixed test cases.
* Added changes to log whatsapp webhook response in db. * Added test cases to fix coverage issue. * Added test cases to fix coverage issue. * Added test cases to fix coverage issue. * Added test cases in the chat_service_test. * Added test cases in the chat_service_test. --------- Co-authored-by: Mahesh <[email protected]>
…ompt action. 1. Added unit and integration test cases. 2. Fixed test cases.