48 Commits

Author SHA1 Message Date
Scott Sadler
01c6d6e72d remove test, see if codecov is happy 2017-05-31 17:13:57 +02:00
Scott Sadler
8348dfb8ce test for vote get_changefeed to make codecov happy (fix) 2017-05-30 17:43:38 +02:00
Scott Sadler
d51632a675 test for vote get_changefeed to make codecov happy 2017-05-30 15:14:23 +02:00
Scott Sadler
51be4be2f7 Merge remote-tracking branch 'origin/master' into vote-order-bug 2017-05-29 17:03:36 +02:00
Rodolphe Marques
92392b51a7 Initial implementation to decouple assets from transactions.
Most changes done to how we write and read blocks to the database.
Created schema, indexes and queries for mongodb.
Fixed tests.
2017-05-10 16:43:52 +02:00
Scott Sadler
8f55febefb rethinkdb changefeed update 2017-04-13 10:53:13 +02:00
Scott Sadler
3bb5973f60 fix block order bug 2017-04-12 17:29:17 +02:00
Rodolphe Marques
cb87221bdf Voting pipeline now checks for duplicated transactions in blocks during
validation.
2017-04-04 17:57:44 +02:00
Scott Sadler
59e21bfa4d fix test, log tx validation errors and document ValidationError 2017-03-03 11:52:12 +01:00
Scott Sadler
5584de59b0 Make ValidationError a superclass of all validation errors and use it 2017-03-03 11:36:50 +01:00
Scott Sadler
fc2b684f32 use is_new_transaction in pipelines 2017-02-22 13:55:29 +01:00
Rodolphe Marques
595f7dc701 several fixes to mongodb queries 2017-01-09 13:25:27 +01:00
Brett Sun
8fa3245309 Rename any *util.py to *utils.py (#991) 2016-12-22 17:39:39 +01:00
Scott Sadler
04a78aacec Merge remote-tracking branch 'origin/master' into inputs-outputs 2016-12-22 13:45:02 +01:00
Brett Sun
9319583ab4 Remove Asset and AssetLink (#982)
* Remove asset.validate_asset and move its validation checks to other areas

* Move Asset.get_asset_id to Transaction

* Remove Asset and AssetLink models

* Add test against creating TRANSFER transactions with bad asset
2016-12-22 10:19:21 +01:00
Sylvain Bellemare
44391da94a Add genesis block fixture and marker 2016-12-21 17:45:14 +01:00
Sylvain Bellemare
fa79fe6783 Add session scope test setup for config and db
resolves #966
2016-12-20 20:37:28 +01:00
libscott
7e33f2bd52 Tx ID as Asset ID (#926)
* Allow AssetLinks to be used in place of Assets in the Transaction Model and enforce `Transaction.transfer()` to only take an AssetLink

* Remove AssetLink's inheritance from Asset

* Remove id from the Asset model

* Fix get_txids_by_asset_id query for rethinkdb after removing asset's uuid

Because `CREATE` transactions don't have an asset that contains an id
anymore, one way to find all the transactions related to an asset is to
query the database twice: once for the `CREATE` transaction and another
for the `TRANSFER` transactions.

* Add TODO notice for vote test utils to be fixtures

* Update asset model documentation to reflect usage of transaction id

* Fix outdated asset description in transaction schema
2016-12-20 17:28:15 +01:00
Scott Sadler
ed55b3984e s/fulfillments/inputs/g && s/conditions/outputs/g (code changes) 2016-12-19 12:29:29 +01:00
Sylvain Bellemare
56feefe3f4 Re-work test fixtures - iteration one 2016-12-15 15:54:15 +01:00
Sylvain Bellemare
65dab4f2eb Group std lib imports together (pep 8) 2016-12-15 15:51:09 +01:00
Brett Sun
345fc27a39 Remove durability from all database-related calls 2016-12-12 16:07:41 +01:00
Brett Sun
9a7e695e18 Fix tests still relying on being able to access removed attribute of the Bigchain class 2016-12-12 15:48:48 +01:00
Scott Sadler
44a43dcf94 make all tests pass after vote schema introduction 2016-12-12 15:15:38 +01:00
Scott Sadler
c43bf10151 add call to vote schema validate in consensus.py 2016-12-12 15:15:38 +01:00
vrde
024c8583b5
Merge remote-tracking branch 'origin/isolate-db-testcalls' 2016-11-28 16:29:23 +01:00
Rodolphe Marques
a824e275e0 decode signature to a str 2016-11-25 16:00:20 +01:00
ryan
9ab0294bc9 partial removal of rethinkdb calls from tests 2016-11-22 14:47:11 +01:00
Rodolphe Marques
eead7dbdda Merge remote-tracking branch 'origin/master' into feat/746/new-naming-convention-for-keys 2016-11-17 11:41:23 +01:00
Rodolphe Marques
3909538c62 Replace all occurrences where vk is used as a shortcut
for public key and replaced it with `pk`
2016-11-10 17:20:27 +01:00
Rodolphe Marques
c068f04a82 Replaced VerifyingKey with PublicKey
Replaced SigningKey with PrivateKey
Replaced all occurences of signing key with private key
Replaced all occurences of verifying key with public key
2016-11-10 17:01:06 +01:00
Rodolphe Marques
e35d2899b5 Removed support for custom threshold
Removed support for hashlocks
Unskipped tests that were skipped waiting for divisible assets
Fixed remaining tests
2016-11-09 13:32:18 +01:00
Sylvain Bellemare
ea9dfaf1e5 Replace bigchaindb_common pkg by bigchaindb.common 2016-10-24 17:01:43 +02:00
vrde
15fb27f327
Remove conn property from core API 2016-10-18 17:32:32 +02:00
Rodolphe Marques
7275e6f44b Added support for cryptoconditions 0.5.0
Fixed tests.
2016-10-14 17:48:45 +02:00
Rodolphe Marques
abf1c98d7c Merge remote-tracking branch 'origin/master' into rebase/feat/564/implement-digital-asset-template 2016-10-12 16:56:49 +02:00
Ryan Henderson
81e70951d4 check if fulfillments are in a valid block (#629)
* check if fulfillments are in a valid block

* documentation

* fix almost all tests where tx validity is checked before writing to block

* move import
2016-10-10 09:41:49 +02:00
Rodolphe Marques
0652348bf0 initial integration of asset 2016-10-07 15:46:21 +02:00
Sylvain Bellemare
50b0b3cef2 Rebase/feat/586/integrate tx model (#641)
* Adjust imports to bigchaindb_common

* Adjust get_spent function signature

* Adjust block serialization

* Fix BigchainApi Test

* Fix TestTransactionValidation tests

* Fix TestBlockValidation tests

* WIP: TestMultipleInputs

* Adjust tests to tx-model interface changes

- Fix old tests
- Fix tests in TestMultipleInputs class

* Remove fulfillment message tests

* Fix TransactionMalleability tests

* Remove Cryptoconditions tests

* Remove create_transaction

* Remove signing logic

* Remove consensus plugin

* Fix block_creation pipeline

* Fix election pipeline

* Replace some util functions with bdb_common ones

- timestamp ==> gen_timestamp
- serialize.

* Implement Block model

* Simplify function signatures for vote functions

Change parameter interface for the following functions:

- has_previous_vote
- verify_vote_signature
- block_election_status

so that they take a block's id and voters instead of a fake block.

* Integrate Block and Transaction model

* Fix leftover tests and cleanup conftest

* Add bigchaindb-common to install_requires

* Delete transactions after block is written (#609)

* delete transactions after block is written

* cleanup transaction_exists

* check for duplicate transactions

* delete invalid tx from backlog

* test duplicate transaction

* Remove dead code

* Test processes.py

* Test invalid tx in on server

* Fix tests for core.py

* Fix models tests

* Test commands main fn

* Add final coverage to vote pipeline

* Add more tests to voting pipeline

* Remove consensus plugin docs and misc

* Post rebase fixes

* Fix rebase mess

* Remove extra blank line

* Improve docstring

* Remove comment

handled in bigchaindb/cryptoconditions#27;
see https://github.com/bigchaindb/cryptoconditions/issues/27

* Fix block serialization in block creation

* Add signed_ prefix to transfer_tx

* Improve docs

* Add library documentation page on pipelines

* PR feedback for models.py

* Impr. readability of get_last_voted_block

* Use dict comprehension

* Add docker-compose file to build and serve docs

locally for development purposes

* Change private_key for signing_key

* Improve docstrings

* Remove consensus docs

* Document new consensus module

* Create different transactions for the block

* Cleanup variable names in block.py

* Create different transactions for the block

* Cleanup variable names in block.py
2016-09-29 10:29:41 +02:00
vrde
25d10957ca
Validate block metadata 2016-08-05 11:58:07 +02:00
vrde
3ad72077d3
Fix failing tests 2016-08-03 15:55:24 +02:00
vrde
13bd69f977
Move tests to new file 2016-08-02 17:28:22 +02:00
vrde
79980c08a6
Port final tests 2016-08-02 16:04:08 +02:00
vrde
074cae4484
Add last tests 2016-08-02 15:39:08 +02:00
vrde
17c11e5935
Add docstrings 2016-08-02 14:27:25 +02:00
vrde
54984364b1
Fix stoopid error in tests 2016-08-02 11:53:46 +02:00
vrde
cdcb6b4e1e
Remove old code 2016-08-01 22:55:17 +02:00
vrde
199e8633bb
Port tests to the new pipeline process 2016-08-01 22:45:53 +02:00