Skip to content

chore(deps): upgrade class-validator to v0.15.1 (closes #759)#861

Open
dzekojohn4 wants to merge 1 commit into
MettaChain:mainfrom
dzekojohn4:fix/issue-759-class-validator-0.15
Open

chore(deps): upgrade class-validator to v0.15.1 (closes #759)#861
dzekojohn4 wants to merge 1 commit into
MettaChain:mainfrom
dzekojohn4:fix/issue-759-class-validator-0.15

Conversation

@dzekojohn4

@dzekojohn4 dzekojohn4 commented Jun 30, 2026

Copy link
Copy Markdown

Closes #759
Closes #760
Closes #761
Closes #762

  • Bump class-validator from ^0.14.1 to ^0.15.1 (resolved 0.15.1)
  • class-transformer stays at ^0.5.1 (resolved 0.5.1) - version range unchanged, compatible with v0.15

Audit performed

@type(() => Date) (8 sites, all reviewed):

  • src/transactions/dto/transactions.dto.ts (lines 29, 34)
  • src/transactions/dto/transaction.dto.ts (lines 207, 216)
  • src/properties/dto/search-properties.dto.ts (lines 116, 120)
  • src/properties/dto/property.dto.ts (lines 143, 233)
    Left unchanged. v0.15's stricter IsDate handling is compatible with the global ValidationPipe config (src/main.ts): transform: true + transformOptions.enableImplicitConversion: true. enableImplicitConversion delegates native primitive coercion to class-transformer, and v0.15's stricter Date-string validation continues to reject malformed ISO strings.

@ValidateNested (4 sites, all reviewed):

  • src/users/dto/update-profile.dto.ts:105 (ContactHoursDto, paired @type at 106)
  • src/users/dto/update-profile.dto.ts:110 (AddressDto, paired @type at 111)
  • src/neighborhoods/dto/neighborhood.dto.ts:137 (SchoolDto, paired @type at 138)
  • src/neighborhoods/dto/neighborhood.dto.ts:143 (AmenityDto, paired @type at 144)
    All four are already correctly paired with @type, which is the contract v0.15 enforces strictly. No source changes required.

Validation

  • tsc --noEmit: clean (no type errors)
  • Full npm test: 34 suites passed / 1 skipped, 224 tests passed / 2 skipped, 0 failures
  • Working tree contained ONLY package.json + package-lock.json changes (lint --fix auto-fixes on unrelated files were reverted before commit)

Semver note

^0.15.1 allows future 0.15.x patches but blocks 0.16.0 - appropriate for a dep where minor versions historically introduce semantic changes.

- class-validator: ^0.14.1 -> ^0.15.1; class-transformer ^0.5.1 unchanged (still compatible)

- Mostly additions in v0.15; validateNested() is stricter but every @ValidateNested site (4 total) already has its @type paired, so no source-code change required

- Audit on the 8 @type(() => Date) sites - all left unchanged because the global ValidationPipe uses transform: true + enableImplicitConversion: true (src/main.ts), and v0.15's stricter IsDate semantics are satisfied

- Validation: tsc clean, full test suite 34 suites / 224 tests / 0 failures (2 skipped, unchanged)

- Working tree clean: no unrelated lint --fix style edits included
@drips-wave

drips-wave Bot commented Jun 30, 2026

Copy link
Copy Markdown

@dzekojohn4 Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits.

You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀

Learn more about application limits

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

1 participant