Skip to content

1.5.7

⚙️ Patch 1.5.7 — Base Repricer: Cron webhook wiring, FBA/FBM sync, backend fixes & WS visibility

🚀 Summary

  • Frontend: Cron dialog now forwards an optional Discord webhook URL to the backend when scheduling the base repricer cron.
  • Backend: several fixes to FBA handling and recalc flow (persisting explicit ignore flags, safe JSON updates, and re-enabled recalc on FBA updates).
  • Operational: base repricer cron now syncs FBM details in addition to FBA, and FBA sync/export flows are more resilient when the base product pull is skipped.

✨ New Features

  • UI: Cron dialog captures and forwards an optional Discord webhook URL when creating/updating the base_repricer_cron job. This allows the background sync to publish an evaluation summary to Discord when provided.
  • Backend: Base repricer cron now also syncs FBM details (stock, package dimensions and related metadata) alongside FBA, making the cron a single-source sync for both fulfillment types.

🔧 Improvements

  • Observability: Confirmed how notifications.notify_clients() maintains an in-memory running_map snapshot so new WS clients can see active tasks; documented why very short or very long running tasks can be invisible in the widget.
  • FBA sync fallback: implemented a DB-backed fallback in process_sync_fba_skus so when the base product pull is skipped (sync_base_articles=False) we iterate FBADetails and apply stock_map and dim_map directly — creating base articles by ASIN when needed. This ensures stock and dimension updates are applied reliably.
  • backend ratelimiter increased to 1000 request per minute

  • UVP propagation: Manual UVP edits made via the base repricer UI now recursively apply to all related SKUs (bundle components, explicit child SKUs, and variant postfix matches). The backend discovers child SKUs via a breadth-first traversal and persists UVP changes to each affected SKU.

  • Immediate export: After a manual UVP change, the background task now recalculates and immediately exports the base SKU and all affected child SKUs to enabled platforms (Shopify, Kaufland, Otto and FBM). Each SKU is processed individually so websocket task notifications, per-SKU error handling, and export status updates are accurate.

🐛 Bug Fixes

  • Frontend: The CronDialog in BaseArticles.jsx now receives and forwards discordWebhook/onDiscordWebhookChange, ensuring optional webhooks are persisted and sent to scheduled jobs.
  • Backend: PUT /articles/{sku}/fba now triggers a recalculation after persisting changes so updates to international_pricing (including ignore toggles) are reflected immediately in the UI and export phase.
  • Backend: Hardened crud.repricer_article.update_fba_details to preserve arbitrary region-level keys (e.g., hazmat, order_fee), coerce and persist explicit ignore boolean values reliably, and replace the fragile raw SQL fallback with a safe ORM-level update to avoid psycopg2 binding/syntax errors.
  • Recalculation: when use_min_max_rules is enabled we now compute profit/margin fields from the existing target_price (min/max/manual overrides) without making unnecessary SP-API calls to derive a new target price.
  • Export: international_pricing.ignore is now respected consistently during export; regions marked ignore: true are skipped.
  • Recalculation/Export: Preserved pending export status (UPDATE_NEEDED) across recalculations for FBM, Shopify and Kaufland so that pending updates are not unintentionally downgraded to ACTIVE. This prevents concurrent or subsequent recalculation runs from clearing export flags and ensures exports remain queued until an explicit successful export occurs.
  • UVP export fix: Fixed an issue where manual UVP updates on base SKUs were not exported to variants and bundle children. The UVP workflow now includes recursive DB propagation and per-SKU exports so platform syncs happen immediately for all affected SKUs.

📁 Files changed

  • frontend/src/pages/MultiRepricer/Tabs/BaseArticles/BaseArticles.jsx — Pass discordWebhook and onDiscordWebhookChange props into CronDialog so webhook URLs are saved and forwarded.
  • backend/service_multi-repricer/app/api/v1/endpoints/repricer_articles.py — Re-enabled FBA recalculation after PUT /{sku}/fba and ensured cron args forward webhook values.
  • backend/service_multi-repricer/app/crud/repricer_article.py — Hardened update_fba_details merge logic and safe JSON persistence of international_pricing.
  • backend/service_multi-repricer/app/api/v1/endpoints/fba_articles.py — Implemented DB fallback for process_sync_fba_skus (apply stock_map/dim_map when items empty) and adjusted recalc logic to update profit fields when use_min_max_rules is used.
  • docs/docs/patchnotes/1.5/1.5.7.md — This patchnotes file (updated).