HNHacker News
TopNewBestAskShowJobs

andrewmackrodt

251 karma · joined April 1, 2018

submissionscomments
andrewmackrodt··on OpenAI quietly launched Whisper V2 in a GitHub commit
Not OP but regularly access my home network remotely. I have an Asus RT-AX86U which has a lot of features in the stock firmware, including OpenVPN configuration. If I need "LAN" access to my home network, I will open the OpenVPN client and then it will just work, this is useful to access things like local samba shares or SSH into my Linux machines (I was dissatisfied with the log spam of having an open SSH port even with fail2ban and router level protections).

If you have an always running server and only need access via a browser, forwarding port 80/443 to a reverse proxy works well. Dynamic DNS can be used if you don't have a static IP address. Alternatively, if you are more security conscious and don't mind the reliance on CloudFlare, you can use CloudFlare tunnel which won't expose ports from you local network at all. It can also be combined with a third party authentication mechanism.

andrewmackrodt··on Ask HN: FFmpeg real-time desktop streaming
I would also recommend OBS as another commentator has mentioned. I believe in both cases you will need an RTSP server to handle multiple client connections.

I looked into a similar ffmpeg solution a couple of months ago and broadcast an libx264 video only stream with ~1 second latency to an rtsp server: https://gist.github.com/andrewmackrodt/88c2233fb9cc4797ada93...

However, I found this solution to be too CPU intensive as I was unsure if/how to instruct x11grab to interact with the GPU directly. Perhaps if I used my nvidia card for encoding it would have been more performant. However, OBS makes this entire process much easier.

andrewmackrodt··on Ask HN: How influential can physical appearance be in professional environments?
I would imagine you have some concept of this, for many, symmetrical features is attractive. There are other more obvious factors too, e.g. a chubby face (typically due to high body fat percentage) would be seen as less healthy/desirable/attractive.

Attractiveness describes the perception of success (friendships, health, career etc) based on physical appearance and the likelihood of passing these traits to offspring.

andrewmackrodt··on Some statistics about BTRFS compression
I'm using btrfs for the first time (Ubuntu 22.04) and noticed that the performance is hugely reduced versus ext4, especially in kernels prior to 5.17. This was most evident installing papiris-icon-theme; there was a bug/inefficiency in how btrfs handles lots of files in the same directory. This has been fixed in 5.17, and while still slower than ext4 overall, for day-to-day usage (developer and gaming via steam/proton) I will stick with it for the ability to create snapshots.
andrewmackrodt··on BlueJ – A Lightweight Java IDE
We were recommended to use this during our first year of university (2006), Michael was a lecturer so the university must have felt BlueJ a useful introductory programming tool.

Personally I struggled to get to grips with it. While I can appreciate it tries to visualize foundational OOP principles, for someone who already had some experience with various (mainly web programming languages), BlueJ felt too limiting but also broke my mental model of what I should be doing.

If I were to think of it more as an interactive debugger, then maybe I would have had more favourable memories of it. However, a few weeks later I switched to Netbeans and felt far less anxiety that I didn't belong in my course.

andrewmackrodt··on Former Microsoft director of user experience trashes Windows 11 Start menu
I wonder which Linux DE environment you will be using, KDE? I find Gnome's changes to be more unnecessary than Windows, e.g. Gnome 42 defaults to overview on login.

Overall, I find Gnome to at least be more consistent than Windows and no adverts in the activities/applications menus are of course appreciated. However, every major release tends to force the user to relearn certain how to use your desktop principals.

andrewmackrodt··on I turned my iPad Pro into my main computer (2021)
Xbox Cloud is quite useable, Dirt 5 for example impressed me in regards to latency but I found it to be too high for Forza Horizon 5 to be enjoyable. I've found RPGs to be a good fit, e.g Dragon Age Inquisition and Yakuza 0.
andrewmackrodt··on New XPS 13 Shows the Price of Going Too Thin
Not sure if something like this would work on non Apple hardware: Satechi 4-Port USB-C Hub - https://amzn.eu/d/6a85dgf

I have a Dell XPS 2in1 from 2019 which only has 2 USB-C ports, however, I'm using a thunderbolt dock so I get a USB-C port back and a USB-C display port output on the back, have never tried connecting a device to it to though.

Anker also have some hubs with one USB-C input and one PD.

andrewmackrodt··on Deluge BitTorrent Client
I've been running deluge in Linux since 2019 (version 2.0+, so considerably newer than the bug report) and it appeared to have been using my SOCKS5 proxy settings correctly; I had applied some extra hardening such as disabling natpmp etc, although I'm not sure if those are required.

However I don't doubt that these kind of leaks could have happened depending on configuration / bugs etc.

Eventually I ended up changing my configuration to run deluge in a VPN container (docker) network namespace so that I could use VPN port forwarding for better speeds (supported by Mullvad).

andrewmackrodt··on Paginating Requests in APIs (2020)
I haven't had a need to implement this but something like the following should work to provide the same* records regardless of insertion/deletion.

* data of the record may have been updated, but if there are 1,000 records total, paginating in either direction will always return those same 1,000 records regardless of insertion/deletion.

- Filter by created_at <= time the endpoint first returned a result.

- Utilize soft deletes, where deleted_at IS NULL OR deleted_at < time the endpoint first returned a result.

Any keys allowed to be used in the ORDER BY query should also be immutable.

andrewmackrodt··on Paginating Requests in APIs (2020)
You can do something like the following in application code.

Imagine a table with the following schema/data: id=1,created_at='2022-28-05T18:00Z' id=2,created_at='2022-28-05T18:00Z' id=3,created_at='2022-28-05T18:00Z'

To retrieve articles in order of descending creation time, our sort order would be: created_at DESC, id DESC

The last item in the ORDER BY query should be a unique key to ensure we have consistent ordering across multiple queries. We must also ensure all supported sort columns have an INDEX for performance reasons.

Assume our application returns one article at a time, we have already retrieved the first article in the result set. Our cursor must include information for that last records ORDER BY values, e.g. serialize('2022-28-05T18:00Z,3'), for example purposes I will use base64, so our cursor is MjAyMi0yOC0wNVQxODowMFosMw==.

When the user requests the next set of results, they will supply the cursor and it will be used to construct a WHERE (AND) expression: created_at < '2022-28-05T18:00Z' OR (created_at = '2022-28-05T18:00Z' AND id < 3)

So our query for the next set of results would be: SELECT * FROM articles WHERE (created_at < '2022-28-05T18:00Z' OR (created_at = '2022-28-05T18:00Z' AND id < 3) ORDER BY created_at DESC, id DESC LIMIT 1

For queries with more than 2 sort columns the WHERE expression will slightly increase in complexity but it need only be implemented once. If the sort order direction is flipped, make sure to adjust the comparator appropriately, e.g. for 'DESC' use '<' and for 'ASC' use '>'.

andrewmackrodt··on FTC fines Twitter $150M for using 2FA phone numbers for ad targeting
As with most (all?) Android apps, support for permission requires user consent; Camera, "Files and media" and Location are all set to "Not allowed" on my device. From what I can tell based on Microsoft's help page, location may be a requirement of a work/school account and as far as I can remember, I've never been prompted for the location permission - it's possible I denied access if I was, but the app works without it.

From Microsoft's Authenticator help page:

"You will see a prompt from Microsoft Authenticator asking for access to your location if your IT admin has created a policy requiring you to share your GPS location before you are allowed to access specific resources"

https://support.microsoft.com/en-us/account-billing/common-q...

andrewmackrodt··on FTC fines Twitter $150M for using 2FA phone numbers for ad targeting
Are you using Microsoft Authenticator in a corporate environment/profile? I just checked my personal install (Android) and it does not require any permissions (location is denied).
andrewmackrodt··on Behold GoldenEye 007 with four screens – dream come true or travesty?
In the default layout the analogue stick controlled forward and backward movement and turning left or right. The yellow c buttons could be used for strafing or adjusting the vertical "aim" (the game heavily relied on autoaim). It was also possible to use the R trigger to enter an aiming mode where the analogue acts like the left stick would in modern FPS.
andrewmackrodt··on More PCs Running Windows XP, 7, and 8 Than Windows 11
WSLG supports faux GPU passthrough/sharing with the host, e.g. for CUDA workloads or graphics acceleration from within the WSL environment.
andrewmackrodt··on Is the DTS vs. Dolby war effectively over?
As mentioned in another comment, Windows Sonic is the default spatial implementation provided with Windows by default. There are also paid Dolby Atmos and DTS plugins available through the Microsoft Store where licenses may be included dependent on your hardware or OEM, e.g. my Logitech Gaming Pro X includes a license for the DTS plugin.

Personally I do like the Dolby Atmos plugin, I have my computer connected to a TV with sound passed via eARC to my soundbar. However, if you're consuming Film/TV with such a setup, you probably just want to enable Dolby/DTS passthrough instead.

andrewmackrodt··on OBS Plugin: Background Removal
This looks cool, being both free and cross platform.

A non free (4 hours free a month) solution I quite like on macOS is krisp.ai which I also use for noise removal. Background replacement was recently added to M1 chips.

On the Windows side, Nvidia Broadcast has worked well for me (requires an RTX card), it also supports tracking which I really like. I've previously tried XSplit but the results were worse than whatever implementation Zoom and even Hangouts in a browser use.

I rarely video call under Linux (non existent laptop drivers for my webcam) but look forward to trying this out if the need ever arises.

andrewmackrodt··on I have no capslock and I must scream
This annoys me too, but since starting work at a company which uses single sign on, it's started to make sense why certain sites have this pattern, e.g. if your login is an email address and the domain is enrolled to handle sign on outside of the service, you are redirected and the original website doesn't have the ability to capture your password.

For personal use, I find 1Password typically handles multiple screen logins, including 2FA quite well, although requires an extra UI interaction.

andrewmackrodt··on Show HN: A daily math puzzle inspired by Wordle
Nice job, reminds me of the countdown numbers game with a twist of wordle.
andrewmackrodt··on How to Squash and Rebase in Git
I use rerere on all git installations, it's a massive time saver. On the very rare occasion I do want to squash a single commit onto the branch HEAD, I use the same workflow as yourself. Using rebase for that workflow as described in the article isn't necessary IMO.

For anyone wondering what that command would look like:

git fetch

git merge origin/main

git reset --soft origin/main

git commit -m 'HN-1337 Awesome new feature'

andrewmackrodt··on DaedalOS: Desktop Environment in the Browser
There's also the Broadway GTK backend https://docs.gtk.org/gtk3/broadway.html
andrewmackrodt··on Linux Touchpad Like MacBook Update: Touchpad Gestures Now Shipping
I'm primarily a Ubuntu user but I there are certain design elements of macOS that I appreciate. It's a common theme in reddit for users to post the desktop environments with a macOS skin and state no reason to use a mac now - but the workflow differences extend far beyond the look of an empty desktop with no windows open.

When working portably, macOS is my preferred OS.

I'm not sure about KDE, but Gnome's experience is severely degraded when outputting to an external monitor with different display scaling. Without Wayland there is horrendous screen tearing but pipewire isn't trivial to install which makes screen sharing while WFH problematic. Intel WiFi drivers are a hot mess. There are numerous other QoL differences.

While Gnome supports dynamic workspaces, the workflow is very keyboard based and without Wayland gestures aren't native (e.g. smooth scrolling between workspaces) - AFAIK the only solution is to emulate keyboard shortcuts which is quite jarring given a decade plus of having super responsive smartphones - but Wayland without pipewire is problematic for screensharing, etc ..

andrewmackrodt··on Linux Touchpad Like MacBook Update: Touchpad Gestures Now Shipping
There's more to macOS than look of the desktop, notably the universal menu and full screen mode opens to a new workspace. I find the latter a big productivity boost when working on an undocked laptop as the gestures to switch workspace or windows between an application are so well integrated.
andrewmackrodt··on Vinegar: Safari extension that replaces YouTube embeds with HTML5 video tags
Hmm, this doesn't work for me in the app in Android 10 or 11. Perhaps it is region specific? I'm in the UK.

Edit: it does work via browser if you navigate out of fullscreen. TIL :)

andrewmackrodt··on Vinegar: Safari extension that replaces YouTube embeds with HTML5 video tags
The YouTube app on Android only supports picture in picture and background play (screen off) with premium; I imagine the iOS app is similar.
andrewmackrodt··on A Gov.uk site dedicated to porn?
I used to browse lowendbox which occasionally has good deals from smaller companies who've been around for at least a few years but there's always a risk one day they'll sell, shut down operations or worse just disappear. However, if budget is your number one priority, you can get a years VPS hosting for low double digit dollars a year.

Nowadays a host personal projects on scaleway and netcup (EU based). I've been with the first for a could of years and the second for 6 months now, good service from both.

If you're mainly hosting static* or cacheable content, you may even get by with a raspberry pi running behind cloudflare's free plan with cache enabled. If you don't mind all traffic to your site being served by such a third party of course.

* If you only have static content, GitHub pages can be considered too.

andrewmackrodt··on What's the Future of IDEs?
JetBrains have recently released a new project (JetBrains Gateway) which is worth a look at too https://www.jetbrains.com/help/idea/2021.3/remote-developmen...
andrewmackrodt··on $ sudo rm -rf / === NPM install
A lesson I learnt several years ago when I discovered that mktemp behaves differently on macOS versus the GNU version in Linux.

From that day onward I always make sure the first line of my bash scripts contains at least "set -e".

andrewmackrodt··on Google DNS at 010.010.010.010
I agree with these points although going back to the grandparent comment, the value of being able to show the source code of a controller with these frameworks by appending a query string is close to zero.
andrewmackrodt··on Quickemu: Quickly create and run optimised Win-10,11/macOS/Linux on Linux
FWIW I use my Windows 10 Pro (VLK) license on my gaming PC, and as a virtual machine when using Linux. It's undergone 3 activations, initially for the desktop, once when I was using VirtualBox and the last when I converted my VDI to VMDK when I migrated to VMware. All activations were several months apart however.

Windows activation servers were happy enough with that, without any install becoming unactivated (other than the VirtualBox to VMware conversion which is the 3rd activation).

While you can use Windows unactivated but it restricts access to various settings, which may not be important to you depending on your use case.

← PreviousPage 2 of 5Next →