Re: Review Request 37081: Let __init__.py getting installed to $PREFIX/lib/pythonX.Y/site-packages/mesos.

2015-08-05 Thread Marco Massenzio

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/37081/#review94196
---

Ship it!


Ship It!

- Marco Massenzio


On Aug. 5, 2015, 4:21 a.m., haosdent huang wrote:
 
 ---
 This is an automatically generated e-mail. To reply, visit:
 https://reviews.apache.org/r/37081/
 ---
 
 (Updated Aug. 5, 2015, 4:21 a.m.)
 
 
 Review request for mesos, Kapil Arya and Marco Massenzio.
 
 
 Bugs: MESOS-2337
 https://issues.apache.org/jira/browse/MESOS-2337
 
 
 Repository: mesos
 
 
 Description
 ---
 
 Let __init__.py getting installed to 
 $PREFIX/lib/pythonX.Y/site-packages/mesos.
 
 
 Diffs
 -
 
   src/Makefile.am 54eaf205eecb6bf1a9a5c4b5ddad55f46ad635ec 
   src/python/interface/setup.py.in afcaf7ad6851eb36304a3be92c062cb6b21dbb03 
   src/python/setup.py.in 304c4bf87870fbaff2de0615cfd2263bb8a7ad3a 
 
 Diff: https://reviews.apache.org/r/37081/diff/
 
 
 Testing
 ---
 
 ## Test steps
 ### In CentOS 6.6
 ```
 ./bootstrap
 mkdir build
 cd build
 make -j4
 sudo make install
 ```
 
 And then execute
 
 ```
 export PYTHONPATH=/usr/local/lib/python2.6/site-packages
 python -c import mesos; from mesos import native; from mesos import 
 interface
 ```
 
 Check it could success or not.
 
 Also check the `__init__.py` file 
 ```
 cat /usr/local/lib/python2.6/site-packages/mesos/__init__.py
 ```
 
 
 Thanks,
 
 haosdent huang
 




Re: Review Request 37081: Let __init__.py getting installed to $PREFIX/lib/pythonX.Y/site-packages/mesos.

2015-08-05 Thread Marco Massenzio


 On Aug. 5, 2015, 6:05 a.m., Marco Massenzio wrote:
  Ship It!

Tested on Mac OSX 10.10 (Python 2.7) and Ubuntu 14.04: by `export 
PYTHONPATH=$MESOS_INSTALL_DIR/lib/python/site-packages` importing `mesos` and 
associated modules works.

Thanks for fixing this, @haosdent!


- Marco


---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/37081/#review94196
---


On Aug. 5, 2015, 4:21 a.m., haosdent huang wrote:
 
 ---
 This is an automatically generated e-mail. To reply, visit:
 https://reviews.apache.org/r/37081/
 ---
 
 (Updated Aug. 5, 2015, 4:21 a.m.)
 
 
 Review request for mesos, Kapil Arya and Marco Massenzio.
 
 
 Bugs: MESOS-2337
 https://issues.apache.org/jira/browse/MESOS-2337
 
 
 Repository: mesos
 
 
 Description
 ---
 
 Let __init__.py getting installed to 
 $PREFIX/lib/pythonX.Y/site-packages/mesos.
 
 
 Diffs
 -
 
   src/Makefile.am 54eaf205eecb6bf1a9a5c4b5ddad55f46ad635ec 
   src/python/interface/setup.py.in afcaf7ad6851eb36304a3be92c062cb6b21dbb03 
   src/python/setup.py.in 304c4bf87870fbaff2de0615cfd2263bb8a7ad3a 
 
 Diff: https://reviews.apache.org/r/37081/diff/
 
 
 Testing
 ---
 
 ## Test steps
 ### In CentOS 6.6
 ```
 ./bootstrap
 mkdir build
 cd build
 make -j4
 sudo make install
 ```
 
 And then execute
 
 ```
 export PYTHONPATH=/usr/local/lib/python2.6/site-packages
 python -c import mesos; from mesos import native; from mesos import 
 interface
 ```
 
 Check it could success or not.
 
 Also check the `__init__.py` file 
 ```
 cat /usr/local/lib/python2.6/site-packages/mesos/__init__.py
 ```
 
 
 Thanks,
 
 haosdent huang
 




Re: Review Request 37081: Let __init__.py getting installed to $PREFIX/lib/pythonX.Y/site-packages/mesos.

2015-08-05 Thread Bernd Mathiske

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/37081/#review94213
---

Ship it!


Ship It!

- Bernd Mathiske


On Aug. 4, 2015, 9:21 p.m., haosdent huang wrote:
 
 ---
 This is an automatically generated e-mail. To reply, visit:
 https://reviews.apache.org/r/37081/
 ---
 
 (Updated Aug. 4, 2015, 9:21 p.m.)
 
 
 Review request for mesos, Kapil Arya and Marco Massenzio.
 
 
 Bugs: MESOS-2337
 https://issues.apache.org/jira/browse/MESOS-2337
 
 
 Repository: mesos
 
 
 Description
 ---
 
 Let __init__.py getting installed to 
 $PREFIX/lib/pythonX.Y/site-packages/mesos.
 
 
 Diffs
 -
 
   src/Makefile.am 54eaf205eecb6bf1a9a5c4b5ddad55f46ad635ec 
   src/python/interface/setup.py.in afcaf7ad6851eb36304a3be92c062cb6b21dbb03 
   src/python/setup.py.in 304c4bf87870fbaff2de0615cfd2263bb8a7ad3a 
 
 Diff: https://reviews.apache.org/r/37081/diff/
 
 
 Testing
 ---
 
 ## Test steps
 ### In CentOS 6.6
 ```
 ./bootstrap
 mkdir build
 cd build
 make -j4
 sudo make install
 ```
 
 And then execute
 
 ```
 export PYTHONPATH=/usr/local/lib/python2.6/site-packages
 python -c import mesos; from mesos import native; from mesos import 
 interface
 ```
 
 Check it could success or not.
 
 Also check the `__init__.py` file 
 ```
 cat /usr/local/lib/python2.6/site-packages/mesos/__init__.py
 ```
 
 
 Thanks,
 
 haosdent huang
 




Re: Review Request 37081: Let __init__.py getting installed to $PREFIX/lib/pythonX.Y/site-packages/mesos.

2015-08-05 Thread Kapil Arya

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/37081/#review94214
---

Ship it!


LGTM module the file ordering.


src/Makefile.am (lines 1248 - 1250)
https://reviews.apache.org/r/37081/#comment148766

I think 
`python/dist/mesos-$(PACKAGE_VERSION)$(PYTHON_EGG_PUREPY_POSTFIX).egg` should 
come first in this list.



src/Makefile.am (lines 1253 - 1255)
https://reviews.apache.org/r/37081/#comment148767

same as above


- Kapil Arya


On Aug. 5, 2015, 5:45 a.m., haosdent huang wrote:
 
 ---
 This is an automatically generated e-mail. To reply, visit:
 https://reviews.apache.org/r/37081/
 ---
 
 (Updated Aug. 5, 2015, 5:45 a.m.)
 
 
 Review request for mesos, Bernd Mathiske, Kapil Arya, Marco Massenzio, and 
 Sebastien Pahl.
 
 
 Bugs: MESOS-2337
 https://issues.apache.org/jira/browse/MESOS-2337
 
 
 Repository: mesos
 
 
 Description
 ---
 
 Let __init__.py getting installed to 
 $PREFIX/lib/pythonX.Y/site-packages/mesos.
 
 
 Diffs
 -
 
   src/Makefile.am 54eaf205eecb6bf1a9a5c4b5ddad55f46ad635ec 
   src/python/interface/setup.py.in afcaf7ad6851eb36304a3be92c062cb6b21dbb03 
   src/python/setup.py.in 304c4bf87870fbaff2de0615cfd2263bb8a7ad3a 
 
 Diff: https://reviews.apache.org/r/37081/diff/
 
 
 Testing
 ---
 
 ## Test steps
 ### In CentOS 6.6
 ```
 ./bootstrap
 mkdir build
 cd build
 make -j4
 sudo make install
 ```
 
 And then execute
 
 ```
 export PYTHONPATH=/usr/local/lib/python2.6/site-packages
 python -c import mesos; from mesos import native; from mesos import 
 interface
 ```
 
 Check it could success or not.
 
 Also check the `__init__.py` file 
 ```
 cat /usr/local/lib/python2.6/site-packages/mesos/__init__.py
 ```
 
 
 Thanks,
 
 haosdent huang
 




Re: Review Request 37081: Let __init__.py getting installed to $PREFIX/lib/pythonX.Y/site-packages/mesos.

2015-08-05 Thread haosdent huang

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/37081/
---

(Updated Aug. 5, 2015, 9:54 a.m.)


Review request for mesos, Bernd Mathiske, Kapil Arya, Marco Massenzio, and 
Sebastien Pahl.


Bugs: MESOS-2337
https://issues.apache.org/jira/browse/MESOS-2337


Repository: mesos


Description
---

Let __init__.py getting installed to $PREFIX/lib/pythonX.Y/site-packages/mesos.


Diffs (updated)
-

  src/Makefile.am 54eaf205eecb6bf1a9a5c4b5ddad55f46ad635ec 
  src/python/interface/setup.py.in afcaf7ad6851eb36304a3be92c062cb6b21dbb03 
  src/python/setup.py.in 304c4bf87870fbaff2de0615cfd2263bb8a7ad3a 

Diff: https://reviews.apache.org/r/37081/diff/


Testing
---

## Test steps
### In CentOS 6.6
```
./bootstrap
mkdir build
cd build
make -j4
sudo make install
```

And then execute

```
export PYTHONPATH=/usr/local/lib/python2.6/site-packages
python -c import mesos; from mesos import native; from mesos import interface
```

Check it could success or not.

Also check the `__init__.py` file 
```
cat /usr/local/lib/python2.6/site-packages/mesos/__init__.py
```


Thanks,

haosdent huang



Re: Review Request 37081: Let __init__.py getting installed to $PREFIX/lib/pythonX.Y/site-packages/mesos.

2015-08-05 Thread Sebastien Pahl

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/37081/#review94215
---



src/python/interface/setup.py.in (line 27)
https://reviews.apache.org/r/37081/#comment148768

This seems weird to me. Why do you need to add the bindings for the google 
search engine?

https://pypi.python.org/pypi/google


- Sebastien Pahl


On Aug. 5, 2015, 9:54 a.m., haosdent huang wrote:
 
 ---
 This is an automatically generated e-mail. To reply, visit:
 https://reviews.apache.org/r/37081/
 ---
 
 (Updated Aug. 5, 2015, 9:54 a.m.)
 
 
 Review request for mesos, Bernd Mathiske, Kapil Arya, Marco Massenzio, and 
 Sebastien Pahl.
 
 
 Bugs: MESOS-2337
 https://issues.apache.org/jira/browse/MESOS-2337
 
 
 Repository: mesos
 
 
 Description
 ---
 
 Let __init__.py getting installed to 
 $PREFIX/lib/pythonX.Y/site-packages/mesos.
 
 
 Diffs
 -
 
   src/Makefile.am 54eaf205eecb6bf1a9a5c4b5ddad55f46ad635ec 
   src/python/interface/setup.py.in afcaf7ad6851eb36304a3be92c062cb6b21dbb03 
   src/python/setup.py.in 304c4bf87870fbaff2de0615cfd2263bb8a7ad3a 
 
 Diff: https://reviews.apache.org/r/37081/diff/
 
 
 Testing
 ---
 
 ## Test steps
 ### In CentOS 6.6
 ```
 ./bootstrap
 mkdir build
 cd build
 make -j4
 sudo make install
 ```
 
 And then execute
 
 ```
 export PYTHONPATH=/usr/local/lib/python2.6/site-packages
 python -c import mesos; from mesos import native; from mesos import 
 interface
 ```
 
 Check it could success or not.
 
 Also check the `__init__.py` file 
 ```
 cat /usr/local/lib/python2.6/site-packages/mesos/__init__.py
 ```
 
 
 Thanks,
 
 haosdent huang
 




Re: Review Request 37081: Let __init__.py getting installed to $PREFIX/lib/pythonX.Y/site-packages/mesos.

2015-08-05 Thread haosdent huang


 On Aug. 5, 2015, 9:57 a.m., Sebastien Pahl wrote:
  src/python/interface/setup.py.in, line 27
  https://reviews.apache.org/r/37081/diff/6/?file=1032437#file1032437line27
 
  This seems weird to me. Why do you need to add the bindings for the 
  google search engine?
  
  https://pypi.python.org/pypi/google

Yes, I think it is also a bit dirty here.

Because I try to fix this, could you see @marco comment above. I don't have 
other ideas to let it contains `__init__.py` under google, so I add this 
dependency.

```
ok - this almost worked :)
Are we missing an __init__.py in google?


$ ../configure --prefix=/Users/marco/mesos-inst/lib

then the usual make  make install - then:

$ find . |grep __init__
./lib/python/site-packages/google/protobuf/__init__.py
./lib/python/site-packages/google/protobuf/__init__.pyc
./lib/python/site-packages/google/protobuf/compiler/__init__.py
./lib/python/site-packages/google/protobuf/compiler/__init__.pyc
./lib/python/site-packages/google/protobuf/internal/__init__.py
./lib/python/site-packages/google/protobuf/internal/__init__.pyc
./lib/python/site-packages/google/protobuf/pyext/__init__.py
./lib/python/site-packages/google/protobuf/pyext/__init__.pyc
./lib/python/site-packages/mesos/__init__.py
./lib/python/site-packages/mesos/__init__.pyc
./lib/python/site-packages/mesos/interface/__init__.py
./lib/python/site-packages/mesos/interface/__init__.pyc
./lib/python/site-packages/mesos/native/__init__.py
./lib/python/site-packages/mesos/native/__init__.pyc
./libexec/mesos/python/mesos/__init__.py

as you can see, there are now the __init__.py files in the right places under 
mesos (if you do the same from master there's nothing in there - so, yay! :) 
but there is none under the google/ package:

[~/mesos-inst/lib] $ export PYTHONPATH=./lib/python/site-packages/

[~/mesos-inst/lib] $ python
Python 2.7.6 (default, Sep  9 2014, 15:04:36) 
[GCC 4.2.1 Compatible Apple LLVM 6.0 (clang-600.0.39)] on darwin
Type help, copyright, credits or license for more information.
 import mesos
 from mesos import native
Traceback (most recent call last):
  File stdin, line 1, in module
  File 
/Users/marco/mesos-inst/lib/lib/python/site-packages/mesos/native/__init__.py,
 line 17, in module
from ._mesos import MesosExecutorDriverImpl
  File 
/Users/marco/mesos-inst/lib/lib/python/site-packages/mesos/interface/mesos_pb2.py,
 line 4, in module
from google.protobuf.internal import enum_type_wrapper
ImportError: No module named google.protobuf.internal
 import google.protobuf.internal
Traceback (most recent call last):
  File stdin, line 1, in module
ImportError: No module named google.protobuf.internal

This was on a Mac OSX 10.10 (Yosemite) - about to test the same on an Ubuntu 
14.04 VM, brand new.
```


- haosdent


---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/37081/#review94215
---


On Aug. 5, 2015, 9:54 a.m., haosdent huang wrote:
 
 ---
 This is an automatically generated e-mail. To reply, visit:
 https://reviews.apache.org/r/37081/
 ---
 
 (Updated Aug. 5, 2015, 9:54 a.m.)
 
 
 Review request for mesos, Bernd Mathiske, Kapil Arya, Marco Massenzio, and 
 Sebastien Pahl.
 
 
 Bugs: MESOS-2337
 https://issues.apache.org/jira/browse/MESOS-2337
 
 
 Repository: mesos
 
 
 Description
 ---
 
 Let __init__.py getting installed to 
 $PREFIX/lib/pythonX.Y/site-packages/mesos.
 
 
 Diffs
 -
 
   src/Makefile.am 54eaf205eecb6bf1a9a5c4b5ddad55f46ad635ec 
   src/python/interface/setup.py.in afcaf7ad6851eb36304a3be92c062cb6b21dbb03 
   src/python/setup.py.in 304c4bf87870fbaff2de0615cfd2263bb8a7ad3a 
 
 Diff: https://reviews.apache.org/r/37081/diff/
 
 
 Testing
 ---
 
 ## Test steps
 ### In CentOS 6.6
 ```
 ./bootstrap
 mkdir build
 cd build
 make -j4
 sudo make install
 ```
 
 And then execute
 
 ```
 export PYTHONPATH=/usr/local/lib/python2.6/site-packages
 python -c import mesos; from mesos import native; from mesos import 
 interface
 ```
 
 Check it could success or not.
 
 Also check the `__init__.py` file 
 ```
 cat /usr/local/lib/python2.6/site-packages/mesos/__init__.py
 ```
 
 
 Thanks,
 
 haosdent huang
 




Re: Review Request 37081: Let __init__.py getting installed to $PREFIX/lib/pythonX.Y/site-packages/mesos.

2015-08-05 Thread haosdent huang


 On Aug. 5, 2015, 9:57 a.m., Sebastien Pahl wrote:
  src/python/interface/setup.py.in, line 27
  https://reviews.apache.org/r/37081/diff/6/?file=1032437#file1032437line27
 
  This seems weird to me. Why do you need to add the bindings for the 
  google search engine?
  
  https://pypi.python.org/pypi/google
 
 haosdent huang wrote:
 Yes, I think it is also a bit dirty here.
 
 Because I try to fix this, could you see @marco comment above. I don't 
 have other ideas to let it contains `__init__.py` under google, so I add this 
 dependency.
 
 ```
 ok - this almost worked :)
 Are we missing an __init__.py in google?
 
 
 $ ../configure --prefix=/Users/marco/mesos-inst/lib
 
 then the usual make  make install - then:
 
 $ find . |grep __init__
 ./lib/python/site-packages/google/protobuf/__init__.py
 ./lib/python/site-packages/google/protobuf/__init__.pyc
 ./lib/python/site-packages/google/protobuf/compiler/__init__.py
 ./lib/python/site-packages/google/protobuf/compiler/__init__.pyc
 ./lib/python/site-packages/google/protobuf/internal/__init__.py
 ./lib/python/site-packages/google/protobuf/internal/__init__.pyc
 ./lib/python/site-packages/google/protobuf/pyext/__init__.py
 ./lib/python/site-packages/google/protobuf/pyext/__init__.pyc
 ./lib/python/site-packages/mesos/__init__.py
 ./lib/python/site-packages/mesos/__init__.pyc
 ./lib/python/site-packages/mesos/interface/__init__.py
 ./lib/python/site-packages/mesos/interface/__init__.pyc
 ./lib/python/site-packages/mesos/native/__init__.py
 ./lib/python/site-packages/mesos/native/__init__.pyc
 ./libexec/mesos/python/mesos/__init__.py
 
 as you can see, there are now the __init__.py files in the right places 
 under mesos (if you do the same from master there's nothing in there - so, 
 yay! :) but there is none under the google/ package:
 
 [~/mesos-inst/lib] $ export PYTHONPATH=./lib/python/site-packages/
 
 [~/mesos-inst/lib] $ python
 Python 2.7.6 (default, Sep  9 2014, 15:04:36) 
 [GCC 4.2.1 Compatible Apple LLVM 6.0 (clang-600.0.39)] on darwin
 Type help, copyright, credits or license for more information.
  import mesos
  from mesos import native
 Traceback (most recent call last):
   File stdin, line 1, in module
   File 
 /Users/marco/mesos-inst/lib/lib/python/site-packages/mesos/native/__init__.py,
  line 17, in module
 from ._mesos import MesosExecutorDriverImpl
   File 
 /Users/marco/mesos-inst/lib/lib/python/site-packages/mesos/interface/mesos_pb2.py,
  line 4, in module
 from google.protobuf.internal import enum_type_wrapper
 ImportError: No module named google.protobuf.internal
  import google.protobuf.internal
 Traceback (most recent call last):
   File stdin, line 1, in module
 ImportError: No module named google.protobuf.internal
 
 This was on a Mac OSX 10.10 (Yosemite) - about to test the same on an 
 Ubuntu 14.04 VM, brand new.
 ```

For openstack, we could find `python-openstack-common` which contains 
`__init__.py` under [root 
namespace](http://packages.ubuntu.com/precise/i386/python-openstack-common/filelist),
 althrough openstack have multi submodules. But seems google don't provide 
package like this.


- haosdent


---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/37081/#review94215
---


On Aug. 5, 2015, 9:54 a.m., haosdent huang wrote:
 
 ---
 This is an automatically generated e-mail. To reply, visit:
 https://reviews.apache.org/r/37081/
 ---
 
 (Updated Aug. 5, 2015, 9:54 a.m.)
 
 
 Review request for mesos, Bernd Mathiske, Kapil Arya, Marco Massenzio, and 
 Sebastien Pahl.
 
 
 Bugs: MESOS-2337
 https://issues.apache.org/jira/browse/MESOS-2337
 
 
 Repository: mesos
 
 
 Description
 ---
 
 Let __init__.py getting installed to 
 $PREFIX/lib/pythonX.Y/site-packages/mesos.
 
 
 Diffs
 -
 
   src/Makefile.am 54eaf205eecb6bf1a9a5c4b5ddad55f46ad635ec 
   src/python/interface/setup.py.in afcaf7ad6851eb36304a3be92c062cb6b21dbb03 
   src/python/setup.py.in 304c4bf87870fbaff2de0615cfd2263bb8a7ad3a 
 
 Diff: https://reviews.apache.org/r/37081/diff/
 
 
 Testing
 ---
 
 ## Test steps
 ### In CentOS 6.6
 ```
 ./bootstrap
 mkdir build
 cd build
 make -j4
 sudo make install
 ```
 
 And then execute
 
 ```
 export PYTHONPATH=/usr/local/lib/python2.6/site-packages
 python -c import mesos; from mesos import native; from mesos import 
 interface
 ```
 
 Check it could success or not.
 
 Also check the `__init__.py` file 
 ```
 cat /usr/local/lib/python2.6/site-packages/mesos/__init__.py
 ```
 
 
 Thanks,
 
 haosdent huang
 




Re: Review Request 37081: Let __init__.py getting installed to $PREFIX/lib/pythonX.Y/site-packages/mesos.

2015-08-05 Thread haosdent huang

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/37081/
---

(Updated Aug. 5, 2015, 10:28 a.m.)


Review request for mesos, Bernd Mathiske, Kapil Arya, Marco Massenzio, and 
Sebastien Pahl.


Changes
---

Change dependency to google-common, which only contains `__init__.py`.


Bugs: MESOS-2337
https://issues.apache.org/jira/browse/MESOS-2337


Repository: mesos


Description
---

Let __init__.py getting installed to $PREFIX/lib/pythonX.Y/site-packages/mesos.


Diffs (updated)
-

  docs/mesos-c++-style-guide.md d8ad0acbb5f1484699f06e6748328a1ec0e7957f 
  src/Makefile.am 54eaf205eecb6bf1a9a5c4b5ddad55f46ad635ec 
  src/python/interface/setup.py.in afcaf7ad6851eb36304a3be92c062cb6b21dbb03 
  src/python/setup.py.in 304c4bf87870fbaff2de0615cfd2263bb8a7ad3a 

Diff: https://reviews.apache.org/r/37081/diff/


Testing
---

## Test steps
### In CentOS 6.6
```
./bootstrap
mkdir build
cd build
make -j4
sudo make install
```

And then execute

```
export PYTHONPATH=/usr/local/lib/python2.6/site-packages
python -c import mesos; from mesos import native; from mesos import interface
```

Check it could success or not.

Also check the `__init__.py` file 
```
cat /usr/local/lib/python2.6/site-packages/mesos/__init__.py
```


Thanks,

haosdent huang



Re: Review Request 37081: Let __init__.py getting installed to $PREFIX/lib/pythonX.Y/site-packages/mesos.

2015-08-05 Thread haosdent huang

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/37081/
---

(Updated Aug. 5, 2015, 10:29 a.m.)


Review request for mesos, Bernd Mathiske, Kapil Arya, Marco Massenzio, and 
Sebastien Pahl.


Bugs: MESOS-2337
https://issues.apache.org/jira/browse/MESOS-2337


Repository: mesos


Description
---

Let __init__.py getting installed to $PREFIX/lib/pythonX.Y/site-packages/mesos.


Diffs (updated)
-

  src/Makefile.am 54eaf205eecb6bf1a9a5c4b5ddad55f46ad635ec 
  src/python/interface/setup.py.in afcaf7ad6851eb36304a3be92c062cb6b21dbb03 
  src/python/setup.py.in 304c4bf87870fbaff2de0615cfd2263bb8a7ad3a 

Diff: https://reviews.apache.org/r/37081/diff/


Testing
---

## Test steps
### In CentOS 6.6
```
./bootstrap
mkdir build
cd build
make -j4
sudo make install
```

And then execute

```
export PYTHONPATH=/usr/local/lib/python2.6/site-packages
python -c import mesos; from mesos import native; from mesos import interface
```

Check it could success or not.

Also check the `__init__.py` file 
```
cat /usr/local/lib/python2.6/site-packages/mesos/__init__.py
```


Thanks,

haosdent huang



Re: Review Request 37081: Let __init__.py getting installed to $PREFIX/lib/pythonX.Y/site-packages/mesos.

2015-08-05 Thread haosdent huang


 On Aug. 5, 2015, 9:57 a.m., Sebastien Pahl wrote:
  src/python/interface/setup.py.in, line 27
  https://reviews.apache.org/r/37081/diff/6/?file=1032437#file1032437line27
 
  This seems weird to me. Why do you need to add the bindings for the 
  google search engine?
  
  https://pypi.python.org/pypi/google
 
 haosdent huang wrote:
 Yes, I think it is also a bit dirty here.
 
 Because I try to fix this, could you see @marco comment above. I don't 
 have other ideas to let it contains `__init__.py` under google, so I add this 
 dependency.
 
 ```
 ok - this almost worked :)
 Are we missing an __init__.py in google?
 
 
 $ ../configure --prefix=/Users/marco/mesos-inst/lib
 
 then the usual make  make install - then:
 
 $ find . |grep __init__
 ./lib/python/site-packages/google/protobuf/__init__.py
 ./lib/python/site-packages/google/protobuf/__init__.pyc
 ./lib/python/site-packages/google/protobuf/compiler/__init__.py
 ./lib/python/site-packages/google/protobuf/compiler/__init__.pyc
 ./lib/python/site-packages/google/protobuf/internal/__init__.py
 ./lib/python/site-packages/google/protobuf/internal/__init__.pyc
 ./lib/python/site-packages/google/protobuf/pyext/__init__.py
 ./lib/python/site-packages/google/protobuf/pyext/__init__.pyc
 ./lib/python/site-packages/mesos/__init__.py
 ./lib/python/site-packages/mesos/__init__.pyc
 ./lib/python/site-packages/mesos/interface/__init__.py
 ./lib/python/site-packages/mesos/interface/__init__.pyc
 ./lib/python/site-packages/mesos/native/__init__.py
 ./lib/python/site-packages/mesos/native/__init__.pyc
 ./libexec/mesos/python/mesos/__init__.py
 
 as you can see, there are now the __init__.py files in the right places 
 under mesos (if you do the same from master there's nothing in there - so, 
 yay! :) but there is none under the google/ package:
 
 [~/mesos-inst/lib] $ export PYTHONPATH=./lib/python/site-packages/
 
 [~/mesos-inst/lib] $ python
 Python 2.7.6 (default, Sep  9 2014, 15:04:36) 
 [GCC 4.2.1 Compatible Apple LLVM 6.0 (clang-600.0.39)] on darwin
 Type help, copyright, credits or license for more information.
  import mesos
  from mesos import native
 Traceback (most recent call last):
   File stdin, line 1, in module
   File 
 /Users/marco/mesos-inst/lib/lib/python/site-packages/mesos/native/__init__.py,
  line 17, in module
 from ._mesos import MesosExecutorDriverImpl
   File 
 /Users/marco/mesos-inst/lib/lib/python/site-packages/mesos/interface/mesos_pb2.py,
  line 4, in module
 from google.protobuf.internal import enum_type_wrapper
 ImportError: No module named google.protobuf.internal
  import google.protobuf.internal
 Traceback (most recent call last):
   File stdin, line 1, in module
 ImportError: No module named google.protobuf.internal
 
 This was on a Mac OSX 10.10 (Yosemite) - about to test the same on an 
 Ubuntu 14.04 VM, brand new.
 ```
 
 haosdent huang wrote:
 For openstack, we could find `python-openstack-common` which contains 
 `__init__.py` under [root 
 namespace](http://packages.ubuntu.com/precise/i386/python-openstack-common/filelist),
  althrough openstack have multi submodules. But seems google don't provide 
 package like this.

I upload a `__init__.py` to https://pypi.python.org/pypi/google-common, and 
change dependcy to this. But I think it is also tricky here.


- haosdent


---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/37081/#review94215
---


On Aug. 5, 2015, 10:29 a.m., haosdent huang wrote:
 
 ---
 This is an automatically generated e-mail. To reply, visit:
 https://reviews.apache.org/r/37081/
 ---
 
 (Updated Aug. 5, 2015, 10:29 a.m.)
 
 
 Review request for mesos, Bernd Mathiske, Kapil Arya, Marco Massenzio, and 
 Sebastien Pahl.
 
 
 Bugs: MESOS-2337
 https://issues.apache.org/jira/browse/MESOS-2337
 
 
 Repository: mesos
 
 
 Description
 ---
 
 Let __init__.py getting installed to 
 $PREFIX/lib/pythonX.Y/site-packages/mesos.
 
 
 Diffs
 -
 
   src/Makefile.am 54eaf205eecb6bf1a9a5c4b5ddad55f46ad635ec 
   src/python/interface/setup.py.in afcaf7ad6851eb36304a3be92c062cb6b21dbb03 
   src/python/setup.py.in 304c4bf87870fbaff2de0615cfd2263bb8a7ad3a 
 
 Diff: https://reviews.apache.org/r/37081/diff/
 
 
 Testing
 ---
 
 ## Test steps
 ### In CentOS 6.6
 ```
 ./bootstrap
 mkdir build
 cd build
 make -j4
 sudo make install
 ```
 
 And then execute
 
 ```
 export PYTHONPATH=/usr/local/lib/python2.6/site-packages
 python -c import mesos; from mesos import native; from mesos import 
 interface
 ```
 
 Check it 

Re: Review Request 37081: Let __init__.py getting installed to $PREFIX/lib/pythonX.Y/site-packages/mesos.

2015-08-05 Thread Sebastien Pahl


 On Aug. 5, 2015, 9:57 a.m., Sebastien Pahl wrote:
  src/python/interface/setup.py.in, line 27
  https://reviews.apache.org/r/37081/diff/6/?file=1032437#file1032437line27
 
  This seems weird to me. Why do you need to add the bindings for the 
  google search engine?
  
  https://pypi.python.org/pypi/google
 
 haosdent huang wrote:
 Yes, I think it is also a bit dirty here.
 
 Because I try to fix this, could you see @marco comment above. I don't 
 have other ideas to let it contains `__init__.py` under google, so I add this 
 dependency.
 
 ```
 ok - this almost worked :)
 Are we missing an __init__.py in google?
 
 
 $ ../configure --prefix=/Users/marco/mesos-inst/lib
 
 then the usual make  make install - then:
 
 $ find . |grep __init__
 ./lib/python/site-packages/google/protobuf/__init__.py
 ./lib/python/site-packages/google/protobuf/__init__.pyc
 ./lib/python/site-packages/google/protobuf/compiler/__init__.py
 ./lib/python/site-packages/google/protobuf/compiler/__init__.pyc
 ./lib/python/site-packages/google/protobuf/internal/__init__.py
 ./lib/python/site-packages/google/protobuf/internal/__init__.pyc
 ./lib/python/site-packages/google/protobuf/pyext/__init__.py
 ./lib/python/site-packages/google/protobuf/pyext/__init__.pyc
 ./lib/python/site-packages/mesos/__init__.py
 ./lib/python/site-packages/mesos/__init__.pyc
 ./lib/python/site-packages/mesos/interface/__init__.py
 ./lib/python/site-packages/mesos/interface/__init__.pyc
 ./lib/python/site-packages/mesos/native/__init__.py
 ./lib/python/site-packages/mesos/native/__init__.pyc
 ./libexec/mesos/python/mesos/__init__.py
 
 as you can see, there are now the __init__.py files in the right places 
 under mesos (if you do the same from master there's nothing in there - so, 
 yay! :) but there is none under the google/ package:
 
 [~/mesos-inst/lib] $ export PYTHONPATH=./lib/python/site-packages/
 
 [~/mesos-inst/lib] $ python
 Python 2.7.6 (default, Sep  9 2014, 15:04:36) 
 [GCC 4.2.1 Compatible Apple LLVM 6.0 (clang-600.0.39)] on darwin
 Type help, copyright, credits or license for more information.
  import mesos
  from mesos import native
 Traceback (most recent call last):
   File stdin, line 1, in module
   File 
 /Users/marco/mesos-inst/lib/lib/python/site-packages/mesos/native/__init__.py,
  line 17, in module
 from ._mesos import MesosExecutorDriverImpl
   File 
 /Users/marco/mesos-inst/lib/lib/python/site-packages/mesos/interface/mesos_pb2.py,
  line 4, in module
 from google.protobuf.internal import enum_type_wrapper
 ImportError: No module named google.protobuf.internal
  import google.protobuf.internal
 Traceback (most recent call last):
   File stdin, line 1, in module
 ImportError: No module named google.protobuf.internal
 
 This was on a Mac OSX 10.10 (Yosemite) - about to test the same on an 
 Ubuntu 14.04 VM, brand new.
 ```
 
 haosdent huang wrote:
 For openstack, we could find `python-openstack-common` which contains 
 `__init__.py` under [root 
 namespace](http://packages.ubuntu.com/precise/i386/python-openstack-common/filelist),
  althrough openstack have multi submodules. But seems google don't provide 
 package like this.
 
 haosdent huang wrote:
 I upload a `__init__.py` to https://pypi.python.org/pypi/google-common, 
 and change dependcy to this. But I think it is also tricky here.

I can't seem to reproduce your problem.

Here is what I get:
```
?  ~  mkvirtualenv -p python2.7 mesos
Running virtualenv with interpreter /usr/bin/python2.7
New python executable in mesos/bin/python2.7
Also creating executable in mesos/bin/python
Installing setuptools, pip, wheel...done.
?  ~  pip install protobuf   
Collecting protobuf
Requirement already satisfied (use --upgrade to upgrade): setuptools in 
./.virtualenvs/mesos/lib/python2.7/site-packages (from protobuf)
Installing collected packages: protobuf
Successfully installed protobuf-2.6.1
?  ~  python
Python 2.7.10 (default, May 26 2015, 04:16:29) 
[GCC 5.1.0] on linux2
Type help, copyright, credits or license for more information.
 import google.protobuf
 
?  ~  pip freeze
protobuf==2.6.1
wheel==0.24.0
?  ~  ls -l ./.virtualenvs/mesos/lib/python2.7/site-packages/google 
total 4
drwxr-xr-x 5 seb seb 4096 Aug  5 04:18 protobuf
```

No need for the google-common package


- Sebastien


---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/37081/#review94215
---


On Aug. 5, 2015, 10:29 a.m., haosdent huang wrote:
 
 ---
 This is an automatically generated e-mail. To reply, visit:
 https://reviews.apache.org/r/37081/
 

Re: Review Request 37081: Let __init__.py getting installed to $PREFIX/lib/pythonX.Y/site-packages/mesos.

2015-08-05 Thread Sebastien Pahl


 On Aug. 5, 2015, 9:57 a.m., Sebastien Pahl wrote:
  src/python/interface/setup.py.in, line 27
  https://reviews.apache.org/r/37081/diff/6/?file=1032437#file1032437line27
 
  This seems weird to me. Why do you need to add the bindings for the 
  google search engine?
  
  https://pypi.python.org/pypi/google
 
 haosdent huang wrote:
 Yes, I think it is also a bit dirty here.
 
 Because I try to fix this, could you see @marco comment above. I don't 
 have other ideas to let it contains `__init__.py` under google, so I add this 
 dependency.
 
 ```
 ok - this almost worked :)
 Are we missing an __init__.py in google?
 
 
 $ ../configure --prefix=/Users/marco/mesos-inst/lib
 
 then the usual make  make install - then:
 
 $ find . |grep __init__
 ./lib/python/site-packages/google/protobuf/__init__.py
 ./lib/python/site-packages/google/protobuf/__init__.pyc
 ./lib/python/site-packages/google/protobuf/compiler/__init__.py
 ./lib/python/site-packages/google/protobuf/compiler/__init__.pyc
 ./lib/python/site-packages/google/protobuf/internal/__init__.py
 ./lib/python/site-packages/google/protobuf/internal/__init__.pyc
 ./lib/python/site-packages/google/protobuf/pyext/__init__.py
 ./lib/python/site-packages/google/protobuf/pyext/__init__.pyc
 ./lib/python/site-packages/mesos/__init__.py
 ./lib/python/site-packages/mesos/__init__.pyc
 ./lib/python/site-packages/mesos/interface/__init__.py
 ./lib/python/site-packages/mesos/interface/__init__.pyc
 ./lib/python/site-packages/mesos/native/__init__.py
 ./lib/python/site-packages/mesos/native/__init__.pyc
 ./libexec/mesos/python/mesos/__init__.py
 
 as you can see, there are now the __init__.py files in the right places 
 under mesos (if you do the same from master there's nothing in there - so, 
 yay! :) but there is none under the google/ package:
 
 [~/mesos-inst/lib] $ export PYTHONPATH=./lib/python/site-packages/
 
 [~/mesos-inst/lib] $ python
 Python 2.7.6 (default, Sep  9 2014, 15:04:36) 
 [GCC 4.2.1 Compatible Apple LLVM 6.0 (clang-600.0.39)] on darwin
 Type help, copyright, credits or license for more information.
  import mesos
  from mesos import native
 Traceback (most recent call last):
   File stdin, line 1, in module
   File 
 /Users/marco/mesos-inst/lib/lib/python/site-packages/mesos/native/__init__.py,
  line 17, in module
 from ._mesos import MesosExecutorDriverImpl
   File 
 /Users/marco/mesos-inst/lib/lib/python/site-packages/mesos/interface/mesos_pb2.py,
  line 4, in module
 from google.protobuf.internal import enum_type_wrapper
 ImportError: No module named google.protobuf.internal
  import google.protobuf.internal
 Traceback (most recent call last):
   File stdin, line 1, in module
 ImportError: No module named google.protobuf.internal
 
 This was on a Mac OSX 10.10 (Yosemite) - about to test the same on an 
 Ubuntu 14.04 VM, brand new.
 ```
 
 haosdent huang wrote:
 For openstack, we could find `python-openstack-common` which contains 
 `__init__.py` under [root 
 namespace](http://packages.ubuntu.com/precise/i386/python-openstack-common/filelist),
  althrough openstack have multi submodules. But seems google don't provide 
 package like this.
 
 haosdent huang wrote:
 I upload a `__init__.py` to https://pypi.python.org/pypi/google-common, 
 and change dependcy to this. But I think it is also tricky here.
 
 Sebastien Pahl wrote:
 I can't seem to reproduce your problem.
 
 Here is what I get:
 ```
 ?  ~  mkvirtualenv -p python2.7 mesos
 Running virtualenv with interpreter /usr/bin/python2.7
 New python executable in mesos/bin/python2.7
 Also creating executable in mesos/bin/python
 Installing setuptools, pip, wheel...done.
 ?  ~  pip install protobuf   
 Collecting protobuf
 Requirement already satisfied (use --upgrade to upgrade): setuptools in 
 ./.virtualenvs/mesos/lib/python2.7/site-packages (from protobuf)
 Installing collected packages: protobuf
 Successfully installed protobuf-2.6.1
 ?  ~  python
 Python 2.7.10 (default, May 26 2015, 04:16:29) 
 [GCC 5.1.0] on linux2
 Type help, copyright, credits or license for more information.
  import google.protobuf
  
 ?  ~  pip freeze
 protobuf==2.6.1
 wheel==0.24.0
 ?  ~  ls -l ./.virtualenvs/mesos/lib/python2.7/site-packages/google 
 total 4
 drwxr-xr-x 5 seb seb 4096 Aug  5 04:18 protobuf
 ```
 
 No need for the google-common package
 
 haosdent huang wrote:
 If you already install protobuf, you could install this success. But if 
 you don't install protobuf before, You would get error. Because we 
 mesos.interface depends on protobuf. When install mesos.interface, it find 
 protobuf is not installed and it would try to install 

Re: Review Request 37081: Let __init__.py getting installed to $PREFIX/lib/pythonX.Y/site-packages/mesos.

2015-08-05 Thread haosdent huang


 On Aug. 5, 2015, 9:57 a.m., Sebastien Pahl wrote:
  src/python/interface/setup.py.in, line 27
  https://reviews.apache.org/r/37081/diff/6/?file=1032437#file1032437line27
 
  This seems weird to me. Why do you need to add the bindings for the 
  google search engine?
  
  https://pypi.python.org/pypi/google
 
 haosdent huang wrote:
 Yes, I think it is also a bit dirty here.
 
 Because I try to fix this, could you see @marco comment above. I don't 
 have other ideas to let it contains `__init__.py` under google, so I add this 
 dependency.
 
 ```
 ok - this almost worked :)
 Are we missing an __init__.py in google?
 
 
 $ ../configure --prefix=/Users/marco/mesos-inst/lib
 
 then the usual make  make install - then:
 
 $ find . |grep __init__
 ./lib/python/site-packages/google/protobuf/__init__.py
 ./lib/python/site-packages/google/protobuf/__init__.pyc
 ./lib/python/site-packages/google/protobuf/compiler/__init__.py
 ./lib/python/site-packages/google/protobuf/compiler/__init__.pyc
 ./lib/python/site-packages/google/protobuf/internal/__init__.py
 ./lib/python/site-packages/google/protobuf/internal/__init__.pyc
 ./lib/python/site-packages/google/protobuf/pyext/__init__.py
 ./lib/python/site-packages/google/protobuf/pyext/__init__.pyc
 ./lib/python/site-packages/mesos/__init__.py
 ./lib/python/site-packages/mesos/__init__.pyc
 ./lib/python/site-packages/mesos/interface/__init__.py
 ./lib/python/site-packages/mesos/interface/__init__.pyc
 ./lib/python/site-packages/mesos/native/__init__.py
 ./lib/python/site-packages/mesos/native/__init__.pyc
 ./libexec/mesos/python/mesos/__init__.py
 
 as you can see, there are now the __init__.py files in the right places 
 under mesos (if you do the same from master there's nothing in there - so, 
 yay! :) but there is none under the google/ package:
 
 [~/mesos-inst/lib] $ export PYTHONPATH=./lib/python/site-packages/
 
 [~/mesos-inst/lib] $ python
 Python 2.7.6 (default, Sep  9 2014, 15:04:36) 
 [GCC 4.2.1 Compatible Apple LLVM 6.0 (clang-600.0.39)] on darwin
 Type help, copyright, credits or license for more information.
  import mesos
  from mesos import native
 Traceback (most recent call last):
   File stdin, line 1, in module
   File 
 /Users/marco/mesos-inst/lib/lib/python/site-packages/mesos/native/__init__.py,
  line 17, in module
 from ._mesos import MesosExecutorDriverImpl
   File 
 /Users/marco/mesos-inst/lib/lib/python/site-packages/mesos/interface/mesos_pb2.py,
  line 4, in module
 from google.protobuf.internal import enum_type_wrapper
 ImportError: No module named google.protobuf.internal
  import google.protobuf.internal
 Traceback (most recent call last):
   File stdin, line 1, in module
 ImportError: No module named google.protobuf.internal
 
 This was on a Mac OSX 10.10 (Yosemite) - about to test the same on an 
 Ubuntu 14.04 VM, brand new.
 ```
 
 haosdent huang wrote:
 For openstack, we could find `python-openstack-common` which contains 
 `__init__.py` under [root 
 namespace](http://packages.ubuntu.com/precise/i386/python-openstack-common/filelist),
  althrough openstack have multi submodules. But seems google don't provide 
 package like this.
 
 haosdent huang wrote:
 I upload a `__init__.py` to https://pypi.python.org/pypi/google-common, 
 and change dependcy to this. But I think it is also tricky here.
 
 Sebastien Pahl wrote:
 I can't seem to reproduce your problem.
 
 Here is what I get:
 ```
 ?  ~  mkvirtualenv -p python2.7 mesos
 Running virtualenv with interpreter /usr/bin/python2.7
 New python executable in mesos/bin/python2.7
 Also creating executable in mesos/bin/python
 Installing setuptools, pip, wheel...done.
 ?  ~  pip install protobuf   
 Collecting protobuf
 Requirement already satisfied (use --upgrade to upgrade): setuptools in 
 ./.virtualenvs/mesos/lib/python2.7/site-packages (from protobuf)
 Installing collected packages: protobuf
 Successfully installed protobuf-2.6.1
 ?  ~  python
 Python 2.7.10 (default, May 26 2015, 04:16:29) 
 [GCC 5.1.0] on linux2
 Type help, copyright, credits or license for more information.
  import google.protobuf
  
 ?  ~  pip freeze
 protobuf==2.6.1
 wheel==0.24.0
 ?  ~  ls -l ./.virtualenvs/mesos/lib/python2.7/site-packages/google 
 total 4
 drwxr-xr-x 5 seb seb 4096 Aug  5 04:18 protobuf
 ```
 
 No need for the google-common package
 
 haosdent huang wrote:
 If you already install protobuf, you could install this success. But if 
 you don't install protobuf before, You would get error. Because we 
 mesos.interface depends on protobuf. When install mesos.interface, it find 
 protobuf is not installed and it would try to install 

Re: Review Request 37081: Let __init__.py getting installed to $PREFIX/lib/pythonX.Y/site-packages/mesos.

2015-08-05 Thread Sebastien Pahl

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/37081/#review94243
---

Ship it!


I would say ship it if everyone agrees that this now depends on this python 
package just as a hack to add an empty __init__.py to the google submodule for 
protobuf.

A better solution could be found later of course.

- Sebastien Pahl


On Aug. 5, 2015, 10:29 a.m., haosdent huang wrote:
 
 ---
 This is an automatically generated e-mail. To reply, visit:
 https://reviews.apache.org/r/37081/
 ---
 
 (Updated Aug. 5, 2015, 10:29 a.m.)
 
 
 Review request for mesos, Bernd Mathiske, Kapil Arya, Marco Massenzio, and 
 Sebastien Pahl.
 
 
 Bugs: MESOS-2337
 https://issues.apache.org/jira/browse/MESOS-2337
 
 
 Repository: mesos
 
 
 Description
 ---
 
 Let __init__.py getting installed to 
 $PREFIX/lib/pythonX.Y/site-packages/mesos.
 
 
 Diffs
 -
 
   src/Makefile.am 54eaf205eecb6bf1a9a5c4b5ddad55f46ad635ec 
   src/python/interface/setup.py.in afcaf7ad6851eb36304a3be92c062cb6b21dbb03 
   src/python/setup.py.in 304c4bf87870fbaff2de0615cfd2263bb8a7ad3a 
 
 Diff: https://reviews.apache.org/r/37081/diff/
 
 
 Testing
 ---
 
 ## Test steps
 ### In CentOS 6.6
 ```
 ./bootstrap
 mkdir build
 cd build
 make -j4
 sudo make install
 ```
 
 And then execute
 
 ```
 export PYTHONPATH=/usr/local/lib/python2.6/site-packages
 python -c import mesos; from mesos import native; from mesos import 
 interface
 ```
 
 Check it could success or not.
 
 Also check the `__init__.py` file 
 ```
 cat /usr/local/lib/python2.6/site-packages/mesos/__init__.py
 ```
 
 
 Thanks,
 
 haosdent huang
 




Re: Review Request 37081: Let __init__.py getting installed to $PREFIX/lib/pythonX.Y/site-packages/mesos.

2015-08-05 Thread Sebastien Pahl


 On Aug. 5, 2015, 1:47 p.m., Sebastien Pahl wrote:
  I would say ship it if everyone agrees that this now depends on this python 
  package just as a hack to add an empty __init__.py to the google submodule 
  for protobuf.
  
  A better solution could be found later of course.

https://pypi.python.org/pypi/google-common


- Sebastien


---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/37081/#review94243
---


On Aug. 5, 2015, 10:29 a.m., haosdent huang wrote:
 
 ---
 This is an automatically generated e-mail. To reply, visit:
 https://reviews.apache.org/r/37081/
 ---
 
 (Updated Aug. 5, 2015, 10:29 a.m.)
 
 
 Review request for mesos, Bernd Mathiske, Kapil Arya, Marco Massenzio, and 
 Sebastien Pahl.
 
 
 Bugs: MESOS-2337
 https://issues.apache.org/jira/browse/MESOS-2337
 
 
 Repository: mesos
 
 
 Description
 ---
 
 Let __init__.py getting installed to 
 $PREFIX/lib/pythonX.Y/site-packages/mesos.
 
 
 Diffs
 -
 
   src/Makefile.am 54eaf205eecb6bf1a9a5c4b5ddad55f46ad635ec 
   src/python/interface/setup.py.in afcaf7ad6851eb36304a3be92c062cb6b21dbb03 
   src/python/setup.py.in 304c4bf87870fbaff2de0615cfd2263bb8a7ad3a 
 
 Diff: https://reviews.apache.org/r/37081/diff/
 
 
 Testing
 ---
 
 ## Test steps
 ### In CentOS 6.6
 ```
 ./bootstrap
 mkdir build
 cd build
 make -j4
 sudo make install
 ```
 
 And then execute
 
 ```
 export PYTHONPATH=/usr/local/lib/python2.6/site-packages
 python -c import mesos; from mesos import native; from mesos import 
 interface
 ```
 
 Check it could success or not.
 
 Also check the `__init__.py` file 
 ```
 cat /usr/local/lib/python2.6/site-packages/mesos/__init__.py
 ```
 
 
 Thanks,
 
 haosdent huang
 




Re: Review Request 37081: Let __init__.py getting installed to $PREFIX/lib/pythonX.Y/site-packages/mesos.

2015-08-05 Thread haosdent huang


 On Aug. 5, 2015, 1:47 p.m., Sebastien Pahl wrote:
  I would say ship it if everyone agrees that this now depends on this python 
  package just as a hack to add an empty __init__.py to the google submodule 
  for protobuf.
  
  A better solution could be found later of course.
 
 Sebastien Pahl wrote:
 https://pypi.python.org/pypi/google-common

Yes, I think we need add a way to install dependency before build.


- haosdent


---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/37081/#review94243
---


On Aug. 5, 2015, 10:29 a.m., haosdent huang wrote:
 
 ---
 This is an automatically generated e-mail. To reply, visit:
 https://reviews.apache.org/r/37081/
 ---
 
 (Updated Aug. 5, 2015, 10:29 a.m.)
 
 
 Review request for mesos, Bernd Mathiske, Kapil Arya, Marco Massenzio, and 
 Sebastien Pahl.
 
 
 Bugs: MESOS-2337
 https://issues.apache.org/jira/browse/MESOS-2337
 
 
 Repository: mesos
 
 
 Description
 ---
 
 Let __init__.py getting installed to 
 $PREFIX/lib/pythonX.Y/site-packages/mesos.
 
 
 Diffs
 -
 
   src/Makefile.am 54eaf205eecb6bf1a9a5c4b5ddad55f46ad635ec 
   src/python/interface/setup.py.in afcaf7ad6851eb36304a3be92c062cb6b21dbb03 
   src/python/setup.py.in 304c4bf87870fbaff2de0615cfd2263bb8a7ad3a 
 
 Diff: https://reviews.apache.org/r/37081/diff/
 
 
 Testing
 ---
 
 ## Test steps
 ### In CentOS 6.6
 ```
 ./bootstrap
 mkdir build
 cd build
 make -j4
 sudo make install
 ```
 
 And then execute
 
 ```
 export PYTHONPATH=/usr/local/lib/python2.6/site-packages
 python -c import mesos; from mesos import native; from mesos import 
 interface
 ```
 
 Check it could success or not.
 
 Also check the `__init__.py` file 
 ```
 cat /usr/local/lib/python2.6/site-packages/mesos/__init__.py
 ```
 
 
 Thanks,
 
 haosdent huang
 




Re: Review Request 37081: Let __init__.py getting installed to $PREFIX/lib/pythonX.Y/site-packages/mesos.

2015-08-05 Thread Mesos ReviewBot

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/37081/#review94249
---


Patch looks great!

Reviews applied: [37081]

All tests passed.

- Mesos ReviewBot


On Aug. 5, 2015, 10:29 a.m., haosdent huang wrote:
 
 ---
 This is an automatically generated e-mail. To reply, visit:
 https://reviews.apache.org/r/37081/
 ---
 
 (Updated Aug. 5, 2015, 10:29 a.m.)
 
 
 Review request for mesos, Bernd Mathiske, Kapil Arya, Marco Massenzio, and 
 Sebastien Pahl.
 
 
 Bugs: MESOS-2337
 https://issues.apache.org/jira/browse/MESOS-2337
 
 
 Repository: mesos
 
 
 Description
 ---
 
 Let __init__.py getting installed to 
 $PREFIX/lib/pythonX.Y/site-packages/mesos.
 
 
 Diffs
 -
 
   src/Makefile.am 54eaf205eecb6bf1a9a5c4b5ddad55f46ad635ec 
   src/python/interface/setup.py.in afcaf7ad6851eb36304a3be92c062cb6b21dbb03 
   src/python/setup.py.in 304c4bf87870fbaff2de0615cfd2263bb8a7ad3a 
 
 Diff: https://reviews.apache.org/r/37081/diff/
 
 
 Testing
 ---
 
 ## Test steps
 ### In CentOS 6.6
 ```
 ./bootstrap
 mkdir build
 cd build
 make -j4
 sudo make install
 ```
 
 And then execute
 
 ```
 export PYTHONPATH=/usr/local/lib/python2.6/site-packages
 python -c import mesos; from mesos import native; from mesos import 
 interface
 ```
 
 Check it could success or not.
 
 Also check the `__init__.py` file 
 ```
 cat /usr/local/lib/python2.6/site-packages/mesos/__init__.py
 ```
 
 
 Thanks,
 
 haosdent huang
 




Re: Review Request 37081: Let __init__.py getting installed to $PREFIX/lib/pythonX.Y/site-packages/mesos.

2015-08-04 Thread haosdent huang

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/37081/
---

(Updated Aug. 5, 2015, 4:19 a.m.)


Review request for mesos, Kapil Arya and Marco Massenzio.


Changes
---

A bit dirty to work arround protobuf install to 
$PREFIX/lib/pythonX.Y/site-packages/


Bugs: MESOS-2337
https://issues.apache.org/jira/browse/MESOS-2337


Repository: mesos


Description
---

Let __init__.py getting installed to $PREFIX/lib/pythonX.Y/site-packages/mesos.


Diffs (updated)
-

  src/Makefile.am 54eaf205eecb6bf1a9a5c4b5ddad55f46ad635ec 
  src/master/http.cpp 76e70801925041f08bc94f0ca18c86f1a573b2b3 
  src/master/master.hpp e44174976aa64176916827bec4c911333c9a91db 
  src/master/master.cpp 5aa0a5410804fe16abd50b6953f1ffe46a019ecf 
  src/python/interface/setup.py.in afcaf7ad6851eb36304a3be92c062cb6b21dbb03 
  src/python/setup.py.in 304c4bf87870fbaff2de0615cfd2263bb8a7ad3a 
  src/slave/containerizer/isolators/filesystem/shared.cpp 
b30ab3fd0013045a2843fe1e8843cc120ce180c6 
  src/tests/http_api_tests.cpp 586d11288828fe9997e54f5dbd7d28c200e973f5 
  src/tests/mesos.hpp 20418d4fbd2f4ae35ee0c707472cbf37125883b0 
  src/tests/resources_tests.cpp 2ae93a9c8235e5e4643539d409df51c39c6d7e56 

Diff: https://reviews.apache.org/r/37081/diff/


Testing
---

## Test steps
### In CentOS 6.6
```
./bootstrap
mkdir build
cd build
make -j4
sudo make install
```

And then execute

```
export PYTHONPATH=/usr/local/lib/python2.6/site-packages
python -c import mesos; from mesos import native; from mesos import interface
```

Check it could success or not.

Also check the `__init__.py` file 
```
cat /usr/local/lib/python2.6/site-packages/mesos/__init__.py
```


Thanks,

haosdent huang



Re: Review Request 37081: Let __init__.py getting installed to $PREFIX/lib/pythonX.Y/site-packages/mesos.

2015-08-04 Thread haosdent huang

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/37081/
---

(Updated Aug. 5, 2015, 4:21 a.m.)


Review request for mesos, Kapil Arya and Marco Massenzio.


Bugs: MESOS-2337
https://issues.apache.org/jira/browse/MESOS-2337


Repository: mesos


Description
---

Let __init__.py getting installed to $PREFIX/lib/pythonX.Y/site-packages/mesos.


Diffs (updated)
-

  src/Makefile.am 54eaf205eecb6bf1a9a5c4b5ddad55f46ad635ec 
  src/python/interface/setup.py.in afcaf7ad6851eb36304a3be92c062cb6b21dbb03 
  src/python/setup.py.in 304c4bf87870fbaff2de0615cfd2263bb8a7ad3a 

Diff: https://reviews.apache.org/r/37081/diff/


Testing
---

## Test steps
### In CentOS 6.6
```
./bootstrap
mkdir build
cd build
make -j4
sudo make install
```

And then execute

```
export PYTHONPATH=/usr/local/lib/python2.6/site-packages
python -c import mesos; from mesos import native; from mesos import interface
```

Check it could success or not.

Also check the `__init__.py` file 
```
cat /usr/local/lib/python2.6/site-packages/mesos/__init__.py
```


Thanks,

haosdent huang



Re: Review Request 37081: Let __init__.py getting installed to $PREFIX/lib/pythonX.Y/site-packages/mesos.

2015-08-04 Thread haosdent huang


 On Aug. 4, 2015, 5:17 p.m., Marco Massenzio wrote:
  Can you please define how did you test that this works in the 'tests' 
  section?
  I can try this out on Ubuntu 14.04 (and OSX) given the steps to reproduce 
  the issue, and then applying the patch.
  
  Once we verify that it works on enough platforms, we can ship it.
  
  Thanks!
 
 haosdent huang wrote:
 Hi, @marco. Thank you for your help.
 
 Marco Massenzio wrote:
 haha thank *you* for fixing this!
 I'm testing it out currently on my Mac - will try it out on a Ubuntu VM 
 or my home box later this evening.
 Will keep you posted.
 
 Thanks for repro steps!
 
 Marco Massenzio wrote:
 ok - this *almost* worked :)
 Are we missing an `__init__.py` in `google`?
 
 ```
 $ ../configure --prefix=/Users/marco/mesos-inst/lib
 ```
 then the usual `make  make install` - then:
 ```
 $ find . |grep __init__
 ./lib/python/site-packages/google/protobuf/__init__.py
 ./lib/python/site-packages/google/protobuf/__init__.pyc
 ./lib/python/site-packages/google/protobuf/compiler/__init__.py
 ./lib/python/site-packages/google/protobuf/compiler/__init__.pyc
 ./lib/python/site-packages/google/protobuf/internal/__init__.py
 ./lib/python/site-packages/google/protobuf/internal/__init__.pyc
 ./lib/python/site-packages/google/protobuf/pyext/__init__.py
 ./lib/python/site-packages/google/protobuf/pyext/__init__.pyc
 ./lib/python/site-packages/mesos/__init__.py
 ./lib/python/site-packages/mesos/__init__.pyc
 ./lib/python/site-packages/mesos/interface/__init__.py
 ./lib/python/site-packages/mesos/interface/__init__.pyc
 ./lib/python/site-packages/mesos/native/__init__.py
 ./lib/python/site-packages/mesos/native/__init__.pyc
 ./libexec/mesos/python/mesos/__init__.py
 ```
 as you can see, there are now the `__init__.py` files in the right places 
 under `mesos` (if you do the same from `master` there's nothing in there - 
 so, yay! :) but there is none under the `google/` package:
 ```
 [~/mesos-inst/lib] $ export PYTHONPATH=./lib/python/site-packages/
 
 [~/mesos-inst/lib] $ python
 Python 2.7.6 (default, Sep  9 2014, 15:04:36) 
 [GCC 4.2.1 Compatible Apple LLVM 6.0 (clang-600.0.39)] on darwin
 Type help, copyright, credits or license for more information.
  import mesos
  from mesos import native
 Traceback (most recent call last):
   File stdin, line 1, in module
   File 
 /Users/marco/mesos-inst/lib/lib/python/site-packages/mesos/native/__init__.py,
  line 17, in module
 from ._mesos import MesosExecutorDriverImpl
   File 
 /Users/marco/mesos-inst/lib/lib/python/site-packages/mesos/interface/mesos_pb2.py,
  line 4, in module
 from google.protobuf.internal import enum_type_wrapper
 ImportError: No module named google.protobuf.internal
  import google.protobuf.internal
 Traceback (most recent call last):
   File stdin, line 1, in module
 ImportError: No module named google.protobuf.internal
 ```
 This was on a Mac OSX 10.10 (Yosemite) - about to test the same on an 
 Ubuntu 14.04 VM, brand new.
 
 haosdent huang wrote:
 Oh, because I already have pip install protobuf in my machine. So don't 
 have this problem, let me check again.

Hi, @marco, Could you try again? The problem of protobuf is if you never pip 
install protobuf before, the protobuf would install to 
$PREFIX/lib/pythonX.Y/site-packages. It cause this problem because google is 
namespace package. I add a new dependency to workarround this.


- haosdent


---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/37081/#review94084
---


On Aug. 5, 2015, 4:21 a.m., haosdent huang wrote:
 
 ---
 This is an automatically generated e-mail. To reply, visit:
 https://reviews.apache.org/r/37081/
 ---
 
 (Updated Aug. 5, 2015, 4:21 a.m.)
 
 
 Review request for mesos, Kapil Arya and Marco Massenzio.
 
 
 Bugs: MESOS-2337
 https://issues.apache.org/jira/browse/MESOS-2337
 
 
 Repository: mesos
 
 
 Description
 ---
 
 Let __init__.py getting installed to 
 $PREFIX/lib/pythonX.Y/site-packages/mesos.
 
 
 Diffs
 -
 
   src/Makefile.am 54eaf205eecb6bf1a9a5c4b5ddad55f46ad635ec 
   src/python/interface/setup.py.in afcaf7ad6851eb36304a3be92c062cb6b21dbb03 
   src/python/setup.py.in 304c4bf87870fbaff2de0615cfd2263bb8a7ad3a 
 
 Diff: https://reviews.apache.org/r/37081/diff/
 
 
 Testing
 ---
 
 ## Test steps
 ### In CentOS 6.6
 ```
 ./bootstrap
 mkdir build
 cd build
 make -j4
 sudo make install
 ```
 
 And then execute
 
 ```
 export PYTHONPATH=/usr/local/lib/python2.6/site-packages
 python -c import mesos; from mesos import native; from 

Re: Review Request 37081: Let __init__.py getting installed to $PREFIX/lib/pythonX.Y/site-packages/mesos.

2015-08-04 Thread Marco Massenzio

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/37081/#review94191
---


did you forget to rebase?

- Marco Massenzio


On Aug. 5, 2015, 4:21 a.m., haosdent huang wrote:
 
 ---
 This is an automatically generated e-mail. To reply, visit:
 https://reviews.apache.org/r/37081/
 ---
 
 (Updated Aug. 5, 2015, 4:21 a.m.)
 
 
 Review request for mesos, Kapil Arya and Marco Massenzio.
 
 
 Bugs: MESOS-2337
 https://issues.apache.org/jira/browse/MESOS-2337
 
 
 Repository: mesos
 
 
 Description
 ---
 
 Let __init__.py getting installed to 
 $PREFIX/lib/pythonX.Y/site-packages/mesos.
 
 
 Diffs
 -
 
   src/Makefile.am 54eaf205eecb6bf1a9a5c4b5ddad55f46ad635ec 
   src/python/interface/setup.py.in afcaf7ad6851eb36304a3be92c062cb6b21dbb03 
   src/python/setup.py.in 304c4bf87870fbaff2de0615cfd2263bb8a7ad3a 
 
 Diff: https://reviews.apache.org/r/37081/diff/
 
 
 Testing
 ---
 
 ## Test steps
 ### In CentOS 6.6
 ```
 ./bootstrap
 mkdir build
 cd build
 make -j4
 sudo make install
 ```
 
 And then execute
 
 ```
 export PYTHONPATH=/usr/local/lib/python2.6/site-packages
 python -c import mesos; from mesos import native; from mesos import 
 interface
 ```
 
 Check it could success or not.
 
 Also check the `__init__.py` file 
 ```
 cat /usr/local/lib/python2.6/site-packages/mesos/__init__.py
 ```
 
 
 Thanks,
 
 haosdent huang
 




Re: Review Request 37081: Let __init__.py getting installed to $PREFIX/lib/pythonX.Y/site-packages/mesos.

2015-08-04 Thread Marco Massenzio


 On Aug. 5, 2015, 5:47 a.m., Marco Massenzio wrote:
  did you forget to rebase?

Never mind - I was just looking at diff 4 -- 5.
All good.


- Marco


---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/37081/#review94191
---


On Aug. 5, 2015, 4:21 a.m., haosdent huang wrote:
 
 ---
 This is an automatically generated e-mail. To reply, visit:
 https://reviews.apache.org/r/37081/
 ---
 
 (Updated Aug. 5, 2015, 4:21 a.m.)
 
 
 Review request for mesos, Kapil Arya and Marco Massenzio.
 
 
 Bugs: MESOS-2337
 https://issues.apache.org/jira/browse/MESOS-2337
 
 
 Repository: mesos
 
 
 Description
 ---
 
 Let __init__.py getting installed to 
 $PREFIX/lib/pythonX.Y/site-packages/mesos.
 
 
 Diffs
 -
 
   src/Makefile.am 54eaf205eecb6bf1a9a5c4b5ddad55f46ad635ec 
   src/python/interface/setup.py.in afcaf7ad6851eb36304a3be92c062cb6b21dbb03 
   src/python/setup.py.in 304c4bf87870fbaff2de0615cfd2263bb8a7ad3a 
 
 Diff: https://reviews.apache.org/r/37081/diff/
 
 
 Testing
 ---
 
 ## Test steps
 ### In CentOS 6.6
 ```
 ./bootstrap
 mkdir build
 cd build
 make -j4
 sudo make install
 ```
 
 And then execute
 
 ```
 export PYTHONPATH=/usr/local/lib/python2.6/site-packages
 python -c import mesos; from mesos import native; from mesos import 
 interface
 ```
 
 Check it could success or not.
 
 Also check the `__init__.py` file 
 ```
 cat /usr/local/lib/python2.6/site-packages/mesos/__init__.py
 ```
 
 
 Thanks,
 
 haosdent huang
 




Re: Review Request 37081: Let __init__.py getting installed to $PREFIX/lib/pythonX.Y/site-packages/mesos.

2015-08-04 Thread Mesos ReviewBot

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/37081/#review94165
---


Patch looks great!

Reviews applied: [37081]

All tests passed.

- Mesos ReviewBot


On Aug. 4, 2015, 5:33 p.m., haosdent huang wrote:
 
 ---
 This is an automatically generated e-mail. To reply, visit:
 https://reviews.apache.org/r/37081/
 ---
 
 (Updated Aug. 4, 2015, 5:33 p.m.)
 
 
 Review request for mesos, Kapil Arya and Marco Massenzio.
 
 
 Bugs: MESOS-2337
 https://issues.apache.org/jira/browse/MESOS-2337
 
 
 Repository: mesos
 
 
 Description
 ---
 
 Let __init__.py getting installed to 
 $PREFIX/lib/pythonX.Y/site-packages/mesos.
 
 
 Diffs
 -
 
   src/Makefile.am 54eaf205eecb6bf1a9a5c4b5ddad55f46ad635ec 
   src/python/setup.py.in 304c4bf87870fbaff2de0615cfd2263bb8a7ad3a 
 
 Diff: https://reviews.apache.org/r/37081/diff/
 
 
 Testing
 ---
 
 ## Test steps
 ### In CentOS 6.6
 ```
 ./bootstrap
 mkdir build
 cd build
 make -j4
 sudo make install
 ```
 
 And then execute
 
 ```
 export PYTHONPATH=/usr/local/lib/python2.6/site-packages
 python -c import mesos; from mesos import native; from mesos import 
 interface
 ```
 
 Check it could success or not.
 
 Also check the `__init__.py` file 
 ```
 cat /usr/local/lib/python2.6/site-packages/mesos/__init__.py
 ```
 
 
 Thanks,
 
 haosdent huang
 




Re: Review Request 37081: Let __init__.py getting installed to $PREFIX/lib/pythonX.Y/site-packages/mesos.

2015-08-04 Thread haosdent huang

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/37081/
---

(Updated Aug. 4, 2015, 5:12 p.m.)


Review request for mesos, Kapil Arya and Marco Massenzio.


Bugs: MESOS-2337
https://issues.apache.org/jira/browse/MESOS-2337


Repository: mesos


Description
---

Let __init__.py getting installed to $PREFIX/lib/pythonX.Y/site-packages/mesos.


Diffs (updated)
-

  src/Makefile.am 54eaf205eecb6bf1a9a5c4b5ddad55f46ad635ec 
  src/python/setup.py.in 304c4bf87870fbaff2de0615cfd2263bb8a7ad3a 

Diff: https://reviews.apache.org/r/37081/diff/


Testing
---


Thanks,

haosdent huang



Re: Review Request 37081: Let __init__.py getting installed to $PREFIX/lib/pythonX.Y/site-packages/mesos.

2015-08-04 Thread haosdent huang

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/37081/
---

(Updated Aug. 4, 2015, 5:33 p.m.)


Review request for mesos, Kapil Arya and Marco Massenzio.


Bugs: MESOS-2337
https://issues.apache.org/jira/browse/MESOS-2337


Repository: mesos


Description
---

Let __init__.py getting installed to $PREFIX/lib/pythonX.Y/site-packages/mesos.


Diffs
-

  src/Makefile.am 54eaf205eecb6bf1a9a5c4b5ddad55f46ad635ec 
  src/python/setup.py.in 304c4bf87870fbaff2de0615cfd2263bb8a7ad3a 

Diff: https://reviews.apache.org/r/37081/diff/


Testing (updated)
---

## Test steps
### In CentOS 6.6
```
./bootstrap
mkdir build
cd build
make -j4
sudo make install
```

And then execute

```
export PYTHONPATH=/usr/local/lib/python2.6/site-packages
python -c import mesos; from mesos import native; from mesos import interface
```

Check it could success or not.

Also check the `__init__.py` file 
```
cat /usr/local/lib/python2.6/site-packages/mesos/__init__.py
```


Thanks,

haosdent huang



Re: Review Request 37081: Let __init__.py getting installed to $PREFIX/lib/pythonX.Y/site-packages/mesos.

2015-08-04 Thread haosdent huang

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/37081/
---

(Updated Aug. 4, 2015, 4:33 p.m.)


Review request for mesos, Kapil Arya and Marco Massenzio.


Bugs: MESOS-2337
https://issues.apache.org/jira/browse/MESOS-2337


Repository: mesos


Description
---

Let __init__.py getting installed to $PREFIX/lib/pythonX.Y/site-packages/mesos.


Diffs (updated)
-

  src/Makefile.am 54eaf205eecb6bf1a9a5c4b5ddad55f46ad635ec 

Diff: https://reviews.apache.org/r/37081/diff/


Testing
---


Thanks,

haosdent huang



Re: Review Request 37081: Let __init__.py getting installed to $PREFIX/lib/pythonX.Y/site-packages/mesos.

2015-08-04 Thread Marco Massenzio

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/37081/#review94084
---


Can you please define how did you test that this works in the 'tests' section?
I can try this out on Ubuntu 14.04 (and OSX) given the steps to reproduce the 
issue, and then applying the patch.

Once we verify that it works on enough platforms, we can ship it.

Thanks!

- Marco Massenzio


On Aug. 4, 2015, 5:12 p.m., haosdent huang wrote:
 
 ---
 This is an automatically generated e-mail. To reply, visit:
 https://reviews.apache.org/r/37081/
 ---
 
 (Updated Aug. 4, 2015, 5:12 p.m.)
 
 
 Review request for mesos, Kapil Arya and Marco Massenzio.
 
 
 Bugs: MESOS-2337
 https://issues.apache.org/jira/browse/MESOS-2337
 
 
 Repository: mesos
 
 
 Description
 ---
 
 Let __init__.py getting installed to 
 $PREFIX/lib/pythonX.Y/site-packages/mesos.
 
 
 Diffs
 -
 
   src/Makefile.am 54eaf205eecb6bf1a9a5c4b5ddad55f46ad635ec 
   src/python/setup.py.in 304c4bf87870fbaff2de0615cfd2263bb8a7ad3a 
 
 Diff: https://reviews.apache.org/r/37081/diff/
 
 
 Testing
 ---
 
 
 Thanks,
 
 haosdent huang
 




Re: Review Request 37081: Let __init__.py getting installed to $PREFIX/lib/pythonX.Y/site-packages/mesos.

2015-08-04 Thread Marco Massenzio


 On Aug. 4, 2015, 5:17 p.m., Marco Massenzio wrote:
  Can you please define how did you test that this works in the 'tests' 
  section?
  I can try this out on Ubuntu 14.04 (and OSX) given the steps to reproduce 
  the issue, and then applying the patch.
  
  Once we verify that it works on enough platforms, we can ship it.
  
  Thanks!
 
 haosdent huang wrote:
 Hi, @marco. Thank you for your help.
 
 Marco Massenzio wrote:
 haha thank *you* for fixing this!
 I'm testing it out currently on my Mac - will try it out on a Ubuntu VM 
 or my home box later this evening.
 Will keep you posted.
 
 Thanks for repro steps!

ok - this *almost* worked :)
Are we missing an `__init__.py` in `google`?

```
$ ../configure --prefix=/Users/marco/mesos-inst/lib
```
then the usual `make  make install` - then:
```
$ find . |grep __init__
./lib/python/site-packages/google/protobuf/__init__.py
./lib/python/site-packages/google/protobuf/__init__.pyc
./lib/python/site-packages/google/protobuf/compiler/__init__.py
./lib/python/site-packages/google/protobuf/compiler/__init__.pyc
./lib/python/site-packages/google/protobuf/internal/__init__.py
./lib/python/site-packages/google/protobuf/internal/__init__.pyc
./lib/python/site-packages/google/protobuf/pyext/__init__.py
./lib/python/site-packages/google/protobuf/pyext/__init__.pyc
./lib/python/site-packages/mesos/__init__.py
./lib/python/site-packages/mesos/__init__.pyc
./lib/python/site-packages/mesos/interface/__init__.py
./lib/python/site-packages/mesos/interface/__init__.pyc
./lib/python/site-packages/mesos/native/__init__.py
./lib/python/site-packages/mesos/native/__init__.pyc
./libexec/mesos/python/mesos/__init__.py
```
as you can see, there are now the `__init__.py` files in the right places under 
`mesos` (if you do the same from `master` there's nothing in there - so, yay! 
:) but there is none under the `google/` package:
```
[~/mesos-inst/lib] $ export PYTHONPATH=./lib/python/site-packages/

[~/mesos-inst/lib] $ python
Python 2.7.6 (default, Sep  9 2014, 15:04:36) 
[GCC 4.2.1 Compatible Apple LLVM 6.0 (clang-600.0.39)] on darwin
Type help, copyright, credits or license for more information.
 import mesos
 from mesos import native
Traceback (most recent call last):
  File stdin, line 1, in module
  File 
/Users/marco/mesos-inst/lib/lib/python/site-packages/mesos/native/__init__.py,
 line 17, in module
from ._mesos import MesosExecutorDriverImpl
  File 
/Users/marco/mesos-inst/lib/lib/python/site-packages/mesos/interface/mesos_pb2.py,
 line 4, in module
from google.protobuf.internal import enum_type_wrapper
ImportError: No module named google.protobuf.internal
 import google.protobuf.internal
Traceback (most recent call last):
  File stdin, line 1, in module
ImportError: No module named google.protobuf.internal
```
This was on a Mac OSX 10.10 (Yosemite) - about to test the same on an Ubuntu 
14.04 VM, brand new.


- Marco


---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/37081/#review94084
---


On Aug. 4, 2015, 5:33 p.m., haosdent huang wrote:
 
 ---
 This is an automatically generated e-mail. To reply, visit:
 https://reviews.apache.org/r/37081/
 ---
 
 (Updated Aug. 4, 2015, 5:33 p.m.)
 
 
 Review request for mesos, Kapil Arya and Marco Massenzio.
 
 
 Bugs: MESOS-2337
 https://issues.apache.org/jira/browse/MESOS-2337
 
 
 Repository: mesos
 
 
 Description
 ---
 
 Let __init__.py getting installed to 
 $PREFIX/lib/pythonX.Y/site-packages/mesos.
 
 
 Diffs
 -
 
   src/Makefile.am 54eaf205eecb6bf1a9a5c4b5ddad55f46ad635ec 
   src/python/setup.py.in 304c4bf87870fbaff2de0615cfd2263bb8a7ad3a 
 
 Diff: https://reviews.apache.org/r/37081/diff/
 
 
 Testing
 ---
 
 ## Test steps
 ### In CentOS 6.6
 ```
 ./bootstrap
 mkdir build
 cd build
 make -j4
 sudo make install
 ```
 
 And then execute
 
 ```
 export PYTHONPATH=/usr/local/lib/python2.6/site-packages
 python -c import mesos; from mesos import native; from mesos import 
 interface
 ```
 
 Check it could success or not.
 
 Also check the `__init__.py` file 
 ```
 cat /usr/local/lib/python2.6/site-packages/mesos/__init__.py
 ```
 
 
 Thanks,
 
 haosdent huang
 




Re: Review Request 37081: Let __init__.py getting installed to $PREFIX/lib/pythonX.Y/site-packages/mesos.

2015-08-04 Thread Marco Massenzio


 On Aug. 4, 2015, 5:17 p.m., Marco Massenzio wrote:
  Can you please define how did you test that this works in the 'tests' 
  section?
  I can try this out on Ubuntu 14.04 (and OSX) given the steps to reproduce 
  the issue, and then applying the patch.
  
  Once we verify that it works on enough platforms, we can ship it.
  
  Thanks!
 
 haosdent huang wrote:
 Hi, @marco. Thank you for your help.

haha thank *you* for fixing this!
I'm testing it out currently on my Mac - will try it out on a Ubuntu VM or my 
home box later this evening.
Will keep you posted.

Thanks for repro steps!


- Marco


---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/37081/#review94084
---


On Aug. 4, 2015, 5:33 p.m., haosdent huang wrote:
 
 ---
 This is an automatically generated e-mail. To reply, visit:
 https://reviews.apache.org/r/37081/
 ---
 
 (Updated Aug. 4, 2015, 5:33 p.m.)
 
 
 Review request for mesos, Kapil Arya and Marco Massenzio.
 
 
 Bugs: MESOS-2337
 https://issues.apache.org/jira/browse/MESOS-2337
 
 
 Repository: mesos
 
 
 Description
 ---
 
 Let __init__.py getting installed to 
 $PREFIX/lib/pythonX.Y/site-packages/mesos.
 
 
 Diffs
 -
 
   src/Makefile.am 54eaf205eecb6bf1a9a5c4b5ddad55f46ad635ec 
   src/python/setup.py.in 304c4bf87870fbaff2de0615cfd2263bb8a7ad3a 
 
 Diff: https://reviews.apache.org/r/37081/diff/
 
 
 Testing
 ---
 
 ## Test steps
 ### In CentOS 6.6
 ```
 ./bootstrap
 mkdir build
 cd build
 make -j4
 sudo make install
 ```
 
 And then execute
 
 ```
 export PYTHONPATH=/usr/local/lib/python2.6/site-packages
 python -c import mesos; from mesos import native; from mesos import 
 interface
 ```
 
 Check it could success or not.
 
 Also check the `__init__.py` file 
 ```
 cat /usr/local/lib/python2.6/site-packages/mesos/__init__.py
 ```
 
 
 Thanks,
 
 haosdent huang