embulk 0.8.17 → 0.8.18

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: 702de940d5bf69898d3b0b27dca68a4b08bab5da
4
- data.tar.gz: fee576066971cf13a247adc902b0918849d73221
3
+ metadata.gz: d66941d7b936e34061caefed36090e468ecc370c
4
+ data.tar.gz: ae10e38c4b86ba5517469e00cf081a18fe77bc90
5
5
  SHA512:
6
- metadata.gz: 8b9c17ab94c8408b2d7f4679e2334b3b3755d2dd61a9caa872e33c2466547cd1b1aa5c89c17ec677430813a846fffaa1783046a40b8da888f6739171aa43e0ef
7
- data.tar.gz: 19164d94065a883efceef282860b8d6dd82783364552520f9ab75ce51a9e61055a86514884fd5fb77924a444a2da5ed2301ee89d6e765b2696cf2d9ab5a36a08
6
+ metadata.gz: c850b9132ed2672a7f30719b8062f84b39b0dd9c03c79e35a540cf8c76105a1374b783e0760c517d4b44a11ad6df5fb9fea91b2a0c466099494dc38cee8610d9
7
+ data.tar.gz: 1aa158cd445c3639ec9f8b5c3a3c7c8857b3d640d3bdb4365ba29813712c60d02492473375219dce389a25270aed35f9ac1d462785781fe9c8934c42b036111b
data/README.md CHANGED
@@ -20,7 +20,7 @@ Embulk is a Java application. Please make sure that [Java](http://www.oracle.com
20
20
  Following 4 commands install embulk to your home directory:
21
21
 
22
22
  ```sh
23
- curl --create-dirs -o ~/.embulk/bin/embulk -L "http://dl.embulk.org/embulk-latest.jar"
23
+ curl --create-dirs -o ~/.embulk/bin/embulk -L "https://dl.embulk.org/embulk-latest.jar"
24
24
  chmod +x ~/.embulk/bin/embulk
25
25
  echo 'export PATH="$HOME/.embulk/bin:$PATH"' >> ~/.bashrc
26
26
  source ~/.bashrc
data/build.gradle CHANGED
@@ -16,7 +16,7 @@ def release_projects = [project(":embulk-core"), project(":embulk-standards"), p
16
16
 
17
17
  allprojects {
18
18
  group = 'org.embulk'
19
- version = '0.8.17'
19
+ version = '0.8.18'
20
20
 
21
21
  ext {
22
22
  jrubyVersion = '9.1.5.0'
@@ -36,7 +36,7 @@ dependencies {
36
36
  compile 'org.apache.bval:bval-jsr303:0.5'
37
37
  compile 'io.airlift:slice:0.9'
38
38
  compile 'joda-time:joda-time:2.9.2'
39
- compile 'io.netty:netty-buffer:5.0.0.Alpha1'
39
+ compile 'io.netty:netty-buffer:4.0.44.Final'
40
40
  compile 'org.fusesource.jansi:jansi:1.11'
41
41
  compile 'org.msgpack:msgpack-core:0.8.11'
42
42
 
@@ -44,7 +44,7 @@ dependencies {
44
44
  compile 'com.ibm.icu:icu4j:54.1.1'
45
45
 
46
46
  gems 'rubygems:bundler:1.10.6'
47
- gems 'rubygems:msgpack:0.7.4'
47
+ gems 'rubygems:msgpack:1.1.0'
48
48
  gems 'rubygems:liquid:3.0.6'
49
49
  }
50
50
 
@@ -29,6 +29,7 @@ public class JsonParser
29
29
  {
30
30
  this.factory = new JsonFactory();
31
31
  factory.enable(Feature.ALLOW_UNQUOTED_CONTROL_CHARS);
32
+ factory.enable(Feature.ALLOW_NON_NUMERIC_NUMBERS);
32
33
  }
33
34
 
34
35
  public Stream open(InputStream in) throws IOException
@@ -4,6 +4,7 @@ Release Notes
4
4
  .. toctree::
5
5
  :maxdepth: 1
6
6
 
7
+ release/release-0.8.18
7
8
  release/release-0.8.17
8
9
  release/release-0.8.16
9
10
  release/release-0.8.15
@@ -4,7 +4,7 @@ Release 0.7.8
4
4
  General Changes
5
5
  ------------------
6
6
 
7
- * Added "mkbundle" subcommand. Its help messae shows how to use plugin blundes with examples.
7
+ * Added "mkbundle" subcommand. Its help message shows how to use plugin bundles with examples.
8
8
  * When a transaction throws an exception and cleanup code (close() method) also throws an exception, the exception of transaction was hidden. Now the exception of transaction is the primary error and exception of cleanup code is also included as a suppressed exception.
9
9
  * CSV parser plugin doesn't show lines twice with "Unexpected extra character" error.
10
10
 
@@ -0,0 +1,27 @@
1
+ Release 0.8.18
2
+ ==================================
3
+
4
+ General Changes
5
+ ------------------
6
+
7
+ * Fixed schema guess plugin and changed a condition to guess double type. [#554]
8
+
9
+ * Fixed guess plugin that doesn't not use last line in sample_lines for schema guess. [#551]
10
+
11
+ * Fixed Json parser plugin that enables to parse non numeric numbers as floating number values. [#548]
12
+
13
+ * Updated msgpack-ruby v1.1.0 (@hiroyuki-sato) [#539, #553]
14
+
15
+ * ChangeLog: https://github.com/msgpack/msgpack-ruby/blob/master/ChangeLog
16
+
17
+ * Downgraded netty-buffer 4.0.x for Embulk instead of 5.x. [#549]
18
+
19
+ * Minor fix:
20
+
21
+ * Fixed typos in v0.7.8 release note. (@yoshihara) [#552]
22
+
23
+ * Updated download link to be https. (@cosmok) [#544]
24
+
25
+ Release Date
26
+ ------------------
27
+ 2017-03-06
@@ -156,6 +156,15 @@ public class TestCsvGuessPlugin
156
156
  "test_int_single_column_guessed.yml");
157
157
  }
158
158
 
159
+ @Test
160
+ public void testDoubleSingleColumn()
161
+ throws Exception
162
+ {
163
+ assertGuessByResource(embulk,
164
+ "test_double_single_column_seed.yml", "test_double_single_column.csv",
165
+ "test_double_single_column_guessed.yml");
166
+ }
167
+
159
168
  @Test
160
169
  public void testStringSingleColumnWithHeader()
161
170
  throws Exception
@@ -0,0 +1,12 @@
1
+ 1.01
2
+ -1.01
3
+ +1.02
4
+ 10.001
5
+ 1.234e+5
6
+ 2.345e-6
7
+ NaN
8
+ +NaN
9
+ -NaN
10
+ Infinity
11
+ +Infinity
12
+ -Infinity
@@ -0,0 +1,12 @@
1
+ charset: UTF-8
2
+ newline: LF
3
+ type: csv
4
+ delimiter: ','
5
+ quote: '"'
6
+ escape: '"'
7
+ trim_if_not_quoted: false
8
+ skip_header_lines: 0
9
+ allow_extra_columns: false
10
+ allow_optional_columns: false
11
+ columns:
12
+ - {name: c0, type: double}
@@ -62,11 +62,12 @@ module Embulk::Guess
62
62
  return "long"
63
63
  end
64
64
 
65
- if str.include?('.')
66
- a, b = str.split(".", 2)
67
- if a.to_i.to_s == a && b.to_i.to_s == b
68
- return "double"
69
- end
65
+ # Introduce a regular expression to make better suggestion to double type. It refers to Guava 21.0's regular
66
+ # expression in Doubles#fpPattern() but, there're difference as following:
67
+ # * It intentionaly rejects float values when they start with "0" like "001.0", "010.01". "0.1" is ok.
68
+ # * It doesn't support hexadecimal representation. It could be improved more later.
69
+ if str =~ /^[+-]?(NaN|Infinity|([1-9]\d*|0)(\.\d+)([eE][+-]?\d+)?[fFdD]?)$/
70
+ return "double"
70
71
  end
71
72
 
72
73
  if str.empty?
@@ -114,7 +114,7 @@ module Embulk
114
114
  sample_lines << line
115
115
  end
116
116
  unless sample.end_with?(parser_task.getNewline.getString)
117
- sample_lines.pop if sample_lines.empty? # last line is partial
117
+ sample_lines.pop unless sample_lines.empty? # last line is partial
118
118
  end
119
119
  end
120
120
 
@@ -1,3 +1,3 @@
1
1
  module Embulk
2
- VERSION = '0.8.17'
2
+ VERSION = '0.8.18'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: embulk
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.8.17
4
+ version: 0.8.18
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sadayuki Furuhashi
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-02-18 00:00:00.000000000 Z
11
+ date: 2017-03-06 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: jruby-jars
@@ -108,9 +108,9 @@ files:
108
108
  - classpath/commons-beanutils-core-1.8.3.jar
109
109
  - classpath/commons-compress-1.10.jar
110
110
  - classpath/commons-lang3-3.1.jar
111
- - classpath/embulk-cli-0.8.17.jar
112
- - classpath/embulk-core-0.8.17.jar
113
- - classpath/embulk-standards-0.8.17.jar
111
+ - classpath/embulk-cli-0.8.18.jar
112
+ - classpath/embulk-core-0.8.18.jar
113
+ - classpath/embulk-standards-0.8.18.jar
114
114
  - classpath/guava-18.0.jar
115
115
  - classpath/guice-4.0.jar
116
116
  - classpath/guice-bootstrap-0.1.1.jar
@@ -127,8 +127,8 @@ files:
127
127
  - classpath/logback-classic-1.1.3.jar
128
128
  - classpath/logback-core-1.1.3.jar
129
129
  - classpath/msgpack-core-0.8.11.jar
130
- - classpath/netty-buffer-5.0.0.Alpha1.jar
131
- - classpath/netty-common-5.0.0.Alpha1.jar
130
+ - classpath/netty-buffer-4.0.44.Final.jar
131
+ - classpath/netty-common-4.0.44.Final.jar
132
132
  - classpath/slf4j-api-1.7.12.jar
133
133
  - classpath/slice-0.9.jar
134
134
  - classpath/snakeyaml-1.14.jar
@@ -432,6 +432,7 @@ files:
432
432
  - embulk-docs/src/release/release-0.8.15.rst
433
433
  - embulk-docs/src/release/release-0.8.16.rst
434
434
  - embulk-docs/src/release/release-0.8.17.rst
435
+ - embulk-docs/src/release/release-0.8.18.rst
435
436
  - embulk-docs/src/release/release-0.8.2.rst
436
437
  - embulk-docs/src/release/release-0.8.3.rst
437
438
  - embulk-docs/src/release/release-0.8.4.rst
@@ -505,6 +506,9 @@ files:
505
506
  - embulk-standards/src/test/resources/org/embulk/standards/guess/csv/test/test_backslash_escape.csv
506
507
  - embulk-standards/src/test/resources/org/embulk/standards/guess/csv/test/test_backslash_escape_guessed.yml
507
508
  - embulk-standards/src/test/resources/org/embulk/standards/guess/csv/test/test_backslash_escape_seed.yml
509
+ - embulk-standards/src/test/resources/org/embulk/standards/guess/csv/test/test_double_single_column.csv
510
+ - embulk-standards/src/test/resources/org/embulk/standards/guess/csv/test/test_double_single_column_guessed.yml
511
+ - embulk-standards/src/test/resources/org/embulk/standards/guess/csv/test/test_double_single_column_seed.yml
508
512
  - embulk-standards/src/test/resources/org/embulk/standards/guess/csv/test/test_int_single_column.csv
509
513
  - embulk-standards/src/test/resources/org/embulk/standards/guess/csv/test/test_int_single_column_guessed.yml
510
514
  - embulk-standards/src/test/resources/org/embulk/standards/guess/csv/test/test_int_single_column_seed.yml