Bug 1212124 - Review Request: golang-github-ryanuber-columnize- Easy column formatted output for golang
Summary: Review Request: golang-github-ryanuber-columnize- Easy column formatted outpu...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: Package Review
Version: rawhide
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Lokesh Mandvekar
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks: 1208616 1212318
TreeView+ depends on / blocked
 
Reported: 2015-04-15 15:19 UTC by Jan Chaloupka
Modified: 2015-07-08 17:11 UTC (History)
4 users (show)

Fixed In Version: golang-github-ryanuber-columnize-0-0.1.git44cb478.el6
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2015-06-30 00:03:37 UTC
Type: ---
Embargoed:
lsm5: fedora-review+
gwync: fedora-cvs+


Attachments (Terms of Use)

Description Jan Chaloupka 2015-04-15 15:19:59 UTC
Spec URL: https://jchaloup.fedorapeople.org/reviews/golang-github-ryanuber-columnize/golang-github-ryanuber-columnize.spec

SRPM URL: https://jchaloup.fedorapeople.org/reviews/golang-github-ryanuber-columnize/golang-github-ryanuber-columnize-0-0.1.git44cb478.fc20.src.rpm

Description: Easy column formatted output for golang

Fedora Account System Username: jchaloup

Koji: http://koji.fedoraproject.org/koji/taskinfo?taskID=9488906

$ rpmlint /home/jchaloup/rpmbuild/SRPMS/golang-github-ryanuber-columnize-0-0.1.git44cb478.fc20.src.rpm /home/jchaloup/rpmbuild/RPMS/noarch/golang-github-ryanuber-columnize-devel-0-0.1.git44cb478.fc20.noarch.rpm
golang-github-ryanuber-columnize.src:14: W: mixed-use-of-spaces-and-tabs (spaces: line 1, tab: line 14)

Comment 1 Alexander Ploumistos 2015-04-16 01:16:03 UTC
Hello,

This is an unofficial review. For such a small source package, I did not expect such an elaborate spec file, I was in awe when I opened it. Obviously, you've been doing this for quite some time. The spec file itself is up to speed with the latest versions of rpm - no deprecated or unnecessary commands or macros.

I don't speak Go and from what I read on wikipedia about the language's structure and from https://fedoraproject.org/wiki/Packaging:Debuginfo I am not sure why a debuginfo package is not needed (perhaps it falls under the "Useless or incomplete debuginfo packages due to other reasons" clause?).

On the other hand -and perhaps I should be asking this on the devel ML- I don't understand the need for a separate devel package. This is clearly a utility to be used in other packages/programs (not sure about the Go terminology) and what goes in the main package goes into the devel package (should the test be there?) as well. Can there be -devel only packages? I'd really appreciate it if you could explain this to me.

According to https://fedoraproject.org/wiki/PackagingDrafts/Go there is a %{go_arches} macro, perhaps you could use it instead of %{ix86} x86_64 %{arm} in your ExclusiveArch, but then again it applies to older versions of fedora and I don't remember what was supported at the time.

The warning you get from rpmlint is because you actually have
"Summary:       \tEasy column formatted output for golang "
I opened the file in Writer to look for the tab stop, if you delete the last whitespace character before the "E" and hit the space bar, you'll get rid of the warning.

I'm still struggling with git, but I think that the closest upstream release version to commit 44cb478 is v2.0.1, not 0.1. Did I get this right?

I have verified all the items that were checked by fedora-review, I'll just comment below on the items that needed manual review:

===== MUST items =====

Generic:
[ ]: Package is licensed with an open-source compatible license and meets
     other legal requirements as defined in the legal section of Packaging
     Guidelines.

     Yes, MIT license.

[ ]: License field in the package spec file matches the actual license.

     It does.

[ ]: Package contains no bundled libraries without FPC exception.

     No bundled libraries present.

[ ]: Changelog in prescribed format.

     Just one entry, properly formatted.

[ ]: Sources contain only permissible code or content.

     They do.

[ ]: Package contains desktop file if it is a GUI application.

     It doesn't, as it is not a GUI application.

[ ]: Development files must be in a -devel package

     They are, but I am confused as to why and if the test should be there...

[ ]: Package uses nothing in %doc for runtime.

     No such thing.

[ ]: Package consistently uses macros (instead of hard-coded directory names).

     All paths appear consistent to what the Go packaging draft specifies. 

[ ]: Package is named according to the Package Naming Guidelines.

     Consistent with the guidelines about snapshot packages (but perhaps it should be 2.0.1?).

[ ]: Package does not generate any conflict.

     No conflicts encountered in the mock build.

[ ]: Package obeys FHS, except libexecdir and /usr/target.

     It does.

[ ]: If the package is a rename of another package, proper Obsoletes and
     Provides are present.

     Does not apply.

[ ]: Requires correct, justified where necessary.

     Not sure about the version requirement, unless I misunderstood something, upstream built the package successfully with a lower Go version.

[ ]: Spec file is legible and written in American English.

     Spec file is beautiful and in English. Didn't notice any biscuits, barristers or lorries :)

[ ]: Package contains systemd file(s) if in need.

     Not needed.

[ ]: Package is not known to require an ExcludeArch tag.

     ExclusiveArch is in place for fedora < 19 and rhel < 7.

[ ]: Large documentation must go in a -doc subpackage. Large could be size
     (~1MB) or number of files.
     Note: Documentation size is 10240 bytes in 2 files.

     Doesn't seem to justify a separate package.

[ ]: Package complies to the Packaging Guidelines

     It does.


===== SHOULD items =====

Generic:
[ ]: If the source package does not include license text(s) as a separate file
     from upstream, the packager SHOULD query upstream to include it.

     Upstream provides such a file.

[ ]: Final provides and requires are sane (see attachments).

     They are and they appear structured as required by the Go packaging draft.

[ ]: Package functions as described.

     I'm no expert, but from a cursory glance at the source code, it should.

[ ]: Latest version is packaged.

     It is.

[ ]: Package does not include license text files separate from upstream.

     It does not.

[ ]: Description and summary sections in the package spec file contains
     translations for supported Non-English languages, if available.

     Not applicable.

[ ]: Package should compile and build into binary rpms on all supported
     architectures.

     Package is noarch.

[ ]: %check is present and all tests pass.

     Both true.

[ ]: Packages should try to preserve timestamps of original installed files.

     Package invokes install and cp with the -p flag.

Comment 2 Jan Chaloupka 2015-04-16 13:48:55 UTC
> This is an unofficial review.

Thanks Alexander. Any review is welcomed.

> For such a small source package, I did not expect such an elaborate spec
> file, I was in awe when I opened it. Obviously, you've been doing this
> for quite some time. The spec file itself is up to speed with the latest
> versions of rpm - no deprecated or unnecessary commands or macros.

Such a small package consisting of one go package and one test file is rare. Usually it has more packages. Thanks, we have been trying to use as few commands as possible.

> I don't speak Go and from what I read on wikipedia about the language's
> structure and from https://fedoraproject.org/wiki/Packaging:Debuginfo
> I am not sure why a debuginfo package is not needed (perhaps it falls
> under the "Useless or incomplete debuginfo packages due to other reasons"
> clause?).

Debuginfo packages are provided only for subpackages providing binaries. As this package provides only source codes there is nothing to debug and thus debuginfo is empty

> On the other hand -and perhaps I should be asking this on the devel ML- 
> don't understand the need for a separate devel package. This is clearly
> a utility to be used in other packages/programs (not sure about the Go
> terminology) and what goes in the main package goes into the devel package

What line? This package has no %files section, only %files devel.

> (should the test be there?) as well.

All tests are in %check section. Sometimes the section is empty as some additional packages are needed for testing. Tests are optional at the moment.

> Can there be -devel only packages?
> I'd really appreciate it if you could explain this to me.

As the main purpose of almost all golang packages is "being buildtime dependency", there is usually only devel subpackage. And as there is a high change a golang project is going to be used in other golang projects, each spec file provides at least one devel subpackage. You can see devel subpackage as static subpackage of C project. However, as there is nothing as shared library in golang we ship all golang source codes. Once a golang project is built (go build) we have binaries as well. Binaries and source codes are separeted. Check etcd or kubernetes packages for example.

> According to https://fedoraproject.org/wiki/PackagingDrafts/Go there is a
> %{go_arches} macro, perhaps you could use it instead of %{ix86} x86_64 %{arm}
> in your ExclusiveArch, but then again it applies to older versions of fedora > and I don't remember what was supported at the time.

There was a problem with %{go_arches} it was not available in epel6. IIRC scratch build was ok but raw build failed on missing %{go_arches}.

> The warning you get from rpmlint is because you actually have
> "Summary:       \tEasy column formatted output for golang "
> I opened the file in Writer to look for the tab stop, if you delete the last > whitespace character before the "E" and hit the space bar, you'll get rid of > the warning.

Thanks, I usually skip those warnings because once I update a spec file to the latest commit, sometimes patch is needed and sometimes i add space sometimes tab. It is fixed now.

> I'm still struggling with git, but I think that the closest upstream release > version to commit 44cb478 is v2.0.1, not 0.1. Did I get this right?

Yes, you are right. Spec files are generated via gofed [1] and it does not check how many releases a project has. This has to be done manually and I am lazy about it as checking it for each project you get mad. This is one of 21 new golang packages to get to Fedora. I can try to detect it via git tags but I does not have to be 1:1 mapping (the latest tag does not has to be the latest release :(). I fixed this too, thanks.

[1] https://github.com/ingvagabund/gofed

Comment 3 Jan Chaloupka 2015-04-16 13:49:54 UTC
Spec URL: https://jchaloup.fedorapeople.org/reviews/golang-github-ryanuber-columnize/golang-github-ryanuber-columnize.spec

SRPM URL: https://jchaloup.fedorapeople.org/reviews/golang-github-ryanuber-columnize/golang-github-ryanuber-columnize-2.0.1-1.git44cb478.fc20.src.rpm

Koji: http://koji.fedoraproject.org/koji/taskinfo?taskID=9493227

$ rpmlint /home/jchaloup/rpmbuild/SRPMS/golang-github-ryanuber-columnize-2.0.1-1.git44cb478.fc20.src.rpm /home/jchaloup/rpmbuild/RPMS/noarch/golang-github-ryanuber-columnize-devel-2.0.1-1.git44cb478.fc20.noarch.rpm
2 packages and 0 specfiles checked; 0 errors, 0 warnings.

Comment 4 Alexander Ploumistos 2015-04-16 14:27:24 UTC
(In reply to Jan Chaloupka from comment #2)
> Debuginfo packages are provided only for subpackages providing binaries. As
> this package provides only source codes there is nothing to debug and thus
> debuginfo is empty

I did a little more digging into Go this morning and I think I understand how this works now.

> What line? This package has no %files section, only %files devel.

Oops... I could have sworn at the time that I was seeing a %files and a %files devel section. Perhaps I should refrain from reviews in the wee hours...

> As the main purpose of almost all golang packages is "being buildtime
> dependency", there is usually only devel subpackage. And as there is a high
> change a golang project is going to be used in other golang projects, each
> spec file provides at least one devel subpackage. You can see devel
> subpackage as static subpackage of C project. However, as there is nothing
> as shared library in golang we ship all golang source codes. Once a golang
> project is built (go build) we have binaries as well. Binaries and source
> codes are separeted. Check etcd or kubernetes packages for example.

So a library for a compiled language that is only used during buildtime warrants just a -devel package. Thanks, I was under the impression that we couldn't have standalone devel packages.

> I can try to detect it via git tags but I does not have to be 1:1 mapping
> (the latest tag does not has to be the latest release :().

I think that the requirement to package the latest upstream version refers to normal releases and not snapshots, I guess that's what you mean too.

Thank you very much for taking the time to respond and for all the information.

I wish you get a formal review pretty soon.

Comment 5 Marek Skalický 2015-06-17 13:06:14 UTC
Specfile conforms to current Go packaging draft [1].

[1] https://fedoraproject.org/wiki/PackagingDrafts/Go


MUST items:
- Not: If (and only if) the source package includes the text of the
     license(s) in its own file, then that file, containing the text of the
     license(s) for the package is included in %license.

Package Review
==============

Legend:
[x] = Pass, [!] = Fail, [-] = Not applicable, [?] = Not evaluated
[ ] = Manual review needed



===== MUST items =====

Generic:
[x]: Package is licensed with an open-source compatible license and meets
     other legal requirements as defined in the legal section of Packaging
     Guidelines.
[x]: License field in the package spec file matches the actual license.
     Note: Checking patched sources after %prep for licenses.
[x]: Package requires other packages for directories it uses.
[x]: Package must own all directories that it creates.
[x]: Package contains no bundled libraries without FPC exception.
[x]: Changelog in prescribed format.
[x]: Sources contain only permissible code or content.
[-]: Package contains desktop file if it is a GUI application.
[x]: Development files must be in a -devel package
[x]: Package uses nothing in %doc for runtime.
[x]: Package consistently uses macros (instead of hard-coded directory
     names).
[x]: Package is named according to the Package Naming Guidelines.
[x]: Package does not generate any conflict.
[x]: Package obeys FHS, except libexecdir and /usr/target.
[-]: If the package is a rename of another package, proper Obsoletes and
     Provides are present.
[x]: Requires correct, justified where necessary.
[x]: Spec file is legible and written in American English.
[-]: Package contains systemd file(s) if in need.
[x]: Package is not known to require an ExcludeArch tag.
[x]: Large documentation must go in a -doc subpackage. Large could be size
     (~1MB) or number of files.
[x]: Package complies to the Packaging Guidelines
[x]: Package successfully compiles and builds into binary rpms on at least
     one supported primary architecture.
[x]: Package installs properly.
[x]: Rpmlint is run on all rpms the build produces.
[!]: If (and only if) the source package includes the text of the
     license(s) in its own file, then that file, containing the text of the
     license(s) for the package is included in %license.
[x]: Package does not own files or directories owned by other packages.
[x]: All build dependencies are listed in BuildRequires, except for any
     that are listed in the exceptions section of Packaging Guidelines.
[x]: Package uses either %{buildroot} or $RPM_BUILD_ROOT
[x]: Package does not run rm -rf %{buildroot} (or $RPM_BUILD_ROOT) at the
     beginning of %install.
[x]: Macros in Summary, %description expandable at SRPM build time.
[x]: Dist tag is present.
[x]: Package does not contain duplicates in %files.
[x]: Permissions on files are set properly.
[x]: Package use %makeinstall only when make install DESTDIR=... doesn't
     work.
[x]: Package is named using only allowed ASCII characters.
[x]: Package does not use a name that already exists.
[x]: Package is not relocatable.
[x]: Sources used to build the package match the upstream source, as
     provided in the spec URL.
[x]: Spec file name must match the spec package %{name}, in the format
     %{name}.spec.
[x]: File names are valid UTF-8.
[x]: Packages must not store files under /srv, /opt or /usr/local

===== SHOULD items =====

Generic:
[x]: If the source package does not include license text(s) as a separate
     file from upstream, the packager SHOULD query upstream to include it.
[x]: Final provides and requires are sane (see attachments).
[x]: Package functions as described.
[x]: Latest version is packaged.
[x]: Package does not include license text files separate from upstream.
[-]: Description and summary sections in the package spec file contains
     translations for supported Non-English languages, if available.
[x]: Package should compile and build into binary rpms on all supported
     architectures.
[x]: %check is present and all tests pass.
[x]: Packages should try to preserve timestamps of original installed
     files.
[x]: Packager, Vendor, PreReq, Copyright tags should not be in spec file
[x]: Sources can be downloaded from URI in Source: tag
[x]: Reviewer should test that the package builds in mock.
[x]: Buildroot is not present
[x]: Package has no %clean section with rm -rf %{buildroot} (or
     $RPM_BUILD_ROOT)
[x]: No file requires outside of /etc, /bin, /sbin, /usr/bin, /usr/sbin.
[x]: SourceX is a working URL.
[x]: Spec use %global instead of %define unless justified.

===== EXTRA items =====

Generic:
[x]: Rpmlint is run on all installed packages.
     Note: No rpmlint messages.
[x]: Spec file according to URL is the same as in SRPM.

Comment 6 Lokesh Mandvekar 2015-06-17 16:11:44 UTC
- specfile conforms to current golang packaging draft
- license correct and valid
- only sources installed for now

package approved

Comment 7 Jan Chaloupka 2015-06-17 16:37:03 UTC
New Package SCM Request
=======================
Package Name: golang-github-ryanuber-columnize
Short Description: Easy column formatted output for golang
Upstream URL: https://github.com/ryanuber/columnize
Owners: jchaloup
Branches: f22 f21 el6
InitialCC: golang-sig

Comment 8 Gwyn Ciesla 2015-06-18 15:08:52 UTC
Git done (by process-git-requests).

Comment 9 Fedora Update System 2015-06-20 08:43:52 UTC
golang-github-ryanuber-columnize-0-0.1.git44cb478.fc22 has been submitted as an update for Fedora 22.
https://admin.fedoraproject.org/updates/golang-github-ryanuber-columnize-0-0.1.git44cb478.fc22

Comment 10 Fedora Update System 2015-06-20 08:44:21 UTC
golang-github-ryanuber-columnize-0-0.1.git44cb478.fc21 has been submitted as an update for Fedora 21.
https://admin.fedoraproject.org/updates/golang-github-ryanuber-columnize-0-0.1.git44cb478.fc21

Comment 11 Fedora Update System 2015-06-20 08:44:47 UTC
golang-github-ryanuber-columnize-0-0.1.git44cb478.el6 has been submitted as an update for Fedora EPEL 6.
https://admin.fedoraproject.org/updates/golang-github-ryanuber-columnize-0-0.1.git44cb478.el6

Comment 12 Fedora Update System 2015-06-20 21:12:30 UTC
golang-github-ryanuber-columnize-0-0.1.git44cb478.el6 has been pushed to the Fedora EPEL 6 testing repository.

Comment 13 Fedora Update System 2015-06-30 00:03:37 UTC
golang-github-ryanuber-columnize-0-0.1.git44cb478.fc21 has been pushed to the Fedora 21 stable repository.

Comment 14 Fedora Update System 2015-06-30 00:10:58 UTC
golang-github-ryanuber-columnize-0-0.1.git44cb478.fc22 has been pushed to the Fedora 22 stable repository.

Comment 15 Fedora Update System 2015-07-08 17:11:33 UTC
golang-github-ryanuber-columnize-0-0.1.git44cb478.el6 has been pushed to the Fedora EPEL 6 stable repository.


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