{"action":"created","issue":{"url":"https://api.github.com/repos/Flexget/Flexget/issues/2225","repository_url":"https://api.github.com/repos/Flexget/Flexget","labels_url":"https://api.github.com/repos/Flexget/Flexget/issues/2225/labels{/name}","comments_url":"https://api.github.com/repos/Flexget/Flexget/issues/2225/comments","events_url":"https://api.github.com/repos/Flexget/Flexget/issues/2225/events","html_url":"https://github.com/Flexget/Flexget/pull/2225","id":369639784,"node_id":"MDExOlB1bGxSZXF1ZXN0MjIyNTMzMzg3","number":2225,"title":"Update regex usage for python 3.7","user":{"login":"gazpachoking","id":187133,"node_id":"MDQ6VXNlcjE4NzEzMw==","avatar_url":"https://avatars2.githubusercontent.com/u/187133?v=4","gravatar_id":"","url":"https://api.github.com/users/gazpachoking","html_url":"https://github.com/gazpachoking","followers_url":"https://api.github.com/users/gazpachoking/followers","following_url":"https://api.github.com/users/gazpachoking/following{/other_user}","gists_url":"https://api.github.com/users/gazpachoking/gists{/gist_id}","starred_url":"https://api.github.com/users/gazpachoking/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gazpachoking/subscriptions","organizations_url":"https://api.github.com/users/gazpachoking/orgs","repos_url":"https://api.github.com/users/gazpachoking/repos","events_url":"https://api.github.com/users/gazpachoking/events{/privacy}","received_events_url":"https://api.github.com/users/gazpachoking/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2018-10-12T17:21:22Z","updated_at":"2018-10-16T16:35:25Z","closed_at":null,"author_association":"MEMBER","pull_request":{"url":"https://api.github.com/repos/Flexget/Flexget/pulls/2225","html_url":"https://github.com/Flexget/Flexget/pull/2225","diff_url":"https://github.com/Flexget/Flexget/pull/2225.diff","patch_url":"https://github.com/Flexget/Flexget/pull/2225.patch"},"body":"### Motivation for changes:\r\nFix our usage of re.sub to work on python 3.7\r\n\r\n### Detailed changes:\r\n- Escapes any needed escapes in re.sub replacement patterns\r\n- Also includes circleci test enabling from #2193\r\n\r\n### Addressed issues:\r\n- Fixes #2189\r\n\r\n#### To Do:\r\n- [ ] Add UpgradeActions, any users specifying regex replacements in manipulate plugin which contain unknown escape patterns will have to double escape them. (I think it's unlikely many users are doing this though.)\r\n- [ ] Figure out proper fix for rtorrent client. Currently it works inconsistently across python versions and contains a hack to get test to pass.\r\n"},"comment":{"url":"https://api.github.com/repos/Flexget/Flexget/issues/comments/430307417","html_url":"https://github.com/Flexget/Flexget/pull/2225#issuecomment-430307417","issue_url":"https://api.github.com/repos/Flexget/Flexget/issues/2225","id":430307417,"node_id":"MDEyOklzc3VlQ29tbWVudDQzMDMwNzQxNw==","user":{"login":"JohnDoee","id":667117,"node_id":"MDQ6VXNlcjY2NzExNw==","avatar_url":"https://avatars2.githubusercontent.com/u/667117?v=4","gravatar_id":"","url":"https://api.github.com/users/JohnDoee","html_url":"https://github.com/JohnDoee","followers_url":"https://api.github.com/users/JohnDoee/followers","following_url":"https://api.github.com/users/JohnDoee/following{/other_user}","gists_url":"https://api.github.com/users/JohnDoee/gists{/gist_id}","starred_url":"https://api.github.com/users/JohnDoee/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/JohnDoee/subscriptions","organizations_url":"https://api.github.com/users/JohnDoee/orgs","repos_url":"https://api.github.com/users/JohnDoee/repos","events_url":"https://api.github.com/users/JohnDoee/events{/privacy}","received_events_url":"https://api.github.com/users/JohnDoee/received_events","type":"User","site_admin":false},"created_at":"2018-10-16T16:35:25Z","updated_at":"2018-10-16T16:35:25Z","author_association":"NONE","body":"So I looked through a bit of the rtorrent command argument parsing code.\r\n\r\nMy C++ isn't the best so it might be a bit wrong, anyways:\r\n\r\nArgument parsing starts after first = found\r\nhttps://github.com/rakshasa/rtorrent/blob/f0207ce6548026853ec57ab26f2e57a872f223bb/src/rpc/parse_commands.cc#L148\r\n\r\nVariable parsing: https://github.com/rakshasa/rtorrent/blob/f0207ce6548026853ec57ab26f2e57a872f223bb/src/rpc/parse.cc#L175\r\n\r\nSome helper commands: https://github.com/rakshasa/rtorrent/blob/f0207ce6548026853ec57ab26f2e57a872f223bb/src/rpc/parse.h#L53\r\n\r\nSpecial characters in the given parsing that should probably be escaped for these use-cases:\r\n\r\n* `,` List separator\r\n* `\"` Quote / Grouping an item\r\n* `\\` Escape characters\r\n* `{}` For a list ?\r\n* `()` Some grouping ? can be nested ?\r\n\r\nAlternatively, throw quotes around, escape quotes and strip `\\`"}}
{"actor":{"display_login":"JohnDoee"}}