How to update a form in formwizard

2013-03-07 Thread Rob
I have a problem with formwizard. In step 3 of the wizard I use a filtered query which depends on choices from step 1 and 2. My wizard works fine when moving forward, but when a user presses previous, or changes the choices of step 1 and 2, things go wrong (validation error or filters won't

Re: RSS combinator

2013-03-07 Thread hinnack
Is'n that something for yahoo pipes? http://pipes.yahoo.com/pipes/ Of course pipes are not django... Hinnack Am Freitag, 8. März 2013 04:24:39 UTC+1 schrieb Lachlan Musicman: > > Hola, > > Does anyone know of a django app that would take a number of rss feeds > >1 and turn it into a single

How can my JQuery Sliderbar pass a value to the Veiw and cause the View to execute?

2013-03-07 Thread 7equivalents
I am trying to create my first Django AJAX App. I have a template that creates a JQuery slider bar. I also have a datamodel which has a sliderbarValue entry and a View that writes to it. I need to know how to make the Javascript call the View and pass it the slider bar value. Here is the

Question modelformset_factory with initial values

2013-03-07 Thread carlos
Hi is posible fill forms with initial values for example -- models.py - class Model1(models.Model): field1 = models.CharField() field2 =models.CharField() CHOICE_ONE = ( (1,'one'), (2, 'two'), (3, 'three'), (4, 'four') ) class Model2(models.Model):

Re: How to pass a value from a Django View to a JQuery Slider bar.

2013-03-07 Thread 7equivalents
> > Thankyou Daniel, That's my name too I appreciate that, it clears > things up and now I understand why the tinkering I did worked! > Thankyou Tom, Gabriel, and everyone for the help... Please follow my next post where I seek help one more time(Need slider to write to database),

Re: RSS combinator

2013-03-07 Thread Thomas Lockhart
On 3/7/13 7:24 PM, Lachlan Musicman wrote: Hola, > > Does anyone know of a django app that would take a number of rss > feeds and turn it into a single blog feed/stream? I'm using feedjack and I think it has features to amalgamate the feeds; I use it to subscribe to feeds then choose sets of

Re: RSS combinator

2013-03-07 Thread Lachlan Musicman
I think feedparser is what I'm after - then it's just a matter of wrapping a template around the results. It could be done with any template really... https://pypi.python.org/pypi/feedparser https://code.google.com/p/feedparser/ Cheers L. On 8 March 2013 14:50, Shawn Milochik

Re: RSS combinator

2013-03-07 Thread Shawn Milochik
I doubt there's a Django app for that -- it's not a problem for a Web framework. You may be able to find a project that does this on Github or Bitbucket. RSS feeds are just XML files. You need something that will parse the XML from multiple files, then re-write one XML file containing the items

RSS combinator

2013-03-07 Thread Lachlan Musicman
Hola, Does anyone know of a django app that would take a number of rss feeds >1 and turn it into a single blog feed/stream? Note, I don't want to create an rss feed of local content - I want to create an amalgam of other feeds. eg: take https://www.djangoproject.com/rss/community/blogs/

Re: Django + Raspberry PI

2013-03-07 Thread dgregory46
The RPi board would fit on a car, but you would have to remove the hdmi and power connectors to keep from being too wide. However I am considering mounting an arduino with flashing leds for my granddaughter's car next year. (Off topic apology) On Wednesday, March 6, 2013 9:59:31 PM UTC-6, Tim

Re: Help with Django form wizard.

2013-03-07 Thread Dilip M
On Thu, Mar 7, 2013 at 9:21 PM, Dilip M wrote: > Hi, > > Here is what I am trying to do. Get the root folder name in form 1 and > list the found sub directories (matching a pattern) and give an > option for user to select the sub dirs. Once selected, I want to save the >

Django and Jenkins, and django-jenkins

2013-03-07 Thread Alessandro Pelliciari
Hi guys, help me to resolve this problem. I'll tell you the whole story :) A week ago i've set up a Jenkins server, installed django-jenkins, and set up a job for my tests and pylint, pep8 etc. In my tests i have selenium tests, with setup and teardown methods. Everything worked smooth until,

Re: Extending the base file depending on User type

2013-03-07 Thread Sandeep kaur
On Wed, Mar 6, 2013 at 10:55 PM, Sam Solomon wrote: > Tom Evans has probably the correct answer for you, but another thing that > def some_view(request): > return render(request, "path/to/template.html", {"view_context": ...}) # > The "render(request" portion will

Re: Django + Raspberry PI

2013-03-07 Thread Amirouche
On Thursday, March 7, 2013 8:08:45 PM UTC+1, Amirouche wrote: > > http://amirouche.github.com/blog/cross-compiling-a-gentoo.html > This will be a long way home for you I recommend you setup a cross compiler and use distcc -- You received this message because you are subscribed to the Google

Re: Django + Raspberry PI

2013-03-07 Thread Amirouche
http://amirouche.github.com/blog/cross-compiling-a-gentoo.html On Thursday, March 7, 2013 8:05:50 PM UTC+1, Amirouche wrote: > > > > On Friday, March 1, 2013 5:04:47 PM UTC+1, Shawn Milochik wrote: >> >> Yep, I got my full development environment for one of my company's >> applications running

Re: Django + Raspberry PI

2013-03-07 Thread Amirouche
On Friday, March 1, 2013 5:04:47 PM UTC+1, Shawn Milochik wrote: > > Yep, I got my full development environment for one of my company's > applications running on it with almost no problem. The one exception > was MongoDB, which is for x86 only, so I had to compile a fork, which > took about

Re: queryset minimization

2013-03-07 Thread Nikolas Stevenson-Molnar
Also, I strongly recommend reading through this document for an idea of when queries do and don't hit the database: https://docs.djangoproject.com/en/1.5/topics/db/optimization/ Additionally, take a look at django-debug-toolbar, which will show you all the queries that go into returning a view,

Re: queryset minimization

2013-03-07 Thread Nikolas Stevenson-Molnar
1. No, the two will execute identically. 2. No, `group` is loaded by select_related, and `name` is a field on group, so it's loaded when group is, unless you explicitly exclude it. 3. That's one query. However, if you're only grabbing the first result, select_related isn't even necessary... just

Re: How to customize Django Admin interface with custom urls and views?

2013-03-07 Thread John James
Thanks a lot buddy!! I think I dig deeper by links you have posted and figure out my misunderstandings. Seem I should define my views in application/views.py file and then define the urls rules! That's great news =)) -- You received this message because you are subscribed to the Google Groups

Re: queryset minimization

2013-03-07 Thread Fatih Tiryakioglu
Thank you Nicolas, This works: reg = p.groupregistration_set.all().select_related('group') name = reg[0].group.name This also works: name = p.groupregistration_set.all().select_related('group')[0].group.name 1) Is there any difference? Which one is beter. 2) reg =

Django Form Designer

2013-03-07 Thread Daniele Procida
I like and use Django Form Designer, , but it hasn't been updated for a while and needs some work. For example, it needs better docs and tests, while there are a number of outstanding pull requests. I'm hoping to hear back from Samuel

Re: queryset minimization

2013-03-07 Thread Nikolas Stevenson-Molnar
The biggest hit is probably going to be the reg.group call. You can optimize that by using select_related (), which will take what is currently 1 + (number of group registrations for the user) queries and turn it into 2 queries: reg = p.groupregistration_set.all().select_related('group') More on

Help with Django form wizard.

2013-03-07 Thread Dilip M
Hi, Here is what I am trying to do. Get the root folder name in form 1 and list the found sub directories (matching a pattern) and give an option for user to select the sub dirs. Once selected, I want to save the model. 1. How to dynamically display found sub directories in form 2. I have

Re: I screwed up my django site using touch

2013-03-07 Thread Bill Freeman
And a last stop gap, assuming the server is *nix, the find command will find all files with changes newer than a given time (though the syntax can be squirrelly. On Thu, Mar 7, 2013 at 10:42 AM, Shawn Milochik wrote: > On Thu, Mar 7, 2013 at 10:38 AM, frocco

Re: I screwed up my django site using touch

2013-03-07 Thread Shawn Milochik
On Thu, Mar 7, 2013 at 10:38 AM, frocco wrote: > Thanks you, I think I will only use Pycharm now to help prevent this issue > again. > I hope future versions will offer better trace. Even better, use version control, such as git. Then your editor will be irrelevant and it

Re: I screwed up my django site using touch

2013-03-07 Thread frocco
Thanks you, I think I will only use Pycharm now to help prevent this issue again. I hope future versions will offer better trace. On Thursday, March 7, 2013 10:14:38 AM UTC-5, ke1g wrote: > > Yes. I'm not happy with the stack trace either. The trouble is that the > import mechanism got the

Re: I screwed up my django site using touch

2013-03-07 Thread frocco
Thanks, I did not know this. On Thursday, March 7, 2013 10:01:28 AM UTC-5, Roberto López López wrote: > > > If you are using pycharm, you just need to use the local history to > check which indents you have changed. > > (right click over the file you want to check - local history - show >

Re: I screwed up my django site using touch

2013-03-07 Thread Bill Freeman
Yes. I'm not happy with the stack trace either. The trouble is that the import mechanism got the error, and it does not deign to mention the file path or even the module path. That is potentially a shortcoming in Django, since django.utils.importlib presumably could have caught this exception

Re: I screwed up my django site using touch

2013-03-07 Thread Roberto López López
If you are using pycharm, you just need to use the local history to check which indents you have changed. (right click over the file you want to check - local history - show history - ...) On 03/07/2013 03:58 PM, frocco wrote: > The problem with the stack trace, is that I could not tell what

Re: I screwed up my django site using touch

2013-03-07 Thread frocco
The problem with the stack trace, is that I could not tell what views.py it was talking about. I use PyCharm, but at work I think I used notepad++ to make a quick change. I understand now that is is a python problem, but what bothers me is that I could not resolve it via the trace. I may have

Re: I screwed up my django site using touch

2013-03-07 Thread Bill Freeman
It's not a Django thing. It is a python thing. Python, as you probably know, determines statement nesting by the amount that the line is indented, that is, the width of the whitespace between the beginning of the line and the first non-whitespace character. The error message says that it has

Re: I screwed up my django site using touch

2013-03-07 Thread j_syk
It's not a problem with wsgi. The problem is incorrect syntax in line 29 of your views.py file. Check that line and make sure that each line is at the same indentation or is properly indented (4 spaces). If you can't figure this out, post a couple lines from that area of your views.py file and

Re: I screwed up my django site using touch

2013-03-07 Thread Roberto López López
In python indentation really matters. Two consecutive lines, with different indentation, do not belong to the same execution block. So: def function(self): this_code_belong_to_the_function() this_code_also() if(True): this_as_well() this_doesnt() And code indented using tabs is

Re: I screwed up my django site using touch

2013-03-07 Thread frocco
I do not understand what the error indentation means. I am new to django, coming from PHP. I was using touch, because unlike PHP, I wanted changes to show without kicking users off. now I am afraid to use touch. On Thursday, March 7, 2013 8:54:15 AM UTC-5, Roberto López López wrote: > > > Check

Re: I screwed up my django site using touch

2013-03-07 Thread Bill Freeman
You were, I presume, touching wsgi to force a reload, in order to pick up recent changes that you made. One of those recent changes was to some view.py (sadly the statcktrace doesn't tell us which one, but it's one that you recently changed), and you made an indentation error (perhaps you let a

Re: models i18n

2013-03-07 Thread Roberto López López
Yes, I meant that. It works great, and fits perfectly my needs. I give it an AAA+ Thanks again. On 03/07/2013 02:58 PM, Johan ter Beest wrote: > > On Mar 6, 2013, at 4:20 PM, Roberto López López wrote: > >> >> Thanks for your suggestion Johan. >> >> Just another

Re: models i18n

2013-03-07 Thread Johan ter Beest
On Mar 6, 2013, at 4:20 PM, Roberto López López wrote: > > Thanks for your suggestion Johan. > > Just another question, which I've not seen answered in the > documentation: is there any custom filter/tag to access those translated > fields from a template? Thanks If you

Re: I screwed up my django site using touch

2013-03-07 Thread Roberto López López
Check the history of the files you've touched, and rollback all indentation changes. On 03/07/2013 02:49 PM, frocco wrote: > Hello, > > I am not sure what happened, I did a touch wsgi and then a touch wsgi.py > I got an error afterwards and could not recover from it. I could not > find the

Re: [Heroku] App crashing on unidle

2013-03-07 Thread Gabriel
Hey, robots.txt is just a file for webcrawlers like Google, it's not required that you have one and you're responding with a 404, so it's ok. I don't think that's the issue. As for the rest, I have no idea. You could look up what exit status 143 is and go on from there. - Gabriel -- You

I screwed up my django site using touch

2013-03-07 Thread frocco
Hello, I am not sure what happened, I did a touch wsgi and then a touch wsgi.py I got an error afterwards and could not recover from it. I could not find the views.py it was complaining about. I tried to reload the site from a backup and still had errors. I ended up recreating the site on

Re: Reusing admin components?

2013-03-07 Thread Bill Freeman
Sorry, I meant under STATIC_URL. On Thu, Mar 7, 2013 at 8:33 AM, Bill Freeman wrote: > Perchance do they appear under MEDIA_URL as admin/js/core.js, etc? > > > On Wed, Mar 6, 2013 at 10:44 AM, Derek wrote: > >> (Working with Django 1.4) >> >> I would

Re: Reusing admin components?

2013-03-07 Thread Bill Freeman
Perchance do they appear under MEDIA_URL as admin/js/core.js, etc? On Wed, Mar 6, 2013 at 10:44 AM, Derek wrote: > (Working with Django 1.4) > > I would like to re-use Django admin's FilteredSelectMultiple widget inside > a custom form. Right now I am working with

[Announce]Django-parsley: Easy client side validations for Django

2013-03-07 Thread Shabda Raaj
I would like to announce our new app: Django Parsley - https://github.com/agiliq/django-parsley Django forms give you nice server side validations for free. This library adds client side valiadtions with very little effort to you your forms, using parsley.js. Patches and feedback welcome. --

Re: How to pass a value from a Django View to a JQuery Slider bar.

2013-03-07 Thread Daniel Roseman
On Thursday, 7 March 2013 07:58:27 UTC, 7equiv...@gmail.com wrote: > Now that I have that part working, I would like to make since of what was > going on and why it didn't work in the first place. I have a question... > > Let's say > (1) a page is requested, and the View renders_to_response a

Re: Changing SECRET_KEY for a project that was already launched

2013-03-07 Thread Ram Rachum
Thanks! On Wed, Mar 6, 2013 at 11:36 PM, Shawn Milochik wrote: > Are you using it as the key for any encrypted fields, or anything > other than the built-in stuff Django does with session cookies? > > If not, I don't think you'll have a problem. Of course, back up your >

Re: get_form in formwizard gives validation error

2013-03-07 Thread Rob
I am a bit further now. When I use the default widget in forms.py the validation error disappears. BoekForm3 becomes: Activiteit = forms.ModelChoiceField(queryset=Activiteit.objects.all(), empty_label="(Nothing)") I ran into another issue however (below is my complete view): I use get_form to

[Heroku] App crashing on unidle

2013-03-07 Thread Vibhu Rishi
Hi I have not done any update to my django site in the last couple of weeks. However, suddenly, about 2 days back, it is crashing repeatedly. If I stop and start the web service from the heroku.com site, it starts again. If check logs from the command line ( heroku logs ) it starts after