writerfilter: convert namespaceids to Python

Change-Id: Ia57a41aba91f00f3c1fb63a82c9793bf43434afb