Re: ModuleNotFoundError: No module named :

2019-09-23 Thread Abu Yusuf
Error in admin.py. So same here in admin.py.

Before starting a django project, try to understand the architecture of it
and the working flow of it.
Otherwise, you can't go long away.
Best Wishes,

On Tue, Sep 24, 2019 at 10:32 AM Abu Yusuf 
wrote:

> In your views.py:
> from .models import users
>
> That's it.
>
> On Tue, Sep 24, 2019 at 10:13 AM Deep Sukhwani 
> wrote:
>
>> Are you supposed to be using a virtualenv and you don't have that
>> activated?
>>
>> Can you run *pip freeze | grep -i django* and share the output?
>>
>> --
>> Regards
>> Deep L Sukhwani
>>
>>
>> On Tue, 24 Sep 2019 at 09:40, MEGA NATHAN 
>> wrote:
>>
>>> Hi.
>>>
>>>
>>> i 'm meganathan from india i was doing django trining ,
>>>
>>> And i have one dout .mo module name found models
>>>
>>> *ModuleNotFoundError: No module named 'django.models'*
>>>
>>>
>>>
>>>
>>>
>>> *Regards*
>>> *Meganathan,*
>>>
>>> --
>>> 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...@googlegroups.com.
>>> To view this discussion on the web visit
>>> https://groups.google.com/d/msgid/django-users/f85f29b7-e3d9-4dfa-945f-70f1fb8e90f1%40googlegroups.com
>>> 
>>> .
>>>
>> --
>> 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...@googlegroups.com.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/django-users/CAEMqiPe7rf4syuVUTEZVO%2BOMh7K-cvGX_yLsL0vhchNbTTfATw%40mail.gmail.com
>> 
>> .
>>
>

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CACNsr2-bU6cCHuthEizB4ZB45UcTns3c-wERXqmbo36upa7Ksw%40mail.gmail.com.


Re: ModuleNotFoundError: No module named :

2019-09-23 Thread Abu Yusuf
In your views.py:
from .models import users

That's it.

On Tue, Sep 24, 2019 at 10:13 AM Deep Sukhwani 
wrote:

> Are you supposed to be using a virtualenv and you don't have that
> activated?
>
> Can you run *pip freeze | grep -i django* and share the output?
>
> --
> Regards
> Deep L Sukhwani
>
>
> On Tue, 24 Sep 2019 at 09:40, MEGA NATHAN 
> wrote:
>
>> Hi.
>>
>>
>> i 'm meganathan from india i was doing django trining ,
>>
>> And i have one dout .mo module name found models
>>
>> *ModuleNotFoundError: No module named 'django.models'*
>>
>>
>>
>>
>>
>> *Regards*
>> *Meganathan,*
>>
>> --
>> 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...@googlegroups.com.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/django-users/f85f29b7-e3d9-4dfa-945f-70f1fb8e90f1%40googlegroups.com
>> 
>> .
>>
> --
> 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...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/CAEMqiPe7rf4syuVUTEZVO%2BOMh7K-cvGX_yLsL0vhchNbTTfATw%40mail.gmail.com
> 
> .
>

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CACNsr2826OxbwQ5YJx0v%3DeYLfrRyVvJeQ94Y8yo_qfOhhAb02Q%40mail.gmail.com.


Re: ModuleNotFoundError: No module named :

2019-09-23 Thread Deep Sukhwani
Are you supposed to be using a virtualenv and you don't have that activated?

Can you run *pip freeze | grep -i django* and share the output?

--
Regards
Deep L Sukhwani


On Tue, 24 Sep 2019 at 09:40, MEGA NATHAN  wrote:

> Hi.
>
>
> i 'm meganathan from india i was doing django trining ,
>
> And i have one dout .mo module name found models
>
> *ModuleNotFoundError: No module named 'django.models'*
>
>
>
>
>
> *Regards*
> *Meganathan,*
>
> --
> 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...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/f85f29b7-e3d9-4dfa-945f-70f1fb8e90f1%40googlegroups.com
> 
> .
>

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CAEMqiPe7rf4syuVUTEZVO%2BOMh7K-cvGX_yLsL0vhchNbTTfATw%40mail.gmail.com.


Re: request module

2019-09-23 Thread Deep Sukhwani
The right place for this would be "requests" community -
https://2.python-requests.org/en/master/community/support/#e-mail

The best immediate course of action would be to post a question on
stackoverflow.com and tag the question with *python-requests*

--
Regards
Deep L Sukhwani


On Mon, 23 Sep 2019 at 18:11, dandu sreenivasulu 
wrote:

> Hi All,
>  can someone please help on below request
>
> url = 'http://abc.com/'
> response = requests.get(url)# 
> url1 = response.url # http://xyz.com --> when we access abc.com url it
> will redirect to xyz.com url and there we have to entere username and
> password
> print(url1) #xyz.com
> print(response.url) #xyz.com
> post_data = {
> 'User Name': 'sr...@gmail.com',
> 'Password': 'srinu123',
> 'action':'btnLogin'
> }
> with requests.Session() as s:
> r = s.post(url1, data=post_data)
> r = s.post(url1, auth=HTTPBasicAuth('sr...@gmail.com', 'srinu123'))
> print(response.status_code) # 200
> print(response.text) # error //
>
> questions:
> 1) what attributes i have to take from text filed ?
>
> User Id:
> Passwor:
>
>
>
> --
> 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...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/406a807c-9979-42c6-b061-9a12d66cd65b%40googlegroups.com
> 
> .
>

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CAEMqiPd9XEK3H76tgJKw%2BdiUyPFBGHBLygqZ1FCwXY4xhmFgoQ%40mail.gmail.com.


Re: Help for building recommendation system in django

2019-09-23 Thread Gabriel Araya Garcia
Hi, What is an  recommendation system ? I live in Chile, and I do not know
what is that.
Have you something done in this minute ?

El mar., 24 sept. 2019 a las 0:35, Mahir Shah ()
escribió:

> Hello , I am trying to build an recommendation system on books using
> django framework but am not been able do it . Please help me out with this
>
> --
> 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...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/27027877-2836-452b-a608-473100edc83e%40googlegroups.com
> .
>


-- 
Gabriel Araya Garcia
GMI - Desarrollo de Sistemas Informáticos
99.7721.15.70

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CAKVvSDCHwtWZSrAbgarmevWNR%3D81EfZDfh%2BnmecTeaLHRQw5xQ%40mail.gmail.com.


Help for building recommendation system in django

2019-09-23 Thread Mahir Shah
Hello , I am trying to build an recommendation system on books using django 
framework but am not been able do it . Please help me out with this 

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/27027877-2836-452b-a608-473100edc83e%40googlegroups.com.


Re: TemplateDoesNotExist

2019-09-23 Thread Manish Maurya
create  a folder name as template in your django project and open your
settings.py file  in template in dir write "templates"


On Mon, 23 Sep 2019 at 19:56, oba stephen  wrote:

> Try using "./base.html"
>
> I believe this should do it.
>
> On Mon, Sep 23, 2019, 1:40 PM yerri swamy 
> wrote:
>
>> Hi guys,
>>
>> By using templates folder i am not getting what i am expecting
>> and i am getting error 'Template Does Not Exist' ,and also defaulty it's
>> not coming templates variable in settings.py file,How do i slove this error
>> please explain me any one.
>>
>> --
>> 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...@googlegroups.com.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/django-users/208e411a-a8f5-4238-b846-f086826f2ff4%40googlegroups.com
>> 
>> .
>>
> --
> 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...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/CAAJsLnoeWbqy6TFuph1j2%2ByaZuek1wFLUbGdYObf_RYzSOEusA%40mail.gmail.com
> 
> .
>

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CANyc5fe6cJh-8JwPYKoPsERTpFfYTst1py%2BnHHqhgVzTBdxKYg%40mail.gmail.com.


Re: Error while trying to connect latest Dango with MSSQL

2019-09-23 Thread Praveen Kumar
Please find blow the error I'm receiving

Traceback (most recent call last):

  File "C:\ProgramData\Anaconda3\lib\threading.py
",
line 916, in _bootstrap_inner

self.run()

  File "C:\ProgramData\Anaconda3\lib\threading.py
",
line 864, in run

self._target(*self._args, **self._kwargs)

  File "C:\ProgramData\Anaconda3\lib\site-packages\django\utils\
autoreload.py
",
line 54, in wrapper

fn(*args, **kwargs)

  File
"C:\ProgramData\Anaconda3\lib\site-packages\django\core\management\commands\
runserver.py
",
line 109, in inner_run

autoreload.raise_last_exception()

  File "C:\ProgramData\Anaconda3\lib\site-packages\django\utils\
autoreload.py
",
line 77, in raise_last_exception

raise _exception[1]

  File
"C:\ProgramData\Anaconda3\lib\site-packages\django\core\management\__init__.py",
line 337, in execute

autoreload.check_errors(django.setup)()

  File "C:\ProgramData\Anaconda3\lib\site-packages\django\utils\
autoreload.py
",
line 54, in wrapper

fn(*args, **kwargs)

  File "C:\ProgramData\Anaconda3\lib\site-packages\django\__init__.py",
line 24, in setup

apps.populate(settings.INSTALLED_APPS)

  File "C:\ProgramData\Anaconda3\lib\site-packages\django\apps\registry.py
",
line 114, in populate

app_config.import_models()

  File "C:\ProgramData\Anaconda3\lib\site-packages\django\apps\config.py
",
line 211, in import_models

self.models_module = import_module(models_module_name)

  File "C:\ProgramData\Anaconda3\lib\importlib\__init__.py", line 126, in
import_module

return _bootstrap._gcd_import(name[level:], package, level)

  File "", line 994, in _gcd_import

  File "", line 971, in _find_and_load

  File "", line 955, in _find_and_load_unlocked

  File "", line 665, in _load_unlocked

  File "", line 678, in exec_module

  File "", line 219, in
_call_with_frames_removed

  File "C:\ProgramData\Anaconda3\lib\site-packages\django\contrib\auth\
models.py
",
line 2, in 

from django.contrib.auth.base_user import AbstractBaseUser,
BaseUserManager

  File "C:\ProgramData\Anaconda3\lib\site-packages\django\contrib\auth\base_
user.py
",
line 47, in 

class AbstractBaseUser(models.Model):

  File "C:\ProgramData\Anaconda3\lib\site-packages\django\db\models\base.py
",
line 117, in __new__

new_class.add_to_class('_meta', Options(meta, app_label))

  File "C:\ProgramData\Anaconda3\lib\site-packages\django\db\models\base.py
",
line 321, in add_to_class

value.contribute_to_class(cls, name)

  File "C:\ProgramData\Anaconda3\lib\site-packages\django\db\models\
options.py
",
line 204, in contribute_to_class

self.db_table = truncate_name(self.db_table,
connection.ops.max_name_length())

  File "C:\ProgramData\Anaconda3\lib\site-packages\django\db\__init__.py",
line 28, in __getattr__

return getattr(connections[DEFAULT_DB_ALIAS], item)

  File "C:\ProgramData\Anaconda3\lib\site-packages\django\db\utils.py

Django bootstrap calendar

2019-09-23 Thread Perceval Maturure
Is there anyone with a step by step procedure of doing this app in a Django
2.1 environment For newbies like some of us in Django
Regards
Perceval
-- 
Sent from Gmail Mobile

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CAFZtZmB2Nm9kZjSy_OkLeMS3j%2B%2BgBXrnkTG2j3jwiacpuq6hSQ%40mail.gmail.com.


Re: TemplateDoesNotExist

2019-09-23 Thread Tosin Ayoola
Can you paste the section of your view code & Hw are you referencing your
base.html is it directly in ur templates folder?

On Sep 23, 2019 13:40, "yerri swamy"  wrote:

Hi guys,

By using templates folder i am not getting what i am expecting and
i am getting error 'Template Does Not Exist' ,and also defaulty it's not
coming templates variable in settings.py file,How do i slove this error
please explain me any one.

-- 
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...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/
msgid/django-users/208e411a-a8f5-4238-b846-f086826f2ff4%40googlegroups.com

.

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CAHLKn72RA0QThHM0GLNuPAdm9r46fKExeFsgSKy5sj%2Bk_btHVw%40mail.gmail.com.


RE: TemplateDoesNotExist

2019-09-23 Thread laya
Hi ,
You should config the template settings:
'BACKEND': 'django.template.backends.django.DjangoTemplates',
'DIRS': [os.path.join(BASE_DIR, 'templates')],


Sent from Mail for Windows 10

From: yerri swamy
Sent: Monday, September 23, 2019 4:11 PM
To: Django users
Subject: TemplateDoesNotExist

Hi guys, 
  
    By using templates folder i am not getting what i am expecting and i am 
getting error 'Template Does Not Exist' ,and also defaulty it's not coming 
templates variable in settings.py file,How do i slove this error please explain 
me any one.   
-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/208e411a-a8f5-4238-b846-f086826f2ff4%40googlegroups.com.

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/5d890eb1.1c69fb81.aa801.2119%40mx.google.com.


Re: TemplateDoesNotExist

2019-09-23 Thread anilumarane
Give the html file current pathSent from my Samsung Galaxy smartphone.
 Original message From: oba stephen  
Date: 23/09/2019  19:55  (GMT+05:30) To: django-users@googlegroups.com Subject: 
Re: TemplateDoesNotExist Try using "./base.html"I believe this should do it. On 
Mon, Sep 23, 2019, 1:40 PM yerri swamy  wrote:Hi 
guys,       By using templates folder i am not getting what i am 
expecting and i am getting error 'Template Does Not Exist' ,and also defaulty 
it's not coming templates variable in settings.py file,How do i slove this 
error please explain me any one.   



-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/208e411a-a8f5-4238-b846-f086826f2ff4%40googlegroups.com.




-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CAAJsLnoeWbqy6TFuph1j2%2ByaZuek1wFLUbGdYObf_RYzSOEusA%40mail.gmail.com.

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/5d88e2a2.1c69fb81.175a3.2a78%40mx.google.com.


Re: Docker performance on Mac OS X

2019-09-23 Thread Chris Wedgwood
Hi Jason

Thank you for your response. I misdaignosed my issue. It actually had 
nothing to do with Docker and instead was a slow performing form in the 
django admin that had a widget referencing a foreign key which was taking 
forever to build.

I fixed it with raw_id_fields, so am now back on docker

In terms of my docker usage I will verse myself in allocations etc

cheers
Chris


On Monday, 23 September 2019 12:18:03 UTC+1, Jason wrote:
>
> What kind of hardware are you working with?  What resources do you have 
> allocated to Docker.  Are you including tens of thousands of files in 
> volume mounts?
>
> We use docker extensively at work, and I've found it helps to have at 
> least half of your machine's hardware available to docker.  My 2018 MBP has 
> 5 cores and 10GB RAM allocated.
>
> However, docker is very sensitive to the amount of files being included 
> and being watched over.  SO if you have thousands to tens of thousands of 
> files in your volume mount symlinks, performance is going to be poor.
>

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/f9a2c6a3-9199-4eee-b362-024f38ba9469%40googlegroups.com.


Re: TemplateDoesNotExist

2019-09-23 Thread oba stephen
Try using "./base.html"

I believe this should do it.

On Mon, Sep 23, 2019, 1:40 PM yerri swamy  wrote:

> Hi guys,
>
> By using templates folder i am not getting what i am expecting and
> i am getting error 'Template Does Not Exist' ,and also defaulty it's not
> coming templates variable in settings.py file,How do i slove this error
> please explain me any one.
>
> --
> 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...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/208e411a-a8f5-4238-b846-f086826f2ff4%40googlegroups.com
> 
> .
>

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CAAJsLnoeWbqy6TFuph1j2%2ByaZuek1wFLUbGdYObf_RYzSOEusA%40mail.gmail.com.


Re: Transaction.atomic()

2019-09-23 Thread Jani Tiainen
And TL;DR; versio.

Code which is wrapped within atomic transaction will guarantee that if code
breaks changes are rolled back.

ma 23. syysk. 2019 klo 15.42 Aryan Patel  kirjoitti:

> Hi colleagues,
>
> I want to understand if transaction.atomic() in django guarantees that the
> client is getting status what the django is sending?
>
> This question is just for discussion whether the django builds a pipeline
> with the client and if the network broke down while the django is sending
> the status then transaction.atomic will be reverted back or it will
> successfully commits regardless whether the client is getting status or
> not?
>
> --
> 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...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/571c334b-9508-41e7-b360-2d312774c192%40googlegroups.com
> 
> .
>

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CAHn91oeob-NwqPq6w5CsojZqmLTdLsVx_61-EL5vG-V-%3D2fGxw%40mail.gmail.com.


Re: Transaction.atomic()

2019-09-23 Thread Jason
no, atomic transactions are just for the database.  It has nothing to do 
with a client, just the integrity of a data commit. 


-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/13e5f4be-f7cd-4eb2-98fc-939198cebabd%40googlegroups.com.


Re: TemplateDoesNotExist

2019-09-23 Thread Desh Deepak
Show me your views.py file.

On Mon, 23 Sep 2019, 18:48 Abu Yusuf,  wrote:

> 1. ensure you have a folder templates inside static folder
> 2. ensure you filled up templates_dir: 'templates'
> 3. ensure 'base.html' exists inside templates folder
>
> On Mon, Sep 23, 2019 at 6:40 PM yerri swamy 
> wrote:
>
>> Hi guys,
>>
>> By using templates folder i am not getting what i am expecting
>> and i am getting error 'Template Does Not Exist' ,and also defaulty it's
>> not coming templates variable in settings.py file,How do i slove this error
>> please explain me any one.
>>
>> --
>> 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...@googlegroups.com.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/django-users/208e411a-a8f5-4238-b846-f086826f2ff4%40googlegroups.com
>> 
>> .
>>
> --
> 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...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/CACNsr29mvap_G4%2Bc70NrkDZEQvPye%3D22caxfBvdUvMt_b7kXqQ%40mail.gmail.com
> 
> .
>

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CAJ0m4xiPWfJ%3Dt-CjkDL81F7wn5ETmcBRacMyBi5n0zpO0C%3DUQg%40mail.gmail.com.


Re: TemplateDoesNotExist

2019-09-23 Thread Abu Yusuf
1. ensure you have a folder templates inside static folder
2. ensure you filled up templates_dir: 'templates'
3. ensure 'base.html' exists inside templates folder

On Mon, Sep 23, 2019 at 6:40 PM yerri swamy 
wrote:

> Hi guys,
>
> By using templates folder i am not getting what i am expecting and
> i am getting error 'Template Does Not Exist' ,and also defaulty it's not
> coming templates variable in settings.py file,How do i slove this error
> please explain me any one.
>
> --
> 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...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/208e411a-a8f5-4238-b846-f086826f2ff4%40googlegroups.com
> 
> .
>

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CACNsr29mvap_G4%2Bc70NrkDZEQvPye%3D22caxfBvdUvMt_b7kXqQ%40mail.gmail.com.


Transaction.atomic()

2019-09-23 Thread Aryan Patel
Hi colleagues,

I want to understand if transaction.atomic() in django guarantees that the 
client is getting status what the django is sending?

This question is just for discussion whether the django builds a pipeline 
with the client and if the network broke down while the django is sending 
the status then transaction.atomic will be reverted back or it will 
successfully commits regardless whether the client is getting status or 
not? 

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/571c334b-9508-41e7-b360-2d312774c192%40googlegroups.com.


Re: how to use generic_inlineformset_factory ?

2019-09-23 Thread MohammadReza Kasaie Sharifi
I want ti open the link but it was expired

On Monday, December 8, 2008 at 7:16:49 AM UTC+3:30, Marco Louro wrote:
>
> Hi, 
>
> I'm trying to use generic_inlineformset_factory. There are no docs for 
> it except a Generic Relations Model example @ 
> http://www.djangoproject.com/documentation/models/generic_relations/ 
> on the bottom (GenericInlineFormSet tests) 
>
> My question here is how to pass the POST vars to it? 
>
> In a modelformset_factory the following works: 
>  formset = AddressFormSet(request.POST, request.FILES) 
>
> but here it is not the case.. 
>

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/9d0635d1-6067-4dc1-9f2e-1df1fe0799c7%40googlegroups.com.


request module

2019-09-23 Thread dandu sreenivasulu
Hi All,
 can someone please help on below request

url = 'http://abc.com/'
response = requests.get(url)# 
url1 = response.url # http://xyz.com --> when we access abc.com url it will 
redirect to xyz.com url and there we have to entere username and password
print(url1) #xyz.com
print(response.url) #xyz.com
post_data = {
'User Name': 'sr...@gmail.com',
'Password': 'srinu123',
'action':'btnLogin'
}
with requests.Session() as s:
r = s.post(url1, data=post_data)
r = s.post(url1, auth=HTTPBasicAuth('sr...@gmail.com', 'srinu123'))
print(response.status_code) # 200
print(response.text) # error //

questions:
1) what attributes i have to take from text filed ? 
   
User Id:
Passwor:
   
   

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/406a807c-9979-42c6-b061-9a12d66cd65b%40googlegroups.com.


Re: Docker performance on Mac OS X

2019-09-23 Thread Jason
What kind of hardware are you working with?  What resources do you have 
allocated to Docker.  Are you including tens of thousands of files in 
volume mounts?

We use docker extensively at work, and I've found it helps to have at least 
half of your machine's hardware available to docker.  My 2018 MBP has 5 
cores and 10GB RAM allocated.

However, docker is very sensitive to the amount of files being included and 
being watched over.  SO if you have thousands to tens of thousands of files 
in your volume mount symlinks, performance is going to be poor.

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/2542d571-0c64-473a-81aa-7aacea2ab300%40googlegroups.com.


Re: Class Based View All Methods

2019-09-23 Thread Abu Yusuf
Most Welcome

On Mon, Sep 23, 2019 at 4:03 PM Shakil Ahmmed 
wrote:

> Thank You Bhaia <3
>
> On Mon, Sep 23, 2019 at 4:02 PM Abu Yusuf 
> wrote:
>
>> yes, of course. see here:
>> https://www.django-rest-framework.org/topics/html-and-forms/
>>
>>
>> On Mon, Sep 23, 2019 at 3:55 PM Shakil Ahmmed 
>> wrote:
>>
>>> Can I Return Html Template From APIView ?
>>>
>>> On Monday, September 23, 2019 at 12:12:54 PM UTC+6, Shakil Ahmmed wrote:

 How Can i Use Those Methods In One Class Base View ['get', 'post',
 'put', 'patch', 'delete', 'head', 'options', 'trace']

 Example:

 from django.views import View

 class Home(View):
   def get(self, request, *args, **kwargs):

 return HttpResponse('Hello, World!')

 def post(self, request, *args, **kwargs):

 return HttpResponse('Hello, World!')


 def put(self, request, *args, **kwargs):

 return HttpResponse('Hello, World!')


 def delete(self, request, *args, **kwargs):

 return HttpResponse('Hello, World!')

 --
>>> 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...@googlegroups.com.
>>> To view this discussion on the web visit
>>> https://groups.google.com/d/msgid/django-users/7aada502-1f1c-4eef-b4ba-70dcc4bee3ec%40googlegroups.com
>>> 
>>> .
>>>
>> --
>> 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...@googlegroups.com.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/django-users/CACNsr2-pd_MeLdkCqpDP3ARLE_0sWWoVywv1pVw64sv2-ZH17g%40mail.gmail.com
>> 
>> .
>>
>
>
> --
>
> 
> Shakil Ahmmed
> about.me/shakilahmmed
> 
>
> --
> 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...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/CA%2BEpJfzP24WT1DCnaVRn3WjsV-AHwMVK9%2BiLokWg_2x5pBrtwg%40mail.gmail.com
> 
> .
>

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CACNsr2-HvsVsJFxg%3DeHab5EBmbBtqyWC2w-06kw%3DPBF3dhb%2B_Q%40mail.gmail.com.


Re: Class Based View All Methods

2019-09-23 Thread Shakil Ahmmed
Thank You Bhaia <3

On Mon, Sep 23, 2019 at 4:02 PM Abu Yusuf 
wrote:

> yes, of course. see here:
> https://www.django-rest-framework.org/topics/html-and-forms/
>
>
> On Mon, Sep 23, 2019 at 3:55 PM Shakil Ahmmed 
> wrote:
>
>> Can I Return Html Template From APIView ?
>>
>> On Monday, September 23, 2019 at 12:12:54 PM UTC+6, Shakil Ahmmed wrote:
>>>
>>> How Can i Use Those Methods In One Class Base View ['get', 'post',
>>> 'put', 'patch', 'delete', 'head', 'options', 'trace']
>>>
>>> Example:
>>>
>>> from django.views import View
>>>
>>> class Home(View):
>>>   def get(self, request, *args, **kwargs):
>>>
>>> return HttpResponse('Hello, World!')
>>>
>>> def post(self, request, *args, **kwargs):
>>>
>>> return HttpResponse('Hello, World!')
>>>
>>>
>>> def put(self, request, *args, **kwargs):
>>>
>>> return HttpResponse('Hello, World!')
>>>
>>>
>>> def delete(self, request, *args, **kwargs):
>>>
>>> return HttpResponse('Hello, World!')
>>>
>>> --
>> 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...@googlegroups.com.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/django-users/7aada502-1f1c-4eef-b4ba-70dcc4bee3ec%40googlegroups.com
>> 
>> .
>>
> --
> 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...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/CACNsr2-pd_MeLdkCqpDP3ARLE_0sWWoVywv1pVw64sv2-ZH17g%40mail.gmail.com
> 
> .
>


-- 

Shakil Ahmmed
about.me/shakilahmmed


-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CA%2BEpJfzP24WT1DCnaVRn3WjsV-AHwMVK9%2BiLokWg_2x5pBrtwg%40mail.gmail.com.


Re: Class Based View All Methods

2019-09-23 Thread Abu Yusuf
yes, of course. see here:
https://www.django-rest-framework.org/topics/html-and-forms/


On Mon, Sep 23, 2019 at 3:55 PM Shakil Ahmmed 
wrote:

> Can I Return Html Template From APIView ?
>
> On Monday, September 23, 2019 at 12:12:54 PM UTC+6, Shakil Ahmmed wrote:
>>
>> How Can i Use Those Methods In One Class Base View ['get', 'post', 'put',
>> 'patch', 'delete', 'head', 'options', 'trace']
>>
>> Example:
>>
>> from django.views import View
>>
>> class Home(View):
>>   def get(self, request, *args, **kwargs):
>>
>> return HttpResponse('Hello, World!')
>>
>> def post(self, request, *args, **kwargs):
>>
>> return HttpResponse('Hello, World!')
>>
>>
>> def put(self, request, *args, **kwargs):
>>
>> return HttpResponse('Hello, World!')
>>
>>
>> def delete(self, request, *args, **kwargs):
>>
>> return HttpResponse('Hello, World!')
>>
>> --
> 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...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/7aada502-1f1c-4eef-b4ba-70dcc4bee3ec%40googlegroups.com
> 
> .
>

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CACNsr2-pd_MeLdkCqpDP3ARLE_0sWWoVywv1pVw64sv2-ZH17g%40mail.gmail.com.


Re: Class Based View All Methods

2019-09-23 Thread Shakil Ahmmed
Can I Return Html Template From APIView ? 

On Monday, September 23, 2019 at 12:12:54 PM UTC+6, Shakil Ahmmed wrote:
>
> How Can i Use Those Methods In One Class Base View ['get', 'post', 'put', 
> 'patch', 'delete', 'head', 'options', 'trace']
>
> Example:
>
> from django.views import View
>
> class Home(View):
>   def get(self, request, *args, **kwargs):
>
> return HttpResponse('Hello, World!')
>
> def post(self, request, *args, **kwargs):
>
> return HttpResponse('Hello, World!')
>
>
> def put(self, request, *args, **kwargs):
>
> return HttpResponse('Hello, World!')
>
>
> def delete(self, request, *args, **kwargs):
>
> return HttpResponse('Hello, World!')
>
>

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/7aada502-1f1c-4eef-b4ba-70dcc4bee3ec%40googlegroups.com.


Re: Class Based View All Methods

2019-09-23 Thread Shakil Ahmmed
Please Provide Me Some Code Example

On Mon, Sep 23, 2019 at 3:47 PM laya Mahmoudi 
wrote:

> Mixinviews can works for your purpose
>
> در تاریخ دوشنبه ۲۳ سپتامبر ۲۰۱۹،‏ ۱۱:۲۵ Shakil Ahmmed <
> shakilfci...@gmail.com> نوشت:
>
>> Please Can You Give me some Exapmle?
>>
>> On Mon, Sep 23, 2019, 1:39 PM Abu Yusuf 
>> wrote:
>>
>>> Check this:
>>> https://docs.djangoproject.com/en/2.2/ref/class-based-views/flattened-index/#formview
>>>
>>> On Mon, Sep 23, 2019 at 12:13 PM Shakil Ahmmed 
>>> wrote:
>>>
 How Can i Use Those Methods In One Class Base View ['get', 'post',
 'put', 'patch', 'delete', 'head', 'options', 'trace']

 Example:

 from django.views import View

 class Home(View):
   def get(self, request, *args, **kwargs):

 return HttpResponse('Hello, World!')

 def post(self, request, *args, **kwargs):

 return HttpResponse('Hello, World!')


 def put(self, request, *args, **kwargs):

 return HttpResponse('Hello, World!')


 def delete(self, request, *args, **kwargs):

 return HttpResponse('Hello, World!')

 --
 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...@googlegroups.com.
 To view this discussion on the web visit
 https://groups.google.com/d/msgid/django-users/2cbd1753-d7d3-40d2-9d47-e935d0e3d75f%40googlegroups.com
 
 .

>>> --
>>> 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...@googlegroups.com.
>>> To view this discussion on the web visit
>>> https://groups.google.com/d/msgid/django-users/CACNsr2-Y7bPvDmCYRdLiZf5vVDbs6tX4EABF5HGzDUt3wvOjLA%40mail.gmail.com
>>> 
>>> .
>>>
>> --
>> 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...@googlegroups.com.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/django-users/CA%2BEpJfxOrX0thTdb%3DoikwmTyGYCGVo4zdbGyA6UxvvyV3E7TLg%40mail.gmail.com
>> 
>> .
>>
> --
> 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...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/CABL_bk2poNSOa0ajfM3NP1XOSg_5T8R3NZHYN%2BtGfGd_cWrRxQ%40mail.gmail.com
> 
> .
>


-- 

Shakil Ahmmed
about.me/shakilahmmed


-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CA%2BEpJfy259BsEHuU8hv7MEDU45gf0BvVKbJGjKhe7YW%3DyzZHng%40mail.gmail.com.


Re: Class Based View All Methods

2019-09-23 Thread Abu Yusuf
You can do that using ApiView also:
details: https://www.django-rest-framework.org/tutorial/3-class-based-views/

class SnippetDetail(APIView):
"""
Retrieve, update or delete a snippet instance.
"""
def get_object(self, pk):
try:
return Snippet.objects.get(pk=pk)
except Snippet.DoesNotExist:
raise Http404

def get(self, request, pk, format=None):
snippet = self.get_object(pk)
serializer = SnippetSerializer(snippet)
return Response(serializer.data)

def put(self, request, pk, format=None):
snippet = self.get_object(pk)
serializer = SnippetSerializer(snippet, data=request.data)
if serializer.is_valid():
serializer.save()
return Response(serializer.data)
return Response(serializer.errors, status=status.HTTP_400_BAD_REQUEST)

def delete(self, request, pk, format=None):
snippet = self.get_object(pk)
snippet.delete()
return Response(status=status.HTTP_204_NO_CONTENT)

urlpatterns = [
path('snippets//', views.SnippetDetail.as_view()),]


On Mon, Sep 23, 2019 at 1:54 PM Shakil Ahmmed 
wrote:

> Please Can You Give me some Exapmle?
>
> On Mon, Sep 23, 2019, 1:39 PM Abu Yusuf 
> wrote:
>
>> Check this:
>> https://docs.djangoproject.com/en/2.2/ref/class-based-views/flattened-index/#formview
>>
>> On Mon, Sep 23, 2019 at 12:13 PM Shakil Ahmmed 
>> wrote:
>>
>>> How Can i Use Those Methods In One Class Base View ['get', 'post',
>>> 'put', 'patch', 'delete', 'head', 'options', 'trace']
>>>
>>> Example:
>>>
>>> from django.views import View
>>>
>>> class Home(View):
>>>   def get(self, request, *args, **kwargs):
>>>
>>> return HttpResponse('Hello, World!')
>>>
>>> def post(self, request, *args, **kwargs):
>>>
>>> return HttpResponse('Hello, World!')
>>>
>>>
>>> def put(self, request, *args, **kwargs):
>>>
>>> return HttpResponse('Hello, World!')
>>>
>>>
>>> def delete(self, request, *args, **kwargs):
>>>
>>> return HttpResponse('Hello, World!')
>>>
>>> --
>>> 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...@googlegroups.com.
>>> To view this discussion on the web visit
>>> https://groups.google.com/d/msgid/django-users/2cbd1753-d7d3-40d2-9d47-e935d0e3d75f%40googlegroups.com
>>> 
>>> .
>>>
>> --
>> 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...@googlegroups.com.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/django-users/CACNsr2-Y7bPvDmCYRdLiZf5vVDbs6tX4EABF5HGzDUt3wvOjLA%40mail.gmail.com
>> 
>> .
>>
> --
> 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...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/CA%2BEpJfxOrX0thTdb%3DoikwmTyGYCGVo4zdbGyA6UxvvyV3E7TLg%40mail.gmail.com
> 
> .
>

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CACNsr28poENPaFMrs1HhBNHneNqd1XAi4AdoYa5jsbqZUiDo%3DA%40mail.gmail.com.


Re: Class Based View All Methods

2019-09-23 Thread laya Mahmoudi
Mixinviews can works for your purpose

در تاریخ دوشنبه ۲۳ سپتامبر ۲۰۱۹،‏ ۱۱:۲۵ Shakil Ahmmed <
shakilfci...@gmail.com> نوشت:

> Please Can You Give me some Exapmle?
>
> On Mon, Sep 23, 2019, 1:39 PM Abu Yusuf 
> wrote:
>
>> Check this:
>> https://docs.djangoproject.com/en/2.2/ref/class-based-views/flattened-index/#formview
>>
>> On Mon, Sep 23, 2019 at 12:13 PM Shakil Ahmmed 
>> wrote:
>>
>>> How Can i Use Those Methods In One Class Base View ['get', 'post',
>>> 'put', 'patch', 'delete', 'head', 'options', 'trace']
>>>
>>> Example:
>>>
>>> from django.views import View
>>>
>>> class Home(View):
>>>   def get(self, request, *args, **kwargs):
>>>
>>> return HttpResponse('Hello, World!')
>>>
>>> def post(self, request, *args, **kwargs):
>>>
>>> return HttpResponse('Hello, World!')
>>>
>>>
>>> def put(self, request, *args, **kwargs):
>>>
>>> return HttpResponse('Hello, World!')
>>>
>>>
>>> def delete(self, request, *args, **kwargs):
>>>
>>> return HttpResponse('Hello, World!')
>>>
>>> --
>>> 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...@googlegroups.com.
>>> To view this discussion on the web visit
>>> https://groups.google.com/d/msgid/django-users/2cbd1753-d7d3-40d2-9d47-e935d0e3d75f%40googlegroups.com
>>> 
>>> .
>>>
>> --
>> 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...@googlegroups.com.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/django-users/CACNsr2-Y7bPvDmCYRdLiZf5vVDbs6tX4EABF5HGzDUt3wvOjLA%40mail.gmail.com
>> 
>> .
>>
> --
> 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...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/CA%2BEpJfxOrX0thTdb%3DoikwmTyGYCGVo4zdbGyA6UxvvyV3E7TLg%40mail.gmail.com
> 
> .
>

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CABL_bk2poNSOa0ajfM3NP1XOSg_5T8R3NZHYN%2BtGfGd_cWrRxQ%40mail.gmail.com.


Re: Class Based View All Methods

2019-09-23 Thread Shakil Ahmmed
Please Can You Give me some Exapmle?

On Mon, Sep 23, 2019, 1:39 PM Abu Yusuf  wrote:

> Check this:
> https://docs.djangoproject.com/en/2.2/ref/class-based-views/flattened-index/#formview
>
> On Mon, Sep 23, 2019 at 12:13 PM Shakil Ahmmed 
> wrote:
>
>> How Can i Use Those Methods In One Class Base View ['get', 'post', 'put',
>> 'patch', 'delete', 'head', 'options', 'trace']
>>
>> Example:
>>
>> from django.views import View
>>
>> class Home(View):
>>   def get(self, request, *args, **kwargs):
>>
>> return HttpResponse('Hello, World!')
>>
>> def post(self, request, *args, **kwargs):
>>
>> return HttpResponse('Hello, World!')
>>
>>
>> def put(self, request, *args, **kwargs):
>>
>> return HttpResponse('Hello, World!')
>>
>>
>> def delete(self, request, *args, **kwargs):
>>
>> return HttpResponse('Hello, World!')
>>
>> --
>> 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...@googlegroups.com.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/django-users/2cbd1753-d7d3-40d2-9d47-e935d0e3d75f%40googlegroups.com
>> 
>> .
>>
> --
> 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...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/CACNsr2-Y7bPvDmCYRdLiZf5vVDbs6tX4EABF5HGzDUt3wvOjLA%40mail.gmail.com
> 
> .
>

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CA%2BEpJfxOrX0thTdb%3DoikwmTyGYCGVo4zdbGyA6UxvvyV3E7TLg%40mail.gmail.com.


Re: Class Based View All Methods

2019-09-23 Thread Abu Yusuf
Check this:
https://docs.djangoproject.com/en/2.2/ref/class-based-views/flattened-index/#formview

On Mon, Sep 23, 2019 at 12:13 PM Shakil Ahmmed 
wrote:

> How Can i Use Those Methods In One Class Base View ['get', 'post', 'put',
> 'patch', 'delete', 'head', 'options', 'trace']
>
> Example:
>
> from django.views import View
>
> class Home(View):
>   def get(self, request, *args, **kwargs):
>
> return HttpResponse('Hello, World!')
>
> def post(self, request, *args, **kwargs):
>
> return HttpResponse('Hello, World!')
>
>
> def put(self, request, *args, **kwargs):
>
> return HttpResponse('Hello, World!')
>
>
> def delete(self, request, *args, **kwargs):
>
> return HttpResponse('Hello, World!')
>
> --
> 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...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/2cbd1753-d7d3-40d2-9d47-e935d0e3d75f%40googlegroups.com
> 
> .
>

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CACNsr2-Y7bPvDmCYRdLiZf5vVDbs6tX4EABF5HGzDUt3wvOjLA%40mail.gmail.com.


Django Multiple File Uploads for latest versions

2019-09-23 Thread Abu Yusuf
Here i have created a repo  Django Multiple File Uploads for latest 
versions(>1.9)

Check this and let me know if there have any issues. Hit star if this helps 
you.

https://github.com/Revel109/django-multiupload-lts

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/a96add2c-4e92-4f32-9e1f-b4c091331faa%40googlegroups.com.


Docker performance on Mac OS X

2019-09-23 Thread Chris Wedgwood
Hi All

I generally use the Django Cookiecutter project to start my projects and
have started using *docker* for my local development.

However I have started to get some really awful performance with pageloads
taking 30-40 seconds. I am know considering stopping using docker entirely.

Has anyone else encountered this on Mac OS and have any wisdom to share to
alleviate?

Thanks
Chris

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CACQBJYXuQ7i3oe22y%2B9c9dOVb5%2Bdc-YjyyrkUZ_GZkbCEp1zMw%40mail.gmail.com.


Class Based View All Methods

2019-09-23 Thread Shakil Ahmmed
How Can i Use Those Methods In One Class Base View ['get', 'post', 'put', 
'patch', 'delete', 'head', 'options', 'trace']

Example:

from django.views import View

class Home(View):
  def get(self, request, *args, **kwargs):

return HttpResponse('Hello, World!')

def post(self, request, *args, **kwargs):

return HttpResponse('Hello, World!')


def put(self, request, *args, **kwargs):

return HttpResponse('Hello, World!')


def delete(self, request, *args, **kwargs):

return HttpResponse('Hello, World!')

-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/2cbd1753-d7d3-40d2-9d47-e935d0e3d75f%40googlegroups.com.


Re: convert python 3 to python2

2019-09-23 Thread Shakil Ahmmed
How Can I Use ['get', 'post', 'put', 'patch', 'delete', 'head', 'options',
'trace'] in One Class

On Sun, Sep 22, 2019 at 4:14 PM Ankita Gupta 
wrote:

>
>
> On Saturday, September 21, 2019 at 11:07:21 PM UTC+5:30, Sipum wrote:
>>
>> Hi Ankita,
>>
>> In coming January, python 2 is going to retire. So better to use python 3.
>>
> Only official access is denied, we can still work in python2. Anyway
> thanks.
>
>>
>>
>
>> Thanks
>>
>> On Sat, 21 Sep, 2019, 11:02 PM Ankita Gupta, 
>> wrote:
>>
>>> Not related to Django, I have a project made in python3 but due to some
>>> package installation, i need to convert my project to python2. Is there any
>>> method or package to solve this?
>>>
>>> --
>>> 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...@googlegroups.com.
>>> To view this discussion on the web visit
>>> https://groups.google.com/d/msgid/django-users/875549f9-5bca-4280-88fd-db197ca577dc%40googlegroups.com
>>> 
>>> .
>>>
>> --
> 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...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/408bd2a0-add7-450d-a004-d5fc22bc4b45%40googlegroups.com
> 
> .
>


-- 

Shakil Ahmmed
about.me/shakilahmmed


-- 
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...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CA%2BEpJfw7h8UzHHDf1vGdqUE9Q9%2BQO%3DcBv6J7uqjJoR0568RVkQ%40mail.gmail.com.