Incorrect house wiring is not at all an idle concern.
The houses in our development were wired by a person or persons who were-
* outright malicious
* or some combination of the above
We have lived here for over 20 years and are still finding things that are dead wrong occasionally and which could not possibly have passed even a cursory but real building inspection.
And there have been many instances of wall outlet box fires and two garage fires due to wiring mistakes that resulted in the actual destruction of both garages. No joke.
I wish I were exaggerating but I am not.
Enough of that.
Fortunately there is a very simple way to check at least the outlet that the printer is plugged into-
https://www.lowes.com/pd/Southwire-Analog-Voltage-Detector/50129728 (or equivalent)
Everyone should keep one in their toolbox.
Assuming that the indications when using such a tester are all good, then the ground should be OK to use as a safety connection.
In that case the frame should be connected directly to it to act as a "safety" system, with a side benefit that it will also dissipate static charges.
However if all you want is a static shield, then yes you can connect the framework to "a" ground through a 2-4 megohm resistor.
But even then you still need a reliable ground, so we are right back to using a tester such as the one above or finding a reliable ground of some form.