Python での BOM書込み

Python でBOMを書き込む時は、以下のようにする

import codecs
with codecs.open(outputPath, "a+", "utf-8") as fd:
        fd.write(u'\ufeff')