Unable to pull some Apotheosis items using a Storage Terminal
wolfsilver00 opened this issue Β· 29 comments
Issue type:
- π Bug
Short description:
Some items cant be pulled from storage using the terminal, tried with normal chests, sophisticated storage chests, barrels, the armory from Functional storage.. I dont know exactly what is it that makes an item unable to be pullable, for example, this item can be pulled:
But this one cannot:
The only thing all items that I cant pull have in common is that they have an apotheosis modifier
Steps to reproduce the problem:
- ... Get some apotheosis items in storage
- Try to pull them using a terminal
Expected behaviour:
All of them to be able to be taken from storage
Versions:
- This mod: 1.6.7
- Integrated Dynamics: 1.25.2
- Minecraft: 1.21.1
- Mod loader version: Neoforge 21.1.115
- Apotheosis: 8.1.2
And in case you want to try with the storage mods:
- Sophisticated storage: 1.3.0
- Functional Storage: 1.3.7
Log file:
That looks like as if the affected item not functioning properly due to it having a specification of 3 affix names, while only defining 2. And that when the middle name gets filled, it starts working again.
Can you work out if the above is always the type of item that doesn't work? Because if that is the case it is vital information for Apotheosis.
@rubensworks could find one item that changes its data after equipping (and after equipping it comes out of the terminal no problem)
Not working:
{components: {"apotheosis:rarity": "apotheosis:uncommon", "apotheosis:affix_name": {with: [{translate: "affix.apotheosis:armor/attribute/fortunate"}, {"": ""}, {translate: "affix.apotheosis:armor/attribute/fireproof.suffix"}], color: "#33FF33", translate: "misc.apotheosis.affix_name.three"}, "apotheosis:affixes": {"apotheosis:armor/attribute/fireproof": 0.48692143f, "apotheosis:armor/attribute/fortunate": 0.7389696f}}, count: 1, id: "minecraft:diamond_helmet"}
Working after equipping:
{components: {"apotheosis:rarity": "apotheosis:uncommon", "apotheosis:affix_name": {with: [{translate: "affix.apotheosis:armor/attribute/fortunate"}, {translate: "item.minecraft.diamond_helmet"}, {translate: "affix.apotheosis:armor/attribute/fireproof.suffix"}], color: "#33FF33", translate: "misc.apotheosis.affix_name.three"}, "apotheosis:affixes": {"apotheosis:armor/attribute/fireproof": 0.48692143f, "apotheosis:armor/attribute/fortunate": 0.7389696f}}, count: 1, id: "minecraft:diamond_helmet"}
Only thing different is that empty data with the {translate: "item.minecraft.diamond_helmet"}
Other weird thing is that the terminal showed the item twice for a second.. (After I put it in again, after equipping it, it looked like there was 2 items, shift click, one comes out, the other disappears)
This all sounds very similar to #130
That looks like as if the affected item not functioning properly due to it having a specification of 3 affix names, while only defining 2. And that when the middle name gets filled, it starts working again.
Can you work out if the above is always the type of item that doesn't work? Because if that is the case it is vital information for Apotheosis.
Nope, this item (with the missing data) came out of the system no problem
{components: {"apotheosis:rarity": "apotheosis:common", "everythingcopper:oxidation_state": "exposed", "apotheosis:affix_name": {with: [{translate: "affix.apotheosis:armor/attribute/fortunate"}, {translate: "item.everythingcopper.exposed_copper_helmet"}, {"": ""}], color: "#808080", translate: "misc.apotheosis.affix_name.two"}, "apotheosis:affixes": {"apotheosis:armor/attribute/fortunate": 0.87914f}}, count: 1, id: "everythingcopper:copper_helmet"}
This all sounds very similar to #130
Something must have changed these last couple months, as it seems to not be working anymore with Silent Gear either (some items do, most of them donΒ΄t, didnt find a pattern for those either but for those, the equipping "fix" never worked)
Is there some kind of debug mode that I can access to have a bit more information and do further testing? Logs are not helping me at all as there is no error or anything
Thanks for the information. Can you reproduce this in the newest version of the Integrated mods? There's been at least a couple of updates for both and they have had bug fixes. It's always best to see how the newest version of the mod(s) behave in an issue.
Thanks for the information. Can you reproduce this in the newest version of the Integrated mods? There's been at least a couple of updates for both and they have had bug fixes. It's always best to see how the newest version of the mod(s) behave in an issue.
Yup, all mods updated, issue persists
Can someone who is able to repro the issue test with this build of Apotheosis? https://maven.shadowsoffire.dev/releases/dev/shadowsoffire/Apotheosis/1.21.1-8.1.4-beta0/Apotheosis-1.21.1-8.1.4-beta0.jar
This might fix the issue, but I'm not 100% certain if this is the root cause or not.
I notice you're using more mods than you mentioned. Can you reproduce this issue with only the mods you mentioned installed? It's possible other mods are conflicting with storage in some way, it's best to test in a clean test environment.
I notice you're using more mods than you mentioned. Can you reproduce this issue with only the mods you mentioned installed? It's possible other mods are conflicting with storage in some way, it's best to test in a clean test environment.
Yup, just tested and it happens (cant test with those exact items because the world won't load)
Oh and if it helps, I also found out that some Silent Gear items cant be pulled (without any apotheosis modifiers)
This should have been fixed in a recent version of Silent Gear, see #130
If not, could you open a bug report on the Silent Gear issue tracker?
Got some data for items that are the same, from the same mod, with apotheosis and without enchantment.. One with socket, one with not.. (Difficult set of variables to get tbh)
This one pulls out of the system no problem:
{components: {"apotheosis:rarity": "apotheosis:uncommon", "everythingcopper:oxidation_state": "exposed", "apotheosis:sockets": 1, "apotheosis:affix_name": {with: [{translate: "affix.apotheosis:armor/attribute/fireproof"}, {translate: "item.everythingcopper.exposed_copper_helmet"}, {translate: "affix.apotheosis:armor/attribute/fortunate.suffix"}], color: "#33FF33", translate: "misc.apotheosis.affix_name.three"}, "apotheosis:affixes": {"apotheosis:armor/attribute/fireproof": 0.3926167f, "apotheosis:armor/attribute/fortunate": 0.2731598f}}, count: 1, id: "everythingcopper:copper_helmet"}
This one does not:
{components: {"apotheosis:rarity": "apotheosis:common", "everythingcopper:oxidation_state": "weathered", "apotheosis:affix_name": {with: [{translate: "affix.apotheosis:armor/attribute/ironforged"}, {"": ""}, {"": ""}], color: "#808080", translate: "misc.apotheosis.affix_name.two"}, "apotheosis:affixes": {"apotheosis:armor/attribute/ironforged": 0.7941283f}}, count: 1, id: "everythingcopper:copper_helmet"}
Note that the one that doesnt pull, has less information about it and no socket. This one, no matter how many time I equip it, seems to not get fixed by that. (nor does it make a difference for it to receive damage, so im confused as to why it worked with other items before)
Some more findings, if an apotheosis item has never been equipped, you cant pull it out.. but equipping it seems to make it work in SOME cases (sorry for reopening the issue but this was originally about apotheosis, Silent Gear seems to be working correctly now, EDIT: some more testing and it still has some broken items, ill open an issue there)
Further info on an item in terminal and in inv:
Although it may look like it, the Gem slot does not seem to be the cause, as it also happens without it. But I cant help but notice that in the terminal, at least that data does not appear correctly, even after filling that socket (so that its value has some data) still it appears as APOTH_REMOVE_MARKER
Can someone who is able to repro the issue test with this build of Apotheosis? https://maven.shadowsoffire.dev/releases/dev/shadowsoffire/Apotheosis/1.21.1-8.1.4-beta0/Apotheosis-1.21.1-8.1.4-beta0.jar
This might fix the issue, but I'm not 100% certain if this is the root cause or not.
Ill test this today when I finish work, ty for the quick commit
@Shadows-of-Fire nope, did not work, I can confirm the missing data is not the culprit, this one could be pulled for example (never equipped):
{components: {"apotheosis:rarity": "apotheosis:uncommon", "apotheosis:sockets": 1, "apotheosis:affix_name": {with: [{translate: "affix.apotheosis:armor/attribute/fireproof"}, {translate: "item.minecraft.diamond_helmet"}, {translate: "affix.apotheosis:armor/attribute/fortunate.suffix"}], color: "#33FF33", translate: "misc.apotheosis.affix_name.three"}, "apotheosis:affixes": {"apotheosis:armor/dmg_reduction/grounded": 0.18796235f, "apotheosis:armor/attribute/fireproof": 0.023551524f, "apotheosis:armor/attribute/fortunate": 0.19578123f}}, count: 1, id: "minecraft:diamond_helmet"}
All items I tested were on a new world, just reforged items, never equipped.
After equipping one of the items, the item could be pulled from the terminal, leaving a ghost item inside. I can now store and retrieve the item (of course, when I store it, it says I have 2), this behavior persists until the interface is closed. Then I can put and pull the item no problem, this does not seem to work with all items though.
After closing the world, re-opening, and putting the item back in into the chest, it could be pulled from the terminal, no data changes in the item, no need to equip it. This behavior does not seem to be repeatable, even though I tried a loooot.. Items left in the chest while the world is closed, or in inventory, seems to not make any difference.
@rubensworks are you able to perform any further investigation on the equality issue here? After the fix to copy the name component there, I don't think there are any outstanding equality issues from my end. The only other thing I can think of is Object2FloatOpenHashMap#equals being flaky, but I suspect that would have larger consequences than this.
Sure, I'll try to have a look at this on my end. Not sure yet when exactly I'll be able to do this though, hopefully soon-ish.
@rubensworks are you able to perform any further investigation on the equality issue here? After the fix to copy the name component there, I don't think there are any outstanding equality issues from my end. The only other thing I can think of is
Object2FloatOpenHashMap#equalsbeing flaky, but I suspect that would have larger consequences than this.
Sorry if I'm mistaken here and this is not possible, I'm a qa, not a dev.. But if at all possible to add some plog (or whatever it is java has, my code experience is php only) in the functions used by the terminal to pull items, or even some catches and defining the try on a check to see if the item has moved, catch an exception with packet data and send it to log, I can debug further (I dont care if the log is kilometric, im used to that kind of shit).
Again, sorry if im totally wrong here, very out of my waters but dude, I really fucking love this mod, and I really want it to work so Im willing to put in the work ahahah
@wolfsilver00 Could you give me some instructions on the easiest way possible to obtain an Apotheosis item that experiences problems? (since I don't know the mod that well myself)
@wolfsilver00 Could you give me some instructions on the easiest way possible to obtain an Apotheosis item that experiences problems? (since I don't know the mod that well myself)
Of course, the easier way I found to do it is to just load a creative world with JEI, spawn in a Reforging Table and a stack of Timeworn Fabric and one of Sigil of Rebirth, and use on this configuration, while spawning, for example, diamond helmets and putting them in the middle, then, shift clicing the button to the bottom right:
Grab a dozen of those, and just put them in a chest with an Item Interface and terminal, like so:
Most if not all items should not be able to be taken out of storage using the terminal
You can also put the items via the terminal instead of directly in the chest, with the same result
@Shadows-of-Fire It looks like the affix_name component is being considered unequal between server and client.
I haven't been able to find anything yet on why that could be occurring. Maybe you have some ideas?
Is this with the beta build from my earlier comment?
If so, I have no idea what is causing the inequality. That build includes this commit which fixes the only known mutation of that component value.
@Shadows-of-Fire Yes, that's the one I was using.
After some more inspection, it looks like the client and server variants of the stack differer in terms of their translation arguments for the affix_name.
That's exactly what I figured out already in this comment though: #152 (comment)
For future reference, I added a debugger to Common Capabilities for easier debugging of these cases: CyclopsMC/CommonCapabilities@119a991
Oh. I see, Component#copy() doesn't do a deep copy of the component contents, so the mutation issue is still present. I'll have to rebuild the component contents from scratch to avoid the mutation problem.
This is being tracked in Shadows-of-Fire/Apotheosis#1478, as I suspect it's fixed in the latest Apotheosis version.







