Skip to content

ModelInstanceDocument doc.replace, there are some fields that are not updated in db table #2499

Open

Description

@lyd0

Describe the bug

    const doc = await ModelInstanceDocument.create(ceramic, CONTENT0, midMetadata)
    await doc.replace(CONTENT1)

but in postgress ,the db table only updates 2 fields(last_anchored_at&updated_at) when doc updated, CONTENT1 data is not updated to table,maybe other fields should be updated as well

https://github.com/ceramicnetwork/js-ceramic/blame/33e3c0969c0161d5dc17b55501775385241066be/packages/core/src/indexing/postgres/postgres-index-api.ts#L57

Screenshots
If applicable, add screenshots to help explain your problem.
image

Activity

  1. lyd0 commented on Oct 18, 2022

    @lyd0
    Author

    @willex hello~ Looking forward to your reply

  2. stbrody commented on Oct 19, 2022

    @stbrody
    Collaborator

    @lyd0 this does indeed look like a bug. Thanks for bringing it to our attention! We'll triage it at our next triage meeting in a week or so

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions