Bacterial adaptation is constrained in complex communities