-
Notifications
You must be signed in to change notification settings - Fork 866
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
gh-actions fails for foundry #607
Comments
No. 8 and 9 are not necessary, change the GitHub URL directly from the project rather than copying the whole files into another folder |
Thanks for reporting this @Hotmanics ! You are right! Since the GitHub action env doesn't have anvil / forge installed, it can't init the local node + deploy contracts I think the solution might be to use https://github.com/marketplace/actions/foundry-toolchain on the projects using the foundry template. |
I'm using I ended up coming up with some hacky work-around for the build stage that was also failing (unmet dependency from another package).
I do have the CI lint stage fully passing and working with foundry now though. Do you want me to open a PR with my changes made? |
That's great. I saw that you added foundry toolchain. It'd be great if you could make a PR. Take a look at the CLI branch and the docs for devs, which explain a bit how to contribute to the CLI branch (it's trickier than contributing to
Never happened before to me (but similar ones did happen). Since we don't have a yarn.lock file on the CLI branch (it'd depend on the CLI user selection), the solution could be to lock the dep in package.json file (eg. 2.0.0 instead of ~2.0.0). If you open a PR we can assist you there too! Thanks @Hampton-Black !! |
Attempting to do this... I added
to the however when I try
It errors out when looking for an etherscan environment variable (obviously, since .env files do not get pushed to github). Not sure on the best plan of action there...? Additionally, modifying the command to be
leaves the check stuck in a never-ending check that never progresses to the next job. Anyone have any suggestions for this? |
Hey @Hotmanics ! You could do something like (got it from @Hampton-Black repo):
Where you specify the env variable there (using GitHub secrets in this case). I guess you could even have a random/fake API KEY (so it won't complain) since this is just deploying it on the local chain that spins for checking the linting. Let us know how it goes! Thanks. |
Sorry I haven't done the PR yet for this. I'm still planning to, but might have to wait until after the hackathon is finished (next weekend). |
Seems to of fixed the issue regarding the env variable thank you. But now getting stuck for HOURS on the yarn chain aspect. |
will be eagerly anticipating this and glad to help push it forward however I can. |
Hey @Hampton-Black, please let us know if you need any help / stuck with |
Might need some help. I have it splitting up the github workflow files how I want now, but I'm getting errors with initializing the repo now via the CLI tool. Here's my fork: https://github.com/Hampton-Black/scaffold-eth-2/tree/607-gh-actions-lint-split and a sample actions pipeline: https://github.com/Hampton-Black/cli-test-5/actions/runs/7304157195 |
I think its better if we keep it simple for the first PR. We don't want to split job as I see in https://github.com/Hampton-Black/cli-test-5/actions/runs/7304157195, Actually we want to run frontend lint after So for initial draft PR:
next we can iterate on created PR, Thanks @Hampton-Black 🙌 |
Completed at scaffold-eth#38 |
Is there an existing issue for this?
Current Behavior
When using a project built with "npx create-eth@latest" and the selected option for "What solidity framework do you want to use" is "Foundry", then any time successfully push commit to GitHub, the Git Hooks will fail on the step "Run hardhat node, deploy contracts (& generate contracts typescript output)".
Expected Behavior
When pushing a commit to GitHub while using a project built from "npx create-eth@latest" and Foundry is the selected Solidity Framework, then the Git Hooks should succeed in deploying a local foundry chain and deploy contracts (& generate contracts typescript output).
Steps To Reproduce
Anything else?
You can see my current implementation in my own project here: https://github.com/ATXDAO/reputation-and-roles-monorepo/actions/runs/6869607334/job/18682721792
The text was updated successfully, but these errors were encountered: