Crash after trying to create profile with name that already exists
traceback after TUI onboarding:
CommunicationError: Problem occurred during communication with: url=http://127.0.0.1:46251, request={"id": 0, "jsonrpc": "2.0",
"method": "beekeeper_api.create", "params": {"wallet_name": "alice", "password": "alice123", "token":
"aee47c9a81009715c6960f16afcb7206564a9a01aae2b08ed82fe025413b63aa"}}, result={'jsonrpc': '2.0', 'error': {'code': -32003, 'message':
"Assert Exception:!fc::exists( wallet_file_name ): Wallet with name: 'alice' already exists at
/home/dev/.clive/beekeeper/alice.wallet", 'data': {'code': 10, 'name': 'assert_exception', 'message': 'Assert Exception', 'stack':
[{'context': {'level': 'error', 'file': 'wallet_content_handlers_deliverer.cpp', 'line': 50, 'method': 'create', 'hostname': '',
'thread_name': 'th_l', 'timestamp': '2024-09-19T06:53:46'}, 'format': "Wallet with name: '${n}' already exists at ${path}", 'data':
{'n': 'alice', 'path': '/home/dev/.clive/beekeeper/alice.wallet'}}], 'extension': {'assertion_expression': '!fc::exists(
wallet_file_name )'}}}, 'id': 0}
Traceback (most recent call last):
File "/home/dev/clive/clive/main.py", line 45, in <module>
main()
File "/home/dev/clive/clive/main.py", line 41, in main
asyncio.run(_main())
File "/home/dev/.pyenv/versions/3.10.12/lib/python3.10/asyncio/runners.py", line 44, in run
return loop.run_until_complete(main)
File "/home/dev/.pyenv/versions/3.10.12/lib/python3.10/asyncio/base_events.py", line 649, in run_until_complete
return future.result()
File "/home/dev/clive/clive/main.py", line 34, in _main
await run_tui()
File "/home/dev/clive/clive/__private/run_tui.py", line 36, in run_tui
sys.exit(await Clive.app_instance().run_async())
File "/home/dev/clive/clive/__private/ui/app.py", line 133, in run_async
async with TUIWorld() as world:
File "/home/dev/clive/clive/__private/core/world.py", line 69, in __aexit__
await self.close()
File "/home/dev/clive/clive/__private/core/world.py", line 115, in close
self.profile.save()
File "/home/dev/clive/clive/__private/core/profile.py", line 145, in save
PersistentStorageService().save_profile(self)
File "/home/dev/clive/clive/__private/storage/service.py", line 80, in save_profile
self._raise_if_profile_with_name_already_exists_on_first_save(profile)
File "/home/dev/clive/clive/__private/storage/service.py", line 254, in _raise_if_profile_with_name_already_exists_on_first_save
raise ProfileAlreadyExistsError(profile_name, existing_profile_names)
clive.__private.storage.service.ProfileAlreadyExistsError: Profile `alice` already exists. Please choose another name, different than ['alice', 'mary'].
Edited by Mateusz Kudela