Skip to content
This repository has been archived by the owner on Jun 12, 2023. It is now read-only.

Latest commit

 

History

History
278 lines (184 loc) · 6.06 KB

windows.md

File metadata and controls

278 lines (184 loc) · 6.06 KB

README for MS Windows Users

Preparing for Your First Release

Install Docker

Ensure the following repositories are forked to your GitHub account

Open an Anaconda Prompt

Build a Docker image with the conda base environment configured and repositories initialized.

change GH_USERNAME to your Github username

docker build -t pandas-release --build-arg GH_USERNAME=simonjayhawkins -f docker-files/windows/Dockerfile .

Preparing the Release Environment for a New Release

Next we will prepare a Docker container for interactive use during the release process and copy the repositories from the Docker image into a Docker volume for building the distribution and testing.

To start with a clean volume. (after a previous release)

docker volume rm pandas-release

change TAG to the release version

docker run -it --env TAG=v1.0.5 --name=pandas-release -v pandas-release:/pandas-release pandas-release /bin/bash

The Docker release container should be now be running.

Make sure the repos are up-to-date

make update-repos

Tag the release. (This doesn't push the tag)

make tag

Stop the container.

exit

Preparing the Build and Test Environment

Create the Docker image for the sdist build, pip test and conda test containers

docker build -t pandas-build .

Build the sdist

docker run -it --rm -v pandas-release:/pandas-release pandas-build /bin/bash

ln -s pandas-release/pandas pandas

cd pandas-release/

./scripts/build_sdist.sh

exit

Pip Tests

change filename to the release version

docker run -it --rm -v pandas-release:/pandas-release pandas-build /bin/bash

ln -s pandas-release/pandas pandas

cd pandas-release/

./scripts/pip_test.sh /pandas/dist/pandas-1.0.5.tar.gz

exit

Conda Tests

change PANDAS_VERSION to the release version

docker run -it --rm --env PANDAS_VERSION=1.0.5 -v pandas-release:/pandas-release pandas-build /bin/bash

ln -s pandas-release/pandas pandas

cd pandas-release/

conda build --numpy=1.17.3 --python=3.8 ./recipe --output-folder=/pandas/dist

exit

Copy the sdist File from the Docker Volume to the Local Host.

change filename to the release version

docker run -t --rm -v %cd%:/local -v pandas-release:/pandas-release pandas-release /bin/bash -c "cp /pandas-release/pandas/dist/pandas-1.0.5.tar.gz /local/"

Push the Tag.

No going back now.

Restart the release container.

docker start pandas-release -i

make push-tag

exit

Create New Branch

(not needed for Patch release)

On pandas you should also now create and tag a new branch, so

...

Create a Release

Now manually create a release https://github.com/pandas-dev/pandas/releases

Make sure to upload the sdist as the "binary". Conda-forge uses it.

Start the Binary Builds.

Restart the release container.

docker start pandas-release -i

make conda-forge

make wheels

exit

Open PRs for each of those.

Note that make wheels actually pushes a job to MacPython to produce wheels which we will download later.

Build the Docs.

You can cheat and re-tag / rebuild these if needed.

docker run -it --name=pandas-docs -v pandas-release:/pandas-release pandas-docs /bin/bash

rm -r pandas

ln -s pandas-release/pandas pandas

cd pandas-release/

# following maybe necessary to prevent segfaults
conda update -n base -c defaults conda

conda env create --file=/pandas/environment.yml --name=pandas

./scripts/build-docs.sh

exit

Copy the built doc files to host and manually inspect html and pdf docs.

first remove the local pandas-docs directory (just manually use file manager for now)

docker run -t --rm -v %cd%:/local -v pandas-release:/pandas-release pandas-release /bin/bash -c "cp -r /pandas-release/pandas/doc/build/ /local/pandas-docs"

Upload the Docs

Copy ssh key and config into release container and restart container.

docker cp %userprofile%/.ssh pandas-release:/root/.ssh

docker start pandas-release -i

chmod 400 ~/.ssh/id_rsa

make upload-doc

exit

Upload the Binarys to PyPI

Once the binaries finish, you'll need to manually upload the wheels to PyPI.

Assuming the job which make wheels triggered on MacPython completed successfully (you may want to double check this https://anaconda.org/multibuild-wheels-staging/pandas/files) you can download a copy of the wheels locally.

docker start pandas-release -i

make download-wheels

make upload-pypi

exit

Finalize the Docs

Do this once the wheels are available on PyPI.

docker start pandas-release -i

make link-stable

make link-version

exit

Announce

  • [ ] Announce Mailing List
  • [ ] Announce Twitter