Anonymous
Not working
Which database you are using
Jimmies San
Yes
use a ci/cd tool [jenkins, gitlab-ci, whatever], create a script that check if migrations: if yes do it, if not go on
cj
do you want to automate the migrate command running?
it that's what you want to do, migrate has to be run once a migration is ready to be applied, so maybe you need to create a task at CI/CD time when your code is deployed to the server, easily achieved using a CI/CD tool
Jimmies San
lol
😂😂❤️
Jimmies San
postgres ftw :D
ಶಶಾಂಕ್
why MySQL? 🤔
I thought he is using MySQL
ಶಶಾಂಕ್
Bcz MySQL only give trouble like operations error
ಶಶಾಂಕ್
Sql
Can u put pic
ಶಶಾಂಕ್
Error getting and line code
Anonymous
Can u put pic
Yeah But group is not allowed you send😅
Jimmies San
Yeah But group is not allowed you send😅
link using an external service
Jimmies San
like imgshare or something
ಶಶಾಂಕ್
Dm me
Jimmies San
so all can see, all can help and no trash on chat :)
cj
or some paste/bin service if you plan to share code... you know, copy/pasting is better from plain text rather than from an image, unless you have a good OCR tool
Anonymous
url(r'polls/',include('polls.urls'),name="i"),
Anonymous
not working
Anonymous
Reverse for 'i' not found. 'i' is not a valid view function or pattern name.
Anonymous
i am trying to link to an app ftom the home section,but showing this error
Anonymous
<a href="{% url 'i' %}"><h3>POLLS</h3></a>
Anonymous
pls help
Mirco
https://wsvincent.com/books/djangoforprofessionals
Mirco
https://wsvincent.com/books/djangoforprofessionals
One of the most recent book on Django 2.2 and Python 3.7 for building prod-ready webapps I've just added it to @pythores
Anonymous
How can I filters the specific fields from the post request
Mirco
How can I filters the specific fields from the post request
Explain better your goal, there are so many ways to "filter"
Anonymous
I want only some fields to be save in the file from the post request
ಶಶಾಂಕ್
How to fetch the data from Excel (csv,text,json)and convert it as django model dynamically in django?
Root
I'm trying to load the files from media dir. I'm using this : urlpatterns += static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT) do i need to import setting or something... ? This is the error NameError: name 'settings' is not defined
Maksim
From Django.conf import settings
Anders (izzno / gooood) 🇳🇴
I just realized I inadvertently set my Django templates up like vue: {% block css %} {% endblock css %} {% block content %} {% endblock content %} {% block javascript %} {% endblock javascript %}
Maverick
I use nvim/gvim/vim.
You must be pro at cmd programming🤔
Anders (izzno / gooood) 🇳🇴
Always did like you ahah
hehe, it's easier to keep track / understand the page you'r working on.
Dennoh
<a href="{% url 'i' %}"><h3>POLLS</h3></a>
This link is supposed to take you to index page of all the polls?
Ghorz
Configure nginx, gunicorn using vagrant, It got speed. So fast that django wsgi crawls
Ghorz
Though I had issues with static files, fixed in less than 5 mins
Anders (izzno / gooood) 🇳🇴
Anders (izzno / gooood) 🇳🇴
seems to be for dev not prod
Ghorz
how is vagrant compared to docker ?
Haven't made use of docker. It's on dev server.
Jesus
I have created two users. One with an custom group and one without group. Now Im trying to create different views(or give it different fucntionalities) depending to which group the user belongs to. I tried this https://pastebin.com/1yBdymvD but indipendently of any groups, it will always load the index without required_group decorator. I have also created a custom group with a custom permission following this tutorial https://medium.com/@theparadoxer02/user-groups-with-custom-permissions-in-django-9eaea67b220e
Anonymous
This link is supposed to take you to index page of all the polls?
i have defined a name='i' in url. so the name with url name 'i' is supposed to work right
Anonymous
what should i do to make it work
Anders (izzno / gooood) 🇳🇴
Haven't made use of docker. It's on dev server.
You made such a big point about speed i got curious... I have not had a problem with speed and Django ever.
Anders (izzno / gooood) 🇳🇴
(gunicorn)
Dennoh
what should i do to make it work
lemme see your polls.urls
Anders (izzno / gooood) 🇳🇴
(and i dont even use extra workers...)
Anonymous
lemme see your polls.urls
path('',views.index,name='index')
Ghorz
(gunicorn)
Have you used it
Ghorz
(and i dont even use extra workers...)
Do you server your files locally or cdn
Anders (izzno / gooood) 🇳🇴
Anders (izzno / gooood) 🇳🇴
Anders (izzno / gooood) 🇳🇴
nginx
Ghorz
Amazon s3 don't quite cut
Anders (izzno / gooood) 🇳🇴
https://github.com/grantjenks/python-diskcache Check this out.
Dennoh
path('',views.index,name='index')
Since after all you want to be taken to index, why can't you refer to *index* instead of i
Anders (izzno / gooood) 🇳🇴
Amazon s3 don't quite cut
I run all my deployments on VPS's It's just as cheap as other options... but requires more knowledge about sysadmin / linux
Anonymous
Anders (izzno / gooood) 🇳🇴
Digital Ocean
Anders (izzno / gooood) 🇳🇴
I just install Gitlabrunner (shell) and docker. Then gitlabds CI/CD does the rest.
Anders (izzno / gooood) 🇳🇴
(Anyway I'd be happy to share some setup later, but this is a Django channel).