187 Commits

Author SHA1 Message Date
Sylvain Bellemare
02fe712c34 Integrate cryptoconditions version 02 2017-06-22 14:56:22 +02:00
Rodolphe Marques
b523ba3fe5 Rename unspent -> spent in outputs endpoint
- If spent=None return all outputs
- If spent=True return only spent outputs
- If spent=False return only unspent outputs
- Updated documentation
- Add the ability to return only spent outputs in core
- Added and update tests
2017-06-16 10:31:46 +02:00
Rodolphe Marques
3819ae5d65 Clean up code
- Fixed docstrings
2017-05-26 10:34:58 +02:00
Rodolphe Marques
285fc03ca9 Merge remote-tracking branch 'origin/master' into feat/1462/text-search 2017-05-24 11:59:49 +02:00
Rodolphe Marques
6900e86458 Filter out assets from invalid transactions
- Created docstrings
- Created tests
- Raise an exception when trying to use text search with RethinkDB.
2017-05-24 11:38:15 +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
b4f14b26ce address nomenclature issues 2017-05-08 14:25:39 +02:00
Scott Sadler
4f99122758 fast unspents 2017-04-19 15:47:58 +02:00
Rodolphe Marques
10d83c2ab9 No duplicate vote inserts with mongodb (#1258)
* prevent duplicate vote inserts
2017-03-22 14:25:16 +01:00
Scott Sadler
1f5a8582b6 Merge branch 'master' into tx-structure 2017-03-14 16:22:14 +01:00
Scott Sadler
7c461e47d7 remove structural and schematic validations from Transaction.validate which is validating the spend 2017-03-14 12:39:57 +01:00
Scott Sadler
dc58466de3 Merge branch 'master' into voting-class-integration 2017-03-13 13:35:03 +01:00
Scott Sadler
a3fccbc599 change TransactionDoesNotExist to InputDoesNotExist in tests 2017-03-08 13:01:52 +01:00
Scott Sadler
ffccf86c91 Merge remote-tracking branch 'origin/master' into voting-class-integration 2017-03-08 12:54:33 +01:00
Scott Sadler
e5dd5c665b address vrde's comments, reshuffle some exceptions around 2017-03-07 13:15:31 +01:00
Scott Sadler
352627b83a add test that asset id is a string 2017-03-06 12:12:04 +01:00
Scott Sadler
3346fcb47b break BigchainDBCritical into CriticalDoubleSpend and CriticalDoubleInclusion and add test 2017-03-03 13:48:52 +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
ebeb94f35a cleanup has_previous_vote 2017-02-27 16:25:29 +01:00
libscott
4a5a5566e7 Merge pull request #1208 from bigchaindb/is_new_transaction
Bigchaindb.is_new_transaction, fix double inclusion in Vote pipeline
2017-02-24 10:17:06 +01:00
Scott Sadler
89e76ffec2 fix tests, temporarily disabling some tests that need to be re-written 2017-02-23 21:53:12 +01:00
Scott Sadler
b94eab715d introduce BigchainDBCritical exception 2017-02-22 14:37:34 +01:00
Scott Sadler
843d65d233 bigchain.is_new_transaction method 2017-02-22 13:55:29 +01:00
Scott Sadler
2af8fcb918 test unicode write block to disk 2017-01-31 15:48:34 +01:00
Scott Sadler
248e89a666 unicode tests uses serialize() and includes info about unicode symbol 2017-01-31 15:43:46 +01:00
Scott Sadler
2a07362bad test transaction supports unicode 2017-01-30 16:11:44 +01:00
Scott Sadler
9762b4b968 fix spend input twice bug (https://github.com/bigchaindb/bigchaindb/issues/1099) 2017-01-26 13:39:06 +01:00
Scott Sadler
e3317b370b don't rename TransactionLink to TL 2017-01-24 12:11:21 +01:00
Scott Sadler
af23ff5b65 clean up use of double quotes, rename UNSPENTS_ENDPOINT, clarify test 2017-01-24 12:08:55 +01:00
Scott Sadler
897ffe81bc outputs endpoint with unspent filter parameter 2017-01-23 16:10:21 +01:00
Scott Sadler
4bb64fa0b8 generalise get_owned_ids to get_outputs and get_owned_ids 2017-01-23 16:10:21 +01:00
Scott Sadler
7c4c7e9be3 remove use of random in test_bigchain_api 2017-01-17 11:48:58 +01:00
Sylvain Bellemare
1cfd3de60e Fix flake8 errors in tests 2017-01-11 05:13:27 -05:00
Rodolphe Marques
7f05974f0f Added a secondary index with uniqueness constraint in backlog.
Several test fixes
2017-01-09 13:25:42 +01:00
Rodolphe Marques
8e99d18fd6 Merge pull request #994 from bigchaindb/feat/927/implement-mongodb-changefeed
[WIP] Implement mongodb changefeed
2017-01-04 17:10:46 +01:00
Rodolphe Marques
1b3c909d51 Fixed mongodb queries
Fixed some tests
2017-01-04 15:43:17 +01:00
Brett Sun
8fa3245309 Rename any *util.py to *utils.py (#991) 2016-12-22 17:39:39 +01:00
libscott
5190e0a682 Merge pull request #925 from bigchaindb/inputs-outputs
Inputs & Outputs
2016-12-22 13:52:19 +01:00
Scott Sadler
04a78aacec Merge remote-tracking branch 'origin/master' into inputs-outputs 2016-12-22 13:45:02 +01:00
Brett Sun
2882bee48e Small flake8 fixes for tests (#987) 2016-12-22 11:57:13 +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
libscott
b2cb426097 Merge pull request #962 from bigchaindb/remove-asset-keywords
Remove asset keywords
2016-12-20 10:02:42 +01:00
Scott Sadler
4e17fe5c3d change fulfills.idx to fulfills.output 2016-12-19 12:29:29 +01:00
Scott Sadler
ed55b3984e s/fulfillments/inputs/g && s/conditions/outputs/g (code changes) 2016-12-19 12:29:29 +01:00
Scott Sadler
d2827dfae8 remove asset keywords 2016-12-16 13:50:23 +01:00
Sylvain Bellemare
56feefe3f4 Re-work test fixtures - iteration one 2016-12-15 15:54:15 +01:00
Scott Sadler
448ee87944 flatten transaction - code changes 2016-12-12 16:07:41 +01:00