|
1 | 1 | This is an overview of how to release bionemo sub-packages. |
2 | 2 |
|
3 | | - |
4 | | -1. The code should be in a sub-directory of `bionemo-framework/sub-packages`. The package should be named bionemo-<package_name>. For an example of the directory structure, see https://github.com/NVIDIA/bionemo-framework/tree/main/sub-packages/bionemo-scdl. |
5 | | -The directory should contain: |
6 | | - - a `pyproject.toml` file with the dependencies |
7 | | - - a `README.md` |
8 | | - - a `LICENSE` file |
9 | | - - a `VERSION` file |
10 | | - - the source code should be in src/bionemo/package-name. |
11 | | - - the test should be in tests/bionemo/package-name. The test directory structure should be the same as the source code directory structure. |
12 | | -2. Create some tests that can be run in a notebook within the package or as a small python script that verifies that the package is correctly installed. These can be re-purposed for QA test plan. |
13 | | -3. In the VERSION file in the root of the sub-package, set the package version. Currently, the sub-package versions are independent of the overall BioNeMo version. An ideal approach is to specify the bionemo sub-package versions. That the package depends on. This may create issues. For example, an issue could arise if the latest version of your sub-package depends on the newest bionemo-core, but the latest pushed version of bionemo-core does not have these changes. It may be necessary to update bionemo-core then, but before updating another package, it should be tested and its authors should be consulted. |
14 | | -4. Make sure that the directory dist doesn’t exist or is empty. |
15 | | -5. Run `python -m build .` |
16 | | -6. Create a test-pypi and pypi account if you don’t have one at: https://test.pypi.org/ and https://pypi.org/ |
17 | | -7. Upload to test-pypi with: |
18 | | - `twine upload --repository-url https://test.pypi.org/legacy/ dist/* --non-interactive -u $TWINE_USERNAME -p $TWINE_PASSWORD` |
19 | | -8. In a clean python environment, download the package from test-pypi: |
20 | | -`pip install --index-url https://test.pypi.org/simple/ --no-deps package-name` |
21 | | -9. Run the code/notebooks from step 3. |
| 3 | +01. The code should be in a sub-directory of `bionemo-framework/sub-packages`. The package should be named bionemo-\<package_name>. For an example of the directory structure, see https://github.com/NVIDIA/bionemo-framework/tree/main/sub-packages/bionemo-scdl. |
| 4 | + The directory should contain: |
| 5 | + - a `pyproject.toml` file with the dependencies |
| 6 | + - a `README.md` |
| 7 | + - a `LICENSE` file |
| 8 | + - a `VERSION` file |
| 9 | + - the source code should be in src/bionemo/package-name. |
| 10 | + - the test should be in tests/bionemo/package-name. The test directory structure should be the same as the source code directory structure. |
| 11 | +02. Create some tests that can be run in a notebook within the package or as a small python script that verifies that the package is correctly installed. These can be re-purposed for QA test plan. |
| 12 | +03. In the VERSION file in the root of the sub-package, set the package version. Currently, the sub-package versions are independent of the overall BioNeMo version. An ideal approach is to specify the bionemo sub-package versions. That the package depends on. This may create issues. For example, an issue could arise if the latest version of your sub-package depends on the newest bionemo-core, but the latest pushed version of bionemo-core does not have these changes. It may be necessary to update bionemo-core then, but before updating another package, it should be tested and its authors should be consulted. |
| 13 | +04. Make sure that the directory dist doesn’t exist or is empty. |
| 14 | +05. Run `python -m build .` |
| 15 | +06. Create a test-pypi and pypi account if you don’t have one at: https://test.pypi.org/ and https://pypi.org/ |
| 16 | +07. Upload to test-pypi with: |
| 17 | + `twine upload --repository-url https://test.pypi.org/legacy/ dist/* --non-interactive -u $TWINE_USERNAME -p $TWINE_PASSWORD` |
| 18 | +08. In a clean python environment, download the package from test-pypi: |
| 19 | + `pip install --index-url https://test.pypi.org/simple/ --no-deps package-name` |
| 20 | +09. Run the code/notebooks from step 3. |
22 | 21 | 10. If everything looks good, upload it to the actual pypi repository: `twine upload dist/* --non-interactive -u $TWINE_USERNAME -p $TWINE_PASSWORD --verbose` |
23 | 22 | 11. Run steps 7 and 8 with pypi instead of test-pypi. |
0 commit comments