Bentobox: Islands did not load on startup with latest SNAPSHOT

Created on 14 May 2019  路  14Comments  路  Source: BentoBoxWorld/BentoBox

Description

Describe the bug

  • We updated BBox to 1.5.0-SNAPSHOT-b1062 and islands became unowned while console printed:
    Could not load object duplicate key: null
    Could not load object duplicate key: null
  • We had also noticed that NPE on connection with github

Steps to reproduce the behavior

  1. Update to b1062
  2. Check your islands (Unowned)
  3. Typing /is - Generates new island
  4. Downgrading to: bentobox-1.5.0-1045.jar made islands load perfectly

Log

Console log: https://www.hastebin.com/iqaroqumuv.md

Expected behavior

Not get unowned

Environment

Server


  • OS: Debian GNU/Linux 9
  • Java version:
    Java(TM) SE Runtime Environment 18.3 (build 10.0.1+10)
    Java HotSpot(TM) 64-Bit Server VM 18.3 (build 10.0.1+10, mixed mode)

Plugins

[06:32:17 INFO]: Plugins (50): AnimatedNames*, AreaShop, ArmorStandTools, BentoBox, BungeeTabListPlus*, ChatControl, ChestCommands, ChestShop*, ClearLag*, CrateReloaded, EditableSign, Essentials, EssentialsChat*, EssentialsSpawn*, ExecuteEverywhere*, FastAsyncWorldEdit*, FeatherBoard*, HeadDatabase*, HolographicDisplays, HungerKeeperPlus*, IPWhitelist*, IslandBorder, LeaderHeads*, LibsDisguises, LuckPerms, MobManager*, Multiverse-Core*, MVdWPlaceholderAPI*, NickRemover*, NoSleepCMDs*, OpenInv*, PlayerHeads, PlayerPoints*, ProtocolLib*, PvPManager*, PvPManagerBossBar*, RedstoneClockDetector*, RPGHealthIndicator*, SilkSpawners, SkinsRestorer, Spartan, TradeMe, TrophyHeads*, UnbreakingAnvils*, Vault*, VoidGenerator, WorldEdit, WorldGuard, WorldGuardPistonFix*, Yamler*

BentoBox setup

BentoBox and Addons
[21:39:11] [main/INFO]: [CHAT] Running PAPER 1.13.2.
[21:39:11] [main/INFO]: [CHAT] BentoBox version: 1.5.0-SNAPSHOT-b1062
[21:39:11] [main/INFO]: [CHAT] Loaded Game Worlds:
[21:39:11] [main/INFO]: [CHAT] acidisland (acidisland)
[21:39:11] [main/INFO]: [CHAT] skyblock (skyblock)
[21:39:11] [main/INFO]: [CHAT] Loaded Addons:
[21:39:11] [main/INFO]: [CHAT] AcidIsland 1.5.0-SNAPSHOT
[21:39:11] [main/INFO]: [CHAT] BentoBox-InvSwitcher 0.0.3-SNAPSHOT
[21:39:11] [main/INFO]: [CHAT] Biomes 1.5.0.0-SNAPSHOT-#30
[21:39:11] [main/INFO]: [CHAT] BSkyBlock 1.5.0
[21:39:11] [main/INFO]: [CHAT] Challenges 0.7.5-SNAPSHOT-#190
[21:39:11] [main/INFO]: [CHAT] Level 1.4.0
[21:39:11] [main/INFO]: [CHAT] Limits 0.2.0-SNAPSHOT
[21:39:11] [main/INFO]: [CHAT] SerbCraftAddon 2.2
[21:39:11] [main/INFO]: [CHAT] WelcomeWarps 1.4.1
Configuration
  • Database: mySQL

Additional context

None, it's a test server, so we are not in a panic! 馃槃

Critical Done Bug

All 14 comments

Hi @wellnesscookie - can you try the latest build on your test database? may sure you use fresh MysQL copy from your production server and not the left over one. I saw this issue occur a few builds ago and I think I fixed it. If you still see it I'd like to do some debug.

@tastybento
Still same problem even with the newest BBox build. Islands did not load.
Build tried: https://ci.codemc.org/job/BentoBoxWorld/job/BentoBox/1076/

Downgrading to: bentobox-1.5.0-1045.jar made islands load perfectly

Steps we did:

  1. Updated BBox
  2. Acid and BSB did not load
  3. Updated BSB + Acid too
  4. Islands did not load (With same error from comment above)
  5. Downgraded BBox
  6. BSB + Acid did not load (Or at least not correctly)
  7. Downgraded BSB + Acid
  8. Addons/ Gamemodes loaded perfectly + islands as well

Thanks. Please could you unzip and try and use this build attached that has debugging in it and paste a link to the console errors? That'll help me pin down what data is causing the null.
Thanks!
BentoBox-1.5.0-SNAPSHOT-LOCAL.jar.zip

@wellnesscookie Any luck? I think this is a blocker for 1.5.0 release so thanks for helping! Also, is there a way I could get a copy of your database so I can try and fix it myself? Thanks!

@tastybento
Sure, we will test provided build in next 2 hours. Sorry I didn't answer earlier, I was in school the whole day.

@tastybento

@wellnesscookie One issue is that in the database you gave me the island data has a null flag in it. I'm not sure how that occurred. Even trying to load it with Build#1045 causes null errors. Here's an example:

{
  "name": null,
  "flags": {
    "BED": 500,
    "DYE": 500,
    "TNT": 500,
    "BOAT": 500,
    "DOOR": 500,
    "EGGS": 500,
    "GATE": 0,
    "LOCK": 0,
    "null": 0,
    "ANVIL": 500,

See the null above the ANVIL. I need to see if there's a way to ignore these. I'm not sure where it came from...

@wellnesscookie Could you check if that database is the original one? I'm not sure how or if it's possible to get around this issue programmatically if null keys have crept into the database.

@tastybento The island name can be null, that's a totally expected value. Should an empty string be used instead?

@Poslovitch It's not the island name, it's the flags. I just worked out what was happening. See the comments on the commit from February and I'll commit a change that should stop this from being an issue.

@wellnesscookie I don't need you to give me anything. I worked out what the issue is.

I found another issue that I'm working on. If an Addon registers a flag and it's saved in the database with an island and that addon subsequently changes the name of the flag, or removes it, or the addon is removed, the flag will cause an error when the object is loaded. I'm working on a fix for that now.

@wellnesscookie This should be fixed now. I tested it on your database and the islands load fine. Thanks for finding this issue, it helped a lot. If it all works okay, please close. Otherwise, let me know what didn't work.

@Poslovitch This fix should actually give us the ability to delete flags in future. It seems the general rule of never being able to delete an Enum has been solved with this approach.

@tastybento So we did update to Build-1079 and islands loaded perfectly!
I'm aware that I wasn't very fast when giving feedback, therefore I'm sorry, but I'm happy it's fixed.
Thanks once, again. Closing this issue, as requested :blush:

Was this page helpful?
0 / 5 - 0 ratings

Related issues

LegacyGamerHD picture LegacyGamerHD  路  6Comments

wellnesscookie picture wellnesscookie  路  6Comments

wellnesscookie picture wellnesscookie  路  3Comments

doitliketyler picture doitliketyler  路  3Comments

Michel-0 picture Michel-0  路  5Comments