I must be missing something. On the page telling you how to upgrade to 5 it says,
Upgrade to the latest version like this:
sudo apt update
sudo apt install weewx
When I do that I get (I did do a sudo apt update before this)
me@raspberrypi:~ $ sudo apt install weewx
Reading package lists... Done
Building dependency tree
Reading state information... Done
weewx is already the newest version (4.10.2-1).
0 upgraded, 0 newly installed, 0 to remove and 2 not upgraded.
This is running on a raspi 4 running Raspbian Buster with Davis Vantage Pro 2