Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

[MAINTENANCE] - Remove usages of `SafeHash`

Open
#952 8 comments 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

Assessment

Difficulty
5/5
Estimated time
Over a week
Newbie friendliness
30/100
Issue type
Refactor
Clarity
Needs clarification
Activity status
Quiet
Tech stack
haskell
Domain
blockchain, cli

Research direction

Search the repository for all usages and unsafe creations of SafeHash, then trace each use to determine whether its source can be tracked. Review the affected Cardano CLI and API interfaces first; done means usages use unverified Hash except where conversion at a lower-level interface is unavoidable.

Written by the indexing model from the issue text.

Description

refactor Stale

What

Replace all usages of SafeHash with unverified Hash unless in cases where it is possible to track the source of the hash. If somewhere this is unavoidable, wait till the last second before unsafely converting to SafeHash.

Why

SafeHash is meant to encode that the hash has a pre-image, but this is not enforceable most of the time in practice, since both cardano-cli and cardano-api are often provided with the hash only, not with the pre-image.

Acceptance Criteria

  • There are no unsafe creations of SafeHash with the possible exception of just before interfaces with modules down the stack if unavoidable.
Dominant language
Haskell
Stars
72
Forks
25
Avg merge
2d 1h
Merged PRs (30d)
8

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from IntersectMBO/cardano-cli

All issues in IntersectMBO/cardano-cli

Similar issues

More Haskell issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.