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

perform checks based on NavigationProperty multiplicity #117

Open
filak-sap opened this issue Jul 16, 2020 · 0 comments
Open

perform checks based on NavigationProperty multiplicity #117

filak-sap opened this issue Jul 16, 2020 · 0 comments
Labels
enhancement New feature or request

Comments

@filak-sap
Copy link
Contributor

When creating a new entity, it is possible to call the method set with an invalid value for a navigation property because the method set does not verify multiplicity of the corresponding navigation property relation ship. To put it simple, it is possible to assign a list to a navigation property which is supposed to be an entity.

More explicitly, we need to add a check for multiplicity before the following line:
https://github.com/SAP/python-pyodata/blob/master/pyodata/v2/service.py#L489

mamiksik added a commit to mamiksik/python-pyodata that referenced this issue Jul 16, 2020
Change test entity from Car to Customer, since car can only have one navigation property.

A check for correct multiplicity is needed As described in SAP#117.
@filak-sap filak-sap added the enhancement New feature or request label Jul 20, 2020
mamiksik added a commit to mamiksik/python-pyodata that referenced this issue Jul 22, 2020
Change test entity from Car to Customer, since car can only have one navigation property.

A check for correct multiplicity is needed As described in SAP#117.
filak-sap pushed a commit that referenced this issue Jul 22, 2020
Change test entity from Car to Customer, since car can only have one
navigation property.

A check for correct multiplicity is needed As described in #117.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant