According to AppEngine documentation (quoted below), using download_data and upload_data should preserve the original keys of the downloaded data.
When data is downloaded, the entities are stored along with their original keys. When the data is uploaded, the original keys are used. If an entity exists in the datastore with the same key as an entity being uploaded, the entity in the datastore is replaced.
I am using these two commands:
appcfg.py download_data --oauth2 --url=https://myapp-id.appspot.com/_ah/remote_api --filename=testdata/gamedata
appcfg.py upload_data --url=http://localhost:9876/_ah/remote_api --filename=testdata/gamedata
The data uploads with same ids but the keys are different, any idea what I am doing wrong? Or is the keys are computed differently il the local devappserver?
Update
Adding some data to compare between the prod and the local dev version
Production key: ag9zfmF3ZXNvbWVzdGdhbWVyGAsSCENhdGVnb3J5IgrYo9is2YbYqNmKDA
After download_data from PROD and upload_data to localhost, the key turns into for that same object: ahFkZXZ-YXdlc29tZXN0Z2FtZXIYCxIIQ2F0ZWdvcnkiCtij2KzZhtio2YoM