Skip to content

Fix iterable selections for entity and collection requests - #319

Open
Shubham-Padkonde wants to merge 1 commit into
SAP:masterfrom
Shubham-Padkonde:fix/iterable-select
Open

Shubham-Padkonde wants to merge 1 commit into
SAP:masterfrom
Shubham-Padkonde:fix/iterable-select

Conversation

@Shubham-Padkonde

Copy link
Copy Markdown

Fixes #71.

Normalize iterable selections into a comma-separated string before building the query. Both EntityGetRequest.select() and QueryRequest.select() use the same helper, so .select(['NameFirst', 'NameLast']) produces one $select value rather than serializing the Python collection. Iterators are consumed once when setting the selection.

Existing string inputs, fluent chaining, and .select(None) retain their behavior. The method documentation and changelog describe the supported input.

Validation: all 306 tests pass, including networking integration tests. Six iterable regressions fail before the fix; two additional cases cover strings and clearing the selection. Pylint passes at 10/10, and the pinned Flake8 passes under Python 3.10 (its entry-point discovery is incompatible with Python 3.12).

@cla-assistant

cla-assistant Bot commented Oct 2, 2026

Copy link
Copy Markdown

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
You have signed the CLA already but the status is still pending? Let us recheck it.

@phanak-sap

Copy link
Copy Markdown
Contributor

Hii @Shubham-Padkonde, thanks for the PR.

Normalize selection clauses through one helper while preserving strings and None. Fixes SAP#71.
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.

the method select of ODataQuery classes should handle iterable parameters

2 participants