4.2M1 downgrade to 4.1 causes JsonStorage - Couldn't deserialize value errors

I encountered problems upgrading from 4.1 to 4.2M2 so I decided to downgrade again. But unfortunately I am now getting JsonStorage - Couldn’t deserialize value errors. => How to fix?

2024-03-04 17:13:02.119 [ERROR] [re.storage.json.internal.JsonStorage] - Couldn't deserialize value 'org.openhab.core.storage.json.internal.StorageEntry@5e3f9015'. Root cause is: java.lang.NumberFormatException: For input string: "2024-03-04T16:20:14.302672877Z"

Downgrade is not supported. You can replace all timestamps in userdata/org.openhab.core.config.discovery.DiscoveryResult.json with epoch milliseconds.

For example:

 "timestamp": "2024-01-09T20:17:27.818829400Z",

to:

"timestamp": 1699728096882,
1 Like