Skip to content

Implement product_csr app #74

Open
kajal-082 wants to merge 19 commits into
Rippling:mainfrom
kajal-082:kajal-new-branch
Open

Implement product_csr app #74
kajal-082 wants to merge 19 commits into
Rippling:mainfrom
kajal-082:kajal-new-branch

Conversation

@kajal-082
Copy link
Copy Markdown

@kajal-082 kajal-082 commented Mar 24, 2026

  • Added product and productCategory modules following hexagonal architecture
  • Implemented core business logic in service layer
  • Created unit tests for service validation
  • Added seed files for initial data setup

Note

Medium Risk
Adds new HTTP endpoints plus MongoEngine persistence and seed tooling, and changes runtime configuration (dotenv, MongoDB container creds, DB setup), which can affect local/prod deployment behavior. Risk is moderate due to new data paths and hard-coded Mongo connection settings.

Overview
Introduces two new Django apps: product (in-memory CRUD endpoints under /product/products/...) and product_csr (MongoDB-backed product/category API under /product-csr/..., including filtering, category assignment, and CSV bulk upload).

Updates Django configuration to load env vars, register the new apps, wire new URL routes, and connect via mongoengine, and adjusts the dev docker-compose.yaml Mongo image/version and root credentials. Adds seed utilities and a management command for product_csr, along with unit and integration tests covering service validation and API behavior.

Written by Cursor Bugbot for commit 8ef7341. Configure here.

Copy link
Copy Markdown

@cursor cursor Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 6 potential issues.

Fix All in Cursor

Bugbot Autofix is ON, but it could not run because the branch was deleted or merged before autofix could start.

Comment @cursor review or bugbot run to trigger another review on this PR

Comment thread backend/python/product/views.py
Comment thread backend/python/django_app/settings.py Outdated
db="product_db",
host="localhost",
port=27017,
) No newline at end of file
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

MongoDB connect ignores configured environment variables

High Severity

MONGO_USER, MONGO_PASS, MONGO_PORT, and MONGO_HOST are defined from environment variables but never used. The connect() call hardcodes host="localhost" and port=27017, while docker-compose exposes port 27019 and requires authentication. The app will fail to connect to MongoDB in any standard deployment.

Additional Locations (1)
Fix in Cursor Fix in Web

Comment thread backend/python/product_csr/views.py
Comment thread backend/python/product_csr/views.py
Comment thread backend/python/product/views.py
Comment thread backend/python/django_app/settings.py Outdated
Comment thread .vscode/settings.json
Comment thread backend/python/django_app/settings.py Outdated
Comment thread backend/python/product_csr/models.py
Comment thread backend/python/product/views.py
Comment thread backend/python/product_csr/tests/test_product_service.py Outdated
@antassinha
Copy link
Copy Markdown
Member

We can remove node modules from the PR

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants