-
Notifications
You must be signed in to change notification settings - Fork 20
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Expect missing copyright field and ValueError errors
Expecting the errors enables to give better feedback to users than just a 500 error
- Loading branch information
1 parent
b6a5357
commit f99fc6a
Showing
7 changed files
with
58 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
20 changes: 20 additions & 0 deletions
20
debsources/app/copyright/templates/copyright/value_error.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
{# | ||
Copyright (C) 2016 The Debsources developers <info@sources.debian.net>. | ||
See the AUTHORS file at the top-level directory of this distribution and at | ||
https://anonscm.debian.org/gitweb/?p=qa/debsources.git;a=blob;f=AUTHORS;hb=HEAD | ||
License: GNU Affero General Public License, version 3 or above. | ||
#} | ||
{% extends name+"/base.html" %} | ||
|
||
{% block title %}Error{% endblock %} | ||
{% block content %} | ||
<h2>{{ self.title() }}</h2> | ||
<p>Parsing the debian/copyright file yields a Value error. Causes of ValueError can be: | ||
<ul> | ||
<li>continued line must begin with " "</li> | ||
<li>missing value in one of the required attributes (Files, Copyright, License)</li> | ||
</ul> | ||
|
||
<p><a href="{{ url_for('sources.source', path_to=(package +'/'+version+'/debian/copyright'))}}">View raw copyright file</a></p> | ||
</p> | ||
{% endblock %} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters