Here's a guide for setting up claude-code with Trello using the REST API to have it read and manage your boards for you, without you having to go and click around. Pre-reqs you already have claude-code installed you already have a trello account install jq for linux & osx Set up the Trello API Key & Token You first need to create a Trello Power-Up - this is a feature meant for developers who are…
Gotten stuck in a rabbit hole figuring out how to add "Log In with Google" to your web app? This was an earlier series on my site from way back, but it looks like the landscape has changed so much - its worth trying to address how to do simple things like sign-in with google and use google oauth. In this series now updated for 2025, I'll cover: why you might want to use the Sign-In for Website JS…
In 2021, I joined Cornell Tech as a Visiting Instructor, to trial out a class called CS 5356 Building Startup Systems. It started off as a 1-credit course that met for 1:15 hours a week. The goal of the class was to cover all the practical aspects of building software and software engineering. It is where you take the theoretical skills of writing code and connect it to real world problems solved…
Have you ever been stuck on what looks like an empty page, and you ask yourself, "Am I supposed to be seeing something yet?", only for it to appear like 30 seconds later? Or maybe you've clicked on a button and you're not sure whether its processing or not (like on checkout pages). If thats what your own app feels like then, read on. In this guide, I'll walk you through 4 scenarios you should…
If you're itching to write some code, but you can't stand the thought of another MEAN, MERN, or PERN stack, here's a few resources to help you explore javascript using a slightly different approach - games! Last week, I saw a Reddit comment thread that was asking about coding games - games where you have to write code to play the game. I've heard of a couple over the years, but never explored the…
I sign in with my Google account everywhere I can to avoid having yet-another-password on another random website. I've been seeing an upgraded experience on some sites (maybe I'm just noticing now) like Trello/Medium where you can sign-in with Google with one click on the page without getting redirected. Turns out its called One Tap for Web and its Google's passwordless sign-in option and you can…
Today, I stared at a to-do on my Trello board saying "schedule 1-1s with your team." Its been on my list for 2 weeks now, and even though I see it every day, I keep putting it off. I recently became tech lead of my team after the previous lead left suddenly. This wasn't my first time filling in the tech lead's shoes, and I've tried to study a lot about being a lead ( check out my recommended book…
Note: If you want to see how to handle these in React, take a look at my new post on that here - handling async errors with axios in react. Whenever you're making a backend API call with axios, you have to consider what to do with the .catch() block of your promise. Now, you might think that your API is highly available and it'll be running 24/7. You might think that the user workflow is pretty…
Sharing some reusable javascript is hard - even moreso if you're trying to share between node and the browser. I'm just trying to share some 10 lines of code. Why is this taking me more than a day to figure out?! Its times like these I have to talk myself out of doing a copy/paste. I know its wrong, and reusable packages are better, but ugh... at what cost. Some JS code is meant to run in the…
Does this sound familiar? The best dev on the team is promoted to being a tech lead, despite not having any management experience. That dev then all of a sudden has to deal with: Angela, the senior dev who broke up with her partner and is emotionally devastated and needs to take a few days Oscar, the new dev, saying he needs a few more days to refactor a logging module that needs a "cleaner"…
Why do some of your styles no longer work when using [innerHtml] to show some HTML content? Angular comes with a built-in html sanitizer DomSanitizer , as a security feature, thats used whenever you use [innerHtml] . Its a great feature - but has a pretty annoying bug/feature in that if you have elements with inline styles, the styles wind up getting removed from your page. Judging by the amount…
Up until late last year, you couldn't set up automatic failover in CloudFront to look at a different bucket. You could only have one Primary origin at a time, which meant that you needed additional scripts to monitor and trigger failover. (It was one of CloudFront's gotchas I had written about previously ) Then AWS dropped the bombshell during re:invent 2018 that Cloudfront can now support it by…
Get branded short links under your own domain for dirt-cheap by self-hosting it on AWS using CloudFront + S3. It's a no-code server-less solution to get redirects on the cheap and in this guide, I'll detail how to set it up. If you're interested in some good reasons why - check out my first post on it here . In this guide, I'll go over what do our redirects/short links need to be able to do how to…
This problem landed on my lap awhile ago, and I've seen it come up time and time again so I wanted to share how we went about it. Our marketing team was submitting one of our products for a review for a client, it has a ton of content. There was a long list of deep-links in the product that we wanted the reviewers to see, but we needed to create shortlinks so they could embed them on some doc.…
[embed]https://www.youtube.com/watch?v=iND-Epl8nz0[/embed] *Check out the video to see me follow along with the code. In this next part of the series, I'll be walking you through an implementation of google sign-in with a simple react app and a bonus react-router example. Up until now, we've seen 2 different hello world examples of how to add google sign-in on the front-end - using plain HTML and…
In the first part of the series, we decided to use the Google Sign-In for websites library to allow you to show some info about the user using javascript. In that part, we use the default Google Sign-In workflow with a default button. In this part, we'll be going over how to use the gapi library to configure Sign-In and then actually sign-in the user, as well as a few snippets for handling some…
[embed]https://youtu.be/KwOmVpd1DUA[/embed] *Check out the video to see me follow along with the code. Gotten stuck in a rabbit hole figuring out how to add "Log In with Google" to your web app? In this series, I'll cover: why you might want to use the Sign-In for Website JS library, and getting started with it Adding the library via javascript adding it to an existing project (angular & react)…
UI browser tests can be flaky, and it can be really frustrating to have to re-run a test suite because 1/50 tests failed and most likely, it'll work on the next run. webdriverio offers retries but only at the individual spec level as seen on their docs which doesn't help you re-run all the specs in 1 file . webdriverio lets you hook into the test reporter using Custom Reporters , and we can create…
Using headless chrome for your UI tests works great out of the box on your laptop, but it won’t work out of the box when you're trying to run your tests in Docker. One recent work project was getting webdriverio tests successfully running in a Docker container as part of a Jenkins pipeline. Locally, our tests worked fine, but when we ran them in docker, they became super flaky with errors showing…
https://youtu.be/66E7y12GQaE ^ Update - check out my video walkthrough where I follow along with the post and show you how I set it up. https://youtu.be/wvvIz60DNp4 ^ EDIT 10/2019 – I’ve published a new video to my Youtube Channel where I debug a test and show you how to use browser.debug() alongside the VS Code Debugger. Check it out! Am I using the correct selector? Which element is it actually…
Can I use jest to run webdriverio tests? You have a web app and you're using jest for unit testing your components. You're checking out webdriverio to run your UI tests in javascript. Webdriverio comes with its own test runner if you want to use it. But you're already using jest in your codebase. Can you use jest to run your tests using webdriverio? Short answer: yes. Long answer: maybe not?…
The tech lead was moving to another team for a long-term assignment, and I took over as the engineering manager/team lead. From the outside, the tech lead's job seemed doable, but I quickly realized I was getting in over my head. Unfortunately, my team was responsible for a lot of centralized infrastructure as well as day-to-day technical operations. I had no tech lead training, and how could…
You've finished deploying your website to its new domain. You start to see your normal user traffic, but then you also notice funny patterns in your access logs. Here's a few examples of things you might see in your access logs once your site or API is public in production. Automated vulnerability scanners from all over the world Crawlers SQL Injection attempts Scanners You know what regularly…
You have a few lines you've been typing in your shell, and you'd like to just run it the way you run any other CLI including options. If you're writing a shell script, here's a few tips to help you get a head start. #! the shebang line usage docs flags and options error handling dealing with output This doc assumes you're using bash in an OSX/Linux environment. 1. the shebang line You'll usually…
Have you run into an error saying "Element is not clickable at point" when you're trying to click a button? You might be seeing this if you have a spinner that appears on your buttons or its a customized button (like a div as a button with inner styled elements). In these cases, you're kinda out of luck if you want selenium to be able to do it because it can't see the element that you want to…
If you're loading a page and want to make sure that some elements are showing up before advancing, you'd be inclined to use browser.waitUntil() . While it does do the job, it holds onto the errors until the test times out. In this example, I'd like to use waitUntil to check that multiple elements are visible browser.waitUntil(function() { return doesNotExist.$$('#elem-1').isVisible() &&…
There's a few ways to go about getting text from a list of elements, but there's a gotcha with webdriverIO that can make your tests a lot flakier. The easiest way should be to: // get some of the headers on wikipedia.org > browser.getText("#mp-topbanner > ul > li") [ 'Arts', 'Biography', 'Geography', 'History', 'Mathematics', 'Science', 'Society', 'Technology', 'All portals' ] One exception that I…
Ever want to stop your Selenium tests halfway and try to see what your tests are seeing? Using .debug() helps but be aware of your test timeouts & context around your code. EDIT 10/2019 - I've published a new video to my Youtube Channel where I debug a test and show you how browser.debug() alongside the VS Code Debugger. Check it out! https://youtu.be/wvvIz60DNp4 timeouts Lets go over a simple use…
Last week, I started working on integrating a test suite previously built using Nightwatch, and making it work with webdriverIO. While I love all of webdriverIO's features like synchronous code when using their test runner and a REPL, there were a few things that I'd like to share which were a little hard to find in the docs or on a quick search. Each day this week, I'll be posting one thing I've…
A guide for when you have to add/remove/update/and/20/other/things in both mysql & postgres databases, and you wind up getting lost trying to do seemingly simple things. I've been keeping a running doc where I keep snippets of SQL for those times when I have to remember, and I hope they help if you happen to be using both postgres and mysql and need to manage user access. Below, we've got 10…
At my current gig, we've got 50+ services, ~6+ environments, and a rough count of 3.5k parameters across our environments. We used to use Chef::EncryptedDataBags when we used chef-server. A few years later, we migrated to using Vault. And then a year after that, we finally settled on using Parameter Store. Over time, we've grown used to the intricacies of managing secrets and access to secrets. If…
A few years ago, I was helping a company get its secrets in order. There were secrets stored in Google Docs, in Chef, in git, in an OSX image stored in git, in email, in a file manually placed in a Jenkins instance somewhere near you. It helps to split out your solutions by common use cases rather than use one tool for everything so here's 4 things that your org might need a safe and secure way to…
As a follow up from my last post about things I look for when hiring a junior DevOps engineer - these are the things I'm looking for out of a senior engineer. It all boils down to what I consider the core of DevOps - helping engineering teams ship their apps quickly and safely to production. At a high level, this means being able to provide: a CI workflow knowledge of release workflows an…
If you're following along, in my previous post, i was building a blog with gatsby . Now that I've got some changes made to my blog, I want to make sure that the blog is loading at least and click around a few pages to make sure everything loads correctly. Setting up browser tests We can use nightwatch js to set up some happy path tests for your blog. I've used this getting started guide to get up…
You've been hearing about DevOps as a career path, and you're looking to to break into the field as a Jr DevOps engineer, but you don't quite know if you're qualified for it yet. You might be a recent grad, or maybe you've been in the industry a few years and you want to improve your skills. How do you know whether you need another 3 months to get some better experience under your belt, or whether…
Yes! Absolutely. It'll be the only way for you to really know whats going on behind the scenes. When I got started, my first few expenses of my tech career were a domain, a private non-gmail email inbox, and a wordpress website via Bluehost, ...and some business cards. It must have cost me $100 for the first year which was mainly the domain + bluehost costs. I was running a wordpress blog with…
Create a blog using HTML and JS In this section, we're going to set up our new Gatsby project as a blog, add a few posts, and get a blog working locally. Pre-requisites: node v8 npm git You should be familiar with html, javascript, npm, and the command line. I won't go too far into details about using gatsby - here, I just want to get something half-decent looking on a live environment first.…
This is a pretty typical nightmare scenario. An engineer suddenly quit and I was part of a new team that was maintaining a brittle system with little documentation. Someone pings me and says, hey this website isn't working anymore - it says the cert's invalid! halp! Debugging SSL issues are tough, especially when I hadn't dealt with them before and no one on the team was too familiar with our…
Cookbooks can also get the same red, green, refactor loop going the same way you would with a simple application. It's not all roses though because the loop itself takes a few minutes at a time. Even with a simple cookbook, you're looking at 3-4 minutes each run if you're constantly testing using converges. In terms of the fastest feedback loops, you should: Use Chefspec to test that you're…
How do you get started with chef cookbooks as an app dev? My first time approaching Chef was after doing Android for about 2 years. Whether you're working on the front-end or backend or even on Mobile, the overall workflow of your application is the same. Make changes to your application locally Write unit and/or integration tests to verify your changes Deploy & verify your changes to a test…
Right now, we have a website hosted in an S3 bucket using CloudFront defined in terraform running with automated tests. There's a few catches with using this setup so we'll go into what these issues are and how to work around them. the lifecycle of the cache There's a few different ways to configure TTLs on CloudFront Use a TTL of 0 Control the cache at your Origin. See this Stack Overflow…
Let's review the architecture we put together in Part 1. Check out Part 1 a main website that is hosted at a www. subdomain an html/js/css app that is hosted in an S3 bucket a cloudfront distribution to give us an https URL a certificate that will be used with the cloudfront distribution for that domain a series of vanity URLs that will redirect to the main website Let's start building some…
Creating a serverless static website What's the problem? I want to deploy a plain HTML/CSS/JS website with the minimal amount of fuss. I'm going to be using it for a simple web-app so I want to make sure its always up and always working as well. There's many different ways of deploying websites with mostly static content. You could run a server using nginx/apache to serve files out of a directory,…