fix dump user info

This commit is contained in:
Kenneth Kehl
2024-08-01 13:00:49 -07:00
parent ef88378d72
commit e7ef25af01
2 changed files with 14 additions and 5 deletions

View File

@@ -664,7 +664,10 @@ def populate_annual_billing_with_the_previous_years_allowance(year):
def dump_user_info(user_email_address):
user = get_user_by_email(user_email_address)
content = user.serialize()
click.echo(content)
with open("user_download.json", "wb") as f:
f.write(json.dumps(content).encode("utf8"))
f.close()
print("Successfully downloaded user info to user_download.json")
@notify_command(name="populate-annual-billing-with-defaults")