rlz_lib tries to read JSON file on thread that disallows IO |
||||||||||
Issue descriptionThis is seen on a debug ChromeOS build on Linux: [641:662:0807/160030.302640:FATAL:thread_restrictions.cc(38)] Check failed: false. Function marked as IO-only was called from a thread that disallows IO! If this thread really should be allowed to make IO calls, adjust the call to base::ThreadRestrictions::SetIOAllowed() in this thread's startup. If this task is running inside the TaskScheduler, the TaskRunner used to post it needs to have MayBlock() in its TaskTraits. #0 0x7f7bf4e14f7d base::debug::StackTrace::StackTrace() #1 0x7f7bf4e134fc base::debug::StackTrace::StackTrace() #2 0x7f7bf4e9cb2d logging::LogMessage::~LogMessage() #3 0x7f7bf5046834 base::ThreadRestrictions::AssertIOAllowed() #4 0x7f7bf4e6c533 base::OpenFile() #5 0x7f7bf4e62f77 base::ReadFileToStringWithMaxSize() #6 0x7f7bf4e63354 base::ReadFileToString() #7 0x7f7bf4e7df91 JSONFileValueDeserializer::ReadFileToString() #8 0x7f7bf4e7e2cb JSONFileValueDeserializer::Deserialize() #9 0x55df823b12f0 rlz_lib::RlzValueStoreChromeOS::ReadStore() #10 0x55df823b11ab rlz_lib::RlzValueStoreChromeOS::RlzValueStoreChromeOS() #11 0x55df823b57e1 rlz_lib::ScopedRlzValueStoreLock::ScopedRlzValueStoreLock() #12 0x55df823bcd6f rlz_lib::GetAccessPointRlz() #13 0x55df8854ac65 rlz::RLZTracker::GetAccessPointRlzImpl() #14 0x55df88547970 rlz::RLZTracker::GetAccessPointRlz() #15 0x55df8854d687 _ZN4base8internal13FunctorTraitsIPFbN7rlz_lib11AccessPointEPNSt3__112basic_stringItNS_20string16_char_traitsENS4_9allocatorItEEEEEvE6InvokeIJRKS3_RKSA_EEEbSC_DpOT_ #16 0x55df8854d640 _ZN4base8internal13FunctorTraitsINS0_18IgnoreResultHelperIPFbN7rlz_lib11AccessPointEPNSt3__112basic_stringItNS_20string16_char_traitsENS5_9allocatorItEEEEEEEvE6InvokeIRKSE_JRKS4_RKSB_EEEvOT_DpOT0_ #17 0x55df8854d5ed _ZN4base8internal12InvokeHelperILb0EvE8MakeItSoIRKNS0_18IgnoreResultHelperIPFbN7rlz_lib11AccessPointEPNSt3__112basic_stringItNS_20string16_char_traitsENS7_9allocatorItEEEEEEEJRKS6_RKSD_EEEvOT_DpOT0_ #18 0x55df8854d59d _ZN4base8internal7InvokerINS0_9BindStateINS0_18IgnoreResultHelperIPFbN7rlz_lib11AccessPointEPNSt3__112basic_stringItNS_20string16_char_traitsENS6_9allocatorItEEEEEEEJS5_SC_EEEFvvEE7RunImplIRKSF_RKNS6_5tupleIJS5_SC_EEEJLm0ELm1EEEEvOT_OT0_NS_13IndexSequenceIJXspT1_EEEE #19 0x55df8854d4ac _ZN4base8internal7InvokerINS0_9BindStateINS0_18IgnoreResultHelperIPFbN7rlz_lib11AccessPointEPNSt3__112basic_stringItNS_20string16_char_traitsENS6_9allocatorItEEEEEEEJS5_SC_EEEFvvEE3RunEPNS0_13BindStateBaseE #20 0x7f7bf4dc31d1 _ZNO4base8CallbackIFvvELNS_8internal8CopyModeE0ELNS2_10RepeatModeE0EE3RunEv #21 0x7f7bf4e198dd base::debug::TaskAnnotator::RunTask() #22 0x7f7bf50164d7 base::internal::TaskTracker::PerformRunTask() #23 0x7f7bf501832c base::internal::TaskTrackerPosix::PerformRunTask() #24 0x7f7bf5014efc base::internal::TaskTracker::RunNextTask() #25 0x7f7bf50029d8 base::internal::SchedulerWorker::Thread::ThreadMain() #26 0x7f7bf5023cb1 base::(anonymous namespace)::ThreadFunc() #27 0x7f7bf544f184 start_thread #28 0x7f7bdb482ffd clone
,
Aug 7 2017
I neither wrote the chromeos rlz code, nor have I worked on rlz in many years.
,
Aug 8 2017
thakis: As rlz/ owner, could you please recommend an owner to this issue?
,
Aug 8 2017
,
Aug 9 2017
On bisect, the culprit is https://codereview.chromium.org/2949263003 Assigning bug to +rogerta
,
Aug 9 2017
,
Aug 9 2017
Adding another stacktrace: [124974:125003:0808/180629.704520:FATAL:thread_restrictions.cc(38)] Check failed: false. Function marked as IO-only was called from a thread that disallows IO! If this thread really should be allowed to make IO calls, adjust the call to base::ThreadRestrictions::SetIOAllowed() in this thread's startup. If this task is running inside the TaskScheduler, the TaskRunner used to post it needs to have MayBlock() in its TaskTraits. #0 0x7ffba53b94ec base::debug::StackTrace::StackTrace() #1 0x7ffba53dee2c logging::LogMessage::~LogMessage() #2 0x7ffba545b879 base::ThreadRestrictions::AssertIOAllowed() #3 0x7ffba53d0a3b base::OpenFile() #4 0x7ffba53cd17e base::ReadFileToStringWithMaxSize() #5 0x7ffba53d54ec JSONFileValueDeserializer::Deserialize() #6 0x5567cfb80d4d rlz_lib::RlzValueStoreChromeOS::ReadStore() #7 0x5567cfb829a2 rlz_lib::ScopedRlzValueStoreLock::ScopedRlzValueStoreLock() #8 0x5567cfb84a70 rlz_lib::GetAccessPointRlz() #9 0x5567d170ffdb rlz::RLZTracker::GetAccessPointRlzImpl() #10 0x5567d170eb78 rlz::RLZTracker::GetAccessPointRlz() #11 0x7ffba53b9d90 base::debug::TaskAnnotator::RunTask() #12 0x7ffba544711d base::internal::TaskTracker::PerformRunTask() #13 0x7ffba54477b7 base::internal::TaskTrackerPosix::PerformRunTask() #14 0x7ffba5446872 base::internal::TaskTracker::RunNextTask() #15 0x7ffba5441ad4 base::internal::SchedulerWorker::Thread::ThreadMain() #16 0x7ffba545162f base::(anonymous namespace)::ThreadFunc() #17 0x7ffba5532184 start_thread #18 0x7ffb9a9dbffd clone
,
Aug 9 2017
,
Aug 9 2017
Fix incoming https://chromium-review.googlesource.com/609105
,
Aug 9 2017
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/3b78dd54d9897db94dd8b2968dabb765bb017ca2 commit 3b78dd54d9897db94dd8b2968dabb765bb017ca2 Author: Gabriel Charette <gab@chromium.org> Date: Wed Aug 09 19:16:18 2017 Add missing MayBlock() trait to RLZTracker's background_task_runner. TBR=fdoray@chromium.org Bug: 753145 Change-Id: If3c8d2c660333185b18e6ffb6bc336eb7c30986b Reviewed-on: https://chromium-review.googlesource.com/609105 Reviewed-by: Gabriel Charette <gab@chromium.org> Commit-Queue: Gabriel Charette <gab@chromium.org> Cr-Commit-Position: refs/heads/master@{#493091} [modify] https://crrev.com/3b78dd54d9897db94dd8b2968dabb765bb017ca2/components/rlz/rlz_tracker.cc
,
Aug 9 2017
,
Aug 14 2017
,
Jan 22 2018
|
||||||||||
►
Sign in to add a comment |
||||||||||
Comment 1 by xhw...@chromium.org
, Aug 7 2017