Client: remove Betanet disclaimer
This commit is contained in:
parent
7051325ba4
commit
968afcf682
@ -30,23 +30,11 @@ let disable_disclaimer =
|
|||||||
| Some ("yes" | "y" | "YES" | "Y") -> true
|
| Some ("yes" | "y" | "YES" | "Y") -> true
|
||||||
| _ -> false
|
| _ -> false
|
||||||
|
|
||||||
let default () =
|
|
||||||
if not disable_disclaimer then
|
|
||||||
Format.eprintf
|
|
||||||
"@[<v 2>@{<warning>@{<title>Warning@}@}@,@,\
|
|
||||||
\ This is @{<warning>NOT@} the Tezos Mainnet.@,\
|
|
||||||
\ The Tezos Mainnet is not yet released.@,\
|
|
||||||
@,\
|
|
||||||
\ Use your fundraiser keys @{<warning>AT YOUR OWN RISK@}.@,\
|
|
||||||
All transactions happening on the Betanet @{<warning>are expected to be valid in the Mainnet@}.@,\
|
|
||||||
\ In doubt, we recommend that you wait for the launch of the Mainnet.@]@\n@."
|
|
||||||
|
|
||||||
let zeronet () =
|
let zeronet () =
|
||||||
if not disable_disclaimer then
|
if not disable_disclaimer then
|
||||||
Format.eprintf
|
Format.eprintf
|
||||||
"@[<v 2>@{<warning>@{<title>Warning@}@}@,@,\
|
"@[<v 2>@{<warning>@{<title>Warning@}@}@,@,\
|
||||||
\ This is @{<warning>NOT@} the Tezos Mainnet.@,\
|
\ This is @{<warning>NOT@} the Tezos Mainnet.@,\
|
||||||
\ The Tezos Mainnet is not yet released.@,\
|
|
||||||
@,\
|
@,\
|
||||||
\ The node you are connecting to claims to be running on the@,\
|
\ The node you are connecting to claims to be running on the@,\
|
||||||
\ @{<warning>Tezos Zeronet DEVELOPMENT NETWORK@}.@,\
|
\ @{<warning>Tezos Zeronet DEVELOPMENT NETWORK@}.@,\
|
||||||
@ -58,34 +46,27 @@ let alphanet () =
|
|||||||
Format.eprintf
|
Format.eprintf
|
||||||
"@[<v 2>@{<warning>@{<title>Warning@}@}@,@,\
|
"@[<v 2>@{<warning>@{<title>Warning@}@}@,@,\
|
||||||
\ This is @{<warning>NOT@} the Tezos Mainnet.@,\
|
\ This is @{<warning>NOT@} the Tezos Mainnet.@,\
|
||||||
\ The Tezos Mainnet is not yet released.@,\
|
|
||||||
@,\
|
@,\
|
||||||
\ The node you are connecting to claims to be running on the@,\
|
\ The node you are connecting to claims to be running on the@,\
|
||||||
\ @{<warning>Tezos Alphanet DEVELOPMENT NETWORK.@}@,\
|
\ @{<warning>Tezos Alphanet DEVELOPMENT NETWORK.@}@,\
|
||||||
\ Do @{<warning>NOT@} use your fundraiser keys on this network.@,\
|
\ Do @{<warning>NOT@} use your fundraiser keys on this network.@,\
|
||||||
\ Alphanet is a testing network, with free tokens.@]@\n@."
|
\ Alphanet is a testing network, with free tokens.@]@\n@."
|
||||||
|
|
||||||
let betanet () =
|
let mainnet () =
|
||||||
if not disable_disclaimer then
|
if not disable_disclaimer then
|
||||||
Format.eprintf
|
Format.eprintf
|
||||||
"@[<v 2>@{<warning>@{<title>Warning@}@}@,@,\
|
"@[<v 2>@{<warning>@{<title>Disclaimer@}@}@,\
|
||||||
\ This is @{<warning>NOT@} the Tezos Mainnet.@,\
|
The Tezos network is a new blockchain technology.@,\
|
||||||
\ The Tezos Mainnet is not yet released.@,\
|
Users are solely responsible for any risks associated@,\
|
||||||
@,\
|
with usage of the Tezos network. Users should do their@,\
|
||||||
\ The node you are connecting to claims to be running on the@,\
|
own research to determine if Tezos is the appropriate@,\
|
||||||
\ @{<warning>Tezos Betanet EXPERIMENTAL NETWORK@}.@,\
|
platform for their needs and should apply judgement and@,\
|
||||||
\ Betanet is a pre-release experimental network and comes with no warranty.@,\
|
care in their network interactions.@]@\n@."
|
||||||
\ Use your fundraiser keys on this network @{<warning>AT YOUR OWN RISK@}.@,\
|
|
||||||
\ All transactions happening on the Betanet @{<warning>are expected to be valid in the Mainnet@}.@,\
|
|
||||||
\ If in doubt, we recommend that you wait for the Mainnet launch.@]@\n@."
|
|
||||||
|
|
||||||
let sandbox () =
|
let sandbox () =
|
||||||
if not disable_disclaimer then
|
if not disable_disclaimer then
|
||||||
Format.eprintf
|
Format.eprintf
|
||||||
"@[<v 2>@{<warning>@{<title>Warning@}@}@,@,\
|
"@[<v 2>@{<warning>@{<title>Warning@}@}@,@,\
|
||||||
\ This is @{<warning>NOT@} the Tezos Mainnet.@,\
|
|
||||||
\ The Tezos Mainnet is not yet released.@,\
|
|
||||||
@,\
|
|
||||||
\ The node you are connecting to claims to be running in a@,\
|
\ The node you are connecting to claims to be running in a@,\
|
||||||
\ @{<warning>Tezos TEST SANDBOX@}.@,\
|
\ @{<warning>Tezos TEST SANDBOX@}.@,\
|
||||||
\ Do @{<warning>NOT@} use your fundraiser keys on this network.@,\
|
\ Do @{<warning>NOT@} use your fundraiser keys on this network.@,\
|
||||||
@ -94,7 +75,6 @@ let sandbox () =
|
|||||||
let check_network ctxt =
|
let check_network ctxt =
|
||||||
Shell_services.P2p.versions ctxt >>= function
|
Shell_services.P2p.versions ctxt >>= function
|
||||||
| Error _ ->
|
| Error _ ->
|
||||||
default () ;
|
|
||||||
Lwt.return_none
|
Lwt.return_none
|
||||||
| Ok versions ->
|
| Ok versions ->
|
||||||
match String.split_on_char '_' (P2p_version.best versions).name with
|
match String.split_on_char '_' (P2p_version.best versions).name with
|
||||||
@ -108,10 +88,9 @@ let check_network ctxt =
|
|||||||
alphanet () ;
|
alphanet () ;
|
||||||
Lwt.return_some `Alphanet
|
Lwt.return_some `Alphanet
|
||||||
| "TEZOS" :: "BETANET" :: _date :: [] ->
|
| "TEZOS" :: "BETANET" :: _date :: [] ->
|
||||||
betanet () ;
|
mainnet () ;
|
||||||
Lwt.return_some `Betanet
|
Lwt.return_some `Mainnet
|
||||||
| _ ->
|
| _ ->
|
||||||
default () ;
|
|
||||||
Lwt.return_none
|
Lwt.return_none
|
||||||
|
|
||||||
let get_commands_for_version ctxt network block protocol =
|
let get_commands_for_version ctxt network block protocol =
|
||||||
|
@ -26,7 +26,7 @@
|
|||||||
open Client_context
|
open Client_context
|
||||||
|
|
||||||
type command = full Clic.command
|
type command = full Clic.command
|
||||||
type network = [ `Betanet | `Alphanet | `Zeronet | `Sandbox ]
|
type network = [ `Mainnet | `Alphanet | `Zeronet | `Sandbox ]
|
||||||
|
|
||||||
exception Version_not_found
|
exception Version_not_found
|
||||||
|
|
||||||
|
@ -26,7 +26,7 @@
|
|||||||
open Client_context
|
open Client_context
|
||||||
|
|
||||||
type command = full Clic.command
|
type command = full Clic.command
|
||||||
type network = [ `Betanet | `Alphanet | `Zeronet | `Sandbox ]
|
type network = [ `Mainnet | `Alphanet | `Zeronet | `Sandbox ]
|
||||||
|
|
||||||
exception Version_not_found
|
exception Version_not_found
|
||||||
|
|
||||||
|
@ -204,7 +204,7 @@ let commands version : Client_context.io_wallet Clic.command list =
|
|||||||
signers >>= return) ;
|
signers >>= return) ;
|
||||||
|
|
||||||
begin match version with
|
begin match version with
|
||||||
| Some `Betanet ->
|
| Some `Mainnet ->
|
||||||
command ~group ~desc: "Generate a pair of keys."
|
command ~group ~desc: "Generate a pair of keys."
|
||||||
(args2 (Secret_key.force_switch ()) sig_algo_arg)
|
(args2 (Secret_key.force_switch ()) sig_algo_arg)
|
||||||
(prefixes [ "gen" ; "keys" ]
|
(prefixes [ "gen" ; "keys" ]
|
||||||
@ -236,7 +236,7 @@ let commands version : Client_context.io_wallet Clic.command list =
|
|||||||
end ;
|
end ;
|
||||||
|
|
||||||
begin match version with
|
begin match version with
|
||||||
| Some `Betanet ->
|
| Some `Mainnet ->
|
||||||
command ~group ~desc: "Generate keys including the given string."
|
command ~group ~desc: "Generate keys including the given string."
|
||||||
(args2
|
(args2
|
||||||
(switch
|
(switch
|
||||||
@ -296,7 +296,7 @@ let commands version : Client_context.io_wallet Clic.command list =
|
|||||||
Signature.Public_key_hash.pp pkh >>= fun () ->
|
Signature.Public_key_hash.pp pkh >>= fun () ->
|
||||||
register_key cctxt ~force (pkh, pk_uri, sk_uri) ?public_key name) ;
|
register_key cctxt ~force (pkh, pk_uri, sk_uri) ?public_key name) ;
|
||||||
] @
|
] @
|
||||||
(if version <> (Some `Betanet) then [] else [
|
(if version <> (Some `Mainnet) then [] else [
|
||||||
command ~group ~desc: "Add a fundraiser secret key to the wallet."
|
command ~group ~desc: "Add a fundraiser secret key to the wallet."
|
||||||
(args1 (Secret_key.force_switch ()))
|
(args1 (Secret_key.force_switch ()))
|
||||||
(prefix "import"
|
(prefix "import"
|
||||||
|
@ -24,5 +24,5 @@
|
|||||||
(*****************************************************************************)
|
(*****************************************************************************)
|
||||||
|
|
||||||
val commands:
|
val commands:
|
||||||
[`Zeronet | `Alphanet | `Betanet | `Sandbox] option ->
|
[`Zeronet | `Alphanet | `Mainnet | `Sandbox] option ->
|
||||||
Client_context.io_wallet Clic.command list
|
Client_context.io_wallet Clic.command list
|
||||||
|
@ -386,7 +386,7 @@ let commands version () =
|
|||||||
return_unit
|
return_unit
|
||||||
end;
|
end;
|
||||||
] @
|
] @
|
||||||
(if version = (Some `Betanet) then [] else [
|
(if version = (Some `Mainnet) then [] else [
|
||||||
command ~group ~desc:"Register and activate an Alphanet/Zeronet faucet account."
|
command ~group ~desc:"Register and activate an Alphanet/Zeronet faucet account."
|
||||||
(args2
|
(args2
|
||||||
(Secret_key.force_switch ())
|
(Secret_key.force_switch ())
|
||||||
@ -416,7 +416,7 @@ let commands version () =
|
|||||||
return_unit
|
return_unit
|
||||||
);
|
);
|
||||||
]) @
|
]) @
|
||||||
(if version <> Some `Betanet then [] else [
|
(if version <> Some `Mainnet then [] else [
|
||||||
command ~group ~desc:"Activate a fundraiser account."
|
command ~group ~desc:"Activate a fundraiser account."
|
||||||
(args1 dry_run_switch)
|
(args1 dry_run_switch)
|
||||||
(prefixes [ "activate" ; "fundraiser" ; "account" ]
|
(prefixes [ "activate" ; "fundraiser" ; "account" ]
|
||||||
|
Loading…
Reference in New Issue
Block a user