diff --git a/cmd/goal/messages.go b/cmd/goal/messages.go index edd6ea74cb..5cd66e99bf 100644 --- a/cmd/goal/messages.go +++ b/cmd/goal/messages.go @@ -24,8 +24,8 @@ const ( errorGenesisIDFail = "Error determining kmd folder (%s). Ensure the node is running in %s." errorDirectoryNotExist = "Specified directory '%s' does not exist." errorParseAddr = "Failed to parse addr: %v" - errorNonPrintableCharacters = "One or more non-printable characters were ommited from the following error message:" - infoNonPrintableCharacters = "One or more non-printable characters were ommited from the subsequent line:" + errorNonPrintableCharacters = "One or more non-printable characters were omitted from the following error message:" + infoNonPrintableCharacters = "One or more non-printable characters were omitted from the subsequent line:" // Account infoNoAccounts = "Did not find any account. Please import or create a new one." @@ -169,6 +169,7 @@ const ( infoCreatedWallet = "Created wallet '%s'" infoBackupExplanation = "Your new wallet has a backup phrase that can be used for recovery.\nKeeping this backup phrase safe is extremely important.\nWould you like to see it now? (Y/n): " infoPrintedBackupPhrase = "Your backup phrase is printed below.\nKeep this information safe -- never share it with anyone!" + infoBackupPhrase = "\n%s" infoNoWallets = "No wallets found. You can create a wallet with `goal wallet new`" errorCouldntCreateWallet = "Couldn't create wallet: %s" errorCouldntInitializeWallet = "Couldn't initialize wallet: %s" diff --git a/cmd/goal/messages_common.go b/cmd/goal/messages_common.go deleted file mode 100644 index 39b2ae636f..0000000000 --- a/cmd/goal/messages_common.go +++ /dev/null @@ -1,24 +0,0 @@ -// Copyright (C) 2019-2021 Algorand, Inc. -// This file is part of go-algorand -// -// go-algorand is free software: you can redistribute it and/or modify -// it under the terms of the GNU Affero General Public License as -// published by the Free Software Foundation, either version 3 of the -// License, or (at your option) any later version. -// -// go-algorand is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU Affero General Public License for more details. -// -// You should have received a copy of the GNU Affero General Public License -// along with go-algorand. If not, see . - -// +build !windows - -package main - -const ( - // Wallet - infoBackupPhrase = "\n\x1B[32m%s\033[0m" -) diff --git a/cmd/goal/messages_windows.go b/cmd/goal/messages_windows.go deleted file mode 100644 index 3d06815cd0..0000000000 --- a/cmd/goal/messages_windows.go +++ /dev/null @@ -1,22 +0,0 @@ -// Copyright (C) 2019-2021 Algorand, Inc. -// This file is part of go-algorand -// -// go-algorand is free software: you can redistribute it and/or modify -// it under the terms of the GNU Affero General Public License as -// published by the Free Software Foundation, either version 3 of the -// License, or (at your option) any later version. -// -// go-algorand is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU Affero General Public License for more details. -// -// You should have received a copy of the GNU Affero General Public License -// along with go-algorand. If not, see . - -package main - -const ( - // Wallet - infoBackupPhrase = "\n%s" -) diff --git a/debug/logfilter/example3.in b/debug/logfilter/example3.in index 76b7f7ec5f..54db2210c9 100644 --- a/debug/logfilter/example3.in +++ b/debug/logfilter/example3.in @@ -145,9 +145,7 @@ - One or more non-printable characters were ommited from the subsequent line: - - [32mtest faculty trash brick need involve stand run jelly genius clap business zero ticket head grief rib fox ladder soap injury thrive balance able tissue[0m + test faculty trash brick need involve stand run jelly genius clap business zero ticket head grief rib fox ladder soap injury thrive balance able tissue WALLET_1_PASSPHRASE: test faculty trash brick need involve stand run jelly genius clap business zero ticket head grief rib fox ladder soap injury thrive balance able tissue spawn goal wallet list -d /home/travis/gopath/src/github.com/algorand/go-algorand/tmp/out/e2e/103916-1617037129265/tealAndStatefulTealTest/algod/root/Primary/ @@ -198,9 +196,7 @@ - One or more non-printable characters were ommited from the subsequent line: - - [32mpowder sing write danger match cabin order oblige shrug slide tragic select true rule gym celery wool vendor salon goat summer rule dove able collect[0m + powder sing write danger match cabin order oblige shrug slide tragic select true rule gym celery wool vendor salon goat summer rule dove able collect WALLET_2_PASSPHRASE: powder sing write danger match cabin order oblige shrug slide tragic select true rule gym celery wool vendor salon goat summer rule dove able collect spawn goal wallet list -d /home/travis/gopath/src/github.com/algorand/go-algorand/tmp/out/e2e/103916-1617037129265/tealAndStatefulTealTest/algod/root/Primary/ diff --git a/debug/logfilter/example3.out.expected b/debug/logfilter/example3.out.expected index c2f2f58188..e20c090b9c 100644 --- a/debug/logfilter/example3.out.expected +++ b/debug/logfilter/example3.out.expected @@ -75,8 +75,7 @@ Your backup phrase is printed below. Keep this information safe -- never share it with anyone! - One or more non-printable characters were ommited from the subsequent line: - [32mtest faculty trash brick need involve stand run jelly genius clap business zero ticket head grief rib fox ladder soap injury thrive balance able tissue[0m + test faculty trash brick need involve stand run jelly genius clap business zero ticket head grief rib fox ladder soap injury thrive balance able tissue WALLET_1_PASSPHRASE: test faculty trash brick need involve stand run jelly genius clap business zero ticket head grief rib fox ladder soap injury thrive balance able tissue spawn goal wallet list -d /home/travis/gopath/src/github.com/algorand/go-algorand/tmp/out/e2e/103916-1617037129265/tealAndStatefulTealTest/algod/root/Primary/ ################################################## @@ -103,8 +102,7 @@ Your backup phrase is printed below. Keep this information safe -- never share it with anyone! - One or more non-printable characters were ommited from the subsequent line: - [32mpowder sing write danger match cabin order oblige shrug slide tragic select true rule gym celery wool vendor salon goat summer rule dove able collect[0m + powder sing write danger match cabin order oblige shrug slide tragic select true rule gym celery wool vendor salon goat summer rule dove able collect WALLET_2_PASSPHRASE: powder sing write danger match cabin order oblige shrug slide tragic select true rule gym celery wool vendor salon goat summer rule dove able collect spawn goal wallet list -d /home/travis/gopath/src/github.com/algorand/go-algorand/tmp/out/e2e/103916-1617037129265/tealAndStatefulTealTest/algod/root/Primary/ ################################################## diff --git a/debug/logfilter/example6.in b/debug/logfilter/example6.in index ab22b4c545..f34549897d 100644 --- a/debug/logfilter/example6.in +++ b/debug/logfilter/example6.in @@ -268,9 +268,8 @@ ok github.com/algorand/go-algorand/test/e2e-go/cli/goal 26.354s - One or more non-printable characters were ommited from the subsequent line: - - [32mattract shy usage prison umbrella december sail finish struggle spring walk wisdom bread globe eyebrow admit typical tag december poet labor cable radar absent secret[0mWALLET_1_PASSPHRASE: attract shy usage prison umbrella december sail finish struggle spring walk wisdom bread globe eyebrow admit typical tag december poet labor cable radar absent secret + attract shy usage prison umbrella december sail finish struggle spring walk wisdom bread globe eyebrow admit typical tag december poet labor cable radar absent secret + WALLET_1_PASSPHRASE: attract shy usage prison umbrella december sail finish struggle spring walk wisdom bread globe eyebrow admit typical tag december poet labor cable radar absent secret spawn goal wallet list -d /home/travis/gopath/src/github.com/algorand/go-algorand/tmp/out/e2e/104122-1617229030279/tealAndStatefulTealTest/algod/root/Primary/ ################################################## @@ -317,9 +316,7 @@ ok github.com/algorand/go-algorand/test/e2e-go/cli/goal 26.354s - One or more non-printable characters were ommited from the subsequent line: - - [32mcasual double chuckle method salmon talent cabbage maze parade luggage under elite pass best session sign december cliff master proud since crunch joy above jump[0m + casual double chuckle method salmon talent cabbage maze parade luggage under elite pass best session sign december cliff master proud since crunch joy above jump WALLET_2_PASSPHRASE: casual double chuckle method salmon talent cabbage maze parade luggage under elite pass best session sign december cliff master proud since crunch joy above jump spawn goal wallet list -d /home/travis/gopath/src/github.com/algorand/go-algorand/tmp/out/e2e/104122-1617229030279/tealAndStatefulTealTest/algod/root/Primary/ diff --git a/debug/logfilter/example6.out.expected b/debug/logfilter/example6.out.expected index b3d517124a..a695920344 100644 --- a/debug/logfilter/example6.out.expected +++ b/debug/logfilter/example6.out.expected @@ -98,8 +98,8 @@ ok github.com/algorand/go-algorand/test/e2e-go/cli/goal 26.354s Your backup phrase is printed below. Keep this information safe -- never share it with anyone! - One or more non-printable characters were ommited from the subsequent line: - [32mattract shy usage prison umbrella december sail finish struggle spring walk wisdom bread globe eyebrow admit typical tag december poet labor cable radar absent secret[0mWALLET_1_PASSPHRASE: attract shy usage prison umbrella december sail finish struggle spring walk wisdom bread globe eyebrow admit typical tag december poet labor cable radar absent secret + attract shy usage prison umbrella december sail finish struggle spring walk wisdom bread globe eyebrow admit typical tag december poet labor cable radar absent secret + WALLET_1_PASSPHRASE: attract shy usage prison umbrella december sail finish struggle spring walk wisdom bread globe eyebrow admit typical tag december poet labor cable radar absent secret spawn goal wallet list -d /home/travis/gopath/src/github.com/algorand/go-algorand/tmp/out/e2e/104122-1617229030279/tealAndStatefulTealTest/algod/root/Primary/ ################################################## Wallet: Wallet_1_1617230151 @@ -124,8 +124,7 @@ ok github.com/algorand/go-algorand/test/e2e-go/cli/goal 26.354s Your backup phrase is printed below. Keep this information safe -- never share it with anyone! - One or more non-printable characters were ommited from the subsequent line: - [32mcasual double chuckle method salmon talent cabbage maze parade luggage under elite pass best session sign december cliff master proud since crunch joy above jump[0m + casual double chuckle method salmon talent cabbage maze parade luggage under elite pass best session sign december cliff master proud since crunch joy above jump WALLET_2_PASSPHRASE: casual double chuckle method salmon talent cabbage maze parade luggage under elite pass best session sign december cliff master proud since crunch joy above jump spawn goal wallet list -d /home/travis/gopath/src/github.com/algorand/go-algorand/tmp/out/e2e/104122-1617229030279/tealAndStatefulTealTest/algod/root/Primary/ ################################################## diff --git a/test/e2e-go/cli/goal/expect/goalExpectCommon.exp b/test/e2e-go/cli/goal/expect/goalExpectCommon.exp index 8a4ee7305c..7907cc0584 100644 --- a/test/e2e-go/cli/goal/expect/goalExpectCommon.exp +++ b/test/e2e-go/cli/goal/expect/goalExpectCommon.exp @@ -283,7 +283,7 @@ proc ::AlgorandGoal::CreateWallet { WALLET_NAME WALLET_PASSWORD TEST_PRIMARY_NOD } expect { timeout {::AlgorandGoal::Abort "Timed out CreateWallet pass phrase" } - -re {32m([a-z ]+)} {set WALLET_PASS_PHRASE $expect_out(1,string); close;} + -re {([a-z ]+)} {set WALLET_PASS_PHRASE $expect_out(1,string); close;} } } EXCEPTION ] } { ::AlgorandGoal::Abort "ERROR in CreateWallet: $EXCEPTION" diff --git a/test/e2e-go/cli/goal/expect/goalFormattingTest.exp b/test/e2e-go/cli/goal/expect/goalFormattingTest.exp index 281c53c3db..6f60d10611 100644 --- a/test/e2e-go/cli/goal/expect/goalFormattingTest.exp +++ b/test/e2e-go/cli/goal/expect/goalFormattingTest.exp @@ -22,7 +22,7 @@ if { [catch { spawn goal clerk inspect $TEST_ALGO_DIR/tx expect { timeout { close; ::AlgorandGoal::Abort "failed to inspect transaction file within timeout" } - {One or more non-printable characters were ommited from the following error message:} { + {One or more non-printable characters were omitted from the following error message:} { set NON_PRINTABLE_CHARS_WARNING 1 exp_continue }