Skip to content

Conversation

@fcq
Copy link
Contributor

@fcq fcq commented Jan 7, 2020

The former is only available in Python3, in which getargspec was
deprecated.

  • Motivation for features / changes
    This allows to get rid of a deprecation warning when using Python3.

  • Technical description of changes
    Uses a Python3 drop-in replacement, when available.
    Both return a namedtuple with an equivalent "args" attribute, so the
    functionality is unchanged.

  • Screenshots of UI changes
    N/A

  • Detailed steps to verify changes work correctly (as executed by you)
    Ran event_file_loader_test, in Python2 and Python3.

  • Alternate designs / implementations considered

inspect.getargspec.

The former is only available in Python3, in which getargspec was
deprecated. This allows to get rid of a deprecation warning.

Both return a namedtuple with an equivalent "args" attribute, so the
functionality is unchanged.
@stephanwlee stephanwlee requested a review from nfelt January 7, 2020 15:23
Copy link
Contributor

@nfelt nfelt left a comment

Choose a reason for hiding this comment

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

Thanks for the fix!

@nfelt nfelt merged commit 3d81fef into tensorflow:master Jan 7, 2020
bileschi pushed a commit to bileschi/tensorboard that referenced this pull request Mar 3, 2020
…pec. (tensorflow#3116)

* When available, use inspect.getfullargspec instead of
inspect.getargspec.

The former is only available in Python3, in which getargspec was
deprecated. This allows to get rid of a deprecation warning.

Both return a namedtuple with an equivalent "args" attribute, so the
functionality is unchanged.

* Changes so that black --check succeeds.
@bileschi bileschi mentioned this pull request Mar 3, 2020
nfelt pushed a commit that referenced this pull request Mar 4, 2020
…pec. (#3116)

* When available, use inspect.getfullargspec instead of
inspect.getargspec.

The former is only available in Python3, in which getargspec was
deprecated. This allows to get rid of a deprecation warning.

Both return a namedtuple with an equivalent "args" attribute, so the
functionality is unchanged.

* Changes so that black --check succeeds.
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 participants