[TurboGears] Re: Web Development - Forms and others

2005-10-23 Thread Ian Bicking
[EMAIL PROTECTED] wrote: That can be done easily in TurboGears too. Though there is a few things I don't like about subway, just seeing this blog, that is nothing but style and preference though. I don't like tying logic into presentation. The choice of Cheetah and this form mechanism

[TurboGears] Re: Web Development - Forms and others

2005-10-23 Thread [EMAIL PROTECTED]
thanks. Yes, I like to build the schema in python code as it looks cleaner to my eye. I would rather prefer a way to turn a schema into a presentation. Say if I have field that is string with only 3 valid choice, make that into a radio button or dropdown. This way, when I drop the valid choice

[TurboGears] Re: Does TG can support other templates than Kid ?

2005-10-23 Thread william
I've tried Mozilla, and I've don't find any options saying that the code generated will be XHTML compliant. Mozylla generate br, hr, img, ... Based on suggestions I've received, I've tried nvu. And nvu has an options allowing you to generate XHTML files that kid can manage. Fine BUT I

[TurboGears] Re: rough testing doc

2005-10-23 Thread matthew clark
this is great. Testing is really key to getting an understanding of how a program works. This doc is going to help a lot. Here is some initial feedback - I really dig TestGears. I was able to get some tests running last night in just a few minutes, and it was my first day with the code. Amazing!

[TurboGears] How to generate inline images (with text and numbers) for a registeration page?

2005-10-23 Thread vinjvinj
Is there a way to generate an image with some text and numbers for a registeration page in python/TG?

[TurboGears] Re: How to generate inline images (with text and numbers) for a registeration page?

2005-10-23 Thread Lee McFadden
You are probably looking for something like PIL[1] or PythonMagick[2]. Having used neither myself I can't give you much more info than that I'm afraid. Regards, Lee [1] http://www.pythonware.com/products/pil/ [2] http://starship.python.net/crew/zack/pymagick/ On 23/10/05, vinjvinj [EMAIL

[TurboGears] Re: How to generate inline images (with text and numbers) for a registeration page?

2005-10-23 Thread [EMAIL PROTECTED]
a long while ago, I would use GD library which allows you to draw(including putting text) to a GIF. There is a python binding too. However, the author of that python module moves to PIL so I believe PIL should give you the same functionality and it is wildly available. I don't think you need

[TurboGears] Identity Management for TurboGears

2005-10-23 Thread Jeff Watkins
I just committed the code for the TurboGears identity management support (revision 89). And because this is such new code, I thought it might be helpful to include a short How To for getting everything up and running. The How To is available at:

[TurboGears] Re: Does TG can support other templates than Kid ?

2005-10-23 Thread Tim Lesher
On 10/23/05, william [EMAIL PROTECTED] wrote: I've tried Mozilla, and I've don't find any options saying that the code generated will be XHTML compliant. Mozylla generate br, hr, img, ... Based on suggestions I've received, I've tried nvu. And nvu has an options allowing you to generate

[TurboGears] Re: How to generate inline images (with text and numbers) for a registeration page?

2005-10-23 Thread Ronald Jaramillo
Rui Carmo's PNGCanvas is quite nice for this, no dependencies, compact and understandable. He hasn't implement text/numbers (yet), but you can 'copy/blit' those from another png containing your 'alphabet' or do your own low level character drawing.

[TurboGears] Re: Does TG can support other templates than Kid ?

2005-10-23 Thread william
I just tried this in NVU 1.0 for Windows, and I'm not seeing this problem. On what platform are you running? -- I'm on Gentoo. But, finally, I've found the magic options in Preferences called Don't encode special characters in attributes. That's the solution. To summarize, don't use

[TurboGears] Re: Identity Management for TurboGears

2005-10-23 Thread Elvelind Grandin
But. it depends on RuleDispatch so we need to update setup.py On 10/23/05, Elvelind Grandin [EMAIL PROTECTED] wrote: Wonderful. I will start using it right away :) On 10/23/05, Jeff Watkins [EMAIL PROTECTED] wrote: I just committed the code for the TurboGears identity management support

[TurboGears] Re: Identity Management for TurboGears

2005-10-23 Thread Jeff Watkins
Oops. That's true. Technically nothing actually relies on it yet. But Ian's jsonify code makes use of it, and I have jsonify functions for all the model classes.I suppose I should disable this until Kevin decides whether TurboGears should depend on RuleDispatch.Thanks for finding this.On 23 Oct,

[TurboGears] Re: Identity Management for TurboGears

2005-10-23 Thread Elvelind Grandin
No problems. On 10/23/05, Jeff Watkins [EMAIL PROTECTED] wrote: Oops. That's true. Technically nothing actually relies on it yet. But Ian's jsonify code makes use of it, and I have jsonify functions for all the model classes. I suppose I should disable this until Kevin decides whether

[TurboGears] Re: Identity Management for TurboGears

2005-10-23 Thread Jeff Watkins
I commented out the parts that use jsonify, so this should remove the RuleDispatch requirement (Revision 90).On 23 Oct, 2005, at 12:43 pm, Elvelind Grandin wrote:But. it depends on RuleDispatch so we need to update setup.py --  Jeff Watkins http://metrocat.org/ Computers, they're just a fad.

[TurboGears] Re: Identity Management for TurboGears

2005-10-23 Thread Guy Hulbert
I'm new to tg and I'm not trying to be rude but ... Does none of this exist already ? [ tg philosophy seems to be aimed at reuse ] Why do you have to add it all ? I plan to run turbogears behind apache. Most of the laundry list below seems to be there. The one thing I found missing was a

[TurboGears] Re: How to generate inline images (with text and numbers) for a registeration page?

2005-10-23 Thread Mamading Ceesay
Is this for a captcha? If so, a simple google search on captcha python will yield results like the following: http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/440588 http://captchas.net/sample/python/ http://freshmeat.net/projects/pycaptcha/ Regards, Mamading

[TurboGears] Re: Identity Management for TurboGears

2005-10-23 Thread Guy Hulbert
On Sun, 2005-23-10 at 13:22 -0400, Jeff Watkins wrote: snip Of course, I'm *really* new to Python. So what do I know. I have a couple of books but I am working with someone else who will write most of the code (he's buried right now, fixing C++ bugs in another piece of our project). Why do

[TurboGears] Re: Identity Management for TurboGears

2005-10-23 Thread [EMAIL PROTECTED]
Sounds that what you want is not some infra things of TurboGears(what Jeff is working on), but more like a generic web apps that allows you to manipulate some database backend, be it RDBMS/LDAP or even flat file(like .htaccess) or combination of that. I am not sure what platform you are on but

[TurboGears] Re: rough testing doc

2005-10-23 Thread loki77
I just started using TurboGears yesterday, and saw your document. It's well written, even for such an early draft. Unfortunately I couldn't get your method of testing to work with 'python setup.py testgears'. When I ran it with the verbose option it looked as though the only place it was

[TurboGears] Re: Easiest Way to Access cherrypy.config from page templates?

2005-10-23 Thread loki77
Oh, and here's the template that it calls. Sorry: !DOCTYPE html PUBLIC -//W3C//DTD XHTML 1.0 Transitional//EN http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd; ?python import sitetemplate ? html xmlns=http://www.w3.org/1999/xhtml; xmlns:py=http://purl.org/kid/ns#; py:extends=sitetemplate

[TurboGears] Re: Identity Management for TurboGears

2005-10-23 Thread Kevin Dangoor
On 10/23/05, Jeff Watkins [EMAIL PROTECTED] wrote: Oops. That's true. Technically nothing actually relies on it yet. But Ian's jsonify code makes use of it, and I have jsonify functions for all the model classes. I suppose I should disable this until Kevin decides whether TurboGears should

[TurboGears] Re: Easiest Way to Access cherrypy.config from page templates?

2005-10-23 Thread Kevin Dangoor
On 10/23/05, loki77 [EMAIL PROTECTED] wrote: Jeez- and as I post that last bit of code I realize where I screwed up. My template was wrong. Sorry for the noise, and thanks if you took the time to read through this. There's nothing like talking it out to solve a problem sometimes :) By the

[TurboGears] Validation into the model

2005-10-23 Thread João Paulo Fernandes Farias
Hi! I was following the discussion about form validation and I think validation should go into the model. I'm not sure, but I think FormEncode integrates with SQLObject. Maybe Ian can provide more info on this. If that is true, we could think a way of integrating that with cherrypy, and make

[TurboGears] Re: Identity Management for TurboGears

2005-10-23 Thread Kevin Dangoor
On 10/23/05, Guy Hulbert [EMAIL PROTECTED] wrote: I'm new to tg and I'm not trying to be rude but ... Does none of this exist already ? [ tg philosophy seems to be aimed at reuse ] Why do you have to add it all ? I plan to run turbogears behind apache. Most of the laundry list below

[TurboGears] Re: rough testing doc

2005-10-23 Thread Kevin Dangoor
On 10/23/05, matthew clark [EMAIL PROTECTED] wrote: this is great. Testing is really key to getting an understanding of how a program works. This doc is going to help a lot. Here is some initial feedback - I really dig TestGears. I was able to get some tests running last night in just

[TurboGears] Re: rough testing doc

2005-10-23 Thread Kevin Dangoor
TestGears looks for modules named test-* anywhere inside your project's package. There's a little bit more info about TestGears on its page: http://www.turbogears.org/testgears/ (Note again that TestGears will be deprecated in favor of Nose sometime soon.) Kevin On 10/23/05, loki77 [EMAIL

[TurboGears] Re: Using formencode.fields.*

2005-10-23 Thread Kevin Dangoor
On 10/22/05, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: Sounds interesting but does it belong to controllers.py ? That seems like presentation to me and say if one day, I want to put a layer of dojo on top of the web page, will it mean lots of change to the python code ? Otherwise, it is a

[TurboGears] Re: Identity Management for TurboGears

2005-10-23 Thread Guy Hulbert
On Sun, 2005-23-10 at 15:21 -0400, Kevin Dangoor wrote: On 10/23/05, Guy Hulbert [EMAIL PROTECTED] wrote: snip I plan to run turbogears behind apache. Most of the laundry list below snip I'm sure you won't be the only person running behind Apache. I want What if your authentication is

[TurboGears] Re: setuptools and file exists problem

2005-10-23 Thread Kevin Dangoor
On 10/23/05, Phillip J. Eby [EMAIL PROTECTED] wrote: Not at the moment; just 'rm -rf' anything you're not using. In the 0.7 or 0.8 timeframe, there will be a 'nest' tool for managing eggs, which will support listing and deleting eggs, along with other to-be-determined package management

[TurboGears] Re: rough testing doc

2005-10-23 Thread loki77
Awesome. Thanks for the pointer, Kevin.

[TurboGears] Re: Easiest Way to Access cherrypy.config from page templates?

2005-10-23 Thread loki77
I'm going to sound like a broken record here soon, but thanks Kevin :) I thought I remembered something about the variable provider, but couldn't remember if it was a cherrypy or turbogears thing.

[TurboGears] Re: kid = 0.7adev-r186 ?

2005-10-23 Thread Guy Hulbert
On Sun, 2005-23-10 at 15:50 -0400, Kevin Dangoor wrote: On 10/22/05, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: found the reason. I am using svk to mirror svn repo. That don't have .svn in the checkout. But svk is much nicer to use than svn :-) I'm glad you found that. I never

[TurboGears] Re: Identity Management for TurboGears

2005-10-23 Thread Robert Leftwich
Jeff Watkins wrote: I just committed the code for the TurboGears identity management support... Looks good! Thanks for all your hard work on this. Some of the things I still have to add: Can I suggest that you change the model to use a PackageHub instead of an AutoConnectHub to

[TurboGears] Re: Identity Management for TurboGears

2005-10-23 Thread Jeff Watkins
On 23 Oct, 2005, at 4:47 pm, Robert Leftwich wrote: Can I suggest that you change the model to use a PackageHub instead of an AutoConnectHub to allow the identity data to be sourced from a different db if required? Excellent idea. I need to look at PackageHub a little closer, but it

[TurboGears] TurboGears the Podcast

2005-10-23 Thread rdsteph
Can be found at http://www.awaretek.com/python/index.html

[TurboGears] Working with an svn checkout

2005-10-23 Thread Robert Leftwich
I've just switched to working from an svn checkout as described in 'Developing with eggs' from http://www.turbogears.org/community/contributing.html. Although the latest TG code is used when running apps it doesn't appear to use the code from the thirdparty directory of the checkout, e.g. the

[TurboGears] Re: TurboGears the Podcast

2005-10-23 Thread Lee McFadden
Is it just me, or are the podcasts listed there only a small part of the whole podcast? Lee On 23/10/05, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: Can be found at http://www.awaretek.com/python/index.html

[TurboGears] Re: TurboGears the Podcast

2005-10-23 Thread Ron Stephens
Hmmm, should be the whole podcasts... Maybe try http://www.awaretek.com/index.xml or worst case go to http://www.podcastalley.com/podcast_details.php? pod_id=5786 and click on the podcast title you want... But I am perturbed. I get the whole podcasts when I click on the

[TurboGears] Re: TurboGears the Podcast

2005-10-23 Thread Lee McFadden
It's odd. I think it may have something to do with a combination of Firefox, Quicktime and possibly the host of the MP3. I just subscribed in iTunes (searching in the apple podcast directory for python411 brought it straight up) and the podcasts are downloading in full. On 23/10/05, Ron

[TurboGears] Re: TurboGears the Podcast

2005-10-23 Thread rdsteph
OK. Sorry for the trouble. As I say, every once in a while, something strange happens with the podcast feeds causing incomplete downloads. I do not know what it is yet. Ron Stephens

[TurboGears] Re: TurboGears the Podcast

2005-10-23 Thread Lee McFadden
No problem. I've managed to get them now and I'm uploading them to my phone to listen to at work tomorrow. :) On 23/10/05, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: OK. Sorry for the trouble. As I say, every once in a while, something strange happens with the podcast feeds causing incomplete

[TurboGears] Re: Does TG can support other templates than Kid ?

2005-10-23 Thread Tim Lesher
On 10/23/05, william [EMAIL PROTECTED] wrote: I just tried this in NVU 1.0 for Windows, and I'm not seeing this problem. On what platform are you running? -- I'm on Gentoo. But, finally, I've found the magic options in Preferences called Don't encode special characters in

[TurboGears] Re: kid = 0.7adev-r186 ?

2005-10-23 Thread [EMAIL PROTECTED]
prmiarily mirroring. I don't need to remember all the urls of modules used in TurboGears. And I do have some local changes to some of them. Also becaue I have some linux kernel patches collection too, I need the star merge of svk. It means I can seperate my version with upstream and merge

[TurboGears] Re: Validation into the model

2005-10-23 Thread Kevin Dangoor
On 10/23/05, Ian Bicking [EMAIL PROTECTED] wrote: And then extract these into a schema. But while you might want this validation on a form, I'm of the opinion that it's better to be more lax when doing programmatic updates, especially because there might not be a feedback cycle to correct

[TurboGears] Re: setuptools and file exists problem

2005-10-23 Thread Phillip J. Eby
At 07:07 PM 10/23/2005 -0500, Ian Bicking wrote: Kevin Dangoor wrote: I thought that was why Ian made paster? Yes, there would be overlap, and it would be good to consider how best to deal with that. If the paster create code goes into nest, I have no problem with deprecating its presence in

[TurboGears] How to track Multiyear stats?

2005-10-23 Thread modmans2ndcoming
I have this data model for an amateur hockey league. they want to track the stats by year as well. I thought about making the entries by player ID and year, but I am unsure how to make that happen. Any help will be appreciated.

[TurboGears] Re: setuptools and file exists problem

2005-10-23 Thread Ian Bicking
Phillip J. Eby wrote: At 07:07 PM 10/23/2005 -0500, Ian Bicking wrote: Kevin Dangoor wrote: I thought that was why Ian made paster? Yes, there would be overlap, and it would be good to consider how best to deal with that. If the paster create code goes into nest, I have no problem

[TurboGears] Re: Identity Management for TurboGears

2005-10-23 Thread Kevin Dangoor
On 10/23/05, Jeff Watkins [EMAIL PROTECTED] wrote: Excellent idea. I need to look at PackageHub a little closer, but it seems like the right thing to do. Luckily, you don't have to look at it a little closer... just replace AutoConnectHub with PackageHub and you're golden :) On that note,

[TurboGears] Re: Working with an svn checkout

2005-10-23 Thread Kevin Dangoor
I've just updated the contributing page to have a section about dealing with dependencies. The short of it is that CherryPy does not use setuptools and therefore doesn't generate an egg. (The other projects all use setuptools.) I *believe* that, from the thirdparty directory, you can run

[TurboGears] Re: Identity Management for TurboGears

2005-10-23 Thread Tim Lesher
On 10/23/05, Jeff Watkins [EMAIL PROTECTED] wrote: I just committed the code for the TurboGears identity management support (revision 89). And because this is such new code, I thought it might be helpful to include a short How To for getting everything up and running. The How To is

[TurboGears] Re: Identity Management for TurboGears

2005-10-23 Thread Jeff Watkins
On 23 Oct, 2005, at 11:05 pm, Tim Lesher wrote: This looks really nice, but I'm having a spot of difficulty with the how-to, running against an otherwise-happy svn installation (rev 91). Adding the @identity.require( group=admin ) decorator to any exposed method (secured, index, what have

[TurboGears] Re: Validation into the model

2005-10-23 Thread Ian Bicking
Kevin Dangoor wrote: On 10/23/05, Ian Bicking [EMAIL PROTECTED] wrote: And then extract these into a schema. But while you might want this validation on a form, I'm of the opinion that it's better to be more lax when doing programmatic updates, especially because there might not be a feedback

[TurboGears] Re: Identity Management for TurboGears

2005-10-23 Thread Tim Lesher
On 10/23/05, Jeff Watkins [EMAIL PROTECTED] wrote: What it's choking on is, strangely, the py:extends attribute of the html element: - html xmlns=http://www.w3.org/1999/xhtml; xmlns:py=http://purl.org/kid/ns#; py:extends='master.kid' - I'll ask the obvious

[TurboGears] Re: relational tables in SQLObject

2005-10-23 Thread Ian Bicking
Robin Munn wrote: As for primary keys made of multiple columns, SQLObject doesn't support that, and I believe it never will, due to a deliberate design decision. See the note at the bottom of http://sqlobject.org/SQLObject.html#many-to-many-relationships for a brief discussion as to why.