mirror of
https://github.com/ElementsProject/lightning.git
synced 2025-01-17 19:03:42 +01:00
Onboarding: Make log output texts friendlier to new users
This commit is contained in:
parent
92ce3d5e8d
commit
689db5b7c1
@ -8,6 +8,6 @@ const char *version(void);
|
||||
|
||||
#define opt_register_version() \
|
||||
opt_register_early_noarg("--version|-V", version_and_exit, NULL, \
|
||||
"print version to standard output and exit")
|
||||
"Print version and exit")
|
||||
|
||||
#endif /* LIGHTNING_COMMON_VERSION_H */
|
||||
|
@ -332,7 +332,7 @@ int main(int argc, char *argv[])
|
||||
setup_jsonrpc(ld, ld->rpc_filename);
|
||||
|
||||
/* Mark ourselves live. */
|
||||
log_info(ld->log, "Hello world from %s aka %s #%s (version %s)!",
|
||||
log_info(ld->log, "Server started with public key %s, alias %s (color #%s) and lightningd %s",
|
||||
type_to_string(ltmp, struct pubkey, &ld->id),
|
||||
ld->alias, tal_hex(ltmp, ld->rgb), version());
|
||||
|
||||
|
@ -617,7 +617,7 @@ bool handle_opts(struct lightningd *ld, int argc, char *argv[])
|
||||
|
||||
/* Move to config dir, to save ourselves the hassle of path manip. */
|
||||
if (chdir(ld->config_dir) != 0) {
|
||||
log_unusual(ld->log, "Creating lightningd dir %s",
|
||||
log_unusual(ld->log, "Creating configuration directory %s",
|
||||
ld->config_dir);
|
||||
if (mkdir(ld->config_dir, 0700) != 0)
|
||||
fatal("Could not make directory %s: %s",
|
||||
|
@ -280,7 +280,7 @@ void peer_fail_transient(struct peer *peer, const char *fmt, ...)
|
||||
void peer_set_condition(struct peer *peer, enum peer_state old_state,
|
||||
enum peer_state state)
|
||||
{
|
||||
log_info(peer->log, "state: %s -> %s",
|
||||
log_info(peer->log, "State changed from %s to %s",
|
||||
peer_state_name(peer->state), peer_state_name(state));
|
||||
if (peer->state != old_state)
|
||||
fatal("peer state %s should be %s",
|
||||
@ -668,9 +668,9 @@ static void copy_to_parent_log(const char *prefix,
|
||||
{
|
||||
const char *idstr = type_to_string(peer, struct pubkey, &peer->id);
|
||||
if (continued)
|
||||
log_add(peer->ld->log, "peer %s: ... %s", idstr, str);
|
||||
log_add(peer->ld->log, "Peer %s: ... %s", idstr, str);
|
||||
else
|
||||
log_(peer->ld->log, level, "peer %s: %s", idstr, str);
|
||||
log_(peer->ld->log, level, "Peer %s: %s", idstr, str);
|
||||
tal_free(idstr);
|
||||
}
|
||||
|
||||
|
@ -266,7 +266,7 @@ class LightningD(TailableProc):
|
||||
|
||||
def start(self):
|
||||
TailableProc.start(self)
|
||||
self.wait_for_log("Hello world from")
|
||||
self.wait_for_log("Server started with public key")
|
||||
logging.info("LightningD started")
|
||||
|
||||
def wait(self, timeout=10):
|
||||
|
Loading…
Reference in New Issue
Block a user