-
Notifications
You must be signed in to change notification settings - Fork 307
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Renderer.context won't update when looping through an array #158
Comments
Rewriting it as dicts won't work either:
|
Yes, it looks like there may be an issue. I will try to track this down. |
It looks like the issue is that calling This is related to this TODO. One work-around is to avoid changing the original renderer's context by creating a new renderer each time:
Another work-around is to make sure you're always referencing the original context:
I think issue #157 is related and may have other suggestions. |
Thanks, this works fine:
|
My target: print the following lines:
without a final comma.
I tried this way:
The output:
The culprit is the invocation to render() inside rstrip. Notice how, during the second call, the 3d element of the ContextStack is exactly identical to the previous call, instead of changing to {'gangsters': [ {'name': 'Tim'}, {'name': 'Tom'} , {'name': 'Todd'}]}.
Is this a bug, or am I missing something?!?
The text was updated successfully, but these errors were encountered: