[FATAL:local_extension_cache.cc(549)] Check failed: 0. Cache contains newer or the same version |
|||||||
Issue descriptionHow to reproduce: Check out ToT chrome (I used internal version, but it doesn't seem to be important), build debug version and deploy to device. Add new user. Chrome will crash with: [27659:27659:0523/202053:FATAL:local_extension_cache.cc(549)] Check failed: 0. Cache contains newer or the same version #0 0x7feb905b2d2b base::debug::StackTrace::StackTrace() #1 0x7feb905f1dcf logging::LogMessage::~LogMessage() #2 0x7feb988fb69b extensions::LocalExtensionCache::OnCacheEntryInstalled() #3 0x7feb97b43428 _ZN4base8internal15RunnableAdapterIMN3gcm11GCMKeyStoreEFvRKSsS5_bRKNS_8CallbackIFvRKNS2_7KeyPairES5_ELNS0_8CopyModeE1EEEEE3RunIPS3_JS5_S5_RKbSE_EEEvOT_DpOT0_ #4 0x7feb97b424c9 _ZN4base8internal12InvokeHelperILb1EvNS0_15RunnableAdapterIMN3gcm11GCMKeyStoreEFvRKSsS6_bRKNS_8CallbackIFvRKNS3_7KeyPairES6_ELNS0_8CopyModeE1EEEEEEE8MakeItSoINS_7WeakPtrIS4_EEJS6_S6_RKbSF_EEEvSI_T_DpOT0_ #5 0x7feb9890145f _ZN4base8internal7InvokerINS_13IndexSequenceIJLm0ELm1ELm2ELm3ELm4EEEENS0_9BindStateINS0_15RunnableAdapterIMN10extensions19LocalExtensionCacheEFvRKSsRKNS7_13CacheItemInfoEbRKNS_8CallbackIFvRKNS_8FilePathEbELNS0_8CopyModeE1EEEEEEFvPS7_S9_SC_bSL_EJRNS_7WeakPtrIS7_EES9_SA_RbSL_EEENS0_12InvokeHelperILb1EvSO_EEFvvEE3RunEPNS0_13BindStateBaseE #6 0x7feb8f8a59a6 base::Callback<>::Run() #7 0x7feb907191d9 base::debug::TaskAnnotator::RunTask() #8 0x7feb9060724f base::MessageLoop::RunTask() #9 0x7feb90607372 base::MessageLoop::DeferOrRunPendingTask() #10 0x7feb90607961 base::MessageLoop::DoWork() #11 0x7feb9059277e base::MessagePumpLibevent::Run() #12 0x7feb90606e63 base::MessageLoop::RunHandler() #13 0x7feb9067404f base::RunLoop::Run() #14 0x7feb9a01d61b ChromeBrowserMainParts::MainMessageLoopRun() #15 0x7feb96511aed content::BrowserMainLoop::RunMainMessageLoopParts() #16 0x7feb95e79395 content::BrowserMainRunnerImpl::Run() #17 0x7feb95e78796 content::BrowserMain() #18 0x7feb9052fbc8 content::RunNamedProcessTypeMain() #19 0x7feb90530dca content::ContentMainRunnerImpl::Run() #20 0x7feb9052eee0 content::ContentMain() #21 0x7feb8f79b52a ChromeMain #22 0x7feb8f79b4c0 main #23 0x7feb8d008fb6 __libc_start_main #24 0x7feb8f79b34b <unknown>
,
May 24 2016
,
Jun 14 2016
It seems like this would be pretty simple to bisect?
,
Dec 16 2016
This is still a major nuisance when running on CrOS with dcheck_always_on = true (e.g. to look for other unexpected DCHECKs :) ). This isn't a good use of a DCHECK since it's inside a condition that we handle. Scanning the code, it doesn't even look like an entirely invalid condition - the message is "Cache contains newer or the same version", and we log the same message as a WARNING in line 170. I would propose logging a WARNING here, at least for now, and maybe filing and referencing a follow up issue.
,
Dec 16 2016
I don't know why this DCHECK is reproduced reliably for me always with the same extension ID - "oedeeodfidgoollimchfdnbmhcpnklnd"; the cache initially contains version "0.76", and then a DCHECK is hit while trying to install version "0.74". Maybe it's because I'm testing a ToT build or because this extension was rolled back by Omaha. Looking at the code, I actually think the DCHECK may be reasonable, because probably the relevant checkes should have been performed upper in the stack, before reaching LocalExtensionCache::OnCacheEntryInstalled (which works after the extension crx gets installed into the cache directory). For instance, does anybody understand why is LocalExtensionCache::PutExtension calling FindExtension with the hash of the considered extension instead of empty string? This makes the subsequent condition with NewerOrSame pretty much useless unless the cached version is equal to the considered version. https://cs.chromium.org/chromium/src/chrome/browser/extensions/updater/local_extension_cache.cc?l=167
,
Dec 16 2016
Strictly speaking, {D}CHECK and NOTREACHED should only be used for situations that should be logically impossible, e.g. unexpected input arguments to a function or return results from a function. We are also deprecating {D}CHECK << message.
That fact that it is not clear by inspection whether this failure case is invalid indicates that we shouldn't be using CHECK, we should LOG(ERROR) or LOG(FATAL). The fact that it is handled suggests LOG(ERROR) would be sufficient, with a bug filed to investigate the failure.
,
Feb 1 2017
I've committed the patch to replace DCHECK with LOG(WARNING): http://crrev.com/2662863003. Though this still leaves the question about the correctness of the logic in the LocalExtensionCache class (see e.g. comment 5 above).
,
May 15 2018
|
|||||||
►
Sign in to add a comment |
|||||||
Comment 1 by asargent@chromium.org
, May 24 2016Owner: ----