Not really.
If you're specially working with legacy databases trying to figure out that do
Django models match underlying schema is PITA.
We resolved this partially by doing few simple tests, namely running through
all models and doing empty query. Since Django ORM queries for every field it
r
How to use django custom validators to verify form fields data
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to
django-users+unsubs
Hello,
Can anyone give me hand and help me with my problem?
How can I distribute Django project as linux package? For example deb
package.
Thanks a lot for your time.
Regards
Petr
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this
I am using django-profiles with django-registration as per tutorial from
http://praveensunsetpoint.wordpress.com/2009/04/21/django-registration-and-django-profile
But after the submitting the form I am getting this error
AttributeError at /accounts/register/
'RegistrationForm' object has no att
On Mon, May 31, 2010 at 12:36:36AM -0700, Petr Pejcel wrote:
> How can I distribute Django project as linux package? For example deb
> package.
http://www.radix50.net/~ibr/notes/20080323-0-django-autotools-debian.html
Questions or feedback welcome.
With kind regards,
--
Baurzhan Ismagulov
http:
Per the comment moderation docs at:
http://docs.djangoproject.com/en/dev/ref/contrib/comments/moderation/
:
# models.py
from django.contrib.comments.moderation import CommentModerator,
moderator
class ItemModerator(CommentModerator):
email_notification = True
enable_field = 'enable
Which version of grappelli are you using? Currently the trunk requires
django 1.2 but I think there's a branch that still works with 1.1.
Having said that, we're using grappelli (a slightly older revision)
with Django 1.1 in a live project and it works just fine. Do you
notice any javascript error
you can use ant and ant-deb-task
http://code.google.com/p/ant-deb-task/
regards
Henrik
>reply to message:
>date: 31.05.2010 10:21:04
>from: "Baurzhan Ismagulov"
>to: "Django users"
>subject: Re: Django project as linux package
>
>On Mon, May 31, 2010 at 12:36:36AM -0700, Petr Pejcel wrote:
>>
Well, it seems that your python lib is at /usr/lib/python2.6/dist-packages:
> mx:~/webapps$ python -c "from distutils.sysconfig import
> get_python_lib; print get_python_lib()"
>
> /usr/lib/python2.6/dist-packages
but django is in "local" - /usr/local/lib/python2.6/dist-packages
> /usr/local/lib
Hi,
I want to upload a file in 2 steps.
First I want to upload it and show the errors and on the second step I
want actually to save the file data in the database.
So I made a simple form and my problem is how to pass the same file to
the form on the second step.
I mean how to insert request.FILES
Hi,
I'm trying to deploy a django app with fabric and get the following
error:
Alexs-MacBook:fabric alex$ fab config:instance=peergw deploy -H -
u -p
[192.168.2.93] run: cat /etc/issue
Traceback (most recent call last):
File "build/bdist.macosx-10.6-universal/egg/fabric/main.py", line
419, i
Thanks so much. But I don't need to do it, but talk about it on my
exam.
Can you give me only important things, which must be done?
Thanks again.
On 31 kvě, 10:21, Baurzhan Ismagulov wrote:
> On Mon, May 31, 2010 at 12:36:36AM -0700, Petr Pejcel wrote:
> > How can I distribute Django project as
Dear Django users,
I have written a new module for Django: it's called django-queries,
and is sort of a mix between the Admin and the Databrowse products.
While the Admin interface is for entering data, django-queries is
intended for searching the entered information.
After defining the searchabl
Have you already read
http://docs.djangoproject.com/en/1.2/ref/forms/validation/#ref-forms-validation
?
On Mon, May 31, 2010 at 9:16 AM, tazimk wrote:
> How to use django custom validators to verify form fields data
>
> --
> You received this message because you are subscribed to the Google Group
Hello.
Can You explain the difference between this module and filters and
search functionality of admin.modelAdmin?
What is its best?
On May 31, 1:55 pm, Guthy Peter wrote:
> Dear Django users,
>
> I have written a new module for Django: it's called django-queries,
> and is sort of a mix between
You have much more freedom with defining search criteria.
In case of ForeignKeys, users can also select more then one related
object, so one can search for "books, that have genre Sci-Fi or
Fantasy".
Also, as it's noted in the documentation, you can define InlineQueries
(comparable to the InlineA
On Fri, May 28, 2010 at 12:59 PM, Rolando Espinoza La Fuente
wrote:
> On Thu, May 27, 2010 at 2:00 PM, dmitry b wrote:
>> So, no one is running automated tests?
>
> I'd added a patch that adds the --noinput option to testserver command:
> http://code.djangoproject.com/ticket/12619
I've just mark
Hi.
Here what I have done
http://github.com/gvkalra/showtime/blob/master/photo/views.py
What I want to do is:
Auto populate the database with currently logged in user's user id
like it has been done with the date of creation of the record by
using
uploaded = models.DateField(auto_now_add=True)
h
Hi All,
The standard Django File Fields (both on models and the form
equivalent) have a number of shortcomings from my point of view / in
my field. The most important of these are:
* The result of uploaded file fields are assumed to be "public", i.e.
served through the MEDIA url. I would rather
Thanks for the info Jani.
One question: How did you manage to make the tests in Django?
Because it forces you to create a test database and the idea of our
tests is to do them on an already full test database.
My idea if I can't skip it is to try and make them with the Python
Unit Testing Framewor
I think that I figured it out . we can use commit=False then
get the user from request.user .. am I correct ? ... any
other way ??
On May 31, 6:03 pm, gvkalra wrote:
> Hi.
> Here what I have
> donehttp://github.com/gvkalra/showtime/blob/master/photo/views.py
>
> What I want t
On 31/05/10 11:55, Guthy Peter wrote:
Dear Django users,
I have written a new module for Django: it's called django-queries,
and is sort of a mix between the Admin and the Databrowse products.
While the Admin interface is for entering data, django-queries is
intended for searching the entered in
No, I haven't seen this, thank you for pointing me at that.
However, I think my "solution" is a much simpler one. You don't have
to write views, everything is set up automatically.
Also, the list of searchable models is generated automatically.
Of course, django-queries is a tool for people you
> I agree with you, Shawn. I just didn't want to push ahead with a manual
uninstall and install if more-experienced Ubuntu users thought I'd be
seeing Django 1.2.1 show up in the repository quickly.
>
> I'll give it a go. Thanks,
>
Ubuntu is a stable linux distribution. This means once a release
Hello!
I could use some help tracking down a problem here. I have a view that
starts as follows:
@login_required
@json_response
def save_exercise_week( request, week_id ):
formID = request.POST['formID']
But this returns a 500 error because the QueryDict is empty --
MultiValueDictKeyError at
or you can do the following tric:
1) install django sudo apt-get -y install python-django
2) now you have all the dependencies you need
3) sudo apt-get -y install python-setuptools
4) sudo apt-get remove python-django
5) sudo easy_install -Z django
repeat step 5 after each release of django
On Mo
I have a query that filters on four fields:
res = MyModel.objects.filter(name=self.name,
type=self.type,
last_update_time__gte=today,
Thanks.
I went ahead and downloaded the Django 1.2.1 tarball, untarred it and
ran
sudo python setup.py install in the directory.
I needed to make one small change in my Apache httpd.conf file, but
otherwise it all seems to be working smoothly!
Thanks!
On May 31, 10:33 am, Massimiliano della Ro
On Mon, May 31, 2010 at 9:56 AM, Stodge wrote:
> I have a query that filters on four fields:
>
> res = MyModel.objects.filter(name=self.name,
> type=self.type,
>
> la
Thanks. The various pieces of data (self.name etc) are 100% correct -
I dumped them all using syslog. However, it just occurred to me that
maybe it's a unicode/string issue. I'm trying to dump the SQL that's
generated - debug_toolbar isn't working for me.
The timestamps are generated from the requ
the only javascript error i'm getting is this:
document.getElementsBySelector is not a function
it's in my admin/js folder in the action.js file?
On May 31, 5:15 am, Nuno Maltez wrote:
> Which version of grappelli are you using? Currently the trunk requires
> django 1.2 but I think there's a
Try using django-debug-toolbar. It will show the POST and GET values.
Also, you can use request.POST.get('formID') instead, which will return None
(or the second, optional argument) if it's empty.
What is your json_response middleware doing? Could it have anything to do with
this?
What if you
Weird:
syslog.syslog("Connections = %s" % str(connection.queries))
gives:
May 31 12:18:41 localhost python: Connections = []
On May 31, 12:12 pm, Stodge wrote:
> Thanks. The various pieces of data (self.name etc) are 100% correct -
> I dumped them all using syslog. However, it just occurred
Maybe related to this issue?
http://code.google.com/p/django-grappelli/issues/detail?id=184
It's supposed to be fixed on the latest grappelli release though.
Nuno
On Mon, May 31, 2010 at 5:13 PM, Bobby Roberts wrote:
> the only javascript error i'm getting is this:
>
> document.getElementsByS
Pankaj -
The fact that you're using a save() method here means that you're
using instructions referring to an older version of django-
registration. But you're probably actually deploying a current
version, which doesn't allow for that. The upgrade guide says:
"Previously, the form used to collec
Using Django 1.2,
I've got a "Niveau" class in models.py. That class contains an auto-
refering field called "niveau" as a ForeignKey field. I use this class
to store a tree structure: the "niveau" field references a "Niveau"
instance's parent.
class Niveau(models.Model):
TYPES=( ('CAMP', 'Ca
yes, I have read that section but right know I am using Django version
1.1 which does not support some new built in validation functions .
Also, where should valiadtions be done ideally server side or client
side i.e using javascripts etc ?
On May 31, 1:01 pm, Horst Gutmann wrote:
> Have you alre
Senhores,
Preciso de ajuda no que se diz respeito a configuração do MANAGE.PY
estou com o seguinte erro:
Error execute_manage.py(settings)
Estou criando uma pagina, criei no arquivo de Setting.py a seguinte
definição:
'django.contrib.blog'; inclui esta linha logo abaixo da linha
'django.contr
I hang my head in shame. I had the name and type reversed in my Ajax
call to the view.
:(
On May 31, 12:19 pm, Stodge wrote:
> Weird:
>
> syslog.syslog("Connections = %s" % str(connection.queries))
>
> gives:
>
> May 31 12:18:41 localhost python: Connections = []
>
> On May 31, 12:12 pm, Stodge
Well, I know this doesn't address most of the issues you raise, but
I've used a combination of django-filebrowser,
http://code.google.com/p/django-filebrowser/ , FileBrowseField and
apache's x-sendfile, http://tn123.ath.cx/mod_xsendfile/, for serving
restricted access files, successfully.
I found
On May 31, 1:41 am, shacker wrote:
> I get "The model 'item' is already being moderated." I haven't set up
> moderation before, so it's not clear what's triggering this. I do have
> an "enable_comments" field on the Item model. Odd that the error puts
> "item" in lowercase rather than upper.
I
Hi David,
DEBUG = True
TEMPLATE_DEBUG = DEBUG
ADMINS = (
# ('Your Name', 'your_em...@domain.com'),
)
MANAGERS = ADMINS
DATABASE_ENGINE = 'mysql' # 'postgresql_psycopg2',
'postgresql', 'mysql', 'sqlite3' or 'oracle'.
# Local time zone for this installation. Choices can be f
Well, since validators were introduced with 1.2 you can't really use
them just right away with 1.1. So if zou want to use validators as in
1.2, you probably should update to 1.2 ;-) But there are still all the
other validation facilities available like clean_fieldname etc.
You can find all the det
Hi Django,
I have few questions and would like to seek your help.
Q1) I have defined lot of admin actions and some of the actions
require creating threads. So I split my long models.py into set of
files. But whenever I try to import anything from models
python complains ?
ex: if i have defined
Thanks. I have successfully made a lobotomized version I called
OverwritingStorage that extends FileStorage and overrides
get_available_name, _save and delete (and offers a hashed_path
classmethod to be used in upload_to callables)
http://djangosnippets.org/snippets/2044/
Now my problem is not be
Hi Mike,
Thanks for the response. I did think of that. My template loaders
setting is as follows:
TEMPLATE_LOADERS = (
'django.template.loaders.app_directories.Loader',
'django.template.loaders.filesystem.Loader',
)
all of my templates are stored in the template directory for each
indivi
Hi folks
I am having huge problems wrapping my head around the ImageField field
type. I am trying to generate default thumbnails for uploaded images,
both stored as ImageField attributes. It's done this way because the
user must be able to manually edit the thumbnail if needed.
I am failing miser
Nope.
But, there were changes in with some of the settings when I did my
first upload to webfaction, but from what I can tell, I've restored
all my settings to their original state before the upload, but even
though the dev runs, I can't connect.
On May 29, 5:30 pm, Juan Hernandez wrote:
> any f
I plan on utilizing: http://github.com/simplegeo/python-oauth2 for my
django-based Twitter app, however I'm wondering if anyone here who
understands the django example, understands it better than I do.
The first half of the page has an example for just plain Python, and
there's a part there, whe
Thanks my problem has been resolved :)
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to
django-users+unsubscr...@googlegroups.com.
Also, I can connect to other projects, just not this one. Seems like
I'm overlooking something in settings.py or urls.py.
What would cause it to give no errors while not connecting?
On May 31, 1:31 pm, gin tonic wrote:
> Nope.
>
> But, there were changes in with some of the settings when I did m
FIXED:
settings.py > was
ADMIN_MEDIA_PREFIX = ''
settings.py > is now
ADMIN_MEDIA_PREFIX = '/media/'
On May 31, 3:15 pm, gin tonic wrote:
> Also, I can connect to other projects, just not this one. Seems like
> I'm overlooking something in settings.py or urls.py.
>
> What would cause it to g
Hello
1. no index page (debug off)
2. try another port
3. check for bugs in urls and views
4. recheck configurations in settings
On May 30, 3:03 am, gin tonic wrote:
> My development server is running but when I attempt to access it at
> the localhost 127.0.0.1:8000 I receive a page not found err
I'm trying to implement a simple grade book application using a
modelformset where the students' names are READONLY and the grades are
the only thing the teacher can edit. I've been looking for sample code
to implement the readonly portion and one fellow (on another site)
suggests I use his, but he
Hi, I am having trouble getting the behavior I would like from a
ManyRelatedManager.
I have a many to many relationship with User and ModelB, with a join
table ModelJ. Instead of deleting items in my database, I am simply
marking them as deleted. I have a custom manager that filters out
deleted ob
Hi, everybody! I tried to set Flatpages about 3 days but I could get
only "404" error in browser. If someone had a few time look at my
settings: http://files.mail.ru/JXHUOU
Enter for admin part: user:Django, pass:Django
Regards.
--
You received this message because you are subscribed to the G
On 1/06/2010 6:20am, Cromulent wrote:
Hi Mike,
Thanks for the response. I did think of that. My template loaders
setting is as follows:
TEMPLATE_LOADERS = (
'django.template.loaders.app_directories.Loader',
'django.template.loaders.filesystem.Loader',
)
all of my templates are stored
We're adapting our Django powered video site to be an open video
platform for any user to create their own "site" using subdomains (eg
mysite.vidplatform.com) on one Django server instance. Each "site"
would obviously have content associated with only that site in
addition to template and navigatio
On Jun 1, 1:04 pm, Kieran Farr wrote:
> We're adapting our Django powered video site to be an open video
> platform for any user to create their own "site" using subdomains (eg
> mysite.vidplatform.com) on one Django server instance. Each "site"
> would obviously have content associated with onl
59 matches
Mail list logo