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

Fix test_fs git failures #3281

Closed
peiyuwang opened this issue Apr 27, 2016 · 3 comments
Closed

Fix test_fs git failures #3281

peiyuwang opened this issue Apr 27, 2016 · 3 comments

Comments

@peiyuwang
Copy link
Contributor

This is a placeholder to address the test failures after https://rbcommons.com/s/twitter/r/3770/ makes ScmProjectTree pickable #3189

Test failures look like this

E       SerializationError: Failed to pickle Throw(exc=GitDiedException(u"Git cat-file died while trying to read 'HEAD:\n'.",)): Can't pickle <class 'pants.scm.git.GitDiedException'>: attribute lookup pants.scm.git.GitDiedException failed

The root issue is probably related to git setup in test, for example, the following would fail:

git --git-dir=/Users/peiyu/github/pants/tests/python/pants_test/engine/exp/examples/fs_test/.git --work-tree=/Users/peiyu/github/pants/tests/python/pants_test/engine/exp/examples/fs_test cat-file --batch
peiyuwang added a commit to peiyuwang/pants that referenced this issue Apr 27, 2016
peiyuwang added a commit that referenced this issue Apr 29, 2016
Two things to make `ScmProjectTree` picklable:

* `_reader`, `GitRepositoryReader` contains a `Popen` instance. This review marks it `@memoized` so it is saved by memoized.
* `_scm`, `Git` contains a logger, this review moves the logger to the module.

Also added is to initialize Git FS for test, only two tests fail now, created #3281 to address separately.
(Assertion errors not pickle or exceptions)

Testing Done:
https://travis-ci.org/peiyuwang/pants/builds/126266801 passed
https://travis-ci.org/peiyuwang/pants/builds/126289749 passed
https://travis-ci.org/peiyuwang/pants/builds/126550497 passed

Reviewed at https://rbcommons.com/s/twitter/r/3770/
@kwlzn
Copy link
Member

kwlzn commented May 26, 2016

looks like a couple of commits went in around this, but the issue is still open - is this resolved by chance?

@peiyuwang
Copy link
Contributor Author

Still open, specifically two tests in GitFSTest.

#3189 's goal was to get some tests passing, wasn't a priority to make all passing, thus this issue was created for the remaining ones.

@stuhood stuhood changed the title Fix test_fs test failures Fix test_fs git failures Jun 13, 2016
@stuhood
Copy link
Member

stuhood commented Apr 6, 2017

Won't fix. Now deprecated.

@stuhood stuhood closed this as completed Apr 6, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants