Closed bluabaleno closed 1 year ago
Hey @bluabaleno! Thanks for the detailed issue :)
Currently this repo is only designed to work with foundry. The dependencies in the lib folder can be installed using the forge install
command. There is some work in progress to improve support for hardhat environments by changing the openzeppelin import paths. Feel free to give that branch a try to see if it helps address these issues.
Additionally, Remix seems to support remappings via a config file. You can try adding the remappings from remappings.txt to your remix environment and see if that helps.
Let me know if either of these options fixes the issues you're experiencing! Would love to better document the installation process for this repo for non-foundry environments.
Hello @jaydenwindle,
Thank you for your response. I've made some progress with your suggestions and have successfully deployed the Registry and the Standard Implementation contracts on the Avalanche testnet. Here are the links to the verified contracts:
Registry ERC6551 Implementation contract ERC721 contract ERC20 token contract I've also created a token-bounded account using the Registry contract and minted some ERC20 tokens to it. Here is the link to the token-bounded account.
However, I'm having some difficulty interacting with the token-bounded account via the implementation contract on the Avalanche blockscanner. From my understanding, I should call the executeCall function with the wallet that is currently holding the ERC721 token that is bound to the account. In my case, the holder is 0x41fF4FD74052847c9E96Be9B989d4528cA0efbf8, which holds an ERC721 token (contract 0x2aA3cc666f8c23974F96AdFaeCDabF7572B15676 tokenId 3).
I've tried to call the executeCall function from the Avalanche blockscanner, but I'm encountering some issues. I'm also not familiar with how to use Foundry to make transactions on the testnet. Could you provide some guidance on how to interact with the token-bounded account using the executeCall function, either through the Avalanche blockscanner or Foundry? Any help would be greatly appreciated. Thank you!
@bluabaleno Did you solve it?
I have published an NPM package that mirrors this repo and solves the issue
Hey @bluabaleno! We've made some changes to the source code of this repo which should make it easier to deploy via remix. We've updated the OZ imports to use hardhat-friendly paths and included a flattened version of the Registry contract. Going to close this for now, feel free to re-open if you're still running into issues with v0.3.0 :)
Hello,
I've been trying to compile the contracts in this repository using Remix IDE, but I've been running into some issues with the imports.
I cloned the repository to my local machine and used the remixd tool to connect Remix to my local filesystem. However, when I tried to compile the contracts in Remix, I encountered several issues.
Firstly, I noticed that the openzeppelin-contracts and forge-std directories in the lib directory are symbolic links. However, these directories are empty in my local copy of the repository, which suggests that the symbolic links are broken or that the libraries have not been installed correctly.
I tried to resolve this issue by installing the OpenZeppelin contracts using npm, which installed the contracts in the node_modules/@openzeppelin/contracts/ directory. However, this did not resolve the issue because the contracts in this repository are looking for the OpenZeppelin contracts in the lib/openzeppelin-contracts/contracts/ directory.
As a workaround, I tried copying the entire contracts directory from node_modules/@openzeppelin/contracts/ to lib/openzeppelin-contracts/contracts/, but I'm still running into import errors.
Additionally, when I opened the contracts in VSCode, I saw a linting error that says "global import of path ./ECDSA.sol is not allowed. Specify names to import individually". This error is coming from the Solidity linter, and it's flagging the global imports in the OpenZeppelin contracts. I understand that this is a linting error and not a compilation error, but it's still causing some confusion.
Could you provide some guidance on how to set up a local development environment for this repository and compile the contracts in Remix? Specifically, I'm wondering:
How should I install the OpenZeppelin contracts and any other dependencies? How should I set up the symbolic links in the lib directory? How should I configure the Solidity linter to avoid the "global import" error? Any help would be greatly appreciated. Thank you!