Skip to content

chore: upgrade @dcl/schemas to 27 - #498

Merged
LautaroPetaccio merged 2 commits into
masterfrom
chore/upgrade-dcl-schemas-27
Oct 14, 2026
Merged

LautaroPetaccio merged 2 commits into
masterfrom
chore/upgrade-dcl-schemas-27

Conversation

@LautaroPetaccio

@LautaroPetaccio LautaroPetaccio commented Oct 14, 2026 •

Copy link
Copy Markdown
Contributor

Stacked on #496.

Bumps @dcl/schemas from ^23.0.0 to ^27.3.0.

What changed in schemas 23 → 27 that matters here

  • Entity, EntityType, AuthChain, ContentMapping and Profile declarations are byte-identical; majors 24–26 only touched events and spring-bone types.
  • 27.0.0 tightened validators: Entity.validate requires unique pointers, AuthChain is capped at 10 links with 100 KB payload/signature, scene parcels must be canonical and unique.

Code changes: none besides package.json/yarn.lock.

Public types: dist/**/*.d.ts is identical to a build of #496 (only dist/package.json differs).

Runtime: buildEntity, buildEntityAndFile and buildEntityWithoutNewFiles now throw on exactly duplicated pointers instead of producing such an entity.

Release notes: buildEntity/buildEntityAndFile/buildEntityWithoutNewFiles now throw Generated entity is not valid (must NOT have duplicate items) when pointers contains duplicates (schemas 27 uniqueItems). Catalysts already reject these deployments server-side (content-validator entity structure check: "There are repeated pointers in your request"), so this only moves the failure before upload.

Consumer impact: not breaking at the type level. A consumer pinned to schemas 23 (with 27 nested under the client) type-checks under strict when passing its own Entity, EntityType, AuthChain and ContentMapping to DeploymentBuilder, deploy and fetchEntitiesByPointers; cross-version assignment works both ways. Also bumps @dcl/crypto to ^3.8.0 (decentraland/core-libs#78), which depends on @dcl/schemas@^27.3.0, so the runtime tree now has a single schemas copy instead of 27 + 25.

Tests: build, lint and 210/210 tests pass.

@github-actions

github-actions Bot commented Oct 14, 2026 •

Copy link
Copy Markdown

Test this pull request

  • The package can be tested by running
    yarn upgrade "https://sdk-team-cdn.decentraland.org/@dcl/catalyst-client/branch/chore/upgrade-dcl-schemas-27/dcl-catalyst-client-22.0.1-38618213597.commit-d7aff76.tgz"

@decentraland-bot decentraland-bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Review: approve

This bumps @dcl/schemas to ^27.3.0 with no source changes. Install, build, lint and 210/210 tests pass, and the runtime closure stays at 49 packages with no new names.

What I checked

  • Validation surface. The only validation call is Entity.validate in buildEntityAndFile, which buildEntity and buildEntityWithoutNewFiles both reach. In 27.3 the Entity schema adds uniqueItems on pointers, but metadata is still object. The tighter scene-parcel and AuthChain rules therefore never run on the client, and there is no AuthChain.validate call in src.
  • Duplicate pointers. Catalyst already rejects these server-side (@dcl/content-validator entity-structure: "There are repeated pointers in your request", present from 5.6.1 through 8.1.0). The new throw makes a deploy that would fail anyway fail earlier, on the client. It only newly breaks code that builds entities with duplicated pointers without deploying them.

Findings

  • [P2] Release notes. Mention the earlier duplicate-pointer error in the next release notes.
  • [P2] Two schema copies at runtime. The runtime tree now has @dcl/schemas@27.3.0 plus @dcl/schemas@25.3.0; the second comes via @dcl/crypto@3.7.0 (^25.2.0). This duplication already existed (23 + 25), so it's not new. As a follow-up, consider bumping @dcl/crypto to schemas 27, or making @dcl/schemas a peer dependency in a future major, so consumers share one copy.

Reviewed by Jarvis 🤖 · Requested by Lautaro Petaccio (<@U025WCHLMN3>) via Slack

Base automatically changed from chore/update-dependencies to master October 14, 2026 18:47
Bump @dcl/schemas from ^23.0.0 to ^27.3.0. The Entity, EntityType,
AuthChain, ContentMapping and Profile type declarations are unchanged
between 23 and 27, so no source changes are needed and the published
.d.ts is identical.

Runtime: Entity.validate now requires unique pointers, so
buildEntityAndFile rejects entities with exactly duplicated pointers
instead of producing them.
@dcl/crypto 3.8.0 depends on @dcl/schemas ^27.3.0, so the nested schemas 25 copy is gone and the runtime tree has a single schemas.
@LautaroPetaccio
LautaroPetaccio force-pushed the chore/upgrade-dcl-schemas-27 branch from fe8b669 to 80a2eae Compare October 14, 2026 18:47
@LautaroPetaccio
LautaroPetaccio merged commit c0c3f9e into master Oct 14, 2026
2 checks passed
@LautaroPetaccio
LautaroPetaccio deleted the chore/upgrade-dcl-schemas-27 branch October 14, 2026 18:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants