APIs & Integrations

aleksandr-swoop
Participant

leadflows.js overrides window.onerror

SOLVE

https://js.hsleadflows.net/leadflows.js overrides existing window.onerror handler. 

It breaks our integration with error logging library Rollbar.

leadflows.js should keep existing window.onerror handler and call it on error.

 

Here is old similar question https://community.hubspot.com/t5/APIs-Integrations/How-to-disable-error-logging-in-LeadIn/m-p/238152 But looks like it was never resolved.

 

I don't know what label to choose for my question. None of them make sense to me. But label field is required.

1 Accepted solution
WendyGoh
Solution
HubSpot Employee
HubSpot Employee

leadflows.js overrides window.onerror

SOLVE

Hey @aleksandr-swoop,

 

Just an update here! Our internal team has pushed a fix for this. Could you check and see if you're seeing seeing the issue?

View solution in original post

0 Upvotes
11 Replies 11
WendyGoh
HubSpot Employee
HubSpot Employee

leadflows.js overrides window.onerror

SOLVE

Hey @aleksandr-swoop,

 

Could you share more in details and provide screenshots on where you're seeing that leadflow.js overrides window.onerror? 

0 Upvotes
aleksandr-swoop
Participant

leadflows.js overrides window.onerror

SOLVE

Hey @WendyGoh!

 

Here is screenshot 

leadflows.png

 

Please let me know if you need more details.

0 Upvotes
WendyGoh
HubSpot Employee
HubSpot Employee

leadflows.js overrides window.onerror

SOLVE

Hey @aleksandr-swoop,

 

Thanks for sharing the screenshot with me. 

 

I'll have to check in with our internal team on this and I'll keep you posted here!

0 Upvotes
aleksandr-swoop
Participant

leadflows.js overrides window.onerror

SOLVE

Hello @WendyGoh!

 

Any update on this?

 

Thanks,

Aleksandr

0 Upvotes
WendyGoh
HubSpot Employee
HubSpot Employee

leadflows.js overrides window.onerror

SOLVE

Hey @aleksandr-swoop,

 

Just an update here. I'm able to confirm that currently this is how HubSpot manage errors. That said, may be your team can try exploring this option -https://errorception.com/docs/onerror to work around the problem.

 

Let me know your thoughts!

0 Upvotes
aleksandr-swoop
Participant

leadflows.js overrides window.onerror

SOLVE

Hey @WendyGoh 

 

Thank you for the article! But looks like this how HubSpot should implement it.

We use Rollbar library which is out control and it relies on window.onerror. It handles window.onerror correct way as described in article. But then HubSpot just overrides it.

 

We cannot delay and load HubSpot first and then Rollbar.

 

Thanks,

Aleksandr

0 Upvotes
WendyGoh
HubSpot Employee
HubSpot Employee

leadflows.js overrides window.onerror

SOLVE

Hey @aleksandr-swoop,

 

Gotcha. Thank you for the clarification.

 

I'll check in with my team and will definitely keep you posted here. 

0 Upvotes
aleksandr-swoop
Participant

leadflows.js overrides window.onerror

SOLVE

Hey @WendyGoh!

 

How is it going? It stuck here for couple of weeks.

 

Thanks,

Aleksandr

0 Upvotes
WendyGoh
HubSpot Employee
HubSpot Employee

leadflows.js overrides window.onerror

SOLVE

Hey @aleksandr-swoop,

 

I'd like to assure you that our internal team is aware of this issue and is looking to push a fix for this. I'll keep you posted once there's an update. 

0 Upvotes
WendyGoh
Solution
HubSpot Employee
HubSpot Employee

leadflows.js overrides window.onerror

SOLVE

Hey @aleksandr-swoop,

 

Just an update here! Our internal team has pushed a fix for this. Could you check and see if you're seeing seeing the issue?

0 Upvotes
aleksandr-swoop
Participant

leadflows.js overrides window.onerror

SOLVE

Hi @WendyGoh!

 

Thank you! I confirm it is fixed now.

 

Thanks,

Aleksandr

0 Upvotes