Search Issue Tracker
By Design
Votes
3
Found in
2020.3
2020.3.10f1
2021.1
2021.2
Issue ID
1339347
Regression
No
Changes made in AssetPostprocessor.OnPostprocessPrefab are not visible in the saved prefab
How to reproduce:
1. Open the attached project "Test2020LTS.zip"
2. Open SampleScene
3. Edit the text of Text (TMP) Game Object
4. Drag the Canvas component to the Project View to create a prefab
5. Open the created prefab
Expected result: You see 'Hello World!' in the saved prefab
Actual result: You can see the edited text in the saved prefab
Reproducible with: 2020.3.11f1, 2021.1.10f1, 2021.2.0a19
Could not test with: 2018.4.34f1, 2019.4.28f1 (No OnPostprocessPrefab method)
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
- Render Pipeline Converter selected asset counter reports one fewer item when using manual selection
- [Android] [Adreno] [WebGL] A light cookie is not rendered with shader compile error when WebGL build is launched on a device with Adreno GPU
- Rigibody sliding over a flat surface that is made of several GameObjects detects false collisions when Collision Detection is set to "Continuous" or "Continuous Dynamic"
- UI Toolkit Label height is incorrectly calculated when using max-width with percentage value
- Visual Effect Material causes Scene view to update continuously when both Scene and Game views are open, despite "Always Refresh" being disabled
Resolution Note (2022.1.X):
This behavior is by design. In the documentation we have "This function is called before the imported Prefab is created in the Library folder and before it is written to disk" => the imported Prefab that is saved in Library folder contains all the changes made in OnPostprocessPrefab, but the original asset remains unchanged.
Prefab Mode (isolation) displays the prefab asset as it is the Assets folder which doesn't contain the changes made by OnPostprocessPrefab