
Can not Import with 4.4.0 format and can not import with 5.0.39 format export file.
PhantumOne opened this issue ยท 9 comments
I backed up my database with "/lp export Pnodes" and then I updated the plugin. When I did "lp import Pnodes" it failed with over 1600 errors. So I added all my groups and a few permissions per group using the Web editor and then I exported the database.
The export file was saved as a ZIP file with Pnodes.json inside. When I unzipped it and viewed the file, the format was completely different from the format in 4.4.0.. So I used the format in the new Pnodes.json file that I exported and added all the permission for each group so I could import them into a new database. Then I stopped the server, deleted the database and started the server. When I tried to Import the Pnodes.json file and my console began scrolling out of control.
Here is the startup of the import and the 1st error posted in the logs:
[18:50:51] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> Starting import process.
[18:50:51] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> Processing commands....
[18:50:51] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> Waiting for initial update task to complete....
[18:50:51] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> Setting up command executor....
[18:50:51] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> All commands have been processed and scheduled - now waiting for the execution to complete..
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) COMPLETED - took 1.295 seconds - 1609 errors.
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) ------------> Showing Error #1 <------------
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) Whilst executing: Command #1
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) Command: {
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) Type: INVALID_ARGS
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) Output:
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> [LP] Running LuckPerms v5.0.39.
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> > /lp user
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> > /lp group
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> > /lp track
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> > /lp group
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> > /lp log
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> > /lp track
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> > /lp sync
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> > /lp log
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> > /lp info
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> > /lp sync
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> > /lp editor [type]
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> > /lp info
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> > /lp verbose <on|record|off|upload> [filter]
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> > /lp editor [type]
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> > /lp tree [scope] [player]
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> > /lp verbose <on|record|off|upload> [filter]
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> > /lp search
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> > /lp tree [scope] [player]
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> > /lp check
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> > /lp search
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> > /lp networksync
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> > /lp check
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> > /lp import
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> > /lp networksync
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> > /lp export
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> > /lp import
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> > /lp reloadconfig
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> > /lp export
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> > /lp bulkupdate
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> > /lp reloadconfig
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> > /lp creategroup
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> > /lp bulkupdate
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> > /lp deletegroup
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> > /lp creategroup
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> > /lp listgroups
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> > /lp deletegroup
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> > /lp createtrack
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> > /lp listgroups
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> > /lp deletetrack
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> > /lp createtrack
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> > /lp listtracks
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> > /lp deletetrack
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) <------------------------------------------>
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) -> > /lp listtracks
[18:50:53] [ForkJoinPool-2-worker-25/INFO]: [LP] (Import) ------------>
Can you please post on the wiki or Spigot Resource the proper format to make an import file and don't just give a list of commands; make a spoiler Button with the import file showing Multible Groups consisting of display_name, prefix, weight and nodes.
Thank You
Also how does your exported file from v4 look like?
It should be just a list of commands.
And make sure the file has a valid extension like .txt
And make sure the file has a valid extension like .txt
That's not needed anymore. At least on the latest LP versions.
And make sure the file has a valid extension like .txt
That's not needed anymore. At least on the latest LP versions.
It kinda was/is to allow importing v4 files into v5 due to the syntax change of the export file.
As I said. It was fixed in the latest versions. It was discussed in the #staff channel.
Well, you are almost there.. I was able to load the old export into luckperms but it had a few errors; all nodes were loaded but every UUID was rejected with this error:
[08:08:06] [ForkJoinPool-2-worker-18/INFO]: [LP] (Import) ------------> Showing Error #1 <------------
[08:08:06] [ForkJoinPool-2-worker-18/INFO]: [LP] (Import) Whilst executing: Command #681
[08:08:06] [ForkJoinPool-2-worker-18/INFO]: [LP] (Import) Command: user b058169e-a3bd-47c8-a7fe-4ce9b7a6f0fb switchprimarygroup mod
[08:08:06] [ForkJoinPool-2-worker-18/INFO]: [LP] (Import) Type: INVALID_ARGS
[08:08:06] [ForkJoinPool-2-worker-18/INFO]: [LP] (Import) Output:
[08:08:06] [ForkJoinPool-2-worker-18/INFO]: [LP] (Import) -> [LP] Command not recognised.
[08:08:06] [ForkJoinPool-2-worker-18/INFO]: [LP] (Import) <------------------------------------------>
[08:08:06] [ForkJoinPool-2-worker-18/INFO]: [LP] (Import) ------------>
Looks like it is having a problem following the track..
Question: So the exports are no longer a backup for LuckPerms unless we convert all the data in the export by hand back into the earlier format?
Here is the old format for users info:
#Export users
#Export user: b058169e-a3bd-47c8-a7fe-4ce9b7a6f0fb - phantumone
/lp user b058169e-a3bd-47c8-a7fe-4ce9b7a6f0fb parent add mod
/lp user b058169e-a3bd-47c8-a7fe-4ce9b7a6f0fb switchprimarygroup mod
/lp user b058169e-a3bd-47c8-a7fe-4ce9b7a6f0fb parent remove default
OK, I have successfully rebuilt the import file from scratch and was able to import the file into luck perms. I could not import the user UUID data and had to reenter it manually thru Promotions for each use when they logged in. I will have to add any future permission to the file that I add manually in game or using the console for backup purposes because your export is no longer a viable backup option (that was one of your selling points to me installing it). I hope you fix it in the near future.
Please fix the UUID importing so I won't have to promote all my users every time I have issues that might require having to reinstall. I have also turned off the auto update for your plugin.
Well, I took the user info out of the import file and it loaded with only two errors:
- default (already existed)
- bukkit.command.restart (STATE ERROR - owner already has set in context global)
If I do a /lp listgroups; it shows my groups I created. I logged into the game and did a /help and I had default permissions (7 pages of help). I then promoted myself to member and I had no permissions. I then proceeded to promote myself through the entire Track and I still had no permission except for default. I then exported the database and this is what I got:
{
"metadata": {
"generatedBy": "Console",
"generatedAt": "2020-01-03 16:52:37 EST"
},
"groups": {
"default": {
"nodes": []
}
},
"tracks": {},
"users": {}
}
I can see there is data in the database.
And I have permissions for default but not for any other group.
What is going on!!
LuckPerms doesn't have an auto update feature, so not sure what you turned off!
As far as I can tell the import is now working properly. The issue you had with the legacy importer was fixed in b73b73e.
The new import/export format is not intended to be "unzipped" and manually read or edited. It's possible that you corrupted the file by doing that.