Skip to main content

General instructions for building for pip distribution

After changing setup.py or any part of the Graffiti codebase, increase the version number in setup.py appropriately, around line 37.

Then run the commands shown below to upgrade what's stored in pip

python3 setup.py prep_to_build npm_run_build sdist bdist_wheel

If you yet don't have twine installed, you need to do pip3 install twine.

Now, uploading to the pypi test servers:

python3 -m twine upload --repository-url https://test.pypi.org/legacy/ dist/* --verbose

(For User name you can use willkessler.)

Installing to a host in the cloud, from the test servers:

python3 -m pip install --index-url https://test.pypi.org/simple/ jupytergraffiti

Testing new installation on cloud host:

jupyter notebook —port=3001 —ip=127.0.0.1 —allow-root

Uploading to the pypi production servers:

python3 -m twine upload dist/*

(For User name you can use willkessler.)

General instructions for building for conda distribution

NB: this relies on jupytergraffiti being in the main (production) pypi repository. First time steps:

mkdir conda
cd conda
rm -rf jupytergraffiti
# Note that after twine upload to pip, above, there will be about 30 seconds before the new build is accessible to conda.
conda skeleton pypi jupytergraffiti
conda install conda-verify

Modify jupytergraffiti/meta.yaml to include build noarch: python and set recipe-maintainers on the last line. Modify jupytergraffiti/meta.json to include github handle: willkessler (appears unnecessary now)

(Re)building on macosx:

(After you make updates, make sure to bump the version number in jupytergraffiti/meta.yml.

conda build jupytergraffiti
export GRAFFITI_VERSION=1.0.1.18
anaconda upload ~/anaconda3/conda-bld/noarch/jupytergraffiti-$GRAFFITI_VERSION-py_0.tar.bz2

You may need to log in with willkessler and the same password you use for pip uploads. (Optional)

Then you want to convert to other architectures and upload these as well:

conda convert --platform all ~/anaconda/conda-bld/osx-64/jupytergraffiti-<version>-py36_0.tar.bz2 -o linux64_out
anaconda upload linux64_out/linux-64/jupytergraffiti-<version>-py36_0.tar.bz2

... etc for all the architectures you want to support. This last step doesn't seem to be necessary any more (01/23/2020).

Finally...

To install and test you should be able to do :

conda install -c willkessler jupytergraffiti

You can test on Udacity streamed linux desktops with:

jupyter notebook —port=3001 —ip=127.0.0.1 —allow-root

Building for Windows and building for pip on Windows

To debug issues on Windows, you need to have cygwin64 and node installed on the system. Then you need to use jupytergraffiti/package.json_windows instead of jupytergraffiti/package.json. This version of package.json has a different build step using utilities provided by Cygwin:

...
  "scripts": {
    "build": "/cygwin64/bin/rm.exe -rf graffiti-dist build ../build_for_pip/code-prep && node node_modules/gulp/bin/gulp.js prebuild && cd node_modules/.bin && r_js.cmd -o ../../build.js && cd ../.. && node ./node_modules/gulp/bin/gulp.js moveStyles && cd node_modules/.bin && r_js.cmd -o ../../../build_for_pip/buildPip.js && cd ../.. && node ./node_modules/gulp/bin/gulp.js pipMoveStyles"
  },
...

You can follow the steps above to build for pip. For creating the pip artifact, from this directory do:

python3 setup.py prep_to_build npm_run_build sdist bdist_wheel

but then you can install from this build, without uploading to pypi servers, by simply :

  1. unpacking the tarball found in the dist directory
  2. switching to the unpack directory
  3. finally: pip install .

Metadata

Release files for jupytergraffiti 1.0.1.20

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

Source distribution (sdist)

Source distribution for jupytergraffiti 1.0.1.20
File Size Uploaded
jupytergraffiti-1.0.1.20.tar.gz 167.5 kB Details

Built distribution (wheel)

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

Total release size: 334.4 kB

Release files / jupytergraffiti-1.0.1.20.tar.gz

Download URL jupytergraffiti-1.0.1.20.tar.gz
Size 167.5 kB
Tags Source
SHA-256 checksum
How to use checksums
52dcc24f0e1bfb0937f73e7ab240c72d9cd1d20608b2d696622f49dd1198ea2d
BLAKE2b-256 checksum
How to use checksums
5565a38d5b4ab486f2d76791a00c6a9e44cf304dce003229757bc3ceed232651
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.4.1 importlib_metadata/4.11.3 pkginfo/1.8.3 requests/2.28.1 requests-toolbelt/0.9.1 tqdm/4.64.1 CPython/3.8.8

Release files / jupytergraffiti-1.0.1.20-py3-none-any.whl

Download URL jupytergraffiti-1.0.1.20-py3-none-any.whl
Size 167.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
5ebc56221715281132baa211125084faaed4b3676d912fa9f9c26e38fbed6eec
BLAKE2b-256 checksum
How to use checksums
9fead3c23db9b3c7aa0a069b18f4c8bd0c9cfc56039b7ece1aae9ac6267aa961
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.4.1 importlib_metadata/4.11.3 pkginfo/1.8.3 requests/2.28.1 requests-toolbelt/0.9.1 tqdm/4.64.1 CPython/3.8.8
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