Post

Replies

Boosts

Views

Activity

Reply to iOS simulator ImageLoader startup crash on Catalina 10.15.2, Xcode 11.3
#00x00007fff523d5bea in __abort_with_payload ()#10x00007fff523d74f3 in abort_with_payload_wrapper_internal ()#20x00007fff523d74a3 in abort_with_reason ()#30x00007fff52469974 in pthread_self.cold.1 ()#40x00007fff52462fe3 in pthread_self ()#50x000000010f3f316b in __tsan::cur_thread() ()#60x000000010f3c8985 in wrap_sysctlbyname ()#70x00007fff52470331 in assert_simulator_supported_host ()#80x00007fff4ff167c1 in libSystem_initializer ()#90x000000010f2fa3a7 in ImageLoaderMachO::doModInitFunctions(ImageLoader::LinkContext const&) ()#100x000000010f2fa7b8 in ImageLoaderMachO::doInitialization(ImageLoader::LinkContext const&) ()#110x000000010f2f59a2 in ImageLoader::recursiveInitialization(ImageLoader::LinkContext const&, unsigned int, char const*, ImageLoader::InitializerTimingList&, ImageLoader::UninitedUpwards&) ()#120x000000010f2f590f in ImageLoader::recursiveInitialization(ImageLoader::LinkContext const&, unsigned int, char const*, ImageLoader::InitializerTimingList&, ImageLoader::UninitedUpwards&) ()#130x000000010f2f590f in ImageLoader::recursiveInitialization(ImageLoader::LinkContext const&, unsigned int, char const*, ImageLoader::InitializerTimingList&, ImageLoader::UninitedUpwards&) ()#140x000000010f2f590f in ImageLoader::recursiveInitialization(ImageLoader::LinkContext const&, unsigned int, char const*, ImageLoader::InitializerTimingList&, ImageLoader::UninitedUpwards&) ()#150x000000010f2f47a6 in ImageLoader::processInitializers(ImageLoader::LinkContext const&, unsigned int, ImageLoader::InitializerTimingList&, ImageLoader::UninitedUpwards&) ()#160x000000010f2f4846 in ImageLoader::runInitializers(ImageLoader::LinkContext const&, ImageLoader::InitializerTimingList&) ()#170x000000010f2e9046 in dyld::initializeMainExecutable() ()#180x000000010f2ed0fc in dyld::_main(macho_header const*, unsigned long, int, char const**, char const**, char const**, unsigned long*) ()#190x000000010f2e81cd in start_sim ()#200x000000011db508cc in dyld::useSimulatorDyld(int, macho_header const*, char const*, int, char const**, char const**, char const**, unsigned long*, unsigned long*) ()#210x000000011db4e575 in dyld::_main(macho_header const*, unsigned long, int, char const**, char const**, char const**, unsigned long*) ()#220x000000011db49227 in dyldbootstrap::start(dyld3::MachOLoaded const*, int, char const**, dyld3::MachOLoaded const*, unsigned long*) ()#230x000000011db49025 in _dyld_start ()
Dec ’19
Reply to Task, onAppear, onDisappear modifiers run twice
I was able to reproduce this on iOS 17 by animating the view transitions by changing the top level MyApp to: @main struct MyApp: App { @State private var store = Store() var body: some Scene { WindowGroup { if store.shown { ContentView() .transition(.move(edge: .bottom)) } else { EmptyView() .transition(.move(edge: .bottom)) } } .environment(store) } } and the DetailView to: struct DetailView: View { @Environment(Store.self) private var store var body: some View { Button("Pop to top") { withAnimation { store.shown = false } } .task { print("DetailView task executed") } .onAppear { print("DetailView appeared") } .onDisappear { print("DetailView disappeared") } } } By the way, this only happens in this simple reproducer if the DetailView is shown from the ContentView within the NavigationView.
Oct ’24