Skip to main content

library to control placement in a hierarchy

Project description

crush

crush is a library to control placement in a hierarchy

GNU/Linux Installation

  • pip install crush

Other Installation

When using pip versions lower than 8.1 or other operating systems, compilation is necessary and packages must be installed first.

  • apt-get install -y gcc g++ python-pip python-all-dev libpython3-all-dev cmake libboost-all-dev libatomic-ops-dev

  • dnf / yum / zypper install -y gcc gcc-c++ python-pip python-devel python3-devel cmake make boost-devel libatomic_ops-devel

  • pip install crush

Hacking

  • Get the code:

    git clone http://libcrush.org/main/python-crush.git
    cd python-crush
  • Set up the development environment:

    deactivate || true ; source bootstrap
  • Run the tests:

    deactivate || true ; bash run-tests.sh
  • Sync the libcrush submodule:

    git submodule update --remote libcrush
  • Run a single test:

    tox -e py27 -- -s -k test_one tests/test_crush.py
  • Check the documentation:

    python setup.py build_sphinx
    firefox build/html/index.html
  • Update requirements

    rm -fr virtualenv virtualenv virtualenv source virtualenv/bin/activate # update some module in requirements.txt tox # if that works pip install -r requirements.txt pip freeze -r requirements.txt > new-requirements.txt .tox/py3/bin/pip freeze -r requirements-dev.txt > new-requirements-dev.txt diff <(.tox/py27/bin/pip freeze -r requirements-dev.txt) new-requirements-dev.txt # all lines after the first “were added by pip freeze” are indirect dependencies remove pkg-resources==0.0.0 https://bugs.launchpad.net/ubuntu/+source/python-pip/+bug/1635463

Release management

  • Prepare a new version

  • git checkout master ; git pull

  • version=1.0.0 ; perl -pi -e “s/^version.*/version = $version/” setup.cfg ; for i in 1 2 ; do python setup.py sdist ; amend=$(git log -1 –oneline | grep –quiet “version $version” && echo –amend) ; git commit $amend -m “version $version” ChangeLog setup.cfg ; git tag -a -f -m “version $version” $version ; done

  • Publish a new version

  • docker build –tag manylinux manylinux

  • docker run –rm -v $(pwd):/io manylinux /io/manylinux/build-wheels.sh OR docker run –rm -v $(pwd):/io manylinux env PYBINS=/opt/python/cp27-cp27mu/bin /io/manylinux/build-wheels.sh

  • sudo chown -R $(id -u) wheelhouse/

  • twine upload –sign wheelhouse/crush

  • rm -fr dist

  • python setup.py sdist

  • twine upload –sign dist/*.tar.gz

  • git push ; git push –tags

  • pypi maintenance

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

crush-1.0.34.tar.gz (351.1 kB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

crush-1.0.34-cp36-cp36m-manylinux1_x86_64.whl (2.5 MB view details)

Uploaded CPython 3.6m

crush-1.0.34-cp35-cp35m-manylinux1_x86_64.whl (2.5 MB view details)

Uploaded CPython 3.5m

crush-1.0.34-cp34-cp34m-manylinux1_x86_64.whl (2.5 MB view details)

Uploaded CPython 3.4m

crush-1.0.34-cp27-cp27mu-manylinux1_x86_64.whl (2.5 MB view details)

Uploaded CPython 2.7mu

File details

Details for the file crush-1.0.34.tar.gz.

File metadata

  • Download URL: crush-1.0.34.tar.gz
  • Upload date:
  • Size: 351.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for crush-1.0.34.tar.gz
Algorithm Hash digest
SHA256 0ca77459b734d48d296862f3cf3474ccc29066cab0b67c9dd7a01e129def95f6
MD5 5ded473ff65538e888df90d2fe044b7c
BLAKE2b-256 f9ace02ed469a39dcdd7851e122fc57d777c3f0a5dcf7d35efe7b553f7214004

See more details on using hashes here.

File details

Details for the file crush-1.0.34-cp36-cp36m-manylinux1_x86_64.whl.

File metadata

File hashes

Hashes for crush-1.0.34-cp36-cp36m-manylinux1_x86_64.whl
Algorithm Hash digest
SHA256 0ed0627dd1e19ba721a4df57936cbbbd0055346ab6987c86c0a6157790410f50
MD5 e25483ee593e9f1d088eba28056b25d9
BLAKE2b-256 e08fc23cac1fda071edb56e4a1dfdd00ea29336fb5f234221df6840fea7e99b8

See more details on using hashes here.

File details

Details for the file crush-1.0.34-cp35-cp35m-manylinux1_x86_64.whl.

File metadata

File hashes

Hashes for crush-1.0.34-cp35-cp35m-manylinux1_x86_64.whl
Algorithm Hash digest
SHA256 98ad3fa615e61e787e912aef7649591283cb4c1a910d09507b63b315844d861e
MD5 3ce3be9fd8962b3bfe96f845c4c6ce21
BLAKE2b-256 bd99f1fe8342d7399f8e75e66bed0d11a412b063b1a276fa5299a94684effc6b

See more details on using hashes here.

File details

Details for the file crush-1.0.34-cp34-cp34m-manylinux1_x86_64.whl.

File metadata

File hashes

Hashes for crush-1.0.34-cp34-cp34m-manylinux1_x86_64.whl
Algorithm Hash digest
SHA256 f39dc2dc3ed010fc1433fced6e5b958b0ee7a359a48c282a7b01b96d30628afe
MD5 b9e90078413a8ee75f343857460c0f72
BLAKE2b-256 8f8fd79db80cca7b760bb95e92bb17de1a2936cf53212471f9020a18704c96fc

See more details on using hashes here.

File details

Details for the file crush-1.0.34-cp27-cp27mu-manylinux1_x86_64.whl.

File metadata

File hashes

Hashes for crush-1.0.34-cp27-cp27mu-manylinux1_x86_64.whl
Algorithm Hash digest
SHA256 c60e610a064bdbdc6e2e2c5eb79930790ed722ddc39881404cb79da701d4a553
MD5 a27eeb8f509cd82652187be6bbe187bd
BLAKE2b-256 959fc3b5faf0ccbb0098ab525edf1f401eeb3d1584afa76c4e83259819d1336e

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page