Ionic-app-scripts: ionic serve on file save loads an older build than the latest

Created on 21 Nov 2017  路  6Comments  路  Source: ionic-team/ionic-app-scripts

Short description of the problem:

Since the latest update ionic serve occasionally loads an older build on file save. So when I am at the nth version and hit save, in my browser the n-1th version gets loaded instead of n+1.

What behavior are you expecting?

Live-reload works properly and always the newest version gets loaded.

Steps to reproduce:

  1. Start building a bigger app with ionic-app-script
  2. Keep doing changes and reloading the app
  3. See that older version of your app gets reloaded occasionally
  4. Re-start ionic serve to fix the problem

Which @ionic/app-scripts version are you using?

3.1.2

Other information:

It seems to happen with bigger apps only. Time varies. Some apps produce it on almost every file save. Some much rarely like every 100th.

Most helpful comment

This is affecting me consistently .. often wasting a lot of time when I don't realize that I haven't in-fact introduced a bug / failed but am getting served an older build. Is there any way to disable ionic caching older builds?

All 6 comments

This issue is really annoying, I keep having to reserve just to get the latest version of the build. Its also really hard to reproduce.

It's true, I have experienced this exact same issue myself. It's random, but it should happen often enough for someone to reproduce the error pretty quickly. I've lost count of how many times this happened in the past few weeks.

This is affecting me consistently .. often wasting a lot of time when I don't realize that I haven't in-fact introduced a bug / failed but am getting served an older build. Is there any way to disable ionic caching older builds?

do you guys know how to reproduce it in a minimal code base and where to debug it?
I've suffered with it for a long time and wanna take some time to look through the source code.

I have the same problem

Was this page helpful?
0 / 5 - 0 ratings