Xcode Breakpoints - Basic Debugging | Swift

  Переглядів 34,022

Sean Allen

Sean Allen

День тому

Check out more information on Devmountain:
bit.ly/35Tzs9K
In this video I walk through a basic debugging exercise using breakpoints in Xcode. We debug an issue where loading the next 100 followers in an app causes a crash. I also talk about various features of breakpoints and how to use some of them.
This tutorial was done using Swift 5.2 and Xcode 11.4.
If you like my teaching style, I've released my first iOS dev course which is all about the take-home project job interview for iOS developers.
Course Info - seanallen.teachable.com/
Link to my book - How I Became an iOS Developer:
gumroad.com/l/sean-allen-origin
Hired.com:
hired.com/x/1n01g
Check out my podcast, iOS Dev Discussions:
itunes.apple.com/us/podcast/i...
Book and learning recommendations that help out the channel if you decide to purchase (Affiliate Links):
Ray Wenderlich Books:
store.raywenderlich.com/a/208...
Ray Wenderlich Videos:
store.raywenderlich.com/a/208...
Mark Moeykens SwiftUI Views & Animations Mastery:
www.bigmountainstudio.com/a/f...
Donny Wals - Combine Framework:
gumroad.com/a/909014131
Paul Hudson's Hacking With Swift:
gumroad.com/a/762098803
Learn Advanced Swift Here:
gumroad.com/a/656585843
Links to my iOS Dev Setup & iOS Dev Book Recommendations
www.amazon.com/shop/seanallen
Personal Links:
Twitter:
/ seanallen_dev
Instagram:
@seanallen_dev
#swift #softwaredeveloper #iosdeveloper

КОМЕНТАРІ: 75
@isaacclark9825
@isaacclark9825 4 роки тому
Great content! I make a living answering student programmer questions. I wish I had a quarter for every time I have asked a student, "have you used the debugger" and received the response "we haven't been taught about that."
@seanallen
@seanallen 4 роки тому
Thanks Isaac!
@bdaralan
@bdaralan 4 роки тому
Thank you, I learnt a few things. To delete all break points, drag away the project icon in the break-point tab. 😃
@ryankanno2562
@ryankanno2562 2 роки тому
Without a doubt debugging is the most important skill for any developer. Great video!
@iosedat
@iosedat 4 роки тому
Hi Sean, I am following you since few days and learning iOS Development. This video is worth of Gold for me. Thanks for sharing your experiences.
@seanallen
@seanallen 4 роки тому
Glad it was helpful, Sedat!
@CredoAcademy
@CredoAcademy 4 роки тому
What a great tutorial about Debugging and how to use breakpoints in Xcode. 👍Great job Sean!
@seanallen
@seanallen 4 роки тому
Thanks!
@sanjayarun4947
@sanjayarun4947 4 роки тому
I always had trouble understanding the exception break point. You cleared it up for me. Thanks a lot sean..
@seanallen
@seanallen 4 роки тому
Happy to help!
@glennmiller394
@glennmiller394 4 роки тому
Good video, Sean. Debugging is the #1 skill software engineers need to develop to keep their sanity. The sound thingie? For long running programs. No more checking the display every three seconds.
@seanallen
@seanallen 4 роки тому
Glad you liked it Glenn, and that would be a good use of the sound.
@denisp.7850
@denisp.7850 4 роки тому
Informative as usual 👍 A quick tip that i've been using a lot: using control+command for jumping to definition. Makes it so much faster to navigate through code.
@seanallen
@seanallen 4 роки тому
Thanks for sharing. That's a shortcut I always forget about.
@VeryBlueBot
@VeryBlueBot 4 роки тому
Oh man this is so clear and helpful. Basically everything I needed to know about break points in xcode in 20 minutes (10 actually, I watch in X2 :)) Most of my code milage is in JS so Im not using breaking points enough.. Thanks :)
@seanallen
@seanallen 4 роки тому
Glad it helped!
@yosansu
@yosansu 2 роки тому
thanks for the video! loved the simple explanation style :)
@Didstoraro
@Didstoraro 2 роки тому
Thank you so much for this video, Sean. 🙂 It has helped me a lot, I'm learning iOS right now and I find myself often overwhelmed with so many new things. So... Thanks 👍
@seanallen
@seanallen 2 роки тому
Happy to help!
@PtolemysEye
@PtolemysEye 4 роки тому
LITERALLY had that exact bug today lol. Super fun figuring it out without using breakpoints :D
@andreagualandris2462
@andreagualandris2462 4 роки тому
Thank you Sean, video so helpful!
@seanallen
@seanallen 4 роки тому
My pleasure!
@SwiftlyShivali
@SwiftlyShivali 4 роки тому
Awesome Video, Sean!
@seanallen
@seanallen 4 роки тому
Thanks! Glad you liked it 😀
@hermanvancauwelaert
@hermanvancauwelaert Рік тому
thanks for the clear explanation
@seanallen
@seanallen Рік тому
Glad it was helpful, Herman.
@ca7986
@ca7986 Рік тому
Amazing tutorial man! 🙏
@seanallen
@seanallen Рік тому
Glad you liked it!
@usamashoukat8233
@usamashoukat8233 Рік тому
Bro Nice and Simple explanation 🔥
@seanallen
@seanallen Рік тому
Glad it was helpful!
@donathmm3881
@donathmm3881 4 роки тому
Learned something new! Thanks Sean
@seanallen
@seanallen 4 роки тому
Happy to help!
@ivanputeraa
@ivanputeraa 3 роки тому
I usually use the breakpoint sound feature whenever I do debugging and left my laptop while running the code. I use Bluetooth headset btw, so whenever I hear the sound I’ve set before, it means that the code has triggered the breakpoint so I can go back to check my laptop. Maybe it looks kinda funny, but it’s really useful for me though 👍🏼
@bruhmoment3731
@bruhmoment3731 3 роки тому
Wow. This video is packed with information. I feel like it raised my IQ by 20 points.
@JonatanEdOrtiz
@JonatanEdOrtiz 2 роки тому
Great tips!
@TylerWasick
@TylerWasick 4 роки тому
Thanks Sean for another great video! How can I make suggestions on new videos? I am trying to learn more advanced cases of protocols and delegates.
@seanallen
@seanallen 4 роки тому
Glad you liked it. Feel free to suggest here, but I have a VERY long video idea list.
@AmitGupta-xc9gq
@AmitGupta-xc9gq 2 роки тому
Hiii Sean, I want the debug te code when app is killed state and notification tap
@hardipgajera2316
@hardipgajera2316 3 роки тому
This is very helpfull thanks man:)
@seanallen
@seanallen 3 роки тому
Glad it helped
@Ivan_Maslov
@Ivan_Maslov 4 роки тому
Hello! Could you make a video on View debugging? By the way, why did you write arg1? Is that a specific variable or you could write arg with any number, like arg0, for example? Thanks
@Some.real.human.
@Some.real.human. 4 роки тому
CMD + A, Delete to delete all
@seanallen
@seanallen 4 роки тому
Thanks for sharing!
@Some.real.human.
@Some.real.human. 4 роки тому
Sean Allen np Sean! Would love to see a more advanced video on breakpoints showing features like conditional breakpoints!
@gillesashley9314
@gillesashley9314 2 роки тому
Sean you leave a lot of spaces before assigning your values, won’t it affect performance. Sorry to ask but coming from a JavaScript background where we minify files to improve speed.
@govind20246
@govind20246 2 роки тому
Really good 👍
@Taxexpert82
@Taxexpert82 Рік тому
O.M.G I am trying to update my app in the apple developers, but I can't, any video you can recommend to me.
@PatricioBenavente
@PatricioBenavente 4 роки тому
Didn’t know the click and drag to delete breackpoints. Nice tip For showing all your breackpoints you can use Command-8 You don’t hace to enter a function and add new breackpoints. Once your program is paused you can use the step-into button (with control-shift) in the debugger. Great work as usual Sean.
@seanallen
@seanallen 4 роки тому
Thanks for the tips!
@luismosqueda7293
@luismosqueda7293 2 роки тому
I got a thread 1: signal sigterm and I have no idea what that is or how to fix it to run the app
@guruitcompany
@guruitcompany 4 роки тому
Thank you very much 😊
@seanallen
@seanallen 4 роки тому
Happy to help
@hareeshgangadhara415
@hareeshgangadhara415 3 роки тому
Sometimes breakpoints not working. What to do in that case
@chrispy104k
@chrispy104k 3 роки тому
Hey Sean, with regard to your query about the Console showing that annoying message: Snapshotting a view (0x7ff9aae0cad0, _UIReplicantView) that has not been rendered at least once requires afterScreenUpdates:YES. I discovered through looking through all the options to configure the textField in the file GFTextField that by adding the line: autocapitalizationType = .none in the configure() function the message stopped. I've no idea what is going on there but clearly that had something to do with it. I did the same for the searchController. ie, in configureSearchController() searchController.searchBar.autocapitalizationType = .none Problem solved.
@edwincreator2855
@edwincreator2855 4 роки тому
The indentation for = is killing me
@dan_pal
@dan_pal Місяць тому
Amazing 🎉
@seanallen
@seanallen Місяць тому
Thanks 😄
@robinandthedog
@robinandthedog 4 роки тому
Note that po means evaluate expression, see : help po. The nice thing is you can change variables with it to run a different course in your program e.g.: po isMyAppCool = true
@seanallen
@seanallen 4 роки тому
Thanks for clearing that up, Robin!
@connorvantress8073
@connorvantress8073 2 роки тому
the code on his screen at 1:52 is the only thing that pops up on my screen when I try and de-bug. I cannot see my actual code or the green line that shows where it is at and running. How do I fix this?
@connorvantress8073
@connorvantress8073 2 роки тому
Fixed it by randomly messing with Xcode debugging settings...great :)
@tech_wizard9315
@tech_wizard9315 4 роки тому
If I practice DSA with Swift for 3 months.... 6 hrs each day... M I ready to get job at Apple..? (I am a fresher)
@seanallen
@seanallen 4 роки тому
Tough for me to say as I don't do any hiring for Apple 😀
@dannylones2159
@dannylones2159 4 роки тому
simple but not easy
@Fwipo
@Fwipo 3 роки тому
Hold up wait why are your breakpoints red?
@seanallen
@seanallen 3 роки тому
It's your system accent color. You can set it in System Preferences > General
@DimitrisTheo
@DimitrisTheo 4 роки тому
Should a beginner know these stuff? I only know what a breakpoint is and how to use it.
@seanallen
@seanallen 4 роки тому
I'd say you'd need to have a good idea of basic breakpoints and debugging before you get your first job. Knowing how to debug can save you tons of time when just learning as well.
@DimitrisTheo
@DimitrisTheo 4 роки тому
@@seanallen Alright thanks!
@aliquewilliams3080
@aliquewilliams3080 3 роки тому
Don't ever paginate using content size. It's a straight up anti-pattern.
@sarahd6314
@sarahd6314 Рік тому
13:23
@dannylones2159
@dannylones2159 4 роки тому
google, debug and google your debug
Improve Debugging Skills | iOS | Swift/Obj C | Xcode
26:02
iCode
Переглядів 16 тис.
How to Make an App in 8 Days (2024) - Full Walkthrough
3:00:49
CodeWithChris
Переглядів 469 тис.
Excited Dog Zooms In and Out of Sliding Door!
00:18
The Pet Collective
Переглядів 16 млн
Історія загиблого Назара Небожинського
00:54
Суспільне Рівне
Переглядів 983 тис.
37 Tips for Jr. Software Developers
16:21
Sean Allen
Переглядів 188 тис.
24 Xcode Tips in 15 Minutes
15:30
Paul Hudson
Переглядів 72 тис.
Xcode - Visual Debugger - A Tool For Debugging UI
6:36
Sean Allen
Переглядів 12 тис.
Xcode Tutorial - Step by Step for Beginners
56:52
CodeWithChris
Переглядів 307 тис.
SwiftData Basics in 15 minutes
15:18
CodeWithChris
Переглядів 34 тис.
Debugging (Swift 4)
16:41
SwiftBook
Переглядів 6 тис.
Swift Closures: @escaping Explained
4:45
Sean Allen
Переглядів 44 тис.
Swift For Beginners - Class & Inheritance Explained
15:42
Sean Allen
Переглядів 16 тис.
Купите ЭТОТ БЮДЖЕТНИК вместо флагманов от Samsung, Xiaomi и Apple!
13:03
Thebox - о технике и гаджетах
Переглядів 22 тис.
Which Phone Unlock Code Will You Choose? 🤔️
0:14
Game9bit
Переглядів 5 млн
Android top🔥
0:12
ARGEN
Переглядів 1 млн