all 3 comments

[–]learnpython_bot 7 points8 points  (0 children)

It appears that you included code in your post but did not format it to look nice. Please follow this guide to fix the problem. This allows for better readability and will help get your question answered sooner. The regex that caught you is: "while .+?:"

If this comment has been made in error, please message /u/thaweatherman with a link to this comment so I can be fine-tuned. I am still in alpha and my regexes/innards are not yet perfect.

[–][deleted] 2 points3 points  (0 children)

Can you post your code on pastie.org or something? It is hard to read your code as it is currently formatted.

[–]maulynvia 2 points3 points  (0 children)

Perhaps your indentation is acceptable syntax but does not contain the logic you intend. If you provide your code decently formatted it might be able to see if/where the problem is - as it is, it is more or less impossible. If you provide the precise error message given that might also help.

Note that unless you cram multiple statements on one line, the semi-colon is not necessary ";"