Move the one-time migration logic (_migrate_legacy_py_data and related
constants) from client.py into legacy_py_data_migration.py. The public
API is migrate_legacy_py_data(data_dir) which derives all paths from
the argument, eliminating module-global monkeypatching in tests.
client.py is reduced by ~110 lines; the new file can be git-rm'd
together with 2 lines in client.py once the migration is retired.