Sunday, January 1, 2012

Re: Django app for IP address lookup

Nice little web app.

It would be great if you can put the source code on GitHub, so others may benefit from this :)

Cal

On Sun, Jan 1, 2012 at 6:56 AM, Timothy Makobu <makobu.mwambiriro@gmail.com> wrote:
Thanks man. Happy new year!


On Sun, Jan 1, 2012 at 9:33 AM, Addy Yeow <ayeowch@gmail.com> wrote:
Here you go:
http://dazzlepod.com/ip/8.8.8.8.json

On Sat, Dec 31, 2011 at 10:14 PM, Timothy Makobu <makobu.mwambiriro@gmail.com> wrote:
Thanks.

Do you have an API for it yet? so we can do something like http://dazzlepod.com/ip/api/json/1x7.x37.8.xx and get the data in JSON?


On Sat, Dec 31, 2011 at 4:09 PM, yati sagade <yati.sagade@gmail.com> wrote:
Nice app :) can you share the sources? And happy new year to you, too!


On Sat, Dec 31, 2011 at 5:20 PM, Addy Yeow <ayeowch@gmail.com> wrote:
Hi guys,

Just sharing a simple Django app that allows you to do IP address lookup:

Happy new year!

--
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 django-users+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/django-users?hl=en.

--
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 django-users+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/django-users?hl=en.

--
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 django-users+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/django-users?hl=en.

--
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 django-users+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/django-users?hl=en.

--
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 django-users+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/django-users?hl=en.

--
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 django-users+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/django-users?hl=en.

Re: Happy new year

Happy new year everyone :)

Lets hope 2012 is a great year for Django!!

On Sun, Jan 1, 2012 at 8:58 AM, Daniel Ngarambe <dngarz@gmail.com> wrote:

Hello Geeks,

I wish you all a happy mew year.

DNSr.

Sent from Samsung Galaxy S

On 1 Jan 2012 08:24, "girish shabadimath" <girishmss.1203@gmail.com> wrote:
New year wishes to everyone,,

regards,
girish ms
On Sun, Jan 1, 2012 at 10:24 AM, Nikhil Verma <varma.nikhil22@gmail.com> wrote:
Happy new year to all of you.


On Sun, Jan 1, 2012 at 10:22 AM, yati sagade <yati.sagade@gmail.com> wrote:
Happy new year all :)


On Sun, Jan 1, 2012 at 7:54 AM, Adrien Lemaire <adrien.lemaire@aquasys.co.jp> wrote:
Happy new year dear folks !

On Jan 1, 1:48 am, Sławomir Zborowski <stilew...@gmail.com> wrote:
> Happy new year, Django users :-) !

--
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 django-users+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/django-users?hl=en.


--
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 django-users+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/django-users?hl=en.



--
Regards
Nikhil Verma
+91-958-273-3156


--
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 django-users+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/django-users?hl=en.



--
Girish M S

--
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 django-users+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/django-users?hl=en.

--
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 django-users+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/django-users?hl=en.

--
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 django-users+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/django-users?hl=en.

"1054 unknown column..." in MySql5

Hi,
I hope I get your good helps or advises.

MY SYSTEM : win7, python2.6, django-1.3.1, using development
server(django), MySql5

After making model class, "1054 unknown column...in field list."
message is shown in admin page.

Is this a MySql version issue? or?

Thanks any.


Happy New Year~

--
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 django-users+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/django-users?hl=en.

User-set domain-prefixes, i.e. myname.googlegroups.com

Good morning,

I want to integrate user-set domain-prefixes to the registration
process of my site.

Sample form:

Username: []
Name: []
Password: []
Email: []
Domain prefix: [].googlegroups.com

How would I go about doing this in Django? — I suspect there would be
some facets of this (i.e. DNS) outside the scope of Django, but there
would be a good portion of it possible within Django.

Thanks for all suggestions,

Alec Taylor

--
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 django-users+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/django-users?hl=en.

Re: Django dev/deploy environment for distributed agile teams

Thanks Denis, I am not sure about using Gunicorn. Actually am thinking about a more async, non-blocking platform maybe using Tornado. What do you think?

Cheers,

On 11 Dey, 1390, at 12:53 AM, Denis Darii wrote:

Hi Ashkan,

You can take a look at our project: django-fagungis = DJANGO + FAbric + GUnicorn + NGInx + Supervisor deployment
Here: https://bitbucket.org/DNX/django-fagungis/
We use it for the same purpose as you described.
If you have some questions, suggestions or ideas about and for the project feel free to open an issue on bitbucket.

Happy new year to all!


On Sat, Dec 31, 2011 at 8:11 PM, Paul Msegeya <msegeya@gmail.com> wrote:
sounds good...Happy new year too.


On Sat, Dec 31, 2011 at 10:25 PM, Ashkan Roshanayi <ashkan.roshanayi@gmail.com> wrote:
Hi everybody, we are working in a geographically distributed agile team. I am trying to design and configure our development environment and deployment procedures and need to know about your valuable experiences. My requirements are:

* Each new developer can kick-start developing: dev environment and all installs/configs (python related) should be achievable in 15 minutes. This procedure should be automated and repeatable.

* Everybody can pull & build whole project locally and run complete *functional* test suite

* Upon pushing code in our Github repo, it will be pulled out by our build/staging server automatically --> all *functional* & *non-functional* tests will be run by Jenkins --> if successful: we can test it manually on this server too.

* Admins can choose some features or profiles on this staging server and deploy them to live (production) server by ideally executing a script


I've read a lot about virtualenv, pip, fabric, puppet, chef & blueprint and used some of them but want to hear more about your recommendations, best practices and potential pitfalls. Appreciate it very much.

Happy new year :)

--
Ashkan

--
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 django-users+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/django-users?hl=en.



--
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 django-users+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/django-users?hl=en.



--
This e-mail and any file transmitted with it is intended only for the person or entity to which is addressed and may contain information that is privileged, confidential or otherwise protected from disclosure. Copying, dissemination or use of this e-mail or the information herein by anyone other than the intended recipient is prohibited. If you are not the intended recipient, please notify the sender immediately by return e-mail, delete this communication and destroy all copies.

--
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 django-users+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/django-users?hl=en.

Re: Multiple access to static data

If you are sending a 2mb json on every action and there are only about
40 nutrients per food, either I am missing a point or something is
really wrong about your logic.

On Dec 3 2011, 12:34 pm, mf <mf2...@gmail.com> wrote:
> I'm building an application and I'm having trouble making a choice
> about how is the best way to access multiple times to static data in a
> django app. My experience in the field is close to zero so I could use
> some help.
>
> The app basically consists in a drag & drop of foods. When you drag a
> food to a determined place(breakfast for example) differents values
> gets updated: total breakfast calories, total day nutrients(Micro/
> Macro), total day calories, ...That's why I think the way I store and
> access the data it's pretty important performance speaking.
>
> This is an excerpt of the json file I'm currently using:
>
> foods.json
>
> {
> "112": {
>     "type": "Vegetables",
>     "description": "Mushrooms",
>     "nutrients": {
>         "Niacin": {
>             "unit": "mg",
>             "group": "Vitamins",
>             "value": 3.79
>         },
>         "Lysine": {
>             "units": "g",
>             "group": "Amino Acids",
>             "value": 0.123
>         },
>         ... (+40 nutrients)
>     "amount": 1,
>     "unit": "cup whole",
>     "grams": 87.0 }
>  }
>
> I've thought about different options:
>
> 1) JSON(The one I'm currently using):
>
> Every time I drag a food to a "droppable" place, I call a getJSON
> function to access the food data and then update the corresponding
> values. This file has a 2mb size, but it surely will increase as I add
> more foods to it. I'm using this option because it was the most
> quickest to begin to build the app but I don't think it's a good
> choice for the live app.
>
> 2) RDBMS with normalized fields:
>
> I could create two models: Food and Nutrient, each food has 40+
> nutrients related by a FK. The problem I see with this is that every
> time a food data request is made, the app will hit the db a lot of
> times to retrieve it.
>
> 3) RDBMS with picklefield:
>
> This is the option I'm actually considering. I could create a Food
> models and put the nutrients in a picklefield.
>
> 4) Something with Redis/Django Cache system:
>
> I'll dive more deeply into this option. I've read some things about
> them but I don't clearly know if there's some way to use them to solve
> the problem I have.
>
> Thanks in advance, Mariano.

--
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 django-users+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/django-users?hl=en.

Re: Internationalization and localization

I always create multilingual sites. What I do is inspired by django-
modeltranslation, but I find awkward that it leaves a "default"
language field and I prefer to have all my fields defined inside my
models.

1. Create a field for each language and a function that returns the
field corresponding to the client language:

class MyModel(models.Model):
title_ca = models.CharField(max_length=255)
title_en = models.CharField(max_length=255)
title_es = models.CharField(max_length=255)
def title(self):
return getattr(self, 'title_%s' % get_language())

2. In templates call the fuction that detects the language:
{{object.title}}

2. Then, urls.py looks like this:
(r'^$', 'home'),
(r'^(?P<language>\w{2})/$', 'home'),

3. And views.py:

from myapp.utils import enable_language

def home(request, language=None):

# We don't want urls without language prefix in order to prevent
duplicate content
if language is None:
return
HttpResponseRedirect(reverse('isaweb.views.home',kwargs={'language':get_language()}) )

enable_language(request, language)

return render_to_response('home.html',
{},context_instance=RequestContext(request))

4. This goes into utils.py:

def enable_language(request, language):
# Language only gets updated if it changed or is not set.
try:
if request.session['django_language'] != language:
request.session['django_language'] = language
translation.activate(language)
request.LANGUAGE_CODE = translation.get_language()
except KeyError:
request.session['django_language'] = language
translation.activate(language)
request.LANGUAGE_CODE = translation.get_language()


On Dec 7 2011, 3:14 am, kenneth gonsalves <law...@thenilgiris.com>
wrote:
> On Mon, 2011-12-05 at 19:00 -0800, rentgeeen wrote:
> > What I want to how to translate stuff from DB, all at django official
> > say is about static content, what I have only found is this:
>
> django-modeltranslation
> --
> regards
> Kenneth Gonsalves

--
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 django-users+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/django-users?hl=en.