What a fascinating cause of this phenomenon:
Purple discoloration can occur in alkaline urine as a result of the degradation of indoxyl sulfate (indican), a metabolite of dietary tryptophan, into indigo (which is blue) and indirubin (which is red) by bacteria such as Providencia stuartii, Klebsiella pneumoniae, P. aeruginosa, Escherichia coli, and enterococcus species.