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

Bug 1863769 - Try to improve diagnostics for AAB upload #254

Merged
merged 2 commits into from
Nov 8, 2023
Merged
Changes from 1 commit
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
26 changes: 18 additions & 8 deletions mozapkpublisher/common/store.py
Original file line number Diff line number Diff line change
Expand Up @@ -104,16 +104,26 @@ def upload_apk(self, apk):
raise

def upload_aab(self, aab):
# try to get extra network diagnostics during upload
debuglevel = httplib2.debuglevel
httplib2.debuglevel = 4

aab_path = aab.name
logger.info('Uploading "{}" ...'.format(aab_path))
response = self._edit_resource.bundles().upload(
editId=self._edit_id,
packageName=self._package_name,
media_body=aab_path,
media_mime_type='application/octet-stream',
).execute()
logger.info('"{}" uploaded'.format(aab_path))
logger.debug('Upload response: {}'.format(response))
try:
response = self._edit_resource.bundles().upload(
editId=self._edit_id,
packageName=self._package_name,
media_body=aab_path,
media_mime_type='application/octet-stream',
).execute()
logger.info('"{}" uploaded'.format(aab_path))
logger.debug('Upload response: {}'.format(response))
except Exception:
logger.exception("caught exception in upload_aab:")
raise
finally:
httplib2.debuglevel = debuglevel

def _update_track(self, track, version_codes, rollout_percentage=None):
if track == 'rollout' and rollout_percentage is None:
Expand Down