Commit Graph

1558 Commits

Author SHA1 Message Date
Ben Carman
f475808dbd Script Program apply method refactor part 7 (#760) (#804) 2019-10-13 09:17:28 -05:00
Ben Carman
e7ce9cd157 Script Program apply method refactor part 6 (#760) (#802) 2019-10-13 09:09:56 -05:00
Ben Carman
3e0c624d2f Script Program apply method refactor part 4 (#760) (#800) 2019-10-12 11:14:56 -05:00
Ben Carman
7641c2b73f Script Program apply method refactor part 3 (#760) (#795)
* Script Program apply method refactor part 3 (#760)

* Remove unsused method

* Documentation

* Fix test case
2019-10-12 11:09:37 -05:00
Ben Carman
76f5810078 Script Program apply method refactor part 2 (#760) (#794)
* Script Program apply method refactor part 2 (#760)

* Remove method
2019-10-12 08:18:36 -05:00
Ben Carman
c1011cd8a7 Script Program apply method refactor part 1 (#760) (#793)
* Script Program apply method refactor part 1 (#760)

* Simplification of line

* Typo fix
2019-10-12 08:14:34 -05:00
rorp
82e6c36493 Make ChainApi to scan the block filters in order to find matches (#786)
* Make ChainApi to scan the block filters in order to find matches

* performance improvements, unit test

* some parallelization

* addressed comments

* parallelism level

* fix parallelism computation

* Scala 2.11 compatibility

* increased test coverage

* cleanup

* more checks and cleanup

* change ChainApi.getMatchingBlocks signature

* some more changes
2019-10-11 14:19:42 -05:00
Nadav Kohen
8e40c0e9d0 2019 10 01 script program cleanup (#791)
* Tightened up types, only allowing ExecutionInProgressScriptPrograms to be executed in Script OPs and having output type that cannot be PreExecutionScriptProgram

* Fixed all tests!

* Replaced all calls to loop and loopOrComplete with a single one at the bottom to retain the tailrec property

* Added a couple docs
2019-10-08 12:28:58 -05:00
Nadav Kohen
0b2728f338 2019 10 01 script interpreter cleanup (#772)
* Removed all IntelliJ warnings and did some very minor and contained cleanup

* Refactored ScriptInterpreter.run into nicer pieces

* Replaced all calls to isInstanceOf with matches
2019-10-08 10:14:00 -05:00
Chris Stewart
780ac75bf0 Run scalafmt, i forgot to run on #783 (#788) 2019-10-07 08:16:28 -05:00
Scala Steward
c27e1136e2 Update sbt-ci-release to 1.4.31 (#754) 2019-10-07 06:12:16 -05:00
Scala Steward
5a502e4a47 Update sbt-bloop to 1.3.4 (#787) 2019-10-07 06:11:40 -05:00
Scala Steward
8aecdc280a Update sttp:core to 1.7.0 (#785) 2019-10-07 06:10:48 -05:00
Chris Stewart
00eafd9970 Use the fact that network headers specify the number of bytes in the … (#783)
* Use the fact that network headers specify the number of bytes in the payload rather than just parsing from bytes.size, this should allow us to be more precise when parsing NetworkPayloads rather than _hoping_ that bytes.size does not land on pseudo-valid NetworkPayload. This hopefully resolves #782

* Add safety check around HeadersMessage.toString()

* Add invariant to NetworkMessage saying payloadSize in header must be the actual payload size
2019-10-06 09:48:53 -05:00
rorp
d390de323c Optimize org.bitcoins.chain.blockchain.BaseBlockChain (#781)
* Optimize org.bitcoins.chain.blockchain.BaseBlockChain

* remove toStream calls

* cleanup

* fix IndexOutOfBoundsException
2019-10-06 09:47:02 -05:00
Scala Steward
fd91fc37e2 Update sttp:core to 1.6.8 (#773) 2019-10-06 09:33:31 -05:00
rorp
f4cedece68 Disable OSX neurtino tests in CI (#777)
* Disable OSX neurtino tests in CI

* fix command line

* fix travis config

* revert .travis and mark NeutrinoNodeTest as @DoNotDiscover
2019-10-06 09:30:08 -05:00
Chris Stewart
56107ac13e Add a log at INFO level to indicate we are making progress while syncing (#780)
* Add a log at INFO level to indicate we are making progress while syncing

* Adjust sync log message to INFO in p2p code

* Fix off by one error

* Run scalafmt
2019-10-03 14:57:02 -05:00
rorp
f4b21043eb Fix bitcoind version for eclair tests (#778) 2019-10-03 13:16:23 -05:00
Chris Stewart
e819baf0dd Reduce GCSTest by more, remove unused warnings when using scala console from sbt (#779) 2019-10-03 09:46:43 -05:00
Scala Steward
2fb9d163f3 Update sbt-bloop to 1.3.3 (#775) 2019-10-03 08:37:10 -05:00
rorp
dac3b0091c Remove bitcoind dependency from node (#770)
* Remove bitcoind dependency from node

* addded some comments
2019-10-01 14:11:47 -05:00
Chris Stewart
9b1caa6561 Remove isInitialized() check in sendMsg, which was causing a deadlock (#763)
* Remove isInitialized() check in sendMsg, which was causing a deadlock

* Enable akka logging to help debug NeutrinoNodeTest

* Revert to bypassing the isInitialized() check in sendMsg()

* Run scalafmt again
2019-10-01 06:25:03 -05:00
rorp
7e19a706de Make tests to not require pre-installed bitcoind (#766)
* Make tests to not require pre-installed bitcoind

* update docs
2019-10-01 06:19:11 -05:00
Chris Stewart
eefbc37a81 2019 09 28 common test trait (#767)
* Create base traits for async tests called BaseAsyncTest, and then create two subtypes, BitcoinSAsyncTest and BitcoinSAsyncFixtureTest to make it easier to manage resources related to test cases. Now it is easier to shutdown things like an actor system in a structured manner

* Remove two bitcoind tests that don't make sense, 'duration' in the parameter is _really_ an interval (bad naming by usTesting an interval does not make sense inside of TestRpcUtilTest

* Turn log off for ChainAppConfigTest we expect to fail

* Bump timeout for BitcoinSUnitTest, use builtint sbt scalafmtCheck

* Remove hardcoded scalafmt binary

* reduce generator size to attempt to fix #768
2019-09-30 14:55:25 -05:00
Chris Stewart
97472930d0 2019 09 27 logging refactor pt2 (#765)
* Remove AKKA_CONFIG that was preventing sane logging for akka, move db-commons reference.conf to testkit so we can control testkit applications, and then rename app/server/.../application.conf to reference.conf like good libraries should do

* Update contributing.md

* update a few more links inside of contributing.md

* Run scalafmt
2019-09-28 09:50:42 -05:00
Chris Stewart
f65f11aead Add akka logging documentation to our contributing.md (#764) 2019-09-27 10:56:16 -05:00
Nadav Kohen
0611f27c25 Removed the sealed trait and private case class Impl pattern from ScriptPrograms (#759) 2019-09-26 07:31:54 -05:00
Chris Stewart
a945131af9 Run scalafmt (#762) 2019-09-26 07:31:30 -05:00
Chris Stewart
09ebdcea66 Remove hard coded log level in test app config (#757)
* Remove hard coded log level in test app config

* Change log level in default reference.conf to WARN so we have the same log level as before
2019-09-25 15:47:27 -05:00
rorp
74a44d1c4d Initial BIP157 support (#695)
* WIP: Initial BIP157 support

* store block hash and hetgh along with its compact filter header

* download and parse block filters

* getcfilters/cfilter

* cfilter table

* rescan full filter chain

* improved rescan performance

* optimize compact headers download

* addressed the PR comments

* split SVP and Neutrino node implementations

* configurable filter batch sizes

* initial filter sync

* addressed comments

* chage filter table's primary key

* fix Golomb filter deserialization

* batch database inserts

* neutrino node test

* fixed node test

* addressed the PR comments

* serializers tests

* cleanup

* fix compilation errors

* fix unit tests

* increase test coverage

* enable NeutrinoNodeTest

* make scalafmt happy

* don't cache experimental binaries

* inclease test coverage

* fix unit tests

* more granular CI tests

* disable NeutrinoNodeTest

* refactor tests

* addressed comments

* test coveage

* fix formatting

* responded to the comments

* some more changes

* fix the build

* test coverage

* revert testnet3 config parameter

* minor changes

* cleanup
2019-09-25 13:18:51 -05:00
Chris Stewart
3500978bae Fix bug where we were sending messages before we were fully initialized (#755)
* Fix bug where we were sending messages before we were fully initialized

* Move the pattern match out of isInitialized() future in sendMsg()
2019-09-24 09:43:27 -05:00
Scala Steward
fe6d0e637b Update sbt to 1.3.2 (#752) 2019-09-22 17:21:07 -05:00
Scala Steward
42c1097a15 Update akka-http, akka-http-testkit to 10.1.10 (#751) 2019-09-22 16:11:21 -05:00
Chris Stewart
3860bb16dc bump scalac version to 2.12.10 (#743)
* bump scalac version to 2.12.10

* bump scalac version to 2.12.10 in .travis.yml
2019-09-17 04:08:20 -05:00
Scala Steward
ff703592d2 Update sbt-scalafmt to 2.0.5 (#744) 2019-09-17 03:45:36 -05:00
Scala Steward
ae62136b22 Update sbt-ci-release to 1.3.2 (#745) 2019-09-17 03:45:18 -05:00
Scala Steward
99bf83d852 Update sttp:core to 1.6.6 (#741) 2019-09-10 01:27:38 -05:00
Scala Steward
a979fd1b7e Update sbt-scalafmt to 2.0.4 (#738) 2019-09-06 08:13:18 -05:00
Chris Stewart
67ead0bc7e 2019 09 05 scalafmt update (#735)
* Update scalafmt to 2.0.1

* Scalafmt

In this commit we
1) Reconfigure the .scalafmt.conf file
2) Add a scalafmt binary (same version as specified in conf file)
3) Use said binary on CI to check that everything is formatted correctly

* Ran scalafmt

* Update scalafmt ignore

* Add scalafmt plugin to project/plugins.sbt, run it

* run scalafmt
2019-09-05 20:02:58 -05:00
rorp
244b4863ba Fix WalletRpcTest (#736) 2019-09-05 16:09:11 -05:00
Chris Stewart
642a3366b1 Add receiver param to BitcoindRpcTestUtil.fundBlockChainTransaction() (#737)
* Add receiver param to BitcoindRpcTestUtil.fundBlockChainTransaction()

* Actually implement awaiting for the hash to be seen
2019-09-05 13:18:32 -05:00
Chris Stewart
d4ccc2c441 2019 09 05 v18 rpc (#734)
* This is for colin

* Fix remaining errors on V18 RPC calls

* remove unused code final formatting fix

* implemented fixed listwalletdir rpc test

* responding to code review and replacing flatmaps
2019-09-05 09:15:00 -05:00
Scala Steward
3aec12df6b Update sbt to 1.3.0 (#732) 2019-09-05 07:55:03 -05:00
rorp
4613d500e2 Make WalletRpcTest more determenistic (#731) 2019-09-04 06:51:33 -05:00
Torkel Rogstad
de39caf174 Add rudimentary docs for node, chain and wallet (#726) 2019-09-02 08:16:44 -05:00
Torkel Rogstad
e0a5646258 Deprecate generate (#728) 2019-09-01 07:46:38 -05:00
Torkel Rogstad
8a58d7dde8 Make it possible to construct RPC client without ActorSystem (#725) 2019-08-30 15:12:18 -05:00
Torkel Rogstad
f6ed565c14 Refactor sbt and make Eclair tests download bitcoind (#727) 2019-08-30 15:11:52 -05:00
Chris Stewart
d810e17324 Remove BlockchainBuilder, speed up ChainHandler test that processes m… (#723)
* Remove BlockchainBuilder, speed up ChainHandler test that processes mainnet headers, add test for ChainAppConfig

* Add test for BlockHeaderDAO.getAncestorAtHeight()

* Consolidate ChainAppConfigTest, add ScalaTestUtil to help with working with scalatest, speed up ChainHandlerTest a bit more
2019-08-27 12:29:22 -05:00