Vasili's Blog

Join us there.

#podcast

For the last couple of days I see a sustained wave of attempted spam inbound. From a very wide variety of IP addresses, so it's not a single compromised VPS somewhere...

Munin graph showing a sudden increase in rejected messages

My mail server is very small, usually it rejects spam 40-60 messages per day, but yesterday it hit just over a thousand...

I'm using mtpolicyd to do Greylisting and Postfix filters out a lot of script-kiddie level non-compliant garbage as well. With additional layers of DKIM, DMARC, and some DNSBL's barely anything ever hits my mail box, thankfully...

I don't have one of those, but we can simply use our hands to make it easier to synchronize audio track to the video track, and also two separate video tracks together...

Clapping to synchronize audio and video

#podcast #production

I'm currently working on cutting Episode 8 of the #podcast and even in the span of these couple of months my production workflow has evolved some. As I'm learning the tool and its capabilities things become more streamlined.

One of the big changes actually happened to the audio. Before I did some prep work in Audacity, but the final mixing and VST plugins were applied in Resolve, however now I do all audio cleanup work in Reaper, bounce it down to a final mix, and then just import it into the project. Mostly because it's easier to have a preset for all the plugin settings in Reaper, maybe I just haven't found a good way to do this in Resolve, but since I still need to use a DAW to trim silences, breathing noises, and other things, it makes it easier to just do all audio-related tasks there. I'll make a post about my Reaper workflow at some point.

Approach 1

So, for instance, in the first couple of episodes I had a video for the animated background that I use, which I got from Pexels. It's only a few seconds long, and originally I had to copy-paste the track back-to-back to achieve a continuous animation.

Approach 2

Later on I came up with a trick in using Fusion, to set the clip to loop internally, and expand the Global In/Out Frames to the max, which also requires creating a Fusion clip of the correct length. You also need to set Hold Frames to 0. Resolve Fusion UI

This worked but required creating a separate track to keep the composition there.

Current Approach

Because I do the keying of the green screen in fusion, you can simply add the clip into the same composition, and just merge it with the output of the keyer. This way you don't need to mess around with new Fusion clips, it's guaranteed to be the correct length, and you don't need a separate track for it.

Fusion composition with Background

I gotta do a better job at updates...

Episode 6

  • Productivity, background music, and Tetris Effect
  • Dopamine, exercise, and carnivore lifestyle
  • Questions you better have answers to if you're starting a company

Episode 7

  • Effects of Remote Work on productivity and how it affects Interviewing
  • Cargo Cults
  • Do better tools make you a better developer?
  • Dress code and erosion of professional standards

#podcast

I've recently upgraded my monitor, going from a very budget 24” Sceptre (1080p resolution at 60Hz) to a Gigabyte M28U monitor, 28”, 4K resolution at 144Hz

The really nice thing about is a built-in KVM switch and a dedicated KVM button, that allows me to switch between by work laptop and my home desktop with a single press (not quite, but I'll expand on that later).

This monitor features three 3.0 USB-A ports for your peripherals, 1 USB 3.0-B port and 1 USB-C port for 2 distinct sources. I've ended up plugging in a USB3 hub, to get an additional port for the webcam, so having 4 would be really nice.

The work laptop (a MacBook Pro) I've plugged in with a single Thunderbolt 40Gbps cable (which was quite expensive for its length, at almost $40 CAD for 2.7'). It carries the video signal to the monitor, and all of the periphery signals back to the laptop, which is an excellent way to de-clutter. Prior to that I had 2 sets of keyboard, mouse, headphones on my desk, and switching setups was getting pretty ridiculous.

The main computer is connected with the USB-B for peripherals and an HDMI cable for video. I wish the monitor had the second USB-C plug, so I could've done the same as with the macbook...

Now I have one mouse, one keyboard, one webcam and a USB headset with mic plugged in and shared between both machines. My desk is de-cluttered quite significantly. The only remaining pain is switching the muscle memory for the Windows vs Mac keyboard shortcuts... (Used to have a mac layout keyboard for the mac specifically).

Desk Photo

Gaming performance is also better, it has FreeSync so that works really well with my Radeon card, and at 144Hz refresh rate the latency is much better. Battlefield 2042 runs at really good framerates even at 4K 144Hz.

About the KVM... The problem with the monitor is that if it doesn't detect signal it switches back to the previous input almost immediately. The counterpart system usually goes to sleep and doesn't produce video signal. And it also takes some time for the USB peripherals to switch over and get online, so I have to press the KVM and then mash the keyboard buttons to wake up the target, so it start outputting video signal for the monitor to pick up... It's not the smoothest, but maybe there's a setting to not try to fallback as aggressively.

  • Effects of sleep on productivity
  • Producing technical content
  • Creator/Audience feedback loops
  • Finding your audience
  • worklifebalance
  • gratitude vs resentment
  • focus and anxiety
  • carnivore lifestyle

The episode can be found here: https://youtu.be/Un-KZYIhXHY

Be sure to subscribe to the channel to get notified about new episodes.

#podcast

At work we are using Contentful as a headless CMS, and also Adobe DAM as an asset storage platform. Both platforms support localization, but we only want to have it enabled in the DAM as that makes the digital production team's life easier.

However some Contentful models ended up having linked DAM assets fields set to localized: true, which means that the content editor team now needs to link the asset essentially twice, so that's not good.

How do we ensure, that all new changes to the Contentful schema are not going to suffer from the same problem?

ESLint no-restricted-syntax rule to the rescue.

Essentially a migration looks like this

function(migration) {
  migration
    .createContentType("coolImageStorage")
    .createField("coolImage", {
      type: "Link",
      linkType: "Entry",
      localized: true, // <- here's what we want to avoid
      validations: [{ linkContentType: "damAsset" }]
    })
}

A following rule can detect when a field is created as a damAsset link, and also has localized set to true.

CallExpression:has(Property[key.name=localized][value.value=true]) Property[key.name=linkContentType]:has(Literal[value=damAsset])

Wire it up into the .eslintrc file as follows:

{
  "rules": {
    "no-restricted-syntax": ["error", {
      "selector": "CallExpression:has(Property[key.name=localized][value.value=true]) Property[key.name=linkContentType]:has(Literal[value=damAsset])",
    "message": "DAM Asset should not be localized"
    }]
  }
}

and marvel at how technology is sometimes able to save us from ourselves.

AST Explorer with babel-eslint parser and ESLint v8 transform can help you poke around at the AST to figure out how to wire up these rules.

#eslint #contentful #astexplorer