You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by zh...@apache.org on 2020/03/13 06:49:34 UTC
[pulsar] 01/03: Fixed enum package not found (#6401)
This is an automated email from the ASF dual-hosted git repository.
zhaijia pushed a commit to branch branch-2.5
in repository https://gitbox.apache.org/repos/asf/pulsar.git
commit 71e24d95bf0f82d1023266ab6605088a6ff3bc13
Author: guangning <gu...@apache.org>
AuthorDate: Tue Feb 25 03:37:04 2020 +0800
Fixed enum package not found (#6401)
Fixes https://github.com/apache/pulsar/issues/6400
### Motivation
This problem is blocking the current test. 1.1.8 version of `enum34` seems to have some problems, and the problem reproduces:
Use pulsar latest code:
```
cd pulsar
mvn clean install -DskipTests
dokcer pull apachepulsar/pulsar-build:ubuntu-16.04
docker run -it -v $PWD:/pulsar --name pulsar apachepulsar/pulsar-build:ubuntu-16.04 /bin/bash
docker exec -it pulsar /bin/bash
cmake .
make -j4 && make install
cd python
python setup.py bdist_wheel
pip install dist/pulsar_client-*-linux_x86_64.whl
```
`pip show enum34`
```
Name: enum34
Version: 1.1.8
Summary: Python 3.4 Enum backported to 3.3, 3.2, 3.1, 2.7, 2.6, 2.5, and 2.4
Home-page: https://bitbucket.org/stoneleaf/enum34
Author: Ethan Furman
Author-email: ethan@stoneleaf.us
License: BSD License
Location: /usr/local/lib/python2.7/dist-packages
Requires:
Required-by: pulsar-client, grpcio
```
```
root@55e06c5c770f:/pulsar/pulsar-client-cpp/python# python
Python 2.7.12 (default, Oct 8 2019, 14:14:10)
[GCC 5.4.0 20160609] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> from enum import Enum, EnumMeta
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
ImportError: No module named enum
>>> exit()
```
There is no problem with using 1.1.9 in the test.
### Modifications
* Upgrade enum34 from 1.1.8 to 1.1.9
### Verifying this change
local test pass
(cherry picked from commit 2f4207753f1f1164b28d24d49c813557c15d2f63)
---
pulsar-client-cpp/python/setup.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/pulsar-client-cpp/python/setup.py b/pulsar-client-cpp/python/setup.py
index c16b9cf..97100df 100644
--- a/pulsar-client-cpp/python/setup.py
+++ b/pulsar-client-cpp/python/setup.py
@@ -76,7 +76,7 @@ dependencies = [
if PY2:
# Python 2 compat dependencies
- dependencies += ['enum34']
+ dependencies += ['enum34>=1.1.9']
setup(
name="pulsar-client",