You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
release_value="0.1"# Default value in case there's no tag
@@ -57,6 +58,7 @@
57
58
myst_enable_extensions= [
58
59
"colon_fence",
59
60
"deflist",
61
+
"attrs_block",
60
62
]
61
63
myst_heading_anchors=3
62
64
@@ -69,7 +71,7 @@
69
71
# Link to our repo for easy PR/ editing
70
72
html_theme_options= {
71
73
"announcement": "<p><a href='https://www.pyopensci.org/about-peer-review/index.html'>We run peer review of scientific Python software. Learn more.</a></p>",
72
-
#"navbar_center": ["nav"], this can be a way to override the default navigation structure
74
+
#"navbar_center": ["nav"], this can be a way to override the default navigation structure
73
75
"external_links": [
74
76
{
75
77
"url": "https://www.pyopensci.org",
@@ -92,7 +94,7 @@
92
94
},
93
95
],
94
96
"logo": {
95
-
#"text": "Python Packaging",
97
+
#"text": "Python Packaging",
96
98
"image_dark": "logo-dark-mode.png",
97
99
"image_light": "logo-light-mode.png",
98
100
"alt_text": "pyOpenSci Python Package Guide. The pyOpenSci logo is a purple flower with pyOpenSci under it. The o in open sci is the center of the flower",
Copy file name to clipboardExpand all lines: documentation/repository-files/license-files.md
+4-4Lines changed: 4 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -47,7 +47,7 @@ To select your license, we suggest that you use GitHub's
47
47
[Choose a License tool ](https://choosealicense.com/).
48
48
49
49
If you choose your license when creating a new GitHub repository, you can also
50
-
automatically get a text copy of the license file to add to your repo. However
50
+
automatically get a text copy of the license file to add to your repository. However
51
51
in some cases the license that you want is not available through that online
52
52
process.
53
53
@@ -78,9 +78,9 @@ with the license that you selected for your package.
78
78
:::{admonition} An example of how a license determine how code can be reused
79
79
:class: note
80
80
81
-
Let's use stackOverflow as an example that highlights how a license determines how code can or can not be used.
81
+
Let's use StackOverflow as an example that highlights how a license determines how code can or can not be used.
82
82
83
-
[Stack overflow uses a Creative Commons Share Alike license.](https://stackoverflow.com/help/licensing). The sharealike license requires you to use the same sharealike license when you reuse any code from stackoverflow.
83
+
[Stack overflow uses a Creative Commons Share Alike license.](https://stackoverflow.com/help/licensing). The sharealike license requires you to use the same sharealike license when you reuse any code from StackOverflow.
84
84
85
85
This means that technically, if you copy code from the Stack Overflow website, and use it in your package. And your packages uses a different license such as a MIT license, you are violating Stack Overflow's license requirements!
86
86
@@ -92,7 +92,7 @@ This means that technically, if you copy code from the Stack Overflow website, a
92
92
93
93
While many permissive licenses do not require citation we STRONG encourage that you cite all software that you use in papers, blogs and other publications. You tell your users how to cite your package by using a [citation.cff file](https://docs.github.com/en/repositories/managing-your-repositorys-settings-and-features/customizing-your-repository/about-citation-files). We will cover this topic when we talk about creating DOI's for your package using zenodo.
94
94
95
-
<!-- TODO: add link when lesson is created - but also we don't yet know how citation.cff files work with zenodo (do they work??) will the citation info update with a new zenodo link
95
+
<!-- TODO: add link when lesson is created - but also we don't yet know how citation.cff files work with Zenodo (do they work??) will the citation info update with a new Zenodo link
96
96
97
97
These files - we need to understand if that date releases auto populates or forces zenodo to modify it's citation. if it's not dynamic it could be problematic
Copy file name to clipboardExpand all lines: package-structure-code/publish-python-package-pypi-conda.md
+9-11Lines changed: 9 additions & 11 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -19,7 +19,7 @@ Below you will learn more specifics about the differences between PyPI and conda
19
19
:::
20
20
21
21
22
-
:::{figure-md} pypi-conda-channels
22
+
:::{figure-md} upload-conda-forge
23
23
24
24
<imgsrc="../images/publish-python-package-pypi-conda.png"alt="Image showing the progression of creating a Python package, building it and then publishing to PyPI and conda-forge. You take your code and turn it into distribution files (sdist and wheel) that PyPI accepts. then there is an arrow towards the PyPI repository where ou publish both distributions. From PyPI if you create a conda-forge recipe you can then publish to conda-forge. "width="700px">
25
25
@@ -48,13 +48,13 @@ Click here for a tutorial on publishing your package to PyPI.
48
48
:::
49
49
50
50
51
-
```{tip}
51
+
:::{tip}
52
52
On the package build page, we discussed the [two package distribution
53
53
types that you will create when making a Python package](python-package-distribution-files-sdist-wheel): SDist (packaged as a .tar.gz or .zip) and
54
54
Wheel (.whl) which is really a zip file. Both of those file "bundles" will
55
55
be published on PyPI when you use [a standard build tool](python-package-build-tools) to build
56
56
your package.
57
-
```
57
+
:::
58
58
59
59
(about-conda)=
60
60
## What is Anaconda Cloud and conda?
@@ -69,8 +69,6 @@ packages. These repositories are known as channels (discussed below).
69
69
:::{admonition} A brief history of conda's evolution
70
70
:class: note
71
71
72
-
The conda ecosystem evolved years ago to provide support for and
73
-
simplify the process of managing software dependencies in scientific
74
72
The conda ecosystem evolved years ago to provide support for, and
75
73
simplify the process of, managing software dependencies in scientific
76
74
Python projects.
@@ -156,11 +154,11 @@ to use conda to manage their local environments (which many do), you should
156
154
consider publishing to both PyPI and the conda-forge channel (_more
157
155
on that below_).
158
156
159
-
```{admonition} Additional resources
160
-
* [learn more about why conda-forge was created, here](https://conda-forge.org/docs/user/introduction.html#why-conda-forge)
157
+
:::{admonition} Additional resources
158
+
*[learn more about why conda-forge was created, here](https://conda-forge.org/docs/user/introduction.html)
161
159
162
160
*[To learn more about conda terminology, check out their glossary.](https://docs.conda.io/projects/conda/en/latest/glossary.html)
163
-
```
161
+
:::
164
162
165
163
<!-- One of our packages on conda-forge https://anaconda.org/conda-forge/pandera -->
166
164
@@ -171,7 +169,7 @@ we encourage you to consider doing so!
171
169
172
170
Once your package is on PyPI, the process to add your package to conda-forge
173
171
is straight forward to do. [You can follow the detailed steps provided
174
-
by the conda-forge maintainer team.](https://conda-forge.org/docs/maintainer/adding_pkgs.html#generating-the-recipe).
172
+
by the conda-forge maintainer team.](https://conda-forge.org/docs/maintainer/adding_pkgs.html).
Copy file name to clipboardExpand all lines: package-structure-code/python-package-distribution-files-sdist-wheel.md
+1-2Lines changed: 1 addition & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,15 +1,14 @@
1
1
# Learn about Building a Python Package
2
2
3
3
4
-
:::{figure-md} pypi-conda-channels
4
+
:::{figure-md} pypi-conda-overview
5
5
6
6
<imgsrc="../images/publish-python-package-pypi-conda.png"alt="Image showing the progression of creating a Python package, building it and then publishing to PyPI and conda-forge. You take your code and turn it into distribution files (sdist and wheel) that PyPI accepts. then there is an arrow towards the PyPI repository where ou publish both distributions. From PyPI if you create a conda-forge recipe you can then publish to conda-forge. "width="700px">
7
7
8
8
Once you have published both package distributions (the source distribution and the wheel) to PyPI, you can then publish to conda-forge. conda-forge requires an source distribution on PyPI in order to build your package on conda-forge. You do not need to rebuild your package to publish to conda-forge.
9
9
:::
10
10
11
11
You need to build your Python package in order to publish it to PyPI (or a conda channel). The build process organizes your code and metadata into a distribution format that can be uploaded to PyPI and subsequently downloaded and installed by users. NOTE: you need to publish a sdist to PyPI in order for conda-forge to properly build your package automatically.
0 commit comments