Utils

class salic_api.utils.MLStripper

Strip HTML from strings in Python Has some fixes to the stackoverflow version https://stackoverflow.com/questions/753052/strip-html-from-strings-in-python

salic_api.utils.decrypt(text)

Uses AES to decrypt text with a global secret key.

It extracts the initialization vector from the input message.

salic_api.utils.encrypt(text)

Uses AES to encrypt text with a global secret key.

It saves the initialization vector with the resulting message.

salic_api.utils.pc_quote(st)

Comenta string com sinais de “%”

salic_api.utils.timer(action, verbose=True)

Log results for the time required to execute the given action.

Used as a context manager: >>> with timer(“foo”): … print(“hello world!”)