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

Small logging update to java executor and fix undefined var in release.sh #7370

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions build-support/bin/release.sh
Original file line number Diff line number Diff line change
Expand Up @@ -513,7 +513,7 @@ function fetch_and_check_prebuilt_wheels() {
do
packages=($(find_pkg "${PACKAGE}" "${PANTS_UNSTABLE_VERSION}" "${check_dir}"))
if [ ${#packages[@]} -eq 0 ]; then
missing+=("${NAME}")
missing+=("${PACKAGE}")
Copy link
Contributor

Choose a reason for hiding this comment

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

Is this change breaking anything for you at the moment, or you only noticed it and are being a good citizen? I can roll it into #7197 if you prefer Stu to keep this PR more focused.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It's not breaking anything at the moment, just needed to be cleaned up.

Copy link
Contributor

Choose a reason for hiding this comment

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

Sounds good! I'll add it to my PR that makes a bunch of releases.sh changes already, meaning it can be removed here and the PR title can be shortened.

Copy link
Contributor

Choose a reason for hiding this comment

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

So looking more into it, there are 5 distinct places we use ${NAME} in release.sh. I'm not entirely sure where it gets defined, but it seems like they're getting resolved as we run these functions when doing a manual release, and no one has seemed to notice.

I'm going to leave it out of my PR after all. If we still want to address it, I think this change would be best broken out into a dedicated PR.

continue
fi

Expand All @@ -529,7 +529,7 @@ function fetch_and_check_prebuilt_wheels() {

# N.B. For platform-specific wheels, we expect 6 wheels: {linux,osx} * {cp27m,cp27mu,abi3}.
if [ "${cross_platform}" != "true" ] && [ ${#packages[@]} -ne 6 ]; then
missing+=("${NAME} (expected whls for each platform: had only ${packages[@]})")
missing+=("${PACKAGE} (expected whls for each platform: had only ${packages[@]})")
continue
fi
done
Expand Down
3 changes: 2 additions & 1 deletion src/python/pants/java/executor.py
Original file line number Diff line number Diff line change
Expand Up @@ -256,4 +256,5 @@ def _spawn(self, cmd, cwd, stdout=None, stderr=None, stdin=None, **subprocess_ar
return subprocess.Popen(cmd, cwd=cwd, stdin=stdin, stdout=stdout, stderr=stderr,
**subprocess_args)
except OSError as e:
raise self.Error('Problem executing {0}: {1}'.format(self._distribution.java, e))
raise self.Error('Problem executing {0} at cwd={1}: {2}'
.format(self._distribution.java, cwd, e))
2 changes: 1 addition & 1 deletion tests/python/pants_test/java/distribution/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,11 @@ python_tests(
sources = ['test_distribution_integration.py'],
dependencies = [
'3rdparty/python:future',
'3rdparty/python/twitter/commons:twitter.common.collections',
'src/python/pants/java/distribution',
'src/python/pants/util:osutil',
'tests/python/pants_test:int-test',
'tests/python/pants_test/subsystem:subsystem_utils',
'3rdparty/python/twitter/commons:twitter.common.collections',
],
tags = {'integration'},
timeout = 120,
Expand Down