Bug 267735 - graphics/inkscape: Add runtime dependency on www/py-requests to "Import Web Image"
Summary: graphics/inkscape: Add runtime dependency on www/py-requests to "Import Web I...
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Some People
Assignee: Dima Panov
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-11-13 05:48 UTC by freebsd
Modified: 2022-11-13 10:30 UTC (History)
3 users (show)

See Also:


Attachments
Add run time dependency on "www/py-requests" (735 bytes, patch)
2022-11-13 05:48 UTC, freebsd
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description freebsd 2022-11-13 05:48:03 UTC
Created attachment 238047 [details]
Add run time dependency on "www/py-requests"

On freebsd-quesitons@ list, lumiwa@dismail.de mentioned in message 20221112140934.157b9d6e@dismail.de ...

I am using Inkscape 1.2.1 on FreeBSD 13.1 - Release - p3 and it works.
The problem which I have is when going File - Import Web Image... than
I got:

Traceback (most recent call last):
  File "/usr/local/share/inkscape/extensions/other/clipart/import_web_image.py", line 47, in <module>
    from import_sources import RemoteSource, RemoteFile, RemotePage
  File "/usr/local/share/inkscape/extensions/other/clipart/import_sources.py", line 26, in <module>
    import requests
ModuleNotFoundError: No module named 'requests'


Either Inkscape ought to intercept the error & ask the user to install "requests" package so that it could "Import Web Image". Or, the FreeBSD port, graphics/inkscape, needs run time dependency on the package.

Attached (untested yet) patch adds the run time dependency on "www/py-requests" port; bumps the PORTREVISION to 9.
Comment 1 commit-hook freebsd_committer freebsd_triage 2022-11-13 10:24:27 UTC
A commit in branch main references this bug:

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

commit 1c65779922470d65c99bb6c7c113526eb84ce762
Author:     Dima Panov <fluffy@FreeBSD.org>
AuthorDate: 2022-11-13 10:20:32 +0000
Commit:     Dima Panov <fluffy@FreeBSD.org>
CommitDate: 2022-11-13 10:20:32 +0000

    graphics/inkscape: Add runtime dependency on www/py-requests to "Import Web Image"

    PR:             267735

 graphics/inkscape/Makefile | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
Comment 2 Dima Panov freebsd_committer freebsd_triage 2022-11-13 10:24:49 UTC
Shipped, thanks
Comment 3 commit-hook freebsd_committer freebsd_triage 2022-11-13 10:30:29 UTC
A commit in branch 2022Q4 references this bug:

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

commit 3fb31ee47011d5e07068e52fea8e9f560bea9679
Author:     Dima Panov <fluffy@FreeBSD.org>
AuthorDate: 2022-11-13 10:20:32 +0000
Commit:     Dima Panov <fluffy@FreeBSD.org>
CommitDate: 2022-11-13 10:27:18 +0000

    graphics/inkscape: Add runtime dependency on www/py-requests to "Import Web Image"

    PR:             267735
    (cherry picked from commit 1c65779922470d65c99bb6c7c113526eb84ce762)

 graphics/inkscape/Makefile | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)