4 levels of Rust error handling

แชร์
ฝัง
  • เผยแพร่เมื่อ 6 พ.ย. 2024

ความคิดเห็น • 15

  • @empathy_monster
    @empathy_monster 2 หลายเดือนก่อน

    Thank you so much for the video! I didn't know you had a YT channel. I just picked up your book, Rust in Action! Thanks so much for all your teaching!

  • @JorgetePanete
    @JorgetePanete ปีที่แล้ว +18

    Some video editing to shorten the video would be very useful

    • @programmer1356
      @programmer1356 2 หลายเดือนก่อน

      watching *2 helps and he has added timestamps

  • @agustindiaz3361
    @agustindiaz3361 9 หลายเดือนก่อน +1

    This is awesome! This kind of high quality, advanced topics in rust is really absent in youtube. Thanks for sharing it :D

  • @ekarademir
    @ekarademir ปีที่แล้ว +5

    Thank you for this video.
    I just wanted to add, another advantage of using a crate level Error enum is that if you are emitting the errors in different ways, like printing out, or returning as a server response, or pushing into a central system, your extra work would be just implementing conversions to that enum.

    • @timClicks
      @timClicks  ปีที่แล้ว +3

      Excellent point. Thank you for adding your thoughts.

  • @pyprem
    @pyprem 10 หลายเดือนก่อน +1

    There is some confusion at 25:17. However, to make this idea work you can do it like this: `.map_err(|_err| "could not create file")?;`, i.e. `map_err` returns the value contained in the Err variant, not the whole variant itself.

    • @nubunto
      @nubunto 8 หลายเดือนก่อน

      came here to say this. there's a confusion between the Result type and the Err variant, which is common!

  • @bakhtiyargarashov805
    @bakhtiyargarashov805 ปีที่แล้ว

    Going through the Rust learning journey with you is amazing. Thanks for that.

  • @nscheer
    @nscheer 10 หลายเดือนก่อน

    Really enjoyed your content!
    One thing: The video would be way nicer to watch without all the „ehem“ and „aahmm“ - it is worth it to train and let there be just some silence between the words 😊

    • @timClicks
      @timClicks  10 หลายเดือนก่อน +1

      Thanks for the advice. You'll find that more recent videos of mine are much more polished

  • @pmcgee003
    @pmcgee003 10 หลายเดือนก่อน

    unwrap .. because Result should be understood as a functor / monad

  • @jimBov-b8r
    @jimBov-b8r ปีที่แล้ว

    Привет я на этом канале сново увидел шедевр это видео прекрасно как и остальные

  • @mustafazakiassagaf1757
    @mustafazakiassagaf1757 ปีที่แล้ว +1

    hey it would be nice if you provide timestamps for longer video like this. other than that this is a good video with good story telling 💪