5 Debugging Tips Every Developer Should Know | Build a Startup #7

Поделиться
HTML-код
  • Опубликовано: 22 окт 2024

Комментарии • 357

  • @CSDojo
    @CSDojo  5 лет назад +100

    Hey guys, I recommend 1.25x or 1.5x speed if you want to get through the video quickly.
    Also, here’s the source code I used today: github.com/ykdojo/editdojo

    • @ratansingh2248
      @ratansingh2248 5 лет назад +3

      Love u sir

    • @veipuniilana1842
      @veipuniilana1842 5 лет назад +2

      How much seconds do take to solve Rubik cube

    • @CSDojo
      @CSDojo  5 лет назад +3

      haha I haven't solved it in a while, so no idea

    • @ropro9817
      @ropro9817 5 лет назад

      But if you succeeded to reproduce the issue locally, why not just run it through a debugger instead of the hassle of littering the code with print statements?

    • @CSDojo
      @CSDojo  5 лет назад +3

      Hmm I think that's what I would've done if I was more comfortable with pdb. Since I wasn't that used to using it, I just went with printing this time - which took less learning up front.

  • @iRapplexD
    @iRapplexD 5 лет назад +185

    1. Come up with hypothesis and test it. Repeat.
    2. Reproduce the problem locally.
    3. Read the source code carefully.
    4. Read print statement effectively.
    5 Read a debugger effectively.

    • @bharatbommena3459
      @bharatbommena3459 5 лет назад +4

      Thanks! , I was about to rewatch the video to make notes.

    • @ditsokar4168
      @ditsokar4168 4 года назад +13

      6 flip out and call the computer stupid

    • @zabiullahs.z9867
      @zabiullahs.z9867 3 года назад +2

      @@ditsokar4168 Yoooo wtf I do that all the time 😅😅🤣🤣

    • @viewerguy10
      @viewerguy10 2 года назад

      Thanks for the recap

  • @ALEXEIS
    @ALEXEIS 5 лет назад +281

    The silliest bugs are usually the most frustrating.

    • @ALEXEIS
      @ALEXEIS 5 лет назад +4

      ai4k
      A native English speaker understands my statement.

    • @ALEXEIS
      @ALEXEIS 5 лет назад +2

      ai4k
      Ok 👍

    • @Lucy-dk5cz
      @Lucy-dk5cz 5 лет назад

      Same as farts

    • @zerosandones7547
      @zerosandones7547 4 года назад +5

      The ones that can make you go "this is the correct code, why is it not working?" type of bugs

    • @jkf16m96
      @jkf16m96 3 года назад +1

      @@zerosandones7547 oh boy, that feels frustrating.

  • @FaizanAnwerAli
    @FaizanAnwerAli 5 лет назад +26

    Similar techniques were taught to me by my senior developer for php. Instead of importing and checking in command line you can use print_r or var_dump in php to print out every single thing a variable holds.

  • @joaovfeijo
    @joaovfeijo 5 лет назад +181

    kkkkkkkkkkkkkkk 90% of the problems a programmer faces are of this type. It was just hilarious when you said "ah.. turns out it was just a typo" xDDDDD

    • @xCaleb
      @xCaleb 5 лет назад +7

      João Victor Feijó We need Grammarly for programming

    • @mamirazmi
      @mamirazmi 5 лет назад +1

      @@xCaleb create one.

    • @starlord9220
      @starlord9220 5 лет назад

      :)

  • @lngwnd1
    @lngwnd1 5 лет назад +11

    This was a very valuable video! I literally said "when debugging use print statements effectively" in an interview a got the job lol... Thanks for sharing!

  • @adarshchaudhary5362
    @adarshchaudhary5362 5 лет назад +32

    Easiest way is
    to copy the error
    Paste it in google
    Open most similar stackoverflow links.
    Boom done!

    • @saifallauddin
      @saifallauddin 5 лет назад +5

      This is for the people who answer at stackoverflow :p

    • @adarshchaudhary5362
      @adarshchaudhary5362 4 года назад

      @MANISH SHARMA bhai jo bhi errors aati hain unhe bugs kehte hain. Errors/bugs ke removal wali process ko debugging

    • @adarshchaudhary5362
      @adarshchaudhary5362 4 года назад

      @MANISH SHARMA hn bhai.

  • @lin-zchang4774
    @lin-zchang4774 5 лет назад +3

    This is great! I would also say, you can get some insight from the Http Status Codes you received from printing your response variable. I think you had 403 and 401 show up, if you Google those codes I believe 403 (from your local environment) means access was forbidden, and 401 (from the server) means unauthorized. It can help you identity what's going wrong sometimes if you check out what code you're getting :)

  • @Chaosman88
    @Chaosman88 5 лет назад +110

    I have a very hard time reading other people's codes in Python. Could you make a video of you reading a brand new python code that you haven't seen before? And while you read it, you would say out loud how you think, and understand it. Would be very useful for me ! :)
    Do you use the debugger to understand the code? If so, that you could include that too in the code reading tutorial vid :) Or any other tool that is helpful for the purpose.

    • @kwii22789
      @kwii22789 5 лет назад +8

      That just comes from experience and seeing a lot of code. You will get it. Python language was created with readability as one of the main focuses so it shouldn't be a too much of an issue.

    • @Chaosman88
      @Chaosman88 5 лет назад +4

      @@kwii22789 yeah, Python is even easier to understand than other languages, yet I still struggle reading, and understanding others code.
      When I need to implement a feature from zero, its not a big deal for me. But when I need to add a feature to an existing project, that someone else wrote, and its quite large already, thats a problem.. I dont even know where to start, and what to modify. So a code reading tutorial would be very nice!

    • @MinecraftMasterNo1
      @MinecraftMasterNo1 5 лет назад +1

      @@Chaosman88
      Unless there is a reason you want to modify how a framework or library works, the only thing you should care about is what input you need to have and what is the expected output.
      Both of which should be in the doctring/comments if the original developer was organized enough.

    • @Chaosman88
      @Chaosman88 5 лет назад +1

      ​@@MinecraftMasterNo1 No, I want to modify my colleague's code to add a new feature. Its a large repo with partly legacy code, and partly written by my colleagues. Nor the legacy part, nor my colleague's part is documented, and its written in such a way that is hard to decode for me. Like there is a function that does nothing but to wrap another function, that does something and call an API function, etc..

    • @TuanTran-og5te
      @TuanTran-og5te 5 лет назад +2

      @@Chaosman88 Yeah, the two tools of the trade that I use are: 1) git blame to see the context of why a line of code was written (to fix a bug, or part of a feature, when, by whom) and 2) IDE with debugger so you could step through the code line by line while looking at all the values of all the variables (raw pdb is good, but it doesn't have a UI, too toxic to use in large code base).

  • @xiaoyu88
    @xiaoyu88 5 лет назад

    I would say that having a duck or a buddy to talk about it with, is the most effective way. how many times Ive went to a friend, told him about it and before he was able to respond I was like "OH RIGHT" went back and solved it.
    Thank you for everything you post here. youre a gem!

  • @llittlegreyhound
    @llittlegreyhound 5 лет назад +7

    I also look at Chrome's Network tab in the dev tools to inspect the responses. Just make sure to preserve logs there and you're ok.

    • @bjmaldonado
      @bjmaldonado 5 лет назад +2

      Napoleon M. I was coming in, to comment this very thing. Usually auth failures are caught by Chromes Dev Tools! Great Video tho.

  • @vivekalagarsamy7339
    @vivekalagarsamy7339 4 года назад

    I would also recommend seeing following logs to understand the bug better, such as
    1. Application log
    2. Web server log (Apache/Tomcat/Anything?)
    3. Database log (if relevant)
    4. In this case it can be API Provider official error documentation page. For info on error code and its description. Which can also pinpoint what can be the issue exactly.
    5. Last but not least I may be checking server logs(linux/Anything?). For instance, memory allocation issue or disk space or anything.
    I hope it helps

  • @JoaoPedro-zn8bn
    @JoaoPedro-zn8bn 5 лет назад

    Thanks YK, your videos help me not only to get better at programming, but also to improve my english listening skills!

  • @josephgaviota
    @josephgaviota 5 лет назад

    I always enjoy CS DOJO vids; I learn a little something every time.

  • @zakirme
    @zakirme 5 лет назад

    1 missing letter and a few hours debugging made you create this awesome video. Perfect!!!

  • @sebbes333
    @sebbes333 5 лет назад +1

    *@CS Dojo* In PHP there are some "magic constants" ( php.net/manual/en/language.constants.predefined.php ) and my preferred logging method is:
    *print( 'Line: ' . **__LINE__** . ', in function: ' . **__METHOD__** . '(), in file: ' . **__FILE__** );*
    The output looks like this: *"Line: 42, in function: my_class::my_function(), in file: C:/full/path/to/file.php"*
    The best part is that it's super easy to remove, just search & replace with an empty string, because all these debug functions looks exactly the same but prints the information you need.
    Check if your preferred language also have any similar "magic constants" that you can use like this, it's super convenient.

  • @codeonmars579
    @codeonmars579 5 лет назад +1

    This is a nice topic, learning new things and debugging are the 2 important things for any software developer.

  • @Loppy2345
    @Loppy2345 5 лет назад +55

    Pro debugging tip: use emoji such as 😃when doing console logs!

    • @evansmith7911
      @evansmith7911 5 лет назад +1

      Loppy2345 I’m gunna do that now! 😀😀😀

    • @mayrw1
      @mayrw1 5 лет назад +1

      Is it because it will be easier to spot it in the logs? Sorry I'm new 😅

    • @codeonmars579
      @codeonmars579 5 лет назад

      nice

    • @mayursaroj4360
      @mayursaroj4360 5 лет назад +9

      I end up logging curse words..due to the level of frustration while debugging...

    • @aaronbell5994
      @aaronbell5994 5 лет назад

      It works!

  • @gordongood
    @gordongood 2 года назад

    This is great! Drilling deep and not giving up is the key to being a bug fixing ninja.

  • @sanyoun4328
    @sanyoun4328 4 года назад +1

    Wow! So It's like to be a detector! I haven't known about debugging correctly, but you spot it on to me. Thank you Dojo!

  • @michael05242002
    @michael05242002 5 лет назад +1

    Nice tips.
    But, the last 2 tips can be entirely replaced by using an IDE debugger (for example PyCharm), to save your time to write (+rollback) print() statement and pdb commands. IDE usually have nice features like watch variables, or even "backward step into" when stopped in a breakpoint.

  • @xCaleb
    @xCaleb 5 лет назад +14

    When I debug, I usually insert like a dozen breakpoints around the suspected area of the bug and step through them lol

    • @FelixAVargasA
      @FelixAVargasA 5 лет назад

      Sorry what's a break point? Thanks

    • @codeonmars579
      @codeonmars579 5 лет назад +1

      @@FelixAVargasA Place where you want your code to pause while running, so that you can inspect values.

  • @lakhtey6837
    @lakhtey6837 5 лет назад

    I think another way can also be to think of something different we have done in two same code base on two different environments. If we can answer to this question then it will be a lot easier to trace the issue at the very early stage. btw great video CS DOJO :)

  • @nicknameyu3588
    @nicknameyu3588 5 лет назад

    it's really a good thing for us that you missed one letter when you copying the keys because this video you create after that little accident is so inspiring

  • @gustavobertocco554
    @gustavobertocco554 5 лет назад

    I had a lot of issues on my iOS project with the google and facebook auth... Looks easy when you get this libraries that are already for this purpose but the effort for putting everything in your project.. This is the real deal! Great video :))))

  • @bryanchoong5920
    @bryanchoong5920 5 лет назад +2

    Nice video quality, lighting, well decorate background and sound quality😃

  • @albl6815
    @albl6815 5 лет назад +1

    If yes. I have an idea.
    Creating an app for phone or video call. But people not use direct address, they choose theme of discussion or tips of it. For example: " students want to practice their speaking skills. Their choose an issue. let's say - crisis in cold war. They write the name of issue and write some tips like - 1. Why cold war is crisis 2. Which countries were involved. 3. ... .
    And if somebody interests then can join to conversation.
    Video call (for example) for art, painting ...
    And also need background with already given issues for suggestion.

  • @yugioh8810
    @yugioh8810 5 лет назад +10

    Print statements are the X factor. It works like a charm!
    I just spam prints at functions or if checks I suspect are the problem. BINGO problem solved.

    • @nusratakhiislam2523
      @nusratakhiislam2523 5 лет назад

      My absolute favourite solution. Function not working? no problem, print/alert/echo. Not entering in the loop, no problem just do the bloody print 😂😂😂

  • @TuanTran-og5te
    @TuanTran-og5te 5 лет назад

    Great video. Just a few comments coming to minds.
    1. I don't think putting in a whole bunch of logging statement is good. Firstly, it clutter your code, secondly, it's just wasteful computations that you force the software to do just to figure out an error and bring no real benefit to clients, not to mention more code == less readibility. Logging is great to keep track of what went wrong in production, then use as a starting point for trouble-shooting production issue that happened in the past. In very rare case, when you cannot reproduce locally, pushing logging statement to production so that the next time it happens, you can have a starting point.
    2. The raw pdb is good if you want to debug something quick and simple (again, I dislike putting code into source code just for debugging purposes). I think the best way to debug is to use a proper IDE where you could set a break point, step through the code line by line (some debugger can allow you to go backwards, rerun a block of code multiple times, so you can see what happens), examine values of all variables on a GUI at all times. Some thing like this will do: ruclips.net/video/w8QHoVam1-I/видео.html. The advantage of using a break point is that you don't have to put extra code to debug production code. In my line of work, I deal with a large C++ code base, where a full compilation takes 40 mins, partial compilation of a project might take 1-2 mins. Recompiling every-time you need a new logging statement seems inefficient.
    3. Use unittest can also help keep track of bugs, if new implementation can break something already working and save you time from looking at wrong places.
    4. You should also mention the legendary stackoverflow somewhere :P

  • @LeetLife
    @LeetLife 5 лет назад +2

    OMG, that was so funny to look at now. But I can feel the pain of going through it. I am very happy you cracked it.

  • @neto6230
    @neto6230 5 лет назад +1

    insted of thinking i waist 4 hours debugging it would be i spend four hors learning something new.
    Great Video i learn a lot too

  • @mikediaz9033
    @mikediaz9033 2 года назад

    Cool.
    Thanks.
    Just learning.
    Continue don't give up, respect your history first.

  • @yashseetaram2127
    @yashseetaram2127 5 лет назад +4

    I love your videos so much for the past 1 1/2 years you've helped me a lot thank you so much man you're the best and keep up the fantastic work 😃😃😃😃😃😎😍😍😍😍😋😋😋😃😃

  • @aviadlampert5956
    @aviadlampert5956 5 лет назад

    The print statement tip is very useful.

  • @mikeg9b
    @mikeg9b 5 лет назад +1

    My last tough bug was due to not being familiar with the difference between shallow copies and deep copies in Python. I thought new_list = list(old_list) will ensure that old_list will not change when mutating new_list. Wrong! That line makes a copy of the top-level elements of old_list, but if old_list has elements that are themselves lists, those lists will still be aliased!
    I used print statements to zero in on the line that was behaving in an unexpected way. I may have used some assert statements too.
    old_list = [1, 2, [3, 4], 5]
    print('old_list = {}'.format(old_list))
    new_list = list(old_list) # If you think this means old_list is safe, it's not!
    new_list[0] = 66 # old_list is not affected
    print('old_list = {}'.format(old_list))
    new_list[2][0] = 77 # old_list IS affected!
    print('old_list = {}'.format(old_list))

  • @NYmarlon
    @NYmarlon 5 лет назад

    Your front end design looks super nice. You did it yourself or what library did you use?

  • @naveenkarthick528
    @naveenkarthick528 5 лет назад

    That was a pretty nice video, well done. Being a fresher in software development this can help me when I face frustrating bugss.

  • @not_enoughmana
    @not_enoughmana 5 лет назад

    Uf. I've had this happen to me on Heroku. Environment variable misspellings strike again! Good job tracking that one down, and after it takes hours it's certain to be the first thing a lot of folks check now when something similar happens. We learn our lesson the hard way sometimes, and that's okay. :)

  • @ocallesp
    @ocallesp 5 лет назад

    1 - Understand how the program should work
    2 - read the documentation, source code
    3 - Get the list of normal errors (sometimes developers write warning messages like fatal errros, but it is just a warning). Errors that seems to be errors, but they are not errors.
    4 - Find a good tool (debugger)
    5 - Learn how to use the tool correctly
    6 - Reproduce the problem locally and force it to happen whenever you want just to examine it with the debugger. In case the problem happened in a remote system, debug the problem locally. It will help you to proof you fixed the problem correctly after you create a patch.
    7 - Create a hypotesis about the possible root cause of the problem

  • @alimfuzzy
    @alimfuzzy 5 лет назад

    Thanks. Showing your thought process is so helpful.

  • @asashish905
    @asashish905 3 года назад

    Loved the session. ❤️ And the ending.😀👍

  • @Thiscantbeanyone
    @Thiscantbeanyone 2 года назад

    A single simple mistake made this whole knowledge for you and us, thanks for sharing your experience !

  • @Intothemarket101
    @Intothemarket101 5 лет назад +1

    Thank you so much for this useful data ! Greatly appreciated.

  • @szpitor
    @szpitor 3 года назад

    Super useful information how to start debugging. Thanks

  • @akhileshasare
    @akhileshasare 5 лет назад

    Hi, one of friend had google onsite interview last week. He's been asked interesting problem for which I am not able to find solution:-
    Find element in tree without visiting all nodes. So if you have root as 1 and child are 2, 3 and again there are two child of 3 which are 4 and 5. Now if you have to find element 5 in tree your algorithm should not go to left subtree with node 2. It should directly come to 3 and find 5. You can not use extra space like storing all elements in array and find element.

  • @betheprogrammer5359
    @betheprogrammer5359 5 лет назад

    i learn from this video today thank you cs dojo

  • @suchi19
    @suchi19 3 года назад

    Thank you so much for your debugging strategies.

  • @djk12587
    @djk12587 5 лет назад

    haha, this is so true, a lot of times the hardest bugs are caused by dumb programmer mistakes. But great video, your debugging logic is spot on.

  • @felixp535
    @felixp535 5 лет назад +1

    Or you could just use assertions. Most of the bugs I used to run into were just because of some data somewhere not being set/reset/sent correctly. I almost don't have to debug anything since I've been asserting what I know should always be true everywhere, and when it's not I get a nice trace log as well to help me understand the specific case that breaks my program

  • @yujinggrace8551
    @yujinggrace8551 5 лет назад +1

    so intersting!good job!

  • @shrihari7386
    @shrihari7386 5 лет назад

    I am not kidding. I got the exact same bug while using google oauth in one of my personal projects. Missed the last "k" in the api key(I couldn't find the difference since it had a horizontal scroll to it :x). Finally found it and was so pissed off. Took me not 4 hours but almost 2 days.

  • @lizzard2023
    @lizzard2023 4 года назад

    I took python las semester and the upcoming semester will be debugging.... this was extremely helpful thank you

  • @Naz-yi9bs
    @Naz-yi9bs 3 года назад

    haha awesome, thank you for the video! Quick question, what's your recommendation for the best Python Debugger if your IDE is VSC? I realized your using the built-in debugger, but is that your recommendation? Thank you!

  • @Lecxlez
    @Lecxlez 5 лет назад +2

    That's insane i remember watching one of your videos when you had about 20k and now you have 700k wow

  • @TheXxBananeroxX
    @TheXxBananeroxX 3 года назад

    Nice video. Just curious what IDE are you using?

  • @anilraj2792
    @anilraj2792 5 лет назад

    Nice video regarding debugging, but the error is funny😀

  • @tokugeeky2931
    @tokugeeky2931 5 лет назад

    Well like in life we miss the obvious solutions sometimes. Cool videos as always man look forward to more.

  • @H8orSk8
    @H8orSk8 5 лет назад

    I think the stack trace gives you a good idea on where the code is breaking

  • @iamdandy2436
    @iamdandy2436 5 лет назад +2

    Hey YK, loved your videos from the Python playlist. Could you please make a same playlist on Java, JavaScript or C++
    Thanks

  • @nut2975
    @nut2975 5 лет назад

    I have been ur follower for years...and never found a useless video in your channel....keep Up ThE GoOD work......and pls do a video about kali linux vs parrot if u can

  • @codersdance
    @codersdance 3 года назад

    Great! But please post the key points in the description next time. I liked the first and print yk1 ideas a lot.

  • @klof33920
    @klof33920 5 лет назад +10

    I prefer to comment some lines 🌷

  • @reemaalhamdan1
    @reemaalhamdan1 3 года назад

    Thank you this was a super clean video!

  • @josephgaviota
    @josephgaviota 5 лет назад

    If I might add _one more thing_ ...
    I like to do:
    print("Hello World") ###
    Then I can search for the triple pound, and delete those lines; easy to identify debugging print statements vs "real" print statements.

  • @施崇祐SHIHCHOUNGYOHF1405
    @施崇祐SHIHCHOUNGYOHF1405 5 лет назад +1

    wow pdf is blowing my mind. Thanks a lots :)

  • @rockyfrancisco9275
    @rockyfrancisco9275 4 года назад

    Thank you,i will always like your videos. I will learn lots of basic and tip,tricks.

  • @faisalkhan-gy5ef
    @faisalkhan-gy5ef 5 лет назад

    Another Helpful video from a great man...

  • @tiktokers8218
    @tiktokers8218 5 лет назад +6

    You are the man inspired me

  • @rishabhrawat9969
    @rishabhrawat9969 5 лет назад

    Is this the last video for this playlist? Will you be uploading more...dying to see what you do as a next step!

  • @HandledRoute
    @HandledRoute 5 лет назад +1

    Subbed since 1k can't believe how much you progressed ^^

    • @CSDojo
      @CSDojo  5 лет назад +1

      Thank you!!

  • @LetsLearnWithUs
    @LetsLearnWithUs 5 лет назад

    thanks cs dojo.. its very good tips for debugging

  • @musicjunkie421
    @musicjunkie421 2 года назад

    I would have looked into the Chrome network tab from the beginning then cleared it, reproduced it and examined which endpoint was getting rekt. Then examine request payload and response would have likely been "Could not authenticate you"

  • @nonohajar3886
    @nonohajar3886 5 лет назад

    thank you so much for this effort sir, but I wanna know if i follow the code will the program executes well? I mean is it ready to use if I copy & past your code? I am planning to make the same thing in my software engineering course project & I wanna be sure that it is working completely fine, coz I read the source code but could not understand =(

  • @technicalilm8999
    @technicalilm8999 5 лет назад

    Pdb was new for me . Great video yk

  • @chetanputtappanavar4176
    @chetanputtappanavar4176 5 лет назад

    Hey, you told in your previous videos that you did a machine learning project. You mean you implemented a research paper about machine learning?

  • @jihwankim9773
    @jihwankim9773 5 лет назад +1

    Awesome!! A similar type of problem appeared in the online coding test yesterday, but I couldn't solve it!!! I guess I'm an idiot...

    • @h.venkateshdeveloper6997
      @h.venkateshdeveloper6997 4 года назад

      No. , you're given your best, thats all, no one is fool and genius, matters what is how they train

  • @jaehyeokchoi4937
    @jaehyeokchoi4937 5 лет назад

    Hi! I really enjoy your video as a freshman cs/math student. I was wondering if u were an international student like me. If that was the case, is it extra ordinarilly hard to find a sponsor for your visa as a data scientist or software engineer? Anyways thanks for the great tips man !

  • @sakshamjain7984
    @sakshamjain7984 5 лет назад

    sir , you are a great teacher

  • @SwapnilSingh4u
    @SwapnilSingh4u 5 лет назад

    Dear brother I had a very hard time in learning and understanding Django framework of python though I know python very well and I have made some good projects on web scrapings, so can u suggest any resources to clear my fear of Django coz I have followed many tutorials but failed to grasp the Django framework.

  • @david-nb5ug
    @david-nb5ug 5 лет назад

    Great vid! Quick question, if you have a rule about print statements in production do you know of any tools that can get rid of uncommitted print statements when you commit but keep them locally so you can keep debugging?

  • @arni5na
    @arni5na 5 лет назад +1

    It’s a great video to learn how to debug in Python. But I already knew that the issue has something to do with the API keys right after you said what the issue is. The website works locally so it has nothing to do with the code.

  • @xCaleb
    @xCaleb 5 лет назад +11

    Grammarly for Programmers - let’s start a GoFundMe to make it happen

    • @temitopeoyeyemi899
      @temitopeoyeyemi899 5 лет назад

      Damn it....
      That's an idea man

    • @TheF4talgamer
      @TheF4talgamer 5 лет назад

      @@temitopeoyeyemi899 It already exists, for a long time

    • @coltonbreving7488
      @coltonbreving7488 3 года назад

      @@TheF4talgamer wanna give us some insight or.....?

  • @Deocharlesc
    @Deocharlesc 5 лет назад

    So,
    1. Come up with several hypothesis to test.
    2. Reproduce error locally.
    3. Read The Source Code carefully.
    4. Use Print Statements effectively.
    5. Use a Debugger effectively.
    I would say start with 1, 2+4, 5 then 3. You will spend lesser time debugging.

  • @ip0x085
    @ip0x085 5 лет назад

    i think dir() function usefull too, you can get list of valid attributes of the object

  • @olaoluwadaramola6828
    @olaoluwadaramola6828 5 лет назад

    Damn Edit Dojo has come a long way

  • @dibasdauliya1114
    @dibasdauliya1114 5 лет назад +1

    Hello Sir, please make videos about uploading website in Internet or recommend me personally...
    Love from Nepal !

  • @camzyrecap
    @camzyrecap 4 года назад

    I Just discovered ur channel, it's a good mine

  • @vedranjanjetovic5176
    @vedranjanjetovic5176 5 лет назад

    What have you been using for front-end? Which framework/template...

  • @thecashlessgamer480
    @thecashlessgamer480 5 лет назад +2

    Hi.... I am 14 and i just discovered your channel so i started the python coarse you have on your channel(just started it.... And I'm a TOTAL beginner) so i just wanted to ask am i starting too soon or too late? And do you have any tips for me?

    • @mbayelab
      @mbayelab 5 лет назад

      I you're willing to put in the time and effort necessary to learn programming, age don't matter.

  • @rexcode1759
    @rexcode1759 3 года назад

    I test the codes that I 100% think causing the issue in the interactive shell..and it helps me.. If you use other packages in your code, when it runs when you last run it, and then you install it again in the future..propably the pckage version is causing the problem..so need to check that too, try to test downgrade the package version

  • @bislari124
    @bislari124 3 года назад

    I'm going to start my career as an App Support Engineer. So please give me some tips how to start debugging.

  • @anshumanpatel3545
    @anshumanpatel3545 5 лет назад

    Quite a thriller from programmers perspective. Kind of hangover movie, look everywhere and then realise there is just a letter/keyword issue.

  • @manchuratt8900
    @manchuratt8900 5 лет назад

    Relatable. Just the other day I spent 3 hours resolving a bug only to discover wrong variable was being passed in as arg.

  • @adipratapsinghaps
    @adipratapsinghaps 5 лет назад

    Hey YK. This is an amazing video. But why no more coding interview problems?

  • @danilocecilia7831
    @danilocecilia7831 5 лет назад

    great tips! thank you!

  • @marcinkrysinski1566
    @marcinkrysinski1566 5 лет назад +1

    Wow, I didnt know about Pdb. EDIT, one letter really ? 😂, btw good content

  • @4345ghee
    @4345ghee 5 лет назад

    My first step when debugging is always assume the dumbest/simplest hypothesis first. I've experience SQLServer pw expirations that bubbled up into JSON validation exceptions at the API level before, and the first time it happened I was digging for hours on the Newtonsoft JSON nuget package that was used. Which is also another tip: Login failures can masquerade as something much more complicated/obfuscated.
    P.S.: Is pdb in the terminal the only debugger tool available to py devs? Is there no good IDE that has this functionality built in?

    • @hayenne
      @hayenne 5 лет назад

      PyCharm is an amazing IDE with a fantastic debugger.

  • @drhasnainsikandar
    @drhasnainsikandar 2 года назад

    Thank you. I mostly get suck while coding. In the beginning I thought it is ok because of is a part of growth but now,. I think that is too much wattage of time. Can you further tell me.

  • @ashura_amane8499
    @ashura_amane8499 4 года назад

    Thank you very much for sharing! ;)

  • @abdullahsaqib9904
    @abdullahsaqib9904 5 лет назад +1

    please make a video on how can we understand a programming language deeply so that we can develop alogrithms easily