Upgrading Craft 2 to 3 hits database error I'm working on upgrading a site from Craft2 to Craft3. I've run through the steps in the upgrade guide and when I go to /admin and press the button to run the Database upgrade I get the following error.

Integrity constraint violation: SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry 'createfoldersinvolume:bb790fdf-3d6b-46b8-a023-b9f7ffe8aba5' for key 'craft_userpermissions_name_unq_idx'
The SQL being executed was: UPDATE craft_userpermissions SET name='createfoldersinvolume:bb790fdf-3d6b-46b8-a023-b9f7ffe8aba5', dateUpdated='2019-02-04 17:39:32' WHERE id=173

Migration: craft\migrations\m180518_173000_permissions_to_uid



I can restore the database so that's fine but not sure how best to proceed with the upgrade. Any help would be appreciated!
This sounds like a bug, you should probably report it directly to support@craftcms.com.

I'm posting this as an answer however, because you may be able to skirt the issue... Try updating to Craft 3.0.x first, and then updating the 3.1.x from there.