From c8cf0272f96079b57efddc89f29a9b2b87277185 Mon Sep 17 00:00:00 2001 From: Dima Gerasimov Date: Sun, 28 Aug 2022 23:08:35 +0100 Subject: [PATCH] instagram.gdpr: use new path to personal information --- my/instagram/gdpr.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/my/instagram/gdpr.py b/my/instagram/gdpr.py index 3dfe352..4c54fbf 100644 --- a/my/instagram/gdpr.py +++ b/my/instagram/gdpr.py @@ -77,7 +77,12 @@ def _entities() -> Iterator[Res[Union[User, _Message]]]: # whereas here I don't need it.. # so for now will just implement this adhoc thing and think about properly fixing later - j = json.loads((last / 'account_information/personal_information.json').read_text()) + personal_info = last / 'personal_information' + if not personal_info.exists(): + # old path, used up to somewhere between feb-aug 2022 + personal_info = last / 'account_information' + + j = json.loads((personal_info / 'personal_information.json').read_text()) [profile] = j['profile_user'] pdata = profile['string_map_data'] username = pdata['Username']['value']