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

Make take_bug_reports consistent with its singular version. #602

Merged
merged 3 commits into from
Jul 23, 2019
Merged

Conversation

xpconanfan
Copy link
Collaborator

@xpconanfan xpconanfan commented Jul 23, 2019

Also simplify the timestamp generation logic.


This change is Reviewable

@xpconanfan xpconanfan added this to the Mobly Release 1.9 milestone Jul 23, 2019
@xpconanfan xpconanfan self-assigned this Jul 23, 2019
Copy link
Contributor

@winterfroststrom winterfroststrom left a comment

Choose a reason for hiding this comment

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

Reviewable status: 0 of 2 files reviewed, 1 unresolved discussion (waiting on @winterfroststrom and @xpconanfan)


mobly/controllers/android_device.py, line 408 at r1 (raw file):

_begin_time

Is there a reason against using begin_time directly?
it's a string reference right? so it should be immutable.

Copy link
Collaborator Author

@xpconanfan xpconanfan left a comment

Choose a reason for hiding this comment

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

Reviewable status: 0 of 2 files reviewed, 1 unresolved discussion (waiting on @winterfroststrom and @xpconanfan)


mobly/controllers/android_device.py, line 408 at r1 (raw file):

Previously, winterfroststrom wrote…
_begin_time

Is there a reason against using begin_time directly?
it's a string reference right? so it should be immutable.

I don't think you are supposed to reassign params?

Copy link
Contributor

@winterfroststrom winterfroststrom left a comment

Choose a reason for hiding this comment

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

Reviewable status: 0 of 2 files reviewed, 1 unresolved discussion (waiting on @xpconanfan)


mobly/controllers/android_device.py, line 408 at r1 (raw file):

Previously, xpconanfan (Ang Li) wrote…

I don't think you are supposed to reassign params?

Isn't
if param is None:
param = ...

A really common pattern with default params?

Also simplify the timestamp generation logic.
Copy link
Collaborator Author

@xpconanfan xpconanfan left a comment

Choose a reason for hiding this comment

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

Reviewable status: 0 of 2 files reviewed, 1 unresolved discussion (waiting on @winterfroststrom and @xpconanfan)


mobly/controllers/android_device.py, line 408 at r1 (raw file):

Previously, winterfroststrom wrote…

Isn't
if param is None:
param = ...

A really common pattern with default params?

Done.

Copy link
Contributor

@winterfroststrom winterfroststrom left a comment

Choose a reason for hiding this comment

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

Reviewable status: 0 of 2 files reviewed, all discussions resolved (waiting on @xpconanfan)


mobly/controllers/android_device.py, line 408 at r1 (raw file):

Previously, xpconanfan (Ang Li) wrote…

Done.

what if begin_time needs to be explicitly empty string for some reason?
would it be worthwhile to change the check to "begin_time is None" instead for that

Copy link
Collaborator Author

@xpconanfan xpconanfan left a comment

Choose a reason for hiding this comment

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

Reviewable status: 0 of 2 files reviewed, all discussions resolved (waiting on @xpconanfan)


mobly/controllers/android_device.py, line 408 at r1 (raw file):

Previously, winterfroststrom wrote…

what if begin_time needs to be explicitly empty string for some reason?
would it be worthwhile to change the check to "begin_time is None" instead for that

I don't think it's a valid use case.
But changed anyway.

Copy link
Contributor

@winterfroststrom winterfroststrom left a comment

Choose a reason for hiding this comment

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

Reviewable status: 0 of 2 files reviewed, all discussions resolved (waiting on @xpconanfan)

@xpconanfan xpconanfan merged commit dc2ba96 into master Jul 23, 2019
@xpconanfan xpconanfan deleted the br branch July 23, 2019 01:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants