Re: ANN: fathom 0.2.0

2011-04-09 Thread Filip Gruszczyński
I forgot links: Homepage: http://code.google.com/p/fathom/ Documentation: http://code.google.com/p/fathom/wiki/Manual -- Filip Gruszczyński -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to dj

ANN: fathom 0.2.0

2011-04-09 Thread Filip Gruszczyński
ity-relationship diagrams in graphviz dot language, that can be turned into pdf or image files -- Filip Gruszczyński -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com

Re: Constants in model, that point to certain objects in database

2011-01-25 Thread Filip Gruszczyński
s ....: In [19]: isinstance(Foo, type) Out[19]: True -- Filip Gruszczyński -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com. To unsubscribe from this group, send email to

Re: Constants in model, that point to certain objects in database

2011-01-24 Thread Filip Gruszczyński
s they do - as long as their metaclass derives from the appropriate > metaclass (ModelBase IIRC but better to check it out). I'll definitely try that. -- Filip Gruszczyński -- You received this message because you are subscribed to the Google Groups "Django users" group. To

Constants in model, that point to certain objects in database

2011-01-24 Thread Filip Gruszczyński
Model, that would be used during run time, but Model subclasses can't have own metaclass. So, is there any other way? What I am thinking, is attaching those constants after table are created _and_ fixtures are loaded. Is there any hook in django, that I could use? -- Filip Gruszczyński -- Yo

Re: root_path in admin sites is None

2010-08-03 Thread Filip Gruszczyński
nd if you don't please tell it too, so that the ticket you opened can > be closed. > > Cheers > > On Jun 23, 6:00 pm, Filip Gruszczyński wrote: >> > before: ('^admin/(.*)',admin.site.root), >> >> > after: (r'^admin/', include(admin.site.

Re: Own template instead of a inline

2010-06-28 Thread Filip Gruszczyński
> You can just define `template` in your inlineadmin class: > >    class MyInlineAdmin(admin.InlineModelAdmin): >        template = 'mytemplates/myinlinetemplate.html' >        model = MyModel I'll try this. Thanks a lot. -- Filip Gruszczyński -- You receive

Own template instead of a inline

2010-06-28 Thread Filip Gruszczyński
I would like to inject my own admin template instead of a standard inline for a certain model (this model has additional reference, that can't be edited by traditional inline). Could someone suggest me, how I could achieve this? -- Filip Gruszczyński -- You received this message becaus

Re: root_path in admin sites is None

2010-06-23 Thread Filip Gruszczyński
o.contrib.admindocs.urls')), # (r'^admin/(.*)', admin.site.root), (r'^admin/', include(admin.site.urls)), It solved some other problems (admin didn't work at all), but I still have the problems with links in admin site. > > it work good now!!! > > bye >

root_path in admin sites is None

2010-06-23 Thread Filip Gruszczyński
variable is rendered in those urls). What I might have forgotten to set and how can I change it to an empty string? -- Filip Gruszczyński -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to

Re: Haven't enabled CSRF protection and yet server throws CSRF based 403

2010-06-07 Thread Filip Gruszczyński
ease. I guess we will slowly move in this direction, but for now I just would like to upgrade our project to 1.2, because it has some feature we would like use. -- Filip Gruszczyński -- You received this message because you are subscribed to the Google Groups "Django users" group.

Re: Haven't enabled CSRF protection and yet server throws CSRF based 403

2010-06-07 Thread Filip Gruszczyński
lates for contrib > views, you MUST READ THE UPGRADE INSTRUCTIONS to fix those templates.") You > need to update the login template you are using to include the {% csrf_token > %} tag. Thanks a lot, Karen. You are always right ;-) and this time it worked too :-) -- Filip Grus

Re: Haven't enabled CSRF protection and yet server throws CSRF based 403

2010-06-07 Thread Filip Gruszczyński
I thought I don't have to do anything. Can I disable it somehow? 2010/6/7 Kenneth Gonsalves : > On Monday 07 June 2010 17:53:46 Filip Gruszczyński wrote: >> I have just upgraded to 1.2 and when I run ./manage runserver and >> tried to open main page of our project first I wa

Haven't enabled CSRF protection and yet server throws CSRF based 403

2010-06-07 Thread Filip Gruszczyński
hould be ready to go, but it isn't. What I might be doing still wrong? -- Filip Gruszczyński -- 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 f

Re: error while migrating from 1.1 to 1.2

2010-06-07 Thread Filip Gruszczyński
It seems that some old 1.1.2 eggs must have been messing with me. I have removed them all and it works now just right. -- Filip Gruszczyński -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to

Re: error while migrating from 1.1 to 1.2

2010-06-07 Thread Filip Gruszczyński
'', # Not used with sqlite3. 'PASSWORD': '', # Not used with sqlite3. 'HOST': '', # Set to empty string for localhost. Not used with sqlite3. 'PORT': '',

error while migrating from 1.1 to 1.2

2010-06-07 Thread Filip Gruszczyński
aseWrapper(db, alias) File "/usr/local/lib/python2.6/dist-packages/django/db/backends/sqlite3/base.py", line 154, in __init__ super(DatabaseWrapper, self).__init__(*args, **kwargs) TypeError: __init__() takes exactly 2 arguments (3 given) Has anyone encountered it and know perha

Re: contrib.auth test failures persist to 1.2

2010-05-28 Thread Filip Gruszczyński
Yes, it seems the fault is on my side (not directly, not my code :-)). Thanks a lot. On May 19, 2010 3:54 PM, "Karen Tracey" wrote: 2010/5/19 Filip Gruszczyński > > I have just installed Django 1.2 hoping, that my test suites will > finally work flawlessly and... If you

Re: runtests.py fails with ImportError: No module named messages

2010-05-28 Thread Filip Gruszczyński
ren Tracey" wrote: 2010/5/27 Filip Gruszczyński > > I am trying to run tests on the trunk (rev 13307) and when I do, I get: > > grusz...@gruszczy-la... Every time I have seen this, the problem has been that I'm using a settings file generated with 1.2-level code but I'v

runtests.py fails with ImportError: No module named messages

2010-05-27 Thread Filip Gruszczyński
tlib.py", line 35, in import_module __import__(name) ImportError: No module named messages Am I doing something wrong? How can I diagnoze what is wrong? -- Filip Gruszczyński -- You received this message because you are subscribed to the Google Groups "Django users" group.

reverse('django.contrib.auth.views.login') in auth tests returns /login/ rather then value set in LOGIN_URL

2010-05-19 Thread Filip Gruszczyński
login/. Why is that? Is that a bug and I should file it in the issue tracker or maybe I am doing something wrong? -- Filip Gruszczyński -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to

contrib.auth test failures persist to 1.2

2010-05-19 Thread Filip Gruszczyński
=== FAIL: test_current_site_in_context_after_login (django.contrib.auth.tests.views.LoginTest) -- Traceback (most recent call last): File "/usr/local/lib/python2.6/dist-packages/django/contrib/auth/tests/views.py", line 181, in test_c

tests fail for django.contrib.auth

2010-03-24 Thread Filip Gruszczyński
'newuser') TypeError: 'NoneType' object is unsubscriptable == FAIL: test_current_site_in_context_after_login (django.contrib.auth.tests.views.LoginTest) -- Tra

Re: Problem with text encoding MS SQL Server 2005

2010-02-03 Thread Filip Gruszczyński
Sure. In file freetds.conf you should set client charset = UTF-8 and it started to work. I heard, that there might be still some problems with, but we haven't yet encountered them. 2010/2/3 Shawn Milochik : > > On Feb 3, 2010, at 1:30 PM, Filip Gruszczyński wrote: > >> OK,

Re: Problem with text encoding MS SQL Server 2005

2010-02-03 Thread Filip Gruszczyński
OK, we managed to solve this ourselves. W dniu 3 lutego 2010 18:08 użytkownik Filip Gruszczyński napisał: > Hello, > > I'm trying to store Django data on MS SQL Server 2005 using: > > http://code.google.com/p/django-pyodbc/ (pyodbc + FreeTDS) > > As long as I'm

Problem with text encoding MS SQL Server 2005

2010-02-03 Thread Filip Gruszczyński
7;\xc5\x82',) self sql 'SELECT (1) AS [a] FROM [cli_punktrejestracji] WHERE [cli_punktrejestracji].[adres] = ? ' BTW http://code.google.com/p/django-mssql/ doesn't seems to work under Linux, django-mssql needs pythoncom library. Am I right? -- Filip Gruszczyński -- You received

Re: Analyzing modules before application start

2010-01-25 Thread Filip Gruszczyński
Ok, I will. Thanks :-) W dniu 21 stycznia 2010 22:41 użytkownik Matt Schinckel napisał: > On Jan 22, 12:00 am, Filip Gruszczyński wrote: >> I would like to go through all registered apps before server is >> started and check if certain modules (and then process them). I guess &g

Analyzing modules before application start

2010-01-21 Thread Filip Gruszczyński
? Into manage.py? -- Filip Gruszczyński -- 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...@googlegroup

Re: Proper way of importing projects modules

2009-09-11 Thread Filip Gruszczyński
myproj1 --> ../myproj1a >> >> So Django will still look for, and find, myproj1, but it'll point at your >> renamed directory. >> >> Hope this helps. Like I say, it's better form to just do the right thing up >> front and do the renaming, but this

Re: Editors of choice

2009-09-10 Thread Filip Gruszczyński
Geany: http://geany.org/ It's very small, very fast, very easy to learn, and yet provides some cool features (autocompletion, tips, detecting symbols). Developers are very responsive and already made a few features just for me ;-) -- Filip Gruszcz

Re: Proper way of importing projects modules

2009-09-10 Thread Filip Gruszczyński
ature. Then it gets quite messy ;-) So, these are the only two ways? -- Filip Gruszczyński --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-u

Proper way of importing projects modules

2009-09-10 Thread Filip Gruszczyński
repo using mercurial), it stopped importing anything. Does it mean I should just use relative imports and this would be fine? Do I have to then always add root directory to the PYTHON_PATH or can I live without it? How exactly django projects should be constructed. -- Filip Gruszczyński

Re: Running django tests

2009-08-10 Thread Filip Gruszczyński
Indeed it helped. Thanks a lot, Karen. 2009/8/10 Karen Tracey : > 2009/8/10 Filip Gruszczyński >> >> Hi! >> >> I would like to run django source code tests, but as soon as I do it >> (after specifying the settings file), I get all kinds of exceptions. >>

Running django tests

2009-08-10 Thread Filip Gruszczyński
delete_regress: File "./runtests.py", line 134, in django_tests mod = load_app(model_label) File "/var/lib/python-support/python2.6/django/db/models/loading.py", line 72, in load_app mod = __import__(app_name, {}, {}, ['models']) File "/root/django/t

Re: Temporary urls for tests

2009-05-31 Thread Filip Gruszczyński
:43 pm, Ramiro Morales wrote: >> 2009/5/30 Filip Gruszczyński : >> >> >> >> > I am building a library for Django that provides some abstract views >> > (I am using classes instead of functions), that can be used subclassed >> > and used in any

Re: Temporary urls for tests

2009-05-30 Thread Filip Gruszczyński
Should have check those docs, sorry. Next time I'll make sure I've checked it all. Thanks for you help. W dniu 30 maja 2009 15:43 użytkownik Ramiro Morales napisał: > > 2009/5/30 Filip Gruszczyński : >> >> I am building a library for Django that provides some a

Temporary urls for tests

2009-05-30 Thread Filip Gruszczyński
they could be called with client.get or post. Is there any possibility to achieve this? -- Filip Gruszczyński --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, sen

Re: Callable objects instead of functions in views.py

2009-05-20 Thread Filip Gruszczyński
ovoke not really an exceptional situation an elegant solution? Isn't it a bit a hack? I mean - from pragmatic point of view it's cool, cause it will just work fine. But it causes some strange unease in me.. -- Filip Gruszczyński --~--~-~--~~~---~--~~ You received

Re: Callable objects instead of functions in views.py

2009-05-20 Thread Filip Gruszczyński
elf, *args, **kwargs): self.some_method(*args, **kwargs) def some_method(self, *args, **kwargs): # need redirect here - this won't work return HttpResponseRedirect(.. Is there any elegant solution, which would allow to break, just when it's needed? 2009/5/20 Alex Gaynor : >

Re: Callable objects instead of functions in views.py

2009-05-20 Thread Filip Gruszczyński
right? So I can just subclass HttpResponse, add all stuff (like having function forbid or redirect) and it should work? -- Filip Gruszczyński --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" gr

Re: Callable objects instead of functions in views.py

2009-05-20 Thread Filip Gruszczyński
pass def serveBoth(self, request, *args, **kwargs): pass I am most concerned with it being thread (and not only thread) safe. Your alternatives are cool, but I would like to get a solution as general as (in pr

Re: Callable objects instead of functions in views.py

2009-05-20 Thread Filip Gruszczyński
I then use constructors and create an object, that will serve a request? Would this prevent sharing the object? -- Filip Gruszczyński --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group.

Callable objects instead of functions in views.py

2009-05-20 Thread Filip Gruszczyński
to use it, because my views functions began to grow big and I wanted to divide them into smaller chunks, and yet keep them logically connected. What do you think about using this kind of solution? Have anyone tried it? -- Filip Gruszczyński --~--~-~--~~~---~--~~ You rec

Re: Seperate thread - best practices

2009-05-14 Thread Filip Gruszczyński
Ok, thanks. I'll give it a try :-) W dniu 14 maja 2009 11:40 użytkownik Daniel Roseman napisał: > > On May 14, 10:03 am, Filip Gruszczyński wrote: >> > Best practice here would be to stop trying to use a webserver to do >> > things it wasn't intended for. >

Re: Seperate thread - best practices

2009-05-14 Thread Filip Gruszczyński
ry to invoke the script. Even if it's an integral part of an app? And I would like to be able to access it easily from django testing framework, so it can be automatically tested every time I need it. -- Filip Gruszczyński --~--~-~--~~~---~--~~ You received

Seperate thread - best practices

2009-05-13 Thread Filip Gruszczyński
stdlib and don't worry about anything? -- Filip Gruszczyński --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com

Form using widget built by filter_horizontal

2009-04-30 Thread Filip Gruszczyński
In admin definition attribute filter_horirozntal can be specified, that creates cool javascript using widget for ManyToMany field. I would like to use such widget in my form. How can I specify this? I looked into django.forms.widgets, but none looks like this one. -- Filip Gruszczyński

Making First name/Last name required in User

2009-04-29 Thread Filip Gruszczyński
I would like to make First name and Last name to be required in User class from auth package. I believe enough would be to make forms in admin invalid, when name wasn't provided. Is it somehow possible to achieve, without changing Django code? -- Filip Gruszcz

Testing and 'module' object has no attribute 'handler500'

2009-04-28 Thread Filip Gruszczyński
oogled, but found no information, how to solve this. Can I somehow make it return just response with information about the error, so I can use it in test? -- Filip Gruszczyński --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups

Re: Turning password reset

2009-04-21 Thread Filip Gruszczyński
> http://code.google.com/p/nose-django/ Is there any python lib, that didn't get django plugin ;-)? Thanks :-) -- Filip Gruszczyński --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users&qu

Re: Turning password reset

2009-04-21 Thread Filip Gruszczyński
ot for, I didn't know about this package and I'm gonna take a deeper look, since I would like to learn finally something more about unit tests. -- Filip Gruszczyński --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Goog

Re: Turning password reset

2009-04-21 Thread Filip Gruszczyński
specify the test to run, > then it can be of some help. Thanks a lot, I'll take a look. > I've also been told nose has similar functionality. I don't get this one. Is it some kind of a sarcastic or ironic remark I won't understand unless I

Re: Turning password reset

2009-04-21 Thread Filip Gruszczyński
t? W dniu 21 kwietnia 2009 15:43 użytkownik Russell Keith-Magee napisał: > > 2009/4/21 Filip Gruszczyński : >> >> Hi! >> >> I don't have password reset in my project and the base test suite >> fails because of this. Can I somehow turn of these tests until I >

Turning password reset

2009-04-21 Thread Filip Gruszczyński
Hi! I don't have password reset in my project and the base test suite fails because of this. Can I somehow turn of these tests until I decide to add password reset? -- Filip Gruszczyński --~--~-~--~~~---~--~~ You received this message because you are subsc

Re: Collapsed inline

2009-04-07 Thread Filip Gruszczyński
OK, thanks. I'll wait patiently for 1.2 then :-) W dniu 1 kwietnia 2009 17:00 użytkownik Karen Tracey napisał: > 2009/4/1 Filip Gruszczyński >> >> I am creating my own admin for a model and I would to add a collapsed >> inline. >> >> [snip] >> Bu

Default values in inline admin widget

2009-04-01 Thread Filip Gruszczyński
I have inline admin widget, it's a tabular inline and I would like to have a few of it's rows filled for the user. Can I achieve it somehow quickly (DJango 1.0 or 1.1)? Should I put some JS somewhere or is it possible from admin.py? -- Filip Gr

Collapsed inline

2009-04-01 Thread Filip Gruszczyński
possibly in 1.0, because this is at the production server, but I can also live with 1.1) -- Filip Gruszczyński --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, sen

Re: iterating over fields of a model

2009-03-31 Thread Filip Gruszczyński
I'll do. Thanks :-) W dniu 31 marca 2009 18:12 użytkownik Daniel Roseman napisał: > > On Mar 31, 4:54 pm, Filip Gruszczyński wrote: >> I have a user profile class and I would like to iterate over all >> defined fields and retrieve their values. For example if I had:

iterating over fields of a model

2009-03-31 Thread Filip Gruszczyński
values from an instance. Is this possible? -- Filip Gruszczyński --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com To u

testing suite fails on auth

2009-03-31 Thread Filip Gruszczyński
ised if the provided email address isn't currently registered -- Traceback (most recent call last): File "/usr/lib/python2.5/site-packages/django/contrib/auth/tests/views.py",

Re: DJango, threads and serial port

2009-03-31 Thread Filip Gruszczyński
is with getting things done perfectly done at work), I will try to put serial package right into the project instead of using egg and put some prints into this. This way I might be able to see, what happens inside. -- Filip Gruszczyński --~--~-~--~~~---~--~~ You r

Re: DJango, threads and serial port

2009-03-31 Thread Filip Gruszczyński
threads, everything works fine. Since the serial port is open only once at the system startup, it is a satisfactory solution. But I wouldn't be myself, if I didn't try to determine, why it didn't work, when I run it on separate thread. Any idea, why this might hav

Re: DJango, threads and serial port

2009-03-26 Thread Filip Gruszczyński
just tells them to do something and the follows normal routine. Those threads do some heavy output work (only output) and then just die. I will try to debug without threads and see what happens. -- Filip Gruszczyński --~--~-~--~~~---~--~~ You received this messag

Re: DJango, threads and serial port

2009-03-26 Thread Filip Gruszczyński
I tried using import pdb right before the exception and runing set_trace, but it just displayed next command and finished. This code is executed in separate thread (ususally operations on serial port take a while, so I have to do it on seperate thread). 2009/3/26 Filip Gruszczyński : >&g

Re: DJango, threads and serial port

2009-03-26 Thread Filip Gruszczyński
code? Strangely, when I just run manage runserver, the serial connection seems to be working fine. -- Filip Gruszczyński --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this g

DJango, threads and serial port

2009-03-26 Thread Filip Gruszczyński
ename, module_globals) File "/usr/lib/python2.5/linecache.py", line 113, in updatecache for dirname in sys.path: TypeError: 'NoneType' object is not iterable (I use threads to allow asynchronous initialisation and sms sending, since timeout take a while). Do you know of any

Why save on attributes is no good?

2009-03-24 Thread Filip Gruszczyński
and it can't be null). Why it happens so? -- Filip Gruszczyński --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com

Re: Aggrevate and offsets

2009-03-21 Thread Filip Gruszczyński
That explains everything. Thanks. 2009/3/21 Alex Gaynor : > > > 2009/3/21 Filip Gruszczyński >> >> I have a following question. I started using 1.1 alpha and encountered >> such an issue. Should I consider it a bug or is it working properly? >> If it is not, is

Aggrevate and offsets

2009-03-21 Thread Filip Gruszczyński
vg('value')) {'value__avg': 10699.9} >>> Salary.objects.all()[1:10].aggregate(Avg('value')) {'value__avg': 10699.9} >>> If it is a bug, could you point me to a place, where I could try to take a look and f

Re: Testing

2009-03-19 Thread Filip Gruszczyński
d tests.py in your application. > > An example of testing a view with doctests can be found here: > http://docs.djangoproject.com/en/dev/topics/testing/#overview-and-a-quick-example > > Preston > > > > On Mar 18, 6:34 pm, Filip Gruszczyński wrote: >> I am trying to ha

Testing

2009-03-18 Thread Filip Gruszczyński
I am trying to have my function tested using docstring with examples. When I put it into models.py of an app, it gets tested. If I put it into views.py, it is not tested; this happens also, if I add another module (which I import). How can make testing framework test those? -- Filip

Re: Completions

2009-03-18 Thread Filip Gruszczyński
I see. Thanks a lot :-) 2009/3/18 Alex Gaynor : > > > On Tue, Mar 17, 2009 at 8:10 PM, Alex Gaynor wrote: >> >> >> 2009/3/17 Filip Gruszczyński >>> >>> > Are you talking about autocompletion as in what the browser does, or >>> > some

Re: Completions

2009-03-17 Thread Filip Gruszczyński
will put directly into DJango in some future releases? -- Filip Gruszczyński --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.

Completions

2009-03-17 Thread Filip Gruszczyński
Does DJango forms provide option of completions? I mean the ones we can see in Google recently or in youtube. If not, could you point me to the part of the code,where this could be added? -- Filip Gruszczyński --~--~-~--~~~---~--~~ You received this message

Re: Depth of serialization

2009-03-01 Thread Filip Gruszczyński
Looks good, thanks. I'll try to use it :-) 2009/3/1 mattimust...@gmail.com : > > Hi Filip, > > Try my serializer at > http://code.google.com/p/wadofstuff/wiki/DjangoFullSerializers. > It does what you need. > > regards > > matthew > > On Mar 2, 8:51 a

Depth of serialization

2009-03-01 Thread Filip Gruszczyński
there was taken care of it. I tried depth argument on serialization, but there wasn't such and I can't find any reference. I took a look at the code, but found info only about two args (although function uses **kwargs). Can I somehow specify the depth? -- Fil