pkgsrc-Changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

CVS commit: pkgsrc/chat/tootstream



Module Name:    pkgsrc
Committed By:   nia
Date:           Tue Jul 31 16:15:33 UTC 2018

Modified Files:
        pkgsrc/chat/tootstream: Makefile distinfo
Added Files:
        pkgsrc/chat/tootstream/patches: patch-src_tootstream_toot.py

Log Message:
chat/tootstream: Add a patch removing the use of the 'async' keyword,
allowing it to be used with Python 3.7.


To generate a diff of this commit:
cvs rdiff -u -r1.2 -r1.3 pkgsrc/chat/tootstream/Makefile
cvs rdiff -u -r1.1 -r1.2 pkgsrc/chat/tootstream/distinfo
cvs rdiff -u -r0 -r1.1 \
    pkgsrc/chat/tootstream/patches/patch-src_tootstream_toot.py

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: pkgsrc/chat/tootstream/Makefile
diff -u pkgsrc/chat/tootstream/Makefile:1.2 pkgsrc/chat/tootstream/Makefile:1.3
--- pkgsrc/chat/tootstream/Makefile:1.2 Tue Jul 31 15:55:16 2018
+++ pkgsrc/chat/tootstream/Makefile     Tue Jul 31 16:15:33 2018
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.2 2018/07/31 15:55:16 nia Exp $
+# $NetBSD: Makefile,v 1.3 2018/07/31 16:15:33 nia Exp $
 
 DISTNAME=      tootstream-0.3.4
 CATEGORIES=    chat www
@@ -13,7 +13,6 @@ EXTRACT_USING=        bsdtar
 USE_LANGUAGES= # none
 
 PYTHON_VERSIONS_INCOMPATIBLE+= 27
-PYTHON_VERSIONS_INCOMPATIBLE+= 37 # mastodon.py
 
 DEPENDS+=      ${PYPKGPREFIX}-click-[0-9]*:../../devel/py-click
 DEPENDS+=      ${PYPKGPREFIX}-colored-[0-9]*:../../textproc/py-colored

Index: pkgsrc/chat/tootstream/distinfo
diff -u pkgsrc/chat/tootstream/distinfo:1.1 pkgsrc/chat/tootstream/distinfo:1.2
--- pkgsrc/chat/tootstream/distinfo:1.1 Thu Jul 26 20:24:48 2018
+++ pkgsrc/chat/tootstream/distinfo     Tue Jul 31 16:15:33 2018
@@ -1,6 +1,7 @@
-$NetBSD: distinfo,v 1.1 2018/07/26 20:24:48 nia Exp $
+$NetBSD: distinfo,v 1.2 2018/07/31 16:15:33 nia Exp $
 
 SHA1 (tootstream-0.3.4.tar.gz) = ebeb5d39aaa836a57c7e52a0b78678181afbd030
 RMD160 (tootstream-0.3.4.tar.gz) = 04e36ac3cbc6ab5ed4958b47bf90feb8ef32e519
 SHA512 (tootstream-0.3.4.tar.gz) = 261c8dc7bad6203c8df8781c2d9e4884f6e1e82228e32bf181b27d072541ecd4b2c29cfdd55643bf3eedd46b890c40e3570010974489a78e690bcbf6e398b6a2
 Size (tootstream-0.3.4.tar.gz) = 24627 bytes
+SHA1 (patch-src_tootstream_toot.py) = fb9c23183f6edee2f805f83d0b591dd4e4cc5956

Added files:

Index: pkgsrc/chat/tootstream/patches/patch-src_tootstream_toot.py
diff -u /dev/null pkgsrc/chat/tootstream/patches/patch-src_tootstream_toot.py:1.1
--- /dev/null   Tue Jul 31 16:15:33 2018
+++ pkgsrc/chat/tootstream/patches/patch-src_tootstream_toot.py Tue Jul 31 16:15:33 2018
@@ -0,0 +1,34 @@
+$NetBSD: patch-src_tootstream_toot.py,v 1.1 2018/07/31 16:15:33 nia Exp $
+
+'async' is a reserved keyword in Python 3.7.
+
+--- src/tootstream/toot.py.orig        2018-05-31 00:06:11.000000000 +0000
++++ src/tootstream/toot.py
+@@ -1279,11 +1279,11 @@ def stream(mastodon, rest):
+ 
+     try:
+         if rest == "home" or rest == "":
+-            handle = mastodon.stream_user(toot_listener, async=True)
++            handle = mastodon.stream_user(toot_listener, run_async=True)
+         elif rest == "fed" or rest == "public":
+-            handle = mastodon.stream_public(toot_listener, async=True)
++            handle = mastodon.stream_public(toot_listener, run_async=True)
+         elif rest == "local":
+-            handle = mastodon.stream_local(toot_listener, async=True)
++            handle = mastodon.stream_local(toot_listener, run_async=True)
+         elif rest.startswith('list'):
+             # Remove list from the rest string
+             items = rest.split('list ')
+@@ -1295,10 +1295,10 @@ def stream(mastodon, rest):
+                 cprint("List {} is not found".format(items[-1]), fg('red'))
+                 return
+ 
+-            handle = mastodon.stream_list(item, toot_listener, async=True)
++            handle = mastodon.stream_list(item, toot_listener, run_async=True)
+         elif rest.startswith('#'):
+             tag = rest[1:]
+-            handle = mastodon.stream_hashtag(tag, toot_listener, async=True)
++            handle = mastodon.stream_hashtag(tag, toot_listener, run_async=True)
+         else:
+             handle = None
+             print("Only 'home', 'fed', 'local', 'list', and '#hashtag' streams are supported.")



Home | Main Index | Thread Index | Old Index