Search Issue Tracker
Fixed in 6000.0.38f1
Fixed in 6000.0.X, 6000.1.0b6, 6000.2.X, 6000.2.0a4, 7000.0.0a19
Votes
0
Found in
6000.0.20f1
6000.1.0a7
6000.2.0a1
Issue ID
UUM-82870
Regression
Yes
Serialization error when editing an asset with a class starting with the same name as the namespace that it is in
Reproduction steps:
1. Open the attached project "ErrorProject"
2. Enter The Play mode
3. Observe Console
Expected result: No errors
Actual result: Scripted class MyNamespace.MyNamespace.class is serialized as MyNamespace.lass and an error appears
Reproducible with: 2023.2.0b1, 6000.0.20f1
Not reproducible with: 2021.3.43f1, 2022.3.48f1, 2023.2.0a23
Couldn’t test with:
Reproducible on: Windows 11
Not reproducible on: No other environment tested
Comments (1)
Add comment
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- Redoing creation of Sub Scenes and Cube GameObjects in Hierarchy throws “Assertion failed on expression: 'targetScene != nullptr’” error in Console window
- Selecting “New Sub Scene” after assigning “New Scene” in Sub Scene Script Component throws “Destroying GameObjects immediately is not permitted” in the Console window
- Shader Graph "Zoom Step Size" can be set to 0 even though the zoom still works
- Enabling/Disabling the Deprecated Nodes doesn't apply to the opened Shader Graph unless any Variable is added to the Blackboard
- Group Selection title text size is smaller in renaming than the actual font size
glutinousfrizzy
Sep 25, 2024 07:44
The serialization error you're encountering, where a class with the same name as its namespace is improperly serialized, seems to occur in newer Unity versions (starting from 2023.2.0b1 and later). It does not happen in earlier versions like 2021.3.43f1 or 2022.3.48f1. The issue seems to stem from how Unity’s serialization system handles class names that share the same name as their enclosing namespace.