diff --git a/README.md b/README.md index 32171d7..e8cc1ed 100644 --- a/README.md +++ b/README.md @@ -30,4 +30,5 @@ make migrate # run DB migrations ## Operational Commands - View active environment on production: `sudo cat /opt/motovaultpro/config/deployment/state.json` - Switch traffic between environments on production: `sudo ./scripts/ci/switch-traffic.sh blue instant` -- View which container images are running: `docker ps --format 'table {{.Names}}\t{{.Image}}'` \ No newline at end of file +- View which container images are running: `docker ps --format 'table {{.Names}}\t{{.Image}}'` +- Flush all redis cache: `docker compose exec -T mvp-redis sh -lc "redis-cli FLUSHALL"` \ No newline at end of file diff --git a/docs/PROMPTS.md b/docs/PROMPTS.md index c216b27..45ac502 100644 --- a/docs/PROMPTS.md +++ b/docs/PROMPTS.md @@ -22,19 +22,22 @@ You are a senior software engineer specializsing in NodeJS, Typescript, front en - Make no assumptions. - Ask clarifying questions. - Ultrathink -- Troubleshoot UX problems when using Firefox *** CONTEXT *** - This is a modern web app for managing a vehicle fleet. It has both a desktop and mobile versions of the site that both need to maintain feature parity. It's currently deployed via docker compose but in the future will be deployed via k8s. - Read README.md CLAUDE.md and AI-INDEX.md and follow relevant instructions to understand this code repository in the context of this change. -- The vehicles dynamic drop downs are broken on Firefox. The dropdowns don't populate immediately and require selecting and unselecting options to work. -- There is a console error "Error: Can't find the actor ID for objects-manager from root or target actor's form. types.js:559:11" - *** CHANGES TO IMPLEMENT *** - Research this code base and ask iterative questions to compile a complete plan. - We will pair troubleshoot this. Tell me what logs and things to run and I will - +- The CSV import for the vehicle catalog fails with a basic file +- Here is the data trying to import +year,make,model,trim,engine_name,transmission_type + 1968,Chevrolet,Camaro,Rally Sport Coupe,V-8,Manual + 1969,Oldsmobile,Cutlass,F85,V-8,Automatic +- Here is the error. It appears it's failing the insert because there are duplicate V-8 engine items. This shouldn't cause a failure. This should be handled gracefully. +Row 0: Failed to upsert 1968 Chevrolet Camaro Rally Sport Coupe: duplicate key value violates unique constraint "engines_pkey" +Row 0: Failed to upsert 1969 Oldsmobile Cutlass F85: current transaction is aborted, commands ignored until end of transaction block diff --git a/frontend/src/features/vehicles/components/VehicleForm.tsx b/frontend/src/features/vehicles/components/VehicleForm.tsx index 4445569..5661133 100644 --- a/frontend/src/features/vehicles/components/VehicleForm.tsx +++ b/frontend/src/features/vehicles/components/VehicleForm.tsx @@ -14,7 +14,7 @@ import { VehicleImageUpload } from './VehicleImageUpload'; const vehicleSchema = z .object({ vin: z.string().optional(), - year: z.number().min(1980).max(new Date().getFullYear() + 1).optional(), + year: z.number().min(1950).max(new Date().getFullYear() + 1).optional(), make: z.string().optional(), model: z.string().optional(), engine: z.string().optional(),