{"action":"opened","issue":{"url":"https://api.github.com/repos/5j9/wikitextparser/issues/4","repository_url":"https://api.github.com/repos/5j9/wikitextparser","labels_url":"https://api.github.com/repos/5j9/wikitextparser/issues/4/labels{/name}","comments_url":"https://api.github.com/repos/5j9/wikitextparser/issues/4/comments","events_url":"https://api.github.com/repos/5j9/wikitextparser/issues/4/events","html_url":"https://github.com/5j9/wikitextparser/issues/4","id":158082986,"number":4,"title":"Parse item lists","user":{"login":"gsauthof","id":464832,"avatar_url":"https://avatars.githubusercontent.com/u/464832?v=3","gravatar_id":"","url":"https://api.github.com/users/gsauthof","html_url":"https://github.com/gsauthof","followers_url":"https://api.github.com/users/gsauthof/followers","following_url":"https://api.github.com/users/gsauthof/following{/other_user}","gists_url":"https://api.github.com/users/gsauthof/gists{/gist_id}","starred_url":"https://api.github.com/users/gsauthof/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gsauthof/subscriptions","organizations_url":"https://api.github.com/users/gsauthof/orgs","repos_url":"https://api.github.com/users/gsauthof/repos","events_url":"https://api.github.com/users/gsauthof/events{/privacy}","received_events_url":"https://api.github.com/users/gsauthof/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2016-06-02T08:13:39Z","updated_at":"2016-06-02T08:13:39Z","closed_at":null,"body":"This is not a bug, this is a feature request.\r\n\r\nAs far as I can see, currently, there is no direct support for parsing item lists.\r\n\r\nThat means for something like this:\r\n\r\n    The North American Numbering Plan Area includes:\r\n    *[[North American Numbering Plan|+1]] {{flag|Canada}}\r\n    *[[North American Numbering Plan|+1]] {{flag|United States}}, including United States territories:\r\n    **[[Area code 340|+1 340]] {{flag|United States Virgin Islands}}\r\n    **[[Area code 670|+1 670]] {{flag|Northern Mariana Islands}}\r\n\r\nThe API could be similar to what is available via `sections` or `tables`.\r\n\r\nFor example:\r\n\r\n    import wikitextparser as wtp\r\n    p = wtp.parse(str)\r\n    p.lists[0].items[0]\r\n    p.lists[0].level # i.e. hiearrchy level as indicated by the stars\r\n\r\nMotivation: sometimes it is useful to be able to iterate over such item lists when extracting data.\r\n\r\nMy current workaround: use wikitextparser to traverse over some highlevel structure like sections and the `splitlines()` on the `contents`, text based filter for asterisks and the re-parse those lines again.\r\n\r\n"}}
{"actor":{"display_login":"gsauthof"}}