Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Xcode 9 / Swift 4 migration error

Tags:

swift4

xcode9

I'm receiving errors when trying to automatically migrate to swift 4.

I'm getting "unexpected duplicate task" when trying to migrate a workspace with multiple targets.

like image 337
Uba Duba Avatar asked Sep 18 '17 15:09

Uba Duba


2 Answers

Reference From BEm answer

I had the same problem. In my app I have three target

  • Dev
  • Pre
  • Prod

App was running in Dev but not in Pre & Prod.

When I open my under File > Workspace Settings, I had below (New Build System(Default))

enter image description here

I changed it to (Legacy Build System)

enter image description here

And it was a fix for me.

like image 110
Gagan_iOS Avatar answered Nov 09 '22 04:11

Gagan_iOS


Had the same error when trying to migrate to swift 4. Check if you did enable the "New Build System (Preview)" under File > Workspace Settings. If you enabled it make sure to set it back to "Standard Build System". Did solve the problem for me.

like image 13
Baran Emre Avatar answered Nov 09 '22 02:11

Baran Emre