Quick question for web hosting production

2021-10-08 Thread Patrick Luke Astrero
I want to ask a quick question guys that, is it possible to host 2 apps in one cloud service? like for example, angular for the front end and django for the backend? and they would use one ip address right but on a different port? -- You received this message because you are subscribed to the

Re: libssl.so.1.1 / OPENSSL_1_1_1 not found after upgrade (ubuntu server 18.04 / apache / mod_wsgi)

2019-06-23 Thread Luke
Hah! Found it! The psycopg2-binary module needed to be reinstalled (now version 2.8.3) I believe the old one must have been compiled against libssl1.1.0, which was replaced by 1.1.1 in the upgrade which broke things. On Monday, June 24, 2019 at 11:11:11 AM UTC+12, Luke wrote: > > I&#x

Re: libssl.so.1.1 / OPENSSL_1_1_1 not found after upgrade (ubuntu server 18.04 / apache / mod_wsgi)

2019-06-23 Thread Luke
I'm having the same problem, totally unable to find a resolution so far. I get no error messages of any use, even with all logging set to DEBUG. The only thing i'm seeing is "Truncated or oversized response headers received from daemon process" in the apache error log. Works fine when using the

Re: django ORM with asyncio

2018-09-25 Thread luke lukes
yet to be > started. > > Andrew > > On Tue, Sep 18, 2018 at 5:55 AM luke lukes > wrote: > >> I'm looking for something that can allow the usage of the Django ORM with >> asyncio (with PostgreSQL). >> >> As of now I found only aiopg <https://

django ORM with asyncio

2018-09-18 Thread luke lukes
I'm looking for something that can allow the usage of the Django ORM with asyncio (with PostgreSQL). As of now I found only aiopg in the *asyncio ecosystem* , which allows to run raw SQL or to use SQLAlchemy only. I then fou

Re: Getting channels 2 to work

2018-03-30 Thread Luke Waltman
(2.03), Channels (2.02) and Python(3.5.1) within a virtual environment. I also installed asgi_redis. -Luke On Monday, December 4, 2017 at 11:11:14 AM UTC-6, Andrew Godwin wrote: > > Hi John, > > The ProtocolTypeRouter currently does this for you automatically as long > as you don&#x

Django Channels 2 Group_send to channel layer causes runtime error: "got Future attached to a different loop"

2018-02-16 Thread Luke Hebert
Trying to call a consumer method inside a SyncConsumer class def alert_receive(self, event): # Get a message of the alert.receive type off of channel_layers content = json.dumps("Group send working") self.send({ "type":"websocket.send",#

Django Channels 2 Group_send to channel layer causes runtime error: "got Future attached to a different loop"

2018-02-16 Thread Luke Hebert
Trying to call the "alert_receive" consumer method import json from channels.consumer import SyncConsumer from channels.exceptions import StopConsumer from asgiref.sync import async_to_sync from channels.layers import get_channel_layer class ClientAlertPtrConsumer(SyncConsumer): def websocke

python - handling HTTP requests asynchronously

2016-05-06 Thread luke lukes
Hi everyone, I need to generate a PDF report for each entry of a django queryset. There'll be between between 30k and 40k entries. The PDF is generated through an external API. Since currently is generated on demand, this is handled synchronously via an HTTP request/response. That will be dif

New ODM for MongoDB

2015-12-04 Thread Luke Lovett
Hi Django Users! I'm in the planning process for creating a general-purpose (i.e., not only Django) MongoDB ODM. The short-term goal for this project is to provide a general purpose core ODM useful in a variety of frameworks. Later on, I'd like to extend this generic layer to provide Django-spe

Re: [ANNOUNCE] Django 1.9 released

2015-12-02 Thread Luke Granger-Brown
On Wed, Dec 2, 2015 at 10:20 AM, Mike wrote: > pip install django >> Downloading/unpacking django >> Downloading Django-1.9-py2.py3-none-any.whl (6.6MB): 6.6MB downloaded >> Installing collected packages: django >> Compiling >> /Users/mike/sieve2/SIEVEENV/build/django/django/conf/app_template/a

Re: simplify query

2015-11-10 Thread Luke M
> > > > > El martes, 10 de noviembre de 2015, 10:14:02 (UTC-6), > luk...@riseup.net > > escribió: > >> > >> Haven't run this code, but you could try something like: > >> > >> ``` > >> impor

model Field subclass + validation

2015-11-01 Thread Luke M
d help out by either answering here or on SO. Here is the full question text: https://stackoverflow.com/questions/33460690/django-models-add-validation-to-custom-field Best, Luke -- You received this message because you are subscribed to the Google Groups "Django users" group. To u

django admin fieldsets - adding fields of related models

2014-07-14 Thread luke lukes
address_city or\ obj.home_address_postcode != old_obj.home_address_postcode or\ obj.home_address_country != old_obj.home_address_country or\ obj.home_address_phone != old_obj.home_address_phone or\ obj.personal_email != old_obj.personal_email: new_address = '%s\n%s\n%s\n%s\n%s\n%

Javascript and sessions

2014-02-26 Thread Luke Baker
Hey there, (Forgive my ignorance) My web application is heavily based around form input. I'd like to update the user's session with each form input that they update or change while working with a form. I'm thinking of implementing some simple javascript that listens for 'change' events on each

Re: Django newbie frustrated

2014-02-12 Thread Sean Luke
It gives me an error saying unresolved reference. I will try the django tutorial. -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscr...@goog

Re: Django newbie frustrated

2014-02-12 Thread Sean Luke
models.py from django.db import models # Create your models here. class Poll(models.Model): question = models.CharField(max_length=200) pub_date = models.DateTimeField('date published') class Choice(models.Model): poll = models.ForeignKey(Poll) choice = models.CharField(max_le

Re: Django newbie frustrated

2014-02-12 Thread Sean Luke
= 'UTC' USE_I18N = True USE_L10N = True USE_TZ = True # Static files (CSS, JavaScript, Images) # https://docs.djangoproject.com/en/1.6/howto/static-files/ STATIC_URL = '/static/' On Wednesday, February 12, 2014 1:21:53 PM UTC-6, Lucas Klassmann wrote: > > Hi Sean

Django ModelForms - testing forms with model that have M2M inline instance using an intermediate model

2013-12-25 Thread luke lukes
rue(self.form.is_valid(), msg=self.form.errors) the test fails due to the lack of mandatory field 'tasks'. I can't explain this. I've tried to save the form using admin interface, and it worked without errors. Using ipdb debugger, I saved the data querydict and I used it in the form case. So same data for populating the form, but

Django admin - dinamically update through ajax choices of a ChoiceField in a ModelForm

2013-09-21 Thread luke lukes
Maybe subclassing the original ChoiceField or the Select widget? Many thanks LuKe -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsu

Re: CachedStaticFilesStorage with database cache backend - static file not found (404)

2013-06-24 Thread luke lukes
) is missing in an app (django-tinymce), though without storage enabled I don't get any error. - Files are served correctly without hash token. Il giorno sabato 22 giugno 2013 13:47:39 UTC+2, Denis Cornehl ha scritto: > > Hi Luke, > > 2013/6/21 luke lukes >: > > [snip]

CachedStaticFilesStorage with database cache backend - static file not found (404)

2013-06-21 Thread luke lukes
g to do that, but since I don't want to reinvent the wheel I'd like to solve it in an appropeiate way. Thanks LuKe -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe from this group and stop receiving emails from it

django admin - changelist view: keep selected items on multiple pages

2013-01-23 Thread luke lukes
select some items; 3. then i go to page 2; 4. I select other items; 5. I return to page 1; 6. my previous selection is lost. Is it possible to keep that selection somewhere (cookie, session,...)? thanks, Luke -- You received this message because you are subscribed to the Google Grou

django admin: keeping selected items on different page in changelist view

2013-01-23 Thread luke lukes
eturn to page 1; 6. my selection is lost. Is it possible to keep it somewhere (cookie, session,...)? thanks, Luke -- You received this message because you are subscribed to the Google Groups "Django users" group. To view this discussion on the web visit https://groups.google.c

Re: django - adding a counter for every ManyToMany field added

2012-11-13 Thread luke lukes
Hi. I don't need a total counter for all related activities. I need a counter for each related Activity: Invoice instance: activity A -> counter: 3 activity B -> counter: 5 ... ... is this possible? thanks, Luke Il giorno martedì 13 no

django - adding a counter for every ManyToMany field added

2012-11-13 Thread luke lukes
field to count and save the quantity of each activity added to my Invoice instance. Is this possible? I mean: for each 'Activity' added to an Invoice instance, i need to count the amount of that activity. thanks, LuKe -- You received this message because you are subscribed to the

Re: Newbie Looking for Starter Plugin

2012-10-05 Thread Luke Hovington
ed to to choose the programing language. Thanks for helping me out. Luke -- You received this message because you are subscribed to the Google Groups "Django users" group. To view this discussion on the web visit https://groups.google.com/d/msg/django-users/-/Vo8qtcPZ-P8J. To post to th

Newbie Looking for Starter Plugin

2012-10-05 Thread Luke Hovington
After lots of talk on I'm going to start using Django a project turned up that allowed me to start learning how this all works. So far I have managed (Via tutorials) to get everything setup and running nicely, I have also installed admin_tools which brings me to my question. Is there any plugin

Re: django forms - overriding constructor for changing field type depending by input

2012-05-20 Thread luke lukes
the form.errors print show an empty dict. The form is returned back and instead of renderized ChoiceFields as select, i got these messages printed in html: ...any help? Il giorno domenica 20 maggio 2012 14:21:39 UTC+2, Paul Prior ha scritto: > > I think you need self.fields[field_name] =

Re: django forms - overriding constructor for changing field type depending by input

2012-05-20 Thread luke lukes
Il giorno domenica 20 maggio 2012 13:49:28 UTC+2, luke lukes ha scritto: > > Hi. already tried this way --> fields are instantiated > () but are not > rendered in the template... > > Il giorno domenica 20 maggio 2012 03:25:36 UTC+2, somecallitblues ha > scritto: >&

Re: django forms - overriding constructor for changing field type depending by input

2012-05-20 Thread luke lukes
Hi. already tried this way --> fields are instantiated () but are not rendered in the template... Il giorno domenica 20 maggio 2012 03:25:36 UTC+2, somecallitblues ha scritto: > > Hey Luke, > > I don't think you need to return anything, especially not a super clas

django forms - overriding constructor for changing field type depending by input

2012-05-19 Thread luke lukes
hi everyone. i need to overrid the constructor of a form: if i have some value in input, some fields has to be ChoiceField, otherwise they have to be CharField. here's the code: http://dpaste.com/750343/ but this way doesn't work. even if i declare fields before constructor as CharField and t

Re: deploying django - including third party apps

2012-04-26 Thread luke lukes
enied* any help? Il giorno giovedì 26 aprile 2012 04:32:01 UTC+2, Daniel Sokolowski ha scritto: > > If you have shell access you could do a virtualenv/pip combo install. > > *From:* luke lukes > *Sent:* Wednesday, April 25, 2012 11:14 AM > *To:* django-users@googlegro

deploying django - including third party apps

2012-04-25 Thread luke lukes
ll. Now i've checked on alwaysdata.com and reportlab is installed, but seems there's no django_evolution. what i have to do to include it in my app and to get it working? thanx LuKe -- You received this message because you are subscribed to the Google Groups "Django users" g

reportlab.platypus - frame and background image made with Canvas

2012-04-19 Thread luke lukes
Hi everyone. i'm using Reportlab to output an invoice on a simple Django app. I've already modified the code many times and here's the result: http://dpaste.com/734262/ . Well, this code doesn't work. the issue seems to be on the section from line to line 105 and line 108, on which i got the follow

reportlab.platypus - rendering template with a right aligned image in the template header as background

2012-04-10 Thread luke lukes
x27;ve tried to look at Reportlab documentation but seems not so clear to me and poor of code snippets. tnx to everyone, LuKe -- 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@googleg

Re: Django - Forms Widget TypeChoiceField - how to set id for two radio buttons

2011-12-28 Thread luke lukes
t"}) > > > > > > > > On Tue, Dec 27, 2011 at 3:08 AM, Mengu wrote: > > hi luke, > > > instead of setting auto_id to False, you should give it a string > > parameter. please read more on > > >https://docs.djangoproject.com/en/dev/ref/for

Django - Forms Widget TypeChoiceField - how to set id for two radio buttons

2011-12-26 Thread luke lukes
to_id=False) in the view, but it's just my assumption, anyway i haven't find anything helpful on the internet.any idea? thanx - luke -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-use

Django - ValidationError on saving a model instance containing DateField

2011-11-26 Thread luke lukes
hi everyone. I'm working on this view: http://dpaste.com/661995/ and i have a ValidationError while trying to save the model instance. the error is 'Enter a valid date in -MM-DD format'. the datefield is correctly filled, the type of instance passed to model is unicode. I have to do something l

django model forms validation and error display

2011-11-01 Thread luke lukes
i have this template: http://dpaste.com/645468/ that send data to this view: http://dpaste.com/645469/. the template display a form made by modelforms, with a custom layout. i have to validate the fields value send to view, and then redirect to the same template if the field validation fails. i've

Re: django request.POST data caching

2011-11-01 Thread luke lukes
nt them to see, even if it is just additional form > fields (within the same, or another, view). > > I'm not sure what you're trying to achieve by clicking on the "back" button > -- but if you give some more information on what you're actually trying to > achieve, I&

django request.POST data caching

2011-10-29 Thread luke lukes
hi have a template with a form and many inputs that pass some data trough a POST request to a view, that process them and send the result to another template. in the final template, if i use the browser back button to jump to the first view, i can see again old data. i refresh the page and i insert

{% url %} and None

2010-12-23 Thread Luke Maurer
I have a few pages essentially implementing a master/detail view; it's a report with variably many different constraints on the data. I'm making thorough use of Django's flexible URL configuration — I have just one view, defined by one (rather long) regex with multiple optional capturing groups.

I can't get urls with explicit keyword arguments to reverse correctly.

2010-02-08 Thread Luke Sneeringer
er-nonprofit". I really do not want to do this if I can avoid it. That would require me to have something to the effect of... {% if nonprofit %} {% url register-nonprofit %} {% else %} {% url register %} {% endif %} ...on the relevant pages. That's substantially less c

Re: Access apache environment variable in template

2010-02-04 Thread Luke Sneeringer
out of a QueryDict, but I expect that {{ request.META.TIER }} would work. Regards, Luke On February 4, 2010, at 11:25 , Sonal Breed wrote: > Hi all, > In my default-server.conf, I set an env variable as > setenv TIER hi > > Can anybody let me know how can I access this

It looks like Django is working from a stale DB. What am I doing wrong?

2010-02-04 Thread Luke Sneeringer
Good morning, everyone! Apologies in advance if this is the wrong place to ask this question. First of all, the setup. I'm using MySQL and InnoDB tables. I've encountered an unusual problem, which has reared its ugly head on several fronts. The basic jist is that Django seems to not recognize dat

Building a form to write one of two models

2009-10-16 Thread Luke Sneeringer
). - if the form is bound, do not include the "type" field (as I don't want the user to be able to change it) I'm pretty sure my solution is off base. Can someone enlighten me regarding a better way? Much obliged! Thanks, Luke Sneeringer --~--~-~--~~~

Re: connectiong querysets

2009-08-11 Thread Luke Seelenbinder
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 http://docs.djangoproject.com/en/dev/topics/db/queries/#complex-lookups-with-q-objects Luke Seelenbinder luke.seelenbin...@gmail.com http://www.google.com/profiles/luke.seelenbinder On Tue, Aug 11, 2009 at 9:38 AM, elminio wrote: -BEGIN PGP

Re: Django comments honeypot hide

2009-08-10 Thread Luke Seelenbinder
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 xhtml: html: Luke Seelenbinder luke.seelenbin...@gmail.com http://www.google.com/profiles/luke.seelenbinder -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.9 (GNU/Linux) iEYEARECAAYFAkqAgj8ACgkQXQrGVCncjPz8FACffs+kJ757sMZIB2MEiuLX7V9P LIQAnj

Re: Javascript with built-in templates tags

2009-08-08 Thread Luke Seelenbinder
efore you post here, it wastes our time, and yours waiting for a response. Thanks! We are more than happy to help, just please check the documentation first. ;) Hope that works for you. Luke Seelenbinder luke.seelenbin...@gmail.com On Sat, Aug 8, 2009 at 5:32 PM, WilsonOfCanada wrote: -BEGI

Re: using python libraries in django?

2009-08-08 Thread Luke Seelenbinder
Django follows normal python import rules. So just lookup those to know what Django can use and how it needs to be setup. -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Luke Seelenbinder luke.seelenbin...@gmail.com -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.9 (GNU/Linux) iEYEARECAAYFAkp

Re: How to get rid of the 'u'? Seems to be everyhere :)

2009-08-08 Thread Luke Seelenbinder
anything with Django, it helped a lot. Hope it helps, Luke Seelenbinder luke.seelenbin...@gmail.com On Sat, Aug 8, 2009 at 10:03 PM, strotos wrote: > > Hey all, > > I am very new to Django and am having a bit of trouble with something > and I'm hoping I can get some help fro

Re: Javascript with built-in templates tags

2009-08-08 Thread Luke Seelenbinder
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 I think your problem is just the spaces between the filters, try {{ mooman|safe|escapejs }}. Other then that, as long as the mooman is set in the context... that should work. Luke On Sat, Aug 8, 2009 at 12:34 PM, WilsonOfCanada wrote: -BEGIN

Re: Duplicate results using ORd Q queries

2009-08-08 Thread Luke Seelenbinder
. Luke On Sat, Aug 8, 2009 at 10:21 AM, Tom wrote: -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.9 (GNU/Linux) iEYEARECAAYFAkp9n94ACgkQXQrGVCncjPyeLQCeKGYLvv4jL2vDLLQ+DQKh/1+d lg0AoIEABek7zEx800mmEpnjzUH0uxVa =w/tR -END PGP SIGNATURE- > > Luke, > > That's brilliant,

Re: Duplicate results using ORd Q queries

2009-08-08 Thread Luke Seelenbinder
helps. Luke On Sat, Aug 8, 2009 at 9:19 AM, Thomas Scrace wrote: > > Hi all, > > In order to teach myself Django I am creating a simple film database > project.  My search code looks like this: > > results = Film.objects.filter( >                      

Re: Javascript with built-in templates tags

2009-08-07 Thread Luke Seelenbinder
. Luke On Fri, Aug 7, 2009 at 10:31 PM, WilsonOfCanada wrote: -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.9 (GNU/Linux) iEYEARECAAYFAkp85c8ACgkQXQrGVCncjPyvtACfdp1MNDbfcA4FVXCEBA6vAlAs NGgAnjlGepehXauPkVf20eW2wGtKiqfa =29IC -END PGP SIGNATURE- > > Hellos, > > I was wond

Re: ValueError

2009-08-06 Thread Luke Seelenbinder
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Could we have the full traceback? That really isn't enough information to determine your problem. Regards, Luke luke.seelenbin...@gmail.com rekha wrote: > Hi, im getting ValueError when try to redirect to an html page.. also > the vali

Re: multiple projects shared database

2009-08-05 Thread Luke Seelenbinder
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 There is no problem with that, as long as your code accounts for it. Luke luke.seelenbin...@gmail.com Robin Becker wrote: > My boss wants to have two different django controlled websites with a common > database. Is there a way to d

Re: Counting results

2009-08-05 Thread Luke Seelenbinder
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 I believe QuerySets have a .count() method. Luke luke.seelenbin...@gmail.com When ideas fail wrote: > Hi, I was wondering what is the simpliest way to count the number of > objects returned in a QuerySet? > > Basically i have a blo

Re: Template links when Django not domain root

2009-08-01 Thread Luke Seelenbinder
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Check out RequestContext and setting it up with the setting in settings.py: http://docs.djangoproject.com/en/dev/ref/settings/#template-context-processors Luke luke.seelenbin...@gmail.com "I [may] disapprove of what you say, but I will defe

Re: Amazon Product Advertising API

2009-08-01 Thread Luke Seelenbinder
0% sure it works, but for what I've used it for I think it does. Any testing is 100% appreciated. Luke Seelenbinder luke.seelenbin...@gmail.com "I [may] disapprove of what you say, but I will defend to the death your right to say it." -- Voltaire br...@instantdirectmarketing.c

Re: Log in problem

2009-07-31 Thread Luke Seelenbinder
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Try: {% if user.is_authenticated() %} If that doesn't work, you would need to setup the TEMPLATE_CONTEXT_PROCESSORS setting in settings.py. http://docs.djangoproject.com/en/dev/ref/settings/#template-context-processors Luke luke.seel

Re: Do I need django.contrib.auth in my INSTALLED_APP when if I don't use the models from there?

2009-07-31 Thread Luke Seelenbinder
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 No, you would not. Hope that helps. Luke luke.seelenbin...@gmail.com "I [may] disapprove of what you say, but I will defend to the death your right to say it." -- Voltaire Vasil Vangelovski wrote: > It's like this: > I act

Re: Log in problem

2009-07-31 Thread Luke Seelenbinder
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 No it doesn't. That would be your problem, you would have to write a custom backend if you wanted to not show the login form to already logged-in visitors. Luke luke.seelenbin...@gmail.com "I [may] disapprove of what you say, but I will

Re: Do I need django.contrib.auth in my INSTALLED_APP when if I don't use the models from there?

2009-07-31 Thread Luke Seelenbinder
need to know what apps it is using. Luke luke.seelenbin...@gmail.com "I [may] disapprove of what you say, but I will defend to the death your right to say it." -- Voltaire Vasil Vangelovski wrote: > I'm making a very small project that will use the apps/models from a >

Re: Log in problem

2009-07-31 Thread Luke Seelenbinder
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Are you passing the "request" to it? That's the only thing I can think of that would mess it up, otherwise it looks good syntactically. Luke luke.seelenbin...@gmail.com "I [may] disapprove of what you say, but I will defend to

Re: Django 1.1 returns 500 instead of 404 in non-debug mode

2009-07-30 Thread Luke Seelenbinder
p with the views, or somewhere in the server process. I'll look through and see if I can spot anything. Good luck! Luke luke.seelenbin...@gmail.com "I [may] disapprove of what you say, but I will defend to the death your right to say it." -- Voltaire prabhu S wrote: > Hi Luke

Re: how encrypt datetime.now with python?

2009-07-30 Thread Luke Seelenbinder
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 convert it to a string: str(datetime.now()) Luke luke.seelenbin...@gmail.com "I [may] disapprove of what you say, but I will defend to the death your right to say it." -- Voltaire Asinox wrote: > hi guys, i want to encrypt the

Re: Django 1.1 returns 500 instead of 404 in non-debug mode

2009-07-30 Thread Luke Seelenbinder
default', name='guidy-default'), That should fix your problem. What is actually happening is you are raising 500s on 404s. That's why the 404 error page is not showing. Luke luke.seelenbin...@gmail.com "I [may] disapprove of what you say, but I will defend to the

Re: dictionaries in template

2009-07-30 Thread Luke Seelenbinder
sibly do you mean to use if loops in the template since you are only passing one object? Luke luke.seelenbin...@gmail.com "I [may] disapprove of what you say, but I will defend to the death your right to say it." -- Voltaire Salvatore Leone wrote: > Hi, > > I pass to my templa

Re: [solved]Re: test if GET is "empty"

2009-07-29 Thread Luke Seelenbinder
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 There is a more "pythonic" way to test, use request.GET.get(, False) e.g.: if request.GET.get('q', False): etc. That tests the dict for the key 'q' if it's not there, it returns false. Luke Seelenbinder luke

Re: No such Table Error

2009-07-28 Thread Luke Seelenbinder
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Did you run manage.py syncdb in your project folder? And are the apps in your settings.py? Luke Seelenbinder marcoshernandez wrote: > Im having this error in my application (both admin models and my app > models) I'm almost certain tha

Re: IDE for Django and Ext JS

2009-07-28 Thread Luke Seelenbinder
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 I don't know of an extension for Eclipse. I really hope somebody will develop one soon. As far as Netbeans django template handling, I've heard they have a beta version. Haven't tried it yet though. Luke S. Jonas Obrist wrote:

Re: IDE for Django and Ext JS

2009-07-28 Thread Luke Seelenbinder
that just use vim. My recommendation is try out the ones that interest you and have the features you need, give them a week of development and decide for yourself. That is really the only way to find "your" IDE. We could start a fight really quickly if "the best IDE" discussio

Re: Where are the admin app icons from?

2009-07-27 Thread Luke Seelenbinder
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 No problem, glad to help. At that size things really are hard to deal with, hope you find the solution. Luke S. Margie wrote: > > I'll try the css idea, but I suspect that things this small just can't > be resized well. I

Re: Trying to reference a foreignKey in a modelAdmin class

2009-07-27 Thread Luke Seelenbinder
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 What error exactly is it throwing? I noticed this: is it supposed to be: list_filter('Competition.startDate', 'Division')? Hope that helps. We really need the error it is throwing to more accurately diagnose and repair. Luke

Re: Where are the admin app icons from?

2009-07-27 Thread Luke Seelenbinder
Could you resize them simply with CSS? CSS handles resizing quite well. I did find one set of icons sized at 10x10 here: http://www.brandspankingnew.net/archive/2006/12/hohoho.html But they are greyscale. Luke S. On Mon, Jul 27, 2009 at 3:07 PM, Margie wrote: > > Yeah, I looked at tho

Re: Where are the admin app icons from?

2009-07-27 Thread Luke Seelenbinder
I think they are the FamFamFam Icon pack. http://www.famfamfam.com/ Luke S. On 07/27/2009 02:10 PM, Margie wrote: Yeah ... I know where the icons used in the admin app are. And I'm using them in my own app (which is derived from the admin app). So I was just trying to figure out if

Re: Application level data

2009-07-27 Thread Luke Seelenbinder
Look at the official caching documentation: Low-level API (for individual data pieces) http://docs.djangoproject.com/en/dev/topics/cache/#the-low-level-cache-api That should work for you Luke S. On 07/27/2009 12:21 PM, vishy wrote: > Hi, > > I have some data which I don't wa

Re: Using Django's Cache

2009-07-20 Thread Luke Seelenbinder
That is entirely possible; however, it might slow down the rendering of the template, because you simply have more to handle. Luke On Jul 20, 12:49 pm, WilsonOfCanada wrote: > Well then I will have to try a different approach.  When using > render_to_response('webpage.html', d

Re: How redirect lightweight webserver messages?

2009-07-17 Thread Luke Seelenbinder
That would depend on the OS you use. If you use linux: "python manage.py runserver >> example.log" That will save the output in a file, instead of showing it on screen, allowing you to have another webserver serve it. Luke On Jul 17, 6:38 am, Andrew wrote: > Hi, >

Amazon Product Advertising API

2009-07-17 Thread Luke Seelenbinder
, is there anybody willing to help me develop a new python abstraction for the api. I'm going to get started today with a new python api, if there is anybody willing to help, drop me an email (lukeqsee at gmail), or just reply to this message

AttributeError: 'str' object has no attribute '_default_manager'

2009-06-01 Thread Luke Graybill
I am getting this error under either mod_python or mod_wsgi, when the project functions just fine under the development server. I've pasted the more detailed traceback here (edited out some of the sensitive corporate stuff). We are using Django 1.0.2 and Python 2.6 on Ubun

Re: how can I modify automatic ordering of fields in a ModelForm?

2009-05-12 Thread Luke Graybill
Sorry, see my last reply above; dpaste.org doesn't seem to have an edit feature, so I submitted a new paste without typos. On Tue, May 12, 2009 at 1:37 PM, George Song wrote: > > On 5/12/2009 12:28 PM, Luke Graybill wrote: > > Here is how I've implemented field orde

Re: how can I modify automatic ordering of fields in a ModelForm?

2009-05-12 Thread Luke Graybill
Erm, that should be this link, my apologies: http://dpaste.org/7WiU/ On Tue, May 12, 2009 at 1:28 PM, Luke Graybill wrote: > The fields option on the inner Meta class does not appear to function that > way in 1.0.2; I presume it is a 1.1 forward feature. (doh, yeah it says > developmen

Re: how can I modify automatic ordering of fields in a ModelForm?

2009-05-12 Thread Luke Graybill
The fields option on the inner Meta class does not appear to function that way in 1.0.2; I presume it is a 1.1 forward feature. (doh, yeah it says development version only in those docs you pointed to) Here is how I've implemented field ordering for 1.0.2, and it seems pre

Re: how can I modify automatic ordering of fields in a ModelForm?

2009-05-12 Thread Luke Graybill
se the same preferred field ordering, but I'll take what I can get, atm. On Tue, May 12, 2009 at 12:32 PM, Luke Graybill wrote: > I didn't mean to imply a feature suggestion, I meant to ask if this is > possible already. If not, then is there some way to manipulate the form > __i

Re: how can I modify automatic ordering of fields in a ModelForm?

2009-05-12 Thread Luke Graybill
m I out of luck on this, or can I get some ideas on how better to handle things? On Tue, May 12, 2009 at 12:26 PM, George Song wrote: > > On 5/12/2009 11:22 AM, Luke Graybill wrote: > > Is there a good way to dynamically reorder these fields on the fly? > > Preferably, the code sh

how can I modify automatic ordering of fields in a ModelForm?

2009-05-12 Thread Luke Graybill
I am using a mixin class on some of my models that provides a few extra fields: > class Mixin(models.Model): > code = models.CharField(max_length=8, blank=True, unique=True) > hint = models.CharField(max_length=8, unique=True, null=True, > blank=True) > > class Meta: >

Re: Using managers for related object access

2008-12-05 Thread Luke Graybill
Thanks for the help, bruno. I'm glad to hear that I wasn't misreading the documentation in some fashion. I'll apply your suggestions. Luke On Thu, Dec 4, 2008 at 2:21 PM, bruno desthuilliers < [EMAIL PROTECTED]> wrote: > > > > On 4 déc, 21:39, "Luke Graybil

Using managers for related object access

2008-12-04 Thread Luke Graybill
nked above seems fairly straightforward, so am I missing something obvious here? I'm hesitant to file this as a bug report, because I have not found any mention of similar issues posted, and that leads me to feel that I must be in the wrong. Any help would be appreciated. Thanks! Luke --~--~

order_by function

2008-11-21 Thread Luke Seelenbinder
Can I order_by a function within the model? I know you can list them in the admin inteface, etc. But can you order_by a model function? Or would you have to write a custom piece of code to do that? Thanks, Luke --~--~-~--~~~---~--~~ You received this message

Combine QuerySets from two different child models

2008-11-19 Thread Luke Seelenbinder
annot combine queries on two different base models." is there anyway to accomplish this, the reason I don't want to do: nouns= list(Noun.objects.all()) verbs=list(Verb.objects.all()) words = verbs + nouns is I want to be able to run an order_by on the resulting list or queryset

Re: ManyToManyField with multiple model options

2008-11-15 Thread Luke Seelenbinder
That was a typo. The error I'm getting is "ForeignKey cannot define a relation with abstract class Word" It is a ManyToMany through table, that's the reason it is ForeignKey Luke On Nov 15, 8:29 pm, Malcolm Tredinnick <[EMAIL PROTECTED]> wrote: > On Sat, 20

Re: Css and Images are missing

2008-11-15 Thread Luke Seelenbinder
Django doesn't serve the media files, look at http://docs.djangoproject.com/en/dev/howto/static-files/?from=olddocs Luke On Nov 15, 10:49 am, Luis Goncalves <[EMAIL PROTECTED]> wrote: > Hello guys I need your help in here. > > Sorry I am new in Django and I am having a prob

Re: Bug in Admin or in my model ?

2008-11-15 Thread Luke Seelenbinder
You need to specify your encoding in your models file. Like: # -*- coding: iso-8859-15 -*- Look at http:// evanjones.ca/python-utf8.html The sixth section of the page explains. Regards Luke On Nov 15, 11:09 am, Ivan Mincik <[EMAIL PROTECTED]> wrote: > Hi, > I have a problem when a

ManyToManyField with multiple model options

2008-11-15 Thread Luke Seelenbinder
gular = models.BooleanField(...) #Here is where I need the help def WordStats(models.Model): # I get an error saying word = models.ManyToManyField(Word) stats = ... Is there anyway to accomplish this? Without writing separate models for each word. Thanks, Lu

Re: Foreign Key with a default key

2008-11-13 Thread Luke Seelenbinder
made a mistake in the c&p the line: definition = models.CharField(max_length='100', default=Stat()) should be: definition = models.CharField(max_length='100',) On Nov 13, 6:35 pm, Luke Seelenbinder <[EMAIL PROTECTED]> wrote: > I'm

Foreign Key with a default key

2008-11-13 Thread Luke Seelenbinder
ld(max_length='100',) definition_stats= models.ForeignKey(Stat, default=Stat(),) irregular = models.BooleanField() Thanks, Luke --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django users" g

Re: Create field from two others

2008-07-04 Thread Luke Seelenbinder
Thanks, for the reply I have since defined a function to handle this. On Thu, Jul 3, 2008 at 11:35 PM, James Bennett <[EMAIL PROTECTED]> wrote: > > On Thu, Jul 3, 2008 at 8:59 PM, lukeqsee <[EMAIL PROTECTED]> wrote: > > > > Can you take a first_name & a last_name field and then in the same > > mo

  1   2   3   >