Bug 896101 - Review Request: initial-setup - The replacement for firstboot utility
Summary: Review Request: initial-setup - The replacement for firstboot utility
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: Package Review
Version: rawhide
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Michael S.
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-01-16 16:01 UTC by Martin Sivák
Modified: 2013-06-19 10:48 UTC (History)
4 users (show)

Fixed In Version: initial-setup-0.3.4-3.fc19
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-06-19 10:48:18 UTC
Type: ---
Embargoed:
misc: fedora-review+
gwync: fedora-cvs+


Attachments (Terms of Use)

Description Martin Sivák 2013-01-16 16:01:06 UTC
Spec URL: http://msivak.fedorapeople.org/newpkg/inital-setup.spec
SRPM URL: http://msivak.fedorapeople.org/newpkg/inital-setup-0.1-1.fc17.src.rpm
Description: This package contains the new inital setup utility that is used to configure the system after the Anaconda installer reboots.
Fedora Account System Username: msivak

Comment 1 Robin Lee 2013-01-17 03:11:34 UTC
inital? typo?

Comment 2 Martin Sivák 2013-01-17 08:56:28 UTC
Nope, that is intentional. Gnome also uses gnome-inital-experience for their environment specific supplement.

Comment 3 Robin Lee 2013-01-17 12:56:52 UTC
Really? As I have addicted to the typos in KDE, like Konsole, this GNOME style of typo shocked me a bit.

Comment 4 Martin Sivák 2013-01-17 13:19:10 UTC
Well give me a sec and I will rename it to initial-setup.

Comment 6 Michael S. 2013-01-19 10:33:47 UTC
A few comments :
- ExclusiveOS: Linux  is uneeded

- there is no url for the code checkout nor where to download it

- why are the debug package disabled when it shouldn't be needed ?

- why does the s390 port have a specific variable in %post ?

- .pyc should be packaged by the rpm to avoid doing that :

if [ $1 = 0 ]; then
  rm -rf /usr/share/initial-setup/*.pyc
  rm -rf /usr/share/initial-setup/modules/*.pyc
fi


- %defattr(-,root,root,-)
this should be uneeded

- are you sure that systemd-sysv chkconfig are neeed in %post ?

- you should use %_unitdir instead of hardcoding the path to systemd unit

Comment 7 Michael S. 2013-01-19 10:38:59 UTC
And it doesn't build on rawhide :

======================================================================
ERROR: Failure: ImportError (No module named pyanaconda.ui.gui.hubs)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/usr/lib/python2.7/site-packages/nose/loader.py", line 390, in loadTestsFromName
    addr.filename, addr.module)
  File "/usr/lib/python2.7/site-packages/nose/importer.py", line 39, in importFromPath
    return self.importFromDir(dir_path, fqname)
  File "/usr/lib/python2.7/site-packages/nose/importer.py", line 86, in importFromDir
    mod = load_module(part_fqname, fh, filename, desc)
  File "/builddir/build/BUILD/initial-setup-0.1/initial_setup/gui/hubs/__init__.py", line 1, in <module>
    from initial_setup import InitalSetupMainHub
  File "/builddir/build/BUILD/initial-setup-0.1/initial_setup/gui/hubs/initial_setup.py", line 1, in <module>
    from pyanaconda.ui.gui.hubs import Hub
ImportError: No module named pyanaconda.ui.gui.hubs

Comment 8 Martin Sivák 2013-01-22 14:43:10 UTC
So,

- the traceback is fixed, BuildRequires: anaconda was missing, but I had to comment out the %check section until #902401 gets resolved
- git checkout url added, there is not upstream tarball, nor there ever was
- I removed the lines that were not needed
- s390 needs the sysconfig variable because it starts the initial-setup differently, it waits for the first user to connect to the console (there is no hw console)

The updated spec file and source codes are again uploaded here:

Spec URL: http://msivak.fedorapeople.org/newpkg/initial-setup.spec
SRPM URL: http://msivak.fedorapeople.org/newpkg/initial-setup-0.1-2.fc17.src.rpm

It passes fedora-review with the exception of one empty README file (inside plugins directory, we do not have docs for it atm) and warnings about commented out %check section (intentional, once the Gtk bug is fixed, I will uncomment it)

Comment 9 Martin Sivák 2013-02-12 10:09:59 UTC
Michael, any updates?

Comment 10 Michael S. 2013-02-13 07:42:54 UTC
Sorry, totally forgot about this review.

There is a few issues that should be easy to correct, and a few ones
that should be discussed.
 
Package Review
==============

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


Issues:
=======
- %global debug_package %{nil} should not be needed, can you remove or explain 
why it is needed ?

- rm -rf ${buildroot} is not needed in %install

- License should be be shipped in %doc

- Should not have %dir %{_sysconfdir}/profile.d, since this is already owned by 
setup rpm.

- systemd-sysv chkconfig are not used in %post, should not be required IMHO.

- since the package call directly metacity, it should requires it ( since 
mate-windows-manager also provides 'firstboot(windowmanager)', likely something 
it shouldn't ).

- not sure if xorg-x11-xinit should be explicitely added as Requires,
need to check what pull it ( used by initial-setup-xserver.service )

- Requires: libreport-python 
do not seems to be needed in the code

- As a side note, the initial-setup-xserver.service is never disabled, not
sure if that's what you want.

===== 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]: 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 is not known to require ExcludeArch.
[x]: Package complies to the Packaging Guidelines
[!]: 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 %doc.
[x]: License field in the package spec file matches the actual license.
     Note: Checking patched sources after %prep for licenses. Licenses found:
     "GPL (v2 or later)", "Unknown or generated". 2 files have unknown
     license. Detailed output of licensecheck in
     /home/misc/checkout/git/FedoraReview/896101-initial-
     setup/licensecheck.txt
[x]: The spec file handles locales properly.
[x]: Package consistently uses macro is (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.
[!]: Requires correct, justified where necessary.
[x]: Spec file is legible and written in American English.
[x]: Package contains systemd file(s) if in need.
[x]: All build dependencies are listed in BuildRequires, except for any that
     are listed in the exceptions section of Packaging Guidelines.
[x]: Package does not run rm -rf %{buildroot} (or $RPM_BUILD_ROOT) at the
     beginning of %install.
[x]: Each %files section contains %defattr if rpm < 4.4
[x]: Macros in Summary, %description expandable at SRPM build time.
[x]: Package requires other packages for directories it uses.
[x]: Package does not contain duplicates in %files.
[x]: Permissions on files are set properly.
[x]: Fully versioned dependency in subpackages, if present.
[x]: Package use %makeinstall only when make install' ' DESTDIR=... doesn't
     work.
[x]: Package is named using only allowed ASCII characters.
[x]: Package do not use a name that already exist
[x]: Package must own all directories that it creates.
[x]: Package does not own files or directories owned by other packages.
[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]: Large documentation must go in a -doc subpackage.
     Note: Documentation size is 0 bytes in 0 files.
[x]: Packages must not store files under /srv, /opt or /usr/local
[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).

Python:
[x]: Python eggs must not download any dependencies during the build process.
[x]: A package which is used by another package via an egg interface should
     provide egg info.
[x]: Package meets the Packaging Guidelines::Python
[x]: Package contains BR: python2-devel or python3-devel
[x]: Binary eggs must be removed in %prep

===== 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.
[x]: Final provides and requires are sane (see attachments).
[-]: Package functions as described.
[x]: Latest version is packaged.
[x]: Package does not include license text files separate from upstream.
[x]: SourceX tarball generation or download is documented.
     Note: Package contains tarball without URL, check comments
[-]: 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.
[!]: %check is present and all tests pass.
[x]: Packages should try to preserve timestamps of original installed files.
[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]: Dist tag is present.
[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.

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

Generic:
[x]: Large data in /usr/share should live in a noarch subpackage if package is
     arched.
[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.


Rpmlint
-------
Checking: initial-setup-0.1-2.fc19.noarch.rpm
initial-setup.noarch: W: no-documentation
initial-setup.noarch: E: zero-length /usr/share/initial-setup/modules/README.txt
initial-setup.noarch: W: no-manual-page-for-binary initial-setup
1 packages and 0 specfiles checked; 1 errors, 2 warnings.




Rpmlint (installed packages)
----------------------------
# rpmlint initial-setup
initial-setup.noarch: W: no-documentation
initial-setup.noarch: E: zero-length /usr/share/initial-setup/modules/README.txt
initial-setup.noarch: W: no-manual-page-for-binary initial-setup
1 packages and 0 specfiles checked; 1 errors, 2 warnings.
# echo 'rpmlint-done:'



Requires
--------
initial-setup (rpmlib, GLIBC filtered):
    /bin/sh
    anaconda
    chkconfig
    firstboot(windowmanager)
    gtk3
    libreport-python
    python
    python(abi)
    systemd-sysv
    systemd-units



Provides
--------
initial-setup:
    initial-setup



Generated by fedora-review 0.4.0 (cf29f98) last change: 2013-02-08
Buildroot used: fedora-rawhide-x86_64
Command line :./try-fedora-review -b 896101 -m fedora-rawhide-x86_64

Comment 11 Martin Sivák 2013-02-13 12:40:12 UTC
- not sure if xorg-x11-xinit should be explicitely added as Requires,
need to check what pull it ( used by initial-setup-xserver.service )

If the service fails, it should start the text version of the initial-setup (which is not included yet..). And RPM does not have Optional dependencies.

- Requires: libreport-python 
do not seems to be needed in the code

It will be :)

- As a side note, the initial-setup-xserver.service is never disabled, not
sure if that's what you want.

It should be closely tied to initial-setup-graphical (PartOf=) and should not be started if graphical isn't... but even systemd guys were not able to tell me if it will work this way. More testing will be needed, but it shouldn't be important for package review as the functionality is usually not part of the review.

Comment 13 Michael S. 2013-02-23 12:27:58 UTC
- this part seems rather suspicious :

%doc COPYING README
%files -f %{name}.lang

shouldn't be in another order ?
It doesn't seems to work fine :
$ rpm -qpl /var/lib/mock/fedora-rawhide-x86_64/result/initial-setup-0.1-3.fc19.noarch.rpm | grep COP
$


- the metacity requires was not added nor commented on.

Comment 14 Martin Sivák 2013-02-26 10:41:08 UTC
Spec URL: http://msivak.fedorapeople.org/newpkg/initial-setup.spec
SRPM URL: http://msivak.fedorapeople.org/newpkg/initial-setup-0.2-1.fc17.src.rpm

I added a script to start the proper window-manager, Requires: firstboot(windowmanager) is correct as is the Provides in gnome, xfce and others.

Firstboot now does not have a hard dependency on metacity as it is supposed to work with other window managers as well.

I fixed the %doc macro.

Comment 15 Michael S. 2013-02-27 21:58:12 UTC
Ok, so I guess this should be ok.

Comment 16 Martin Sivák 2013-03-01 10:15:06 UTC
New Package SCM Request
=======================
Package Name: initial-setup
Short Description: The after-installer setup utility (replacement for firstboot)
Owners: msivak vpodzime
Branches: f19
InitialCC:

Comment 17 Gwyn Ciesla 2013-03-01 13:05:31 UTC
Requested package name initial-setup doesn't match bug summary inital-setup,
please correct.

Comment 18 Gwyn Ciesla 2013-03-01 13:27:41 UTC
Git done (by process-git-requests).


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