codificação aberta python utf-8
from io import open
f = open("test", mode="r", encoding="utf-8")
Maren-of-Alterside
from io import open
f = open("test", mode="r", encoding="utf-8")
import codecs # Python standard library
codecs.encode("A strange character","utf-8")
# this would give you the utf-8 encoded bytes
# -*- coding: utf-8 -*-