Skip to main content

Notifications

Announcements

No record found.

Microsoft Dynamics CRM (Archived)

"Failed to execute 'postMessage' on 'Window': 2 arguments required, but only 1 present" error in CRM Online

(0) ShareShare
ReportReport
Posted on by Microsoft Employee

Folks over the past week or so, we've been seeing these javascript errors start appearing on our sandbox instances of CRM Online.

The error appears to originate in the JsProvider.ashx and cdnavailabilityworker.js files which are internal to the CRM.

My question is what causes these errors?  Are these a result of Microsoft updating our CRM Online site and introducing a bug or is it something we've done on our end? It seems to be on Microsoft's side since we have an out of box instance (organization) without any customizations that we created a month or so ago which has the same errors.  The issue shows up in Chrome and IE and after clearing the browser cache.

Is this a known issue?  Does this require a support incident for MS to resolve?

Stack trace:

JsProvider.ashx?ids=346338581-1481678315&ver=1365697046:35

Uncaught TypeError: Failed to execute 'postMessage' on 'Window': 2 arguments required, but only 1 present. in devmaster.crm.dynamics.com/.../cdnavailabilityworker.js at 8:13

TypeError: Failed to execute 'postMessage' on 'Window': 2 arguments required, but only 1 present.
    at XMLHttpRequest.xmlHttpRequest.onreadystatechange (cdnavailabilityworker.js?ver=1365697046:8)
    at self.onmessage (cdnavailabilityworker.js?ver=1365697046:11)
window.onerror @ JsProvider.ashx?ids=346338581-1481678315&ver=1365697046:35
self.onmessage @ cdnavailabilityworker.js?ver=1365697046:11
postMessage (async)
MarsIframe.SendPostMessage @ MarsIframe.js:637
MarsIframe.authenticateMarsUser @ MarsIframe.js:604
(anonymous) @ MarsIframe.js:548
fire @ jquery-2.1.1.js:3104
fireWith @ jquery-2.1.1.js:3216
deferred.(anonymous function) @ jquery-2.1.1.js:3306
(anonymous) @ MarsIframe.js:433
fire @ jquery-2.1.1.js:3104
fireWith @ jquery-2.1.1.js:3216
deferred.(anonymous function) @ jquery-2.1.1.js:3306
(anonymous) @ MarsIframe.js:491
n @ bluebird.js:23
e._settlePromiseFromHandler @ bluebird.js:23
e._settlePromiseAt @ bluebird.js:23
e._settlePromises @ bluebird.js:23
r._drainQueue @ bluebird.js:22
r._drainQueues @ bluebird.js:22
drainQueues @ bluebird.js:22
attributes (async)
(anonymous) @ bluebird.js:23
r._queueTick @ bluebird.js:22
r.settlePromises @ bluebird.js:22
e._queueSettlePromises @ bluebird.js:23
e._fulfillUnchecked @ bluebird.js:23
e._fulfill @ bluebird.js:23
e._resolveCallback @ bluebird.js:23
(anonymous) @ bluebird.js:23
(anonymous) @ auth.js:227
window.callBackMappedToRenewStates.(anonymous function).window.callBackMappedToRenewStates.(anonymous function) @ adal.js:2
AuthenticationContext.handleWindowCallback @ VM1927 adal.js:2
(anonymous) @ VM1928 authRedirect.js:38
(anonymous) @ VM1928 authRedirect.js:43
12:57:32.011 MarsIframe.js:637 Uncaught TypeError: Failed to execute 'postMessage' on 'Window': 2 arguments required, but only 1 present.

*This post is locked for comments

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: "Failed to execute 'postMessage' on 'Window': 2 arguments required, but only 1 present" error in CRM Online

    For me, the error appeared in the debugger window while navigating to page.  Even if your error is slightly different, the root cause (in the cdnavailabilityworker.js file) is the same since you are seeing the postmessage 2 arguments required but only one present error.

  • M.V Profile Picture
    M.V 35 on at
    RE: "Failed to execute 'postMessage' on 'Window': 2 arguments required, but only 1 present" error in CRM Online

    Thanks for the confirmation. I thought this was the case but, couldn't be sure as I couldn't find the 135 update.

    Can you please confirm when you saw your error. I only see my error on the first time i do a quick search. Also the error i am seeing is different but still contains the 'Failedtoexecute'postMessage'on'Window':2argumentsrequired,butonly1present'

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: "Failed to execute 'postMessage' on 'Window': 2 arguments required, but only 1 present" error in CRM Online

    8.2.2.136 is newer than 8.2.2.135, so just install that.  Undoubtedly Microsoft made a small incremental change to 135 and bumped the version number up to 136.

  • M.V Profile Picture
    M.V 35 on at
    RE: "Failed to execute 'postMessage' on 'Window': 2 arguments required, but only 1 present" error in CRM Online

    Hi Jerry,

    i can only find the service update 8.2.2.136 not 135. could you please send a link

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: "Failed to execute 'postMessage' on 'Window': 2 arguments required, but only 1 present" error in CRM Online

    From what the service rep conveyed the 8.2.2.135 release has been applied to the online EU CRMs on 11/14 and NA on 11/15 so everyone should have the fix.

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: "Failed to execute 'postMessage' on 'Window': 2 arguments required, but only 1 present" error in CRM Online

    When we opened a support ticket, the Microsoft support rep applied a fix to the environment that resolved the issue.

  • billiardguy Profile Picture
    billiardguy 70 on at
    RE: "Failed to execute 'postMessage' on 'Window': 2 arguments required, but only 1 present" error in CRM Online

    Any news on this issue.  Looks like it's been fixed but not released yet.  Thanks.

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: "Failed to execute 'postMessage' on 'Window': 2 arguments required, but only 1 present" error in CRM Online

    Looks like the fix (which should be contained in 8.2.2.135) did work after all.  I had previously tested on an instance where the patch had not been applied.

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: "Failed to execute 'postMessage' on 'Window': 2 arguments required, but only 1 present" error in CRM Online

    Thanks, Jerry.  Hopefully the fix that is in 8.2.2.135 has been verified.  I say this because, according to our case interaction email, a fix was just applied to our Scale Group:

    "TROUBLESHOOT

    + Verified that issue is occurring in ‘out of the box’ Jscript cdnavailabilityworker.js;

    + Discussed with Product Group, who fix the error on this JavaScript;

    + Discussed with Operations team (DOC), who deployed the new JavaScript into Scale Group  NAMCRMLIVESG319;"

    Unfortunately, the fix did not work and I am still seeing the same exceptions in Chrome.

  • Suggested answer
    RE: "Failed to execute 'postMessage' on 'Window': 2 arguments required, but only 1 present" error in CRM Online

    I have just completed an email exchange with a member of the Product Team in Redmond. One of the upsides of being an MVP. This is a known issue that has been fixed in a pending release. It's not your javascript.

    The release that fixes this will be 8.2.2.135. I don't have a scheduled date yet from the product team, but once I do I will repost back here. It is supposed to be deployed very soon. This does pertain to the North American Data centers. I am seeking additional info on deployment to other data centers.

    In the interim go to Settings, Administration, Privacy and turn off ask for permission.

    FYI Thanks John K. for sharing the case #, it really expedited getting an answer.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Congratulations 2024 Spotlight Honorees

Kudos to all of our 2024 community stars! 🎉

Meet the Top 10 leaders for December

Congratulations to our December super stars! 🥳

Start Your Super User Journey

Join the ranks of our community heros! 🦹

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,711 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,458 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans