What to do with the Swift REPL “NameError: name ‘run_one_line’ is not defined” error

I was playing around with Swift this weekend. Every time I started the REPL (whether version 3x or 4x of Swift) I got a whole bunch of errors that look like this:

The REPL would work fine, but you know…. it was really, really, really, really annoying having to look at that error. All 100+ times it got repeated.

Turns out that the Swift REPL depends on a Python library called six. You may be able to quickly install it using this command:

Problem solved……?

Good luck out there!

 

Leave a Reply

Your email address will not be published. Required fields are marked *