FreshRouteX

Perishability-Aware platform

Wild BugsShipped October 15, 2026#general#security
Repo
FreshRouteX banner

About

## Challenges we ran into

BUG-001 (P2 - Test Runner): The React forwardRef Button component was tested using function call syntax instead of React.createElement, which caused test runner failures and was resolved by updating primitives.test.ts to instantiate components with React.createElement.

BUG-002 (P1 - UI / Types): A missing clsx import in OperationsOverview.tsx caused a TypeScript TS2304 compile failure, which was resolved by adding import clsx from "clsx" alongside restored dialog imports.

BUG-003 (P3 - Linter): JSX children containing literal // characters in marketing components were flagged by ESLint's react/jsx-no-comment-textnodes rule, which was resolved by escaping the technical slashes inside string literals {" // "}.

BUG-004 (P1 - Database / DDL): Windows PowerShell Out-File -Encoding utf8 prepended a Byte Order Mark (\uFEFF) to SQL files, triggering PostgreSQL syntax errors during migration execution, which was resolved by stripping the BOM in pglite.ts and rewriting the migration file without a BOM.

BUG-005 (P2 - TypeScript): The calculateRouteTransportCost function rejected string representations of decimal inputs, which was resolved by updating the interfaces in data-foundation.service.ts to accept number | Decimal | string.

BUG-006 (P2 - Test Runner): Parallel test execution with in-process PGlite WASM caused memory contention and hook timeouts, which was resolved by setting fileParallelism: false and extending test timeouts to 30,000ms in vitest.config.ts.

BUG-007 (P2 - UI / Types): Deep import paths to @/components/ui/Button and incorrect button/badge props (icon instead of leftIcon, missing loading, unmapped variants) caused TypeScript errors, which were resolved by consolidating imports to @/components/ui, updating props, and aligning badge variants.

BUG-008 (P1 - SCSS / Styles): Undefined $color-slate-... variables in SCSS design tokens caused Next.js Webpack production build failures, which were resolved by adding the complete slate neutral palette scale ($color-slate-50 through $color-slate-950) to src/styles/_tokens.scss.

BUG-009 (P1 - UI Primitives): Radix UI <Slot> in Button threw an error stating that the slot failed to slot onto its children when asChild was enabled alongside icons, which was resolved by wrapping children in <Slottable> from @radix-ui/react-slot.

BUG-010 (P1 - Next.js RSC): PlaceholderPage had an unnecessary "use client" directive that caused Next.js to fail serialization when passing Lucide icon components from Server Component pages, which was resolved by converting PlaceholderPage.tsx into a pure React Server Component.

BUG-011 (P2 - Planning Engine): Dynamic markdowns were not activated when batch remaining shelf life satisfied secondary channel SLAs without a primary breach, and reason codes only contained a single primary code, which was resolved by updating feasibility.ts to evaluate decay-based markdowns for secondary discount channels and populating composite reasonCodes.

BUG-012 (P2 - Economic Evaluator): The evaluator accessed leftover.remainingKg instead of leftover.unallocatedKg, triggering Decimal instantiation errors, and test destinations had an unmapped warehouseId, which were resolved by accessing leftover.unallocatedKg with batch unit costs and removing warehouseId from test destinations.

BUG-013 (P2 - App Router / Types): An import identifier mismatch occurred in /api/discounts/simulate/route.ts where simulatePlanDiscounts was imported instead of simulatePlanWithDiscounts, which was resolved by correcting the import and function call to simulatePlanWithDiscounts.

BUG-014 (P2 - UI / TypeScript): Property profitSlopePerUnit was incorrectly referenced instead of profitSensitivitySlopeUsdPerUnit on SensitivityResult in ScenarioLabCockpit.tsx, which was resolved by updating the property access.

BUG-015 (P2 - Engine / Contracts): A redundant top-level planningTime was passed to evaluateScenario in scenario-engine.ts, which was resolved by passing a solver configuration object with embedded planningTime to satisfy ScenarioEvaluationOptions.

BUG-016 (P2 - Test Runner): Tests in tests/engine/scenario-engine.test.ts attempted to access .id on a pure EnginePlanOutput object in tests 3, 4, and 5, which was resolved by passing an explicit plan ID string ("plan-test-01") into executeScenarioRun.

BUG-017 (P1 - Multi-Tenancy / SQL): The updateDemand function in destinations.service.ts fetched orders without checking the tenant organizationId, creating a multi-tenancy vulnerability, which was resolved by adding AND "organizationId" = $2 and 404 validation.

BUG-018 (P2 - UI / Shell): AppHeader.tsx used blocking browser alert() dialogs on search click and notification clicks, which was resolved by implementing functional global search navigation to /app/inventory and an interactive notifications popover.

BUG-019 (P1 - Security / CSV): CSV file uploads lacked payload file size limits and maximum row boundaries, which was resolved by enforcing a 5MB payload limit (M

## The problem it solves

FreshRouteX is an enterprise-grade Software-as-a-Service (SaaS) platform engineered for wholesale produce distributors, cold-chain logistics networks, and agricultural hubs. It optimizes perishable produce allocation using First-Expired, First-Out (FEFO) decay curves, enforces strict buyer dock Remaining Shelf Life (RSL) Service Level Agreements (SLAs), and recommends explainable dynamic markdowns to liquidate at-risk inventory before expiration.

Every distribution plan is mathematically benchmarked against a documented FIFO baseline model, delivering transparent, auditable proof of spoilage reduction, gross margin retention, and fulfillment gains.

Screenshots

FreshRouteX screenshot 1FreshRouteX screenshot 2FreshRouteX screenshot 3FreshRouteX screenshot 4FreshRouteX screenshot 5

Team

From the public Devfolio project page. Votes, swipes and the judge score are hackfeed's own.

AI judge

Not judged yet. A free model reads this page, compares it with similar projects and this event's winners, then scores it and says what would make it win.

Still being built?

Not checked yet.

Swipe stats

0upvotes
0skips
0saves

Discussion 0

No comments yet. Ask the team something, or say what you'd use it for.

Posting as a guest. Plain text, 1,000 characters max.

Already built nearby

Closest projects by meaning and shared words. Similar isn't the same as copied: read them.