1. Mike Orr
  2. Unipath
Issue #6 invalid

Non-string arguments

Mike Orr
repo owner created an issue

The constructor should accept int arguments and call 'str' on them. It's common in applications to want to interpolate int IDs into a path, and it clutters the calling code to repeatedly call str() on an argument.

Other non-string types should probably be rejected. True, False, and None have well-known string equivalents but are unlikely to be used in a path. Floats are unstable due to C-level rounding, and collection types are also unlikely for a path segment.

Comments (1)

  1. Log in to comment