-
Notifications
You must be signed in to change notification settings - Fork 155
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
Remove dependency on cardano-prelude #2992
Conversation
e8f1da3
to
9bc84b2
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great. As you did notice we do need to remove some duplication though
eras/alonzo/test-suite/src/Test/Cardano/Ledger/Alonzo/Serialisation/Generators.hs
Outdated
Show resolved
Hide resolved
eras/alonzo/test-suite/test/Test/Cardano/Ledger/Alonzo/Golden.hs
Outdated
Show resolved
Hide resolved
9bc84b2
to
ca54877
Compare
2c9c4d0
to
6413277
Compare
d60414d
to
516d786
Compare
e766385
to
31843b7
Compare
31843b7
to
13ec291
Compare
13ec291
to
a72e63a
Compare
I'm trying to do a similar thing, and I've had to change a lot of |
96a42c1
to
b581958
Compare
so that running cabal from within the shell doesn't have to (which sometimes fails). Update plutus version and adjust to API changes Update cardano-base to a version compatible with plutus Allow newer version of `hashable` since plutus brings in version 1.4.1.0 but our dependency Unique is restricting it to 1.4. Regenerate PlutusScript using plutus-preprocessor Fix Plutus protocol version in test which was wrong, but only started failing with the new plutus version
so that running cabal from within the shell doesn't have to (which sometimes fails). Update plutus version and adjust to API changes Update plutus to latest version Update cardano-base to a version compatible with plutus Allow newer version of `hashalble` since plutus brings in version 1.4.1.0 but our dependency Unique is restricting it to 1.4. [WIP] Try and fail to adapt code to newest Plutus Replace `panic` function from cardano-prelude with `error` Update cardano-base to a version without cardano-prelude Use HeapWords from cardano-base instead of cardano-prelude Remove dependency on cardano-prelude from everywhere except byron Update cardano-base
516d786
to
eadaf0f
Compare
c58f03f
to
bec947a
Compare
This PR brings ledger up to date with latest plutus and cardano-base as well as removes dependency on cardano-prelude. We need to unblock @erikd and others on their effort to update ghc-9.2 Becuase @teodanciu is off on Monday I took it upon myself to address all the review comments and incorporated #3030 into this PR as well. If there is anything else needs to be done for this PR we can tackle it in a subsequent one at a later point. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great. Thank you for doing all the work @teodanciu If there were any other plans for this PR we can postpone it to a later PR.
@JaredCorduan Once you back, it would be nice if you could take a second look at this PR, even though it will merged. It will be valuable, since you are the most familiar person with the Plutus Cost Models in ledger
Most definitely, I am very keen to review this one carefully. thanks for the heads up. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you so much for doing these two items @teodanciu , it looks great! (and you too @lehins for getting it across the line!)
It's going to be wonderful having these changes to the evaluation context (I reviewed it all very carefully).
I made one small followup issue: #3042
Thank you @JaredCorduan |
Update `plutus` and `cardano-base` dependencies. Remove usage of `cardano-prelude`: * Update nix shell to prebuild packages and make them available to ghc-pkg so that running cabal from within the shell doesn't have to (which sometimes fails). * Update plutus version and adjust to API changes * Update cardano-base to a version compatible with plutus and without cardano-prelude * Allow newer version of `hashable`, since plutus brings in version 1.4.1.0, but our dependency Unique is restricting it to 1.4. * Regenerate `PlutusScript` using `plutus-preprocessor` * Fix Plutus protocol version in test, which was wrong, but only started failing with the new plutus version * Replace `panic` function from `cardano-prelude` with `error` * Use HeapWords from cardano-base instead of cardano-prelude * Remove dependency on `cardano-prelude` from everywhere except byron Co-authored-by: Alexey Kuleshevich <alexey.kuleshevich@iohk.io>
Update `plutus` and `cardano-base` dependencies. Remove usage of `cardano-prelude`: * Update nix shell to prebuild packages and make them available to ghc-pkg so that running cabal from within the shell doesn't have to (which sometimes fails). * Update plutus version and adjust to API changes * Update cardano-base to a version compatible with plutus and without cardano-prelude * Allow newer version of `hashable`, since plutus brings in version 1.4.1.0, but our dependency Unique is restricting it to 1.4. * Regenerate `PlutusScript` using `plutus-preprocessor` * Fix Plutus protocol version in test, which was wrong, but only started failing with the new plutus version * Replace `panic` function from `cardano-prelude` with `error` * Use HeapWords from cardano-base instead of cardano-prelude * Remove dependency on `cardano-prelude` from everywhere except byron Co-authored-by: Alexey Kuleshevich <alexey.kuleshevich@iohk.io>
Update `plutus` and `cardano-base` dependencies. Remove usage of `cardano-prelude`: * Update nix shell to prebuild packages and make them available to ghc-pkg so that running cabal from within the shell doesn't have to (which sometimes fails). * Update plutus version and adjust to API changes * Update cardano-base to a version compatible with plutus and without cardano-prelude * Allow newer version of `hashable`, since plutus brings in version 1.4.1.0, but our dependency Unique is restricting it to 1.4. * Regenerate `PlutusScript` using `plutus-preprocessor` * Fix Plutus protocol version in test, which was wrong, but only started failing with the new plutus version * Replace `panic` function from `cardano-prelude` with `error` * Use HeapWords from cardano-base instead of cardano-prelude * Remove dependency on `cardano-prelude` from everywhere except byron Co-authored-by: Alexey Kuleshevich <alexey.kuleshevich@iohk.io>
Update `plutus` and `cardano-base` dependencies. Remove usage of `cardano-prelude`: * Update nix shell to prebuild packages and make them available to ghc-pkg so that running cabal from within the shell doesn't have to (which sometimes fails). * Update plutus version and adjust to API changes * Update cardano-base to a version compatible with plutus and without cardano-prelude * Allow newer version of `hashable`, since plutus brings in version 1.4.1.0, but our dependency Unique is restricting it to 1.4. * Regenerate `PlutusScript` using `plutus-preprocessor` * Fix Plutus protocol version in test, which was wrong, but only started failing with the new plutus version * Replace `panic` function from `cardano-prelude` with `error` * Use HeapWords from cardano-base instead of cardano-prelude * Remove dependency on `cardano-prelude` from everywhere except byron Co-authored-by: Alexey Kuleshevich <alexey.kuleshevich@iohk.io>
* Remove dependency on cardano-prelude (#2992) Update `plutus` and `cardano-base` dependencies. Remove usage of `cardano-prelude`: * Update nix shell to prebuild packages and make them available to ghc-pkg so that running cabal from within the shell doesn't have to (which sometimes fails). * Update plutus version and adjust to API changes * Update cardano-base to a version compatible with plutus and without cardano-prelude * Allow newer version of `hashable`, since plutus brings in version 1.4.1.0, but our dependency Unique is restricting it to 1.4. * Regenerate `PlutusScript` using `plutus-preprocessor` * Fix Plutus protocol version in test, which was wrong, but only started failing with the new plutus version * Replace `panic` function from `cardano-prelude` with `error` * Use HeapWords from cardano-base instead of cardano-prelude * Remove dependency on `cardano-prelude` from everywhere except byron Co-authored-by: Alexey Kuleshevich <alexey.kuleshevich@iohk.io> * Fix plutus-preprocessor * Allow newer base (9.2) * Add 9.2 to workflows * 9.2 mechanical changes * cabal.project cleanup * Bump minor version This adds 9.2 compatibility 1.1.1 -> 1.1.2 1.4.1 -> 1.4.2 * Fix errors due to newer dependencies. Also need to bump the protocol version, otherwise the test-suite will fail. * Also bump cabal version in shell.nix Co-authored-by: teodanciu <teodora.danciu@tweag.io> Co-authored-by: Alexey Kuleshevich <alexey.kuleshevich@iohk.io> Co-authored-by: Michael Peyton Jones <michael.peyton-jones@iohk.io> Co-authored-by: Joosep Jääger <joosep.jaager@iohk.io>
This PR also updates
plutus
andcardano-base
dependencies.The initial purpose of this was to remove the dependency on cardano-prelude. It turns out a good amount of yak-shaving was necessary to achieve this, in the form of updating plutus and adapting to the API changes. Also a change in nix-shell, without which cabal from within the nix-shell could not resolve plutus dependencies (for nix reasons).
You might need to delete ~/.cabal/store/ghc-8.10.7 in order for cabal to get the new plutus version properly. Before deleting this I was getting errors like this:
So if this happens to you, you might want to 1) delete this folder 2) brace yourself with patience
resolves #1676