Skip to content
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

Use liqwid-nix; Bump plutarch #150

Merged
merged 10 commits into from
Aug 12, 2022
Merged

Use liqwid-nix; Bump plutarch #150

merged 10 commits into from
Aug 12, 2022

Conversation

chfanghr
Copy link
Contributor

@chfanghr chfanghr commented Jul 30, 2022

This pr bumps plutarch to version 1.2 and refactors the nix setup with liqwid-nix.

Some caveats regrading the new version of plutarch:

  • Unable to derivePDataFieldsfor a newtype of PDataRecord, which derives its PlutusType instance using PlutusTypeNewtype strategy. Workaround: pto before pletField.
  • Missing PTryfrom PData instances for PAsData _/PUnit/PDatumHash. Workaround: implemented orphan instances in Agora.Plutarch.Orphans. Great thanks to @emiflake for debugging a plutarch compile time infinite recursion bug related to this!
  • development flag which controled whether to include tracing message in the compiled scripts or not has been replaced by Config. This dramatically changes the way we parameterize the scripts, especially when they have dependent relationship.
  • Addition logic of plutarch's compilation pipeline has slowdowned the compilation speed quite a bit, meaning that we have to compile scripts ahead of time for benchmarking and testing purposes. With this strategy, our sample test suite (which contains 1053 test cases) can now finish in 2.17~s (Apple M1, 8 threads), which is 250 times faster.

@chfanghr chfanghr requested review from emiflake and SeungheonOh July 30, 2022 15:51
@SeungheonOh
Copy link
Contributor

Deriving parts looks so much cleaner. Well done.

@chfanghr chfanghr force-pushed the connor/liqwid-nix branch 3 times, most recently from 11a1ebd to ebe0c55 Compare August 2, 2022 13:15
@chfanghr chfanghr force-pushed the connor/liqwid-nix branch 17 times, most recently from f044745 to 658b46d Compare August 5, 2022 16:05
@chfanghr chfanghr force-pushed the connor/liqwid-nix branch 2 times, most recently from 71ebf22 to fdfc329 Compare August 8, 2022 12:10
@chfanghr chfanghr force-pushed the connor/liqwid-nix branch from 4d7ee30 to 53bfffc Compare August 9, 2022 11:58
@chfanghr chfanghr force-pushed the connor/liqwid-nix branch 9 times, most recently from c536b18 to 6ca2ec1 Compare August 11, 2022 12:03
@chfanghr chfanghr marked this pull request as ready for review August 11, 2022 12:34
@chfanghr chfanghr force-pushed the connor/liqwid-nix branch 3 times, most recently from 7bc3e1a to 219b676 Compare August 11, 2022 14:21
Copy link
Member

@emiflake emiflake left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Happy to merge as is, if/when CI works.

@chfanghr chfanghr force-pushed the connor/liqwid-nix branch 2 times, most recently from 95aced2 to 4a3e93b Compare August 11, 2022 20:45
@emiflake emiflake merged commit 8516dec into staging Aug 12, 2022
@emiflake emiflake deleted the connor/liqwid-nix branch November 7, 2022 17:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

4 participants