leo
leo copied to clipboard
[Bug] External Record Input with Nested Imports
🐛 Bug Report
With the following import scheme:
child -> inter -> parent
When child
defines a record, an error will be thrown if inter
defines a transitions that has this external record as an argument.
Steps to Reproduce
- Create 3 programs:
leo new child
:
program child.aleo {
record child_rec {
owner: address
}
transition main(t: child_rec) {}
}
leo new inter
:
import child.aleo;
program inter.aleo {
transition use_child(c: child.aleo/child_rec){}
}
leo new parent
:
import inter.aleo;
program parent.aleo {
transition main() {}
}
- Add the right dependencies:
cd inter
leo add child --local ../child
cd ..
cd parent
leo add inter --local ../inter
cd ..
- Build
parent
:
cd parent
leo build
Error message
Error [ETYC0372017]: The type `child` is not found in the current scope.
The error can be produced after building latest Leo source, default branch.