0

need help with Python regex for URLs

    re.findall(r"((^hxxp|http|https)+:+//+([a-zA-Z]{1,32})+((.){1,4})+(([a-z]|.){1,10}))", datastream)

This is matching full URLs as designed but also chunks of the string to be matched resulting in Python crapping out.

I would prefer to use findall using .match would require some sizeable changes.

trophyfish
  • 11
  • 2

0 Answers0