Ensure exclude and include arrays are arrays of strings.

Fixes #2542.
Update history to reflect merge of #2542 [ci skip]