Commit Graph

20 Commits

Author SHA1 Message Date
Giovanni Petrantoni 6affcda937
Less exceptions more results (#188)
* Less exceptions more results

* Fix daemonapi and interop tests

* Add multibase

* wip multiaddress

* fix the build, consuming new result types

* fix standard setup

* Simplify match, rename into MaError, add more exaustive err text

* Fix the CI issues

* Fix directchat build

* daemon api fixes

* better err messages formatting

Co-authored-by: Zahary Karadjov <zahary@gmail.com>
2020-05-31 16:22:49 +02:00
Dmitriy Ryajov 9cf1fd0216
remove generic constructor and expose serverflags (#176)
* remove generic constructor and expose serverflags

* fix transport constructor

* fix merge issues
2020-05-18 13:04:05 -06:00
Dmitriy Ryajov 167f42ed45
Remove read (#171)
* use readExactly

* remove `read`

* remove read

* no more `read`
2020-05-14 22:02:05 -06:00
Jacek Sieka ccd019b328
use stream directly in chronosstream (#163)
* use stream directly in chronosstream

for now, chronos.AsyncStream is not used to provide any features on top
of chronos.Stream, so in order to simplify the code, chronosstream can
be used directly.

In particular, the exception handling is broken in the current
chronosstream - opening and closing the stream is simplified this way as
well.

A future implementation that actually takes advantage of the AsyncStream
features would wrap AsyncStream instead as a separate lpstream
implementation, leaving this one as-is.

* work around chronos exception type issue
2020-05-08 22:10:06 +02:00
Jacek Sieka 330da51819
removals (#159)
* remove unused stream methods
* reimplement some of them with proc's
* remove broken tests
* Error->Defect for defect
* warning fixes
2020-05-06 18:31:47 +02:00
Giovanni Petrantoni 4c6a123d31
Add chronos trackers and used them to sanitize resource disposal (#131)
* Add chronos trackers and used them to sanitize resource disposal

* Chronos trackers for transport tests wip

* No more chronos leaks in testtransport

* Make tcp transport and test more robust when closing

* Test async leaking tracking wip

* Fix a regression in wire connect

* Add chronos trackers to more tests and sanitize resource closure

* Wip fixing floodsub tests

* Floodsub wip

* Made floodsub basically deterministic, hit a nim bug with captures tho

* Wrap up floodsub tests refactor

* Wrapping up

* Add allFuturesThrowing utility

* Fix missing allFuturesThrowing in noise tests!

* Make tests green

* attempt fixing gossipsub failing cases

* Make sure to check also fanout in waitSub

* More verbose traces

* Gossipsub test improvments

* Refactor TcpTransport remove asyncCheck

* Add Connection trackers

* Add stricter connection tracking, wip mplex fix

* More asynccheck removal, in order to avoid connection leaks

* bump chronicles requirement

* Enable tracker dump to check CI output

* Wait for more futures in testmplex

* Remove tracker dump messages

* add tryAndWarn utility, fix mplex issue with go interop

* All allFuturesThrowing to directchat too

* make sure to cleanup on transport close
2020-04-21 10:24:42 +09:00
cheatfate 833e8c9406
Fix overflow problem.
Fix compilation warnings.
2019-10-29 20:51:48 +02:00
Dmitriy Ryajov 7b66198566 use init instead of toMultiAddr 2019-10-11 08:15:24 +09:00
Dmitriy Ryajov 468cddeb45 style/cleanup 2019-10-11 08:15:24 +09:00
Dmitriy Ryajov f3afe0a6ce feat: allow ussage of 0 addrs 2019-10-11 08:15:24 +09:00
Dmitriy Ryajov 8920cd7d60 misc: pubsub/floodsub and logging 2019-10-11 08:15:24 +09:00
Dmitriy Ryajov 8cd1b71781 cosmetic 2019-10-11 08:15:24 +09:00
Dmitriy Ryajov 79129ea6d1 `handles` should be called on concrete transport 2019-10-11 08:15:24 +09:00
Dmitriy Ryajov e2b04fc30d add gcsafe pragma 2019-10-11 08:15:24 +09:00
Dmitriy Ryajov d23398f498 nimpretty 2019-10-11 08:15:24 +09:00
Dmitriy Ryajov 573a568946 fix tests 2019-10-11 08:15:24 +09:00
Dmitriy Ryajov a91c15c47a feat: adding dial/listen test with transports on both ends 2019-10-11 08:15:24 +09:00
Dmitriy Ryajov c15a9bdd67 feat: adding dial tests 2019-10-11 08:15:24 +09:00
Dmitriy Ryajov c8546583e6 feat: tcp transport listen 2019-10-11 08:15:24 +09:00
Dmitriy Ryajov 47106a6a7d wip: adding test 2019-10-11 08:15:24 +09:00