Bug 2235068 (python-jsonstreams) - Review Request: python-jsonstreams - Python library for writing JSON documents as streams
Summary: Review Request: python-jsonstreams - Python library for writing JSON document...
Keywords:
Status: CLOSED ERRATA
Alias: python-jsonstreams
Product: Fedora
Classification: Fedora
Component: Package Review
Version: rawhide
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Miroslav Suchý
QA Contact: Fedora Extras Quality Assurance
URL: https://github.com/dcbaker/jsonstreams
Whiteboard:
Depends On:
Blocks: scancode-toolkit
TreeView+ depends on / blocked
 
Reported: 2023-08-26 11:22 UTC by Robert-André Mauchin 🐧
Modified: 2023-11-06 04:16 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2023-11-06 01:30:33 UTC
Type: ---
Embargoed:
msuchy: fedora-review+


Attachments (Terms of Use)

Description Robert-André Mauchin 🐧 2023-08-26 11:22:54 UTC
Spec URL: https://eclipseo.fedorapeople.org/for-review/python-jsonstreams.spec
SRPM URL: https://eclipseo.fedorapeople.org/for-review/python-jsonstreams-0.6.0-1.fc38.src.rpm

Description:
JSONstreams is a package that attempts to making writing JSON in a streaming format easier. In contrast to the core json module, this package doesn't require building a complete tree of dicts and lists before writing, instead it provides a straightforward way to to write a JSON document without building the whole data structure ahead of time.  JSONstreams considers there to be two basic types, the JSON array and the JSON object, which correspond to Python's list and dict respectively, and can encode any types that the json.JSONEncoder can, or can use an subclass to handle additional types.  The interface is designed to be context manger centric. The Stream class, and the Array and Object classes returned by the subarray and subobject methods (respectively), can be used as context managers or not, but use as context managers are recommended to ensure that each container is closed properly.

Fedora Account System Username: eclipseo

To build it against the dependencies, use the following COPR in your rawhide mock.cfg:

[copr:copr.fedorainfracloud.org:eclipseo:scancode-toolkit]
name=Copr repo for scancode-toolkit owned by eclipseo
baseurl=https://download.copr.fedorainfracloud.org/results/eclipseo/scancode-toolkit/fedora-rawhide-/
type=rpm-md
skip_if_unavailable=True
gpgcheck=1
gpgkey=https://download.copr.fedorainfracloud.org/results/eclipseo/scancode-toolkit/pubkey.gpg
repo_gpgcheck=0
enabled=1
enabled_metadata=1

Comment 1 Benson Muite 2023-09-28 05:33:12 UTC
Sphinx will generate a number of javascript files for
html documentation.  Some of these should be indicated
as bundled, for example js-jquery.  May consider
also generating man pages.

Comment 2 Miroslav Suchý 2023-10-08 10:18:24 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.
[x]: License file installed when any subpackage combination is installed.
[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.
[x]: 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]: 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]: The License field must be a valid SPDX expression.
[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]: Large documentation must go in a -doc subpackage. Large could be size
     (~1MB) or number of files.
     Note: Documentation size is 2753 bytes in 1 files.
[x]: Packages must not store files under /srv, /opt or /usr/local

Python:
[-]: Binary eggs must be removed in %prep
[x]: Python eggs must not download any dependencies during the build
     process.
[-]: 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

===== 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).
[-]: Fully versioned dependency in subpackages if applicable.
[-]: 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.
[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]: 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.


The package looks good. 
Regarding the Benson comment, I think you need to add.

Provides: bundled(js-searchtools)

After that change I will approve.

Comment 3 Robert-André Mauchin 🐧 2023-10-15 19:12:36 UTC
Sphinx will generate a number of javascript files for
html documentation.  Some of these should be indicated
as bundled, for example js-jquery.  May consider
also generating man pages.


This seems only true < F39 (starting Sphinx 6). If I package for F38, I will add the bundled Provides.



Spec URL: https://eclipseo.fedorapeople.org/for-review/python-jsonstreams.spec
SRPM URL: https://eclipseo.fedorapeople.org/for-review/python-jsonstreams-0.6.0-1.fc39.src.rpm

Comment 4 Fedora Review Service 2023-10-15 19:15:14 UTC
Copr build:
https://copr.fedorainfracloud.org/coprs/build/6528323
(failed)

Build log:
https://download.copr.fedorainfracloud.org/results/@fedora-review/fedora-review-2235068-python-jsonstreams/fedora-rawhide-x86_64/06528323-python-jsonstreams/builder-live.log.gz

Please make sure the package builds successfully at least for Fedora Rawhide.

- If the build failed for unrelated reasons (e.g. temporary network
  unavailability), please ignore it.
- If the build failed because of missing BuildRequires, please make sure they
  are listed in the "Depends On" field


---
This comment was created by the fedora-review-service
https://github.com/FrostyX/fedora-review-service

If you want to trigger a new Copr build, add a comment containing new
Spec and SRPM URLs or [fedora-review-service-build] string.

Comment 5 Miroslav Suchý 2023-10-16 06:15:53 UTC
1) now the build is failing because of missing BR python3-pytest

2) 
> This seems only true < F39 (starting Sphinx 6). If I package for F38, I will add the bundled Provides.

I see something else.

$ rpm -qlpf /var/lib/mock/fedora-rawhide-x86_64/result/python-jsonstreams-doc-0.6.0-1.fc40.noarch.rpm 
/usr/share/doc/python-jsonstreams-doc
/usr/share/doc/python-jsonstreams-doc/html
/usr/share/doc/python-jsonstreams-doc/html/_sources
/usr/share/doc/python-jsonstreams-doc/html/_sources/api.rst.txt
/usr/share/doc/python-jsonstreams-doc/html/_sources/changes.rst.txt
/usr/share/doc/python-jsonstreams-doc/html/_sources/description.rst.txt
/usr/share/doc/python-jsonstreams-doc/html/_sources/examples.rst.txt
/usr/share/doc/python-jsonstreams-doc/html/_sources/index.rst.txt
/usr/share/doc/python-jsonstreams-doc/html/_static
/usr/share/doc/python-jsonstreams-doc/html/_static/basic.css
/usr/share/doc/python-jsonstreams-doc/html/_static/css
/usr/share/doc/python-jsonstreams-doc/html/_static/css/badge_only.css
/usr/share/doc/python-jsonstreams-doc/html/_static/css/theme.css
/usr/share/doc/python-jsonstreams-doc/html/_static/doctools.js
/usr/share/doc/python-jsonstreams-doc/html/_static/documentation_options.js
/usr/share/doc/python-jsonstreams-doc/html/_static/file.png
/usr/share/doc/python-jsonstreams-doc/html/_static/js
/usr/share/doc/python-jsonstreams-doc/html/_static/js/badge_only.js
/usr/share/doc/python-jsonstreams-doc/html/_static/js/theme.js
/usr/share/doc/python-jsonstreams-doc/html/_static/language_data.js
/usr/share/doc/python-jsonstreams-doc/html/_static/minus.png
/usr/share/doc/python-jsonstreams-doc/html/_static/plus.png
/usr/share/doc/python-jsonstreams-doc/html/_static/pygments.css
/usr/share/doc/python-jsonstreams-doc/html/_static/searchtools.js
/usr/share/doc/python-jsonstreams-doc/html/_static/sphinx_highlight.js
/usr/share/doc/python-jsonstreams-doc/html/api.html
/usr/share/doc/python-jsonstreams-doc/html/changes.html
/usr/share/doc/python-jsonstreams-doc/html/description.html
/usr/share/doc/python-jsonstreams-doc/html/examples.html
/usr/share/doc/python-jsonstreams-doc/html/genindex.html
/usr/share/doc/python-jsonstreams-doc/html/index.html
/usr/share/doc/python-jsonstreams-doc/html/objects.inv
/usr/share/doc/python-jsonstreams-doc/html/search.html
/usr/share/doc/python-jsonstreams-doc/html/searchindex.js
/usr/share/licenses/python-jsonstreams-doc
/usr/share/licenses/python-jsonstreams-doc/LICENSE

Comment 6 Robert-André Mauchin 🐧 2023-10-21 16:11:47 UTC
> I see something else.

I see the same thing and no external library ? No underscore or jquery, all of these files are Sphinx regular ones.


> 1) now the build is failing because of missing BR python3-pytest

It is already in the latest file I uploaded:

BuildRequires:  python3dist(pytest)

It is already built here: https://copr.fedorainfracloud.org/coprs/eclipseo/scancode-toolkit/build/6528339/

Comment 7 Miroslav Suchý 2023-10-21 20:05:13 UTC
>> 1) now the build is failing because of missing BR python3-pytest
>It is already in the latest file I uploaded

Ah right, likely some error on my side. Ack.

>> I see something else.
>I see the same thing and no external library ? No underscore or jquery, all of these files are Sphinx regular ones.

Yes, these files were generated by sphinx, but still they are bundled in your package. So you must include that Provides.
You may ask sphinx maintainers to generate these provides automatically, but that will not happen over night.

Comment 8 Robert-André Mauchin 🐧 2023-10-22 15:36:14 UTC
Added :

%package -n python-%{pypi_name}-doc
Summary:        Documentation for python-%{pypi_name}
# BSD-2-Clause: Sphinx javascript
License:        MIT AND BSD-2-Clause
BuildArch:      noarch
Requires:       python3-%{pypi_name} = %{?epoch:%{epoch}:}%{version}-%{release}
Provides:       bundled(js-doctools)
Provides:       bundled(js-language_data)
Provides:       bundled(js-searchtools)



Spec URL: https://eclipseo.fedorapeople.org/for-review/python-jsonstreams.spec
SRPM URL: https://eclipseo.fedorapeople.org/for-review/python-jsonstreams-0.6.0-1.fc39.src.rpm

Thanks!

Comment 9 Miroslav Suchý 2023-10-22 17:27:46 UTC
Thank you.
APPROVED

Comment 10 Robert-André Mauchin 🐧 2023-10-23 16:25:33 UTC
Thank you!

Comment 11 Fedora Admin user for bugzilla script actions 2023-10-23 16:25:40 UTC
The Pagure repository was created at https://src.fedoraproject.org/rpms/python-jsonstreams

Comment 12 Fedora Update System 2023-10-28 21:02:40 UTC
FEDORA-2023-21007cc457 has been submitted as an update to Fedora 39. https://bodhi.fedoraproject.org/updates/FEDORA-2023-21007cc457

Comment 13 Fedora Update System 2023-10-28 21:37:11 UTC
FEDORA-2023-39514db080 has been submitted as an update to Fedora 38. https://bodhi.fedoraproject.org/updates/FEDORA-2023-39514db080

Comment 14 Fedora Update System 2023-10-28 22:54:16 UTC
FEDORA-2023-2f686a69a7 has been submitted as an update to Fedora 37. https://bodhi.fedoraproject.org/updates/FEDORA-2023-2f686a69a7

Comment 15 Fedora Update System 2023-10-29 01:21:43 UTC
FEDORA-2023-21007cc457 has been pushed to the Fedora 39 testing repository.
Soon you'll be able to install the update with the following command:
`sudo dnf install --enablerepo=updates-testing --refresh --advisory=FEDORA-2023-21007cc457 \*`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2023-21007cc457

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 16 Fedora Update System 2023-10-29 01:55:09 UTC
FEDORA-2023-39514db080 has been pushed to the Fedora 38 testing repository.
Soon you'll be able to install the update with the following command:
`sudo dnf install --enablerepo=updates-testing --refresh --advisory=FEDORA-2023-39514db080 \*`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2023-39514db080

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 17 Fedora Update System 2023-10-29 02:15:38 UTC
FEDORA-2023-2f686a69a7 has been pushed to the Fedora 37 testing repository.
Soon you'll be able to install the update with the following command:
`sudo dnf install --enablerepo=updates-testing --refresh --advisory=FEDORA-2023-2f686a69a7 \*`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2023-2f686a69a7

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 18 Fedora Update System 2023-11-06 01:30:33 UTC
FEDORA-2023-21007cc457 has been pushed to the Fedora 39 stable repository.
If problem still persists, please make note of it in this bug report.

Comment 19 Fedora Update System 2023-11-06 01:36:32 UTC
FEDORA-2023-39514db080 has been pushed to the Fedora 38 stable repository.
If problem still persists, please make note of it in this bug report.

Comment 20 Fedora Update System 2023-11-06 04:16:38 UTC
FEDORA-2023-2f686a69a7 has been pushed to the Fedora 37 stable repository.
If problem still persists, 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.