Skip to content

Conversation

@truman-cyborg
Copy link
Contributor

@truman-cyborg truman-cyborg commented Nov 24, 2025

added better error handling for upsert and update the test to be more accurate to what we're upserting

Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

⚠️ API Contract Change Detected

This PR modifies the public API contract of the CyborgDB JS SDK.

Please provide an explanation for this change:

  • Why is this change necessary?
  • Is this a breaking change or backward compatible?
  • Have you updated the documentation?

This review must be dismissed or addressed before the PR can be merged.

// Contents should be decoded to string by SDK
expect(typeof result.contents).toBe('string');
// Contents for the ids were upserted as buffer object
expect(typeof result.contents).toBe('object');
Copy link
Contributor

Choose a reason for hiding this comment

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

The Python SDK expects contents to be returned as a string, even when uploaded as bytes but for JS now we are expecting it to be as raw buffer object? I think we should have consistent behavior across both sdks, having text content is more user friendly

Copy link
Contributor Author

Choose a reason for hiding this comment

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

revert it back for now

lubna-khalid
lubna-khalid previously approved these changes Nov 25, 2025
@truman-cyborg
Copy link
Contributor Author

⚠️ API Contract Change Detected

This PR modifies the public API contract of the CyborgDB JS SDK.

Please provide an explanation for this change:

  • Why is this change necessary?
  • Is this a breaking change or backward compatible?
  • Have you updated the documentation?

This review must be dismissed or addressed before the PR can be merged.

the changes were to reduce the amount of failed test when running them and to fix one bug for upsert.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

bug fix for upsert if we upsert without vector but also include a context

@dupontcyborg dupontcyborg merged commit bd22ad0 into main Nov 26, 2025
6 checks passed
@dupontcyborg dupontcyborg deleted the v0.14.0-fixes branch November 26, 2025 20:56
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.

5 participants