Bug 1648966 - Review Request: golang-github-pascaldekloe-goe - Common enterprise features for the Go programming language
Summary: Review Request: golang-github-pascaldekloe-goe - Common enterprise features f...
Alias: None
Product: Fedora
Classification: Fedora
Component: Package Review
Version: rawhide
Hardware: All
OS: Linux
Target Milestone: ---
Assignee: Ankur Sinha (FranciscoD)
QA Contact: Fedora Extras Quality Assurance
Depends On:
TreeView+ depends on / blocked
Reported: 2018-11-12 15:34 UTC by Robert-André Mauchin
Modified: 2018-12-12 03:07 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Last Closed: 2018-12-12 03:07:41 UTC
sanjay.ankur: fedora-review+

Attachments (Terms of Use)

Description Robert-André Mauchin 2018-11-12 15:34:24 UTC
Spec URL: https://eclipseo.fedorapeople.org/golang-github-pascaldekloe-goe.spec
SRPM URL: https://eclipseo.fedorapeople.org/golang-github-pascaldekloe-goe-0-0.1.20181112git57f6aae.fc30.src.rpm

Koji scratch build: https://koji.fedoraproject.org/koji/taskinfo?taskID=30832189

Common enterprise features for the Go programming language.

Fedora Account System Username: eclipseo

Comment 1 Ankur Sinha (FranciscoD) 2018-11-12 18:14:32 UTC
Package Review

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

It's mostly good. I found one or two nitpicks:

- Should this and other similar packages require golang which owns
- Shouldn't the release include snapshot information?
- rpmlint says there's a hidden file in the directories---I expect this is
  required, but please double check.

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

[X]: Package is licensed with an open-source compatible license and meets
     other legal requirements as defined in the legal section of Packaging
[X]: License field in the package spec file matches the actual license.
     Note: Checking patched sources after %prep for licenses. Licenses
     found: "Unknown or generated". 17 files have unknown license. Detailed
     output of licensecheck in /home/asinha/1648966-golang-github-
[!]: Package must own all directories that it creates.
     Note: Directories without known owners: /usr/share/gocode/src,

Should this golang module (and others in general) require golang which owns

[!]: Package does not own files or directories owned by other packages.
     Note: Dirs in package are owned also by:

Related to the above issue

[x]: %build honors applicable compiler flags or justifies otherwise.
[x]: Package contains no bundled libraries without FPC exception.
[x]: Changelog in prescribed format.
[x]: Sources contain only permissible code or content.
[x]: 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
[?]: Package is named according to the Package Naming Guidelines.

Upstream has never released a version, so the release field is fine, but since
it is a snapshot, should the release not include some snap information also?

[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.
[!]: Requires correct, justified where necessary.
See above issue.

[x]: Spec file is legible and written in American English.
[x]: Package contains systemd file(s) if in need.
[x]: Package is not known to require an ExcludeArch tag.
[-]: Large documentation must go in a -doc subpackage. Large could be size
     (~1MB) or number of files.
     Note: Documentation size is 10240 bytes in 1 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.
     Note: There are rpmlint messages (see attachment).
[x]: 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 requires other packages for directories it uses.
[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
[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
[x]: File names are valid UTF-8.
[x]: Packages must not store files under /srv, /opt or /usr/local

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

[-]: 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).
[?]: Package functions as described.
Please check this

[x]: Latest version is packaged.
[x]: Package does not include license text files separate from upstream.
[x]: Description and summary sections in the package spec file contains
     translations for supported Non-English languages, if available.
[x]: %check is present and all tests pass.
[x]: Packages should try to preserve timestamps of original installed
[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
[x]: No file requires outside of /etc, /bin, /sbin, /usr/bin, /usr/sbin.
[x]: Packager, Vendor, PreReq, Copyright tags should not be in spec file
[x]: Sources can be downloaded from URI in Source: tag
[x]: SourceX is a working URL.
[x]: Package should compile and build into binary rpms on all supported
[x]: Spec use %global instead of %define unless justified.

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

[x]: Rpmlint is run on all installed packages.
     Note: There are rpmlint messages (see attachment).
[x]: Spec file according to URL is the same as in SRPM.

Checking: golang-github-pascaldekloe-goe-devel-0-0.1.20181112git57f6aae.fc29.noarch.rpm
golang-github-pascaldekloe-goe-devel.noarch: W: hidden-file-or-dir /usr/share/gocode/src/github.com/pascaldekloe/goe/.goipath
golang-github-pascaldekloe-goe.src: W: no-%build-section
2 packages and 0 specfiles checked; 0 errors, 2 warnings.

Rpmlint (installed packages)
sh: /usr/bin/python: No such file or directory
golang-github-pascaldekloe-goe-devel.noarch: W: invalid-url URL: https://github.com/pascaldekloe/goe <urlopen error [Errno -2] Name or service not known>
golang-github-pascaldekloe-goe-devel.noarch: W: hidden-file-or-dir /usr/share/gocode/src/github.com/pascaldekloe/goe/.goipath
1 packages and 0 specfiles checked; 0 errors, 2 warnings.

golang-github-pascaldekloe-goe-devel (rpmlib, GLIBC filtered):


Source checksums
https://github.com/pascaldekloe/goe/archive/57f6aae5913c64c9bcae5dbdffd33365b5a7f138/goe-57f6aae5913c64c9bcae5dbdffd33365b5a7f138.tar.gz :
  CHECKSUM(SHA256) this package     : 09ca53fc49068ead3e1381fe0f9845f45f3b4aaae6c5957318085af49237e7a8
  CHECKSUM(SHA256) upstream package : 09ca53fc49068ead3e1381fe0f9845f45f3b4aaae6c5957318085af49237e7a8

Generated by fedora-review 0.6.1 (f03e4e7) last change: 2016-05-02
Command line :/usr/bin/fedora-review -b 1648966
Buildroot used: fedora-29-x86_64
Active plugins: Generic, Shell-api
Disabled plugins: Java, C/C++, Python, fonts, SugarActivity, Ocaml, Perl, Haskell, R, PHP

Comment 2 Robert-André Mauchin 2018-11-12 20:03:25 UTC
- Should this and other similar packages require golang which owns

I don't think so.

- Shouldn't the release include snapshot information?

It's computed automatically in dist by the gometa macro

- rpmlint says there's a hidden file in the directories---I expect this is
  required, but please double check.

It's the .goipath file, which is required.

Comment 3 Ankur Sinha (FranciscoD) 2018-11-12 21:24:01 UTC
(In reply to Robert-André Mauchin from comment #2)
> - Should this and other similar packages require golang which owns
>   /usr/share/gocode/src?
> I don't think so.

Based on my understanding of the guidelines, I think they should either require the golang package, or own the directory themselves. This is what the guidelines say:

"Packages must own all directories they put files in, except for:

- any directories owned by the filesystem, man, or other explicitly created -filesystem packages
- any directories owned by other packages in your package's natural dependency chain"

So, here, since this package doesn't require golang explicitly and doesn't pull it in as a natural dependency either (not listed in requires as generated by fedora-review above), `/usr/share/gocode/src` (and /usr/share/gocode) is currently unowned. So when this package is removed, for example, this directory will get left behind. 


I'm not a golang user, but isn't golang required to use this package anyway? If it isn't, it is this case:

If it is, then it's this one: 

Either way, the two directories need to be owned here.

> - Shouldn't the release include snapshot information?
> It's computed automatically in dist by the gometa macro

Ah, right. So many go marcos now, doing so many fancy things!

> - rpmlint says there's a hidden file in the directories---I expect this is
>   required, but please double check.
> It's the .goipath file, which is required.

I thought so.

Comment 4 Robert-André Mauchin 2018-11-13 11:45:15 UTC
In golang we have:

# ensure directory ownership, so they are cleaned up if empty
%dir %{gopath}
%dir %{gopath}/src
%dir %{gopath}/src/github.com/
%dir %{gopath}/src/bitbucket.org/
%dir %{gopath}/src/code.google.com/
%dir %{gopath}/src/code.google.com/p/
%dir %{gopath}/src/golang.org
%dir %{gopath}/src/golang.org/x

so they ane owned and removed when clean. I don't think we want to start have all Golang libraries depends on the compiler, this would be problematic, like if removing GCC would remove all your C devel packages. It's implicit that if you have a Golang devel package, you'll have Golang installed too, but we don't want to make that a hard dependencies.

Comment 5 Ankur Sinha (FranciscoD) 2018-11-13 12:09:57 UTC
Sure, then it's this case, and the package must (co-)own the directories too: 

There should not be a situation where removing this package leaves those directories---and the implicit dependence on the golang package does not guarantee that.

Comment 7 Ankur Sinha (FranciscoD) 2018-11-13 14:20:51 UTC
You may also need a %dir %{gopath} in there for "/usr/share/gocode" which is also the same case. Please add that before importing.


Comment 8 Gwyn Ciesla 2018-11-13 14:58:56 UTC
(fedscm-admin):  The Pagure repository was created at https://src.fedoraproject.org/rpms/golang-github-pascaldekloe-goe

Comment 9 Fedora Update System 2018-11-13 16:21:09 UTC
golang-github-pascaldekloe-goe-0-0.1.20181113git57f6aae.fc29 has been submitted as an update to Fedora 29. https://bodhi.fedoraproject.org/updates/FEDORA-2018-1456387c01

Comment 10 Fedora Update System 2018-11-14 06:02:10 UTC
golang-github-pascaldekloe-goe-0-0.1.20181113git57f6aae.fc29 has been pushed to the Fedora 29 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2018-1456387c01

Comment 11 Fedora Update System 2018-12-12 03:07:41 UTC
golang-github-pascaldekloe-goe-0-0.1.20181113git57f6aae.fc29 has been pushed to the Fedora 29 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.