Skip to content
Snippets Groups Projects
Select Git revision
  • e30db159a6c79683b6f03e24a4a0de1ceeac81cb
  • master default protected
  • ci-embed-raw-specs
  • network/gtest-1000 protected
  • upgradable-multisig
  • runtime/gtest-1000
  • network/gdev-800 protected
  • cgeek/issue-297-cpu
  • gdev-800-tests
  • update-docker-compose-rpc-squid-names
  • fix-252
  • 1000i100-test
  • hugo/tmp-0.9.1
  • network/gdev-803 protected
  • hugo/endpoint-gossip
  • network/gdev-802 protected
  • hugo/distance-precompute
  • network/gdev-900 protected
  • tuxmain/anonymous-tx
  • debug/podman
  • hugo/195-doc
  • gtest-1000-0.11.0 protected
  • gtest-1000 protected
  • gdev-900-0.10.1 protected
  • gdev-900-0.10.0 protected
  • gdev-900-0.9.2 protected
  • gdev-800-0.8.0 protected
  • gdev-900-0.9.1 protected
  • gdev-900-0.9.0 protected
  • gdev-803 protected
  • gdev-802 protected
  • runtime-801 protected
  • gdev-800 protected
  • runtime-800-bis protected
  • runtime-800 protected
  • runtime-800-backup protected
  • runtime-701 protected
  • runtime-700 protected
  • runtime-600 protected
  • runtime-500 protected
  • v0.4.1 protected
41 results

file_header.txt

Blame
    • Éloïs's avatar
      57ac5589
      Add weights benchmarks (step 1) (!73) · 57ac5589
      Éloïs authored
      * feat(weights): use our benchmarks for pallet proxy
      
      * feat(weights): use our benchmarks for pallet multisig
      
      * fix(benchmarks): some pallets benchmarking need access to system.remark
      
      * feat(weights): use our benchmarks for pallet timestamp
      
      * feat(weights): use our benchmarks for pallet scheduler
      
      * fix(weights): impl proper weights & benchmarks for pallet upgrade origin
      
      * doc(dev):weights-bench: reference machine should use an SSD with USB3
      
      * style(clippy): allow unnecessary_cast for WeighInfo implementations
      
      * doc(dev): add "how to benchmarks weights of a Call/Hook/Pallet"
      
      * feat(runtimes): use our benchmarks for pallet universal dividend
      
      * feat(pallet_ud): add weights info
      
      * feat(pallet_ud): add benchmarking
      
      * fix(weights): use our own extrinsic base weights constant
      
      * feat(weights): use our benchmarks for frame_system
      
      * feat(weights): use our benchmarks for pallet balance
      
      * fix(accounts): providers should be inc as soon as the account recv money
      
      providers should be incremented as soon as the account receive funds
      
      * fix(gdev): fix runtime benchmarks compilation
      57ac5589
      History
      Add weights benchmarks (step 1) (!73)
      Éloïs authored
      * feat(weights): use our benchmarks for pallet proxy
      
      * feat(weights): use our benchmarks for pallet multisig
      
      * fix(benchmarks): some pallets benchmarking need access to system.remark
      
      * feat(weights): use our benchmarks for pallet timestamp
      
      * feat(weights): use our benchmarks for pallet scheduler
      
      * fix(weights): impl proper weights & benchmarks for pallet upgrade origin
      
      * doc(dev):weights-bench: reference machine should use an SSD with USB3
      
      * style(clippy): allow unnecessary_cast for WeighInfo implementations
      
      * doc(dev): add "how to benchmarks weights of a Call/Hook/Pallet"
      
      * feat(runtimes): use our benchmarks for pallet universal dividend
      
      * feat(pallet_ud): add weights info
      
      * feat(pallet_ud): add benchmarking
      
      * fix(weights): use our own extrinsic base weights constant
      
      * feat(weights): use our benchmarks for frame_system
      
      * feat(weights): use our benchmarks for pallet balance
      
      * fix(accounts): providers should be inc as soon as the account recv money
      
      providers should be incremented as soon as the account receive funds
      
      * fix(gdev): fix runtime benchmarks compilation
    silkaj.py 4.14 KiB
    #!/usr/bin/env python3
    # -*- coding: utf-8 -*-
    
    import sys
    
    from commandlines import Command
    from commands import *
    
    
    def usage():
        print("Silkaj: command line Duniter client \
        \n\nhelp: -h, --help, --usage \
        \nversion: -v, --version \
        \n \
        \nCustom endpoint with option `-p` and <domain>:<port>\
        \n \
        \nCommands: \
        \n - info: Display information about currency \
        \n \
        \n - amount: Get amount of one account \
        \n      --pubkey=<pubkey[:checksum]>\
        \n      --auth-scrypt [script parameters -n <N> -r <r> -p <p>] (default: 4096,16,1)\
        \n      --auth-seed | --auth-file [--file=<path file>] | --auth-wif\
        \n \
        \n - transaction: Send transaction\
        \n     - authentication:\
        \n         --auth-scrypt [script parameters -n <N> -r <r> -p <p>] (default: 4096,16,1)\
        \n         --auth-seed | --auth-file [--file=<path file>] | --auth-wif\
        \n     - amount:\
        \n         --amountDU=<relative value> | --amount=<quantitative value>\
        \n         [--allSources] \
        \n     --output=<public key>[:checksum] \
        \n     [--comment=<comment>] \
        \n     [--outputBackChange=<public key[:checksum]>] \
        \n     [-y | --yes], don't ask for prompt confirmation \
        \n \
        \n - network: Display current network with many information \
        \n      [--discover]     Discover all network (could take a while), optional \
        \n      [-s | --sort]     Sort column names comma-separated (for example \"-s block,diffi\"), optional \
        \n                       Default sort is block,member,diffi,uid \
        \n \
        \n - diffi: list proof-of-work difficulty to generate next block \
        \n \
        \n - issuers n: display last n issuers (`0` for all blockchain) \
        \n      last issuers are displayed under n <= 30.\
        \n      To force display last ones, use `--last` option\
        \n \
        \n - argos: display currency information formated for Argos or BitBar\
        \n \
        \n - generate_auth_file: Generate file to store the seed of the account\
        \n      --auth-scrypt [script parameters -n <N> -r <r> -p <p>] (default: 4096,16,1)\
        \n      --auth-seed | --auth-file [--file=<path file>] | --auth-wif\
        \n \
        \n - id <pubkey> or <identity>: get corresponding identity or pubkey from pubkey or identity.\
        \n      it could autocomplete the pubkey corresponding to an identity with three or four following characters.")
        exit()
    
    
    def cli():
        # ep: endpoint, node's network interface
        ep, c = dict(), Command()
        subcmd = ["info", "diffi", "network", "issuers", "argos", "amount", "transaction", "generate_auth_file", "id"]
        if c.is_help_request() or c.is_usage_request() or c.subcmd not in subcmd:
            usage()
        if c.is_version_request():
            print("silkaj 0.2.0")
            exit()
        ep["domain"], ep["port"] = "duniter.org", "10901"
        try:
            ep["domain"], ep["port"] = c.get_definition('p').rsplit(':', 1)
        except:
            print("Requested default node: <{}:{}>".format(ep["domain"], ep["port"]), file=sys.stderr)
        if ep["domain"].startswith('[') and ep["domain"].endswith(']'):
            ep["domain"] = ep["domain"][1:-1]
        return ep, c
    
    
    def manage_cmd(ep, c):
        if c.subcmd == "info":
            currency_info(ep)
    
        elif c.subcmd == "diffi":
            difficulties(ep)
    
        elif c.subcmd == "network":
            from commands import set_network_sort_keys
            if c.contains_switches("sort"):
                set_network_sort_keys(c.get_definition("sort"))
            if c.contains_switches("s"):
                set_network_sort_keys(c.get_definition("s"))
            network_info(ep, c.contains_switches("discover"))
    
        elif c.subcmd == "issuers" and c.subsubcmd and int(c.subsubcmd) >= 0:
            list_issuers(ep, int(c.subsubcmd), c.contains_switches('last'))
    
        elif c.subcmd == "argos":
            argos_info(ep)
    
        elif c.subcmd == "amount" and c.subsubcmd:
            cmd_amount(ep, c)
    
        elif c.subcmd == "transaction":
            cmd_transaction(ep, c)
    
        elif c.subcmd == "generate_auth_file":
            generate_auth_file(c)
    
        elif c.subcmd == "id":
            id_pubkey_correspondence(ep, c.subsubcmd)
    
    
    if __name__ == '__main__':
        ep, c = cli()
        check_port(ep["port"])
        best_node(ep, 1)
        manage_cmd(ep, c)