Giter Site home page Giter Site logo

ibm / gwhisper Goto Github PK

View Code? Open in Web Editor NEW
55.0 10.0 15.0 1.23 MB

A gRPC CLI featuring reflection and tab-completion

License: Apache License 2.0

CMake 6.49% Shell 4.65% C++ 88.27% Dockerfile 0.60%
grpc grpc-client cli debugging-tool completion color protocol-buffers command-line-tool remote-procedure-calls grpc-cli reflection auto-completion autocompletion bash-completion

gwhisper's Introduction

gWhisper - A gRPC command line tool

A gRPC command line client. It allows to invoke gRPC Calls from the commandline, supports tab-completion and formats the replies in a human readable format.

example invocation

The main features are:

  • Reflection support (no proto files required)
  • Tab completion (currently supported in fish and bash) for
    • services
    • methods
    • method arguments, including nested types
  • Usable directly in the shell

Have a look at the project scope for details.

Synopsis:

gwhisper [OPTIONS] <hostname>[:port] <service> <method> [<fieldName>=FIELD_VALUE ]...

Execute gwhisper --help or click here to get detailed information and examples on how to use the tool.

Quick links:

Getting started

Download

Release version: download
Development version: git clone https://github.com/IBM/gWhisper.git

Prerequisites

To be able to build and/or run gWhisper, you need to have the following dependencies installed on your system:

Mandatory:

  • cmake(>=3.11)
  • A C++ compiler, e.g. gcc
  • Either bash, fish(>=v2.6)

Optional:

  • openssl Required if building the test server to generate test certificates. To disable building the test server, have a look at Advanced Building
  • gRPC If you have gRPC installed on your system this will be used to build against, otherwise the gWhisper build system will download, build and statically link gRPC automatically.

Build

To simply build gWhisper in default configuration (including the test server), just execute

./build.sh

Executables are now available in the build/bin folder.

If you do not want to install gWhisper, you need to source the completion file (for tab completion):

source ./complete.bash or source ./complete.fish

NOTE: By default gWhisper downloads, builds and links gRPC in a version known and tested with gWhisper as part of the build. We made this choice, as we experienced many breaking changes in gRPC and wrongly packaged gRPC installations out there. However if you like, you can also link against your system installation of gRPC to save some build time and executable size. See Chapter Advanced Building.

Install

You may use the cmake-provided install target:

cd build
make install

Alternatively just copy the following files to the appropriate locations:

cp build/bin/gwhisper /usr/local/bin/
cp complete.bash /usr/share/bash-completion/completions/gwhisper
cp complete.fish /usr/share/fish/vendor_completions.d/gwhisper.fish

Advanced building

If you plan to build gWhisper for packaging or as a developer / contributor, the following information might be useful:

Directly use CMake to build

Follow the usual CMake flow:

mkdir build
cd build
cmake .. <cmake-options>
make -j<numCores>

CMake options

You can list gWhisper related build options via

cmake -LAH .. | grep --context 1 GWHISPER

The following are the most relevant options:

  • GWHISPER_BUILD_TESTS (default = OFF): Build unit and functional tests
  • GWHISPER_BUILD_TESTSERVER (default = ON): Build the testserver. This requires openssl to be installed for certificate creation.
  • GWHISPER_FORCE_BUILDING_GRPC (default = ON): Do not use a system installation of gRPC even if found. Instead always download and build gRPC from source

You can set options in CMake with the -D flag. For example:

cmake .. -D GWHISPER_BUILD_TESTSERVER=OFF

Examples and Test-Server

Every element except the hostname in the following example CLI invocations can be tab-completed in the bash or fish shell.

Simple example of an unary RPC with only one field in the request message:

gwhisper exampledomain.org bakery orderCookies amount=5

Nested arguments (the config field contains a sub-message):

gwhisper exampledomain.org bakery orderCookies config=:chocolate=true smarties=false: amount=5

IPv6 address and explicit TCP port with an enum typed field:

gwhisper [2001:db8::2:1]:50059 bakery orderCookies type=ChunkyStyle amount=0x7

Feel free to use the Test-Server shipped with gWhisper and try out gWhisper on your own. It is located in build/bin/testServer and implements example RPCs which cover almost the complete gRPC and protocol buffers function set.

Docker

gWhisper comes with a Dockerfile which may be used to build and run gWhisper.
You may also use this, to build for different platforms using dockerx/qemu.
To build the docker image execute (from repository root)

docker build -t gwhisper -f docker/Dockerfile .

To build for a different plattform that your host use buildx (you might need to have QEMU iinstalled):

docker buildx build --platform linux/s390x -t gwhisper -f docker/Dockerfile .

Current development status

Basic functionality is implemented, but you may experience bugs. Feel free to try it out and provide feedback/contributions.

What is working:

  • Tab Completion (bash and fish only)
  • Calling RPCs (unary + streaming)
  • Input and output of all protocol buffer types
  • Security: SSL is supported

Some notable things which are not yet working:

  • Using Proto files instead of Reflection API (currently gWhisper only works with servers which have reflection enabled)
  • Performance: Caching of reflection queries

Supported platforms

Development and testing is done on Fedora Linux 33 and Arch Linux. We expect no bigger problems with building and running this software on different linux distributions.

Reporting issues

We really appreciate any kind of feedback :-) So don't hesitate to open a new issue.
Please use the GitGub issues tab. Be sure to search issues first to avoid duplicate entries.

Contribute

Please have a look at CONTRIBUTE.md for general information about contributing. Some more technical documentation can be found here: Technical Documentation for Developers.

gwhisper's People

Contributors

anna-riesch avatar ericboehmler avatar fp-guitar avatar hermannolafs avatar rainerschoe avatar taojunli avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

gwhisper's Issues

doc test fails sometimes

2: #################################################################

2: Executing test 'oneof input choices again' at line 120

2: execute cmd '/home/travis/build/IBM/gWhisper/build/gwhisper --complete 127.0.0.1 examples.ComplexTypeRpcs sendNumberOrStringOneOf both=:number=5 str=5:'

2: Received:

2: number= (Both, a number and a string)

2: str= (Only a string)

2: both= (Both, a number and a string)

2: Expected:

2: number= (Only a number)

2: str= (Only a string)

2: both= (Both, a number and a string)

2: FAIL: line 1 received and expected text does not match.

Support secure channels

Is your feature request related to a problem? Please describe.
currently only unsecure servers are supported.

Describe why you think this feature is useful for gWhisper users
Users want to test secure servers as well

Provide option to use proto files instead of reflection

Is your feature request related to a problem? Please describe.
server might not support reflection

Describe the solution you'd like
give optional proto file path as CLI argument, if given, reflection is not used

Describe alternatives you've considered
none

Describe why you think this feature is useful for gWhisper users

  • sometimes servers do not have reflection enabled.
  • Users will have increased performance when using local proto files instead reflection over slow network.

Recursive datastructures result in segfault / hang

caused by infinite depth grammar being created

Typical scenario:

./gwhisper localhost testService callWithRecursiveMessage
fish: “./gwhisper localhost teatSer…” terminated by signal SIGSEGV (Address boundary error)

Nested custom output programs

nested Output programs or nested field references.
something like this:

@.listOfDevices:Found device /device_name/ @.device_features:allows music = /allows_music/:$'\n':

or this

@.listOfDevices:Found device /device_name/ with allows music = /device_name.allows_music/$'\n':

is not supported

Version string generation fails when source is built in other git repo

Describe the bug
If gwhisper source is packaged as part of another git repository, the version string contains information about this repository.

To Reproduce

  1. copy gwhisper directory into an other repository
  2. remove .git foder in gwhisper (not sure if necessary)
  3. build gwhisper
  4. run gwhisper --version
  5. you will see git version info from the other repository

Expected behavior
we should see something else or nothing in the --version output but not info from the other repository

make completion friendly interactive

Is your feature request related to a problem? Please describe.
I'm always frustrated when I tab, only : is completed in fish shell
I'm always frustrated when I tab at end of a message, : : is completed in bash shell
I'm always frustrated when I tab nothing is completed because a number is expected
I'm always frustrated when I tab enter and the app does not terminate

Describe the solution you'd like
I'm always frustrated when I tab, only : is completed in fish shell
=> possible to complete space? or some hints
I'm always frustrated when I tab at end of a message, : : is completed in bash shell
=> only one : is compeletet
I'm always frustrated when I tab nothing is completed because a number is expected
=> I need some hints, that an integer is expected
I'm always frustrated when I tab enter and the app does not terminate
=> terminate gWhisper also after streaming

Describe alternatives you've considered

Describe why you think this feature is useful for gWhisper users
to be interactiver. improve user experence

Additional context
Maybe two many request to the server? My server always receive empty message after using gWhisper

Parse error reported if host is not reachable

To Reproduce
when no test server is running execute:
gwhisper 127.0.0.1 examples.ScalarTypeRpcs incrementNumbers
the cmd will fail with error message:
Parse failed. Parsed until: '127.0.0.1 '

Expected behavior
Expected more clear error indicating the problem that grammar could not be fetched from server.

cppcheck is complaining about generated code

Describe the bug

...
[/home/travis/build/IBM/gWhisper/build/tests/testServer/examples.pb.h:3245]: (style) Condition 'GetArenaNoVirtual()==NULL' is always true
[/home/travis/build/IBM/gWhisper/build/tests/testServer/examples.pb.h:3277]: (style) Condition 'message_arena==NULL' is always true
[/home/travis/build/IBM/gWhisper/build/tests/testServer/examples.pb.h:3299]: (style) Condition 'GetArenaNoVirtual()==NULL' is always true
...

To Reproduce
trigger a travis build

Expected behavior
Generated code not checked (at least not generated code from protoc or other third-party code generators).

google test is installed with make install

Describe the bug
googletest installed on system

To Reproduce
make install

Expected behavior
googletest not installed, as it is only needed for unit tests and not for productive use

Possible choice in completion disappears

Describe the bug
A clear and concise description of what the bug is.

To Reproduce
./gwhisper 127.0.0.1 some.service ReadF + TAB still shows ReadFile ReadFileProperties ReadFanBut after adding an "i" I getReadFile`
as completion.

subsequent tabs complete as if "ReadFile" was selected.

Allow options/flags to be placed at multiple positions in CLI args

Is your feature request related to a problem? Please describe.
Currently all gwhisper options and flags need to be placed before the IP address, It would be nice to have the possibility to add options ad other places.

Describe the solution you'd like
Add options before IP after IP and in the end.
maybe also in between message? this might give problems...

Describe alternatives you've considered
keep current implementation.

Describe why you think this feature is useful for gWhisper users
Users might forget to add an option and then need to scroll back to the beginning to ad an option

Additional context
this is not high priority right now, as not many options exist except gwhisper debug options.

Include a gRPC server implementation for testing

Is your feature request related to a problem? Please describe.

  • I would like to test all gWhisper features, but sometimes I do not have a suitable gRPC server available.
  • gWhisper users might want to try gWhisper, but currently do not have a gRPC server available.

Describe the solution you'd like
It would be nice to have a reference gRPC server implementation exposing all gRPC and protobuf features (e.g. unary, streaming, empty messages, nested messages, repeated fields, oneof fields, ...)

Describe alternatives you've considered
none

Describe why you think this feature is useful for gWhisper users

  • gWhisper developers can use this server to test fixes/implementations
  • We could implement automated functional tests running against this server and integrate them with Travis
  • An gWhisper end user could use this server as a playground to get familiar with gWhisper and to try it out.

Timeout on calls to not existing IP/hostname

Is your feature request related to a problem? Please describe.
I'm always frustrated when I type the wrong IP/hostname and gWhisper does wait forever trying to connect.

Describe the solution you'd like
Three solutions I can think of right now:

  1. provide option --connect_timeout_ms=xxx which enables a timeout, if not given timeout is infinite
  2. provide option --no_connect_timeout which disables the timeout and use a timeout by default
  3. provide both options and enable timeout by default

Describe why you think this feature is useful for gWhisper users
For debug use, the default use-case of a user is to debug/test a server's service implementation. If IP is typed wrong or server is not running, we should get a response fast. The user should not have to think about why call is not returning.

allow sending of messages to client-side stream at runtime

Is your feature request related to a problem? Please describe.
currently all message have to be specified at start

Describe the solution you'd like
read from stdin line by line, parse messages and send to stream

Describe alternatives you've considered
none yet

Describe why you think this feature is useful for gWhisper users
full streaming support

Empty messages in request do not work

Describe the bug
RPCs with empty request message cannot be called.

To Reproduce
against test server execute:
./gwhisper 127.0.0.1 examples.NestedTypeRpcs getTime

Expected behavior
Expected rpc to succeed, however I observed

Parse failed. Parsed until: '127.0.0.1 examples.NestedTypeRpcs getTime'
Possible Candidates:
  '127.0.0.1 examples.NestedTypeRpcs getTime  '

Map output is not sorted by key

Describe the bug
map output not sorted

To Reproduce
do not know. sometimes maps appear randomized

Expected behavior
maps consistently transmitted

Increase performance for tab-completion

Is your feature request related to a problem? Please describe.
On machines with high-latency network connections (over-sea) or in simulation environments, tab-completion is sometimes slow (>300ms).

Describe the solution you'd like
Currently for every completion attempt one or more reflection API channels is established and destroyed to retrieve the descriptor database. However the database stays more or less the same every time.
It would be nice to have some mechanism to cache the descriptor database, and avoid connecting to the server for future requests.

Describe alternatives you've considered
I am still open for suggestions.

Describe why you think this feature is useful for gWhisper users
Increased usability by acceptable tab-completion performance.

Prepare release v0.2.0

TODO:

  • step hard coded version number
  • check if we should name the release 0.1.7 or 0.2.0
  • do some manual testing
  • verify if documentation is still valid

exception on conversion

./gwhisper 127.0.0.1 examples.NestedTypeRpcs echoNestedMaps simple_map_string=::key=8 value=ad::
terminate called after throwing an instance of 'std::invalid_argument'
what(): stoul
Aborted (core dumped)

Provide a way to include documentation, which will be displayed in completion suggestions.

Describe the solution you'd like
It would be nice to be able to document RPCs and message fields in the .proto files.
Something like this:

message test{
  int32 count          = 1 [doc:Number of test runs to perform];
  int32 registerValue  = 2 [doc:Chip register value, with which to execute the test];
}

gWhisper should then display this documentation during tab-completion or when requested to (e.g. via CLI flags)
Example 1:

$ gwhisper 127.0.0.1 test.<TAB><TAB>
test.helloWorld       returns a string containing "Hello World"
test.echoInt          returns the integer which was passed into the RPC

Example 2:
$ gwhisper 127.0.0.1 test.echoInt <TAB><TAB>
number                the number to be returned

In shells which support documentation in completions (zsh, fish, etc.) documentation should be correctly displayed as documentation.

Describe alternatives you've considered
Useful naming of RPC method names and field names is already very helpful, but often not sufficient.

Describe why you think this feature is useful for gWhisper users
According to the scope of the project the top priority is usability without the need for external documentation.

Additional context
We could use protobuf extensions for this (also available in proto3), as this allows documentation to be transmitted via reflection API.

Segfault on parse error of bytes field

Error parsing bytes field 'value': Given value is not a multiple of 8 bits long
Error parsing sub-message for field 'fields'
Segmentation fault (core dumped)

Support configuration files - At least for output formatting options (colors)

Describe the solution you'd like
It would be nice to have a way to persistently configure default behavior of the tool:

  • Color-Classes for output formatting
  • Timeouts
  • Greeting message at start of program
  • Default TCP port
  • Grammar caching enable/disable
  • Certs / Keys for secure channels

This configuration obviously needs to be stored on the file-system.
If no configuration is found, default values should be used.

Describe alternatives you've considered
specify all config options on command-line. But this is really annoying, as it forces the user to implement wrappers.

Describe why you think this feature is useful for gWhisper users
Especially for colors this is important, as the used color-set depends on the selected background color of the users terminal. Black on black or white on white does not make sense.

support for fish shell

Describe the solution you'd like
Currently completion only works for bash

Describe alternatives you've considered
stick with bash but more and more users are migrating to modern shells (fish is one of the most popular one)

Describe why you think this feature is useful for gWhisper users
users do not have to change shell to use gWhisper

Additional context
From my initial research fish might not provide a low-level API to "inject" a list of completions. As far as I know, fish supports two kinds of completion implementations:

  • compiled into fish
  • specified in config files via high-level language, which does not support retrieving completions from external commands.

Tab completion hangs when completing IP address or hostname

Describe the bug
gwhisper 127.0<TAB>
causes the shell to freeze up, only <Ctrl>+C allows recovery

To Reproduce
see above

Expected behavior
shell should not freeze up.

Additional context
Only happens when ip/hostname is incomplete/wrong

Create some integration pipeline

we should have some checks, that only semi-stable code will find its way into the master branch.
semi-stable means:

  • well reviewed code
  • all unit tests pass
  • not yet existing functional tests pass
  • code builds

Shorter representation of protobuf Map in output

Currently gWhisper does not know anything about maps, it reads and writes them as repeated messages with key and value members.

It would be nice to detect maps and format them in a shorter format. e.g.

key -> value

does not build with gcc 7

Describe the bug
I got the following compile error, as I try to compile gwisper with build.sh:
[ 35%] Building CXX object third_party/gRPC_utils/CMakeFiles/reflection.dir/cli_call.cc.o
cd /home/chw2lr/tools/gWhisper/build/third_party/gRPC_utils && /usr/bin/c++ -I/home/chw2lr/tools/gWhisper/build -I/home/chw2lr/tools/gWhisper/build/src -I/home/chw2lr/tools/gWhisper -I/home/chw2lr/tools/gWhisper/src -I/home/chw2lr/tools/gWhisper/build/third_party/gRPC_utils -std=gnu++11 -o CMakeFiles/reflection.dir/cli_call.cc.o -c /home/chw2lr/tools/gWhisper/third_party/gRPC_utils/cli_call.cc
In file included from /home/chw2lr/tools/gWhisper/third_party/gRPC_utils/cli_call.cc:21:0:
/home/chw2lr/tools/gWhisper/third_party/gRPC_utils/cli_call.h:32:7: error: using typedef-name ‘grpc::ClientContext’ after ‘class’
class ClientContext;
^~~~~~~~~~~~~
In file included from /usr/local/include/grpcpp/impl/codegen/call_op_set.h:34:0,
from /usr/local/include/grpcpp/impl/codegen/server_context_impl.h:28,
from /usr/local/include/grpcpp/impl/codegen/server_context.h:22,
from /usr/local/include/grpcpp/impl/codegen/async_stream.h:25,
from /usr/local/include/grpcpp/support/async_stream.h:22,
from /usr/local/include/grpcpp/generic/generic_stub_impl.h:24,
from /usr/local/include/grpcpp/generic/generic_stub.h:22,
from /home/chw2lr/tools/gWhisper/third_party/gRPC_utils/cli_call.h:26,
from /home/chw2lr/tools/gWhisper/third_party/gRPC_utils/cli_call.cc:21:
/usr/local/include/grpcpp/impl/codegen/client_context.h:26:36: note: ‘grpc::ClientContext’ has a previous declaration here
typedef ::grpc_impl::ClientContext ClientContext;
^~~~~~~~~~~~~
third_party/gRPC_utils/CMakeFiles/reflection.dir/build.make:100: recipe for target 'third_party/gRPC_utils/CMakeFiles/reflection.dir/cli_call.cc.o' failed
make[2]: *** [third_party/gRPC_utils/CMakeFiles/reflection.dir/cli_call.cc.o] Error 1

To Reproduce
./build.sh

with

$ g++ --version
g++ (Ubuntu 7.4.0-1ubuntu1~18.04.1) 7.4.0
Copyright (C) 2017 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

Expected behavior
It compiled.

Provide details about your environment

  • Operating System version:
  • gwhisper --version output: -
  • gRPC/protobuf version: how to find it out?
  • Compiler version (if related to build): see above
  • CMake version (if related to build):
 cmake --version
cmake version 3.10.2

CMake suite maintained and supported by Kitware (kitware.com/cmake).

Strings in input currently are not allowed to contain spaces

Describe the bug
$ ./gwhisper 127.0.0.1 helloworld.Greeter SayHello name=asd fsd
Parse failed. Parsed until: '127.0.0.1 helloworld.Greeter SayHello name=asd'
also
$ ./gwhisper 127.0.0.1 helloworld.Greeter SayHello name="asd fsd"
Parse failed. Parsed until: '127.0.0.1 helloworld.Greeter SayHello name=asd'

To Reproduce
see above

Expected behavior
$ ./gwhisper 127.0.0.1 helloworld.Greeter SayHello name="asd fsd"
2019-03-06 16:08:55: Received message:
| message = "Hello asd fsd"
RPC succeeded :D

fish shell autocompletion error

Describe the bug
I got the following error message with fish shell:

⋊> ~/t/gWhisper on 3af9796 ⨯ gwhisper /usr/share/fish/vendor_completions.d/gwhisper.fish (line 1): Variables may not be used as commands. In fish, please define a function or use 'eval $commandName'.
$commandName --complete=fish $args
^
in command substitution
	called on line 0 of file /usr/share/fish/vendor_completions.d/gwhisper.fish

in function “getCompletions”
	called on standard input

in command substitution
	called on standard input

gwhisper                     gwhisper                                                              17:17:04                     17:17:04

To Reproduce
in shell tip gwhisper and then tab

Expected behavior
A clear and concise description of what you expected to happen.

Provide details about your environment

  • Operating System version:
  • gwhisper --version output:
fish, version 2.7.1
  • gRPC/protobuf version: no idea

  • Compiler version (if related to build):

  • CMake version (if related to build):

⋊> ~ cmake --version                                        17:20:49
cmake version 3.10.2

CMake suite maintained and supported by Kitware (kitware.com/cmake)

Additional context
I use actually oh my fish

release tar or zip file downloaded from github does not build

Describe the bug
Build fails because googletest directory does not contain a CMakeLists.txt file

To Reproduce

  1. Download code from github release page (do not clone the repository)
  2. unpack tar or zip file
  3. execute ./build.sh
    -> build fails

Expected behavior
build successful

Provide details about your environment

  • gwhisper --version output: v0.1.5 downloaded from github

Additional context
Maybe it is possible to configure the build to not require googletest by default?

--help output contains not working example

Describe the bug

  - map fields:
      As a repeated field with nested key, value pairs (protobuf representation of maps).
      E.g. my_map=::key=5 value=testval :, :key=40 value=anotherValue::
      Map fields are tab-completed

Expected behavior
no space before ":"

No version info available when not built in git repository

Describe the bug
--version just gives build date

To Reproduce

  1. clone repo
  2. remove .git folder
  3. build
  4. execute gwhisper --version

Expected behavior
version printed

Provide details about your environment
n/a

Additional context
version can be provided via environment variable, but this is easily forgotten by users. This will lead to bug-reports which have un-traceable code version.

We should move documentation to the doc folder

Following candidates for a move:

  • example.gif
  • PROJECT_SCOPE.md (careful to update links in md pages)
  • maybe DCO (if no legal problems)
  • maybe MAINTAINERS.md (if no legal problems)
  • maybe CONTRIBUTIONS.md (if no legal problems)

this could clean up the code structure and does not make the project look so messy.

Support writing and reading bytes fields to/from files

Describe the solution you'd like
Some method to transmit / receive binary data other than typing everything in hex

Describe alternatives you've considered

  • not use gWhisper for this, but application specific code directly using gRPC API
  • wrapper script which converts data into hex string and constructs gWhisper CLI call from it.

Describe why you think this feature is useful for gWhisper users
Some RPCs allow read/write access to rather large binary blobs (e.g. firmware update). It would be nice to also debug those RPCs.

Additional context
Binary output could be implemented as some kind of extension of --customOutput.
This will be not so easy however, if other values in the reply also want to be seen, as --customOutput completely replaces standard output formatting.
We more likely want something like --bytesToFileWithPrefix="myPrefix" and then files are generated
Or some option --matchingFieldsToFile="regex"

Input can easily be done via some magic identifier instead of 0x in field value.
E.g.

    data=0xab45           -> reads data as hex
    data=file://~/file.bin  -> reads data from file

Provide a manpage

ideally we should find a mechanism to generate manpage, online docu and --help output from the same source

Travis CI build takes very long (>20min)

Describe the bug
build takes very long

To Reproduce
create a pull request to trigger CI build

Expected behavior
expect build to finish in less than 5 minutes

Additional context
This seems to be caused, as travis has to download, build and install grpc and protobuf for each build.
I think we should migrate to docker builds, in this case we could start with a docker-image with pre-installed gRPC.

Reduce number of RPCs performed for each call

Describe the solution you'd like
Currently, multiple short-lived TCP connections / gRPC channels are estabished for each call:

  • One for retrieving Service list
  • One for retrieving Method list
  • One for retrieving argument grammar
  • One for actually performing the requested RPC

We could establish the channel only once and maybe also retrieve Service and Methods in one call to the reflection API.
This will have significant performance impact, as we will not have to go through TCP handshake and slow-start each time.

Describe alternatives you've considered
A clear and concise description of any alternative solutions or features you've considered.

Describe why you think this feature is useful for gWhisper users
Especially in slow simulation environments this will improve performance significantly and also will make tab-completion much faster

cppcheck snap package is broken

Describe the bug
The build is broken with the current snap package of cppcheck in the revision 228.
The configuration files like std.cfg were existent in previous packages (rev 213).

To Reproduce

Expected behavior

Provide details about your environment

Additional context
Checking out a specific snap revision of cppcheck seems to be disallowed.

sudo snap install cppcheck --revision=213
error: cannot install "cppcheck": Access by specifying a revision is not allowed for this Snap.

So the current plan is to disable cppcheck for the moment to get the build running again and then see if the snap package will be fixed or if the required config files will be added to this repo.

Idea: Control output formatting via proto files

Describe the solution you'd like
It would be nice to automatically format fields the way they are supposed to.
Currently for example integers are by default formatted in both decimal and hex. One of those representations is in most cases unnecessary. When you write a .proto file you will know which representation of a field makes sense, so you could write something like this:

message test{
  int32 count          = 1 [formatHint:dec];
  int32 registerValue  = 2 [formatHint:hex];
}

which then influences the gWhisper output formatter.

Describe alternatives you've considered
none

Describe why you think this feature is useful for gWhisper users
makes output easier to read by only printing necessary information

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.