October 12, 2023 25 mins

In this episode of Ruby for All, we start with a conversation about Julie’s challenges in adjusting to a calendar migration, which leads to discussions about productivity tools, color-coding calendars, and the use of extensions like “Better Comments” for code organization.  Andrew and Julie explore the purpose and potential pitfalls of code comments, share insights into work projects, including a significant rewrite, and even touch on the history of CoffeeScript in the coding world.  Also, they discuss best practices for API response statuses, the effective use of tools like Postman and curl, and the role of practical experience in shaping a developer’s understanding of best practices. Hit download now to hear more! 


[00:00:10] Julie mentions having issues concentrating at work due to a migration from Google Workspaces to Microsoft, with calendar issues. Andrew asks about her calendar system and whether she color codes it.  


[00:01:41] Since colors are so important to Andrew on calendars, he mentions an extension called “Better Comments” for color-coding comments in code. 


[00:03:15] Andrew discusses the purpose of comments, warning about deviations from conventions, and code readability, and Julie and Andrew talk about the problems with excessive comments and the importance of keeping comments up to date. 


[00:07:08] Julie wonders if Andrew adds links to comments or writes detailed PR reviews for reference. 


[00:07:53] What’s up with Andrew? He mentions working on bug fixes and a recent launch at Podia, including a rewrite of their email system.


[00:08:51] Andrew explains Trix, which was previously written in CoffeeScript but may have been ported to TypeScript. He also briefly discusses the history of CoffeeScript, its decline in popularity, and why he didn’t like it when he was new to programming. 


[00:13:21] Julie asks about best practices for API response statuses, such as when to use “status ok” or “status created.” She also asks about the use of “Unprocessable Entity” as a status code and its meaning. Andrew talks about how Rails handles different response statuses and mentions that Rails implicitly handles certain errors.


[00:15:58] Julie and Andrew discuss the importance of choosing the correct HTTP status codes for API responses. 


[00:16:44] Julie asks about handling different types of bad requests and whether Rails catches them. Andrew explains how to undo scaffolded code using “rails d” and suggests looking at Rails scaffold defaults for best practices.


[00:18:50] Andrew explains what Postman is and describes it as an interface for sending API requests. He also talks about the VS extension code, Thunder Client. 


[00:20:26] Andrew explains the benefits of using curl and jq for API requests and JSON processing. 


[00:21:14] We hear an example of using curl and jq to retrieve specific data from a GitHub API endpoint. 


[00:22:15] Julie mentions using ChatGPT as a “rubber duck” to find answers to coding questions and appreciates how it exposes her to new concepts.  


[00:22:43] Andrew and Julie discuss the importance of focusing on a way to solve problems, especially for early career developers, rather than getting caught up in finding the “right” way. 


[00:24:26] Julie brings up Ruby for All Episode 46 that you should check out, where they discussed Single Tab Inheritance (STI).

Panelists:

Andrew Mason

Julie J.

Sponsor:

GoRails

Links:

Andrew Mason Twitter

Andrew Mason Website

Julie J. Twit


Popular Podcasts

Are You A Charlotte?

Are You A Charlotte?

In 1997, actress Kristin Davis’ life was forever changed when she took on the role of Charlotte York in Sex and the City. As we watched Carrie, Samantha, Miranda and Charlotte navigate relationships in NYC, the show helped push once unacceptable conversation topics out of the shadows and altered the narrative around women and sex. We all saw ourselves in them as they searched for fulfillment in life, sex and friendships. Now, Kristin Davis wants to connect with you, the fans, and share untold stories and all the behind the scenes. Together, with Kristin and special guests, what will begin with Sex and the City will evolve into talks about themes that are still so relevant today. "Are you a Charlotte?" is much more than just rewatching this beloved show, it brings the past and the present together as we talk with heart, humor and of course some optimism.

On Purpose with Jay Shetty

On Purpose with Jay Shetty

I’m Jay Shetty host of On Purpose the worlds #1 Mental Health podcast and I’m so grateful you found us. I started this podcast 5 years ago to invite you into conversations and workshops that are designed to help make you happier, healthier and more healed. I believe that when you (yes you) feel seen, heard and understood you’re able to deal with relationship struggles, work challenges and life’s ups and downs with more ease and grace. I interview experts, celebrities, thought leaders and athletes so that we can grow our mindset, build better habits and uncover a side of them we’ve never seen before. New episodes every Monday and Friday. Your support means the world to me and I don’t take it for granted — click the follow button and leave a review to help us spread the love with On Purpose. I can’t wait for you to listen to your first or 500th episode!

Dateline NBC

Dateline NBC

Current and classic episodes, featuring compelling true-crime mysteries, powerful documentaries and in-depth investigations. Follow now to get the latest episodes of Dateline NBC completely free, or subscribe to Dateline Premium for ad-free listening and exclusive bonus content: DatelinePremium.com