Skip to content

Conversation

@nikgraf
Copy link
Collaborator

@nikgraf nikgraf commented Jan 20, 2026

No description provided.

@changeset-bot
Copy link

changeset-bot bot commented Jan 20, 2026

🦋 Changeset detected

Latest commit: de4b69c

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@graphprotocol/grc-20 Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@nikgraf nikgraf changed the title Property types Property types & fix Graph.createProperty Jan 20, 2026
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This pull request updates the property data type system to align with the new grc-20 specification. It replaces the legacy data types (STRING, NUMBER, etc.) with a comprehensive set of new types and fixes Graph.createProperty to properly handle these types by creating data type relations.

Changes:

  • Expanded ValueDataType from 5 types to 12 types (BOOLEAN, INTEGER, FLOAT64, DECIMAL, TEXT, BYTES, DATE, TIME, DATETIME, SCHEDULE, POINT, EMBEDDING)
  • Added logic to create data type relations for value properties
  • Updated all tests, examples, and documentation to use new type names

Reviewed changes

Copilot reviewed 7 out of 7 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
src/types.ts Expanded ValueDataType union to include all new data types supported by the grc-20 spec
src/graph/create-property.ts Added VALUE_DATA_TYPE_TO_ID mapping and logic to create data type relations for value properties
src/graph/create-property.test.ts Updated tests to use new type names and verify data type relation creation
src/core/ids/system.ts Added ID constants for all new data types and the DATA_TYPE relation
scripts/setup-rank-types.ts Updated comments and property definitions to use TEXT and FLOAT64 instead of STRING and NUMBER
README.md Updated examples to reflect new data type names
.changeset/short-cycles-happen.md Added changeset describing the fix

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@nikgraf nikgraf merged commit 87b4032 into main Jan 20, 2026
3 checks passed
@nikgraf nikgraf deleted the property-types branch January 20, 2026 20:42
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