Home

Mac - A javascript error occurred in the main process

%3CLINGO-SUB%20id%3D%22lingo-sub-567385%22%20slang%3D%22en-US%22%3EMac%20-%20A%20javascript%20error%20occurred%20in%20the%20main%20process%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-567385%22%20slang%3D%22en-US%22%3E%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-center%22%20style%3D%22width%3A%20162px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F113304iF8E02F6368948FEE%2Fimage-size%2Fsmall%3Fv%3D1.0%26amp%3Bpx%3D200%22%20alt%3D%22Screen%20Shot%202019-05-15%20at%2011.09.57%20am.png%22%20title%3D%22Screen%20Shot%202019-05-15%20at%2011.09.57%20am.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EI've%20tried%20installing%20Teams%20for%20Mac%20a%20few%20times%20now%20and%20each%20time%20I%20end%20up%20with%20this%20error%20screen%20and%20the%20app%20never%20loads.%20I'm%20going%20to%20assume%20there's%20a%20conflict%20with%20something%20on%20my%20system%2C%20but%20I've%20no%20idea%20what%20or%20where%20to%20look.%3C%2FP%3E%3CP%3ERunning%20Mojave%26nbsp%3B10.14.4%20(18E226)%20on%20a%20MacBook%20Pro.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-567385%22%20slang%3D%22en-US%22%3E%3CLINGO-LABEL%3EMicrosoft%20Teams%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E%3CLINGO-SUB%20id%3D%22lingo-sub-567953%22%20slang%3D%22en-US%22%3ERe%3A%20Mac%20-%20A%20javascript%20error%20occurred%20in%20the%20main%20process%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-567953%22%20slang%3D%22en-US%22%3ESeems%20like%20a%20permission%20error%20for%20user%20%E2%80%9Ccontagious%E2%80%9D%20%3F%20%2C%20trying%20to%20create%20a%20directory%20for%20installation...%3CBR%20%2F%3E%3CBR%20%2F%3EDo%20you%20have%20admin%20rights%3F%3CBR%20%2F%3EI%E2%80%99m%20MAC%20you%20need%20admin%20permissions!%3CBR%20%2F%3E%3CBR%20%2F%3EFrom%20official%20doc%3A%3CBR%20%2F%3E(admin%20rights%20are%20not%20required%20to%20install%20the%20Teams%20client%20on%20a%20PC%20but%20are%20required%20on%20a%20Mac).%3CBR%20%2F%3E%3CBR%20%2F%3EIf%20you%20are%2C%20get%20the%20logs%20and%20let%20us%20know%3A%3CBR%20%2F%3E%3CBR%20%2F%3EYou%20find%20the%20location%20of%20them%20here%3A%3CBR%20%2F%3E%3CBR%20%2F%3E%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fmicrosoftteams%2Flog-files%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%22%3Ehttps%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fmicrosoftteams%2Flog-files%3C%2FA%3E%3CBR%20%2F%3E%3CBR%20%2F%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-614380%22%20slang%3D%22en-US%22%3ERe%3A%20Mac%20-%20A%20javascript%20error%20occurred%20in%20the%20main%20process%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-614380%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F342138%22%20target%3D%22_blank%22%3E%40AdrianR%3C%2FA%3E%26nbsp%3BFacing%20the%20same%20issue%20also!%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20style%3D%22width%3A%20332px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F114328i30801E935E591712%2Fimage-size%2Fmedium%3Fv%3D1.0%26amp%3Bpx%3D400%22%20alt%3D%22Screen%20Shot%202019-05-20%20at%203.11.29%20pm.png%22%20title%3D%22Screen%20Shot%202019-05-20%20at%203.11.29%20pm.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-632637%22%20slang%3D%22en-US%22%3ERe%3A%20Mac%20-%20A%20javascript%20error%20occurred%20in%20the%20main%20process%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-632637%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F72542%22%20target%3D%22_blank%22%3E%40adam%20deltinger%3C%2FA%3E%26nbsp%3B-%20the%20app%20doesn't%20even%20get%20far%20enough%20to%20start%20creating%20logs.%20The%20Teams%20logs%20folder%3CSPAN%3E%26nbsp%3Bdoesn't%20exist%20let%20alone%20the%20log%20file.%3C%2FSPAN%3E%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%3CSPAN%3EI%20have%20admin%20rights%2C%20and%20the%20app%20correctly%20prompts%20for%20access%20permissions%20when%20it%20installs.%3C%2FSPAN%3E%3C%2FP%3E%3CP%3E%3CSPAN%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F115638iDD285CECE0541CDC%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20alt%3D%22Screen%20Shot%202019-05-22%20at%203.26.18%20pm.png%22%20title%3D%22Screen%20Shot%202019-05-22%20at%203.26.18%20pm.png%22%20%2F%3E%3CSPAN%20class%3D%22lia-inline-image-caption%22%20onclick%3D%22event.preventDefault()%3B%22%3EThe%20installation%20appeared%20to%20be%20successful%3C%2FSPAN%3E%3C%2FSPAN%3E%3CBR%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3ELooking%20in%20to%20the%20error%20message%20it's%20complaining%20because%20it%20can't%20create%20the%20folder%26nbsp%3B~%2FLibrary%2FApplication%20Support%2FMicrosoft%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EChecking%20what%20was%20there%20already%20it%20turned%20out%20the%20folder%20was%20owned%20by%20root%20and%20not%20the%20current%20user%20like%20all%20the%20other%20folders.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%3CSPAN%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20style%3D%22width%3A%20998px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F115639i48396BCE71A3B3E2%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20alt%3D%22Screen%20Shot%202019-05-22%20at%203.30.26%20pm.png%22%20title%3D%22Screen%20Shot%202019-05-22%20at%203.30.26%20pm.png%22%20%2F%3E%3CSPAN%20class%3D%22lia-inline-image-caption%22%20onclick%3D%22event.preventDefault()%3B%22%3EThe%20Microsoft%20folder%20was%20owned%20by%20root%20rather%20than%20the%20user%3C%2FSPAN%3E%3C%2FSPAN%3E%3C%2FSPAN%3E%3C%2FP%3E%3CP%3E%3CSPAN%3ELooking%20in%20to%20what%20could%20have%20caused%20that%2C%20I%20had%20an%20ancient%20Silverlight%20folder%20in%20there.%20No-one%20needs%20that%2C%20so%20let's%20kill%20it.%20rm%20-rf%26nbsp%3B~%2FLibrary%2FApplicationSupport%2FMicrosoft%26nbsp%3Band%20try%20running%20Teams%20again%20and%20I%20got%20the%20same%20error.%20Repeated%20the%20process%20one%20more%20time%20to%20be%20sure%20and%20it%20all%20started%20working%20as%20expected.%3C%2FSPAN%3E%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CH2%20id%3D%22toc-hId-1736221403%22%20id%3D%22toc-hId-1736221403%22%20id%3D%22toc-hId-1736221403%22%20id%3D%22toc-hId-1736221403%22%20id%3D%22toc-hId-1736221403%22%20id%3D%22toc-hId-1736221403%22%20id%3D%22toc-hId-1736221403%22%20id%3D%22toc-hId-1736221403%22%20id%3D%22toc-hId-1736221403%22%3E%3CSPAN%3Etldr%3B%20%3C%2FSPAN%3E%3C%2FH2%3E%3CP%3E%3CSPAN%3EAn%20old%20installation%20of%20Silverlight%20messed%20up%20the%20permissions%20on%20the%20folder.%20Deleting%20the%20Microsoft%20folder%20and%20letting%20Teams%20add%20the%20folder%20back%20itself%20solved%20the%20issue.%26nbsp%3B%3C%2FSPAN%3E%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-853684%22%20slang%3D%22en-US%22%3ERe%3A%20Mac%20-%20A%20javascript%20error%20occurred%20in%20the%20main%20process%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-853684%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F342138%22%20target%3D%22_blank%22%3E%40AdrianR%3C%2FA%3E%26nbsp%3BI%20had%20same%20issue%20and%20just%20did%20sudo%20chown%20yourusername%20Microsoft%20from%20~%5CLibrary%5CApplications%20Support%5C%20directory%20and%20it%20worked%20straight%20away.%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1208569%22%20slang%3D%22en-US%22%3ERe%3A%20Mac%20-%20A%20javascript%20error%20occurred%20in%20the%20main%20process%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1208569%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F408248%22%20target%3D%22_blank%22%3E%40Divergent_Technologies%3C%2FA%3E%26nbsp%3BI%20have%20had%20the%20same%20javascript%20issues%20and%20the%20same%20message%20coming%20up%20when%20I%20try%20to%20open%20teams.%20I%20have%20also%20tried%20to%20follow%20all%20the%20steps%20outlined%20above%2C%20changed%20permissions%2C%20etc.%20and%20the%20same%20thing%20happens.%20Any%20ideas%3F%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1241445%22%20slang%3D%22de-DE%22%3ERe%3A%20Mac%20-%20A%20javascript%20error%20occurred%20in%20the%20main%20process%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1241445%22%20slang%3D%22de-DE%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F574128%22%20target%3D%22_blank%22%3E%40hughmichell%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E...%20Same%20here.%20I%20haven't%20the%20faintest%20idea%20what%20else%20I%20can%20do.%20I%20have%20to%20work%20online%20with%20my%20colleagues%20because%20of%20the%20Corona%20crisis%2C%20but%20I%20can't%20because%20the%20teams%20app%20doesn't%20work.%20So%20I%20tried%20everything%20that%20has%20been%20recommended%20here.%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1241489%22%20slang%3D%22de-DE%22%3ERe%3A%20Mac%20-%20A%20javascript%20error%20occurred%20in%20the%20main%20process%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1241489%22%20slang%3D%22de-DE%22%3E%3CP%3EHooray%2C%20error%20found!%20There%20are%202%20library%20folders%20(of%20course!).%20Go%20to%20HD%20%26gt%3B%20Users%20%26gt%3B%20(yourname)%20%26gt%3B%20Library%20%26gt%3B%20Application%20Support%20%26gt%3B%20Microsoft.%20Set%20the%20permissions%20to%20your%20username%3A%20sudo%20chown%20(yourname)%20%2FUsers%2Fyourname%2FLibrary%2FApplication%3C%2FP%3E%3CP%3ETeams%20works%20now%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1266296%22%20slang%3D%22en-US%22%3ERe%3A%20Mac%20-%20A%20javascript%20error%20occurred%20in%20the%20main%20process%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1266296%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F588298%22%20target%3D%22_blank%22%3E%40Angel1060%3C%2FA%3E%26nbsp%3Bcould%20you%20please%20explain%20HOW%20to%20do%20what%20you%20have%20described%20thanks%3F%3C%2FP%3E%3CP%3EAll%20I%20have%20in%20this%20folder%20is%20a%20Silverlight%20folder%3F%3F%3F%3F%3C%2FP%3E%3CP%3EHow%20do%20I%20s%3CSPAN%3Eet%20the%20permissions%20to%20your%20username%3A%20sudo%20chown%20(yourname)%20%2FUsers%2Fyourname%2FLibrary%2FApplication%5C%20Support%2FMicrosoft%3F%3C%2FSPAN%3E%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1272977%22%20slang%3D%22en-US%22%3ERe%3A%20Mac%20-%20A%20javascript%20error%20occurred%20in%20the%20main%20process%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1272977%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F588298%22%20target%3D%22_blank%22%3E%40Angel1060%3C%2FA%3E%26nbsp%3Bcould%20you%20please%20explain%20the%20steps%20required%20to%20do%20this%3F%26nbsp%3B%20I%20am%20also%20having%20the%20same%20issue%20and%20went%20looking%20for%20the%20library%20folder%20under%20my%20username%20but%20I%20don't%20have%20one%3F%3C%2FP%3E%3C%2FLINGO-BODY%3E
Highlighted
New Contributor

Screen Shot 2019-05-15 at 11.09.57 am.png

 

I've tried installing Teams for Mac a few times now and each time I end up with this error screen and the app never loads. I'm going to assume there's a conflict with something on my system, but I've no idea what or where to look.

Running Mojave 10.14.4 (18E226) on a MacBook Pro.

 

9 Replies
Highlighted
Seems like a permission error for user “contagious” ? , trying to create a directory for installation...

Do you have admin rights?
I’m MAC you need admin permissions!

From official doc:
(admin rights are not required to install the Teams client on a PC but are required on a Mac).

If you are, get the logs and let us know:

You find the location of them here:

https://docs.microsoft.com/en-us/microsoftteams/log-files

Highlighted

@AdrianR Facing the same issue also!

 

Screen Shot 2019-05-20 at 3.11.29 pm.png

Highlighted

@adam deltinger - the app doesn't even get far enough to start creating logs. The Teams logs folder doesn't exist let alone the log file.

 

I have admin rights, and the app correctly prompts for access permissions when it installs.

The installation appeared to be successfulThe installation appeared to be successful

 

Looking in to the error message it's complaining because it can't create the folder ~/Library/Application Support/Microsoft 

 

Checking what was there already it turned out the folder was owned by root and not the current user like all the other folders.

 

The Microsoft folder was owned by root rather than the userThe Microsoft folder was owned by root rather than the user

Looking in to what could have caused that, I had an ancient Silverlight folder in there. No-one needs that, so let's kill it. rm -rf ~/Library/ApplicationSupport/Microsoft and try running Teams again and I got the same error. Repeated the process one more time to be sure and it all started working as expected.

 

tldr;

An old installation of Silverlight messed up the permissions on the folder. Deleting the Microsoft folder and letting Teams add the folder back itself solved the issue. 

 

Highlighted

@AdrianR I had same issue and just did sudo chown yourusername Microsoft from ~\Library\Applications Support\ directory and it worked straight away.

Highlighted

@Divergent_Technologies I have had the same javascript issues and the same message coming up when I try to open teams. I have also tried to follow all the steps outlined above, changed permissions, etc. and the same thing happens. Any ideas?

Highlighted

@hughmichell 

 

...same here. I haven't the faintest idea what else I can do. I have to work online with my colleagues because of the Corona crisis, but I can't because the teams app doesn't work. I have also tried everything that has been recommended here.

Highlighted

Hooray, error found! There are 2 library folders (of course!). Go to HD > Users > (yourname) > Library > Application Support > Microsoft. Set the permissions to your username: sudo chown (yourname) /Users/yourname/Library/Application\ Support/Microsoft

Teams works now

Highlighted

@Angel1060 could you please explain HOW to do what you have described thanks?

All I have in this folder is a Silverlight folder????

How do I set the permissions to your username: sudo chown (yourname) /Users/yourname/Library/Application\ Support/Microsoft?

Highlighted

@Angel1060 could you please explain the steps required to do this?  I am also having the same issue and went looking for the library folder under my username but I don't have one?