Skip to content

UnicodeEncodeError in get_title.py #1

@mikej

Description

@mikej

When trying to get the title for https://www.hackingwithswift.com/read

Traceback (most recent call last):
  File "/Users/mike/kmscripts/get_title.py", line 15, in <module>
    sys.stdout.write('"' + soup.title.text + '"')
UnicodeEncodeError: 'ascii' codec can't encode character u'\u2013' in position 20: ordinal not in range(128)

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions