hashworks pushed to branch main at Arch Linux / Packaging / Packages / chatblade


Commits:
40bc92d8 by Justin Kromlinger at 2024-08-26T14:52:17+02:00
upgpkg: 0.6.3-1: Remove patch since it got merged upstream

- - - - -


3 changed files:

- .SRCINFO
- PKGBUILD
- − replace-distutils.patch


Changes:

=====================================
.SRCINFO
=====================================
@@ -1,7 +1,7 @@
 pkgbase = chatblade
        pkgdesc = A CLI Swiss Army Knife for ChatGPT
-       pkgver = 0.6.2
-       pkgrel = 2
+       pkgver = 0.6.3
+       pkgrel = 1
        url = https://github.com/npiv/chatblade
        arch = any
        license = GPL-3.0-only
@@ -16,9 +16,7 @@ pkgbase = chatblade
        depends = python-rich
        depends = python-tiktoken
        depends = python-yaml
-       source = 
chatblade-0.6.2.tar.gz::https://github.com/npiv/chatblade/archive/v0.6.2.tar.gz
-       source = replace-distutils.patch
-       sha256sums = 
90b34945758bbfe66f746a35dc38953836ab261e51f7059219d8e977ea047d56
-       sha256sums = 
b7cd4ef4f26d7481fa3a07a9cc512dc3858e50eee0fcfaec71e10e9e4518ee1b
+       source = 
chatblade-0.6.3.tar.gz::https://github.com/npiv/chatblade/archive/v0.6.3.tar.gz
+       sha256sums = 
5619a64277eab6d083a1f3965d79d4de80b972c104544af5f346fd656695604c
 
 pkgname = chatblade


=====================================
PKGBUILD
=====================================
@@ -3,8 +3,8 @@
 
 pkgname=chatblade
 pkgdesc="A CLI Swiss Army Knife for ChatGPT"
-pkgver=0.6.2
-pkgrel=2
+pkgver=0.6.3
+pkgrel=1
 arch=("any")
 url="https://github.com/npiv/chatblade";
 license=("GPL-3.0-only")
@@ -26,16 +26,13 @@ makedepends=(
 )
 source=(
        "${pkgname}-${pkgver}.tar.gz::${url}/archive/v${pkgver}.tar.gz"
-       "replace-distutils.patch"
 )
-sha256sums=('90b34945758bbfe66f746a35dc38953836ab261e51f7059219d8e977ea047d56'
-            'b7cd4ef4f26d7481fa3a07a9cc512dc3858e50eee0fcfaec71e10e9e4518ee1b')
+sha256sums=('5619a64277eab6d083a1f3965d79d4de80b972c104544af5f346fd656695604c')
 
 prepare() {
        cd "${srcdir}/${pkgname}-${pkgver}"
        # Use remote assets
        sed -i 's#<img src="assets/\([^"]*\)">#<img 
src="'${url}'/raw/v'${pkgver}'/assets/\1">#g' README.md
-       patch -Np1 -i "$srcdir/replace-distutils.patch"
 }
 
 build() {


=====================================
replace-distutils.patch deleted
=====================================
@@ -1,57 +0,0 @@
-commit a313da9261e5eca19a1bc207570bc9f55254d895
-Author: Carl Smedstad <[email protected]>
-Date:   Thu Aug 15 21:12:26 2024 +0200
-
-    Remove distutils usage for Python 3.12 compatibility
-    
-    The distutils module was removed from the standard library in Python
-    3.12 [0]. Replace it with importlib.metadata, introduced in Python 3.8
-    [1] and set that as the minimum required Python version.
-    
-    Without this change, the following error occurs on Python 3.12:
-    
-        $ chatblade --version
-        Traceback (most recent call last):
-          File "/usr/bin/chatblade", line 8, in <module>
-            sys.exit(main())
-                     ^^^^^^
-          File "/usr/lib/python3.12/site-packages/chatblade/__main__.py", line 
5, in main
-            cli.cli()
-          File "/usr/lib/python3.12/site-packages/chatblade/cli.py", line 155, 
in cli
-            version = dist.get_option_dict('metadata')['version'][1]
-                      ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^
-        KeyError: 'version'
-    
-    [0]: https://docs.python.org/3/whatsnew/3.12.html#distutils
-    [1]: https://docs.python.org/3/whatsnew/3.8.html#new-modules
-
-diff --git a/chatblade/cli.py b/chatblade/cli.py
-index d9e1a0a..14d9806 100644
---- a/chatblade/cli.py
-+++ b/chatblade/cli.py
-@@ -149,11 +149,8 @@ def cli():
-     if params.debug:
-         utils.CONSOLE_DEBUG_LOGGING = True
-     if params.version:
--        from distutils.dist import Distribution
--        dist = Distribution()
--        dist.parse_config_files()
--        version = dist.get_option_dict('metadata')['version'][1]
--        print(f"chatblade {version}")
-+        from importlib.metadata import version as get_version
-+        print(f"chatblade {get_version('chatblade')}")
-         exit(0)
-     try:
-         handle_input(query, params)
-diff --git a/setup.cfg b/setup.cfg
-index c8d84fe..67b8049 100644
---- a/setup.cfg
-+++ b/setup.cfg
-@@ -12,6 +12,7 @@ project_urls =
- 
- [options]
- packages = chatblade
-+python_requires = >=3.8
- install_requires =
-   openai~=1.35.15
-   tiktoken~=0.7.0



View it on GitLab: 
https://gitlab.archlinux.org/archlinux/packaging/packages/chatblade/-/commit/40bc92d8ee3f9610117459d219afd5de0cc1dd70

-- 
View it on GitLab: 
https://gitlab.archlinux.org/archlinux/packaging/packages/chatblade/-/commit/40bc92d8ee3f9610117459d219afd5de0cc1dd70
You're receiving this email because of your account on gitlab.archlinux.org.


Reply via email to