-
Notifications
You must be signed in to change notification settings - Fork 379
Open
Description
Here is a sample artifacts hierarchy structure to reproduce the bug:
contracts/1/interfaces/IOne.sol/IOne.json
contracts/2/interfaces/ITwo.sol/ITwo.json
Running typechain on a single directory works fine, typechain --target ethers-v5 --out-dir './typechain' './contracts/1/**/*.json' generates the following files:
./typechain/common.ts
./typechain/factories/index.ts
./typechain/factories/IOne__factory.ts
./typechain/index.ts
./typechain/IOne.ts
On the other hand, trying to generate the types for both contracts concurrently with typechain --target ethers-v5 --out-dir './typechain' './contracts/**/*.json' generates the following error:
Error occured: 'from' expected. (4:24)
2 | /* tslint:disable */
3 | /* eslint-disable */
> 4 | import type * as from './..';
| ^
5 | export type { };
6 | export * as 1 from './1';
7 | export * as 2 from './2';
and some files are generated outside the requested out-dir:
./1/interfaces/IOne.ts
./2/interfaces/ITwo.ts
./typechain/common.ts
Metadata
Metadata
Assignees
Labels
No labels