I think this is a bug I've stumbled upon and it's driving me up the wall. Referring to this question, I've got the same setup:
I thought my prayers had been answered. However, my problem arises because I accidentally included a PDF into the master document. Was a slip of the finger, I was trying to copy and paste into a completely different document but evidently had the wrong window active. I didn't think anything of it and I simply pressed delete and went on my merry way.
Ever since, whenever I try to compile, I get the dreaded xcolor error message of Undefined color "Maroon". Even though the PDF isn't even in my document anymore and there is no (visible) PDF environment in the master document. I've tried everything suggested from other answers but to no avail. It seems that as soon as the PDF was pasted into the master document, some sort of persistent change has happened in LyX which is now causing the trouble. Question is, how the heck do I fix this? I've closed the program, reconfigured, shut down, deleted temporary files etc. etc. but no good.
In case you ask, I have PDFs in Figure environments in some of the child documents which comprise the master document, and had no problems before this copy and paste debacle.