Fixes: 1) Replace `IntegerField` with `PositiveIntegerField` for product image priority to enforce positive values.
Extra: 1) Optimize imports for consistent formatting; 2) Clarify logging messages in tasks; 3) Minor docstring and help text updates.
Fixes: 1) Correct line references in locale files for consistency;
Extra: Improve formatting and alignment of string segments for clarity and maintainability;
Fixes: 1) Resolve annotations compatibility with mypy `type: ignore` adjustments; 2) Correct `resolve_price_with_currency` method to ensure proper float returns; 3) Handle scenarios for empty or null queryset in vendor methods.
Extra: 1) Refactor utility functions for better type annotations and robustness; 2) Minor formatting corrections and removal of redundant mypy strict setting; 3) Improve method return types for consistency.
Fixes: 1) Avoid unused variable warning in `update_products_task` by removing exception variable `vie`; 2) Add missing imports for `logging` and `traceback` in `payments/signals.py`;
Extra: 1) Minor formatting fix in `dbbackup.py` to consolidate FTP URL string construction; 2) Remove unnecessary newline in `core/vendors/__init__.py`.
Fixes: 1) Corrected `ForeignKey` type assertions across models; 2) Resolved typos and formatting inconsistencies in `.env` and README; 3) Fixed explicit boolean checks in user manager methods.
Extra: Updated type hints in multiple models, serializers, and views.
Fixes: 1) Refine logic in vendor category and brand handling to correctly handle multiple active/inactive entries;
Extra: 1) Add missing import for `registry` in Elasticsearch module; 2) Minor cleanup and spacing adjustments in Elasticsearch and vendor modules.
1) Add Celery shared_task decorator to `update_stock` method for asynchronous execution.
Fixes:
1) Replace direct `update_stock()` calls with `update_stock.delay()` to enable task queuing.
Extra:
1) Add missing import for `shared_task` in `core/vendors/__init__.py`.
1) Add error handling with logger and custom error message for holiday API requests;
Fixes:
(none);
Extra:
1) Replace direct API response raising with try-except block for better robustness and logging;
Add error handling during the stock update process to log and skip problematic vendors without halting execution. Additionally, ensure `get_vendor_instance` only returns active vendors, raising an error if the vendor is inactive. This improves system resilience and data integrity.
Updated the API version from 2.5.0 to 2.6.0 in the DRF settings for consistency across configurations. Reformatted migration files for better readability, ensuring consistency in code style and improving maintainability. These changes do not alter functionality but enhance clarity and documentation.
Previously, an "example key" could mistakenly pass the check, leading to potential misuse. This update ensures features are disabled if the API key is invalid or set to default.
Change promotions to inactive instead of deleting them to maintain data integrity. Adjust Celery logging levels to be DEBUG/INFO based on the DEBUG setting, improving log granularity during development and clarity in production.