inkdevhub / drink

De-chained Ready-to-play ink! playground
Apache License 2.0
69 stars 15 forks source link

Move code to "macros" and "session" features #110

Closed pgherveou closed 7 months ago

pgherveou commented 7 months ago

Moved bundle and mocking under session. Alternatively we could keep it where it is but put this code behind other feature flags

This change is needed, cause the current setup introduce dependency cycle with ink!. ink! should import drink! without the session feature to avoid creating a dependency cycle

pmikolajczyk41 commented 7 months ago

what exactly is the dependency cycle? drink doesn't depend on ink!, does it?

pgherveou commented 7 months ago

what exactly is the dependency cycle? drink doesn't depend on ink!, does it?

it does through contract-transcode (that is only required by feature session after this PR), we don't need all the session stuff in ink! as well

ascjones commented 7 months ago

what exactly is the dependency cycle? drink doesn't depend on ink!, does it?

it does through contract-transcode (that is only required by feature session after this PR), we don't need all the session stuff in ink! as well

Exactly.

drink -> contract-transcode -> ink_metadata + ink_env
^                                               ^
|                                               |
ink_e2e ----------------------------------------