Skip to content

Document the package size limit #6192

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
brunobord opened this issue Jul 15, 2019 · 1 comment · Fixed by #16200
Closed

Document the package size limit #6192

brunobord opened this issue Jul 15, 2019 · 1 comment · Fixed by #16200
Labels
documentation good first issue This issue is ideal for first-time contributors! UX/UI design, user experience, user interface

Comments

@brunobord
Copy link

What's the problem this feature will solve?

The PyPI help page describes what to do in case you hit the package upload size limit. But there's apparently no public document or page that says: "File upload limit is X".
There are issues talking about 60MB, which is probably a good guess, because it's the MAX_FILESIZE set by default in the code. But the file in which it is set is called legacy.py so there's still doubt.
Also, an issue that says that the file upload limit is X in 2017 doesn't mean that the file size limit hasn't been changed since.

Describe the solution you'd like

I think that under the "How do I get a file size limit exemption or increase for my project?", there could be a mention of what's the current file size limit, in order to make it clear for project maintainers.

Additional context

@nlhkabu nlhkabu added documentation UX/UI design, user experience, user interface labels Jul 16, 2019
@miketheman miketheman added the good first issue This issue is ideal for first-time contributors! label Jan 5, 2023
@miketheman
Copy link
Member

FAQ source:

<h3 id="file-size-limit">{{ file_size_limit() }}</h3>
<p>
{% trans dev_release_href='https://www.python.org/dev/peps/pep-0440/#developmental-releases', file_issue_href='https://github.com/pypi/support/issues/new?assignees=&labels=limit+request&template=limit-request-file.yml&title=File+Limit+Request%3A+PROJECT_NAME+-+000+MB', title=gettext('External link') %}
If you can't upload your project's release to PyPI because you're hitting the upload file size limit,
we can sometimes increase your limit. Make sure you've uploaded at least one release
for the project that's <em>under</em> the limit
(a <a href="{{ dev_release_href }}" title="{{ title }}" target="_blank" rel="noopener">developmental release version number</a> is fine).
Then, <a href="{{ file_issue_href }}" title="{{ title }}" target="_blank" rel="noopener">file an issue</a> and tell us:
{% endtrans %}
</p>
<ul>
<li>{% trans %}A link to your project on PyPI (or Test PyPI){% endtrans %}</li>
<li>{% trans %}The size of your release, in megabytes{% endtrans %}</li>
<li>{% trans %}Which index/indexes you need the increase for (PyPI, Test PyPI, or both){% endtrans %}</li>
<li>{% trans %}A brief description of your project, including the reason for the additional size.{% endtrans %}</li>
</ul>
{{ code_of_conduct() }}
<h3 id="project-size-limit">{{ project_size_limit() }}</h3>
<p>
{% trans %}
If you can't upload your project's release to PyPI because you're
hitting the project size limit, first remove any unnecessary
releases or individual files to lower your overall project size.
{% endtrans %}
</p>
<p>
{% trans file_issue_href='https://github.com/pypi/support/issues/new?assignees=&labels=limit+request&template=limit-request-project.yml&title=Project+Limit+Request%3A+PROJECT_NAME+-+00+GB', title=gettext('External link') %}
If that is not possible, we can sometimes increase your limit. <a href="{{ file_issue_href }}" title="{{ title }}" target="_blank" rel="noopener">File an issue</a> and tell us:
{% endtrans %}
</p>
<ul>
<li>{% trans %}A link to your project on PyPI (or Test PyPI){% endtrans %}</li>
<li>{% trans %}The total size of your project, in gigabytes{% endtrans %}</li>
<li>{% trans %}A brief description of your project, including the reason for the additional size.{% endtrans %}</li>
</ul>
{{ code_of_conduct() }}

The variables controlling the limits can be found here:

MAX_FILESIZE = 100 * ONE_MB
MAX_SIGSIZE = 8 * 1024
MAX_PROJECT_SIZE = 10 * ONE_GB

I'd prefer using the variables to control the output so as to prevent drift between the values and the docs. The "hard part" is translating the bytes values into more human-friendly MB/GB strings.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation good first issue This issue is ideal for first-time contributors! UX/UI design, user experience, user interface
Projects
None yet
3 participants