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

Integration of MongoDB for feedbacks #106

Closed
wants to merge 4 commits into from

Conversation

Kannav02
Copy link
Collaborator

This PR aims to fix a small part of the issue #75

The objective of this PR can be tracked via the following points

  • Correcting the requirements to now include pyMongo
  • Integrating mongoDB as the database to which the feedback will go back
  • referencing different contexts based on their ids to the main table that is the feedback table

To view/test these changes, follow the following steps

  • run the frontend with the mock server
  • specify the MONGO_DB_URI to which the feedback and the context would be fed back to
  • enter a prompt
  • submit a feedback
  • now access the mongoDB instance and you will see the data there, including the timestamp of submissions

This is what I got when I ran this twice

Screenshot 2024-11-25 at 9 49 49 PM
Screenshot 2024-11-25 at 9 50 04 PM

Follow up question, are there limited number of contexts that we have right now for this application, if yes , I might optimise the database insertions to rather not insert the pre-existing contexts, but to reference them and insert their ids into the main table

Thank you !

- schema corrected for the database
- parameters included in the main submit_feedback function
- insertion corrected to utilise the correct datetime.now() function

Signed-off-by: Kannav02 <[email protected]>
- added the function to now submit feedback back to mongoDB
- corrected the sys path to now include common as a package, workaround , kind of like a pseudopackage

Signed-off-by: Kannav02 <[email protected]>
@Kannav02
Copy link
Collaborator Author

@luarss, i believe the commands for the CI are not propagating to the fork again, do you want me to again push the branch to the upstream?

@luarss
Copy link
Collaborator

luarss commented Nov 26, 2024

Yes please

@luarss luarss closed this Nov 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants