Bug 485159 - Review Request: anki - Flashcard program for using space repetition learning
Review Request: anki - Flashcard program for using space repetition learning
Status: CLOSED NEXTRELEASE
Product: Fedora
Classification: Fedora
Component: Package Review (Show other bugs)
rawhide
All Linux
low Severity medium
: ---
: ---
Assigned To: Tom "spot" Callaway
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2009-02-11 17:51 EST by Christian Krause
Modified: 2009-04-06 13:05 EDT (History)
3 users (show)

See Also:
Fixed In Version: 0.9.9.6-4.fc9
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2009-03-05 11:30:19 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---
tcallawa: fedora‑review+
kevin: fedora‑cvs+


Attachments (Terms of Use)

  None (edit)
Description Christian Krause 2009-02-11 17:51:20 EST
anki - Flashcard program for using space repetition learning
Spec URL: http://www-user.tu-chemnitz.de/~tiwi/anki.spec
SRPM URL: http://www-user.tu-chemnitz.de/~tiwi/anki-0.9.9.6-1.fc10.src.rpm
Description: Anki is a program designed to help you remember facts (such as words
and phrases in a foreign language) as easily, quickly and efficiently
as possible. Anki is based on a theory called spaced repetition.

This is my first package and so I'm seeking a sponsor.
Comment 1 Christian Krause 2009-02-13 17:13:32 EST
I've updated the packages:
- fixed an installation problem
- corrected the license field with the help of Jason Tibbitts (fedora-legal mailing list)

Spec URL: http://www-user.tu-chemnitz.de/~tiwi/anki.spec
SRPM URL: http://www-user.tu-chemnitz.de/~tiwi/anki-0.9.9.6-2.fc10.src.rpm
Comment 2 Christian Krause 2009-02-18 14:19:08 EST
Anyone wants to pick up this review?
Comment 3 Tom "spot" Callaway 2009-02-27 10:13:48 EST
Christian, at first glance, this package looks great. I only noticed one thing when I did the review:

The package is internationalized, with .mo files for libanki and libankiqt. Unfortunately, they're in a location that %find_lang (https://fedoraproject.org/wiki/Packaging/Guidelines#Handling_Locale_Files) doesn't know how to find them in (%{python_sitelib}/ankiqt/locale/*/LC_MESSAGES). Since you can't use %find_lang, you're going to have to tag those files manually, like this:

%lang(cs) %{python_sitelib}/ankiqt/locale/cs_*/

(rpm tags on the first half of the locale country code only)

Unfortunately, this will make your %files more complicated, as you cannot simply claim the toplevel directory or these files will be listed twice.

Start with something like this:

%files
%defattr(-,root,root,-)
%doc COPYING ChangeLog CREDITS README*
%dir %{python_sitelib}/ankiqt/
%{python_sitelib}/ankiqt/*.py*
%{python_sitelib}/ankiqt/forms/
%{python_sitelib}/ankiqt/ui/
%dir %{python_sitelib}/ankiqt/locale/
%lang(cs) %{python_sitelib}/ankiqt/locale/cs_*/
%lang(de) %{python_sitelib}/ankiqt/locale/de_*/
...

It is also possible to script a version of find_lang that can find these files and tag them properly in a file list to use in %files, but that might be more complicated than doing what I've proposed.

rpmlint caught this problem, you should run rpmlint on your packages to look for issues like this. :)

Show me a new package that has this issue fixed and I'll finish out this review.
Comment 4 Christian Krause 2009-02-27 15:21:38 EST
Thank you very much for the review!

(In reply to comment #3)
> The package is internationalized, with .mo files for libanki and libankiqt.
> Unfortunately, they're in a location that %find_lang
> (https://fedoraproject.org/wiki/Packaging/Guidelines#Handling_Locale_Files)
> doesn't know how to find them in
> (%{python_sitelib}/ankiqt/locale/*/LC_MESSAGES). Since you can't use
> %find_lang, you're going to have to tag those files manually, like this:

I've fixed the problem as suggested.

> It is also possible to script a version of find_lang that can find these files
> and tag them properly in a file list to use in %files, but that might be more
> complicated than doing what I've proposed.

Yeah, this makes the spec file a little bit more complicated. I'll try to get this problem fixed upstream, but for now I think it's ok! ;-)

> rpmlint caught this problem, you should run rpmlint on your packages to look
> for issues like this. :)

rpmlint SPECS/anki.spec RPMS/noarch/anki-0.9.9.6-3.fc10.noarch.rpm SRPMS/anki-0.9.9.6-3.fc10.src.rpm 
anki.src: W: strange-permission generate-anki-tarball.sh 0755
2 packages and 1 specfiles checked; 0 errors, 1 warnings.

The remaining warning is about the mode of the script to generate the distributable tarball. Since the file is an executable shell script it may be ok...

> Show me a new package that has this issue fixed and I'll finish out this
> review.

Great! The new package is uploaded:

Spec URL: http://www-user.tu-chemnitz.de/~tiwi/anki.spec
SRPM URL: http://www-user.tu-chemnitz.de/~tiwi/anki-0.9.9.6-3.fc10.src.rpm

and builds fine in F10 and F11:

https://koji.fedoraproject.org/koji/taskinfo?taskID=1206089
https://koji.fedoraproject.org/koji/taskinfo?taskID=1206084
Comment 5 Tom "spot" Callaway 2009-02-27 15:46:58 EST
== Review ==

Good:

- rpmlint checks return:
anki.src: W: strange-permission generate-anki-tarball.sh 0755
Safe to ignore.

- package meets naming guidelines
- package meets packaging guidelines
- license (GPLv3+ and MIT) OK, text in %doc, matches source
- spec file legible, in am. english
- source matches upstream
- package compiles on devel (x86_64)
- no missing BR
- no unnecessary BR
- locales okay
- not relocatable
- owns all directories that it creates
- no duplicate files
- permissions ok
- %clean ok
- macro use consistent
- code, not content
- no need for -docs
- nothing in %doc affects runtime 
- desktop file okay

APPROVED.
Comment 6 Christian Krause 2009-02-27 17:40:04 EST
New Package CVS Request
=======================
Package Name: anki
Short Description: Flashcard program for using space repetition learning
Owners: chkr
Branches: F-10
InitialCC:
Comment 7 Kevin Fenzi 2009-02-28 19:28:16 EST
cvs done.
Comment 8 Fedora Update System 2009-03-02 14:46:20 EST
anki-0.9.9.6-4.fc10 has been submitted as an update for Fedora 10.
http://admin.fedoraproject.org/updates/anki-0.9.9.6-4.fc10
Comment 9 Fedora Update System 2009-03-04 11:26:20 EST
anki-0.9.9.6-4.fc10 has been pushed to the Fedora 10 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update anki'.  You can provide feedback for this update here: http://admin.fedoraproject.org/updates/F10/FEDORA-2009-2322
Comment 10 Tom "spot" Callaway 2009-03-04 17:31:11 EST
Go ahead and push this into stable and close out this bug. No one is going to test a new package in testing. :)
Comment 11 Christian Krause 2009-03-04 17:36:30 EST
(In reply to comment #10)
> Go ahead and push this into stable and close out this bug. No one is going to
> test a new package in testing. :)

Sure - I've just pushed it to stable 5 minutes ago. ;-)

Thank you again for all the support and help!
Comment 12 Fedora Update System 2009-03-05 11:30:11 EST
anki-0.9.9.6-4.fc10 has been pushed to the Fedora 10 stable repository.  If problems still persist, please make note of it in this bug report.
Comment 13 Fedora Update System 2009-03-08 13:26:59 EDT
anki-0.9.9.6-4.fc9 has been submitted as an update for Fedora 9.
http://admin.fedoraproject.org/updates/anki-0.9.9.6-4.fc9
Comment 14 Fedora Update System 2009-03-09 18:45:01 EDT
anki-0.9.9.6-4.fc9 has been pushed to the Fedora 9 stable repository.  If problems still persist, please make note of it in this bug report.

Note You need to log in before you can comment on or make changes to this bug.