Bug 1154218 - Review Request: graphite-api - Graphite-web, without the interface. Just the rendering HTTP API
Summary: Review Request: graphite-api - Graphite-web, without the interface. Just the...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: Package Review
Version: rawhide
Hardware: All
OS: Linux
unspecified
medium
Target Milestone: ---
Assignee: Parag AN(पराग)
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On: 1154213 1239160
Blocks: 1270490
TreeView+ depends on / blocked
 
Reported: 2014-10-17 22:18 UTC by Piotr Popieluch
Modified: 2016-08-26 15:49 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2016-08-26 15:49:20 UTC
panemade: fedora-review+


Attachments (Terms of Use)

Description Piotr Popieluch 2014-10-17 22:18:11 UTC
Spec URL: http://vps533.directvps.nl/graphite-api.spec
SRPM URL: http://vps533.directvps.nl/graphite-api-1.0.1-1.fc20.src.rpm

Description: 
Graphite-API is an alternative to Graphite-web, without any built-in dashboard.
Its role is solely to fetch metrics from a time-series database (whisper,
cyanite, etc.) and rendering graphs or JSON data out of these time series. It
is meant to be consumed by any of the numerous Graphite dashboard applications.

Fedora Account System Username: piotrp

koji builds:
rawhide: http://koji.fedoraproject.org/koji/taskinfo?taskID=7900295
f22: http://koji.fedoraproject.org/koji/taskinfo?taskID=7900304
f21: http://koji.fedoraproject.org/koji/taskinfo?taskID=7900307
f20: http://koji.fedoraproject.org/koji/taskinfo?taskID=7900312
f19: http://koji.fedoraproject.org/koji/taskinfo?taskID=7900313
epel7: http://koji.fedoraproject.org/koji/taskinfo?taskID=7900316


This depends on https://bugzilla.redhat.com/show_bug.cgi?id=1154213
I'm a new package maintainer thus need a sponsor.

Comment 1 Dominik 'Rathann' Mierzejewski 2014-10-20 11:07:58 UTC
A couple of quick comments:

There's some trailing whitespace at the end of lines 35, 75 and 79.

I think you need Requires: systemd for %{_unitdir} directory ownership.

Please use explicit %{__python2} instead of %{__python} and, if viable, build a python3 package as well.

Comment 2 Piotr Popieluch 2014-10-20 18:47:18 UTC
Thank you for reviewing.

I will fix the whitespaces.

I'm not sure about the "Requires: systemd" 
I've took this page as example https://fedoraproject.org/wiki/Packaging:ScriptletSnippets#Systemd
They only require in post, preun, postun. I've checked a couple existing packages and some only require post/pre others only include on "Requires: systemd". It's not clear to me what 'the right way to do this' is.

I will make python2 explicit for now. It doesn't make sense to me to ship two packages yet. I think the user will only use the python version which is default with the OS. I will add python3 when it gets the default python (I think it is scheduled for f22).

Comment 3 Piotr Popieluch 2014-10-22 19:45:51 UTC
New release:

Spec URL: http://vps533.directvps.nl/graphite-api.spec
SRPM URL: http://vps533.directvps.nl/graphite-api-1.0.1-2.fc20.src.rpm

- trailing whitespaces fixed
- made python2 explicit
- added %check section
- added patch from upstream to fix an issue with timezones which made the %check fail

Comment 4 James Turnbull 2015-06-24 02:00:26 UTC
Hi - just wondering on the status of this? Thanks!

Comment 5 Parag AN(पराग) 2015-06-24 03:04:57 UTC
James,
  Feel free to review this package.

Comment 6 James Turnbull 2015-06-24 03:06:11 UTC
Parag - It appears the spec and the package file are no longer at the URL. I was hoping to revive the previous submitters interest.

Comment 7 Piotr Popieluch 2015-06-24 17:49:44 UTC
Im on Holiday now, will upload spec and srpm as soon as i get back. Also Note that i dont use this myself anymore, still willing tot maintain anything graphite related but a comaintainer would be good for quality of package.

Comment 8 James Turnbull 2015-06-24 18:02:46 UTC
Piotr - happy to help.

Comment 9 Piotr Popieluch 2015-07-02 11:40:58 UTC
Spec URL: https://piotrp.fedorapeople.org/graphite-api.spec
SRPM URL: https://piotrp.fedorapeople.org/graphite-api-1.0.1-3.fc22.src.rpm

notes:
- will need some work to get it working on Python 3
- no el6 support
- this is the last available release + a patch. There are many new commits since the last release, maybe we should package the git head instead of the release.

Comment 10 James Turnbull 2015-07-02 15:30:29 UTC
Agreed on HEAD. I've been discussing upstream doing a new release soon hopefully. It's unclear to me what's needed for Python 3 support.

Comment 11 Piotr Popieluch 2015-07-02 22:54:13 UTC
HEAD appears to depend on Flask-Cache which is not in Fedora yet, tests fail now. Will try to package Flask-Cache tomorrow. 

I haven't looked into Python 3 yet, I expect some issues with dependencies which are still missing.

Comment 12 James Turnbull 2015-07-02 23:00:41 UTC
Quickly testing on CentOS Linux release 7.1.1503 (Core) I had to pip upgrade urllib3, six, pyparsing, and websocket to get it to work. Not being overly Python savvy or how Python libraries are packaged on RH/Fedora/CentOS - I am not sure how helpful that is.

$ pip list
backports.ssl-match-hostname (3.4.0.2)
boto (2.38.0)
cairocffi (0.7.1)
carbon (0.9.12)
cffi (1.1.2)
chardet (2.0.1)
Cheetah (2.4.4)
cloud-init (0.7.5)
configobj (4.7.2)
decorator (3.4.0)
Django (1.6.11)
django-tagging (0.3.1)
Flask (0.10.1)
gevent (1.0.2)
graphite-api (1.0.1)
graphite-web (0.9.12)
greenlet (0.4.7)
gunicorn (19.3.0)
iniparse (0.4)
IPy (0.75)
itsdangerous (0.24)
Jinja2 (2.7.3)
jsonpatch (1.2)
jsonpointer (1.0)
Markdown (2.4.1)
MarkupSafe (0.23)
Pillow (2.0.0)
pip (1.5.6)
policycoreutils-default-encoding (0.1)
prettytable (0.7.2)
psycopg2 (2.5.1)
pycparser (2.14)
pycurl (7.19.0)
Pygments (1.4)
pygobject (3.8.2)
pygpgme (0.3)
pyliblzma (0.5.3)
pyOpenSSL (0.13.1)
pyparsing (2.0.3)
pyserial (2.6)
pytz (2012d)
pyudev (0.15)
pyxattr (0.5.1)
PyYAML (3.10)
requests (1.1.0)
rsa (3.1.1)
seobject (0.1)
sepolicy (1.1)
setuptools (0.9.8)
simplejson (3.3.3)
six (1.9.0)
slip (0.4.0)
slip.dbus (0.4.0)
structlog (15.2.0)
Twisted-Core (12.2.0)
urlgrabber (3.10)
urllib3 (1.10.4)
websocket (0.2.1)
Werkzeug (0.10.4)
whisper (0.9.12)
wsgiref (0.1.2)
yum-metadata-parser (1.1.4)
zope.interface (4.0.5)

Comment 13 Piotr Popieluch 2015-07-03 10:23:54 UTC
Thank you for testing. I actually expected that I missed some deps... Will try to do some work on this this evening. Weather here is too good to sit at home today ;)

Comment 14 Piotr Popieluch 2015-07-05 20:27:39 UTC
Updated package for Python 3. 
Updated to git head.
Fixed Missing Requires.
Added doc package.

Builds and works fine now on Fedora. 
Currently does not build on EPEL7 because of a missing module for documentation. Will try to get that module in EPEL7 if that fails will have to omit doc package on el.


Latest version:

Spec URL: https://piotrp.fedorapeople.org/graphite-api.spec
SRPM URL: https://piotrp.fedorapeople.org/graphite-api-1.0.1-3.20150702gitbe7907c.fc22.src.rpm

Comment 15 Piotr Popieluch 2015-07-10 21:06:30 UTC
I've looked into rhel/centos 7. It appears that graphite-api needs at least python-six 1.4 and rhel7 ships 1.3.

We will not be able to get this working on rhel7.

I will clean up the spec to only support fedora/python3 later this week.

Comment 16 Piotr Popieluch 2015-07-22 20:31:23 UTC
Spec URL: https://piotrp.fedorapeople.org/graphite-api.spec
SRPM URL: https://piotrp.fedorapeople.org/graphite-api-1.0.1-4.20150702gitbe7907c.fc22.src.rpm


Updated spec and srpm:
- removed epel support, python-six in el7 is too old and not supported
- removed Python2 support, not targeting el7 anymore, fedora has python3
- fixed lint warnings

Tested on F22

scratch-build: http://koji.fedoraproject.org/koji/taskinfo?taskID=10441716

Comment 17 Piotr Popieluch 2015-07-30 18:59:51 UTC
not targeting epel7, removing epel related dependent bugs.

Comment 18 Upstream Release Monitoring 2015-09-24 15:04:32 UTC
jgrulich's scratch build of kdevelop?#c8e2b9bc57f11e41f3dc6612cdbcc591078d9062 for f22-candidate and git://pkgs.fedoraproject.org/kdevelop?#c8e2b9bc57f11e41f3dc6612cdbcc591078d9062 completed http://koji.fedoraproject.org/koji/taskinfo?taskID=11212117

Comment 19 Parag AN(पराग) 2015-09-26 07:07:51 UTC
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. Licenses
     found: "Apache (v2.0)", "Unknown or generated". 27 files have unknown
     license. Detailed output of licensecheck in /home/parag/1154218
     -graphite-api/licensecheck.txt
[!]: License file installed when any subpackage combination is installed.

==> You need to add license file to -doc subpackage

[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.
[-]: 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).

==> But there is one thing "https://fedoraproject.org/wiki/Packaging:Guidelines#Macros says that "Macro forms of system executables SHOULD NOT be used except when there is a need to allow the location of those executables to be configurable. For example, rm should be used in preference to %{__rm}, but %{__python} is acceptable."

so don't use macro __mkdir_p and __install

[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.
[x]: 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.
     Note: Documentation size is 10240 bytes in 2 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]: Package must own all directories that it creates.
[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]: %config files are marked noreplace or the reason is justified.
[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]: No %config files under /usr.
[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

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

==> You may want to use newer python macros as you targeted this package for Fedora versions.

[x]: Package contains BR: python2-devel or python3-devel
[x]: Binary eggs must be removed in %prep

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

Generic:
[ ]: Avoid bundling fonts in non-fonts packages.
     Note: Package contains font files

===> I don't know why this appeared in review.txt, also I see fedora-review have not ran fonts plugin and no font related directory or files generated in review directory so I assume this as false positive.

[-]: 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).
[-]: Fully versioned dependency in subpackages if applicable.
     Note: No Requires: %{name}%{?_isa} = %{version}-%{release} in
     graphite-api-doc
[?]: 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.


Rpmlint
-------
Checking: graphite-api-1.0.1-4.20150702gitbe7907c.fc24.noarch.rpm
          graphite-api-doc-1.0.1-4.20150702gitbe7907c.fc24.noarch.rpm
          graphite-api-1.0.1-4.20150702gitbe7907c.fc24.src.rpm
graphite-api.noarch: W: spelling-error %description -l en_US cyanite -> cyanide, Canaanite
graphite-api.src: W: spelling-error %description -l en_US cyanite -> cyanide, Canaanite
3 packages and 0 specfiles checked; 0 errors, 2 warnings.




Rpmlint (installed packages)
----------------------------
sh: /usr/bin/python: No such file or directory
2 packages and 0 specfiles checked; 0 errors, 0 warnings.



Requires
--------
graphite-api-doc (rpmlib, GLIBC filtered):

graphite-api (rpmlib, GLIBC filtered):
    /bin/sh
    config(graphite-api)
    python(abi)
    python3-PyYAML
    python3-cairo
    python3-cairocffi
    python3-cffi
    python3-flask
    python3-flask-cache
    python3-gunicorn
    python3-itsdangerous
    python3-pyparsing
    python3-pytz
    python3-six
    python3-structlog
    python3-tzlocal
    python3-werkzeug
    shadow-utils
    systemd



Provides
--------
graphite-api-doc:
    graphite-api-doc

graphite-api:
    config(graphite-api)
    graphite-api



Source checksums
----------------
https://github.com/brutasse/graphite-api/archive/be7907c0138c0b9f05a84d44fd6e41ff397d407e/graphite-api-be7907c0138c0b9f05a84d44fd6e41ff397d407e.tar.gz :
  CHECKSUM(SHA256) this package     : 0f46ff75772851366177ef2d0ee8fd17749ed27382b0c4bf0484621acdce4a57
  CHECKSUM(SHA256) upstream package : 0f46ff75772851366177ef2d0ee8fd17749ed27382b0c4bf0484621acdce4a57

Comment 20 Piotr Popieluch 2015-10-01 19:14:28 UTC
Thank you,

Update to new github source guideline,
removed system macros, 
updated to newer version, 
added license to subpackages

I'm not sure to which "newer python macros" you are referring to. Couldn't find it in the python guidelines, could you please give me more information about them?

Spec URL: https://piotrp.fedorapeople.org/graphite-api.spec
SRPM URL: https://piotrp.fedorapeople.org/graphite-api-1.0.1-5.20150926git4cb65cd.fc22.src.rpm

Comment 21 Piotr Popieluch 2015-10-09 09:01:20 UTC
PS. It seems that there is being worked on updating python-six in RHEL7, see bug 1185409

Comment 22 Parag AN(पराग) 2015-10-09 09:50:01 UTC
Oh I am so sorry I missed your updated comments above. 

Package update looks good.

APPROVED.

I was referring to this guideline https://fedoraproject.org/wiki/Packaging:Python#Example_common_spec_file

we have now python_provide, py3_build, py3_install macros.

Comment 23 Piotr Popieluch 2015-10-09 10:01:45 UTC
Thanks!

New Package SCM Request
=======================
Package Name: graphite-api
Short Description: Graphite-web, without the interface. Just the rendering HTTP API
Upstream URL: https://github.com/brutasse/graphite-api
Owners: piotrp
Branches: f22 f23 epel7

Comment 24 Gwyn Ciesla 2015-10-09 10:34:36 UTC
This SCM request method has been deprecated. Please see https://fedoraproject.org/wiki/PackageDB_admin_requests.

Comment 25 Fedora Update System 2015-10-09 14:23:10 UTC
graphite-api-1.0.1-5.20150926git4cb65cd.fc23 has been submitted as an update to Fedora 23. https://bodhi.fedoraproject.org/updates/FEDORA-2015-7979db562f

Comment 26 Fedora Update System 2015-10-09 14:51:27 UTC
graphite-api-1.0.1-5.20150926git4cb65cd.fc22 has been submitted as an update to Fedora 22. https://bodhi.fedoraproject.org/updates/FEDORA-2015-698c6946b8

Comment 27 Fedora Update System 2015-10-09 23:22:07 UTC
graphite-api-1.0.1-5.20150926git4cb65cd.fc22 has been pushed to the Fedora 22 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 'dnf --enablerepo=updates-testing update graphite-api'
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2015-698c6946b8

Comment 28 Fedora Update System 2015-10-11 08:25:32 UTC
graphite-api-1.0.1-5.20150926git4cb65cd.fc23 has been pushed to the Fedora 23 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 'dnf --enablerepo=updates-testing update graphite-api'
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2015-7979db562f

Comment 29 Fedora Update System 2015-10-13 17:22:57 UTC
graphite-api-1.1-1.fc23 has been submitted as an update to Fedora 23. https://bodhi.fedoraproject.org/updates/FEDORA-2015-f7b0fdce2c

Comment 30 Fedora Update System 2015-10-13 17:24:17 UTC
graphite-api-1.1-1.fc22 has been submitted as an update to Fedora 22. https://bodhi.fedoraproject.org/updates/FEDORA-2015-4fce70baa8

Comment 31 Fedora Update System 2015-10-14 02:13:06 UTC
graphite-api-1.1-1.fc23 has been pushed to the Fedora 23 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 'dnf --enablerepo=updates-testing update graphite-api'
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2015-f7b0fdce2c

Comment 32 Fedora Update System 2015-10-14 09:27:28 UTC
graphite-api-1.1-1.fc22 has been pushed to the Fedora 22 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 'dnf --enablerepo=updates-testing update graphite-api'
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2015-4fce70baa8

Comment 33 Fedora Update System 2015-10-23 17:20:53 UTC
graphite-api-1.1-1.fc22 has been pushed to the Fedora 22 stable repository. If problems still persist, please make note of it in this bug report.

Comment 34 Fedora Update System 2015-11-01 02:38:25 UTC
graphite-api-1.1-1.fc23 has been pushed to the Fedora 23 stable repository. If problems still persist, please make note of it in this bug report.

Comment 35 Fedora Update System 2016-08-09 21:46:06 UTC
graphite-api-1.1.3-3.el7 has been submitted as an update to Fedora EPEL 7. https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2016-aafa9d322d

Comment 36 Fedora Update System 2016-08-10 14:23:26 UTC
graphite-api-1.1.3-3.el7 has been pushed to the Fedora EPEL 7 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-EPEL-2016-aafa9d322d

Comment 37 Fedora Update System 2016-08-26 15:49:16 UTC
graphite-api-1.1.3-3.el7 has been pushed to the Fedora EPEL 7 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.