{"action":"opened","issue":{"url":"https://api.github.com/repos/pallets/jinja/issues/720","repository_url":"https://api.github.com/repos/pallets/jinja","labels_url":"https://api.github.com/repos/pallets/jinja/issues/720/labels{/name}","comments_url":"https://api.github.com/repos/pallets/jinja/issues/720/comments","events_url":"https://api.github.com/repos/pallets/jinja/issues/720/events","html_url":"https://github.com/pallets/jinja/issues/720","id":232946968,"number":720,"title":"Vim syntax file and jinja parser handle nested comments differently","user":{"login":"jpassaro","id":6754005,"avatar_url":"https://avatars3.githubusercontent.com/u/6754005?v=3","gravatar_id":"","url":"https://api.github.com/users/jpassaro","html_url":"https://github.com/jpassaro","followers_url":"https://api.github.com/users/jpassaro/followers","following_url":"https://api.github.com/users/jpassaro/following{/other_user}","gists_url":"https://api.github.com/users/jpassaro/gists{/gist_id}","starred_url":"https://api.github.com/users/jpassaro/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jpassaro/subscriptions","organizations_url":"https://api.github.com/users/jpassaro/orgs","repos_url":"https://api.github.com/users/jpassaro/repos","events_url":"https://api.github.com/users/jpassaro/events{/privacy}","received_events_url":"https://api.github.com/users/jpassaro/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2017-06-01T17:05:44Z","updated_at":"2017-06-01T17:05:44Z","closed_at":null,"body":"## Expected Behavior\r\nJinja parser and the shipped Vim plugin have the same interpretation of comment blocks.\r\n\r\n## Actual Behavior\r\nThey interpret them differently!\r\nThe jinja parser does not support nested comments. The vim syntax file apparently thinks it does.\r\n\r\n## Template Code\r\n```jinja\r\n{# stuff.txt #}\r\n1. This is a jinja document!\r\n{#\r\n2. This section was commented out recently.\r\n{# 3. This section was commented out a long time ago.\r\n4. This is the end of the newly-commented-out section.\r\n#}\r\n5. This section is supposed to appear, but Vim thinks it is a comment.\r\n{# vim: ft=jinja\r\n#}\r\n```\r\nAttempting to render:\r\n```pycon\r\n>>> import jinja2, sys\r\n>>> with open('stuff.txt') as f: print jinja2.Template(f.read()).render()\r\n...\r\n\r\n1. This is a jinja document!\r\n\r\n5. This section is supposed to appear, but Vim thinks it is a comment.\r\n\r\n>>> print sys.version\r\n2.7.13 (default, Dec 18 2016, 07:03:39)\r\n[GCC 4.2.1 Compatible Apple LLVM 8.0.0 (clang-800.0.42.1)]\r\n>>> print jinja2.__version__\r\n2.9.5\r\n```\r\nVim screenshot:\r\n![screen shot 2017-06-01 at 1 04 52 pm](https://cloud.githubusercontent.com/assets/6754005/26691397/f3b1552e-46ca-11e7-8d50-a0e7770e9159.png)\r\n\r\n"}}
{"actor":{"display_login":"jpassaro"}}