Spec URL: https://raw.githubusercontent.com/marxin/fedora-Pebble/master/python-Pebble.spec SRPM URL: https://github.com/marxin/fedora-Pebble/raw/master/python3-Pebble-4.5.1-0.src.rpm Description: Threading and multiprocessing eye-candy for Python Fedora Account System Username: marxin
Is there any progress about the package addition, please?
Hey Martin. This is my fault, I've assigned this to myself and than got distracted and I forgot to finish. Will get back during the week (if not, don'T hesitate to ping me on IRC about this). I am sorry.
Ok, spec sanity: 1) the name should be lowercase https://docs.fedoraproject.org/en-US/packaging-guidelines/Naming/#_general_naming 2) is the copyright header required by your employer? Fedora contributors are covered by https://fedoraproject.org/wiki/Legal:Fedora_Project_Contributor_Agreement which makes this MIT by default 3) the source can be %{pypi_source Pebble} 4) there should be a python3-pebble subpackage, see https://docs.fedoraproject.org/en-US/packaging-guidelines/Python/#_naming 5) the license tag in Fedora is unfortunately different from SUSE, see https://fedoraproject.org/wiki/Licensing:Main?rd=Licensing#SoftwareLicenses 6) The Group tag is not supposed to be used: https://docs.fedoraproject.org/en-US/packaging-guidelines/#_tags_and_sections 7) %{python3_sitelib}/* is not supposed to be used: https://docs.fedoraproject.org/en-US/packaging-guidelines/Python/#_files_to_include 8) changelog is missing (maybe intentionally for the review? or because it's external in Open Build Service?)
(In reply to Miro Hrončok from comment #3) > Ok, spec sanity: Thank you for the review: > > 1) the name should be lowercase > https://docs.fedoraproject.org/en-US/packaging-guidelines/Naming/ > #_general_naming Fixed. > > 2) is the copyright header required by your employer? Fedora contributors > are covered by > https://fedoraproject.org/wiki/Legal:Fedora_Project_Contributor_Agreement > which makes this MIT by default Removed. > > 3) the source can be %{pypi_source Pebble} Done. > > 4) there should be a python3-pebble subpackage, see > https://docs.fedoraproject.org/en-US/packaging-guidelines/Python/#_naming How are these 2 files related? > > 5) the license tag in Fedora is unfortunately different from SUSE, see > https://fedoraproject.org/wiki/Licensing:Main?rd=Licensing#SoftwareLicenses > Done. > 6) The Group tag is not supposed to be used: > https://docs.fedoraproject.org/en-US/packaging-guidelines/#_tags_and_sections Removed. > > 7) %{python3_sitelib}/* is not supposed to be used: > https://docs.fedoraproject.org/en-US/packaging-guidelines/Python/ > #_files_to_include Hm, I noticed it's being used by other Fedora packages: https://apps.fedoraproject.org/packages/python3-GitPython/sources/spec/ > > 8) changelog is missing (maybe intentionally for the review? or because it's > external in Open Build Service?) Added. Please pull: https://github.com/marxin/fedora-Pebble/commit/dc84efb94ed0532256c440a33b138e5c518d0769
> How are these 2 files related? What files? Sorry, I am confused. > Hm, I noticed it's being used by other Fedora packages: Yes, the rule was not always there.
(In reply to Miro Hrončok from comment #5) > > How are these 2 files related? > > What files? Sorry, I am confused. My question is: Will the packages shared the same spec file? > > > Hm, I noticed it's being used by other Fedora packages: > > Yes, the rule was not always there. I fixed that in the github repo.
> Will the packages shared the same spec file? Yes, it's a subpackage. See the example in https://docs.fedoraproject.org/en-US/packaging-guidelines/Python/#_example_python_spec_file
All right, I've just copied the file: https://github.com/marxin/fedora-Pebble/commit/92f7a12b1fed329ad381b74388883ff962d9fc1c
The source package name should be python-pebble, the subpackage name should be python3-pebble, see the example in https://docs.fedoraproject.org/en-US/packaging-guidelines/Python/#_example_python_spec_file Also, the files section is overcomplicated now, this should work: %files -n python3-pebble %doc README.rst %license LICENSE %{python3_sitelib}/pebble/ %{python3_sitelib}/Pebble-*.egg-info/
Ok, should be fixed now, please take a look.
The main package doesn't have Summary.
Suggestion: Run tests in %check?
Yes, both things are fixed.
Ok, could you please give me a new SRPM link?
Done in the git repository.
Spec URL: https://github.com/marxin/fedora-Pebble/raw/master/python-pebble.spec SRPM URL: https://github.com/marxin/fedora-Pebble/raw/master/python-pebble-4.5.1-0.src.rpm
BTW the changelog entry should say: 4.5.1-1 and the release should be 1%{?dist}.
(In reply to Miro Hrončok from comment #17) > BTW the changelog entry should say: 4.5.1-1 and the release should be > 1%{?dist}. Fixed!
Not fixed. You've added the dist to version, not release. See https://docs.fedoraproject.org/en-US/packaging-guidelines/DistTag/
The package doesn't build as is: + /usr/bin/python3 setup.py test fatal: No names found, cannot describe anything. running test WARNING: Testing via this command is deprecated and will be removed in a future version. Users looking for a generic test entry point independent of test runner are encouraged to use tox. running egg_info writing Pebble.egg-info/PKG-INFO writing dependency_links to Pebble.egg-info/dependency_links.txt writing requirements to Pebble.egg-info/requires.txt writing top-level names to Pebble.egg-info/top_level.txt reading manifest file 'Pebble.egg-info/SOURCES.txt' reading manifest template 'MANIFEST.in' writing manifest file 'Pebble.egg-info/SOURCES.txt' running build_ext Traceback (most recent call last): File "setup.py", line 42, in <module> setup( File "/usr/lib/python3.8/site-packages/setuptools/__init__.py", line 144, in setup return distutils.core.setup(**attrs) File "/usr/lib64/python3.8/distutils/core.py", line 148, in setup dist.run_commands() File "/usr/lib64/python3.8/distutils/dist.py", line 966, in run_commands self.run_command(cmd) File "/usr/lib64/python3.8/distutils/dist.py", line 985, in run_command cmd_obj.run() File "/usr/lib/python3.8/site-packages/setuptools/command/test.py", line 238, in run self.run_tests() File "/usr/lib/python3.8/site-packages/setuptools/command/test.py", line 256, in run_tests test = unittest.main( File "/usr/lib64/python3.8/unittest/main.py", line 100, in __init__ self.parseArgs(argv) File "/usr/lib64/python3.8/unittest/main.py", line 124, in parseArgs self._do_discovery(argv[2:]) File "/usr/lib64/python3.8/unittest/main.py", line 244, in _do_discovery self.createTests(from_discovery=True, Loader=Loader) File "/usr/lib64/python3.8/unittest/main.py", line 154, in createTests self.test = loader.discover(self.start, self.pattern, self.top) File "/usr/lib64/python3.8/unittest/loader.py", line 349, in discover tests = list(self._find_tests(start_dir, pattern)) File "/usr/lib64/python3.8/unittest/loader.py", line 405, in _find_tests tests, should_recurse = self._find_test_path( File "/usr/lib64/python3.8/unittest/loader.py", line 483, in _find_test_path tests = self.loadTestsFromModule(package, pattern=pattern) File "/usr/lib/python3.8/site-packages/setuptools/command/test.py", line 55, in loadTestsFromModule tests.append(self.loadTestsFromName(submodule)) File "/usr/lib64/python3.8/unittest/loader.py", line 191, in loadTestsFromName return self.loadTestsFromModule(obj) File "/usr/lib/python3.8/site-packages/setuptools/command/test.py", line 55, in loadTestsFromModule tests.append(self.loadTestsFromName(submodule)) File "/usr/lib64/python3.8/unittest/loader.py", line 211, in loadTestsFromName raise TypeError("calling %s returned %s, not a test" % TypeError: calling <function process at 0x7f874e77d3a0> returned <function process.<locals>.decorating_function at 0x7f874e8fcd30>, not a test
(In reply to Miro Hrončok from comment #19) > Not fixed. You've added the dist to version, not release. See > https://docs.fedoraproject.org/en-US/packaging-guidelines/DistTag/ Ah sorry, fixed!
(In reply to Miro Hrončok from comment #20) > The package doesn't build as is: > > + /usr/bin/python3 setup.py test > fatal: No names found, cannot describe anything. We run 'pytest' in OBS. Do you have a macro for it?
In rawhide, we have %pytest. I plan to backport it soon. See https://lists.fedoraproject.org/archives/list/python-devel@lists.fedoraproject.org/thread/XLPDSH362PJKMJCAYOXNJNV53Y66EF6B/ If you target non-rawhide versions of Fedora as well, just run 'pytest'.
Done.
I need a new SRPM to do the review.
Spec URL: https://github.com/marxin/fedora-Pebble/raw/master/python-pebble.spec SRPM URL: https://github.com/marxin/fedora-Pebble/raw/master/python-pebble-4.5.1-1.src.rpm
Still doesn't build. Could you please test your changes? + pytest ============================= test session starts ============================== platform linux -- Python 3.8.3rc1, pytest-4.6.10, py-1.8.0, pluggy-0.13.0 rootdir: /builddir/build/BUILD/pebble-4.5.1 plugins: celery-4.3.0, cov-2.8.1 collected 0 items / 9 errors ==================================== ERRORS ==================================== ____________ ERROR collecting test/test_concurrent_process_fork.py _____________ ImportError while importing test module '/builddir/build/BUILD/pebble-4.5.1/test/test_concurrent_process_fork.py'. Hint: make sure your test modules/packages have valid Python names. Traceback: test/test_concurrent_process_fork.py:11: in <module> from pebble import concurrent, ProcessExpired E ModuleNotFoundError: No module named 'pebble' _________ ERROR collecting test/test_concurrent_process_forkserver.py __________ ImportError while importing test module '/builddir/build/BUILD/pebble-4.5.1/test/test_concurrent_process_forkserver.py'. Hint: make sure your test modules/packages have valid Python names. Traceback: test/test_concurrent_process_forkserver.py:11: in <module> from pebble import concurrent, ProcessExpired E ModuleNotFoundError: No module named 'pebble' ____________ ERROR collecting test/test_concurrent_process_spawn.py ____________ ImportError while importing test module '/builddir/build/BUILD/pebble-4.5.1/test/test_concurrent_process_spawn.py'. Hint: make sure your test modules/packages have valid Python names. Traceback: test/test_concurrent_process_spawn.py:11: in <module> from pebble import concurrent, ProcessExpired E ModuleNotFoundError: No module named 'pebble' _______________ ERROR collecting test/test_concurrent_thread.py ________________ ImportError while importing test module '/builddir/build/BUILD/pebble-4.5.1/test/test_concurrent_thread.py'. Hint: make sure your test modules/packages have valid Python names. Traceback: test/test_concurrent_thread.py:4: in <module> from pebble import concurrent E ModuleNotFoundError: No module named 'pebble' _____________________ ERROR collecting test/test_pebble.py _____________________ ImportError while importing test module '/builddir/build/BUILD/pebble-4.5.1/test/test_pebble.py'. Hint: make sure your test modules/packages have valid Python names. Traceback: test/test_pebble.py:11: in <module> from pebble import decorators E ModuleNotFoundError: No module named 'pebble' _______________ ERROR collecting test/test_process_pool_fork.py ________________ ImportError while importing test module '/builddir/build/BUILD/pebble-4.5.1/test/test_process_pool_fork.py'. Hint: make sure your test modules/packages have valid Python names. Traceback: test/test_process_pool_fork.py:12: in <module> import pebble E ModuleNotFoundError: No module named 'pebble' ____________ ERROR collecting test/test_process_pool_forkserver.py _____________ ImportError while importing test module '/builddir/build/BUILD/pebble-4.5.1/test/test_process_pool_forkserver.py'. Hint: make sure your test modules/packages have valid Python names. Traceback: test/test_process_pool_forkserver.py:12: in <module> import pebble E ModuleNotFoundError: No module named 'pebble' _______________ ERROR collecting test/test_process_pool_spawn.py _______________ ImportError while importing test module '/builddir/build/BUILD/pebble-4.5.1/test/test_process_pool_spawn.py'. Hint: make sure your test modules/packages have valid Python names. Traceback: test/test_process_pool_spawn.py:12: in <module> import pebble E ModuleNotFoundError: No module named 'pebble' __________________ ERROR collecting test/test_thread_pool.py ___________________ ImportError while importing test module '/builddir/build/BUILD/pebble-4.5.1/test/test_thread_pool.py'. Hint: make sure your test modules/packages have valid Python names. Traceback: test/test_thread_pool.py:5: in <module> from pebble import ThreadPool E ModuleNotFoundError: No module named 'pebble' !!!!!!!!!!!!!!!!!!! Interrupted: 9 errors during collection !!!!!!!!!!!!!!!!!!!! =========================== 9 error in 0.38 seconds ============================ Try: PYTHONPATH=%{buildroot}%{python3_sitelib} pytest
I'm sorry but it's all blind development. I don't an access to a Fedora system and I need apparently fedora-packager. I changed to: PYTHONPATH=%{buildroot}%{python3_sitelib} pytest but I can't test that.
> I'm sorry but it's all blind development. I don't an access to a Fedora system and > I need apparently fedora-packager. Oh. Can you try in docker for example?
Yep, I should have done it earlier. Ok, right now I built the package with podman. I've just added build dependency on python3-pytest. Btw. do you have a way how to install all BuildRequires packages before you run rpmbuild?
Into the environment you are in: $ sudo dnf build-dep xxx.spec I personally use mock to have more reproducible setups and to avoid installing everything to my machine. Many packagers do as well. https://github.com/rpm-software-management/mock/wiki If you have something new for me to review, please recreate the SRPM and post new links. Thanks.
All right, I regenerated them in Fedora container: SRPM: https://github.com/marxin/fedora-Pebble/raw/master/python-pebble-4.5.1-1.fc31.src.rpm SPEC: https://raw.githubusercontent.com/marxin/fedora-Pebble/master/python-pebble.spec
May I please ping that?
Running a build now.
Sources in SRPM do not match what can be downloaded from the URL. https://files.pythonhosted.org/packages/source/P/Pebble/Pebble-4.5.1.tar.gz : CHECKSUM(SHA256) this package : 89828b4ebe1654b81c64d3b1aecc19d651a05231f86cc981af6f9e18f9825c38 CHECKSUM(SHA256) upstream package : 26fdcc0f36d93d8e07559d36b942b7800c6b9622626d5b587ab1a74820d02732 diff -r also reports differences
Fixed: SRPM: https://github.com/marxin/fedora-Pebble/raw/master/python-pebble-4.5.3-1.fc31.src.rpm SPEC: https://raw.githubusercontent.com/marxin/fedora-Pebble/master/python-pebble.spec
It seem to me that the license should be LGPLv3+, see https://github.com/noxdafox/pebble/blob/4.5.3/pebble/common.py#L7 -- it says "or (at your option) any later version" Also note that there are 162 skipped tests (from 241). Maybe a dependency is missing?
> Also note that there are 162 skipped tests (from 241). Maybe a dependency is missing? Seem like it's all about support for various features in Python. I'll trust upstream the detection is OK.
(In reply to Miro Hrončok from comment #38) > It seem to me that the license should be LGPLv3+, see > https://github.com/noxdafox/pebble/blob/4.5.3/pebble/common.py#L7 -- it says > "or (at your option) any later version" > > > Also note that there are 162 skipped tests (from 241). Maybe a dependency is > missing? Fixed.
> > Also note that there are 162 skipped tests (from 241). Maybe a dependency is > missing? They should be run in separate pytest context: https://github.com/noxdafox/pebble/blob/master/test/run-tests.sh because one can't change start method multiple times: https://github.com/noxdafox/pebble/blob/master/test/test_concurrent_process_forkserver.py#L21
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: "Unknown or generated", "GNU Lesser General Public License (v3 or later)". [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). [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. [-]: 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: No rpmlint messages. [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]: 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 must not depend on deprecated() packages. [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 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]: Packages MUST NOT have dependencies (either build-time or runtime) on packages named with the unversioned python- prefix unless no properly versioned package exists. Dependencies on Python packages instead MUST use names beginning with python2- or python3- as appropriate. [x]: Python packages must not contain %{pythonX_site(lib|arch)}/* in %files [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. [?]: Latest version is packaged. [x]: Package does not include license text files separate from upstream. [-]: Sources are verified with gpgverify first in %prep if upstream publishes signatures. Note: gpgverify is not used. [-]: Description and summary sections in the package spec file contains translations for supported Non-English languages, if available. [?]: Package should compile and build into binary rpms on all supported architectures. [x]: %check is present and all tests pass. [?]: 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]: 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]: 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: python3-pebble-4.5.3-1.fc33.noarch.rpm python-pebble-4.5.3-1.fc33.src.rpm 2 packages and 0 specfiles checked; 0 errors, 0 warnings. Rpmlint (installed packages) ---------------------------- 1 packages and 0 specfiles checked; 0 errors, 0 warnings. Source checksums ---------------- https://files.pythonhosted.org/packages/source/P/Pebble/Pebble-4.5.3.tar.gz : CHECKSUM(SHA256) this package : e2cfc81bf1e627ff6314f4e1ca0c3414779d408594f807d702d088c19ff5070b CHECKSUM(SHA256) upstream package : e2cfc81bf1e627ff6314f4e1ca0c3414779d408594f807d702d088c19ff5070b Requires -------- python3-pebble (rpmlib, GLIBC filtered): python(abi) Provides -------- python3-pebble: python-pebble python3-pebble python3.8-pebble python3.8dist(pebble) python3dist(pebble) Generated by fedora-review 0.7.0 (fed5495) last change: 2019-03-17 Command line :try-fedora-review -b 1829340 -m fedora-rawhide-x86_64 Buildroot used: fedora-rawhide-x86_64 Active plugins: Generic, Python, Shell-api Disabled plugins: Perl, R, Java, SugarActivity, fonts, C/C++, Haskell, PHP, Ocaml, Ruby Disabled flags: EPEL6, EPEL7, DISTTAG, BATCH, EXARCH
(In reply to Martin Liška from comment #41) > > > > Also note that there are 162 skipped tests (from 241). Maybe a dependency is > > missing? > > They should be run in separate pytest context: > https://github.com/noxdafox/pebble/blob/master/test/run-tests.sh > > because one can't change start method multiple times: > https://github.com/noxdafox/pebble/blob/master/test/ > test_concurrent_process_forkserver.py#L21 Consider adapting the test section to do the same thing.
(fedscm-admin): The Pagure repository was created at https://src.fedoraproject.org/rpms/python-pebble