Partial fix Importing an addon problems (phrase map rebuild)


I installed about 5 or so addons with no problems on my site. Unusually, I installed an addon and it failed to install today. when It was rebuildig cahces it says an error message, then redirects me to another page that describes this info:
Server Error

Mysqli statement execute error : Duplicate entry '1-Quote' for key 2
  1. Zend_Db_Statement_Mysqli->_execute() in Zend/Db/Statement.php at line 297
  2. Zend_Db_Statement->execute() in Zend/Db/Adapter/Abstract.php at line 479
  3. Zend_Db_Adapter_Abstract->query() in Zend/Db/Adapter/Abstract.php at line 574
  4. Zend_Db_Adapter_Abstract->insert() in XenForo/Model/Phrase.php at line 902
  5. XenForo_Model_Phrase->insertPhraseMapForLanguages() in XenForo/CacheRebuilder/Phrase.php at line 37
  6. XenForo_CacheRebuilder_Phrase->rebuild() in XenForo/ControllerHelper/CacheRebuild.php at line 26
  7. XenForo_ControllerHelper_CacheRebuild->rebuildCache() in XenForo/ControllerAdmin/Tools.php at line 64
  8. XenForo_ControllerAdmin_Tools->actionCacheRebuild() in XenForo/FrontController.php at line 310
  9. XenForo_FrontController->dispatch() in XenForo/FrontController.php at line 132
  10. XenForo_FrontController->run() in /srv/www/vhosts/ at line 13
any addon I install / uninstall I get this error. I'm guessing that theres a problem with the tables in mysql db but I am not sure how to fix this. I dont think / know I did anything to cause this

Many thanks


XenForo developer
Staff member
I don't legitimately know if this is a bug, but it's related to inserting into the phrase map, and I haven't seen this error there before, so I'm moving this to bugs.

The phrase title in question is "Quote" and we don't usually use phrase titles with capitals, so I suspect that's related.
ahh, I think I know what I did. sorry for the troubles.... (its not a xenforo bug, its a bug in my brain)

I renamed the reply phrase to quote to change it for my members. Shows my level of expertise :p

Going to fix the phrase and see if it makes a difference

EDIT: is there a place where I can download the en lang xml
ahh, I think I fixed it by rebuilding master data via /install ;)

was worried for a bit. theres no bug in the excellent xenforo :D

so, the problem was that I renamed my phrases. Maybe there could be a better way to display this error, point out to the user to rebuild their master data? Incase they make the same mistake


XenForo developer
Staff member
I can see how this could happen. It's tricky to deal with, unless we just change all phrases to be lower case. That's probably the best option, though I worry about the backwards compatibility issues that can create.

As such, this will have to be changed in a future version with fairly dramatic changes.
good to know :)

the problem I experienced was all about renaming an existing phrase, and forgot about it after some time. there may be more problems there than I realise, but it might be useful to have a message display by the title of a phrase explaining the problems that could occur if its changed.