Learn Flask for Python - Full Tutorial

  Рет қаралды 1,700,643

freeCodeCamp.org

freeCodeCamp.org

4 жыл бұрын

Flask is a micro web framework written in Python. It is classified as a microframework because it does not require particular tools or libraries. Learn how to use it in this crash course tutorial.
💻Code: github.com/jakerieger/FlaskIn...
Tutorial from Jake Rieger. Check out his KZbin channel: / @codingwjake776
--
Learn to code for free and get a developer job: www.freecodecamp.org
Read hundreds of articles on programming: medium.freecodecamp.org

Пікірлер: 1 300
@BrentBrewington
@BrentBrewington 2 жыл бұрын
Love that you walk through completely end to end - from installing prerequisite tools all the way through. Sometimes the initial install/setup stuff is the hardest part
@pavloaleksyeyev5065
@pavloaleksyeyev5065 3 жыл бұрын
virtualenv install for windows 10: open up terminal in VS Code 1)pip install --upgrade virtualenv press enter 2) virtualenv env press enter 3) virtualenv \path\to\env\Scripts\activate press enter For windows 10 you must use 'virtualenv ...' to run commands. Example: 'virtualenv \path\to\env\bin\activate' to activate.
@hassanwehbi6324
@hassanwehbi6324 Жыл бұрын
habibi u saved my life
@karthikpuvvula
@karthikpuvvula Жыл бұрын
thank you !!
@kunalrajput2234
@kunalrajput2234 9 ай бұрын
Thank you odin
@No_name-lq2ww
@No_name-lq2ww 3 ай бұрын
3) For windows 10 just run ' \path\to\env\bin\activate' without virualenv command
@CozyCoupons_
@CozyCoupons_ 3 ай бұрын
after that if you guys encounter any error like this (execution_policies or running scripts is disabled on this system) 1) use this commend: set-Executionpolicy -scope process -Executionpolicy Bypass run the above commend 2) after that use this commend: .\Activate (or) Activate
@N3fario
@N3fario 4 жыл бұрын
I like the pace and the fact that there's no fluff words. Though, this isn't really a 'learn Flask' video, this is a "Type as you follow along as he *kind of* explains what's going on" type video.
@N3fario
@N3fario 4 жыл бұрын
If your table is blank when you first make it, add a border=1 attribute to the table tag so,
@cat47
@cat47 3 жыл бұрын
15 minutes in and he's already showing us how to work with databases. THIS GUY IS AWESOME
@MeetSinojia7
@MeetSinojia7 3 жыл бұрын
Exactly what I needed! Covers complete flask basics for a simple CRUD application (Todo list) in 45 minutes.
@tiaantoinette8047
@tiaantoinette8047 2 жыл бұрын
The voice was instantly comforting - thank you for being my educator on flask in less than an hour!
@danield.7359
@danield.7359 4 жыл бұрын
Great tutorial about a great framework. The video nudged me into the right direction. I just finished a contract management app for our leasing business within less than a week. Thanks!
@CreativGaming
@CreativGaming Жыл бұрын
Hello all. I figured out why this doesn't work. SQL alchemy has been updated since this video Tutorial. The problem is nobody explains it properly, but I will give you a quick fix. Instead of Running the db.create_all() command in the terminal Initialize the Database in your code after your Database Models classes have been setup: with app.app_context(): db.create_all() Basically, put this in your Flask app under the Db.Model classes. Make sure to indent properly and run your flask app one time. It should create the database (also check your instance folder for the db file). Then comment it out. You can run other SQL commands under the with statement if you need info on what's in your database file.
@mohitvashisht9259
@mohitvashisht9259 Жыл бұрын
This is not working for me. Can you share your code please. Thanks!
@CreativGaming
@CreativGaming Жыл бұрын
@@mohitvashisht9259 What error message are you getting?
@mohitvashisht9259
@mohitvashisht9259 Жыл бұрын
The database file is not creating while running the app.py file
@CreativGaming
@CreativGaming Жыл бұрын
@@mohitvashisht9259 Yes, but what error message are you getting in the terminal when you run the app.py file?
@mohitvashisht9259
@mohitvashisht9259 Жыл бұрын
@@CreativGaming No error in itself, it is executing and giving no error but my database file is not created, as shown here.
@razvanc94
@razvanc94 3 жыл бұрын
Really nice tutorial. I'm a software developer who works in embedded systems/automotive and for my work I use C programming language for 99% of tasks and for the rest of tasks I use python. I enjoid this crash course.
@jacobmoore8734
@jacobmoore8734 3 жыл бұрын
Holy cow! This has been a lifesaver. I got about a quarter way through Cory Schafer's flask series and was completely lost. It's a bit hard to tell the essentials apart from stylistic design choices and I just felt like I was struggling to memorize huge chunks of code. This tutorial is way more bare bones; but that's a great advantage it has over other tutorials as I'm really getting the no-nonsense core ideas about flask out of this. Great stuff!
@anyanyanyanya27
@anyanyanyanya27 Жыл бұрын
Same
@LamNguyen-nm1id
@LamNguyen-nm1id Жыл бұрын
Cory Schafer's flask series is something else, you should take your time taking it in. it's just that good
@carlfranz6805
@carlfranz6805 Жыл бұрын
Cory Schafer is pretty good. His downfall is that he talks way to fast and he skips steps. Also, I'm using a 32 inch screen and even then his VSCode display is still sometimes to small to read clearly. He also needs to do more illustrations, especially project structure. In any of these APIs, the project structure is very important to success AND understanding. It doesn't hemp that VSCode's method of displaying directory structure is less then optimal (read as 'stupidly bad'). Try running it at 0.75 speed. I find it helps with many of the tutorials available on KZbin. Also make sure KZbin is sending the highest available video quality. I'm regularly going into the settings and changing it back to 1080p (this really helps reading small print even on a large screen). I sometimes wonder whether having two screens would help doing these tutorials.
@kristerl939
@kristerl939 4 жыл бұрын
Thanks, this was exactly what I needed to get going with flask :)
@MickaelGillot
@MickaelGillot 4 жыл бұрын
Thanks a lot, it was truly enjoyable to follow your tutorial step by step to dive into Flask. Your voice is really nice to hear. Now, I feel like I have all the basics to build my own app. You did a great job.
@arturoroche3782
@arturoroche3782 2 жыл бұрын
08:53 render_template 10:02 template inheritance 12:58 CSS 15:36 SQL Alchemy 20:35 div 22:25 Make a textbox and a button 24:50 Methods
@davinsutanto
@davinsutanto Жыл бұрын
OK
@marmeladovsvid
@marmeladovsvid Жыл бұрын
"20:35 div" HAHAHAHHA bro
@sam031000
@sam031000 3 жыл бұрын
This is a god send! Have a task using Flask and struggled for 2 weeks just to setup the virtual environment, thanks so much :) Liked and subbed!
@DouglasFrota
@DouglasFrota 3 жыл бұрын
Great tutorial, my friend! I have some experience with Django and yesterday I had to to build a simple crud application and Flask fitted well. Keep it up! 😁
@someoneokay5530
@someoneokay5530 3 жыл бұрын
Really good tutorial. I am a beginner in flask and I must say the lecture is really insightful covering all the topics in one go.
@lazyguy597
@lazyguy597 Жыл бұрын
NA..
@user-bm8uc1ei5p
@user-bm8uc1ei5p Жыл бұрын
Wow, it was so easy explained. I believed that the topic is really difficult, but thanks to you, I understood everything. Thank you!
@TechWithTim
@TechWithTim 4 жыл бұрын
Congrats on 1 million subs!
@Crucizer
@Crucizer 4 жыл бұрын
and no one recognized you here?
@jheave
@jheave 3 жыл бұрын
Hi tim
@kromydas5063
@kromydas5063 3 жыл бұрын
hi tim your tutorials are so nice :)⠀⠀⠀⠀⠀⠀ ⣰⣿⣿⣿⣿⢢⣶⣄⡀⁣ ⠀⠀⠀⠀⣀⣐⠻⣿⣿⡿⢣⣿⣿⣿⣿⡆⁣ ⠀⠀⠀⣰⣿⣿⣿⣶⣍⡁⢿⣿⣿⣿⡟⣰⣷⣄⁣ ⠀⠀⣴⣿⣿⣿⣿⣿⣿⣿⣷⡮⣿⢏⣼⣿⣿⣿⣷⁣ ⠀⣼⣿⣿⣿⣿⡟⠿⣿⣿⠟⠁⢋⣾⣿⣿⣿⡟⣱⣦⡀⁣ ⣼⣿⣿⣿⣿⣿⣁⠀⠀⠀⠀⠀⣿⣿⣿⡿⢋⣾⣿⣿⣿⁣ ⠘⣿⣿⣿⣿⣿⣿⣷⣄⠀⠀⠀⠈⠻⠟⣵⣿⣿⣿⢟⠁⁣ ⠀⠈⢿⣿⣿⣿⣿⣿⣿⣷⡀⠀⠀⠀⠈⠻⣿⠟⣡⣿⁣ ⠀⠀⠈⢻⣿⣿⣿⣿⣿⣿⣿⡀⠀⣿⣶⣤⣠⣾⣿⡟⁣ ⠀⠀⠀⠀⠻⣿⣿⣿⣿⣿⣿⣷⢠⣿⣿⣿⣿⣿⡟⁣ ⠀⠀⠀⠀⠀⠹⣿⣿⣿⣿⣿⣿⣾⣿⣿⣿⣿⡿⠁⁣ ⠀⠀⠀⠀⠀⠀⢸⣿⣿⣿⢿⣿⣿⣿⣿⣿⣿⠁⁣ ⠀⠀⠀⠀⠀⠀⣼⣿⣿⣿⣷⡌⢉⣽⣿⣿⡇⁣ ⠀⠀⠀⠀⠀⠀⣿⣿⣿⣿⣿⡇⣸⣿⣿⣿⡇⁣ ⠀⠀⠀⠀⠀ ⣿⣿⣿⣿⣿⣷⣿⣿⣿⣿⡇⁣ ⠀⠀⠀⠀⠀ ⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⡇ (edit) : thx for 2 likes I never got a like before :))))))))
@senthilkumarsundaravinayag9809
@senthilkumarsundaravinayag9809 3 жыл бұрын
Alert everybody The big Tim guy is HERE!!!!
@vikalpjain1098
@vikalpjain1098 3 жыл бұрын
Just subscribed because of Tim
@wahedshuvo
@wahedshuvo 3 жыл бұрын
Finally, I could really learn something on the web! You are an amazing educator!
@jackcardozo
@jackcardozo 3 жыл бұрын
Glad I stumbled on your tutorial. I followed along for a couple of hours. Thanks so much!
@490o
@490o 3 жыл бұрын
I'm just starting Python and I'm already loving this language. This is so much more fun than PHP.
@DominicNweze
@DominicNweze Жыл бұрын
python is the best. 😊😊
@theonlycaulfield
@theonlycaulfield 7 ай бұрын
That's kind-of a low bar. Anything is better than php.
@jasonlee6294
@jasonlee6294 4 жыл бұрын
Awesome, awesome. as an experienced developer, I could learn new stuff with your confident voice. Thank you, Dude
@alexkarav
@alexkarav 3 жыл бұрын
It's a really cool lesson. Every material, like books and video lessons, show how to create a blog, a nothing else. And this video is something special, thank You so much!
@anisbhsl
@anisbhsl 4 жыл бұрын
Went through the full video. Good intro for newcomers! Thank you!
@circuitmasters5258
@circuitmasters5258 4 жыл бұрын
Brother This is what I needed..I got tons applications I am ready to deploy!
@darwishds1459
@darwishds1459 Жыл бұрын
" Error while activating virtual environment in Windows 10 PowerShell " ??? If you are running Windows, then navigate to \Scripts, where is the name of your virtual environment. Then, execute the following command: set-Executionpolicy -Executionpolicy Remotesigned -Scope CurrentUser Type activate and press return. You will now be able to use your virtual environment.
@oferl15
@oferl15 Жыл бұрын
not working from cmd. Open Powershell as Administrator and run the command: it works
@snigdhapeddi8528
@snigdhapeddi8528 Жыл бұрын
@@oferl15 after routing to the above mentioned path type in .\activate in VS code terminal to activate the environment
@alexandermarthius5593
@alexandermarthius5593 3 жыл бұрын
the fastest and easiest way for my first introdutions flask python.. you doing a great jobs jakerieger! Thanks you so much...
@bipulkumar1556
@bipulkumar1556 3 жыл бұрын
This is amazing for a python experienced person, what is wanted to learn only how to quick started with flask.
@Kenobiii
@Kenobiii 4 жыл бұрын
Great tutorial! A lot of densly packed information for a person who is not that familiar with web applications, but I already learned a lot in this tutorial!
@lron1447
@lron1447 3 жыл бұрын
Thank you very much. It was indeed a great course. I was able to overview the connections between Python, Flask, CSS and SQL.
@RobertoTucci
@RobertoTucci 3 жыл бұрын
thanks man, that has been my official introduction to Python and Flask! You rock!
@CTYPCL
@CTYPCL 2 жыл бұрын
this is an incredibly simple and useful tutorial, thank you very, very much
@EdiFerreiranet
@EdiFerreiranet 4 жыл бұрын
Loved when you did open your Chrome and I saw that you are a PIRATE!!! :P
@da_winraja9740
@da_winraja9740 4 жыл бұрын
anyone having problem with the source command remember you just need to put in the location of activate.bat file, usually in the env directory.
@KimiaXLife
@KimiaXLife 2 жыл бұрын
This was an amazing thorough tutorial! THANK YOU!
@sknganga3633
@sknganga3633 3 жыл бұрын
first freecode camp tutorial i have ever finished!
@BRBallin1
@BRBallin1 4 жыл бұрын
By far one of the best frameworks I used built in the most elegant programming language. Building REST APIs has never been easier.
@sfsf285
@sfsf285 3 жыл бұрын
How is it the best by far? If anything its just a little small framework
@juanfolgarcolomer2573
@juanfolgarcolomer2573 3 жыл бұрын
This tutorial is simply genius mate, you not only explain the very basics from a Flask app but the actual deployment to Heroku too. Probably one of best tutorials ever. Respect!
@GerardGRes
@GerardGRes 2 жыл бұрын
Wait, he is setting up an entire database like do this than that than that. I dont call that explaining, feels moren like a demonstration
@lycorislune3846
@lycorislune3846 2 жыл бұрын
@@GerardGRes right? I felt like he could've explained more
@mrcrazyenough007
@mrcrazyenough007 2 жыл бұрын
I have been working on different frameworks from different languages from the past 8 years. When it was PHP, I worked with CodeIgniter, Symfony, Laravel, Yii2 and CakePHP When it was NodeJs, I worked with ExpressJS, KoaJS, SailsJS and NestJS and now I got a new Python project and the requirement was Flask This crash course helped me a lot in kickstarting with Flask in no time, and definitely this crash course is mostly intended for experienced developers only.
@lukeverso
@lukeverso Жыл бұрын
Such a cool tutorial, finally one short and complete!
@bulcub
@bulcub 4 жыл бұрын
This really filled in some missing blanks, especially on how to setup in Visual Studio Code. Thanks
@greensphinx
@greensphinx 3 жыл бұрын
I need this: 15:53 30:45 42:40 Finished :) Good tutorial
@unknownvariant9842
@unknownvariant9842 3 жыл бұрын
Pretty darn good tutorial. It helped a lot. Thanks for taking your time to make this.
@ramankumar41
@ramankumar41 10 ай бұрын
The perfect hands-on intro to flask !!
@mastercode7851
@mastercode7851 4 жыл бұрын
i just love your vscode setup the font and everything is unique
@byeCoDhelloRS
@byeCoDhelloRS 3 жыл бұрын
Hey all, I was having difficulty with my CSS not loading even after I updated it. The solution is to hard refresh because for some reason flask will save your style settings with caching. Try CTRL-Shift-R and hopefully that can solve your issue as well. :-)
@user-qy7dc3oq2i
@user-qy7dc3oq2i 3 жыл бұрын
I guess it's not a Flask issue, but rather your browser is actually doing that caching stuff.
@MeetSinojia7
@MeetSinojia7 3 жыл бұрын
Thanks, I was confused by this behavior. Your comment saved me the time to debug it :)
@civ20
@civ20 3 жыл бұрын
Has nothing to do with Flask, it is your browser that is caching the website files.
@_JoeDigital
@_JoeDigital 3 жыл бұрын
THANK YOU! Great info
@georgigeorgiev271
@georgigeorgiev271 3 жыл бұрын
Thank you a lot!
@ilkerozturk3260
@ilkerozturk3260 2 жыл бұрын
Thanks Jake, it was so useful for me to learn basics of flask 🙏
@LS-cb7lg
@LS-cb7lg 3 жыл бұрын
amazing workflow i dont know how you can be so fast! amazing tutorial too thanks a lot!
@podoliev
@podoliev 4 жыл бұрын
Thanks a lot, this is an amazing tutorial! I highly recommend it to everybody;)
@yashsolanki069
@yashsolanki069 4 жыл бұрын
Congratulations team #freecodecamp on reaching 1 Million milestone !🙌
@mayursawarkar7916
@mayursawarkar7916 4 жыл бұрын
Good example and simple steps that one can follow along. I'm able to create that Task Master. Kudos to you! Thanks!
@juanmachatelet
@juanmachatelet 3 жыл бұрын
This video really helped me to get started with Flask. Thank you!
@sushantdas1349
@sushantdas1349 3 жыл бұрын
Pretty good tutorial, although it can be a little too fast for a beginner with no backend experience. But for switching frameworks, this is really good. :)
@spicymercedes5287
@spicymercedes5287 2 жыл бұрын
agree
@deaththink
@deaththink 2 жыл бұрын
pause or use the .5 speed and or cc. thats what I do.
@catherinemamo6837
@catherinemamo6837 Жыл бұрын
I agree, but otherwise a very good one.
@AudreyGraceB
@AudreyGraceB 4 ай бұрын
As a beginner, it doesn't explain anything...
@circrna
@circrna 2 жыл бұрын
Excellent! 6:04 Install Requirements 6:53 First app 8:55 Static content, introduction 13:00 CSS 15:36 Databases 19:38 Setting up a database (use 'flask shell' at terminal to activate interactive shell if running it from terminal). And run the commands there. 22:19 Adding methods to 'route' in app file 34:00 Delete code is done; Updating code start here.
@rodrigomessias
@rodrigomessias 3 жыл бұрын
Thanks for the explanation about Flask, it helped me a lot to understand several concepts.
@iainlindahl8460
@iainlindahl8460 3 жыл бұрын
That was so helpful, thank you! Got me going in Flask
@albertulysses
@albertulysses 4 жыл бұрын
Thanks for the tutorial, I'm working through the Flask Mega-Tutorial right now as well and your video really helped me understand some of the things I didn't catch on his tutorial. For example, the difference between {{}} and {%%} for Jinja
@quanganhbui9503
@quanganhbui9503 4 жыл бұрын
I'm stupid so I'm still not sure, what's the difference , can you help me, please ?
@albertulysses
@albertulysses 4 жыл бұрын
@@quanganhbui9503 sure what isnt that you don't understand?
@quanganhbui9503
@quanganhbui9503 4 жыл бұрын
Albert Chavez the 2 brackets you mentioned above
@albertulysses
@albertulysses 4 жыл бұрын
@@quanganhbui9503 {%%} are statements for "for, ifs, and loops"and {{}} is to out put something. If you're familiar with python, when you write a for loop you have to write "for x in y: return x" here it's "{% for x in y%} {{ x }} {% endfor%} " of course this isn't a functional language, so it's not exactly used the same way but the concept is similar
@anupthatal5253
@anupthatal5253 4 жыл бұрын
Which flask mega tutorial you are using
@lhayanavieira7723
@lhayanavieira7723 2 жыл бұрын
for those who are having the database creating problem: just delete the "completed = db.Column(db.Integer, default = 0)" line so it's gonna work
@niteshsingh561
@niteshsingh561 9 ай бұрын
Still not working for me
@namegoeshere657
@namegoeshere657 2 жыл бұрын
Amazing tutorial! BEST beginner flask tutorial out there!!
@jannikbade5974
@jannikbade5974 2 жыл бұрын
very nice to show the final result at the beginning of the video! 👍🏼
@issygaming5479
@issygaming5479 4 жыл бұрын
You guys almost reached 1 million subscribers 😎
@OttoFazzl
@OttoFazzl 4 жыл бұрын
1.1 already!
@kokowin5851
@kokowin5851 2 жыл бұрын
If you are not getting a lines to separate rows and columns like he did you can simply add this:
@pawnage3
@pawnage3 2 жыл бұрын
Any idea how he got the lines without adding this? Also, thanks for posting this!
@natashaiggwilv7193
@natashaiggwilv7193 Жыл бұрын
@@pawnage3 different browser probably, others had the same issue only on Chrome and Firefox
@ysq-nomi
@ysq-nomi 3 жыл бұрын
Great video, to the point. Exactly what I was looking for!
@david2beckham691
@david2beckham691 3 ай бұрын
Very simple and excellent tutorial for getting started with Flask
@ayubomaraden867
@ayubomaraden867 4 жыл бұрын
while i was watching this video you reached 1m subs :))
@destinyjames6117
@destinyjames6117 3 жыл бұрын
Tip: On windows dont put activate.bat, just do activate in command prompt. Note that the privacy issue or something does not allow this to be done in VSC in terminal.
@hardikjadwani7715
@hardikjadwani7715 Жыл бұрын
Thanks a lot :)
@jakubunold5750
@jakubunold5750 4 жыл бұрын
Very good tutorial. Helped me a lot and took several days to fully understand :P
@umeshpandey5226
@umeshpandey5226 Жыл бұрын
Incredible simple and precise flask tutorial !!! Hatts of you 💕👨‍🏫📓
@sweetphilly2
@sweetphilly2 3 жыл бұрын
Heads up: if you plan on using conda to perform this tutorial, make sure you're using pip to install these packages; otherwise, you may run into an issue with the packages in requirements.txt pointing to the conda installation of the package. You'll experience a "No such file or directory" error during the push to master.
@franciscobacotich2672
@franciscobacotich2672 8 ай бұрын
og
@atibyte
@atibyte 4 жыл бұрын
I learnt a lot, thank you.
@sivaramanramamoorthy8493
@sivaramanramamoorthy8493 4 жыл бұрын
really
@namratabafna14
@namratabafna14 2 жыл бұрын
Simple and to the point tutorial!
@izzlenizzle
@izzlenizzle 2 жыл бұрын
Simple and eloquent crud app tutorial. Nicely done!
@mdhidayat1117
@mdhidayat1117 2 жыл бұрын
if you have Windows and getting errors while activating a new virtual env, try this ".\env\Scripts\activate " and ".\env\Scripts\activate.bat " instead of "source env/bin/activate".. one of them will work. first one worked for me, latter didn't.
@_s._.unshine
@_s._.unshine Жыл бұрын
YOU ARE MY HERO
@natashaferguson1618
@natashaferguson1618 Жыл бұрын
If you are on Windows, activate your virtual environment with env/Scripts/activate
@NikkiMcMistie
@NikkiMcMistie Жыл бұрын
Love it. Smooth and quick. Good framework
@petera.k.8735
@petera.k.8735 3 жыл бұрын
Great stuff, all I needed to know in less then an hour.
@Omkarh
@Omkarh 4 жыл бұрын
I am stuck on 20:02 when I type "from app import db" in terminal it is showing this "TypeError: Additional arguments should be named _, got 'defult'"
@sylwesteroleszek3143
@sylwesteroleszek3143 3 жыл бұрын
You need to install flask-sqlalchemy. It looks like you have SQLAlchemy installed but not the Flask extension. Try pip install Flask-SQLAlchemy in your project's virtualenv to install it from PyPI.
@goddessleader
@goddessleader 3 жыл бұрын
@@sylwesteroleszek3143 Thank you!
@spaghetti534
@spaghetti534 3 жыл бұрын
@@sylwesteroleszek3143 thanks
@dotterel
@dotterel 3 жыл бұрын
legend, bruv
@StefanosStavropoulos
@StefanosStavropoulos 4 жыл бұрын
Nice tutorial, thank you! I'm getting the error "Instance of 'SQLAlchemy' has no 'Column' member " when I try to add id variable under class Todo(db.Model). SQLAlchemy is imported though. Any ideas?
@darioradic117
@darioradic117 4 жыл бұрын
The following info from StackOverflow resolved the same problem for me: pip install pylint-flask on your project directory find folder .vscode (if you dont have it, just create it) inside settings.json add this line { "python.linting.pylintArgs": [ "--load-plugins", "pylint-flask" ] }
@carlosamaral6917
@carlosamaral6917 3 жыл бұрын
@K Mmm I have the same problem as well. In both Vscode and pycharm
@sakshishetty1310
@sakshishetty1310 3 жыл бұрын
@@darioradic117 I added that but still getting the error
@athegreat88
@athegreat88 3 жыл бұрын
CTRL+SHIFT+P select linter disable linter. Restart VS code that solved my problem.
@tayebshahbakhsh
@tayebshahbakhsh Жыл бұрын
Thank you for this wonderful tutorial.
@noahplant4524
@noahplant4524 Жыл бұрын
This was exactly what I needed very much appreciated
@CdGreven
@CdGreven 3 жыл бұрын
FYI (if anyone encounters the same problem) I was using comment blocks inside html files to take notes but jinja did not like it. Deleting the comment blocks inside html solved them.
@JorgeGarcia-fv3gp
@JorgeGarcia-fv3gp 4 жыл бұрын
That font is beautiful! Whats it called?
@IzzyRock
@IzzyRock 2 жыл бұрын
OMG thank you so much for this video! One of the best and easy to follow tutorials. Appreciate it very much.. thanks again!
@cindinishimoto9528
@cindinishimoto9528 3 жыл бұрын
I'm so happy I just got my first web app using flask!! Thanks, man!
@guillermobarboza5903
@guillermobarboza5903 4 жыл бұрын
Hey, when linking my css to base.html, I href="/static/css/main.css" and it applied my styles! is Jinja necesary?
@johnnylang3657
@johnnylang3657 4 жыл бұрын
yeah, coz your dev env is probably different from the published one once the project is deployed to application server, so there might chances the hard coded css path is not gonna work
@jakubunold5750
@jakubunold5750 4 жыл бұрын
Yeah, I just had problem with it. Once it's hardcoded it seems not to accomodate to changes
@timotheospetros
@timotheospetros 4 жыл бұрын
How do Windows users install Flask and SqlAlchemy to their newly activated environment?? When I follow the instructions here, these packages get installed to my global Python37 folder instead. I wish Python were a little more Windows-friendly :(
@AdalV51
@AdalV51 9 ай бұрын
Great tutorial for Flask introduction, amazing content!
@CaptainInbox
@CaptainInbox 3 жыл бұрын
great video. attractive due to the 1 hour time on it. Did it on windows in VScode, deployment it didn't go to plan every time, a fair bit of googling, took a few goes but got there, then did it again with a conda env, learned a lot. thanks.
@sarathkumar-ie5iu
@sarathkumar-ie5iu 4 жыл бұрын
what does this mean '' % self.id? Why is it enclosed in a tag and what does the percentage mean?
@ARKSYN
@ARKSYN 4 жыл бұрын
All that line does is return a printable representation of the Todo class we created. The percent is Python syntax for string interpolation where '%r' is the placeholder and the '% self.id' is what will replace the '%r'. In this case we're just printing: where id is the id of the Todo object we just created. The brackets are just for formatting they aren't necessary.
@sarathkumar-ie5iu
@sarathkumar-ie5iu 4 жыл бұрын
@@ARKSYN Thank you the brackets confused me
@kelvinomereshone3541
@kelvinomereshone3541 4 жыл бұрын
Percentages are Jinja2 syntax
@Lucaischz
@Lucaischz 3 жыл бұрын
I actually think it would be better to use __str__() other than __repr__() as it's not going to be the exact representation of the class, which should be Todo().
@kken8766
@kken8766 4 жыл бұрын
Hi, thanks for the tutorial. Good that finally someone can explain why we need the virtual env. I have a question. If I already created/established a database in MySQL. do I still have to go through the process of what you did on the class Todo(db.Model) part 17:45 where you build the DB in the python class? If so, is there a better way of doing this because I have 25 tables in my relational DB and each with 10+ attributes.
@avinashchaudhary2374
@avinashchaudhary2374 3 жыл бұрын
No you have to do it in any db
@taruchitgoyal3735
@taruchitgoyal3735 4 жыл бұрын
Amazing course. Allows to learn Python, Flask and build CRUD application.
@xanthe69
@xanthe69 2 жыл бұрын
the best and easiest flask tutorial I have ever seen
@KetanLambat
@KetanLambat 4 жыл бұрын
If the css content is not loading, try refreshing the browser cache
@stefanbaumann7474
@stefanbaumann7474 3 жыл бұрын
THANKS
@corlipr
@corlipr 4 жыл бұрын
Hey Jake, I've been following along in the video, and I haven't been able to see the CSS rules apply, is there anything I am specifically doing wrong?
@ARKSYN
@ARKSYN 4 жыл бұрын
How are you linking your stylesheet? Have you compared your code to the code in the repo for this video?
@arturblachnio6210
@arturblachnio6210 4 жыл бұрын
After changing css file, you need to 'refresh' your browser with ctrl+shift+r. Then you should see the changes.
@aeddwad
@aeddwad 4 жыл бұрын
@@arturblachnio6210 Thank you so much! Do you know what is the difference between ctrl+shift+r and just ctrl+r?
@LIGHTENING110
@LIGHTENING110 4 жыл бұрын
@@aeddwad ctrl+shift+r clears the cache files as well. ctrl+r only reloads the webpage but does not refresh the linked files.
@QuiqueFlowers
@QuiqueFlowers 4 жыл бұрын
The tutorial is very useful, thank you for share it :)
@mgori_media
@mgori_media 4 жыл бұрын
wow. what such clear and very insightful intro to Flask. Keepup
@shervinrad100
@shervinrad100 3 жыл бұрын
I get an error at 20:00 because ImportError: DLL load failed: The specified module could not be found. line 27, in from _sqlite3 import *?
@cosmicvoice7657
@cosmicvoice7657 2 жыл бұрын
good
@spezistyle
@spezistyle 2 жыл бұрын
I'm on Windows and having problem creating that procfile ('Push failed: cannot parse Procfile.'). Any help how to create that empty file?
@MilkJug12
@MilkJug12 3 жыл бұрын
Tip, if you encounter a issue with return_template is undefined, make sure at the top where the from flask import Flask, do from flask import Flask, return_template.
@DerSpielerMabuse
@DerSpielerMabuse 4 жыл бұрын
Fantastic to the point tutorial. Brilliant
REST API Crash Course - Introduction + Full Python API Tutorial
51:57
Python Django Tutorial for Beginners
1:02:36
Programming with Mosh
Рет қаралды 2,3 МЛН
Mac & Cheese Donut @patrickzeinali @ChefRush
00:53
albert_cancook
Рет қаралды 207 МЛН
Flask vs Django in 2024 - Make a RIGHT Choice (Difference Explained)
9:32
Daniel Dan | Tech & Data
Рет қаралды 31 М.
How This Pen Changed The World
9:17
Primal Space
Рет қаралды 257 М.
build a meme Python website (Flask Tutorial for Beginners)
13:30
NetworkChuck
Рет қаралды 434 М.
Create A Python API in 12 Minutes
12:05
Tech With Tim
Рет қаралды 504 М.
Learn To Code Like a GENIUS and Not Waste Time
9:41
The Coding Sloth
Рет қаралды 952 М.
Python Object Oriented Programming (OOP) - For Beginners
53:06
Tech With Tim
Рет қаралды 3,2 МЛН
5 Amazing Ways to Automate Your Life using Python
18:40
Internet Made Coder
Рет қаралды 144 М.
Собеседование Python. Разбор вопросов
2:24:59