Skip to main content

Codehash

Installing

Install and update using Pip.

pip install -U codehash

A simple example

from codehash import hash_function

dct = {'a': 1}

def f(x):
    return 1 + dct["param"]

h1 = hash_function(f)

def f(x):
    """Docstring."""
    return 1 + dct["param"]  # comment

h2 = hash_function(f)

dct = {'a': 2}

def f(x):
    return 1 + dct["param"]

h3 = hash_function(f)

assert h1 == h2
assert h1 != h3

Release files for codehash 0.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for codehash 0.1.0
File Size Uploaded
codehash-0.1.0.tar.gz 9.2 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for codehash 0.1.0
File Interpreter ABI Platform
codehash-0.1.0-py3-none-any.whl Python 3 none any Details

Total release size: 18.3 kB

Release files / codehash-0.1.0.tar.gz

Download URL codehash-0.1.0.tar.gz
Size 9.2 kB
Tags Source
SHA-256 checksum
How to use checksums
e1232e80c100c47a7f644a6652ba3514c3f2fb8c7e6a06f2a2a8684d2a445792
BLAKE2b-256 checksum
How to use checksums
7650d111c463629e9dedada948dc60dcb94bdc8177a56bbf0350755c48513055
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.1.5 CPython/3.9.2 Darwin/19.6.0

Release files / codehash-0.1.0-py3-none-any.whl

Download URL codehash-0.1.0-py3-none-any.whl
Size 9.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
f83bd2f09e378dac2dfd4752fc08ad457335bcc6d54c261d6e09ce0ac0d7a93c
BLAKE2b-256 checksum
How to use checksums
635f74c1c7492402e1000b1c22a88fc90ce8ac7180e84b0188215b1a019f1078
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.1.5 CPython/3.9.2 Darwin/19.6.0

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page