Unable to create .db file with flask SQLAlchemy
I am trying to create a .db file where the login and signup details of the user will be stored, but i am unable to. Here is my __init__.py file:
from flask import Flask
from flasksqlalchemy import SQLAlchemy
from flasklogin import LoginManager
from app.models import DBNAME
from app.models import User, ElderlyUser, Volunteer
db = SQLAlchemy()
loginmanager = LoginManager()
loginmanager.loginview = 'main.login'
def createapp():
app = Flask(name)
app.config['SECRETKEY'] = 'secretkey'
app.config['SQLALCHEMYDATABASEURI'] = f'sqlite:///{DBNAME}'
db.initapp(app)
loginmanager.initapp(app)
from app.routes import main
app.registerblueprint(main)
return app
@loginmanager.userloader
/r/flask
https://redd.it/1e9gmg8
I am trying to create a .db file where the login and signup details of the user will be stored, but i am unable to. Here is my __init__.py file:
from flask import Flask
from flasksqlalchemy import SQLAlchemy
from flasklogin import LoginManager
from app.models import DBNAME
from app.models import User, ElderlyUser, Volunteer
db = SQLAlchemy()
loginmanager = LoginManager()
loginmanager.loginview = 'main.login'
def createapp():
app = Flask(name)
app.config['SECRETKEY'] = 'secretkey'
app.config['SQLALCHEMYDATABASEURI'] = f'sqlite:///{DBNAME}'
db.initapp(app)
loginmanager.initapp(app)
from app.routes import main
app.registerblueprint(main)
return app
@loginmanager.userloader
/r/flask
https://redd.it/1e9gmg8
Reddit
Unable to create .db file with flask SQLAlchemy : r/flask
86K subscribers in the flask community. Flask is a Python micro-framework for web development. Flask is easy to get started with and a great way to…
CSRF not being sent when in Xframe
My application runs smoothly when working through my own url, including logging in and other form activities. However, when x-frame’d in another site, I run into csrf verification issues and get the 403 forbidden when sending forms. In the dev tools, I can see that no request cookies are being sent, however, my csrf token and 4 other cookies are included in the ‘filtered out request cookies’ section of the cookies tab, so it appears for some reason they just aren't being passed. I have the below values set in my settings. Note that I have tried setting my cookie secure settings to False just to see if procore’s x-frame was maybe operating in a non-HTTPS manner, however, that did nothing to change the issue.
I have done the following to try and fix this: 1) changed the CSRF_COOKIE_SECURE, SESSION_COOKIE_SECURE, CSRF_COOKIE_SAMESITE, and SESSION_COOKIE_SAMESITE to their least secure settings 2) Updated my CSRF_TRUSTED_ORIGINS 3) Double checked all CSRF/security and middleware (I have all the default) 4) added the url to my ALLOWED_HOSTS 5) added custom CSP where I added the host url to my frame-src and frame-ancestors. 6) Remove the X_FRAME_OPTIONS = 'SAMEORIGIN'
None of these seem to be working and I am
/r/djangolearning
https://redd.it/1e9m3w2
My application runs smoothly when working through my own url, including logging in and other form activities. However, when x-frame’d in another site, I run into csrf verification issues and get the 403 forbidden when sending forms. In the dev tools, I can see that no request cookies are being sent, however, my csrf token and 4 other cookies are included in the ‘filtered out request cookies’ section of the cookies tab, so it appears for some reason they just aren't being passed. I have the below values set in my settings. Note that I have tried setting my cookie secure settings to False just to see if procore’s x-frame was maybe operating in a non-HTTPS manner, however, that did nothing to change the issue.
I have done the following to try and fix this: 1) changed the CSRF_COOKIE_SECURE, SESSION_COOKIE_SECURE, CSRF_COOKIE_SAMESITE, and SESSION_COOKIE_SAMESITE to their least secure settings 2) Updated my CSRF_TRUSTED_ORIGINS 3) Double checked all CSRF/security and middleware (I have all the default) 4) added the url to my ALLOWED_HOSTS 5) added custom CSP where I added the host url to my frame-src and frame-ancestors. 6) Remove the X_FRAME_OPTIONS = 'SAMEORIGIN'
None of these seem to be working and I am
/r/djangolearning
https://redd.it/1e9m3w2
Reddit
From the djangolearning community on Reddit
Explore this post and more from the djangolearning community
Need to print a page out
Hi all I want to be able to press a button on the webpage and print the page. I've got it setup so it looks good when I ctrl p, but I can't figure out how to make a button that brings the print page up
/r/flask
https://redd.it/1e9oedb
Hi all I want to be able to press a button on the webpage and print the page. I've got it setup so it looks good when I ctrl p, but I can't figure out how to make a button that brings the print page up
/r/flask
https://redd.it/1e9oedb
Reddit
From the flask community on Reddit
Explore this post and more from the flask community
What skills do you need to become a Junior Developer today?
I'm primarily interested in skills related to data, but I'm open to other areas as well. It seems like the requirements for landing a junior developer position are constantly evolving. Could you provide insights into the minimal skill sets needed to secure that first job?
/r/Python
https://redd.it/1e9mr91
I'm primarily interested in skills related to data, but I'm open to other areas as well. It seems like the requirements for landing a junior developer position are constantly evolving. Could you provide insights into the minimal skill sets needed to secure that first job?
/r/Python
https://redd.it/1e9mr91
Reddit
From the Python community on Reddit
Explore this post and more from the Python community
How can I render dynamic graphs with nodes and edges in my website?
I have a database with nodes and edges. I want users to be able to view the graph, add new nodes and edges and inspect the graph by holding and dragging (just like in the graphic design softwares). I couldn't find a way online to achieve this. Is there a framework or library I can use to achieve this?
/r/djangolearning
https://redd.it/1e8iqy6
I have a database with nodes and edges. I want users to be able to view the graph, add new nodes and edges and inspect the graph by holding and dragging (just like in the graphic design softwares). I couldn't find a way online to achieve this. Is there a framework or library I can use to achieve this?
/r/djangolearning
https://redd.it/1e8iqy6
Reddit
From the djangolearning community on Reddit
Explore this post and more from the djangolearning community
D Self-Promotion Thread
Please post your personal projects, startups, product placements, collaboration needs, blogs etc.
Please mention the payment and pricing requirements for products and services.
Please do not post link shorteners, link aggregator websites , or auto-subscribe links.
--
Any abuse of trust will lead to bans.
Encourage others who create new posts for questions to post here instead!
Thread will stay alive until next one so keep posting after the date in the title.
--
Meta: This is an experiment. If the community doesnt like this, we will cancel it. This is to encourage those in the community to promote their work by not spamming the main threads.
/r/MachineLearning
https://redd.it/1e8btox
Please post your personal projects, startups, product placements, collaboration needs, blogs etc.
Please mention the payment and pricing requirements for products and services.
Please do not post link shorteners, link aggregator websites , or auto-subscribe links.
--
Any abuse of trust will lead to bans.
Encourage others who create new posts for questions to post here instead!
Thread will stay alive until next one so keep posting after the date in the title.
--
Meta: This is an experiment. If the community doesnt like this, we will cancel it. This is to encourage those in the community to promote their work by not spamming the main threads.
/r/MachineLearning
https://redd.it/1e8btox
Reddit
From the MachineLearning community on Reddit
Explore this post and more from the MachineLearning community
How does everyone plan and structure their apps?
I’m new to Django, been looking over different tutorials. For a more complex app, how does everyone plan and map out their app? With django using MVT, is there an easy way to build something usable fast when dealing with more complex apps? How do you polish the UI? Thanks!
/r/django
https://redd.it/1e9tdma
I’m new to Django, been looking over different tutorials. For a more complex app, how does everyone plan and map out their app? With django using MVT, is there an easy way to build something usable fast when dealing with more complex apps? How do you polish the UI? Thanks!
/r/django
https://redd.it/1e9tdma
Reddit
From the django community on Reddit
Explore this post and more from the django community
TypeError: Object of type Decimal is not JSON serializable even though the serialized data don't have Decimal type; Sessions are not updatedI have a cart that is integrated with the user's session. In my `APIView`, I made a function that would return a serialized data of my cart items. So other than my `GET` request, my `POST` and `DELETE` requests would also use the said function for my response.
It works if I try to send `GET` request. But I would get a `TypeError: Object of type Decimal is not JSON serializable` for my `POST` and `DELETE` requests. I also noticed that that my items in my session are not being updated. HOWEVER, if I try not to use the said function (the one that returns serialized data), everything works just fine. Can you guys help me understand what's causing this error?
class CartView(APIView):
def getcartdata(self, request):
cart = Cart(request)
cartdata = {
"items": [item for item in cart],
"totalprice":
/r/django
https://redd.it/1ea3vh4
Reddit
From the django community on Reddit
Explore this post and more from the django community
Tuesday Daily Thread: Advanced questions
# Weekly Wednesday Thread: Advanced Questions 🐍
Dive deep into Python with our Advanced Questions thread! This space is reserved for questions about more advanced Python topics, frameworks, and best practices.
## How it Works:
1. **Ask Away**: Post your advanced Python questions here.
2. **Expert Insights**: Get answers from experienced developers.
3. **Resource Pool**: Share or discover tutorials, articles, and tips.
## Guidelines:
* This thread is for **advanced questions only**. Beginner questions are welcome in our [Daily Beginner Thread](#daily-beginner-thread-link) every Thursday.
* Questions that are not advanced may be removed and redirected to the appropriate thread.
## Recommended Resources:
* If you don't receive a response, consider exploring r/LearnPython or join the [Python Discord Server](https://discord.gg/python) for quicker assistance.
## Example Questions:
1. **How can you implement a custom memory allocator in Python?**
2. **What are the best practices for optimizing Cython code for heavy numerical computations?**
3. **How do you set up a multi-threaded architecture using Python's Global Interpreter Lock (GIL)?**
4. **Can you explain the intricacies of metaclasses and how they influence object-oriented design in Python?**
5. **How would you go about implementing a distributed task queue using Celery and RabbitMQ?**
6. **What are some advanced use-cases for Python's decorators?**
7. **How can you achieve real-time data streaming in Python with WebSockets?**
8. **What are the
/r/Python
https://redd.it/1e9tk2t
# Weekly Wednesday Thread: Advanced Questions 🐍
Dive deep into Python with our Advanced Questions thread! This space is reserved for questions about more advanced Python topics, frameworks, and best practices.
## How it Works:
1. **Ask Away**: Post your advanced Python questions here.
2. **Expert Insights**: Get answers from experienced developers.
3. **Resource Pool**: Share or discover tutorials, articles, and tips.
## Guidelines:
* This thread is for **advanced questions only**. Beginner questions are welcome in our [Daily Beginner Thread](#daily-beginner-thread-link) every Thursday.
* Questions that are not advanced may be removed and redirected to the appropriate thread.
## Recommended Resources:
* If you don't receive a response, consider exploring r/LearnPython or join the [Python Discord Server](https://discord.gg/python) for quicker assistance.
## Example Questions:
1. **How can you implement a custom memory allocator in Python?**
2. **What are the best practices for optimizing Cython code for heavy numerical computations?**
3. **How do you set up a multi-threaded architecture using Python's Global Interpreter Lock (GIL)?**
4. **Can you explain the intricacies of metaclasses and how they influence object-oriented design in Python?**
5. **How would you go about implementing a distributed task queue using Celery and RabbitMQ?**
6. **What are some advanced use-cases for Python's decorators?**
7. **How can you achieve real-time data streaming in Python with WebSockets?**
8. **What are the
/r/Python
https://redd.it/1e9tk2t
Discord
Join the Python Discord Server!
We're a large community focused around the Python programming language. We believe that anyone can learn to code. | 412982 members
Taught 100+ aspiring Data Scientists Python, now I'm doing it again for FREE
Hey everyone,
I’m launching a FREE Bootcamp to teach "Python for Data Science". If you’re feeling lost or simply curious about Data Science, this boot camp is designed for you. Interested?
Why am I doing this?
I believe in structured, practical learning. My experiences taught me that having a mentor is crucial who can mak the learning process more engaging and effective. Having managed without a mentor myself, lectures often felt boring, and understanding Data Science from slides alone was challenging. Additionally, I found that affordable and practical options online was severely lacking. Most tutoring options were expensive and didn't provide the hands-on experience I needed. Code Kaisen is my way of giving to students (like me) and to assist you to gain practical experience and avoid the scattered, confusing path I took.
Why Study with Me?
I've been teaching Data Science for the past 2 years. Within six months, I was awarded a super tutor badge on an online platform that I started teaching on. I have taught over 1,500 lessons and contributed to over 500 successful student projects, assignments, and theses. I have completed no less than 10 courses related to Data Science.
My success with teaching motivated me to aid more
/r/Python
https://redd.it/1ea7421
Hey everyone,
I’m launching a FREE Bootcamp to teach "Python for Data Science". If you’re feeling lost or simply curious about Data Science, this boot camp is designed for you. Interested?
Why am I doing this?
I believe in structured, practical learning. My experiences taught me that having a mentor is crucial who can mak the learning process more engaging and effective. Having managed without a mentor myself, lectures often felt boring, and understanding Data Science from slides alone was challenging. Additionally, I found that affordable and practical options online was severely lacking. Most tutoring options were expensive and didn't provide the hands-on experience I needed. Code Kaisen is my way of giving to students (like me) and to assist you to gain practical experience and avoid the scattered, confusing path I took.
Why Study with Me?
I've been teaching Data Science for the past 2 years. Within six months, I was awarded a super tutor badge on an online platform that I started teaching on. I have taught over 1,500 lessons and contributed to over 500 successful student projects, assignments, and theses. I have completed no less than 10 courses related to Data Science.
My success with teaching motivated me to aid more
/r/Python
https://redd.it/1ea7421
Google Docs
[FREE] Python for Data Science BootCamp
Join us for an immersive journey into the world of Python programming tailored specifically for aspiring data scientists. Over the course of one month, you'll dive deep into Python's powerful capabilities, learning essential skills and techniques crucial…
Pydfy: PDF Reporting Made Easy
# What Our Project Does
Python provides many great tools to collect, transform and visualize data. However, we've found no fitting solution for our use case: creating PDF reports from your data. Working at a data agency, several of our clients wanted to distribute daily, weekly or monthly PDF reports with the latest numbers to employees or customers. In essence, they wanted screenshots of the BI dashboard with more context. Unfortunately, the packages out there either provided too much flexibility or too little, so we ended up building our own solution.
This turned into Pydfy: a package that makes it easy to create PDFs that are "Good enough", while providing several extension possibilities to fine-tune them using custom HTML and CSS. We built in support for popular packages such as
Github Repository: [https://github.com/BiteStreams/pydfy](https://github.com/BiteStreams/pydfy)
Examples at: https://github.com/BiteStreams/pydfy/tree/main/examples
# Target Audience
Data practitioners familiar with Python that want to bundle their analysis into a readable document, but also data engineers that have to bulk create PDF reports periodically for clients, internal stakeholders, or weekly emails.
The setup for the package has been used in production environments (though these were often not mission-critical). We just built the first versions and at this
/r/Python
https://redd.it/1ea1tqd
# What Our Project Does
Python provides many great tools to collect, transform and visualize data. However, we've found no fitting solution for our use case: creating PDF reports from your data. Working at a data agency, several of our clients wanted to distribute daily, weekly or monthly PDF reports with the latest numbers to employees or customers. In essence, they wanted screenshots of the BI dashboard with more context. Unfortunately, the packages out there either provided too much flexibility or too little, so we ended up building our own solution.
This turned into Pydfy: a package that makes it easy to create PDFs that are "Good enough", while providing several extension possibilities to fine-tune them using custom HTML and CSS. We built in support for popular packages such as
pandas, matplotlib and polars where relevant.Github Repository: [https://github.com/BiteStreams/pydfy](https://github.com/BiteStreams/pydfy)
Examples at: https://github.com/BiteStreams/pydfy/tree/main/examples
# Target Audience
Data practitioners familiar with Python that want to bundle their analysis into a readable document, but also data engineers that have to bulk create PDF reports periodically for clients, internal stakeholders, or weekly emails.
The setup for the package has been used in production environments (though these were often not mission-critical). We just built the first versions and at this
/r/Python
https://redd.it/1ea1tqd
GitHub
GitHub - BiteStreams/pydfy: Turn DataFrames Into PDF Reports
Turn DataFrames Into PDF Reports. Contribute to BiteStreams/pydfy development by creating an account on GitHub.
[N] Llama 3.1 405B launches
https://llama.meta.com/
* Comparable to GPT-4o and Claude 3.5 Sonnet, according to the benchmarks
* The weights are publicly available
* 128K context
/r/MachineLearning
https://redd.it/1eaaq05
https://llama.meta.com/
* Comparable to GPT-4o and Claude 3.5 Sonnet, according to the benchmarks
* The weights are publicly available
* 128K context
/r/MachineLearning
https://redd.it/1eaaq05
Industry Leading, Open-Source AI | Llama
Discover Llama 4's class-leading AI models, Scout and Maverick. Experience top performance, multimodality, low costs, and unparalleled efficiency.
`itertools` combinatorial iterators explained with ice-cream
I just figured I could use ice cream to explain the 4 combinatorial iterators from the module `itertools`:
1. `combinations`
2. `combinations_with_replacement`
3. `permutations`
4. `product`
I think this is a good idea because it is quite clear.
Let me know your thoughts:
### `combinations(iterable, r)`
This iterator will produce tuples of length `r` with all the unique combinations of values from `iterable`.
(“Unique” will make use of the original position in `iterable`, and not the value itself.)
E.g., what ice cream flavour combinations can I get?
```py
# Possible flavours for 2-scoop ice creams (no repetition)
from itertools import combinations
flavours = ["chocolate", "vanilla", "strawberry"]
for scoops in combinations(flavours, 2):
print(scoops)
"""Output:
('chocolate', 'vanilla')
('chocolate', 'strawberry')
('vanilla', 'strawberry')
"""
```
### `combinations_with_replacement(iterable, r)`
Same as `combinations`, but values can be repeated.
E.g., what ice cream flavour combinations can I get if I allow myself to repeat flavours?
```py
# Possible flavours for 2-scoop ice creams (repetition allowed)
from itertools import combinations_with_replacement
flavours = ["chocolate", "vanilla", "strawberry"]
for scoops in combinations_with_replacement(flavours, 2):
print(scoops)
"""Output:
('chocolate', 'chocolate')
('chocolate', 'vanilla')
('chocolate', 'strawberry')
('vanilla', 'vanilla')
('vanilla', 'strawberry')
('strawberry', 'strawberry')
"""
```
### `permutations(iterable, r)`
All possible combinations of size `r` in all their possible orderings.
E.g., if I get 2 scoops, how can they be served?
This is a very important question because the flavour at the bottom is eaten last!
```py
# Order in which the
/r/Python
https://redd.it/1eaarah
I just figured I could use ice cream to explain the 4 combinatorial iterators from the module `itertools`:
1. `combinations`
2. `combinations_with_replacement`
3. `permutations`
4. `product`
I think this is a good idea because it is quite clear.
Let me know your thoughts:
### `combinations(iterable, r)`
This iterator will produce tuples of length `r` with all the unique combinations of values from `iterable`.
(“Unique” will make use of the original position in `iterable`, and not the value itself.)
E.g., what ice cream flavour combinations can I get?
```py
# Possible flavours for 2-scoop ice creams (no repetition)
from itertools import combinations
flavours = ["chocolate", "vanilla", "strawberry"]
for scoops in combinations(flavours, 2):
print(scoops)
"""Output:
('chocolate', 'vanilla')
('chocolate', 'strawberry')
('vanilla', 'strawberry')
"""
```
### `combinations_with_replacement(iterable, r)`
Same as `combinations`, but values can be repeated.
E.g., what ice cream flavour combinations can I get if I allow myself to repeat flavours?
```py
# Possible flavours for 2-scoop ice creams (repetition allowed)
from itertools import combinations_with_replacement
flavours = ["chocolate", "vanilla", "strawberry"]
for scoops in combinations_with_replacement(flavours, 2):
print(scoops)
"""Output:
('chocolate', 'chocolate')
('chocolate', 'vanilla')
('chocolate', 'strawberry')
('vanilla', 'vanilla')
('vanilla', 'strawberry')
('strawberry', 'strawberry')
"""
```
### `permutations(iterable, r)`
All possible combinations of size `r` in all their possible orderings.
E.g., if I get 2 scoops, how can they be served?
This is a very important question because the flavour at the bottom is eaten last!
```py
# Order in which the
/r/Python
https://redd.it/1eaarah
Reddit
From the Python community on Reddit: `itertools` combinatorial iterators explained with ice-cream
Explore this post and more from the Python community
Anyone here created a full project that is live and generating revenue only with Flask HTML, without a frontend framework like React? Could you show us your project, please?
Hi everyone,
I'm curious if anyone here has successfully built and deployed a full project using only Flask and HTML templates, without relying on frontend frameworks like React, Angular, or Vue. I'm particularly interested in seeing examples of projects that are currently live and generating revenue.
If you've done this, could you share your project with us? I'm interested in understanding your approach and any tips you might have for someone considering a similar path.
Thanks in advance!
/r/flask
https://redd.it/1ea9ttn
Hi everyone,
I'm curious if anyone here has successfully built and deployed a full project using only Flask and HTML templates, without relying on frontend frameworks like React, Angular, or Vue. I'm particularly interested in seeing examples of projects that are currently live and generating revenue.
If you've done this, could you share your project with us? I'm interested in understanding your approach and any tips you might have for someone considering a similar path.
Thanks in advance!
/r/flask
https://redd.it/1ea9ttn
Reddit
From the flask community on Reddit
Explore this post and more from the flask community
Looking for django developer to join remote team. LLM startup
Hi all,
We're a team working on a startup utilizing LLM's (primarily Anthropic and OpenAI) to automate business processes in different domains where compliance is mandatory.
We're looking for a Django developer to join us, help finish MVP, launch and grow the application.
What we are looking for:
Proven Django/Python experience
You've lived with a live app in production for a long time
Celery experience
Ability to write clean, readable and simple code
You resort to pragmatic solutions
You cover your code with tests
You know principles of good software design
Nice to have:
LLM experience
General ML experience
Some React experience
AWS solution architecture
What we offer:
Fully remote job in your timezone
Flexible working hours
Ability to contribute to product design
If you think we're a good fit please message me with your CV and salary expectations.
Thank you
/r/django
https://redd.it/1eahsbw
Hi all,
We're a team working on a startup utilizing LLM's (primarily Anthropic and OpenAI) to automate business processes in different domains where compliance is mandatory.
We're looking for a Django developer to join us, help finish MVP, launch and grow the application.
What we are looking for:
Proven Django/Python experience
You've lived with a live app in production for a long time
Celery experience
Ability to write clean, readable and simple code
You resort to pragmatic solutions
You cover your code with tests
You know principles of good software design
Nice to have:
LLM experience
General ML experience
Some React experience
AWS solution architecture
What we offer:
Fully remote job in your timezone
Flexible working hours
Ability to contribute to product design
If you think we're a good fit please message me with your CV and salary expectations.
Thank you
/r/django
https://redd.it/1eahsbw
Reddit
From the django community on Reddit
Explore this post and more from the django community
Store Product Management, SPM (My project in python)
Im 15 years old and I made a project that could be used in stores to put barcodes on products and scan them. This is one of my project that im the most proud of (I dont even know why lol) but I wanted to share it here to see if you guys could recommend me few improvements on this project and if you have other projects ideas.
Thanks in advance and here is the link to the github project: https://github.com/TuturGabao/Store-Product-Management-SPM
/r/Python
https://redd.it/1eae015
Im 15 years old and I made a project that could be used in stores to put barcodes on products and scan them. This is one of my project that im the most proud of (I dont even know why lol) but I wanted to share it here to see if you guys could recommend me few improvements on this project and if you have other projects ideas.
Thanks in advance and here is the link to the github project: https://github.com/TuturGabao/Store-Product-Management-SPM
/r/Python
https://redd.it/1eae015
GitHub
GitHub - TuturGabao/Store-Product-Management-SPM: I wanted to create a Qr code generator but i've realised it was way too easy…
I wanted to create a Qr code generator but i've realised it was way too easy, so i made a program that could work for store management: referencing products by giving them attributes like t...
Django + HTMX
I guess that this is truly all you need for web development.
Django + HTMX + Bootstrap
https://insightfol.io/
I particularly love how easy it is to translate it all.
https://insightfol.io/de
What am I missing? as an amateur developer, why would I try to learn JS?
/r/django
https://redd.it/1ea50m5
I guess that this is truly all you need for web development.
Django + HTMX + Bootstrap
https://insightfol.io/
I particularly love how easy it is to translate it all.
https://insightfol.io/de
What am I missing? as an amateur developer, why would I try to learn JS?
/r/django
https://redd.it/1ea50m5
insightfol.io
Insightfolio
Your portfolio, finally explained: Clear insights on risk, exposure, and diversification — everything your broker app doesn’t show you.
Developing GraphQL APIs in Django with Strawberry
https://testdriven.io/blog/django-strawberry/
/r/django
https://redd.it/1eaiizh
https://testdriven.io/blog/django-strawberry/
/r/django
https://redd.it/1eaiizh
testdriven.io
Developing GraphQL APIs in Django with Strawberry
This tutorial details how to integrate GraphQL with Django using Strawberry.
Unsupported method POST
I made a code in a flask that receives pdf files and is sent, but every time it is sent, an "Unsupported method POST" message appears, this only happens on the hostiger vps server, on my local vscode it works correctly
My HTML:
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Upload PDF</title>
</head>
<body>
<h1>Upload PDF</h1>
<form action="/" method="post" enctype="multipart/form-data">
<input type="file" name="file" accept="application/pdf">
<input type="submit" value="Upload">
</form>
</body>
</html>
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Upload PDF</title>
</head>
<body>
<h1>Upload PDF</h1>
<form action="/" method="post" enctype="multipart/form-data">
/r/flask
https://redd.it/1eaoqc4
I made a code in a flask that receives pdf files and is sent, but every time it is sent, an "Unsupported method POST" message appears, this only happens on the hostiger vps server, on my local vscode it works correctly
My HTML:
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Upload PDF</title>
</head>
<body>
<h1>Upload PDF</h1>
<form action="/" method="post" enctype="multipart/form-data">
<input type="file" name="file" accept="application/pdf">
<input type="submit" value="Upload">
</form>
</body>
</html>
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Upload PDF</title>
</head>
<body>
<h1>Upload PDF</h1>
<form action="/" method="post" enctype="multipart/form-data">
/r/flask
https://redd.it/1eaoqc4
Wednesday Daily Thread: Beginner questions
# Weekly Thread: Beginner Questions 🐍
Welcome to our Beginner Questions thread! Whether you're new to Python or just looking to clarify some basics, this is the thread for you.
## How it Works:
1. Ask Anything: Feel free to ask any Python-related question. There are no bad questions here!
2. Community Support: Get answers and advice from the community.
3. Resource Sharing: Discover tutorials, articles, and beginner-friendly resources.
## Guidelines:
This thread is specifically for beginner questions. For more advanced queries, check out our [Advanced Questions Thread](#advanced-questions-thread-link).
## Recommended Resources:
If you don't receive a response, consider exploring r/LearnPython or join the Python Discord Server for quicker assistance.
## Example Questions:
1. What is the difference between a list and a tuple?
2. How do I read a CSV file in Python?
3. What are Python decorators and how do I use them?
4. How do I install a Python package using pip?
5. What is a virtual environment and why should I use one?
Let's help each other learn Python! 🌟
/r/Python
https://redd.it/1ean7a2
# Weekly Thread: Beginner Questions 🐍
Welcome to our Beginner Questions thread! Whether you're new to Python or just looking to clarify some basics, this is the thread for you.
## How it Works:
1. Ask Anything: Feel free to ask any Python-related question. There are no bad questions here!
2. Community Support: Get answers and advice from the community.
3. Resource Sharing: Discover tutorials, articles, and beginner-friendly resources.
## Guidelines:
This thread is specifically for beginner questions. For more advanced queries, check out our [Advanced Questions Thread](#advanced-questions-thread-link).
## Recommended Resources:
If you don't receive a response, consider exploring r/LearnPython or join the Python Discord Server for quicker assistance.
## Example Questions:
1. What is the difference between a list and a tuple?
2. How do I read a CSV file in Python?
3. What are Python decorators and how do I use them?
4. How do I install a Python package using pip?
5. What is a virtual environment and why should I use one?
Let's help each other learn Python! 🌟
/r/Python
https://redd.it/1ean7a2
Discord
Join the Python Discord Server!
We're a large community focused around the Python programming language. We believe that anyone can learn to code. | 412982 members