pkgsrc-Changes archive

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

CVS commit: pkgsrc/net/mikutter



Module Name:    pkgsrc
Committed By:   tsutsui
Date:           Sat Jun 10 09:45:33 UTC 2017

Modified Files:
        pkgsrc/net/mikutter: Makefile distinfo
        pkgsrc/net/mikutter/patches:
            patch-core_plugin_photo__support_photo__support.rb
            patch-mikutter.rb
Added Files:
        pkgsrc/net/mikutter/patches: patch-Gemfile patch-core_boot_delayer.rb
            patch-core_lib_mikutwitter_api__shortcuts.rb
            patch-core_mui_gtk__inneruserlist.rb
            patch-core_mui_gtk__userlist.rb

Log Message:
Update mikutter to 3.5.8.

pkgsrc changes:

- pull upstream fix for redmine ticket #1031 (twitpic gzipped xfer)
- pull changes to use delayer-deferred 2.0.0 for redmine ticket
  #916 (extra follow/follower activities) and
  #995 (abnormal cpu load with delayer-deferred 1.1.0)

Upstream changes:

- ruby-gnome2 3.1.6
- subcommands that create spec files don't accept . as a pathname
- free memories on loading images earlier
- avoid to use deprecated Gdk::PixbufLoader


To generate a diff of this commit:
cvs rdiff -u -r1.141 -r1.142 pkgsrc/net/mikutter/Makefile
cvs rdiff -u -r1.126 -r1.127 pkgsrc/net/mikutter/distinfo
cvs rdiff -u -r0 -r1.1 pkgsrc/net/mikutter/patches/patch-Gemfile \
    pkgsrc/net/mikutter/patches/patch-core_boot_delayer.rb \
    pkgsrc/net/mikutter/patches/patch-core_lib_mikutwitter_api__shortcuts.rb \
    pkgsrc/net/mikutter/patches/patch-core_mui_gtk__inneruserlist.rb \
    pkgsrc/net/mikutter/patches/patch-core_mui_gtk__userlist.rb
cvs rdiff -u -r1.3 -r1.4 \
    pkgsrc/net/mikutter/patches/patch-core_plugin_photo__support_photo__support.rb \
    pkgsrc/net/mikutter/patches/patch-mikutter.rb

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

Modified files:

Index: pkgsrc/net/mikutter/Makefile
diff -u pkgsrc/net/mikutter/Makefile:1.141 pkgsrc/net/mikutter/Makefile:1.142
--- pkgsrc/net/mikutter/Makefile:1.141  Tue May 30 15:18:31 2017
+++ pkgsrc/net/mikutter/Makefile        Sat Jun 10 09:45:33 2017
@@ -1,9 +1,8 @@
-# $NetBSD: Makefile,v 1.141 2017/05/30 15:18:31 taca Exp $
+# $NetBSD: Makefile,v 1.142 2017/06/10 09:45:33 tsutsui Exp $
 #
 
-DISTNAME=      mikutter.3.5.7
+DISTNAME=      mikutter.3.5.8
 PKGNAME=       ${RUBY_PKGPREFIX}-${DISTNAME:S/./-/}
-PKGREVISION=   1
 CATEGORIES=    net
 MASTER_SITES=  http://mikutter.hachune.net/bin/
 
@@ -15,7 +14,7 @@ LICENSE=      mit AND cc-by-sa-v3.0
 .include "../../lang/ruby/rubyversion.mk"
 
 DEPENDS+=      ${RUBY_PKGPREFIX}-pluggaloid>=1.1.1:../../net/ruby-pluggaloid
-DEPENDS+=      ${RUBY_PKGPREFIX}-gnome2-gtk>=3.1.1:../../x11/ruby-gnome2-gtk
+DEPENDS+=      ${RUBY_PKGPREFIX}-gnome2-gtk>=3.1.6:../../x11/ruby-gnome2-gtk
 DEPENDS+=      ${RUBY_PKGPREFIX}-gettext>=3.0.1:../../devel/ruby-gettext
 DEPENDS+=      ${RUBY_PKGPREFIX}-oauth>=0.5.1:../../security/ruby-oauth
 DEPENDS+=      ${RUBY_PKGPREFIX}-addressable>=2.3:../../net/ruby-addressable
@@ -23,7 +22,7 @@ DEPENDS+=     ${RUBY_PKGPREFIX}-memoist-[0-9
 DEPENDS+=      ${RUBY_PKGPREFIX}-hmac>=0.4:../../security/ruby-hmac
 DEPENDS+=      ${RUBY_PKGPREFIX}-typed-array>=0.1:../../misc/ruby-typed-array
 DEPENDS+=      ${RUBY_PKGPREFIX}-delayer-[0-9]*:../../devel/ruby-delayer
-DEPENDS+=      ${RUBY_PKGPREFIX}-delayer-deferred>=1.0.4:../../devel/ruby-delayer-deferred
+DEPENDS+=      ${RUBY_PKGPREFIX}-delayer-deferred>=2.0.0:../../devel/ruby-delayer-deferred
 DEPENDS+=      ${RUBY_PKGPREFIX}-nokogiri-[0-9]*:../../textproc/ruby-nokogiri
 DEPENDS+=      ${RUBY_PKGPREFIX}-httpclient-[0-9]*:../../www/ruby-httpclient
 DEPENDS+=      ${RUBY_PKGPREFIX}-moneta>=0.7:../../databases/ruby-moneta

Index: pkgsrc/net/mikutter/distinfo
diff -u pkgsrc/net/mikutter/distinfo:1.126 pkgsrc/net/mikutter/distinfo:1.127
--- pkgsrc/net/mikutter/distinfo:1.126  Sat Apr  8 07:44:23 2017
+++ pkgsrc/net/mikutter/distinfo        Sat Jun 10 09:45:33 2017
@@ -1,10 +1,15 @@
-$NetBSD: distinfo,v 1.126 2017/04/08 07:44:23 tsutsui Exp $
+$NetBSD: distinfo,v 1.127 2017/06/10 09:45:33 tsutsui Exp $
 
-SHA1 (mikutter.3.5.7.tar.gz) = f42718db50e1810fa4891e8cb2b31e1f9109e1bf
-RMD160 (mikutter.3.5.7.tar.gz) = dd5a42818429fb2a951bedd00a1f973ce53a76e5
-SHA512 (mikutter.3.5.7.tar.gz) = 4b84a5681930e6b4463eff87555bdcae6d07ca7318d25906db13af519e7de47038e942aa861ed41c469725cdeb4a2ed254e791b7f7c68d50f5e7e2cae9fd5b10
-Size (mikutter.3.5.7.tar.gz) = 3743921 bytes
+SHA1 (mikutter.3.5.8.tar.gz) = 2d4a64632ebc9170013a3568264c136c639a4dc5
+RMD160 (mikutter.3.5.8.tar.gz) = e035e9d92acd37ba0ad20beb410197ba35e5a94c
+SHA512 (mikutter.3.5.8.tar.gz) = 7e526e995cfd20f1ecb47f0fd657a1036132068ba947de29b3a548c58f86c0a1f71c0134ebbf5e9bb945e2f885af4aff82ea5250fee5ba9f94c6faa3f6007367
+Size (mikutter.3.5.8.tar.gz) = 2733956 bytes
+SHA1 (patch-Gemfile) = 27cc7e1bea05a5a4205d4da89120da3519ddcee0
+SHA1 (patch-core_boot_delayer.rb) = 3070cd4966c509a2bb722d4baabcc1a7e7026b30
+SHA1 (patch-core_lib_mikutwitter_api__shortcuts.rb) = 36c96889e65ff312aa4e854509edfd0e75c59dd0
+SHA1 (patch-core_mui_gtk__inneruserlist.rb) = 552338b5029ca6236993b2c75f892a2b9fd64d2d
+SHA1 (patch-core_mui_gtk__userlist.rb) = fc7a2d850e7e9ab4d5716c2534f991afbda88a7e
 SHA1 (patch-core_plugin_libnotify_rnotify.rb) = 0bb5630f4411d11ad188c722fb1d14e2d6748d17
 SHA1 (patch-core_plugin_photo__support_Gemfile) = 754b96024904e2e2f55c83e88fd3c763eecf723c
-SHA1 (patch-core_plugin_photo__support_photo__support.rb) = d119209d4de835e6d47d85c8ca5209d1f199bd9e
-SHA1 (patch-mikutter.rb) = 637987302bfbf2903e59712df732e3bdc57768ee
+SHA1 (patch-core_plugin_photo__support_photo__support.rb) = 182135fc0b46035c343c746ddba091d71cdc81f4
+SHA1 (patch-mikutter.rb) = b82a38101b94d9f00a998965b02f05ee3947fc73

Index: pkgsrc/net/mikutter/patches/patch-core_plugin_photo__support_photo__support.rb
diff -u pkgsrc/net/mikutter/patches/patch-core_plugin_photo__support_photo__support.rb:1.3 pkgsrc/net/mikutter/patches/patch-core_plugin_photo__support_photo__support.rb:1.4
--- pkgsrc/net/mikutter/patches/patch-core_plugin_photo__support_photo__support.rb:1.3  Sat Jun  4 02:28:25 2016
+++ pkgsrc/net/mikutter/patches/patch-core_plugin_photo__support_photo__support.rb      Sat Jun 10 09:45:33 2017
@@ -1,8 +1,10 @@
-$NetBSD: patch-core_plugin_photo__support_photo__support.rb,v 1.3 2016/06/04 02:28:25 tsutsui Exp $
+$NetBSD: patch-core_plugin_photo__support_photo__support.rb,v 1.4 2017/06/10 09:45:33 tsutsui Exp $
 
 - temporary workaround to skip totorijp gems (sorry, @toshi_a)
+- pull fixes for upstream ticket #1031
+  https://dev.mikutter.hachune.net/issues/1031
 
---- core/plugin/photo_support/photo_support.rb.orig    2016-05-28 16:42:44.000000000 +0000
+--- core/plugin/photo_support/photo_support.rb.orig    2017-06-10 01:11:51.000000000 +0000
 +++ core/plugin/photo_support/photo_support.rb
 @@ -1,7 +1,7 @@
  # coding: utf-8
@@ -13,7 +15,18 @@ $NetBSD: patch-core_plugin_photo__suppor
  
  module Plugin::PhotoSupport
    INSTAGRAM_PATTERN = %r{\Ahttps?://(?:instagr\.am|(?:www\.)?instagram\.com)/p/([a-zA-Z0-9_\-]+)/}
-@@ -181,9 +181,14 @@ Plugin.create :photo_support do
+@@ -25,8 +25,9 @@ end
+ 
+ Plugin.create :photo_support do
+   # twitpic
+-  defimageopener('twitpic', %r<^http://twitpic\.com/[a-zA-Z0-9]+>) do |display_url|
++  defimageopener('twitpic', %r<^https?://twitpic\.com/[a-zA-Z0-9]+>) do |display_url|
+     connection = HTTPClient.new
++    connection.transparent_gzip_decompression = true
+     page = connection.get_content(display_url)
+     next nil if page.empty?
+     doc = Nokogiri::HTML(page)
+@@ -181,9 +182,14 @@ Plugin.create :photo_support do
  
    # totori.dip.jp
    defimageopener('totori.dip.jp', %r#\Ahttp://totori\.dip\.jp/?\Z#) do |display_url|
Index: pkgsrc/net/mikutter/patches/patch-mikutter.rb
diff -u pkgsrc/net/mikutter/patches/patch-mikutter.rb:1.3 pkgsrc/net/mikutter/patches/patch-mikutter.rb:1.4
--- pkgsrc/net/mikutter/patches/patch-mikutter.rb:1.3   Sat Apr  1 12:35:26 2017
+++ pkgsrc/net/mikutter/patches/patch-mikutter.rb       Sat Jun 10 09:45:33 2017
@@ -1,9 +1,11 @@
-$NetBSD: patch-mikutter.rb,v 1.3 2017/04/01 12:35:26 tsutsui Exp $
+$NetBSD: patch-mikutter.rb,v 1.4 2017/06/10 09:45:33 tsutsui Exp $
 
 - pkgsrc can handle location of ruby binary
- http://dev.mikutter.hachune.net/issues/889
+  https://dev.mikutter.hachune.net/issues/889
+- pull fix to use delayer-deferred 2.x for upstream ticket #995
+  https://dev.mikutter.hachune.net/issues/995
 
---- mikutter.rb.orig   2017-04-01 08:55:38.000000000 +0000
+--- mikutter.rb.orig   2017-06-10 01:11:51.000000000 +0000
 +++ mikutter.rb
 @@ -1,7 +1,5 @@
 -#!/bin/sh
@@ -14,3 +16,32 @@ $NetBSD: patch-mikutter.rb,v 1.3 2017/04
  =begin rdoc
  = mikutter - the moest twitter client
  Copyright (C) 2009-2017 Toshiaki Asai
+@@ -68,12 +66,12 @@ def boot!(profile)
+   rescue => exception
+     into_debug_mode(exception)
+     notice "catch exception `#{exception.class}'"
+-    raise exception
++    raise
+   rescue Exception => exception
+     notice "catch exception `#{exception.class}'"
+     exception = Mainloop.exception_filter(exception)
+     notice "=> `#{exception.class}'"
+-    raise exception end
++    raise end
+   exception = Mainloop.exception_filter(nil)
+   if exception
+     notice "raise mainloop exception `#{exception.class}'"
+@@ -82,6 +80,13 @@ def boot!(profile)
+ 
+ def error_handling!(exception)
+   notice "catch #{exception.class}"
++  if Mopt.debug && exception.respond_to?(:deferred) && exception.deferred
++    if command_exist?('dot')
++      notice "[[#{exception.deferred.graph_draw}]]"
++    else
++      notice exception.deferred.graph
++    end
++  end
+   File.open(File.expand_path(File.join(Environment::TMPDIR, 'crashed_exception')), 'w'){ |io| Marshal.dump(exception, io) }
+   raise exception end
+ 

Added files:

Index: pkgsrc/net/mikutter/patches/patch-Gemfile
diff -u /dev/null pkgsrc/net/mikutter/patches/patch-Gemfile:1.1
--- /dev/null   Sat Jun 10 09:45:33 2017
+++ pkgsrc/net/mikutter/patches/patch-Gemfile   Sat Jun 10 09:45:33 2017
@@ -0,0 +1,16 @@
+$NetBSD: patch-Gemfile,v 1.1 2017/06/10 09:45:33 tsutsui Exp $
+
+- use delayer-deferred 2.0.x for upstream ticket #995
+  https://dev.mikutter.hachune.net/issues/995
+
+--- Gemfile.orig       2017-06-10 02:41:13.000000000 +0000
++++ Gemfile
+@@ -16,7 +16,7 @@ group :default do
+   gem 'typed-array', '~> 0.1'
+   gem 'delayer', '~> 0.0'
+   gem 'pluggaloid', '>= 1.1.1', '< 2.0'
+-  gem 'delayer-deferred', '>= 1.0.4', '< 2.0'
++  gem 'delayer-deferred', '>= 2.0', '< 3.0'
+   gem 'twitter-text', '1.14.2'
+ end
+ 
Index: pkgsrc/net/mikutter/patches/patch-core_boot_delayer.rb
diff -u /dev/null pkgsrc/net/mikutter/patches/patch-core_boot_delayer.rb:1.1
--- /dev/null   Sat Jun 10 09:45:33 2017
+++ pkgsrc/net/mikutter/patches/patch-core_boot_delayer.rb      Sat Jun 10 09:45:33 2017
@@ -0,0 +1,39 @@
+$NetBSD: patch-core_boot_delayer.rb,v 1.1 2017/06/10 09:45:33 tsutsui Exp $
+
+- pull fix to use delayer-deferred 2.x for upstream ticket #995
+  https://dev.mikutter.hachune.net/issues/995
+
+--- core/boot/delayer.rb.orig  2017-06-10 01:11:51.000000000 +0000
++++ core/boot/delayer.rb
+@@ -13,7 +13,7 @@ Delayer.default = Delayer.generate_class
+ 
+ Deferred = Delayer::Deferred::Deferred
+ 
+-module Delayer::Deferred::Deferredable
++module Delayer::Deferred::Deferredable::Chainable
+   # エラーをキャッチして、うまい具合にmikutterに表示する。
+   # このあとにdeferredをくっつけることもできるが、基本的にはdeferredチェインの終了の時に使う。
+   # なお、terminateは受け取ったエラーを再度発生させるので、terminateでエラーを処理した後に特別なエラー処理を挟むこともできる
+@@ -23,7 +23,7 @@ module Delayer::Deferred::Deferredable
+   # ==== Return
+   # Deferred
+   def terminate(message = nil, &message_generator)
+-    self.trap{|exception|
++    defer = self.trap{|exception|
+       message = message_generator.call(exception) if message_generator
+       case exception
+       when MikuTwitter::RateLimitError
+@@ -35,6 +35,13 @@ module Delayer::Deferred::Deferredable
+       else
+         begin
+           notice exception
++          if Mopt.debug
++            if command_exist?('dot')
++              notice "[[#{defer.graph_draw}]]"
++            else
++              notice defer.graph
++            end
++          end
+           if(message)
+             if(exception.is_a?(Net::HTTPResponse))
+               Plugin.activity :error, "#{message} (#{exception.code} #{exception.body})"
Index: pkgsrc/net/mikutter/patches/patch-core_lib_mikutwitter_api__shortcuts.rb
diff -u /dev/null pkgsrc/net/mikutter/patches/patch-core_lib_mikutwitter_api__shortcuts.rb:1.1
--- /dev/null   Sat Jun 10 09:45:33 2017
+++ pkgsrc/net/mikutter/patches/patch-core_lib_mikutwitter_api__shortcuts.rb    Sat Jun 10 09:45:33 2017
@@ -0,0 +1,65 @@
+$NetBSD: patch-core_lib_mikutwitter_api__shortcuts.rb,v 1.1 2017/06/10 09:45:33 tsutsui Exp $
+
+- pull upstream fixes for ticket #916
+  https://dev.mikutter.hachune.net/issues/916
+
+--- core/lib/mikutwitter/api_shortcuts.rb.orig 2017-06-10 01:11:51.000000000 +0000
++++ core/lib/mikutwitter/api_shortcuts.rb
+@@ -52,10 +52,10 @@ module MikuTwitter::APIShortcuts
+   defcursorpager :followers_id, 'followers/ids', :paged_ids, :ids, id: :user_id
+ 
+   def followings(args = {})
+-    idlist2userlist(friends_id(RELATIONAL_DEFAULT.merge(args))) end
++    idlist2userlist(friends_id(RELATIONAL_DEFAULT.merge(args)), cache: args[:cache]) end
+ 
+   def followers(args = {})
+-    idlist2userlist(followers_id(RELATIONAL_DEFAULT.merge(args))) end
++    idlist2userlist(followers_id(RELATIONAL_DEFAULT.merge(args)), cache: args[:cache]) end
+ 
+   def direct_messages(args = {})
+     (self/:direct_messages).direct_messages({:count => 200}.merge(args)) end
+@@ -258,21 +258,30 @@ module MikuTwitter::APIShortcuts
+         cursor_pager(api, parser, key, args.merge(cursor: res[:next_cursor])).next{ |nex|
+           res[key] + nex } end } end
+ 
+-  def idlist2userlist(deferred)
+-    deferred.next{ |ids|
+-      promise = Deferred.new(true)
+-      Thread.new{
+-        begin
+-          promise.call(User.findbyid(ids))
+-        rescue Exception => e
+-          promise.fail(e) end }
+-      promise.next{ |users|
+-        if(users.size != ids.size)
+-          Deferred.when(*(ids - users.map{ |u| u[:id] }).each_slice(100).map{ |segment|
+-                          user_lookup(id: segment.join(',')).trap{ |e| warn e; [] } }).next{ |res|
+-            res.inject(users){ |a, b| a + b } }
++  def idlist2userlist(deferred, cache: :keep)
++    deferred.next do |ids|
++      detected = {}           # {id => User}
++      lookups = Set.new       # [id]
++      ids.each do |id|
++        user = User.findbyid(id, Retriever::DataSource::USE_LOCAL_ONLY)
++        if user.is_a? User
++          detected[id] = user
+         else
+-          users end } } end
++          lookups << id
++        end
++      end
++      defer = lookups.each_slice(100).map{|lookup_chunk|
++        user_lookup(id: lookup_chunk.join(','), cache: cache).next{|users|
++          users.each do |user|
++            detected[user.id] = user
++          end
++        }
++      }
++      Delayer::Deferred.when(*defer).next do
++        ids.map{|id| detected[id] }
++      end
++    end
++  end
+ 
+   # upload.twitter.comに画像等をアップロードし、
+   # アップロードしたファイルのmedia_idを返す。
Index: pkgsrc/net/mikutter/patches/patch-core_mui_gtk__inneruserlist.rb
diff -u /dev/null pkgsrc/net/mikutter/patches/patch-core_mui_gtk__inneruserlist.rb:1.1
--- /dev/null   Sat Jun 10 09:45:33 2017
+++ pkgsrc/net/mikutter/patches/patch-core_mui_gtk__inneruserlist.rb    Sat Jun 10 09:45:33 2017
@@ -0,0 +1,21 @@
+$NetBSD: patch-core_mui_gtk__inneruserlist.rb,v 1.1 2017/06/10 09:45:33 tsutsui Exp $
+
+- pull upstream fixes for ticket #916
+  https://dev.mikutter.hachune.net/issues/916
+
+--- core/mui/gtk_inneruserlist.rb.orig 2017-06-10 01:11:51.000000000 +0000
++++ core/mui/gtk_inneruserlist.rb
+@@ -32,10 +32,10 @@ class Gtk::InnerUserList < Gtk::TreeView
+     }.reject{|user|
+       exist_users.include?(user)
+     }.deach{|user|
++      break if destroyed?
+       iter = model.append
+-      iter[COL_ICON] = user.icon.load_pixbuf(width: 24, height: 24){|pixbuf|
+-        iter[COL_ICON] = pixbuf unless destroyed?
+-      }
++      # ここではCOL_ICONを埋めず、nilのままにしてアイコンを表示しない。
++      # アイコンは Gtk::UserList#emit_expose_user で、カラムが表示された時に初めて埋める
+       iter[COL_SCREEN_NAME] = user[:idname]
+       iter[COL_NAME] = user[:name]
+       iter[COL_USER] = user
Index: pkgsrc/net/mikutter/patches/patch-core_mui_gtk__userlist.rb
diff -u /dev/null pkgsrc/net/mikutter/patches/patch-core_mui_gtk__userlist.rb:1.1
--- /dev/null   Sat Jun 10 09:45:33 2017
+++ pkgsrc/net/mikutter/patches/patch-core_mui_gtk__userlist.rb Sat Jun 10 09:45:33 2017
@@ -0,0 +1,44 @@
+$NetBSD: patch-core_mui_gtk__userlist.rb,v 1.1 2017/06/10 09:45:33 tsutsui Exp $
+
+- pull upstream fixes for ticket #916
+  https://dev.mikutter.hachune.net/issues/916
+
+--- core/mui/gtk_userlist.rb.orig      2017-06-10 01:11:51.000000000 +0000
++++ core/mui/gtk_userlist.rb
+@@ -27,6 +27,10 @@ class Gtk::UserList < Gtk::EventBox
+     scrollbar = ::Gtk::VScrollbar.new(@listview.vadjustment)
+     add Gtk::HBox.new(false, 0).add(@listview).closeup(scrollbar)
+     @listview.ssc(:row_activated, &self.class.row_activated)
++    @listview.ssc(:expose_event){
++      emit_expose_user
++      false
++    }
+   end
+ 
+   def each
+@@ -68,5 +72,25 @@ class Gtk::UserList < Gtk::EventBox
+     @listview.reorder(user)
+     self end
+ 
++  private
++
++  def emit_expose_user
++    if @listview.visible_range
++      current, last = @listview.visible_range
++      Enumerator.new{|y|
++        while (current <=> last) < 1
++          y << @listview.model.get_iter(current)
++          break if not current.next!
++        end
++      }.reject{|iter|
++        iter[Gtk::InnerUserList::COL_ICON]
++      }.each do |iter|
++        iter[Gtk::InnerUserList::COL_ICON] = iter[Gtk::InnerUserList::COL_USER].icon.load_pixbuf(width: 24, height: 24){|pixbuf|
++          iter[Gtk::InnerUserList::COL_ICON] = pixbuf unless @listview.destroyed?
++        }
++      end
++    end
++  end
++
+ end
+ 



Home | Main Index | Thread Index | Old Index