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

Database file got corrupted when running parity bridge #45

Open
peterjoel opened this issue Apr 20, 2018 · 12 comments
Open

Database file got corrupted when running parity bridge #45

peterjoel opened this issue Apr 20, 2018 · 12 comments

Comments

@peterjoel
Copy link

I'm running Parity-bridge, based on the current version of the README, using:

./parity-bridge/target/release/bridge --config config.toml --database db.toml

And my db.toml file is like this:

home_contract_address = "0x74A71bFb6C4903d79EbDd77C556D2d43A9346BdD"
foreign_contract_address = "0xD6fE4c32ADDe8e4b5eD6272Ecb5c434Dc7b120c4"
home_deploy = 2025251 # block number at which the contract was created for home contract you can find in `bridgeDeploymentResults.json`
foreign_deploy = 6923247 # block number at which the contract was created for foreign contract you can find in `bridgeDeploymentResults.json`
checked_deposit_relay = 2025251 # last checked deposits events on Home network
checked_withdraw_relay = 6923247 # last checked withdraw events on Foreign network
checked_withdraw_confirm = 6923247 # last checked withdraw events on Foreign network

However, once the parity-bridge process starts, the file gets corrupted. It looks like this:

home_contract_address = "0x74a71bfb6c4903d79ebdd77c556d2d43a9346bdd"
foreign_contract_address = "0xd6fe4c32adde8e4b5ed6272ecb5c434dc7b120c4"
home_deploy = 2025251
foreign_deploy = 6923247
checked_deposit_relay = 2026365
checked_withdraw_relay = 6924041
checked_withdraw_confirm = 6924041
loy = 6923247 # block number at which the contract was created for foreign contract you can find in `bridgeDeploymentResults.json`
checked_deposit_relay = 2025251 # last checked deposits events on Home network
checked_withdraw_relay = 6923247 # last checked withdraw events on Foreign network
checked_withdraw_confirm = 6923247 # last checked withdraw events on Foreign network

The Home and Foreign account balances show as zero, even though I transferred ETH into them, and I suspect this is the cause.

@peterjoel
Copy link
Author

Moved from omni/bridge-ui#26, which was the wrong repository.

@peterjoel
Copy link
Author

@snd It's probable that I had an extra process running - perhaps it didn't quit correctly on a previous run. Having restarted my machine cleanly, it works correctly now.

But even so, as you said on the other thread, it shouldn't be corrupting the file, regardless.

@peterjoel
Copy link
Author

peterjoel commented Apr 20, 2018

I take that back. It's still doing it.

I'm using the current master of both parity-bridge (commit e885fdf) and bridge-ui (commit 4aefece)

@snd
Copy link

snd commented Apr 20, 2018

could you try https://github.com/paritytech/parity-bridge/ to see whether your problem occurs there as well?

@peterjoel
Copy link
Author

Removing the comments in the Config.toml appears to have fixed it.

@snd
Copy link

snd commented Apr 20, 2018

strange

@maxidev
Copy link

maxidev commented Apr 30, 2018

Same problem here. +1

@igorbarinov
Copy link
Member

@yrashk any ideas why?

@maxidev
Copy link

maxidev commented Apr 30, 2018

Also deleting config.toml comments problem disapeared.

@akolotov
Copy link
Contributor

akolotov commented May 1, 2018

@maxidev could you provide more details on the exact project, branch and commit you are using to build the bridge. What steps to reproduce the issue are?

@maxidev
Copy link

maxidev commented May 1, 2018

@akolotov to have the bridge working I had to checkout to latest commit from Apr 11 (commit da91da9)
OS: Ubuntu server 16.04
Parity: 1.9.5 Stable
cargo --version
cargo 0.26.0 (41480f5cc 2018-02-26)

@yrashk
Copy link
Contributor

yrashk commented Jun 13, 2018

@maxidev have you tried any recent version of the bridge?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants