This is all for archival purposes Hilton -- A selected quote: Language is like music; we rejoice in beauty, range, and quality in both, and we are demeaned by the repetition of a few sour notes. --Spencer W. Kimball
---------- Forwarded message ---------- From: Joshua Gardner <[email protected]> Date: Tue, Dec 22, 2009 at 1:18 PM Subject: Chat with Joshua Gardner To: [email protected] 12:20 PM me: Should we keep the whole server in bzr, or just the rules app? ------------------------------ 12 minutes 12:33 PM Joshua: why not the whole server? 12:36 PM though, if we make truly pluggable django apps we should be able to put each app into its own bzr repo though that might get confusing 12:37 PM me: Is there a better way to configure the server locally? 12:38 PM Without putting that config in the repos? Joshua: There are ways to get Django settings.py files to play nicely across different boxes. I'll have to decide which way to do it. But we don't need to worry about that till we actually write some code that serves data. 12:39 PM what we should focus on is the API. Either REST of JSON-RPC. JSON-RPC is what Pyjamas works with, and we can use Pyjamas with Django, so I'd lean toward JSON-RPC. 12:40 PM me: /me doesn't know much about it Joshua: basically everything we make on the backend should be all JSON, no HTML+CSS or JS, till we have that down pat. me: I know what JSON is Joshua: it should all be JSON requests, basically we should be able to entirely control the app using something like curl. 12:41 PM then we write a JavaScript frontend. and that allows also writing ActionScript (flash) or GUI frontends. And Django can use CouchDB as a backend with some arm twisting, so that shouldn't be a biggy. 12:42 PM we could even write a CLI frontend, or Twitter, or whatever, if we have a good JSON-RPC or REST API. me: Pyjamas apps can also be run with native python Joshua: I like REST better, but if we want to use Pyjamas either we wait till it supports REST, or we use JSON-RPC. Yeah 12:43 PM still, that's the frontend 12:44 PM so, I'll research actually using REST and JSON-RPC, you can do the same. I've never actually used either. REST is more content-focused while JSON-RPC is for running remote commands, not sure which fits our model better. REST I think. 12:45 PM me: Hmm. If the server is the one running the parly pro logic... Joshua: The parli-pro logic goes in the views and the models, the templates can be regular django templates, pyjamas, or a GTK or Qt app. 12:46 PM That's the point of separating it. Most of the logic should go in the models. Methods are your friend. 12:49 PM we may even be able to do both REST and RPC, both JSON-RPC and XML-RPC. 12:54 PM me: The view receives the motion, asks the model what to do, then returns the resulting template to the client right? 12:55 PM Joshua: what happens in django is the url.py has regular expressions requests are matched against, when one is matched, the associated function is called. The function is just a function, could do anything. Normally it'll interface with database objects in some way. ------------------------------ 8 minutes 1:03 PM Joshua: anyway... any other thoughts? 1:04 PM me: how much lettuce I need to wash for lunch? Joshua: depends on what you're having for lunch. Sandwich? Salad? me: Should I work on flushing out the model with motions? taco salad 1:05 PM Joshua: dunno, um 1:06 PM only motions I haven't put in the rules/models.py are ones that "bring a question again before the assembly", which I think have the same rank as main motions. 1:07 PM though there's got to be a better way than making a class for *every * motion type. It's not very customizable, is it? We wanted to allow custom rules, no? 1:09 PM me: Yeah. Maybe some layer that sets the properties of motions when they are created? Joshua: this does that according to the class. ------------------------------ 6 minutes 1:16 PM me: Hmm. 1:17 PM Joshua: don't worry, we'll figure itou me: How does parliament do it? Joshua: haven't figured that out 1:18 PM haven't really looked 1:22 PM me: Hmm. Files contain motions in a special syntax, possibly containing python code Joshua: We could probably find a way to store the rules in the database and have JSON files you can load up into the db with the rules contained. Then we could write an app to edit rules.
_______________________________________________ Mailing list: https://launchpad.net/~gavel-team Post to : [email protected] Unsubscribe : https://launchpad.net/~gavel-team More help : https://help.launchpad.net/ListHelp

