MystenLabs / walrus-sites

Walrus Sites: Decentralized Websites using Sui and Walrus.
https://docs.walrus.site/walrus-sites/intro.html
Apache License 2.0
19 stars 16 forks source link

[Feature]: Add Walrus Site Builder config path to the error output #176

Open kkomelin opened 3 weeks ago

kkomelin commented 3 weeks ago

Description

Currently Wallet and Walrus config paths are printed to the console in case of error. Example:

#...
Caused by:
    running the command exited with error: 2024-08-21T12:41:29.735851Z  INFO walrus: running in JSON mode
    2024-08-21T12:41:29.735925Z  INFO walrus_service::client::cli_utils: using Walrus configuration from '/home/kos/.walrus/client_config.yaml'
    2024-08-21T12:41:29.735979Z  INFO walrus_service::client::cli_utils: Using wallet configuration from /home/kos/suibase/workdirs/testnet/config/client.yaml
    2024-08-21T12:41:29.737098Z  INFO walrus_service::client::cli_utils: using RPC URL set in wallet configuration
    Error: the specified Walrus system object 0x0e37ebae146052248fef02853b39e05b75e8c6d22a074db170aad053429618ba does not exist; make sure you have the latest configuration and you are using the correct Sui network

It would be good to have the Walrus Site Builder config path there as well, for example:

(time) INFO walrus_service::client::cli_utils: Using site-builder configuration from ./site-builder.yaml

The motivation here is that with this number of config files, it's easy to accidentally mix up the paths, and this change can help to investigate the issue.

Component

site-builder

Code of Conduct

giac-mysten commented 3 weeks ago

@kkomelin good point! We can add that for sure.

kkomelin commented 3 weeks ago

Thank you @giac-mysten !