| 1 | Thank for fixing the issue, I just came across a mistake in the regex I posted above: |
| 2 | {{{ |
| 3 | ( |
| 4 | r"""(?P<matched>(?P<import_as>import\s*\*as\s\S)+\s+from\s*["'](?P<url>[./].*?)["']\s*;)""", |
| 5 | """%(import_as)s from "%(url)s";""", |
| 6 | ), |
| 7 | }}} |
| 8 | Should be (the plus should be for one of more chars of the import as name, not groups, so the plus moved one char to the left: |
| 9 | {{{ |
| 10 | ( |
| 11 | r"""(?P<matched>(?P<import_as>import\s*\*as\s\S+)\s+from\s*["'](?P<url>[./].*?)["']\s*;)""", |
| 12 | """%(import_as)s from "%(url)s";""", |
| 13 | ), |
| 14 | }}} |