8.2.7. Changing and Extending the Build Environment

If packages are needed that are not included in development environment they can simply be added. This how-to explains it for Windows. If there is a reference to conf\env\conda_env_win32.yaml and you are on Linux replace it by conf/env/conda_env_linux.yaml.

The basic required packages are listed in conf/env/conda_env_win32-pkgs.yaml. If a package should be added or removed, it needs to be done here. This file only defines the major Python version that should be used.

The steps are basically:

  • Add new packages and/or remove no longer needed packages and update the environment name, for this example example-env.

  • Create a new pseudo-base environment that includes all needed Python packages for the project.

  • Export the exact environment definition.

  • Update the test suite.

  • Commit the new environment to the repository.

  • Add a changelog entry that tells the user to run the environment update script.

These steps in details:

  1. Add packages/remove packages and update environment name.

  2. Create a new pseudo-base environment and wait for the solver to succeeded.

    C:\Users\vulpes>%USERPROFILE%\miniconda3\Scripts\activate base
    (base) C:\Users\vulpes>conda env create -f conf\env\conda_env_win32-pkgs.yaml
    
  3. Export the new development environment:

    (base) C:\Users\vulpes>conda env export -n example-env > conf\env\conda_env_win32.yaml
    
  4. Remove the Prefix entry from conf\env\conda_env_win32.yaml.

  5. Adapt the test suite as needed and run it afterwards.

  6. Commit the new environment file to the repository.

  7. Add changelog entry.

8.2.8. Existing Environments

Environment Name

From

To

2023-02-fennec-fox

1.5.1

-

2021-11-fennec-fox

1.2.1

1.5.0

2021-08-arctic-fox

1.1.0

1.2.0

2021-04-red-fox

1.0.0

1.0.2

8.2.8.1. Further Reading

An explanation why build environments are used is found in Build Environment.