Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Entity matching retrieve endpoint does not return None #1593

Open
KristianVangsnes opened this issue Jan 19, 2024 · 0 comments
Open

Entity matching retrieve endpoint does not return None #1593

KristianVangsnes opened this issue Jan 19, 2024 · 0 comments
Labels

Comments

@KristianVangsnes
Copy link
Contributor

KristianVangsnes commented Jan 19, 2024

System information (please complete the following information):

  • OS: [14.1.2 (23B92)
  • Python Version: Python/3.10.5
  • SDK Version: Latest

Describe the bug
The client.entity_matching.retrieve endpoint raises an error if the model does not exist. It should return None.

To Reproduce
Runnable code reproducing the error.

from cognite.client import CogniteClient

client = CogniteClient()

client.entity_matching.retrieve(external_id = "1234")
#assuming that model with ex_id = "1234" does not exist.

Expected behavior
It should not raise an error, but return None.

def retrieve(self, id: int | None = None, external_id: str | None = None) -> EntityMatchingModel | None:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant