Re: Django "pub_date" error

2018-07-21 Thread Melvyn Sopacua
On maandag 16 juli 2018 04:52:51 CEST Daniel Tobi Onipe wrote: > I wrote it exactly as it is in the tutorial... Maybe that part. But you didn't define the pub_date field on the Question model or made a typo in the field name. Go back into models.py and check. -- Melvyn Sopacua -- You received

Re: Django + WSGI: no HTTP_COOKIE in environ

2018-07-21 Thread Melvyn Sopacua
On donderdag 19 juli 2018 10:34:35 CEST need_some_help wrote: > I first need to make sure I am accessing them correctly. This is as simple > as it gets I imagine: > > view.py: > > def index(environ, start_response, request): > if not 'HTTP_COOKIE' in environ: > response = HttpRespons

display my images available in one class using another class in webpage

2018-07-21 Thread aditya gupta
my Code : class Gallery(models.Model): GameName=models.CharField(max_length=40) D_text=models.CharField(max_length=50) Gime=models.ImageField(upload_to='media/',null=True,blank=True) class Assassin(models.Model): Gimage=models.ImageField(upload_to='media/assassin',null=True,blank=T

Help with FilteredSelectMultiple

2018-07-21 Thread Ike
Good day everyone, I've been stuck with a problem I am having and I can't find any help online. I am trying to assign staffs to a particular role (Moderator, Instructor,) using the FilteredSelectMultiple widget (Similar to Django Admin's assign permissions/groups). I have managed to displa

Re: Help with FilteredSelectMultiple

2018-07-21 Thread Ike
Update: forms.py and designations.html has been updated. This was the only way I could think of for associating the roles to the widget https://gist.github.com/Yggralith0/293c107bef58203a38a84ad4d5df0802 -- You received this message because you are subscribed to the Google Groups "Django users"

Djando 2.0.7 image handling problem on production server

2018-07-21 Thread Asif Khan
I developed application that uses an ImageField in Django==2.0.7 with Pillow 5.2.0 there is no issue on development machine but facing problem on production server giving "Server Error 500" Exception Value: No module named 'PIL' which I have not used or called in my code. I new to Python and Dj

Re: Djando 2.0.7 image handling problem on production server

2018-07-21 Thread Jason
sounds like pillow wasn't installed in your prod environment. how did you set that servcer up? On Saturday, July 21, 2018 at 11:56:12 AM UTC-4, Asif Khan wrote: > > I developed application that uses an ImageField in Django==2.0.7 with > Pillow 5.2.0 there is no issue on development machine bu

Re: Djando 2.0.7 image handling problem on production server

2018-07-21 Thread Asif Khan
Pillow is install in my production environment and the same Pillow 5.2.0 on both development and production. On Saturday, July 21, 2018 at 9:39:36 PM UTC+5, Jason wrote: > > sounds like pillow wasn't installed in your prod environment. how did you > set that servcer up? > > > > On Saturday, Ju

Re: Djando 2.0.7 image handling problem on production server

2018-07-21 Thread Jason
are you sure? open up a python shell on the server and do from *PIL import image* If it works, then the problem is somewhere else. If you get an error, its a missing dependency. -- You received this message because you are subscribed to the Google Groups "Django users" group. To unsubscribe

Re: Djando 2.0.7 image handling problem on production server

2018-07-21 Thread Asif Khan
Oh dear I checked and found that Pillow was install in Python3.5 where as production setup is for Python3.6 so Pillow was installed by pip3.5 but not with pip3.6 which I have installed now. the problem is resolved. Thanks for make me focus on this. On Saturday, July 21, 2018 at 9:58:55 PM UTC+5

Re: Djando 2.0.7 image handling problem on production server

2018-07-21 Thread Melvyn Sopacua
On zaterdag 21 juli 2018 19:08:03 CEST Asif Khan wrote: > Oh dear I checked and found that Pillow was install in Python3.5 where as > production setup is for Python3.6 so Pillow was installed by pip3.5 but not > with pip3.6 which I have installed now. Have a look at pyenv[1]. Relying on "versioned

Re: Help with FilteredSelectMultiple

2018-07-21 Thread Melvyn Sopacua
On zaterdag 21 juli 2018 14:38:11 CEST Ike wrote: > Good day everyone, I've been stuck with a problem I am having and I can't > find any help online. Even though you've done much effort to make a good problem description, you're still making us do a lot of work before we can diagnose your issue:

Re: Django + WSGI: no HTTP_COOKIE in environ

2018-07-21 Thread need_some_help
Thank you Melvyn for your time and response. Regardless of what I call the first parameter, shouldn't HTTP_COOKIE be in it? I have had to reach out to other sources, perhaps the information I provided at the following link can help us figure out what I'm doing completely wrong: https://groups.g

Re: Django + WSGI: no HTTP_COOKIE in environ

2018-07-21 Thread need_some_help
Thank you Melvyn for your time and response. Regardless of what I call the first parameter, shouldn't HTTP_COOKIE be in it? But yes, I am having some confusion about wsgi and django and maybe I am mixing tutorials/information I have found at different sources. I have had to reach out to other s

Re: Django + WSGI: no HTTP_COOKIE in environ

2018-07-21 Thread Jason
its COOKIES, not HTTP_COOKIE, as at https://docs.djangoproject.com/en/2.0/ref/request-response/#django.http.HttpRequest.COOKIES -- 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, se

Re: Djando 2.0.7 image handling problem on production server

2018-07-21 Thread mottaz hejaze
thats why they invented virtualenv On Sat, 21 Jul 2018, 19:36 Melvyn Sopacua, wrote: > On zaterdag 21 juli 2018 19:08:03 CEST Asif Khan wrote: > > > Oh dear I checked and found that Pillow was install in Python3.5 where as > > > production setup is for Python3.6 so Pillow was installed by pip3.5

Re: Djando 2.0.7 image handling problem on production server

2018-07-21 Thread Gerald Brown
I use pyvenvwrapper which I find is even better than pyenv.  Once a project is created just enter "workon proj-name" and it will take you to the project directory.  It can be found at: https://github.com/solovyevn/pyvenvwrapper On Sunday, 22 July, 2018 10:30 AM, mottaz hejaze wrote: thats wh