Cardano Node 1.33.0 Failure: Failed to build katip-0.8.7.0

Hello,

Anyone experience the following failure while compiling cardano-node at 1.33.0?

Steps leading up to the failure:

sudo systemctl stop cnode
cd ~/git
sudo rm -R cardano-node
git clone GitHub - input-output-hk/cardano-node: The core component that is used to participate in a Cardano decentralised blockchain.
cd cardano-node
git fetch --tags --all
git checkout 1.33.0
echo -e “package cardano-crypto-praos\n flags: -external-libsodium-vrf” > cabal.project.local
$CNODE_HOME/scripts/cabal-build-all.sh

Shortly after I received below exception. Did I miss anything?

[35 of 35] Compiling Flat ( src/Flat.hs, /home/adauser/git/cardano-node/dist-newstyle/build/x86_64-linux/ghc-8.10.2/flat-0.4.5/build/Flat.o, /home/adauser/git/cardano-node/dist-newstyle/build/x86_64-linux/ghc-8.10.2/flat-0.4.5/build/Flat.dyn_o )
[6 of 7] Compiling Test.Goblin.Explainer ( src/Test/Goblin/Explainer.hs, /home/adauser/git/cardano-node/dist-newstyle/build/x86_64-linux/ghc-8.10.2/goblins-0.2.0.0/build/Test/Goblin/Explainer.o, /home/adauser/git/cardano-node/dist-newstyle/build/x86_64-linux/ghc-8.10.2/goblins-0.2.0.0/build/Test/Goblin/Explainer.dyn_o )
[7 of 7] Compiling Test.Goblin ( src/Test/Goblin.hs, /home/adauser/git/cardano-node/dist-newstyle/build/x86_64-linux/ghc-8.10.2/goblins-0.2.0.0/build/Test/Goblin.o, /home/adauser/git/cardano-node/dist-newstyle/build/x86_64-linux/ghc-8.10.2/goblins-0.2.0.0/build/Test/Goblin.dyn_o )

Failed to build katip-0.8.7.0.
Build log (
/home/adauser/.cabal/logs/ghc-8.10.2/katip-0.8.7.0-504237a774189f34b162e2f3ed5172189bb0406c957301508a365532eff9d97e.log
):
Configuring library for katip-0.8.7.0…
Preprocessing library for katip-0.8.7.0…
Building library for katip-0.8.7.0…
[1 of 5] Compiling Katip.Core ( src/Katip/Core.hs, dist/build/Katip/Core.o, dist/build/Katip/Core.dyn_o )

src/Katip/Core.hs:114:74: error:
• No instance for (TH.Lift Text)
arising from the first field of ‘Namespace’ (type ‘[Text]’)
Possible fix:
use a standalone ‘deriving instance’ declaration,
so you can specify the instance context yourself
• When deriving the instance for (TH.Lift Namespace)
|
114 | deriving (Eq,Show,Read,Ord,Generic,ToJSON,FromJSON,SG.Semigroup,Monoid,TH.Lift)
| ^^^^^^^
cabal: Failed to build katip-0.8.7.0 (which is required by exe:tx-generator
from tx-generator-1.32, test:cardano-testnet-tests from cardano-testnet-1.33.0
and others). See the build log above for details.

Copying unit to /home/adauser/.cabal/bin/

I’m not sure what $CNODE_HOME/scripts/cabal-build-all.sh, maybe it already contains that… but dir you try to do an “cabal update” before building?

Are u using cntools guide or coincashew?

If u are using cntools u can use my script (for CNTOOLS only) for upgrade from now on

wget https://raw.githubusercontent.com/Alexd1985/node_software_upgrade_script/main/software_upgrade.sh

chmod 750 software_upgrade.sh
./software_upgrade.sh

1 Like

I am using cntools guide and will checkout your script.

@Alexd1985 / @georgem1976 : Unfortunately even after trying with “cabal update” and using the provided script I am still faced with same error during build. This time the results is after running the script: “software_upgrade.sh”:

Configuring library for katip-0.8.7.0…
Preprocessing library for katip-0.8.7.0…
Building library for katip-0.8.7.0…
[1 of 5] Compiling Katip.Core ( src/Katip/Core.hs, dist/build/Katip/Core.o, dist/build/Katip/Core.dyn_o )

src/Katip/Core.hs:114:74: error:
• No instance for (TH.Lift Text)
arising from the first field of ‘Namespace’ (type ‘[Text]’)
Possible fix:
use a standalone ‘deriving instance’ declaration,
so you can specify the instance context yourself
• When deriving the instance for (TH.Lift Namespace)
|
114 | deriving (Eq,Show,Read,Ord,Generic,ToJSON,FromJSON,SG.Semigroup,Monoid,TH.Lift)
| ^^^^^^^
cabal: Failed to build katip-0.8.7.0 (which is required by exe:tx-generator
from tx-generator-1.32, test:cardano-testnet-tests from cardano-testnet-1.33.0
and others). See the build log above for details.

Copying unit to /home/adauser/.cabal/bin/
The software upgrade is succesfully, starting the node
The node has been started… opening gLiveView!

Checking for script updates…

Anything else to consider?

Try run the prereqs

cd ~/tmp
./prereqs.sh

Or not, I found something related

the solution was:


I'm not sure what the exact cause of this error was, but I have managed to work around the issue by adding a constraint for katip in the cabal.project file:

constraints:
    hedgehog >= 1.0
  , bimap >= 0.4.0
  , libsystemd-journal >= 1.4.4
  , systemd >= 2.3.0
    -- systemd-2.3.0 requires at least network 3.1.1.0 but it doesn't declare
    -- that dependency
  , network >= 3.1.1.0
  , katip <= 0.8.4.0
Hopefully this will be useful to others.

@Alexd1985 : Thanks for the follow up. Worked like a charm! The addition of:

, katip <= 0.8.4.0

Was needed as the workaround as pointed out by @bennyguk of github. Many thanks again for your reactivity!

…output truncated…
This version range includes the current package but isn’t needed as the
current package’s library will always be used.
Preprocessing executable ‘tx-generator’ for tx-generator-1.32…
Building executable ‘tx-generator’ for tx-generator-1.32…
[1 of 1] Compiling Main ( app/tx-generator.hs, /git/cardano-node/dist-newstyle/build/x86_64-linux/ghc-8.10.2/tx-generator-1.32/x/tx-generator/build/tx-generator/tx-generator-tmp/Main.o )
Linking /git/cardano-node/dist-newstyle/build/x86_64-linux/ghc-8.10.2/tx-generator-1.32/x/tx-generator/build/tx-generator/tx-generator …
Copying setup to …

real 49m56.424s
user 115m34.510s
sys 6m48.434s

Glade u fixed :beers:

Sorry I have small problem the only block I did disappeared after the upgrade

image

is this normal?

Yes, this interface remembers only the blocks minted since the node started.
If you want to see them after restart, too, you will have to integrate the cncli.sh better (run a few other services):

  • cncli.sh sync
  • cncli.sh leaderlog
  • cncli.sh validate
    I believe there other people who know better how cncli.sh works, there is probably an option to automatically configure the services.

Thanks, I tried to run the sync cncli.sh sync got the following

image

I am not sure to put this file originally it was on tmp, I put it there same error.

you will need to install (the cncli)
cd ~/tmp
./prereqs.sh -c

then nano cncli.sh (from scripts folder) and edit the pool ID + uncomment the line

Then try again
./cncli.sh sync
./cncli.sh init

1 Like

I think everything seems to work now. but on the gLiveview the block still not dsplayed

image

maybe BP needs to be restarted.

@Alexd1985 thanks

You will not see the block anymore on glive
If u want to see it go to ./cntools.sh → blocks → enter → enter

1 Like

Now that I can see it, I can sleep :smiley:
image
thanks

2 Likes

im running into the same issue while im following the stake pool course and cannot locate cabal.project file in any directory. idk what i did wrong… frustrated at this point…

Correction… found file and edited per instructions. Now must i delete everything and start over? Or is there a way to update the software compilation with this edit in the cabal programming file still intact?

1 Like

Which issue? Can u explain?

yes my apologies. i got the failed to build katip 0.8.7.0 error upon node installation. i edited the cabal.project file per instructions. what im trying to ask is what is needed to be done after the file addition? do i need to untistall then re install all dependancies other than cabal and start over?
thank you for your time. i am learning.

u are using cntools or coincashew guide?