Saturday, July 4, 2026

Shokz Bone Transmission Headset - Annoying Low Battery Warning

 Managers should NEVER be allowed to specify product features.  I'm assuming this particular product feature came from a manager's desk somewhere.

The Shokz bone transmission headset, when its battery gets low, instead of just powering off to preserve the remaining charge in the battery, starts announcing every 5 minutes "Charge me."  The irony is that this "feature" is probably only active when the headset is on standby (no active audio), and the periodic announcement assuredly runs the battery completely dead EVEN FASTER!!

I'm partly posting this to possibly help someone figure out what ANNOYING device is emitting this sound that is obviously words, instead of a beep, but it would be nearly impossible to understand what words unless the headset is actually on your head.  The other part of this post is a desperate plea to legitimate product designers to stand up to your managers and reject their horrible design ideas.

The fact that it only emits this vague sound every 5 minutes, makes it VERY time consuming to narrow down which device is emitting the sound (of the dozens or hundreds that might be lying around in a typical home these days).  The manager who suggested this design must have been taking a page from the smoke detector "beep every minute, starting at 3am, but give NO other indication like a flashing LED" design play-book.

After finally locating which stupid device was making this sound, I amused my wife by responding to its "Charge me." with "Maybe I'll just throw you in the trash instead, you piece of !@#$."

Anyway... just adding to the "noise" a web search gives back when someone searches for some of the keywords I've tried to intentionally include here, and maybe save someone a few 5-minute rounds of searching, when it's obviously NOT the AnnoyingPCB cricket prank, but a non-prank product that is designed to be just as annoying.

Wednesday, May 1, 2024

Twilio Trial Accounts are Useless

This post is an attempt to save someone from wasting a lot of time setting up a Twilio trial account in hopes of using it for development or low-volume personal reasons.  With the restrictions on different number types, and the requirements for different registrations or verifications, the trial account, at least for use in the US, is little more than a bait and switch to a paid account.  So, IMO, just save yourself the hassle and leave Twilio for the SMS spammers and big corporations.

There are numerous tutorials, youtube videos, and forum posts that suggest you should be able to register a trial account and use it for development / hobbyist purposes.  Those are apparently mostly obsolete.  

Currently you can:

  • Register a login
  • Create a trial "account" within that login.
  • "Purchase" a phone number with the trial account.
  • Get the credentials (API Key or Auth Token), and
  • Call the API to (try to) send an SMS message.

Then (eventually) find out that the SMS message cannot be delivered, even to a "verified" number, if...

  • The phone number you "purchased" wasn't a toll free number.  Non-toll-free numbers require an A2P 10DLC "campaign" before sending SMS messages is possible. 
    • You can't set up an A2P 10DLC without upgrading from the trial account.
  • You "purchased" a toll-free number but you don't have some kind of business set up already for verification of the toll-free number.
    • That's probably not the case for a hobby/personal/"see how it works" scenario.

I spent several hours trying to navigate Twilio's vague, confusing, incoherent documentation before giving up and opening a ticket with their technical support.  The answer I got from tech support confirmed that there basically isn't a way to use Twilio without upgrading and/or linking it to an established business.  

The "trial" account is effectively a "bait and switch."

Hope this saves someone the hours of time they would waste trying to see how Twilio works.  Hope Twilio realizes that when someone like me, a professional software engineer, has this kind of experience with their (lack of) service, the net result is an ongoing strong recommendation AGAINST using Twilio.

IMO, the tactic of suggesting that something would be free for personal / hobbyist use, even for a limited time, when that is absolutely false, is misleading and dishonest.  If there is ANY alternative, I refuse to engage with such a company. I plan to enthusiastically steer any project I'm working on far away from Twilio

Thursday, February 15, 2024

n8n MongoDB Node - "insert"

This might be the first of several "missing manual" posts for n8n.  The product itself is amazing, but the documentation, and sometimes even the related forum posts are miserably lacking.  This one is about the MongoDB "insert" function.  It should be straightforward and easy, but it does NOT work like you would expect.  If you mouse-hover over the question-mark icons on each input field in the editor form, it helps a little, but still might get you past "trial and error" mode.

What the Docs COULD Say

The value of the "Fields" input must be a comma-separated list of attribute names from the root level of one item in the input data for the node.  For example, if the input data contained this:

[
  {
    "name": "Bob"
    "address": {
      "street": "123 Main St",
      "city": "Lincoln",
      "state": "NE",
      "zip": "68516"
    },
    "age": 42
  },
  {
    "name": "Susan"
    "address": {
      "street": "456 Smith Ave",
      "city": "Springfield",
      "state": "IL",
      "zip": "62704"
    },
    "age": 38
  }
]

...then the MongoDB node insert "Fields" could be...

name, age

 ...and 2 JSON objects (without "address": "value" attributes) would be inserted into the specified collection in MongoDB.

Option: "Use dot notation" (Select/add, then enable)

  • Allows nested attributes to be selected as an included field (excluding peer attributes in the sub-object).
  • This does NOT flatten the structure, but filters which nested fields get included
  • For example, field list could be:

name, age, address.zip

Option: "Date Fields"

  • This is a second comma-separated list field names, but these get converted to MongoDB BSON date values in the inserted object... if you need that for some reason.

 Other notes:

  • Whitespace between fields in the comma separated list of field names will be ignored.
  • If dot notation is specified as a field name without the "Use dot notation" option enabled, the output will most likely include a null attribute like: "somenestedthing.someattribute": null

The Actual "Docs" (Barely)

https://docs.n8n.io/integrations/builtin/app-nodes/n8n-nodes-base.mongodb/

As of 2/2024, this doesn't tell you much of anything.  If it were the owner's manual for a car, it wouldn't give you much past:  Up to 4 people can fit in it.  It goes.  Hopefully it also stops.

Forums

  • Subject: "Insert JSON data to MongoDB inserting empty values"
    • https://community.n8n.io/t/insert-json-data-to-mongodb-inserting-empty-values/24594
    • This post asks why a single JSON document can't just be inserted into MongoDB as is.
    • The answer runs off in the weeds with some nonsense about splitting things into fields.
  • Subject:  "MongoDB Insert key/value formatting"
    • https://community.n8n.io/t/mongodb-insert-key-value-formatting/4948
    • This post is again from someone confused that the input for a MongoDB insert isn't some sort of reference to both Keys and Values (like a whole JSON document... e.g. $json)
    • The answer is a link to some set of examples that seems completely unrelated.
  • Subject: "MongoDB insert data?"
    • https://community.n8n.io/t/mongodb-insert-data/192
    • This might have been asked before the MongoDB built in node/integration was added.
    • The answer mentions the "new" integration node, but still doesn't explain how to use it.
  • Subject: "How to use the “function node” with a “set node” and a “mongodb insert” in combination?"
    • https://community.n8n.io/t/how-to-use-the-function-node-with-a-set-node-and-a-mongodb-insert-in-combination/21059
    • This SHOULD be included in a search for "fields.split is not a function", but that important bit of text is buried in a screen shot.
    • The answer to the problem most people seem to be having is here if you look carefully, but its one of those things you probably see only after you've figured it out anyway.
  • Subject: "How to insert properly data in mongoDB?"
    • https://community.n8n.io/t/how-to-insert-properly-data-in-mongodb/4052
    • Yet another cry for help, because there is no explanation of how this node works.
    • The replies don't help, and the topic is locked (which is why I'm writing here instead of answering there, btw.)



Saturday, January 27, 2024

IP Masquerading with nftables

Why this is here

I realize I'm sorta late to the game writing this, but then I JUST finished sifting through all the half-a$$'d documentation and examples I could find on the topic and NOT ONE of them offered a clear explanation of what is going on with nftables, and what the parts of a masquerading setup mean.  So here I am, hoping I can do a better job, because I'm gonna forget how this works, and probably come back here later and want me to explain it to future-me.

My other motivation for putting this here is to get feedback in comments in case I don't have some part of this quite right.  If you see something here that is just wrong, please let me know.

The Task

Set up a Linux machine, to forward traffic coming in one network interface, to any of the hosts in the network to which another network interface is attached, on any port.

My reason for doing this was that I had a new Wifi router, that I wanted to set up from my workstation, but my workstation was still connected to the "old" router.  I knew one option would be to create ssh tunnels to forward specific ports to the new router's LAN ip, but that meant opening a terminal and connecting / logging-in with the ssh command every time I wanted to open the router's web interface.  It also meant I'd have to set up one or more port-forwards to reach/test/reconfigure each device as I moved them.  That got tedious fast.

The Plan

I had a Raspberry Pi ZeroW that I had used for some forgotten thing a while back, and it was just sitting there in a box, gathering dust, begging to be made into a mini-nat-bridge/router between my current (old) network and the new one.  So, I searched for stuff like "nat" and "masquerade" and "iptables" because I remember it not being too difficult to get that exact thing working in an older version of Linux.  I even had it working once on a coax network with an old 386 machine running RedHat 2 (or something like that), using ipchains.  (That was so my wife and I could share our dialup connection to Mindspring instead of taking turns... boy those weren't the days).  But, after I installed the latest (Bookworm) Raspberry Pi OS, booted up the pi, connected it to the (old) network, and entered the iptables command, when I saw the dreaded: "command not found", I knew this was a new rabbit hole I had just jumped down.

The New Thing

Shifting my search strategy to things like "what replaced iptables" and "how do you set up masquerading now," I found that NetFilter has moved (or is nearly moved) from iptables to nftables.  I knew from experience that any time there's a subtle name change on something in Linux, right behind that I'll find a drastically different way of doing everything.  nftables didn't disappoint.  Instead of pre-established chains to which you inject your own rules, you now need to create a hierarchical table that contains its own set of chains, and each of those contains its own set of rules.  In a nutshell: 

  • Tables belong to a family that designates what subset of traffic it affects (ipv4, arp, ipv6, etc): https://wiki.nftables.org/wiki-nftables/index.php/Nftables_families
  • Chains are in a table, and belong to a type (filter, route, or nat), and are associated with a set of hooks that map to the part of the packet handling lifecycle related to the type - e.g. nat has hooks like prerouting and forward.
  • Rules are in a Chain, and describe something to be done with a packet.

This wiki page expands upon that "bootstrap view" a little: https://wiki.nftables.org/wiki-nftables/index.php/Quick_reference-nftables_in_10_minutes

How Does NAT Masquerading Work?

Before getting into how to set up nftables for NAT with masquerading, it is helpful to remember what is happening, so:

  • First, some other machine sends packets to the "inbound" network interface that are not destined for the machine that "owns" that interface.  This is typically done with a static route on the machine originating those packets, which is treating that interface as if it is part of a router.
  • If the machine receiving those "not for me" packets has packet-forwarding enabled, it will just send packets along, through whatever "outbound" network interface it would normally choose if it was originating those packets itself.  However, since it doesn't do anything to the fix the return IP address or source port number in those packets, the host that receives them next probably has no idea where to send its response packets, and the round-trip breaks.
  • Masquerading dynamically changes the source IP (to the "outbound" interface's IP) and port (to something it generates and keeps track of) so it can receive and re-route response packets back to the originating source IP and port.
    • Note SNAT is a variation on this same concept, but does not figure out what the "outbound" IP should be.  A SNAT setup depends on a specified, fixed "outbound" IP, which allows it to perform a bit better.

How the nftables Pieces Fit

To eliminate ambiguity between stand-in variables and actual values, this example assumes the following:

  • The machine has two network interfaces (because it needs at least two physically separate connections)
    • "inbound" connection is
      • on network 192.168.5.0/24
      • on an interface named "wlan0"
    • "outbound" connection is
      • on network 192.168.200.0.0/24
      • on an interface named "eth0"
  • The table needs a name, so we'll name it "nat_all_to_network2"
  • Chains can have names, but they'll be named unimaginatively with a shortened form of the hook they reference (e.g. hook prerouting chain will be "pre_rt"
The nft command is used to create tables, chains, and rules.
  • Note: Using the nft command in some circumstances relies on terminating argument/parameter (e.g. -a, -x, etc.) parsing before passing a negative number (e.g. -50).  You will see where that is needed below.
    • In bash at least any dash in the command line, after a double dash ("--") will be parsed as a literal value instead of a parameter - e.g.:  nft -- add ... priority -100
    • https://www.man7.org/linux/man-pages/man1/bash.1.html

Creating the Table

In nftables, a table contains a set of related chains, so that's the first required part.
  • Syntax: nft [command] [object_type] [family] [table_name]
  • Command: nft add table ip nat_all_to_network2
Note: The "ip" family means this rule only affects ipv4 packets.  "inet" would include ipv6 too.
Note: Commands to add chains and rules do not need to repeat the [family] part.

Adding Chains

Getting the table to process the right packets needs two chains which hook into prerouting and postrouting phases of packet handling with a chain type of "nat" (which means it only really examines the first packet of a connection to decide what to do with all of the packets that follow).
Note: Other hook types like "filter" continue evaluating each individual packet.
  • Syntax: nft [command] [object_type] [table_name] { type [chain_type] hook [hook_phase] priority [priority_value] ; }
  • Command (prerouting): nft -- add chain nat_all_to_network2 pre_rt { type nat hook prerouting priority -100 \; }
  • Command (postrouting): nft add chain nat_all_to_network2 post_rt { type nat hook postrouting priority 100 \; }
Note: The semicolon must be escaped so the shell/terminal won't treat it as a multiple-command-separator.
Note: The -100 and 100 priority values map to "special" values named dstnat and srcnat, respectively, which is how they appear when the table is viewed with nft list ruleset
For information overload about this, see: https://wiki.nftables.org/wiki-nftables/index.php/Netfilter_hooks

Adding Rules

The final part of setting up the table is to specify the circumstances when a packet should be evaluated, and what to do with it if it matches various attributes.
The prerouting chain needs a rule that limits the table to evaluate and process only packets coming from the inbound interface
  •  nft add rule nat_all_to_iot_network pre_rt iifname "wlan0"
The postrouting chain needs a rule that tells it to set up masquerading for packets that are being routed to the "outbound" interface.
  • nft add rule nat_all_to_iot_network post_rt oifname "eth0" masquerade

Blocking Reverse Traffic

When the default table in /etc/nftables.conf is loaded, there is a table for the inet family, named "filter", containing chains for input, forward, and output hooks.  To prevent any host on the outbound side from forwarding packets to hosts on the inbound side, add a few rules to the forward chain in this table.

First be sure the return packets from connections forwarded and masqueraded to the outbound side are still forwarded back.
  • nft add rule inet filter forward ct state {established, related} accept
Next drop any packets originating on the outbound side, destined for the inbound side.
  • nft add rule inet filter forward iifname "eth0" oifname "wlan0" drop
Packets that don't match one of those rules default to the chain's "policy accept"

Switching it On

None of this will do anything unless packet forwarding is turned on.
To enable forwarding until the next reboot:
  • sysctl -w net.ipv4.ip_forward=1
To make this permanent across reboots, edit /etc/sysctl.conf and add (probably just uncomment)
  • net.ipv4.ip_forward = 1
To reload the config immediately (to see if everything is set for a reboot), enter commands:
  • sysctl -p  (to reload)
  • sysctl net.ipv4.ip_forward  (to check resulting setting)

Persisting for the Next Boot

After following these directions and testing to be sure packet forwarding is working as expected, the table, chains and rules are just in volatile memory and will vanish upon reboot.  

To persist a table, so it is re-activated every time the system starts, it needs to be added to /etc/nftables.conf.  The format of the tables in the config file is approximately the same as the output of the nft list ruleset command.
  • Note: Special-value priorities displayed in the nft list ruleset command output are shown with their names (e.g. dstnat instead of -100,  and srcnat instead of 100).  nftables.conf must have the numeric values, since it doesn't seem to have a mapping from the names back to their numeric equivalents.
  • Note: Many tutorials found on the internet set up the initial rules locked to a particular network interface using iif and oif.  From the ntf command-line, the interface names seem to be translated into their index values, but in nftables.conf, values like eth0 and wlan0 are actually iifname or oifname, so it is better to set up the rules using those attributes to begin with.
    • See comment on Nov 6, 2023 here: https://superuser.com/questions/1815386/internet-connection-activ-only-after-restart-of-nftables






Friday, December 22, 2023

OpenWRT, dnsmasq, dhcp, static mappings, but No DNS Resolution

The Problem

After poking around WAYYYYY too long to connect these dots, I finally have a reasonable explanation for why dnsmasq, running on on OpenWRT, absolutely refused to resolve an IP address from a hostname that was configured, in DHCP, with an IP for a specific client mac address.  The client machine was online, and reachable by that IP.

TL/DR

dnsmasq only resolves names from DHCP active leases, not from DHCP config.  (Read on if you need to know how to check, how to fix, etc.)

The circumstances were:

  • ip/name configured in DHCP for client machines mac address (as mentioned already).
  • client machine hostname configured to match the name also assigned by DHCP
  • client machine (linux) had been rebooted, after configuring DHCP and hostname
  • command dhclient -r issued repeatedly on the client machine
  • interface, domain, etc. set to "lan"
  • ipv6 disabled (just in case it was making things more complicated).
  • ping and nslookup from a different machine received NXDOMAIN response from dnsmasq/openwrt

Extra Circumstances (that didn't seem relevant, but were):

  • client machine had unexpired, cached DHCP lease info in /var/lib/dhcp/dhclient.eth0.leases
  • openwrt dhcp did NOT have an active lease registered in /tmp/dhcp.leases
  • dnsmasq had been restarted, the entire openwrt router had been restarted, and several updates had been "Saved and Applied" via LuCI.  This probably meant that any DHCP in-memory name:ip mappings were gone.

What fixed it?

On the client/host machine that can't be resolved/found by name...
  1. Delete /var/lib/dhcp/dhclient*.leases
  2. Reboot (because dhclient -r eth0 didn't help).

Verification

  1. Check that ping and nslookup now work as expected from other clients for the previously (let's hope) unresolvable hostname.
  2. Check that openwrt /tmp/dhcp.leases DOES now include a line for the recently, forcibly-renewed DHCP lease.

Explanation:

openwrt runs dnsmasq with a configuration that references the /tmp/dhcp.leases file.  
  • The setting is found on the Network - DHCP and DNS page in LuCI, on the Resolv and Hosts Files "tab" in the Leasefile field.
  • The setting is found in the /etc/config/dhcp file in the config dnsmasq section as option leasefile '/tmp/dhcp.leases'
    • See: https://openwrt.org/docs/guide-user/base-system/dhcp
    • This says: "leasefile stores leases in a file so they can be picked up again if dnsmasq is restarted."
    


Monday, December 18, 2023

Gogs: Internal Error from "git push"

This might have been fixed in Gogs, and maybe it just got me because I'm just running an older version, but I think it's worth a quick post here anyway...

Problem

Pushing a git repository to a remote hosted in Gogs... with ssh config, etc. all as it should be... results in:

me@myworkstation#:~/mylocalgitclonedir $ git push

Gogs: Internal error

fatal: Could not read from remote repository.


Please make sure you have the correct access rights

and the repository exists.

Cause

It turned out to be root:root ownership of the xorm.log file on the Gogs server.

In my case, running in a docker container, that was /app/gogs/log/xorm.log

This might be related: https://github.com/gogs/gogs/issues/4990

Don't know how this got changed in my particular setup... yet.  Maybe a backup or log rotation hiccup.

So, the cause was not: (including some of this for searchability of this article)

  • repository write permissions for user
  • SSH config on server or client
    • i.e. not an ssh client known_hosts error
    • i.e. not related to private key file permissions on the client
    • i.e. not using the wrong private key for the registered public key in gogs
    • checked with command:  ssh -v -T git@mygogshost

Solution

Open a terminal on the gogs host, and...

sudo chown git:git /app/gogs/log/xorm.log

After that git push worked fine again.

References

  • https://github.com/gogs/gogs/issues/4990

Tuesday, December 5, 2023

HomeAdvisor.com Password Reset

This info is current as of Dec 5, 2023, so if you're reading this later, and that was ages ago, it's not likely to be correct still.  So, with that said...

I just had the "wonderful" experience of trying to get logged in to HomeAdvisor.com on a mobile browser after initiating an account from a desktop web browser.

Their "clever" scheme to use a temporary login link, sent to an email address, instead of a password, makes it impossible to CHANGE your password once you are logged in, because you might have NEVER SET a password.  The "Forgot Password" link just sends you the non-password login link again... which is just another trip around their endless loop.

Called customer support and described the issue, and they just hung up on me, which might be an indication of whether you'd even want to work with HomeAdvisor/Angi in the first place.

The only way I could get out of the "catch 22" they created on the HomeAdvisor.com site, was to guess that maybe all of the the accounts are wired into the same place as Angi.com.  So, if you go to Angi.com's login page:  https://www.angi.com/login , you'll find a "Forgot Password? link that still goes to another page, which asks for your email address (i.e. login id), and actually sends you a link to reset your password on angi.com.  Magically, that ALSO sets your password on HomeAdvisor.com.

Since the idiots in customer support can't be bothered to help anyone figure out the !@#$% mess they've made of the logins between HomeAdvisor.com and Angi.com, I hope this helps, at least until they fix it, or (more likely) make it into an even bigger mess.

Friday, October 13, 2023

Legacy NVIDIA Driver for Ubuntu 20.04+

Summary

Either because an upgrade wrecked a working Linux install, or because the default drivers aren't performing very well, it may be necessary to install NVIDIA drivers for very old, "legacy" hardware on Ubuntu, or a similar Linux distribution.  This post is meant to help get that done without burning as much time searching for the right information and putting all the pieces together.

Symptoms

  • After an update / upgrade, Linux stalls mid-boot with a black screen and a blinking text cursor in the upper left corner.
  • Linux installed on a machine with older / legacy NVIDIA hardware is running too slow to be usable, and the graphics driver is suspected as the cause.

Elements of the Problem

  • Recent versions of Ubuntu install a kernel version that is no longer compatible with older NVIDIA drivers.
  • The default, generic driver doesn't perform very well (or at all) with older NVIDIA graphics card hardware.

Getting to a Terminal

When/if the X-Window / GUI Startup failed and stopped the bootup, it may be necessary to switch to another tty/terminal.  There are typically several of them started with Linux, and they can be accessed using CTRL+ALT+F2 (or F3, F4, ...).  From the blank / black screen with the blinking cursor, use that key combo to switch over and directly log-in to a terminal / tty, where the commands below can be executed.

Diagnostic Steps

  • Verify old NVIDIA hardware
    • Command:   sudo lspci | grep VGA
      • Should display information about the NVIDIA hardware (e.g. GeForce 9600M GT)
  • Verify old, no longer working, NVIDIA driver version is installed - (e.g. 340.108)
    • Command: dkms status
    • Command: apt list --installed | grep nvidia
      • Should show the NVIDIA driver package version (e.g. nvidia-340 ... 340.108)
  • Verify NVIDIA driver is malfunctioning
    • Command: nvidia-smi
      • Should report a failure to communicate with graphics hardware.
  • Check NVIDIA settings
    • Command: nvidia-settings
      • May report config errors, etc. and/or other useful info.

Elements of the Solution

  • Add the PPA repository from user kelebek333 which contains a version of the NVIDIA drivers that has been patched to work with newer kernel versions.
    • See: https://launchpad.net/~kelebek333/+archive/ubuntu/nvidia-legacy
    • Command: sudo add-apt-repository ppa:kelebek333/nvidia-legacy
  • Run command: sudo apt-get update
    • This should report that one or more packages (which include patched NVIDIA driver) are upgradable.
      • Verify w/ command: apt list --upgradable
  • Run command: sudo apt upgrade nvidia-340
    • This may report that there is a public key missing.  If so, run the following command replacing {key-value} with the key that is reported in the error message from apt upgrade...
      • Command: sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys {key-value}
  • Reboot - If this resolved the NVIDIA driver issues, the X Window system should start normally again.

Tuesday, November 29, 2022

Docker "exec format error"

Overview

Occasionally, for a variety of reasons, a Docker container won't start, and the only clue is a cryptic message that says something like this:

standard_init_linux.go:178: exec user process caused "exec format error"

I'm aware that there are numerous related forum posts to be found via web search with a collection of right, wrong, confusing, and sometimes tediously wordy responses.  This is just an attempt to cut through some of that and cover only the non-wild-goose-chase stuff, not to take credit for any of it.  If any of this ended up worded similarly to something else, it's purely coincidence.

Cause #1 - Missing "shebang" in Shell Script

Sometimes, this is related to an improperly authored shell script, serving as the entrypoint for the container image, and the solution is to add the required "shebang" (#!/bin/sh) line at the top of the shell script.

Troubleshooting

  1. Run the image as a "shell" container and examine the entrypoint script 
    docker run --rm -it --entrypoint [] myimagename:myimagetag /bin/sh
  2. (Possible) Solution: Rebuild the container image with a corrected script

Cause #2 - Image/Runtime Platform Mismatch

The other main reason for the "exec format error" is that the platform for which the container image was built does not match the platform where the container is running.

This could be related to how the image was fetched / staged.  For instance, using "docker pull" from a public registry and "docker push" to a private registry, using a Macbook with an M1 processor (arm64 platform) when the container will be run in a kubernetes system that is on amd64 (intel compatible) hardware and/or virtual machines.

  • Note: When the docker image entrypoint references a binary executable (not a startup shell script... i.e. no chance of missing "#!/bin/sh"), it is more likely that the "platform mismatch" is the cause of the "exec format error".
  • Note: If the source registry does not have an image matching the client/target platform (e.g. on a Raspberry Pi Arm 32bit OS), docker pull might fetch an image with a "best match" platform, which won't work (wrong exec format).  This is the toughest one to fix, since it might require a full recompile of some binary executable files and probably demands building a new image up from multiple layers down.

Troubleshooting

  1. Check the image platform
    docker image inspect myimagename:myimagetag |grep -i architecture
  2. Check the runtime platform
    docker version |grep -i arch
    or
    kubectl version |grep -i server
  3. (Possible) Solutions
    1. Pull the image with the platform that matches the target runtime environment
      docker pull --platform linux/amd64 myimagename:myimagetag
      ...then push again to the target registry to overwrite/replace the wrong-platform image.
      See: https://docs.docker.com/build/building/multi-platform/
    2. Rebuild the image starting from the correct base image
      Modify Dockerfile and add --platform argument to the FROM line.
      See: https://docs.docker.com/engine/reference/builder/#from

Monday, September 26, 2022

MacOS Display Derangement

Overview

The title is intentional, because MacOS falls short of actually accomplishing display arrangement in some circumstances.

Circumstances

When multiple monitors of certain brands and models are plugged into a MacBook, the part of MacOS that derives a "unique" identifier for each monitor fails to distinguish between them.  The HP E243 is one example, but there may also be other brands/models that reveal this flaw in MacOS' handling of external monitor identification.  Since MacOS cannot tell which specific display was previously arranged in a particular position (relative to the internal display, or other external displays, or each other), the overall arrangement sometimes gets mangled.  The only common way to re-arrange the monitors is by way of the cumbersome "System Preferences -> Displays" dialog in MacOS.

Remedy

After years of searching for a reasonable solution to this issue, and hoping Apple would get it fixed (but has not as of Monterey / 12.6), I finally found, sorta by accident, a command line utility (the best kind IMO) with the source code published on Github, called DisplayPlacer.  DisplayPlacer removes "most" of the annoyance of this Apple MacOS bug.  It still requires a manual step (running a command/script) to force displays back into a captured/desired arrangement, but is WAYYYYYYYY better than using the MacOS "System Preferences -> Displays" UI every time.

Steps

  • Install displayplacer (brew tap instructions on the github repo)
    • https://github.com/jakehilborn/displayplacer
  • Arrange displays using the MacOS System Preferences -> Displays (yup... one last time)
  • Run displayplacer list and copy/capture the displayplacer command that is printed to the console, which contains all of the distinct display ids, resolutions, refresh rates, and relative positions.
  • Create a shell script containing the captured command.
  • Whenever MacOS !@#$% the display arrangement again, run the shell script to pop everything back where it is supposed to go.

Conclusion

This isn't my utility.  The author Jake Hilborn had done us all a favor by making MacOS less annoying while we all continue to wait, maybe indefinitely, for Apple to finally acknowledge this is a problem and fix it themselves.  I would recommend sending Jake a thank you, or maybe find a way to buy him a cup of coffee (or similar).  I only posted this so there will be yet one more way some of you might end up finding Jake's excellent work, and maybe end some of your frustration with the display "derangement" on your MacBook.

Sunday, May 29, 2022

Installing webCOrE for SmartThings (Android) - May 2022

Overview

In the wake of several decisions by Samsung and possibly others, the SmartThings eco system is falling apart.  This article sums up several of the answers for installing webCoRE in SmartThings as they are (were) in the spring of 2022.

Alert: If you are trying to do this on an iOS/Apple mobile device, this isn't likely to help you much.  iOS devices aren't really a favorite of people who want to tinker with something like webCoRE anyway, and are generally VERY restrictive, so I'll just wish you luck finding a similar article, if such a thing exists, for your situation.

webCoRE - Why?

Automations in the basic SmartThings app don't allow multiple actions on the same device.  This limitation makes it impossible to do things like using an IOT plug to automate cycling the power off and on for something like an HP multifunction printer that puts itself permanently to sleep under unknown, random circumstances.  webCoRE adds the ability to do more useful automations.

Installation Overview

Instructions found in various places are based on previous versions of the SmartThings IDE (website), and/or previous versions of the SmartThings (Android) mobile app, so the screenshots and instructions often don't match up to current reality.  Even this article will, without a doubt, become obsolete when Samsung moves things around once again.  In the interest of minimizing that "rot" factor, I'm leaving out details for how to do various steps but including enough key words to search the web and find instructions.

The installation process for webCoRE is supposed to be a few simple steps as follows:

  1. Add the SmartApps to the SmartThings IDE
    • Option 1: Create each of the 4 webCoRE components "from code" and copy/paste the source code into the online editor.
    • Option 2: Integrate SmartThings with GitHub, and install each of the 4 webCoRE components from the ady624 GitHub repository.
  2. Add a named "instance" of webCoRE within the SmartThings app with access to the devices, sensors, etc. that the instance may control.
    • This is where Samsung has made things really obscure and difficult.

Installation "Gotcha's"

SmartThings Classic is Discontinued

  • The user interface in SmartThings Classic made it far clearer and easier to install SmartApps, but it is defunct, and the "new" version of the SmartThings app, at least on Android, tries its best to bury and hide the SmartApps functionality.
  • If your Android device is pre-"Oreo" (pre Android 8.0), this is probably already a source of frustration, since the "New" SmartThings app won't even install/run.  For instance, a Samsung Galaxy-S 5 makes a pretty good smart remote for IOT stuff, but you'd have to go to some trouble to get Android 8.0 or later installed on it.

Steps to install a SmartApp in the "New" version of SmartThings

  • Enable Developer Mode - The option to create a SmartApp won't even show up without doing this first.
    • At the moment, this is done by 
      • opening the settings (gear icon displayed when the "Menu" page/tab is selected).
      • scrolling down to "About SmartThings" and tapping it for 5+ seconds
      • scrolling farther down to see, and toggle on "Developer mode"
  • Dive Into the Menus to find where they hid the SmartApp option
    • At the moment, this is done by
      • switching to the Automations page/tab
      • clicking the "+" icon and choosing "Add routine"
      • switching to the "Discover" page/tab
      • scrolling all the way to the bottom and selecting the main webCoRE SmartApp (not the dashboard, piston, or storage items)
        • Note: These will only appear if they were previously added in the SmartThings IDE

Location

  • webCoRE refuses to install unless the Location is properly set in SmartThings.
  • Location was apparently managed in the Menu-Settings at some point, but currently, it is "hidden" on the "Favorites" page/tab
    • tap the location name (e.g. "Home")
    • select "Manage Locations" (gear icon)
  • Even if a geolocation is set, it may be too broad for webCoRE to be happy with it, so try reducing the radius, if webCoRE refuses to install.

References

* https://community.webcore.co/t/installation-trouble-webcore-your-location-is-not-correctly-setup/20079
* https://community.smartthings.com/t/faq-did-we-lose-the-ability-to-add-custom-smartapps-after-the-app-update-of-june-2021/227734
* https://community.smartthings.com/t/alternatives-to-smartthings-ecosystem-2021/227572/3
* https://www.youtube.com/watch?v=y_ElUwmmI6Y (overview of install with several outdated screenshots and instructions)
* https://www.reddit.com/r/SmartThings/comments/jwqskf/automations_more_than_one_action_for_the_same/

Tuesday, March 22, 2022

Mangled Metaphors and Corrupted Cliché's

This is a selection of entertaining mixed or mangled trite phrases (cliché's) that I remembered or saved along the way.

The Original Set

  • "It's not like I'm taking money out of anyone's mouth."
    • Context: This was stated during a conversation about the ethics of using software without paying for a license, or what Bill Gates likes to over-dramatically call "pirating" it.
    • Contributing Cliché: "taking money out of someone else's pocket"
    • Contributing Cliché: "taking food out of someone else's mouth"
  • "That will be the needle that broke the haystack."
    • This was stated by someone who fumbled nearly everything they tried to say, but still tried to inject a colloquial saying here and there, to try making their point even more ridiculous.
    • Contributing Cliché: "the straw that broke the camel's back"
    • Contributing Cliché: "finding a needle in a haystack"
  • "It's just a blimp on my radar."
    • Said by someone who didn't start life speaking English, so... good try.  I suppose, depending on whether the blimp is made of radar-reflective material, this could be ironic, or it could just be absurd.  Funny either way.
    • Contributing Cliché: "a 'blip' on radar"
  • "I'll let you bury your own hole."
    • Context: This was a feeble attempt to declare intent not to interfere in someone else's conflict.  M.C. Escher probably would have tried to paint a picture of this.
    • Contributing Cliché: "dig yourself deeper into a hole"
    • Contributing Cliché: "bury a bone / body / problem /etc."
  • "If I were you, I wouldn't hedge your bets."
    • Context: Hedging is a somewhat negative notion (betting against yourself), so this was a double negative in a way, but if taken literally, it is at least bad advice.  The application of pronouns is also a little hard to parse.
    • Contributing Cliché: "I would hedge my bets"
  • "If you need me, I'll be out rattling some more trees."
    • Context: Reasonably sure this was intended to mean the person planned to talk to additional contacts about something.
    • Contributing Cliché: "rattling some cages" (perturbing captive animals)
    • Contributing Cliché: "shaking some trees" (attempting to dislodge fruits or nuts growing on the tree)
  • "I don't have a horse in this fight."
    • Context: The person was surely intending to say he didn't have a stake or interest in the outcome of an argument.
    • Contributing Cliché: "have a dog in the fight" (reference to the practice of dog fighting)
    • Contributing Cliché: "have a horse in the race" (reference to a sport in which horses are more commonly used)
  • "We'll cross that bridge when it gets here."
    • Context: From a certain relative-motion perspective, this isn't necessarily an incorrect way to suggest waiting until a decision point is reached to actually make the decision, but...
    • Contributing Cliché: "cross that bridge when we come to it"
  • "It's a great place to flex those wings."
    • Context: Attempt to describing an "practice environment" which is particularly conducive to improving skills and increasing knowledge.
    • Contributing Cliché: "flex your muscles" (demonstrate strength)
    • Contributing Cliché: "spread your wings" (expand upon basic abilities and develop them in a place with fewer constraints / guardrails)

New ones...

  • "Easy Hanging Fruit"
    • Context: Discussion of most beneficial tasks to prioritize based on relative cost/benefit
    • Contributing Cliché: "low hanging fruit"
    • Contributing Cliché: "easy" (as generally used to describe something requiring little effort)
    • Commentary: As mangled, this cliché starts to sound a bit risqué.

Friday, January 7, 2022

Irritating Paypal Website Bug - Quick Security Check

Summary

When setting up Paypal as a method of payment, for instance, from Coinbase, in some circumstances, Paypal will prompt for a "Quick security check."  If there isn't a qualifying phone number already associated with the Paypal account, the prompt will also display "Please add a phone" with a link labeled "Add phone."

Note: What makes a number valid for use in the "Quick security check" doesn't seem to be clearly explained.  Based on (speculative) comments in some related forum discussions, it seems the key is that the name associated with the number in the CNAM (telco) directory database matches the name on the Paypal account.  Google Voice numbers seem to have no such entry, and therefore can't be used for this.  A physical mobile account with one of the major U.S. providers (Verizon, T-Mobile, ATT, etc.) seems to be the only option.

The trouble is caused when the size of the popup box for Paypal verification is not big enough to display the form to enter the phone number.  Clicking "Add phone" appears to do nothing.  To me, this falls somewhere between frustrating and infuriating. 

Note: The instructions here are primarily applicable to Windows 10 with a current/recent version of Google Chrome browser, so other OS's and/or other browsers may work a little differently.

What it Looks Like


Workaround

1. Right click (or whatever the equivalent is in your OS + web browser) the title bar of the popup dialog window and choose "Show as tab"


2. Resize the "tabbed" window to be sure it is wide enough to show the form to the right of the "Add phone" link, where there is another link with a "+" icon beside it, also labeled "Add phone."

Note: This is really where the bug exists.  If the window is sized too small/narrow, the form that actually allows adding a phone just disappears.



3. Finally, click the "+ Add Phone" link to display the text field that allows a phone number to be typed in.  From here, things work as expected


4. 

Monday, December 13, 2021

Airbow Guard Cover - V2 Design Update

Design Update

After several years of making the previous version of this gadget for various people around the world, I was forced to redesign it a little so that I could print the parts on a slightly smaller 3D printer, because the original printer I was using sorta started having too many problems.  After I managed to make a few of the covers on the other printer, I decided to keep working on it a while and update the design with a few changes that I have thought about over the past few years.

Here's the blog post about the previous design: https://whirlysworld.blogspot.com/2018/01/benjamin-airbow-missing-accessory.html  So, I won't repeat any of that stuff here.  Most of what that post says hasn't changed.  This post will just cover the design changes for "Version 2".

Friday, September 10, 2021

Arduino Pro Mini Vin/RAW vs. Vcc vs. FTDI

Goal

Connect an Arduino Pro Mini such that external devices get their power from an external power supply, while the Pro Mini remains connected via FTDI to a USB port on a computer, for programming, and serial-monitor uses.

Challenges

  • Powering the Pro Mini board + external devices totaling more than 200mA exceeds the rating for the on-board voltage regulator (VReg) on Vin/RAW.
  • Powering the Pro Mini board using Vin/RAW (i.e. VReg input > the board's operating voltage / 5v or 3.3v) sends voltage/current back, from the VReg output, through various routes, into the FTDI output pins, and in turn through the USB connector, risking damage to the USB port on a computer used for programming or a serial monitor.
    • Note: Disconnecting the FTDI +5v pin prevents the FTDI from communicating with the Pro Mini, and doesn't block all the backflow paths anyway.
  • Powering the Pro Mini board using its Vcc pin with an externally regulated voltage matching the board's operating voltage, basically attaches to the same "bus" as the output pin of the on-board VReg.  This conflicts with input voltage from the USB/FTDI and may backflow current into the USB port.
    • This might be tolerated, but still isn't an ideal, safe way to hook things up.
  • Logic voltage to control high-power external devices (e.g. motor, LED-array, or loud buzzer) must use the same reference +/- voltage as the board, or HIGH and LOW might make no sense.

Solution

While programming and developing, ONLY connect the GND of the external power supply to the GND of the Arduino Pro Mini, creating a common reference point for the Negative / NEG / "-" / Ground / 0v point, but _NO_ connection or conflict for the Positive / POS / "+" / Vcc.

Later, in order to run the external devices directly from the external power supply, and separately also run the Arduino Pro Mini from the same external power supply, completely remove the FTDI/USB device, and connect the external power supply to the Pro Mini via the appropriate pin, Vcc or Vin/RAW.

Explanation

The reason this works is that the difference in potential (voltage) observed relative to GND is polarized / directional based on which way current flows in the circuit.  If the GND reference point for both the board+USB and the external power supply are tied together, then the relative reference point for current flow, is also common.

Transistors (typically used to allow low-current logic to control a higher current device) trigger (amplify) based on current flow, so it only matters that the signal (base) current flows the same direction as the load (collector/emitter) current.  With the GND for both power sources (USB/FTDI and external) tied together, the current flow direction will match.

Connection Scenarios

  1. Programming / Development / Debugging
    • USB/FTDI Connected - supplies power to Arduino Pro Mini
    • Only Arduino Pro Mini GND pin connected to external power supply GND
      • i.e. Pos NOT connected
    • Pos and Neg from external power supply connected to supply power on external devices
  2. Standalone
    • USB/FTDI NOT connected to Arduino Pro Mini
    • Both Pos and Neg from external power supply connected to Pro Mini Vcc and GND
    • Pos and Neg from external power supply connected to supply power on external devices

Disclaimer:

The terminology used here, and maybe even some of the technical statements might not be expressed in the same terms as are used to explain electronics circuits and concepts elsewhere.  This was just my attempt at explaining things the way it makes sense to me, so that when I forget how this works, I can use this as a reminder.  Hope it helps someone else who is struggling with the same thing while developing with an Arduino Pro Mini.

Some of the discussions about this seem to go nowhere, or end in unresolved debate:
  • https://forum.arduino.cc/t/power-the-pro-mini-through-vin-and-serial-ftdi-chip/317067 
  • https://forum.arduino.cc/t/connecting-5v-vcc-to-an-arduino-pro-mini-or-to-any-arduino/340382
  • https://electronics.stackexchange.com/questions/97184/how-to-power-arduino-pro-mini-via-vcc-pin-12v-input
  • https://forum.arduino.cc/t/powering-pro-mini-and-ftdi-serial-question/252020

Tuesday, February 23, 2021

2010 Subaru Outback - LED Headlight Conversion


 Overview

The Subaru Outback is a really popular car, right?  There are millions of them on the road, right?  Things that are annoying about popular cars get solved with aftermarket products after a while, don't they?  Well, I'm puzzled, because the halogen lowbeam (H7) headlights on a 2010 Subaru Outback burn out WAY too often (every ~10 months in my recent experience), and they are an ENORMOUS pain to swap out.  Yet, there seems to be no reasonable options to install LED headlight bulbs.  I finally had enough, and spent some time designing my own solution.  This post is meant to share what I did, so that maybe someone else will have a bit of a head start on the whole endeavor.

Existing Solutions

SubieLED.com

The LED kits from this company seem to be relatively easy to install, and work with the existing dust cover by including an LED with a wide, low-profile heat sink.  Another option looks like it would require the dust-cover to be left off.  Here's a link to their stuff, in case they get them back in stock, or offer them at a more reasonable price:  http://www.subieled.com/#!/Low-Beam-H7/c/48078355

CarRover Silicone Dust Cover

Using these seemed like it might work with many of the standard H7 bulbs you can get for $30 or $40 from Amazon and various other sources.  I even ordered some but when I got them, and thought about it a little more, I realized they wouldn't really close up the headlight housing since the spring clip would be in the way, and if the wire from the LED module/bulb comes out the back, it somehow has to go back into the headlight housing to connect.  That further disrupts the dust seal allowing moisture or dust to get in, so they're still not ideal.

Others

I'm sure there are other LED "bulbs" or dust-cover options that might sorta work for a 2010 Subaru Outback, and there are quite a few that say they'll work, but I really didn't find any that were meant for my specific application.  If you're reading this and you know of something, please add a comment.

My Solution

I have a 3D printer, and reasonably good 3D design skills, so I decided to tackle this with my own "resources." The process was a little annoying since I also decided I was done paying yet-another-$30 for more halogen bulbs, and one of them had already burned out, so I was a bit reluctant to drive after dark.  Then the other halogen burned out, so I was stuck not using the Subie until I worked out how to get the LEDs installed.

Inverted Dust-Cover

I started with the basic idea of an inverted dust cover that leaves the LED heat sink out where air circulates to cool it, and still seals up the headlight housing.  However, unlike the "one size fits all" silicone dust cover, mine would need to either account for the spring clip, or replace its function by holding the LED H7 in place.  There was also the challenge of routing the wire from the rear of the LED back into the headlight housing to connect with the car's wiring harness.


Rigid Plastic

3D printers can produce flexible objects like silicone, but most of the time they work with rigid materials like PLA or ABS.  With strategic use of a few o-rings, I decided the best way to replace the function of the spring-clip was to make the dust-cover fit precisely into the opening and hold the bulb in place.  Here's a sketch of what that means for those who understand things better visually than verbally.

Pass-Thru for the Wire

The final challenge (or so I thought) was passing the wire through from outside back into the headlight housing.  You can make any shape you want with a 3D printer, so that was just a matter of printing a slot for the wire, and a plug to cover up the slot after the wire was in.  Easy!!  Well, ok, it was one of the more tedious parts of creating the 3D model, but still not a complete roadblock.

Tight Spaces


The actual final challenge was that the inverted dust-cover could not be maneuvered into the headlight housing with the LED already installed.  The "blade" part of the LED just sticks out too far, and the dust cover has to slide around in front of metal cross-member in the body of the car.  The only option is to get the dust-cover in place with the flange part of the LED and then install the LED body.  The risk of dropping the LED flange and/or the o-ring into the bottom of the headlight housing was promising to be a show-stopper.  I REALLY didn't want to add the chore of fishing those things back out of the housing to the already-frustrating ordeal,  But, back to the 3D printer for a solution... all it took was a substitute for the LED body, without anything sticking out, to use during installation.  The downside is that this is where the whole solution really locks into a specific LED product (for now).

More about the Lock-In

As I mentioned in the previous section, this solution is not only specific to a 2010 Outback, but also to a specific LED product.  It's not that this product is necessarily any better than others, but just happens to be the one I settled on.  The main drivers for my choice were, A) fanless design, B) good reviews, C) BeamTech brand generally has good reviews on all products, and D) 30,000 hours lifespan.  So, here are the details.

  • BeamTech H7 - BEAMTECH-CCD17-05-S2-H7
    • At Amazon: https://smile.amazon.com/dp/B071J4SCXY/ref=cm_sw_r_tw_dp_NCWMMWCDBZEWQ9ER9YHP
    • At BeamTechs.com: https://www.beamtechs.com/collections/j1-led-headlight-bulb/products/beamtech-h7-led-headlight-bulb-fanless-csp-y19-chips-8000-lumens-6500k-xenon-white-extremely-bright-conversion-kit
By the way, the headlight housing is the same on some other Subaru models, like the Legacy sedan, and possibly other year models (maybe through 2014).  I'm not 100% sure which ones this might also work on.

Summary


There are a few sub-optimal ways of installing LED headlights in a 2010 Subaru Outback and as a result of the time I spent obsessing over the design and development, there is (now) a more workable, and/or affordable option.  Hope this inspires someone else to tackle this project and eliminates some of the guesswork that I had to stumble through.

I know not everyone has a 3D printer, but if you do, and you want to do this project without working all that out for yourself, you can find the model files to print these exact dust-covers and the installation tool for a small fee here:  https://cults3d.com/en/3d-model/various/2010-subaru-outback-led-headlight-dust-cover

I also occasionally have some idle time on my 3D printer, so if it's not an option to print it for yourself, I can print the parts and put together a kit with the o-rings and screws you'll need (but you buy the LED bulbs yourself).  Based on previous, similar projects, I'll ask $50 to reimburse materials, printer setup time, trip to UPS, packaging materials, etc. + actual shipping cost (probably around +$10 to most places in the U.S. and +$25 international).  Just email me at subaru.ledmod @ liveintellect . org (remove the spaces) to request.  I'll let you know how quick I can get it done, arrange for Paypal or something similar, and go from there.

Saturday, January 23, 2021

Userscript to Automatically Click "Not Now" on the PayPal "Get the App" Nag

I finally had enough of the prompt EVERY TIME I LOG IN to PayPal nagging me to get their stupid mobile app.  Here's the UserScript (tested in TamperMonkey) to detect when that annoying "Get the App" page pops up right after login, and automatically find the "Not Now" link, and automatically click it.  This is what I would do anyway from now on, so the browser might as well do it for me.


// ==UserScript==
// @name         SkipPaypalLoginNag
// @namespace    http://tampermonkey.net/
// @version      0.1
// @description  Automatically click the "Not now" link on PayPal's aggravating "every time you log in" Nag to get their stupid mobile app
// @author       Super-Annoyed PayPal User
// @require      http://ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.min.js
// @require      https://gist.github.com/raw/2625891/waitForKeyElements.js
// @match        https://www.paypal.com/cgp/app-download*
// @grant        none
// @run-at       document-idle
// ==/UserScript==

(function() {
    'use strict';
    waitForKeyElements ("[data-name='continue_to_the_website']", clickTheNotNowLink);

    function clickTheNotNowLink() {
        var skipLink = document.querySelector("[data-name='continue_to_the_website']");
        if (skipLink) {
            console.log("Found the link to skip this annoying thing");
            skipLink.click();
        } else {
            console.log("Didn't find the link to skip the annoying thing");
        }
    }
})();

Saturday, December 19, 2020

Mr. Heater Missing Manual Links

Not sure why Mr. Heater chose to more or less hide this content from their customers, but it took me way too much time to find links to the PDF manuals for these Mr. Heater consumer products.  There's no obvious place on the Mr. Heater web site with links to these documents, but they're still online and accessible. Eventually I stumbled over the right combination of search words in Google to get a hint at the URL for these documents on the Mr. Heater web site.  

This post is just to help others who simply want to grab an electronic copy of the manual for a product they have, and keep that info on a phone or tablet (or even desktop/laptop computer I guess) instead of carting around the paper copy that comes with the products.  I didn't make this content, and am taking no responsibility for it... just linking to it on the Mr. Heater web site.  So, I'm sure they'll eventually re-organize things and break these links.  The clock starts now 12/19/2020, until that happens.  When/if I notice the links are broken, I'll try to find time to update this.  Enjoy.

Buddy Flex

  • Buddy Flex Heater - MH11BFLEX - 2020 USA
    • https://www.mrheater.com/mwdownloads/download/link/id/31/
  • Buddy Flex Cooker - MH8CFLEX - 2020 USA and Canada
    • https://www.mrheater.com/mwdownloads/download/link/id/32/

Portable Buddy

  • Portable ("Little") Buddy Heater - MH8BX - 2020 USA
    • https://www.mrheater.com/mwdownloads/download/link/id/36/
  • Portable ("Little") Buddy Heater - MH9BX - 2020 Canada
    •  https://www.mrheater.com/mwdownloads/download/link/id/37/

  • Portable Buddy Radiant Heater - MH4B - 2020 USA
    • https://www.mrheater.com/mwdownloads/download/link/id/33/
  • Portable Buddy Radiant Heater - MH4B - 2020 Canada
    • https://www.mrheater.com/mwdownloads/download/link/id/34/
  • Portable Buddy Radiant Heater - MH12HB - 2020 USA (Camo)
    • https://www.mrheater.com/mwdownloads/download/link/id/38/
  • Portable Hunting Buddy Radiant Heater - MH12HB - 2020 Canada (Camo)
    • https://www.mrheater.com/mwdownloads/download/link/id/39/

Portable Big Buddy

  • Portable Big Buddy Radiant Heater - MH18B - 2020 USA
    • https://www.mrheater.com/mwdownloads/download/link/id/40/
  • Portable Big Buddy Radiant Heater - MH18B - 2020 Canada (Outdoor Only)
    • https://www.mrheater.com/mwdownloads/download/link/id/41/
  • Portable Big Buddy Radiant Heater - MH18B - 2020 USA (No Fan)
    • https://www.mrheater.com/mwdownloads/download/link/id/42/
  • Portable Big Buddy Radiant Heater - MH18B - 2020 USA (No Fan / Outdoor Only)
    • https://www.mrheater.com/mwdownloads/download/link/id/43/

Tank Top Heaters

  • Gas-Fired Infra-Red Portable Heater - MH15 (1-lb canister version)
    • https://www.mrheater.com/mwdownloads/download/link/id/57/
  • Gas-Fired Infra-Red Cooker/Portable Heater - MH15C (1-lb canister version)
    • https://www.mrheater.com/mwdownloads/download/link/id/58/
  • Gas-Fired Infra-Red Tank Top Heater - MH15T, MH30T - 2019 (single and double dish)
    • https://www.mrheater.com/mwdownloads/download/link/id/59/
  • Gas-Fired Infra-Red Tank Top Heater - MH15T, MH30T - 2020 (single and double dish)
    • https://www.mrheater.com/mwdownloads/download/link/id/60/
  • Gas-Fired Infra-Red Tank Top Heater - MH45T - 2019 (triple dish)
    • https://www.mrheater.com/mwdownloads/download/link/id/61/
  • Gas-Fired Infra-Red Tank Top Heater - MH540T - 2020 (mushroom shaped)
    • https://www.mrheater.com/mwdownloads/download/link/id/62/

Other Stuff 

(besides the typical portable heater products)
  • Battery Operated Shower System / BOSS - F235897 - 2017
    • https://www.mrheater.com/mwdownloads/download/link/id/27/
  • Battery Operated Shower System / BOSS - XB13, XW18 - 2019
    • https://www.mrheater.com/mwdownloads/download/link/id/28/
  • Battery Operated Shower System / BOSS - XCW20 - 2019
    • https://www.mrheater.com/mwdownloads/download/link/id/29/
  • Portable Radiant Golf Cart Heater - MH4GC - 2020
    • https://www.mrheater.com/mwdownloads/download/link/id/35/
  • Base Camp Angle Iron Stoves - F235825, F235830, F235835 - 2019
    • https://www.mrheater.com/mwdownloads/download/link/id/26/
  • Mr. Heater Propane Accessories (catalog) - Hoses Fittings Regulators Accessories -2021
    • https://www.mrheater.com/mwdownloads/download/link/id/1/
  • Mr. Heater 2020 Product Catalog - 2020
    • https://www.mrheater.com/mwdownloads/download/link/id/4/

Wednesday, August 5, 2020

Webex Teams Auto-Correct Settings

Summary

This is about disabling the annoying auto-correct features in Webex Teams (on a Mac).

Searched for this answer but it does not appear to be in any obvious place in the docs.

The settings are also not accessible in the main "preferences" dialog for the Webex Teams application.

TL/DR

Right (or control) click in the text area where you type a message, select the "substitutions" pop-up menu item and toggle things on/off.

More detail...

You can toggle on/off
  • Smart Copy/Paste
  • Smart Quotes
  • Smart Dashes
  • Smart Links
  • Data Detectors
  • Text Replacement

Search/Index Keywords

auto-correct autocorrect auto correct substitution substitute dash dashes link links replace replacement fix fixing ignore quote quotes hyphen hyphenate hyphens webex teams chat instant message type typing enter entering send sending

Wednesday, July 8, 2020

When a Maven Release Build says it "Could not resolve dependencies," but...

In This Corner - Apache Maven

I've had this fight with Maven before.  I was always in such a hurry when I finally made the change that ended the fight, that I never stopped to analyze exactly why the issue was resolved.

The whole thing starts when Maven sucker punches me right at the end of the round, when I've got everything working, and it's time to do a release build using the maven-release-plugin.  The build works perfectly, UNLESS it is running within the release plugin.   WHYYYYYYYYYYYY!?!?!?!

The error message starts with: "Could not resolve dependencies" but it goes on to say that the actual dependency that it failed to retrieve is a peer module in the same multi-module project.  That's when I scream obscenities and threaten to change all my builds back to Ant (which at this point, I'm not sure too many people even remember).

Wait.  Why is it trying to "retrieve" it?  It's a peer module, which should be resolved from the reactor.  Why is it trying to find it in a remote repository???

Then the hammering begins...

  • Check that all the groupId tags match each other
    • Yup.  Even removed them from child modules so they're inherited. That's not it.
  • Check that all the version tags match up so the release plugin replaces all of them at once.
    • Yup.  All good,  Even pulled them up into the parent pom's dependencyManagement and used {$project.version} instead of a string that could get messed up.  That's not the issue.
  • Clean up all the dependencies that aren't used (copied/pasted from another project)
    • Didn't work.  No difference.
  • Change the order of the modules in the parent pom
    • Didn't work.  Didn't expect it to.  The reactor reorders them for the build anyway.
  • Add the enforcer plugin in the parent project.
    • Didn't find anything wrong.  At least this keeps my co-workers from dorking it up though.  Will leave that enabled and probably go put it in other projects too.
  • Change the version of plugins to different ones that might have a bug fixed
    • Nope. Same behavior.
  • Compare poms section by section with another project that is building ok.
    • Nothing is jumping out.  The look the same.  WHAT IS DIFFERENT?!?!?
  • Maybe it's character encoding or whitespace.
    • Well, that was a longshot anyway.  Copy/paste in the same IDE/Editor.  Check binary character codes.  That's all the same.

Then the futile Googling begins...


  • Search "maven reactor multi-module dependencies failure"
    • Find some idiot saying to run mvn install, but I already know to NEVER DO THAT!!
  • Search "maven-release-plugin bug"
    • Nothing matches
  • Search "maven-dependency-plugin bug"
    • It actually might be this, but nothing is reported.  Read on and speculate for yourself.
  • Search "maven is stupid and I hate it"
    • Found lots of pointless ranting.

Clues, Circumstances, Sketchy Evidence, and a Good Guess

Then I remember that the state of the Maven reactor changes during the different parts of the build lifecycle.  That has to be related to why the peer module's artifact is missing in action.  But still, why is it ONLY happening during a release build?

Then I see something in the pom for the module that is failing that might explain it.
  <plugin>
      <groupid>org.apache.maven.plugins</groupid>
      <artifactid>maven-dependency-plugin</artifactid>
      <version>3.1.1</version>
      <executions>
          <execution>
              <goals>
                  <goal>properties</goal>
              </goals>
          </execution>
      </executions>
  </plugin>


So, ok... that is related to a hack for a code generation plugin so that it forces Maven to resolve a properties value like this:
<properties>
    <swaggerRef>${com.example.services.myservice:common-abbreviations-service:json:webapp}</swaggerRef>
</properties>

...early enough in the build for the code generation plugin to use it.

So, that explains why the dependency plugin is busy doing stuff BEFORE the reactor has everything ready to resolve locally.

But, it still DOESN'T explain why it only happens in a release build.

Stay tuned.  One day I'll figure out that part too.

(TL/DR) Solved

For now...
If you're having this kind of issue in a build, look around for something that is forcing the normal Maven lifecycle to execute in an unusual order.  The way I resolved this one was to refactor things a bit and make the hacky code-gen module a "leaf" in the module tree.  If there are no peer-module dependencies, it doesn't matter, even in a release-build, if the dependency plugin runs too early.