Cycle in the dependency graph - order of the files when deploying via Remix
Closed this issue · 1 comments
marsrobertson commented
I would like to use https://www.npmjs.com/package/truffle-flattener so that I can have a single file .sol
and deploy in Remix.
I'm encountering an issue:
truffle-flattener contracts/standard/permission/ArbitrableTokenList.sol
Error: There is a cycle in the dependency graph, can't compute topological ordering. Files:
contracts/standard/permission/ArbitrableTokenList.sol
/Users/mars/Code/kleros-interaction/contracts/standard/arbitration/Arbitrable.sol
/Users/mars/Code/kleros-interaction/contracts/standard/arbitration/IArbitrable.sol
/Users/mars/Code/kleros-interaction/contracts/standard/arbitration/Arbitrator.sol
/Users/mars/Code/kleros-interaction/contracts/standard/permission/PermissionInterface.sol
/Users/mars/Code/kleros-interaction/contracts/libraries/CappedMath.sol
at getSortedFilePaths (/Users/mars/.nvm/versions/node/v11.6.0/lib/node_modules/truffle-flattener/index.js:95:13)
Does it seem like there is a circular dependency? Looking at the deployed Etherscan code - https://etherscan.io/address/0xebcf3bca271b26ae4b162ba560e243055af0e679#code - it seems like it is working OK... What's the secret?
epiqueras commented
The compiler supports circular dependencies. They should be avoided, but
sometimes, like with ERC792, they are required.
truffle-flattener needs to implement that functionality.
…On Sun, Apr 14, 2019 at 4:27 AM Mars Robertson ***@***.***> wrote:
I would like to use https://www.npmjs.com/package/truffle-flattener so
that I can have a single file .sol and deploy in Remix.
I'm encountering an issue:
truffle-flattener contracts/standard/permission/ArbitrableTokenList.sol
Error: There is a cycle in the dependency graph, can't compute topological ordering. Files:
contracts/standard/permission/ArbitrableTokenList.sol
/Users/mars/Code/kleros-interaction/contracts/standard/arbitration/Arbitrable.sol
/Users/mars/Code/kleros-interaction/contracts/standard/arbitration/IArbitrable.sol
/Users/mars/Code/kleros-interaction/contracts/standard/arbitration/Arbitrator.sol
/Users/mars/Code/kleros-interaction/contracts/standard/permission/PermissionInterface.sol
/Users/mars/Code/kleros-interaction/contracts/libraries/CappedMath.sol
at getSortedFilePaths (/Users/mars/.nvm/versions/node/v11.6.0/lib/node_modules/truffle-flattener/index.js:95:13)
-
https://github.com/kleros/kleros-interaction/blob/master/contracts/standard/arbitration/IArbitrable.sol#L9
-
https://github.com/kleros/kleros-interaction/blob/master/contracts/standard/arbitration/Arbitrator.sol#L9
-
https://github.com/kleros/kleros-interaction/blob/master/contracts/standard/arbitration/Arbitrable.sol#L9
Does it seem like there is a circular dependency? Looking at the deployed
Etherscan code -
https://etherscan.io/address/0xebcf3bca271b26ae4b162ba560e243055af0e679#code
- it seems like it is working OK... What's the secret?
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#249>, or mute the
thread
<https://github.com/notifications/unsubscribe-auth/ASRQaFtDzyM8CNJgEPzdXGkWE6rZBiOdks5vgvRjgaJpZM4cug1g>
.