Bug 256214

Summary: ports-mgmt/pkg_tree: retrieve data from pkg info in only one try
Product: Ports & Packages Reporter: Tatsuki Makino <tatsuki_makino>
Component: Individual Port(s)Assignee: Li-Wen Hsu <lwhsu>
Status: Closed FIXED    
Severity: Affects Only Me CC: lwhsu
Priority: --- Flags: tatsuki_makino: maintainer-feedback?
Version: Latest   
Hardware: Any   
OS: Any   
Attachments:
Description Flags
patch for ports-mgmt/pkg_tree
none
poudriere log
none
patch for ports-mgmt/pkg_tree tatsuki_makino: maintainer-approval?

Description Tatsuki Makino 2021-05-28 07:29:22 UTC
Created attachment 225329 [details]
patch for ports-mgmt/pkg_tree

pkg_tree has been extended in bug 200730.
The way it works is that it calls pkg info 3 times, so there is a possibility of losing consistency.
So I changed to a better method.

Then I added the -r option.
The -r option will display the "Required by" graph instead of the "Depends on" graph.

Then, distinfo was rebuilt.
Comment 1 Tatsuki Makino 2021-05-28 07:30:13 UTC
Created attachment 225330 [details]
poudriere log
Comment 2 Li-Wen Hsu freebsd_committer freebsd_triage 2021-06-01 03:02:17 UTC
There is no maintainer of this port, do you want to take care of it?
Comment 3 Tatsuki Makino 2021-06-01 06:58:09 UTC
Created attachment 225439 [details]
patch for ports-mgmt/pkg_tree

Yes, I'd like to take over as maintainer.
This is a patch that includes the maintainer changes.
Comment 4 commit-hook freebsd_committer freebsd_triage 2021-06-01 07:21:03 UTC
A commit in branch main references this bug:

URL: https://cgit.FreeBSD.org/ports/commit/?id=4c6e492cd331cfb1dadf2914988ab28ed4b9bdf8

commit 4c6e492cd331cfb1dadf2914988ab28ed4b9bdf8
Author:     Tatsuki Makino <tatsuki_makino@hotmail.com>
AuthorDate: 2021-06-01 07:02:20 +0000
Commit:     Li-Wen Hsu <lwhsu@FreeBSD.org>
CommitDate: 2021-06-01 07:19:46 +0000

    ports-mgmt/pkg_tree: Retrieve data from pkg info at one time

    The way it works is that it calls pkg info 3 times, so there is a
    possibility of losing consistency.

    The -r option added for displaying the "Required by" graph instead of
    the "Depends on" graph.

    Pass maintainership to submitter

    PR:             256214

 ports-mgmt/pkg_tree/Makefile                  |  2 +-
 ports-mgmt/pkg_tree/distinfo                  |  1 +
 ports-mgmt/pkg_tree/files/patch-pkg__tree     | 85 ++++++++++++---------------
 ports-mgmt/pkg_tree/files/patch-pkg__tree.pod | 17 +++++-
 4 files changed, 55 insertions(+), 50 deletions(-)
Comment 5 Li-Wen Hsu freebsd_committer freebsd_triage 2021-06-01 07:21:40 UTC
Pushed. The upstream development seems paused, I suggest you can consider fork and integrate the patches yourself.
Comment 6 commit-hook freebsd_committer freebsd_triage 2021-06-01 07:25:04 UTC
A commit in branch main references this bug:

URL: https://cgit.FreeBSD.org/ports/commit/?id=bbc328d0d7c974bb9bee8172952d270ac266ee8e

commit bbc328d0d7c974bb9bee8172952d270ac266ee8e
Author:     Li-Wen Hsu <lwhsu@FreeBSD.org>
AuthorDate: 2021-06-01 07:24:37 +0000
Commit:     Li-Wen Hsu <lwhsu@FreeBSD.org>
CommitDate: 2021-06-01 07:24:37 +0000

    ports-mgmt/pkg_tree: Bump PORTREVISION for 4c6e492cd331cfb1dadf2914988ab28ed4b9bdf8

    PR:             256214

 ports-mgmt/pkg_tree/Makefile | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)