Open keturn opened 3 years ago
https://github.com/MovingBlocks/Terasology/pull/4841#pullrequestreview-729928568 fixes the NPE, at least.
With those changes, I get different failures in the tests:
This seems to be because producer.getParentPrefab().getName()
throws an NPE.
The respective entity exists and does look like this, but it has no parent prefab :thinking:
{
"id": 31,
"alwaysRelevant": false,
"engine:RetainComponents": {
"components": [
null
]
},
"engine:Location": {
"replicateChanges": true,
"lastPosition": [
0.0,
0.0,
0.0
],
"isDirty": true,
"lastRotation": [
0.0,
0.0,
0.0,
1.0
],
"rotation": [
0.0,
0.0,
0.0,
1.0
],
"scale": 1.0,
"position": [
0.0,
1.0,
0.0
]
},
"engine:Block": {
"block": "SimpleFarming:MatureTestBush",
"position": [
0,
1,
0
]
},
"engine:Network": {
"networkId": 9,
"replicateMode": "RELEVANT"
},
"SimpleFarming:BushDefinition": {
"currentStage": 2,
"seedDropChances": [
0,
1,
1,
1
],
"seed": "SimpleFarming:TestSeed",
"sustainable": true,
"growthStages": {
"SimpleFarming:TestBush:engine:halfblock": {
"minTime": 500,
"maxTime": 500
},
"SimpleFarming:TestBush": {
"minTime": 500,
"maxTime": 500
}
},
"produce": "SimpleFarming:TestProduce"
}
}
Did we change anything to how parent prefabs are computed/stored in the (recent) past? The code in that system was like that from the beginning...
The only recent activity in this module was #117, which looks vaguely similar when I squint but I don't think is the problem here.
No clue about any changes with the engine for prefabs overall.
See latest test report, 3 out of 4 tests fail with an NPE in GenomeAuthoritySystem.onProduceCreated.
https://github.com/Terasology/SimpleFarming/blob/b3c691b0cc50c74cdcbdafbf39cb0e82da589460/src/main/java/org/terasology/simpleFarming/systems/GenomeAuthoritySystem.java#L70
This test failure is reproducible locally.