View Single Post
Old 01-03-2022, 01:27 PM   #10
lomkiri
Groupie
lomkiri ought to be getting tired of karma fortunes by now.lomkiri ought to be getting tired of karma fortunes by now.lomkiri ought to be getting tired of karma fortunes by now.lomkiri ought to be getting tired of karma fortunes by now.lomkiri ought to be getting tired of karma fortunes by now.lomkiri ought to be getting tired of karma fortunes by now.lomkiri ought to be getting tired of karma fortunes by now.lomkiri ought to be getting tired of karma fortunes by now.lomkiri ought to be getting tired of karma fortunes by now.lomkiri ought to be getting tired of karma fortunes by now.lomkiri ought to be getting tired of karma fortunes by now.
 
lomkiri's Avatar
 
Posts: 167
Karma: 1497966
Join Date: Jul 2021
Device: N/A
Quote:
Originally Posted by ugosan View Post
I have modified the script because it was giving me "IndexError: no such group", but now it works fine
It depends of the search string you've used. In the one I wrote for Chouette:
class="noteref">\K(\d+)(</a>)
there were 2 capturing groups: group(1) -> (\d+) and group(2) -> (</a>)

You probably put a different string with only one capturing group, so you correctly adapted the code of the function.

Quote:
Originally Posted by ugosan View Post
Thank you very much for your support.
Most welcome :-).
lomkiri is offline   Reply With Quote