Files
oikos/package.json
T
Ulas Kalayci 3f77fdb11d Fix Migration 30 code quality issues
C1 (CRITICAL): Refactor test-carddav.js to import migrations
- Import MIGRATIONS from server/db.js instead of duplicating SQL
- Export MIGRATIONS array from server/db.js
- Use better-sqlite3 to apply Migration 30 dynamically
- Ensures future changes to Migration 30 are reflected in tests

I1 (IMPORTANT): Add UNIQUE index on carddav_uid
- Create idx_contacts_carddav_uid_unique partial index
- Prevents duplicate CardDAV contacts per account+addressbook
- WHERE clause excludes NULL values (manual contacts allowed)
- Add test to verify unique constraint enforcement

I3 (IMPORTANT): Rename cardav → carddav (RFC 6352 compliance)
- Table: cardav_accounts → carddav_accounts
- Table: cardav_addressbook_selection → carddav_addressbook_selection
- Column: contacts.cardav_* → contacts.carddav_*
- Index: idx_cardav_* → idx_carddav_*
- Test file: test-cardav.js → test-carddav.js
- Package.json: test:cardav → test:carddav
- All test assertions updated

All 25 tests pass.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-04 10:55:30 +02:00

54 lines
2.7 KiB
JSON

{
"name": "oikos",
"version": "0.44.0",
"description": "Self-hosted family planner - calendar, tasks, shopping, meal planning, budget and more. Private, open-source, no subscription.",
"main": "server/index.js",
"type": "module",
"engines": {
"node": ">=22.0.0"
},
"scripts": {
"start": "node --import dotenv/config server/index.js",
"dev": "node --import dotenv/config --watch server/index.js",
"setup": "node --import dotenv/config setup.js",
"test:db": "node --experimental-sqlite test-db.js",
"test:dashboard": "node --experimental-sqlite test-dashboard.js",
"test:tasks": "node --experimental-sqlite test-tasks.js",
"test:shopping": "node --experimental-sqlite test-shopping.js",
"test:meals": "node --experimental-sqlite test-meals.js",
"test:calendar": "node --experimental-sqlite test-calendar.js",
"test:ncb": "node --experimental-sqlite test-notes-contacts-budget.js",
"test:ux-utils": "node test-ux-utils.js",
"test:modal-utils": "node --loader ./test-browser-loader.mjs test-modal-utils.js",
"test:kitchen-tabs": "node --loader ./test-browser-loader.mjs test-kitchen-tabs.js",
"test:reminders": "node --experimental-sqlite test-reminders.js",
"test:api": "node test-api.js",
"test:setup": "node test-setup.js",
"test:ics-parser": "node test-ics-parser.js",
"test:ics-sub": "node --experimental-sqlite test-ics-subscription.js",
"test:backup-scheduler": "node --experimental-sqlite test-backup-scheduler.js",
"test:caldav": "node --experimental-sqlite test-caldav-sync.js",
"test:carddav": "node --experimental-sqlite test-carddav.js",
"test": "node --experimental-sqlite test-db.js && node --experimental-sqlite test-dashboard.js && node --experimental-sqlite test-tasks.js && node --experimental-sqlite test-shopping.js && node --experimental-sqlite test-meals.js && node --experimental-sqlite test-calendar.js && node --experimental-sqlite test-notes-contacts-budget.js && npm run test:ux-utils && npm run test:modal-utils && npm run test:reminders && npm run test:api && npm run test:ics-parser && npm run test:ics-sub && npm run test:setup && npm run test:kitchen-tabs && npm run test:backup-scheduler && npm run test:caldav && npm run test:carddav"
},
"dependencies": {
"bcrypt": "^6.0.0",
"better-sqlite3": "^12.9.0",
"dotenv": "^17.4.2",
"express": "^5.2.1",
"express-rate-limit": "^8.4.1",
"express-session": "^1.19.0",
"helmet": "^8.1.0",
"node-cron": "^4.2.1",
"node-fetch": "^3.3.2"
},
"optionalDependencies": {
"googleapis": "^171.4.0",
"tsdav": "^2.1.8"
},
"license": "MIT",
"devDependencies": {
"sharp": "^0.34.5"
}
}