I have a several classes in models.py, and I would like to load some data
into these models (or tables in the db), as well as add more data over time
through the admin panel.
I googled for some ideas on how to pre-populate the db tables, and found
references to RunSQL (
Hey there!
Glad to join the community! Hope all is well!
I am having issues with the python-social-auth package in Django 1.11.5 and
1.8.
I copied the example on http://python-social-auth-docs.readthedocs.io and
got the error below:
HTTPError at /oauth/login/twitter/
401 Client Error:
>
> Hi Melvyn,
I am lack of knowledge how to use model manager. Would you mind give a
quick example? Thanks
- timh
--
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
Yes, you'd need to do this manually - the databinding in Channels right now
is very barebones and doesn't handle initial state versus change
management. I'd love to eventually get a full event-sourcing solution done,
but I have a lot of things I would like to do!
Andrew
On Thu, Sep 7, 2017 at
Hi,
I'm creating a prototype using Django Channels and I have a question that I
haven't sorted out yet. First of all, big thanks to all django-channels
developer, this is something I was missing for a long time.
So I have a connection that watches on a model and sends updates to a
frontend. It
I've seen this on a few projects before and each time transitioned the
project away from it.
As you note, for whatever advantages it seems like there may be, it's very
much atypical and also unnecessary. I don't see how it makes writing Fabric
tasks significantly easier (presumably you don't
Hi,
You can use requests or urllib ,
was there in similar condition before and this is the Link that helped
me:
https://stackoverflow.com/questions/16760992/how-to-download-a-zip-file-from-a-site-python
might be useful to you too
On Thursday, 7 September 2017 13:42:24 UTC+5:45, vishnu
James, you da man! Fixed it at last.
The problem in the end was indeed lighttpd and is explained here:
https://searchcode.com/codesearch/view/12783344/
Essentially lighttpd splits REQUEST_URI into SCRIPT_NAME and PATH_INFO
and passes those three along with a host of other values in the
Thanks a lot it's work.
i use tag
On Thursday, September 7, 2017 at 2:05:10 PM UTC+4:30, Bernd Wechner wrote:
>
> Ramin,
>
> That's an HTML question, and nothing to do with Django. In HTML whitespace
> all just collapses to a single space, newlines included, and you need to
> request them
Ramin,
That's an HTML question, and nothing to do with Django. In HTML
whitespace all just collapses to a single space, newlines included, and
you need to request them explicitly.
You can wrap it all in atag pair or replace \n with
in your string, but that is just two of a plethora of
Thanks Bernd,
Your right, but i have problem show in view with output format ipconfig in
html,
i try display :
PPP adapter VPN:
Connection-specific DNS Suffix . :
Link-local IPv6 Address . . . . . : fe80::50a6:e568:7895:590d%24
IPv4 Address. . . . . . . . . . . : 172.32.87.176
Hi,
I would recommend that you checkout how django uses storage backends. The
reason for that is that if you would like to use your application with a
cloud provider that has a storage solution - for example S3, your code
won't work the way it is written now.
However if you just make some minor
Thanks.
My solution:
urls.py
url(r'^download/$', 'views.download', name='download'),
template.html
Download dei datiIndietro
views.py
def download(request):
data = open(os.path.join(settings.MEDIA_ROOT, 'static/tmp/dati.csv'),
'r').read()
resp = HttpResponse(data,
You can use a package like requests for that. See
http://docs.python-requests.org/en/master/
You will there be able to download it to a temp directory and then add use
it to connect to your model.
Regards,
Andréas
2017-09-07 10:13 GMT+02:00 vishnu bhand :
> How should i
Ramin,
I'm sorry but your question is not very clear. How about you capture the
output of "ipconfig /all" with something like:
IPconfig = subprocess.check_output(["ipconfig", "/all"], stderr=devnull)
then add Config to your template context in a view something like:
def
How should i download zip from web into my django-project?
On Thursday, September 7, 2017 at 1:35:04 PM UTC+5:30, Andréas Kühne wrote:
>
> Hi,
>
> If you only want to save the content "as is" to a model - just use the
> FileField on the model. See here:
>
>
how should i download zip from web?
--
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 post to this group, send email
On Sep 7, 2017 12:10 AM, "Ramin Farajpour Cami"
wrote:
Hi,
Hi,
I going to show output command "ipconfig /all" in html django template but
i have string uncomfortable,
for example :
i going to show this in html :
Windows IP Configuration
PPP adapter VPN:
Hi,
If you only want to save the content "as is" to a model - just use the
FileField on the model. See here:
https://docs.djangoproject.com/en/1.11/ref/models/fields/#filefield
You can then also use different types of storage backends to save the file
to either the server itself or to the cloud
hello , i want to download zip file from web into my django-project and
save all it's file content to model ...So how should i go?
--
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
hello ,
--
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 post to this group, send email to
Hi,
Hi,
I going to show output command "ipconfig /all" in html django template but
i have string uncomfortable,
for example :
i going to show this in html :
Windows IP Configuration
PPP adapter VPN:
Connection-specific DNS Suffix . :
Link-local IPv6 Address . . . . . :
22 matches
Mail list logo