Posts

Showing posts from 2021

switching from a manager to IC

I switched from manager role to IC role in 2021. I discussed with my manager end 2020 and started the change in January 2021.  If you want to understand my rationale better, then read this post from Charity mipsytipsy  (who is awesome). It's spot on and sums it up better than I could  ..oh,  and this too from Charity  "Management is a support role", read it

when delegating...

when delegating: be clear on what you need, communicate the desired outcome (unless the outcome is unknown and is part of the work to be delegated...but even then, that's an outcome!) let the delegate figure out the approach & details (as appropriate for level) checkin as needed to make sure delegates approach/plan is as expected; ask questions as needed multiple solutions may work, so be flexible on expectations bias toward action & experiment you may (or may not) need a summary of what's going on and who's doing it, status etc. to show to your manager but honestly it can be difficult especially with larger initiatives (months, multiple teams etc) to know when to jump in and when not to 

github "Repository not found fatal: Could not read from remote repository" error, troubleshooting and fix

Yesterday I'm suddenly unable to access repos I work with on a daily basis. When I rebase or try to clone I get this error ERROR: Repository not found. fatal: Could not read from remote repository. Please make sure you have the correct access rights and the repository exists. Nothing changed. My github credentials un-chanaged. My ssh keys unchanged. I was able to fix by regenerating my ssh keys but read on for tips on troubleshooting there's a good troubleshooting page on github with help on common issues first, test your ssh connection and identity using `ssh -vT git@github.com` see more here when I ran this command I noticed it's response "Hi <id>, .." was not the id I expected and clearly a problem check your `~/.gitconfig` (does it looks correct?) check the email and userid used in your repo , they should be as expected and be associated with the ssh key locally and also in github you can unset  git config --global --unset user.name git config --global

AWS Lamdba spinning up a nodsjs microservice with persistence

Image
  AWS Lamdba serverless is pretty cool. Deploy services and code easily without having to provision and manage servers.  My previous employer has it's own data center and infrastructure so we don't get to work hands on configuring and using aws services usually. So I'm creating my own AWS Lamdba microservice to manage appointments and store in DynamoDB nosql key value database. I'm using serverless framework cli integration for aws. There are steps I followed to setup a nodejs service: Create a new aws user for this service. Follow instructions on aws site to install cli locally. I followed command line install. run `aws configure` cli using new user id and secret (created in step 1) install npm serverless locally you can bootstrap a serverless config file using template create, but in next step I do manually create serverless.yml (or js/ts) for your service and handler functions the handler in the serverless config file must match an exported function name and the fil

Javascript Engine

 Interpreted vs Compiled js is considered an interpreted language (not compiled).  there is no executable to be deployed such as a jar file and each line is read and then processed and executed  but a lot is going on under the hood when javascript code is processed by the javascript engine some of which is very "compiler like" Let's look at this code example. The 3rd line is an error but if code was truly interpreted then would see the console.log() and then error. But that does not happen, we see the error without any log. Why? Example 1: let sayHi = 'hello'; console.log(sayHi) sayHi = ."hi"; Let's look at another example.....same thing we see the error before any log. Why? Example 2: console.log("Howdy"); saySomething("Hello","Hi"); function saySomething(greeting,greeting) {     //"use strict";     console.log(greeting); } At a high level, the javascript engine is making multiple passes over

"Clean Agile" with Bob Martin (uncle Bob)

 I listened to an O'Reilly Live Event with Bob Martin https://learning.oreilly.com/accounts/login-check/?next=/live-training/courses/-/0636920061744/ Bob was one of the original signatories of the Agile Manifesto, a software legend and no holds barred educator. key takeaways Agile does not make you go faster, it produces data to understand where the project is at We do Agile to get data such as velocity and burndown, "to see how screwed we are" We want the bad news as early as possible, cold hard data So we can react and adjust our definition for: fast, cheap, good, done (for the feature/project) Agile is about managing a successful outcome given all your constraints Agile software development at 30k foot level is dividing project up into small time increments, measuring how much you get done, multiplying out to get a date and making adjustments as necessary given your constraints e.g. we want to launch X  my notes Agile is a set of disciplines Product Owner is chief spec

creating and publishing npm package "fwap", a typescript fetch wrapper

Browser fetch is a simple well supported built in http api which we use for some apps at Opentable. But fetch has some differences to typical fetch libraries:  it does not throw for 4xx and 5xx responses, you have to check the ok property and if not true then it's a failed error code you have to call async json() on the response to convert to json (tiny tedium) So a simple wrapper facade over fetch to take care of these would be nice eh! And how about we use Typescript and use built in http types like RequestInit and Response as well as generics. That's what fwap is! and it's now available on npm. Of course our code has unit tests. Yes it's yet another fetch wrapper (yafwap was another name I considered) but it's also a good learning experience (it's the journey as much as the destination maaannnn) All my references are at the bottom of this post and I'm much indebted to those authors How I created: git init and npm init confirm fwap not already used add typ

Link to "10 Software Engineering Laws Everybody Loves to Ignore"

Image
 Love this: https://www.netmeister.org/blog/software-engineering-laws.html #11 rotfl

User Story Mapping

  User Story Mapping is a way to have everyone on the team collaborate on discussing and brainstorming the problem domain. It starts with the big picture: who are the users and what do they want to do. Then drills down into more detail leading to stories which can then be prioritized and organized into releases.  User Story mapping fosters shared understanding. It helps the team understand the big picture. It is an active process where everyone is involved. It is a pattern for making sense of the whole product or feature and works by breaking down large into smaller and smaller pieces. "we're building a map that lets us tell a really big story about the system".  User Story Mapping involves a hierarchy of: Users Activity - something a User needs to do Task - steps within activity Stories - broken out from Tasks It's arranged in a hierarchy top down, left to right. You could use a tool like Figma (even trello?) or just post its on a white board. The content and the pro

Customizing Okta login flow (messages, controls, logos, bk img, styles and more)

  Here's the Okta Dev Guide to customizing Okta login pages You can customize lots of properties including customizing UI, Email and sms logo, labels including i18n string translations. Okta provides a dashboard to customize flow as well as manage people, workflows etc. logo, background image and theme; easy to customize in Settings -> Appearance emails; in Settings -> Emails & SMS have to edit a version of each email for each language you support and manually enter the text for each country! UI Screens;  Customize in Settings -> Customization.  Includes these flows signin flow (incl mfa flow) mfa setup flow password reset flow account unlock ...but most customizations are done for these pages in css styles and javascript (see below) unlike emails there is no editor where you can edit each page. Instead you have to customize the pages through javascript and css. This is what you'll typically change and how: hide control reposition add controls change text messages

Chrome emulate print mode rendering

 This is pretty cool for debugging and styling print mode css https://developers.google.com/web/tools/chrome-devtools/css/print-preview

css attribute selectors combined as logical AND

Challenge : you need to match a css id that has a stable beginning and end but a middle that could change and you don't have control over it. You could look at using ends with $ attribute selector or starts with ^ attribute selector. Not bad but not necessarily a strong match esp if ending is generic, like '-container' The wildcard is not a good match (pardon the pun) because of how it works, any match in a string versus wildcarding one or more characters in middle Solution : combine attribute selectors When combined like so they function as an AND. Perfect! Combine the starts with and ends with as in "starts with x AND ends with y" e.g. [id^='third-party-'][id$='-container'] this will target classes like so:  ' third-party-*-container' love it Good css tricks article

Performance testing web pages

Image
Performance of web apps is a big topic and has a direct impact on users engagement. Users will simply not wait for, nor use, slow apps (over 50% of users abandon a website which takes more than 3 seconds to load).  Performance is part of the User Experience. What users experience and what it costs to use. As well as direct user experience, large apps also impact users plan bandwidth costs and cpu performance of their device. Performance (aka speed) is not just the time it takes to load an app. It includes loading feedback, time to show useful content when a user can interact with the page and the ongoing experience of using the app. Google in  web.dev identify phases which they call  "core web vitals" which are "loading"                  "interactivity"          "visual stability"   Metrics such as First Paint, First Meaningful Paint and Time to interactive can be used to measure these  "core web vitals".   "core web vitals"

Story points and estimating per Ron Jeffries

Image
 This is simply a great read , pure gold from Ron Jeffries "To me, the important thing in Real Agile is to pick the next few things to do, and do them promptly. The key question is to find the most valuable things to do, and to do them quickly. Doing them quickly comes down to doing small slices of high value, and iterating rapidly" "This makes me think that estimation, be it in points or time, is to be avoided." "we’d work to have a list of the few most important next things to do." I feel we often try to do too much for completeness sakes or other reasons, when we should be ruthless about going after where the value is. Now how do you decide what is valuable? How do you, like a sculptor working on a slab of rock, whittle it down to fine grained pieces? Ron has advice for that too which he calls story slicing: split a larger story into smaller stories  work on the slices that deliver value drop any that don't any value "Every set of requirements

OKRs and Agile process

Does your organization use Objectives and Key Results (OKRs)?  How do OKRs work in an Agile development process? Lets think and blog about this. Objectives and Key Results recap:  an Objective is "a clearly defined goal and 3-5 key results - specific measures used to track the achievement of that goal" - wikipedia A key result must be measurable e.g. %, $, number and easy to answer if it was achieved or not. Objective vs goal? basically the same but Objective has added specificity. But its what you want to achieve Originated at Intel, popularized at Google and now lots of other companies including where I work for years. Objectives are often defined by senior company & product leadership and then cascade down to be decomposed by departments and groups and ultimately teams/squads. Often the Objective is for multiple quarters. A key part of the Agile process is frequent delivery of software (often every day or week), learning from releases and being flexible (agile) to new

cypress 6.0 and cypress-cucumber

  We've used cypress for a couple of years now to write e2e tests for our apps. Recently I have the opportunity to setup an cypress test suite using cypress-cucumber node package which supports gherkin syntax (new for me). These are my notes and learnings. cypress.io created in 2014, written in javascript, first beta 2017 lots of cool features, can view state on each line of cypress tests, api info logged to console wait on apis (no more sleeps or set wait times and flakey timing problems) now up to version 6.5, e.g. route replaced by intercept uses testing tech you're used to describe and it from Mocha and expect from Chai ( see more here ) cypress docs, guides, tutorials, recipes are awesome cypress-cucumber write cypress tests using gherkin syntax (feature, scenario, given when then etc.) which is based on BDD (see below) npm package a way to write, organize and reuse cypress tests BDD  a way for business and technical people to work together to reach a shared understanding