-
Notifications
You must be signed in to change notification settings - Fork 38
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
Simplate work #481
Simplate work #481
Conversation
@pjz I've updated our labels a bit to fit the rest of Gratipay (nixed |
db2c58b
to
a7129ad
Compare
@@ -0,0 +1,5 @@ | |||
|
|||
# for backwards compatibility with aspen-renderer modules |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Or should we update all of the renderers along with this PR?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Baby steps. Let's not break backward compatibility just yet. Esp. Since we might be breaking simplates out entirely.
@pjz I'm applying |
Yes. Sorry, forgot about that. |
Note this also fixes #417, as a website object is no longer needed to instantiate a simplate. |
I get the feeling @whit537 has been avoiding this review. |
I would say "warming up to it." ;-) |
po-TAY-to, po-TAH-to... |
!m @pjz |
Regularize simplates so they all require at least 3 sections now: 2 of python, and at least one template
Also elucidate response context modification
@@ -8,7 +8,7 @@ | |||
from __future__ import unicode_literals | |||
|
|||
from . import Renderer, Factory | |||
from .. import json | |||
from ... import json |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We still have aspen.json
? Weren't we going to move that to aspen.simplates.json
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's the json registry; It'll move, I just haven't gotten there yet.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So maybe even to aspen.simplates.renderers.json_dump
?
The concept of `state` belongs to algorithm.py, which shouldn't leak over into simplates.
uhh... WTF? why are you doing this work here instead of merging my PR and then doing it in new PRs? |
ff34ad0
to
d5d48d2
Compare
1aec879
to
d5d48d2
Compare
Cool. |
We can't get a test for the |
Other than that I think I just need to grok https://github.com/gratipay/aspen-python/pull/481/files#r36929962. |
There's as many tests for |
Well, what we want to test is that it's called properly from wherever we had |
Well, where we originally had |
That was limited to this file, because it's declared here and not imported anywhere else. I think it's actually limited to the four times in this block (twice per error message). |
I guess we didn't have a test for it before this PR. Out of scope! |
!m @pjz |
Get rid of
is_bound
and make all simplates require at least three sections, per #297