Issue #2 new

Malformed re.compile

xbello
created an issue

in init.py

{{{

!python

USER_AGENTS = "|".join(load_from_agents_file()) browser_regexs = re.compile(USER_AGENTS, re.I|re.M) }}}

(or modify load_from_agents_file to return the list ready to feed re.compile)

and

{{{

!python

b = browser_regexs.search(user_agent) v = version__regex.search(user_agent[0:4]) }}}

instead of

{{{

!python

b = reg_b.search(user_agent) v = reg_v.search(user_agent[0:4]) }}}

Comments (0)

  1. Log in to comment