foundry icon indicating copy to clipboard operation
foundry copied to clipboard

Unclear error messaging on forge install

Open jordaniza opened this issue 4 years ago • 2 comments

Component

Forge

Have you ensured that all of these are up to date?

  • [X] Foundry
  • [X] Foundryup

What version of Foundry are you on?

forge 0.2.0 (7941935 2022-07-11T00:09:05.617669537Z)

What command(s) is the bug in?

forge install

Operating System

Linux

Describe the bug

Given installed packages forge-std openzeppelin-contracts, the command forge install @openzeppelin/contracts-upgradeable errors out with fatal: 'lib' already exists and is not a valid git repo

Interestingly forge install openzeppelin-contracts/contracts-upgradeable shows a different error message, relating to not being able to find the git repository.

This leads me to believe that @openzeppelin/contracts-upgradeable is being found successfully, but that it is in an unsupported format (potentially an npm registry).

Installing directly from the Oz repository, using the forge install https://github.com/OpenZeppelin/openzeppelin-contracts-upgradeable.git works.

Ideally I as a user would appreciate seeing a more detailed stack trace, or potential resolution options.

jordaniza avatar Jul 14 '22 15:07 jordaniza

How to use another version of openzeppelin? It keeps on popping up Error: fatal: empty string is not a valid pathspec. please use . instead if you meant to match all paths

vlavrenenko-ethers avatar Sep 15 '22 19:09 vlavrenenko-ethers

could you please open a separate issue for this with the command you're running

mattsse avatar Sep 15 '22 19:09 mattsse