[jira] [Commented] (HBASE-20910) Fix dev-support/submit-patch.py by opening file with 'b' mode

2019-10-24 Thread Ankit Singhal (Jira)


[ 
https://issues.apache.org/jira/browse/HBASE-20910?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16959289#comment-16959289
 ] 

Ankit Singhal commented on HBASE-20910:
---

It seems [~yuzhih...@gmail.com] already committed this but forgot to resolve it.
{code}
commit 2eee7a3f8bc9749c10e9d311a55696e66fd0b09d
Author: Ankit Singhal 
Date:   Fri Jul 20 15:23:38 2018 -0700

HBASE-20910 Fix dev-support/submit-patch.py by opening file with 'b' mode

Signed-off-by: tedyu 
Signed-off-by: Mike Drob 
{code}

> Fix dev-support/submit-patch.py by opening file with 'b' mode
> -
>
> Key: HBASE-20910
> URL: https://issues.apache.org/jira/browse/HBASE-20910
> Project: HBase
>  Issue Type: Bug
>  Components: scripts
>Reporter: Ankit Singhal
>Assignee: Ankit Singhal
>Priority: Major
> Attachments: HBASE-20910.patch, HBASE-20910_v1.patch
>
>
> {code:python}
> hbase$ python3.6 dev-support/submit-patch.py
> INFO:submit-patch: Active branch: master
> INFO:submit-patch: Using tracking branch as base branch
> INFO:submit-patch: Base branch: origin/master
> INFO:submit-patch: Patch directory: /Users/asinghal/patches
> INFO:submit-patch: Patch name: master.patch
> Traceback (most recent call last):
>  File "dev-support/submit-patch.py", line 253, in 
>  f.write(diff.encode('utf8'))
> TypeError: write() argument must be str, not bytes
> {code}
> [~te...@apache.org], FYI



--
This message was sent by Atlassian Jira
(v8.3.4#803005)


[jira] [Commented] (HBASE-20910) Fix dev-support/submit-patch.py by opening file with 'b' mode

2019-04-10 Thread Josh Elser (JIRA)


[ 
https://issues.apache.org/jira/browse/HBASE-20910?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16814773#comment-16814773
 ] 

Josh Elser commented on HBASE-20910:


Looks to me like someone has already made this change.

> Fix dev-support/submit-patch.py by opening file with 'b' mode
> -
>
> Key: HBASE-20910
> URL: https://issues.apache.org/jira/browse/HBASE-20910
> Project: HBase
>  Issue Type: Bug
>  Components: scripts
>Reporter: Ankit Singhal
>Assignee: Ankit Singhal
>Priority: Major
> Attachments: HBASE-20910.patch, HBASE-20910_v1.patch
>
>
> {code:python}
> hbase$ python3.6 dev-support/submit-patch.py
> INFO:submit-patch: Active branch: master
> INFO:submit-patch: Using tracking branch as base branch
> INFO:submit-patch: Base branch: origin/master
> INFO:submit-patch: Patch directory: /Users/asinghal/patches
> INFO:submit-patch: Patch name: master.patch
> Traceback (most recent call last):
>  File "dev-support/submit-patch.py", line 253, in 
>  f.write(diff.encode('utf8'))
> TypeError: write() argument must be str, not bytes
> {code}
> [~te...@apache.org], FYI



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (HBASE-20910) Fix dev-support/submit-patch.py by opening file with 'b' mode

2019-04-09 Thread Ankit Singhal (JIRA)


[ 
https://issues.apache.org/jira/browse/HBASE-20910?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16813825#comment-16813825
 ] 

Ankit Singhal commented on HBASE-20910:
---

Was just clearing my open JIRAs and found this. [~yuzhih...@gmail.com] 
/[~elserj] , can this be committed now.

> Fix dev-support/submit-patch.py by opening file with 'b' mode
> -
>
> Key: HBASE-20910
> URL: https://issues.apache.org/jira/browse/HBASE-20910
> Project: HBase
>  Issue Type: Bug
>  Components: scripts
>Reporter: Ankit Singhal
>Assignee: Ankit Singhal
>Priority: Major
> Attachments: HBASE-20910.patch, HBASE-20910_v1.patch
>
>
> {code:python}
> hbase$ python3.6 dev-support/submit-patch.py
> INFO:submit-patch: Active branch: master
> INFO:submit-patch: Using tracking branch as base branch
> INFO:submit-patch: Base branch: origin/master
> INFO:submit-patch: Patch directory: /Users/asinghal/patches
> INFO:submit-patch: Patch name: master.patch
> Traceback (most recent call last):
>  File "dev-support/submit-patch.py", line 253, in 
>  f.write(diff.encode('utf8'))
> TypeError: write() argument must be str, not bytes
> {code}
> [~te...@apache.org], FYI



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (HBASE-20910) Fix dev-support/submit-patch.py by opening file with 'b' mode

2018-07-21 Thread Hudson (JIRA)


[ 
https://issues.apache.org/jira/browse/HBASE-20910?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16551679#comment-16551679
 ] 

Hudson commented on HBASE-20910:


Results for branch master
[build #403 on 
builds.a.o|https://builds.apache.org/job/HBase%20Nightly/job/master/403/]: (x) 
*{color:red}-1 overall{color}*

details (if available):

(/) {color:green}+1 general checks{color}
-- For more information [see general 
report|https://builds.apache.org/job/HBase%20Nightly/job/master/403//General_Nightly_Build_Report/]




(x) {color:red}-1 jdk8 hadoop2 checks{color}
-- For more information [see jdk8 (hadoop2) 
report|https://builds.apache.org/job/HBase%20Nightly/job/master/403//JDK8_Nightly_Build_Report_(Hadoop2)/]


(x) {color:red}-1 jdk8 hadoop3 checks{color}
-- For more information [see jdk8 (hadoop3) 
report|https://builds.apache.org/job/HBase%20Nightly/job/master/403//JDK8_Nightly_Build_Report_(Hadoop3)/]


(/) {color:green}+1 source release artifact{color}
-- See build output for details.


(/) {color:green}+1 client integration test{color}


> Fix dev-support/submit-patch.py by opening file with 'b' mode
> -
>
> Key: HBASE-20910
> URL: https://issues.apache.org/jira/browse/HBASE-20910
> Project: HBase
>  Issue Type: Bug
>  Components: scripts
>Reporter: Ankit Singhal
>Assignee: Ankit Singhal
>Priority: Major
> Attachments: HBASE-20910.patch, HBASE-20910_v1.patch
>
>
> {code:python}
> hbase$ python3.6 dev-support/submit-patch.py
> INFO:submit-patch: Active branch: master
> INFO:submit-patch: Using tracking branch as base branch
> INFO:submit-patch: Base branch: origin/master
> INFO:submit-patch: Patch directory: /Users/asinghal/patches
> INFO:submit-patch: Patch name: master.patch
> Traceback (most recent call last):
>  File "dev-support/submit-patch.py", line 253, in 
>  f.write(diff.encode('utf8'))
> TypeError: write() argument must be str, not bytes
> {code}
> [~te...@apache.org], FYI



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (HBASE-20910) Fix dev-support/submit-patch.py by opening file with 'b' mode

2018-07-20 Thread Ted Yu (JIRA)


[ 
https://issues.apache.org/jira/browse/HBASE-20910?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16551381#comment-16551381
 ] 

Ted Yu commented on HBASE-20910:


Thanks for the patch, Ankit

Thanks for the review, Mike

> Fix dev-support/submit-patch.py by opening file with 'b' mode
> -
>
> Key: HBASE-20910
> URL: https://issues.apache.org/jira/browse/HBASE-20910
> Project: HBase
>  Issue Type: Bug
>  Components: scripts
>Reporter: Ankit Singhal
>Assignee: Ankit Singhal
>Priority: Major
> Attachments: HBASE-20910.patch, HBASE-20910_v1.patch
>
>
> {code:python}
> hbase$ python3.6 dev-support/submit-patch.py
> INFO:submit-patch: Active branch: master
> INFO:submit-patch: Using tracking branch as base branch
> INFO:submit-patch: Base branch: origin/master
> INFO:submit-patch: Patch directory: /Users/asinghal/patches
> INFO:submit-patch: Patch name: master.patch
> Traceback (most recent call last):
>  File "dev-support/submit-patch.py", line 253, in 
>  f.write(diff.encode('utf8'))
> TypeError: write() argument must be str, not bytes
> {code}
> [~te...@apache.org], FYI



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (HBASE-20910) Fix dev-support/submit-patch.py

2018-07-19 Thread Mike Drob (JIRA)


[ 
https://issues.apache.org/jira/browse/HBASE-20910?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16549882#comment-16549882
 ] 

Mike Drob commented on HBASE-20910:
---

Yea, I ran a few experiments locally and you're right that it's fine for 
python2.

+1 on the patch.

> Fix dev-support/submit-patch.py
> ---
>
> Key: HBASE-20910
> URL: https://issues.apache.org/jira/browse/HBASE-20910
> Project: HBase
>  Issue Type: Bug
>  Components: scripts
>Reporter: Ankit Singhal
>Assignee: Ankit Singhal
>Priority: Major
> Attachments: HBASE-20910.patch
>
>
> {code:python}
> hbase$ python3.6 dev-support/submit-patch.py
> INFO:submit-patch: Active branch: master
> INFO:submit-patch: Using tracking branch as base branch
> INFO:submit-patch: Base branch: origin/master
> INFO:submit-patch: Patch directory: /Users/asinghal/patches
> INFO:submit-patch: Patch name: master.patch
> Traceback (most recent call last):
>  File "dev-support/submit-patch.py", line 253, in 
>  f.write(diff.encode('utf8'))
> TypeError: write() argument must be str, not bytes
> {code}
> [~te...@apache.org], FYI



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (HBASE-20910) Fix dev-support/submit-patch.py

2018-07-19 Thread Ankit Singhal (JIRA)


[ 
https://issues.apache.org/jira/browse/HBASE-20910?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16549875#comment-16549875
 ] 

Ankit Singhal commented on HBASE-20910:
---

bq. I think this will break python2?

bq. In python2, git.format_patch returns an object of type unicode, and encode 
returns a str

[~mdrob], Python2 should be fine because it doesn't distinguish between str and 
binary. 

{code}
10082:hbase asinghal$ python2.7 dev-support/submit-patch.py
INFO:submit-patch: Active branch: master
INFO:submit-patch: Using tracking branch as base branch
INFO:submit-patch: Base branch: origin/master
INFO:submit-patch: Patch directory: /Users/asinghal/patches
INFO:submit-patch: Patch name: master.patch
{code}

 

> Fix dev-support/submit-patch.py
> ---
>
> Key: HBASE-20910
> URL: https://issues.apache.org/jira/browse/HBASE-20910
> Project: HBase
>  Issue Type: Bug
>  Components: scripts
>Reporter: Ankit Singhal
>Assignee: Ankit Singhal
>Priority: Major
> Attachments: HBASE-20910.patch
>
>
> {code:python}
> hbase$ python3.6 dev-support/submit-patch.py
> INFO:submit-patch: Active branch: master
> INFO:submit-patch: Using tracking branch as base branch
> INFO:submit-patch: Base branch: origin/master
> INFO:submit-patch: Patch directory: /Users/asinghal/patches
> INFO:submit-patch: Patch name: master.patch
> Traceback (most recent call last):
>  File "dev-support/submit-patch.py", line 253, in 
>  f.write(diff.encode('utf8'))
> TypeError: write() argument must be str, not bytes
> {code}
> [~te...@apache.org], FYI



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (HBASE-20910) Fix dev-support/submit-patch.py

2018-07-19 Thread Mike Drob (JIRA)


[ 
https://issues.apache.org/jira/browse/HBASE-20910?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16549818#comment-16549818
 ] 

Mike Drob commented on HBASE-20910:
---

I think this will break python2?

In python2, git.format_patch returns an object of type unicode, and encode 
returns a str
In python3, we get str and then bytes

Will think a bit how to do this correctly

> Fix dev-support/submit-patch.py
> ---
>
> Key: HBASE-20910
> URL: https://issues.apache.org/jira/browse/HBASE-20910
> Project: HBase
>  Issue Type: Bug
>  Components: scripts
>Reporter: Ankit Singhal
>Assignee: Ankit Singhal
>Priority: Major
> Attachments: HBASE-20910.patch
>
>
> {code:python}
> hbase$ python3.6 dev-support/submit-patch.py
> INFO:submit-patch: Active branch: master
> INFO:submit-patch: Using tracking branch as base branch
> INFO:submit-patch: Base branch: origin/master
> INFO:submit-patch: Patch directory: /Users/asinghal/patches
> INFO:submit-patch: Patch name: master.patch
> Traceback (most recent call last):
>  File "dev-support/submit-patch.py", line 253, in 
>  f.write(diff.encode('utf8'))
> TypeError: write() argument must be str, not bytes
> {code}
> [~te...@apache.org], FYI



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (HBASE-20910) Fix dev-support/submit-patch.py

2018-07-19 Thread Ted Yu (JIRA)


[ 
https://issues.apache.org/jira/browse/HBASE-20910?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16549804#comment-16549804
 ] 

Ted Yu commented on HBASE-20910:


[~appy] [~mdrob]:
Can you review ?

Thanks

> Fix dev-support/submit-patch.py
> ---
>
> Key: HBASE-20910
> URL: https://issues.apache.org/jira/browse/HBASE-20910
> Project: HBase
>  Issue Type: Bug
>  Components: scripts
>Reporter: Ankit Singhal
>Assignee: Ankit Singhal
>Priority: Major
> Attachments: HBASE-20910.patch
>
>
> {code:python}
> hbase$ python3.6 dev-support/submit-patch.py
> INFO:submit-patch: Active branch: master
> INFO:submit-patch: Using tracking branch as base branch
> INFO:submit-patch: Base branch: origin/master
> INFO:submit-patch: Patch directory: /Users/asinghal/patches
> INFO:submit-patch: Patch name: master.patch
> Traceback (most recent call last):
>  File "dev-support/submit-patch.py", line 253, in 
>  f.write(diff.encode('utf8'))
> TypeError: write() argument must be str, not bytes
> {code}
> [~te...@apache.org], FYI



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)