14

While I'm developing Lightning Components I usually have this workflow:

  • First I change my code
  • Then I save it
  • Finally I reload LEX to get the newest version of the component rendered via F5 to see and debug the results.

This is my usual development cycle.

But also when I'm working in LEX as user, I very often use F5 to reload everything. This I do unrelated from development, just to ensure that I see the most recent data.

Starting with Winter 18 I noticed a very odd behavior in at least two different flavors:

a) Regular freeze

Every second time I reload LEX via F5, it get stuck. It's freezing completely and the page becomes unresponsive.

b) Random freezings

Just using LEX (while development or just as normal user) and refreshing with F5 from time to time randomly the same freezing is happening.

In both cases a+b: there is only the release icon visible at that time:

enter image description here

Some time later a Page Unresponsive popup appears:

enter image description here

With Summer 17 this never happened. I cleared the browser cache, uninstalled all browser extensions, installed even different versions of Chrome, but none of this helped.

What is going on here?

At the network tab the freezing happen very early while loading one.app

enter image description here

Update

At least for scenario a) described above I found the reason - see it in the answer below. But this is not all: still b) is happening from time to time but it is rare enough to prevent me for debugging it to nail it down.

Also my colleagues and others here are reporting similar effects. It is happening irregularly. And it's happening on standard pages without any custom components, too. So in my opinion there is a serious bug in W18. Possibly multiple things can cause that - but it's nearly impossible for us to investigate that deeper.

Please feel free to add your scenarios (in the question, in comments or as answers if you solved such freezings).

  • if you check your network tab, can you spot where the response hangs or what resource might be causing this? – glls Oct 16 '17 at 16:24
  • fyi. shift-esc opens chromes task manager, where you can stop the failing tab. – Basti Oct 16 '17 at 16:26
  • I remove the part of URL after one/one.app to get rid of refresh issue. Still not a permanent solution. Helps, sometimes. – Raul Oct 16 '17 at 16:28
  • 1
    @Basti no news from my side. I still have this issue happening randomly not revealing any pattern. So without repro it'll be hard for me to log a case. Also I think that this issue is likely caused by multiple independent reasons. I would appreciate if someone from Salesforce could comments on this with some insights. They must know about this for sure because it happens too often to ignore. – Uwe Heim Oct 25 '17 at 10:28
  • 2
    @Basti not sure, if really all issues will be fixed, but lets hope for some and we need to review the situation after that Patch 12 is deployed. In the meantime I'm falling back to Chrome 59, because it was stated to affect only Chrome 60+. Chrome 59 for me is a viable option but turning on that "persistent cache" is absolute not usable for me. Not finished testing yet, but Chrome 59 seems working OK - no crash so far. – Uwe Heim Oct 25 '17 at 11:45
2

Just received this mail from Salesforce, seems to be fixed in all instances:

Dear Sebastian:

We are pleased to notify you that the following Known Issue has been resolved: Chrome 60 and above crashes when "Enable secure and persistent browser caching to improve performance" is unchecked in Session Settings on Winter '18. Thank you for being patient while we worked to address this issue. Please feel free to reach out to Customer Support if you have further questions. Sincerely, Salesforce Success Team

And I can confirm, that I can't reproduce it anymore. Not with the Home page and not with a custom Component page.

7

Scenario a) "Regular freeze" ONLY (using Chrome v60.0+)

I turned out that the reason was the way how I was starting LEX...

Because I like to use Aloha (Salesforce Classic) and LEX at the same time, I never used the Menu "My Name" > Switch to Lightning Experience. There are lots of reasons to work in both works in parallel. My way to start LEX was to simply use a link pointing to /one/one.app

What I had then, was kind of a hybrid state: on user level I was still an Aloha user. I just run LEX by link. Now I had several Aloha-tabs running side-by-side with several LEX-tabs. I liked that very much. A REAL switch to LEX causes unwanted jumps of some my opened Aloha-tabs to reload in LEX.

I don't now the exact reasons why, but the crash and freezing does not happen, if I use the standard switch mechanism. I don't like it, but for now that "normal" way to switch the different themes is my "workaround".

Also I have tried to change my link to /one/one.app?source=aloha#/home, but this seems not to help. For now it looks like we really need to be Lightning Users to avoid the freezing. For what I've observed, this behavior is very good to reproduce.

I would highly appreciate it if Salesforce could allow us to use just two different URLs to access and switch between the two experiences dynamically and (more importantly!) to use them in parallel peacefully coexisting in tabs like it worked fine until Winter 18.

As said above there is also at least scenario b) and this is not the only reason for such freezings. If you have similar experiences, let's collect them here. This caused my a lot of headache and I'm sure a list of things to check will help others.

  • 1
    I use the same working method - use LEX and classic through changing the url. And I found another problem: if I use in apex UserInfo.getUiThemeDisplayed() or UserInfo.getUiTheme() - these methods do not return the actual UI on my browser, they return the definition in my user if I changed the UI to Switch to Salesforce Classic or Switch to Lightning Experience - so if I am in classic mode but my page shows LEX because of using the /one/one.app url, these methods return Theme3 -this is a bug I think – Itai Shmida Oct 17 '17 at 14:49
  • Hm this did not resolve it for me. When I reload my page with a view nested lightning components, it crashes just randomly after a few reloads. – Basti Oct 18 '17 at 13:15
  • @Basti beside this observation about my "hybrid mode loading" I can confirm that the freezings can still happen. Even if I start LEX in the "Standard Way" via "Switch to Lightning Experience" from time to time freezings will occur. But actually for me they are not reproducible. Too many loose ends. They happen randomly and rarely - while the issue above (starting LEX in hybrid mode just via URL) is perfectly reproducible. It happens exactly every 2nd reload via F5. Bottom-line: something is still NOT OK! – Uwe Heim Oct 18 '17 at 15:56
2

We have had this issue in Chrome for some of our developers. Salesforce has told us that this is an issue with Chrome specifically and the fix for us was to enable caching via Session Settings in Setup:

Session Settings

We previously had this disabled as it was caching our components and causing problems in development, but these issues seem to be resolved now.

  • 1
    enable that would be no option for me because then you never can be sure to see the most recent data. I found that the cache invalidation is below usability the last time I've tried around 5 months ago. E.g. changing the owner of a record showed the old owner after F5 and much much more. So I might need to test it again, but I'm super sceptical. Also if there is this option to turn it on/off neither setting should end in freezings. – Uwe Heim Oct 17 '17 at 18:42
  • I agree. We were faced with the same situation. They recommended we develop in firefox and then test in chrome with caching enabled. You could always try with caching enabled and see if the issues you were having 5 months ago are still a problem. – Dan Nicholson Oct 18 '17 at 10:56
  • I can at least confirm, that even if I start LEX in the "Standard Way" via "Switch to Lightning Experience" from time to time freezings will occur. But actually they are not reproducible. They happen randomly and rarely - while the issue above (starting LEX in hybrid mode just via URL) is perfectly reproducible. It happens exactly every 2nd reload via F5. So something is still NOT OK! – Uwe Heim Oct 18 '17 at 15:53
  • This is now listed on the SF issues page: success.salesforce.com/issues_view?id=a1p3A000000mCfPQAU – Aidan Oct 23 '17 at 12:55
  • Chrome is locking up for me regularly even with caching enabled. – doublesharp Oct 23 '17 at 18:50
2

Any Scenario: use Chrome <= v59.0 or Mozilla Firefox

Now Known Issue has been created by Salesforce confirming the situation: https://success.salesforce.com/issues_view?id=a1p3A000000mCfPQAU

As stated there this issue is caused by LEX with Chrome v60.0+.

I can confirm, that using Chrome v59.0 (or v57.0) now for a couple of hours not one of these freezing occurred. Also from my colleagues using Firefox I got the indication, that none of such freezing are happening.

0

I found that it was one of my apex controller methods.

It was getting hung up on one of its queries and that would cause the page to crash. I had 'WHERE Id = :var' and var was blank or null it caused this hanging problem. I would open up the network tab in chrome console to check if any apex controller methods are hanging.

When I put an if-statement to only query if var is not null, it does not hang anymore.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.