Skip to content

Use isinstance in is_string_like#2660

Merged
jarrodmillman merged 1 commit intonetworkx:masterfrom
jarrodmillman:deprecate-is_string_like
Sep 10, 2017
Merged

Use isinstance in is_string_like#2660
jarrodmillman merged 1 commit intonetworkx:masterfrom
jarrodmillman:deprecate-is_string_like

Conversation

@jarrodmillman
Copy link
Member

@dschult
Copy link
Member

dschult commented Sep 10, 2017

I understand the change matplotlib is making toward isinstance over duck-typing (the duck-typing doesn't work with e.g. open). But instead of spreading lots of basestring cruft throughout our codebase, could we continue to use is_string_like with the basestring cruft built into it. That would contain the py2/py3 checking to utils/misc.py. [eventually py2 checking will need to be deprecated too -- can we contain the impact?]

@jarrodmillman jarrodmillman changed the title Deprecate is_string_like WIP: Deprecate is_string_like Sep 10, 2017
@jarrodmillman jarrodmillman force-pushed the deprecate-is_string_like branch from ddcd07a to fcbc1d2 Compare September 10, 2017 15:10
@jarrodmillman jarrodmillman changed the title WIP: Deprecate is_string_like Use isinstance in is_string_like Sep 10, 2017
@jarrodmillman jarrodmillman merged commit 0ab38ce into networkx:master Sep 10, 2017
@jarrodmillman jarrodmillman deleted the deprecate-is_string_like branch September 11, 2017 19:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Development

Successfully merging this pull request may close these issues.

2 participants