Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bugfix: python's api close was non-functional #1141

Merged
merged 2 commits into from Nov 22, 2017

Conversation

Projects
None yet
2 participants
@hackaugusto
Copy link
Collaborator

hackaugusto commented Nov 21, 2017

This fixes the python api close, add a regression test for that problem
and add general tests for it.

@hackaugusto

This comment has been minimized.

Copy link
Collaborator Author

hackaugusto commented Nov 21, 2017

this supersedes #434 and fixes #1138

@hackaugusto hackaugusto force-pushed the hackaugusto:raiden_api_test branch from 474b9a7 to 93abad4 Nov 21, 2017

@hackaugusto hackaugusto force-pushed the hackaugusto:raiden_api_test branch 3 times, most recently from e65b94e to edb0235 Nov 21, 2017

@hackaugusto hackaugusto force-pushed the hackaugusto:raiden_api_test branch from edb0235 to f72e594 Nov 21, 2017

@LefterisJP

This comment has been minimized.

Copy link
Collaborator

LefterisJP commented Nov 21, 2017

I am reviewing this one

@LefterisJP
Copy link
Collaborator

LefterisJP left a comment

Looks good to me. Some minor comments.

* :feature:`1097` Added `--gas-price` command line option
* :feature:`1038` Introduce an upper limit for the ``settle_timeout`` attribute of the netting channel
* :bug:`1044` Rename ``/connection`` API endpoint to ``/connections`` for consistency
* :bug:`1138` REST and Python API close did not working if a transfer was made.

This comment has been minimized.

Copy link
@LefterisJP

LefterisJP Nov 21, 2017

Collaborator

working ->work

* :feature:`921` Add ``/api/1/connection`` API endpoint returning information about all connected token networks.
* :bug:`1011` Remove ``settled`` attribute from the NettingChannel smart contract.

* :release:`0.1.0 <2017-09-12>`
* :release:`0.1.0 <2017-09-12>`.

This comment has been minimized.

Copy link
@LefterisJP

LefterisJP Nov 21, 2017

Collaborator

I think this appears as a section title in the changelog so it should not need a full stop at the end.

assert channel12.contract_balance == deposit
assert api1.get_channel_list(token_address, api2.address) == [channel12]

# there is a channel open, they must be checking each other

This comment has been minimized.

Copy link
@LefterisJP

LefterisJP Nov 21, 2017

Collaborator

checking -> healthchecking <--- being kind of pedantic here but anyway ..

amount = 10
assert api1.transfer(token_address, amount, api2.address)

api1.close(token_address, api2.address)

This comment has been minimized.

Copy link
@LefterisJP

LefterisJP Nov 21, 2017

Collaborator

as we discussed in the chat after you suggestions, add here more asserts after the close for the invariants of the channel state after close()

@LefterisJP

This comment has been minimized.

Copy link
Collaborator

LefterisJP commented Nov 21, 2017

PR is approved. Merge as soon as tests pass.

@hackaugusto hackaugusto force-pushed the hackaugusto:raiden_api_test branch from e939e08 to 816ea0a Nov 21, 2017

hackaugusto added some commits Nov 21, 2017

bugfix: python's api close was non-functional
This fixes the python api close, add a regression test for that problem
and add general tests for it.

@hackaugusto hackaugusto force-pushed the hackaugusto:raiden_api_test branch from 816ea0a to 33317be Nov 22, 2017

@hackaugusto hackaugusto merged commit 7512ebe into raiden-network:master Nov 22, 2017

1 check passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details

@hackaugusto hackaugusto deleted the hackaugusto:raiden_api_test branch Nov 22, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.