microsoftgraph / microsoftgraph/msgraph-sdk-dotnet-core
AddListItem to SP List using MsGraph is not allowed to provide null values for fields that allow have the option "require column to have information" set to false
Nobody has claimed this yet.
- Dominant language
- C#
- Stars
- 164
- Forks
- 65
- Avg merge
- 38m
- Merged PRs (30d)
- 1
Description
Please provide the following (and please check them off the list with [x]) before submitting this issue:
- Expected behavior. Please provide links to the specific Microsoft Graph documentation you used to determine the expected behavior.
- Actual behavior. Provide error codes, stack information, and a Fiddler capture of the request and response (please remove personally identifiable information before posting).
- Steps to reproduce the behavior. Include your code, IDE versions, client library versions, and any other information that might be helpful to understand your scenario.
Expected behavior
When initializing a new list item object we provide 'null' for some fields if the source is empty or null:
Actual behavior
When initializing a new list item object we provide 'null' for some fields if the source is empty or null:
When submitting the newly created listitem to the GraphServiceClient:
This results in a Generic Service Exception, after investigating I realized this had to do with the field data types and there respective option to allow the field to have no content.
But since this week, it is no longer allowed to send null values using the MsGraph.
Steps to reproduce the behavior
Prepare a listitem object like in Expected Behavior.
Then try to add it using the MsGraph Core SDK
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the list-item creation described with the Microsoft Graph Core SDK and GraphServiceClient, using optional fields set to null. Review the resulting generic service exception and compare the request behavior with the expected handling of nullable SharePoint list fields. Done means the behavior is understood and either corrected or clearly documented with a reproducible test case.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- csharp
- Domain
- api
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100