NullReferenceException on parallel Deserialize
Open
Beginner friendly
Nobody has claimed this yet.
- Dominant language
- C#
- Stars
- 4.7k
- Forks
- 313
- PR merge metrics
- No merged PRs in 30d
Description
Check<T>.registered = true; is set before Cache<T>.formatter = formatter; and cause Cache<T>.formatter to be null on parallel access
Contributor guide
No contributing guide indexed for this repository
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 at src/MemoryPack.Core/MemoryPackFormatterProvider.cs lines 47-52 and inspect the parallel Deserialize path around the registration and formatter cache assignments. Reproduce concurrent access and verify that deserialization no longer raises NullReferenceException under parallel access, adding regression coverage where the existing tests for this component belong.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- csharp
- Domain
- backend
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Active
- Clarity
- Clearly specified
- Newbie friendliness
- 82/100