Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[PYTHON] Only generate protos in development #351

Merged
merged 4 commits into from
May 15, 2015
Merged

[PYTHON] Only generate protos in development #351

merged 4 commits into from
May 15, 2015

Conversation

tamird
Copy link
Contributor

@tamird tamird commented May 7, 2015

@tseaver
Copy link
Contributor

tseaver commented May 11, 2015

I don't believe removing MANIFEST.in helps: that file governs what files are included when creating the "sdist", but is not in play during installation. The build_py step is what fails on install.

@tamird
Copy link
Contributor Author

tamird commented May 11, 2015

I tested it locally (and added it to CI) so it seems to work. It's another matter that the cpp_implementation tests are failing now :(

@tseaver
Copy link
Contributor

tseaver commented May 11, 2015

@tamird have you tested it by running python setup.py sdist and then trying to install the generated sdist in a fresh virtualenv? (not anywhere inside the main protobuf repo)?

@tseaver
Copy link
Contributor

tseaver commented May 11, 2015

#360 out-of-lines the proto-generation stuff from "normal" installation, adding a new setup.py generate_protos command for the maintainers to use.

@tamird
Copy link
Contributor Author

tamird commented May 14, 2015

Hey, this is green (and it tests pip install in a fresh virtualenv). How about it @haberman ?

@haberman
Copy link
Member

I love the code to test pip in a virtualenv.

I would rather not remove MANIFEST.in, because it pollutes our distribution with stuff that doesn't belong there.

Instead, to fix the build, could we simply add this at the beginning of GenerateUnittestProtos():

# Unittest protos are only needed for development.
if not os.path.exists("../.git"):
  return

@@ -102,10 +104,13 @@ build_python_cpp() {
./autogen.sh
./configure
make -j2
export LD_LIBRARY_PATH=../src/.libs
export LD_LIBRARY_PATH=../src/.libs
export DYLD_LIBRARY_PATH=../src/.libs
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please add a comment like "# For OS X"

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

@tamird
Copy link
Contributor Author

tamird commented May 15, 2015

Done.

@tamird tamird changed the title Remove MANIFEST.in Only generate protos in development May 15, 2015
@tamird tamird changed the title Only generate protos in development [PYTHON] Only generate protos in development May 15, 2015
@haberman
Copy link
Member

Thanks a lot! Merging.

haberman added a commit that referenced this pull request May 15, 2015
[PYTHON] Only generate protos in development
@haberman haberman merged commit 17ca0fe into protocolbuffers:master May 15, 2015
@tamird tamird deleted the remove-manifest-fix-dist branch May 15, 2015 22:14
adellahlou pushed a commit to adellahlou/protobuf that referenced this pull request Apr 20, 2023
…lity of NaN and Infinity + additional documentation of util.toJSONOptions, see protocolbuffers#351
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3.0.0-alpha-2 won't pip install
4 participants