[ 
https://issues.apache.org/jira/browse/IMPALA-8337?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16799854#comment-16799854
 ] 

ASF subversion and git services commented on IMPALA-8337:
---------------------------------------------------------

Commit eb95c912cb7e720caf66388942b4e94d95e95658 in impala's branch 
refs/heads/master from Fredy Wijaya
[ https://gitbox.apache.org/repos/asf?p=impala.git;h=eb95c91 ]

IMPALA-8337: Fix OrderedDict Python compatibility issue in Impala shell

IMPALA-8317 added a patch that uses OrderedDict, which is not available
on Python 2.6 or lower. The patch in IMPALA-8317 also requires a newer
version of configparser to handle duplicate keys, which is not available
in Python 2.6. This patch fixes the issue by using the OrderedDict from
ordereddict third-party library when running on Python 2.6 or lower and
using configparser from the backport.

Testing:
- Ran all E2E shell tests on Python 2.6 and 2.7

Change-Id: Iab1a33542319e9bb75d806bfd38b158995b54aa9
Reviewed-on: http://gerrit.cloudera.org:8080/12830
Reviewed-by: Impala Public Jenkins <[email protected]>
Tested-by: Impala Public Jenkins <[email protected]>


> Dataload fails due to ImportError: cannot import name OrderedDict from 
> impala-shell
> -----------------------------------------------------------------------------------
>
>                 Key: IMPALA-8337
>                 URL: https://issues.apache.org/jira/browse/IMPALA-8337
>             Project: IMPALA
>          Issue Type: Bug
>          Components: Clients
>    Affects Versions: Impala 3.3.0
>            Reporter: Joe McDonnell
>            Assignee: Fredy Wijaya
>            Priority: Blocker
>              Labels: broken-build
>             Fix For: Impala 3.3.0
>
>
> Dataload on centos 6 (with Python 2.6) fails when running "Caching test 
> tables":
> {noformat}
> 15:14:59 ImportError: cannot import name OrderedDict
> 15:14:59 Traceback (most recent call last):
> 15:14:59   File 
> "/data/jenkins/workspace/impala-cdh6.x-exhaustive-centos6/repos/Impala/shell/impala_shell.py",
>  line 42, in <module>
> 15:14:59     from option_parser import get_option_parser, get_config_from_file
> 15:14:59   File 
> "/data/jenkins/workspace/impala-cdh6.x-exhaustive-centos6/repos/Impala/shell/option_parser.py",
>  line 34, in <module>
> 15:14:59     from collections import OrderedDict{noformat}
> Unfortunately, OrderedDict was introduced in Python 2.7 according to this 
> table:
> [https://docs.python.org/2/library/collections.html]
> Python 2.6 strikes again.



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

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to