Is MQ needed for sending many texts?
I have an API endpoint via Twiliio to send texts, and a lot will be sent each day, typically in batches all at once. The endpoints will be hit to do this. Is a full message queue needed to do this?
I was thinking just an async request like this https://github.com/spyoungtech/grequests along with Twilio's built in monitoring on success/not success could do without holding up the application?
/r/djangolearning
https://redd.it/10desde
I have an API endpoint via Twiliio to send texts, and a lot will be sent each day, typically in batches all at once. The endpoints will be hit to do this. Is a full message queue needed to do this?
I was thinking just an async request like this https://github.com/spyoungtech/grequests along with Twilio's built in monitoring on success/not success could do without holding up the application?
/r/djangolearning
https://redd.it/10desde
GitHub
GitHub - spyoungtech/grequests: Requests + Gevent = <3
Requests + Gevent = <3. Contribute to spyoungtech/grequests development by creating an account on GitHub.
How to put 3 different forms in one page with django and how to call Django's own password change view (PasswordChangeView) from another function?
I have a profile page where I want to
1- change profile picture
2- change name/surname/e-mail
3- change password with django's own PasswordChangeView
I wanted to create a profile class for those and change the data from within that one class, dividing it into 3 functions (change picture, change info, change password (which calls the PasswordChangeView)) but I cant seem to use the POST method with 3 different forms inside one page since it blocks me doing so and doesnt even submit data whatever I try to do so.
So my questions are:
1- is there any way for me to call the PasswordChangeView from another class' function and to change the data from there?
2- any ways that I can change 3 different data with 3 different forms through the same page?
Looked at so many stackoverflow questions, watched so many youtube videos, read the documentation but whatever I tried doesnt seem to work. Couldn't find a way to do that. So any help would be much appreciated.
Thank you in advance!
/r/djangolearning
https://redd.it/10debkj
I have a profile page where I want to
1- change profile picture
2- change name/surname/e-mail
3- change password with django's own PasswordChangeView
I wanted to create a profile class for those and change the data from within that one class, dividing it into 3 functions (change picture, change info, change password (which calls the PasswordChangeView)) but I cant seem to use the POST method with 3 different forms inside one page since it blocks me doing so and doesnt even submit data whatever I try to do so.
So my questions are:
1- is there any way for me to call the PasswordChangeView from another class' function and to change the data from there?
2- any ways that I can change 3 different data with 3 different forms through the same page?
Looked at so many stackoverflow questions, watched so many youtube videos, read the documentation but whatever I tried doesnt seem to work. Couldn't find a way to do that. So any help would be much appreciated.
Thank you in advance!
/r/djangolearning
https://redd.it/10debkj
reddit
How to put 3 different forms in one page with django and how to...
I have a profile page where I want to 1- change profile picture 2- change name/surname/e-mail 3- change password with django's own...
Generative art coded in Python
​
https://preview.redd.it/ozw3udzjelca1.jpg?width=8662&format=pjpg&auto=webp&v=enabled&s=b834cfd8faed8642b502550eb0846e448ec1dbb5
The outputs in the image above are fully coded in Python. The codes producing the digital images rely on the pandas, numpy and plotnine packages.
A little more detailed explanation can be found in our medium article.
​
https://medium.com/@mintofchaos/introducing-dawn-of-chaos-generative-art-concept-revolving-around-randomly-generated-points-e112e17dbc08
/r/Python
https://redd.it/10eahk7
​
https://preview.redd.it/ozw3udzjelca1.jpg?width=8662&format=pjpg&auto=webp&v=enabled&s=b834cfd8faed8642b502550eb0846e448ec1dbb5
The outputs in the image above are fully coded in Python. The codes producing the digital images rely on the pandas, numpy and plotnine packages.
A little more detailed explanation can be found in our medium article.
​
https://medium.com/@mintofchaos/introducing-dawn-of-chaos-generative-art-concept-revolving-around-randomly-generated-points-e112e17dbc08
/r/Python
https://redd.it/10eahk7
Medium
Introducing Dawn of Chaos — generative art concept revolving around randomly generated points
Python is the most used programming language in the 21st century. The majority of our current state of the art technologies rely on code…
What are the best IDEs for Python?
PyCharm is so bulky and takes up too much space on my SSD (I'm so confused as to why but whatever.)
VSCode uses PowerShell and it annoys me because everytime I run a code it prints 5-6 lines about PowerShell and whatever. (If you have a way to remove it that would be PERFECT.)
/r/Python
https://redd.it/10ekmyl
PyCharm is so bulky and takes up too much space on my SSD (I'm so confused as to why but whatever.)
VSCode uses PowerShell and it annoys me because everytime I run a code it prints 5-6 lines about PowerShell and whatever. (If you have a way to remove it that would be PERFECT.)
/r/Python
https://redd.it/10ekmyl
reddit
What are the best IDEs for Python?
PyCharm is so bulky and takes up too much space on my SSD (I'm so confused as to why but whatever.) VSCode uses PowerShell and it annoys me...
Python's Assignment Operator: Write Robust Assignments – Real Python
https://realpython.com/python-assignment-operator/
/r/Python
https://redd.it/10ee6gb
https://realpython.com/python-assignment-operator/
/r/Python
https://redd.it/10ee6gb
Realpython
Python's Assignment Operator: Write Robust Assignments – Real Python
In this tutorial, you'll learn how to use Python's assignment operators to write assignment statements that allow you to create, initialize, and update variables in your code.
Using PyArrow with Pandas - Arrow Tables and Parquet Files explored
Hi all,
This week I published our most recent newsletter, so thanks for sharing your projects so I could find them here and link to them. But one article of mine I linked to that was kind of fun was Python Parquet and Arrow: PyArrow and Pandas. The article covers how to use Pandas with Arrow or Parquet and some benchmarks comparing the performance of Arrow Tables vs. Pandas DataFrames, and Parquet vs. several other file storage choices.
/r/Python
https://redd.it/10el34b
Hi all,
This week I published our most recent newsletter, so thanks for sharing your projects so I could find them here and link to them. But one article of mine I linked to that was kind of fun was Python Parquet and Arrow: PyArrow and Pandas. The article covers how to use Pandas with Arrow or Parquet and some benchmarks comparing the performance of Arrow Tables vs. Pandas DataFrames, and Parquet vs. several other file storage choices.
/r/Python
https://redd.it/10el34b
Build Rich GUI Apps In Python With Aid From Delphi
https://www.i-programmer.info/news/216-python/16018-build-rich-gui-apps-in-python-with-aid-from-delphi.html
/r/Python
https://redd.it/10ejy21
https://www.i-programmer.info/news/216-python/16018-build-rich-gui-apps-in-python-with-aid-from-delphi.html
/r/Python
https://redd.it/10ejy21
www.i-programmer.info
Build Rich GUI Apps In Python With Aid From Delphi
Programming book reviews, programming tutorials,programming news, C#, Ruby, Python,C, C++, PHP, Visual Basic, Computer book reviews, computer history, programming history, joomla, theory, spreadsheets and more.
Boost Your Python Application Performance Using Continuous Profiling
https://medium.com/@martin.heinz/boost-your-python-application-performance-using-continuous-profiling-7eb993e68d23
/r/Python
https://redd.it/10egvm8
https://medium.com/@martin.heinz/boost-your-python-application-performance-using-continuous-profiling-7eb993e68d23
/r/Python
https://redd.it/10egvm8
Medium
Boost Your Python Application Performance Using Continuous Profiling
Learn how to use Grafana Phlare and continuous profiling to discover bottlenecks in you code and boost the performance of your Python apps
asynchrony: asyncio Python framework for writing safe and fast concurrent code
https://github.com/orsinium-labs/asynchrony
/r/Python
https://redd.it/10eedhq
https://github.com/orsinium-labs/asynchrony
/r/Python
https://redd.it/10eedhq
GitHub
GitHub - orsinium-labs/asynchrony: asyncio Python framework for writing safe and fast concurrent code
asyncio Python framework for writing safe and fast concurrent code - GitHub - orsinium-labs/asynchrony: asyncio Python framework for writing safe and fast concurrent code
Create Your OWN Programming Language! EP 2 - Token Types
https://youtube.com/watch?v=Yn9hcQxresM&feature=share
/r/Python
https://redd.it/10ejwix
https://youtube.com/watch?v=Yn9hcQxresM&feature=share
/r/Python
https://redd.it/10ejwix
YouTube
Create Your OWN Programming Language! EP 2 - Token Types
This is Episode 2 ins a series on how to create your own interpreted coding language using python. In this episode I will show you how to determine the different types of tokens which we need to do in order to prepare for future episodes.
DISCLAIMER: this…
DISCLAIMER: this…
Faster than calling abs()
instead of
a = abs(a)
I tried
a = a + (a<0) * (-a-a)
measured it with 10 million calls and it runs in 58% of the time,
see anything wrong with this?
saw some other post where people suggest setting _abs = abs before the loop and use _abs() inside it to make it faster
and still my method runs in 68% of the time it takes the _abs() method.
/r/Python
https://redd.it/10ep3y3
instead of
a = abs(a)
I tried
a = a + (a<0) * (-a-a)
measured it with 10 million calls and it runs in 58% of the time,
see anything wrong with this?
saw some other post where people suggest setting _abs = abs before the loop and use _abs() inside it to make it faster
and still my method runs in 68% of the time it takes the _abs() method.
/r/Python
https://redd.it/10ep3y3
reddit
Faster than calling abs()
instead of a = abs(a) I tried a = a + (a<0) * (-a-a) measured it with 10 million calls and it runs in 58% of the time, see anything...
Semantic workflows backed by Transformers models
https://neuml.github.io/txtai/workflow/
/r/Python
https://redd.it/10ebcma
https://neuml.github.io/txtai/workflow/
/r/Python
https://redd.it/10ebcma
neuml.github.io
txtai - Workflow
txtai is an all-in-one open-source embeddings database for semantic search, LLM orchestration and language model workflows
Is it possible to sort a query.all
just a quick question for those well verse with flask. I'm trying to sort my query before being parse over to a template. Currently it is using model.query.all(), been trying to use .order_by with it but without any luck.
any feedback would be appreciated
/r/flask
https://redd.it/10ekg69
just a quick question for those well verse with flask. I'm trying to sort my query before being parse over to a template. Currently it is using model.query.all(), been trying to use .order_by with it but without any luck.
any feedback would be appreciated
/r/flask
https://redd.it/10ekg69
reddit
Is it possible to sort a query.all
just a quick question for those well verse with flask. I'm trying to sort my query before being parse over to a template. Currently it is using...
Open Source Django Projects for Study
Hello everyone,
I'm looking for open source projects made using Django, preferably Django REST Framework, that fix real business problems, and whose code I can analyze, get ideas and learn from.
So far I've got GitHub repositories of Saleor, Django CMS, Wagtail, and a few more, but I would like to see a solution like an inventory management system of a company, HR system, an API that manages data of a game server, something like that, but I guess anything you find interesting or worth seeing could help.
I know that companies wouldn't release their code like that, but there are probably open-source solutions released to the public somewhere on the internet.
So, are there any repositories you could recommend for analyzing, and learning Django a little more in-depth?
Thanks!
/r/django
https://redd.it/10epg4m
Hello everyone,
I'm looking for open source projects made using Django, preferably Django REST Framework, that fix real business problems, and whose code I can analyze, get ideas and learn from.
So far I've got GitHub repositories of Saleor, Django CMS, Wagtail, and a few more, but I would like to see a solution like an inventory management system of a company, HR system, an API that manages data of a game server, something like that, but I guess anything you find interesting or worth seeing could help.
I know that companies wouldn't release their code like that, but there are probably open-source solutions released to the public somewhere on the internet.
So, are there any repositories you could recommend for analyzing, and learning Django a little more in-depth?
Thanks!
/r/django
https://redd.it/10epg4m
reddit
Open Source Django Projects for Study
Hello everyone, I'm looking for open source projects made using Django, preferably Django REST Framework, that fix real business problems, and...
I made A Reddit Video Website.
My Website: https://vreddit.up.railway.app
This website fetcher data from reddit and presents the Videos in a youtube style.
You can Also Visit subreddits by going to sub search and also can search on whole reddit.
The above Version returns only SFW Videos For nsfw visit https://indianwebseries-hathori.koyeb.app/
Please Give Your feedbacks and also share your experiance. And It will be great if you can me suggestions.
/r/flask
https://redd.it/10f0h82
My Website: https://vreddit.up.railway.app
This website fetcher data from reddit and presents the Videos in a youtube style.
You can Also Visit subreddits by going to sub search and also can search on whole reddit.
The above Version returns only SFW Videos For nsfw visit https://indianwebseries-hathori.koyeb.app/
Please Give Your feedbacks and also share your experiance. And It will be great if you can me suggestions.
/r/flask
https://redd.it/10f0h82
Web app with JavaScript
Hi!
I need some advice. For my portfolio I want to build a web app for my national sports team. A bit like a news website but with some more features. I know Flask already and want to work on my JS skills also. I get confused when reading to use Flask for the backend and JS for frontend. I built Flask only apps without any JS. What will be different when using JS too? Are redirects, form submissions, validations, etc.. still handled by Flask? Do people still use jinja and what would be things I've done normally with Flask and now with JS?
Thank you!
/r/flask
https://redd.it/10ephsw
Hi!
I need some advice. For my portfolio I want to build a web app for my national sports team. A bit like a news website but with some more features. I know Flask already and want to work on my JS skills also. I get confused when reading to use Flask for the backend and JS for frontend. I built Flask only apps without any JS. What will be different when using JS too? Are redirects, form submissions, validations, etc.. still handled by Flask? Do people still use jinja and what would be things I've done normally with Flask and now with JS?
Thank you!
/r/flask
https://redd.it/10ephsw
reddit
Web app with JavaScript
Hi! I need some advice. For my portfolio I want to build a web app for my national sports team. A bit like a news website but with some more...
Is it Bad to have gunicorn --reload option enabled in Production?
Is there any downside to having the
/r/flask
https://redd.it/10ek15x
Is there any downside to having the
--reload option enabled for Gunicorn in production? For example, does it require additional memory or CPU or anything? I imagine it must have to poll for changes to files./r/flask
https://redd.it/10ek15x
reddit
Is it Bad to have gunicorn --reload option enabled in Production?
Is there any downside to having the `--reload` option enabled for Gunicorn in production? For example, does it require additional memory or CPU or...
I created some code to test the search functionality for elasticsearch to have a better understanding of the code. I wrote the code quickly so it is crappy code but it mostly runs . The problem is when I run the code and click search nothing appears. I assume it is the html causing the problems.
Can someone help fix the errors?
​
I am following this tutorial https://blog.miguelgrinberg.com/post/the-flask-mega-tutorial-part-xvi-full-text-search
​
​
​
To save time here is my environment.yaml code
name: py
channels:
- defaults
dependencies:
- python
- flask-wtf
- flask-sqlalchemy
- flask-login
- elasticsearch
- flask-migrate
- bcrypt
prefix: C:\Users\user\Anaconda3\envs\py
Also of important note I just want to state that I manually added the Post columns by using the code below in the command line.
​
from app import db, app
from app import User, Posts
with app.appcontext():
post = Post(title='The Second Posts', body='Here is the body text')
​
I also tested to see if the column was added and it seems to be by using the example below.
​
from app import Post
post = Post.query.filterby(body='Here is the body text').first( )
print(post)
print(post.title)
/r/flask
https://redd.it/10d1zgg
Can someone help fix the errors?
​
I am following this tutorial https://blog.miguelgrinberg.com/post/the-flask-mega-tutorial-part-xvi-full-text-search
​
​
​
To save time here is my environment.yaml code
name: py
channels:
- defaults
dependencies:
- python
- flask-wtf
- flask-sqlalchemy
- flask-login
- elasticsearch
- flask-migrate
- bcrypt
prefix: C:\Users\user\Anaconda3\envs\py
Also of important note I just want to state that I manually added the Post columns by using the code below in the command line.
​
from app import db, app
from app import User, Posts
with app.appcontext():
post = Post(title='The Second Posts', body='Here is the body text')
​
I also tested to see if the column was added and it seems to be by using the example below.
​
from app import Post
post = Post.query.filterby(body='Here is the body text').first( )
print(post)
print(post.title)
/r/flask
https://redd.it/10d1zgg
Miguelgrinberg
The Flask Mega-Tutorial, Part XVI: Full-Text Search
This is the sixteenth installment of the Flask Mega-Tutorial series, in which I'm going to add a full-text search capability to Microblog.You are reading the 2024 edition of the Flask Mega-Tutorial…