spider-gazelle 3.0.6 → 3.0.7

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 49d9e0d9dee57cc23287f2155e6ebe81137e3f15
4
- data.tar.gz: 385f9ee18cdc18dab2b1de1f34b689968c617e8a
3
+ metadata.gz: '019fff0efc2bb105421dc8bc272a712359488538'
4
+ data.tar.gz: d73d90a4addbf4968ba678e68320bff312ff2503
5
5
  SHA512:
6
- metadata.gz: 932d6770571115d8e01d8e039725222929e7da5800be5d3ec9730505e97e1f8d153a76dfab4bbfb8ce8deea47993deb7d5a1797fabb7d869e5349c512108b6f7
7
- data.tar.gz: 3b33aa02ef5fad6b922ef577e22c3b209cd6f2db336f85d74c666f75cc38574dec6db3ae7b76ce2ab1bd50b7af33fdbdc8d26893943f0e1982e3bb3303fff102
6
+ metadata.gz: 57ec106d3f41d1569a0363fe0557c80b55702132f109dc3a4b8878cb9ae1d57a6e2fcef3b47ca55d3c64868765a92a5feb845f5a0df3dbcf0095acdc5fdbb4f5
7
+ data.tar.gz: deecf209798f9771d66dddfd84400185ae015d6332c0436e4ff818ed899dbc5d56113dbff0fe84e22bb573b94427cd5f811c484fdbb699eb69646401552a1ee7
@@ -5,7 +5,7 @@ require 'libuv'
5
5
  module SpiderGazelle
6
6
  class Logger
7
7
  include Singleton
8
- attr_reader :level, :thread, :stdout
8
+ attr_reader :level, :thread
9
9
  attr_accessor :formatter
10
10
 
11
11
 
@@ -29,7 +29,7 @@ module SpiderGazelle
29
29
 
30
30
 
31
31
  def self.log(data)
32
- Logger.instance.stdout.write(data)
32
+ Logger.instance.write(data)
33
33
  end
34
34
 
35
35
  def level=(level)
@@ -78,10 +78,14 @@ module SpiderGazelle
78
78
  def verbose(msg = nil)
79
79
  if @verbose
80
80
  msg = yield if block_given?
81
- @stdout.write ">> #{msg}\n"
81
+ @thread.schedule { @stdout.write ">> #{msg}\n" }
82
82
  end
83
83
  end
84
84
 
85
+ def write(msg)
86
+ @thread.schedule { @stdout.write msg }
87
+ end
88
+
85
89
  def print_error(e, msg = nil, trace = nil)
86
90
  message = String.new(msg || e.message)
87
91
  message << "\n#{e.message}" if msg
@@ -1,6 +1,6 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module SpiderGazelle
4
- VERSION = '3.0.6'
4
+ VERSION = '3.0.7'
5
5
  EXEC_NAME = 'sg'
6
6
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: spider-gazelle
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.0.6
4
+ version: 3.0.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Stephen von Takach