Skip to content

Remove 'add another token' form from token creation page #11260

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

Merged
merged 2 commits into from
Apr 26, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 14 additions & 14 deletions warehouse/locale/messages.pot
Original file line number Diff line number Diff line change
Expand Up @@ -946,8 +946,8 @@ msgstr ""
#: warehouse/templates/manage/publishing.html:109
#: warehouse/templates/manage/roles.html:170
#: warehouse/templates/manage/roles.html:182
#: warehouse/templates/manage/token.html:136
#: warehouse/templates/manage/token.html:153
#: warehouse/templates/manage/token.html:133
#: warehouse/templates/manage/token.html:150
#: warehouse/templates/re-auth.html:51
msgid "(required)"
msgstr ""
Expand Down Expand Up @@ -2043,7 +2043,7 @@ msgstr ""

#: warehouse/templates/manage/account.html:143
#: warehouse/templates/manage/account.html:435
#: warehouse/templates/manage/token.html:151
#: warehouse/templates/manage/token.html:148
msgid "Scope"
msgstr ""

Expand Down Expand Up @@ -2537,7 +2537,7 @@ msgid ""
msgstr ""

#: warehouse/templates/manage/account.html:714
#: warehouse/templates/manage/token.html:169
#: warehouse/templates/manage/token.html:166
msgid "Proceed with caution!"
msgstr ""

Expand Down Expand Up @@ -3779,7 +3779,7 @@ msgid "Permissions:"
msgstr ""

#: warehouse/templates/manage/token.html:40
#: warehouse/templates/manage/token.html:147
#: warehouse/templates/manage/token.html:144
msgid "Upload packages"
msgstr ""

Expand All @@ -3789,7 +3789,7 @@ msgid "Scope:"
msgstr ""

#: warehouse/templates/manage/token.html:42
#: warehouse/templates/manage/token.html:158
#: warehouse/templates/manage/token.html:155
msgid "Entire account (all projects)"
msgstr ""

Expand Down Expand Up @@ -3872,37 +3872,37 @@ msgid ""
"href=\"%(href)s\">visit the PyPI help page</a>."
msgstr ""

#: warehouse/templates/manage/token.html:127
#: warehouse/templates/manage/token.html:122
msgid "Add another token"
msgstr ""

#: warehouse/templates/manage/token.html:134
#: warehouse/templates/manage/token.html:131
msgid "Token name"
msgstr ""

#: warehouse/templates/manage/token.html:143
#: warehouse/templates/manage/token.html:140
msgid "What is this token for?"
msgstr ""

#: warehouse/templates/manage/token.html:146
#: warehouse/templates/manage/token.html:143
msgid "Permissions"
msgstr ""

#: warehouse/templates/manage/token.html:157
#: warehouse/templates/manage/token.html:154
msgid "Select scope..."
msgstr ""

#: warehouse/templates/manage/token.html:161
#: warehouse/templates/manage/token.html:158
msgid "Project:"
msgstr ""

#: warehouse/templates/manage/token.html:170
#: warehouse/templates/manage/token.html:167
msgid ""
"An API token scoped to your entire account will have upload permissions "
"for all of your current and future projects."
msgstr ""

#: warehouse/templates/manage/token.html:173
#: warehouse/templates/manage/token.html:170
msgid "Add token"
msgstr ""

Expand Down
8 changes: 3 additions & 5 deletions warehouse/templates/manage/token.html
Original file line number Diff line number Diff line change
Expand Up @@ -119,13 +119,10 @@ <h2>{% trans %}Using this token{% endtrans %}</h2>
<p>{% trans href='/help#apitoken' %}For further instructions on how to use this token, <a href="{{ href }}">visit the PyPI help page</a>.{% endtrans %}</p>
</section>
<hr>
{% endif %}

<a href="." class="button">{% trans %}Add another token{% endtrans %}</a>
{% else %}
{{ form_error_anchor(create_macaroon_form) }}
<section id="add-token">
{% if serialized_macaroon %}
<h2>{% trans %}Add another token{% endtrans %}</h2>
{% endif %}
<form method="POST">
<input type="hidden" name="csrf_token" value="{{ request.session.get_csrf_token() }}">
{{ form_errors(create_macaroon_form) }}
Expand Down Expand Up @@ -174,4 +171,5 @@ <h3 class="callout-block__heading">{% trans %}Proceed with caution!{% endtrans %
</div>
</form>
</section>
{% endif %}
{% endblock %}