Bug Related to Get Async

Hi all!

I am refactoring a project.
The main goal of the refactoring is to get rid of Promise framework and replace it with Swift modern concurrency.
The project has a low coupling principle violation, that's why I cannot make atomic commits to narrow the number of bug reasons down.
At the current stage, I started refactoring properties to give them an async getter where needed, which lead to a compiler error.

The complier message is as follows:

Please submit a bug report (https://swift.org/contributing/#reporting-bugs) and include the crash backtrace.
Stack dump without symbol names (ensure you have llvm-symbolizer in your PATH or set the environment var `LLVM_SYMBOLIZER_PATH` to point to it):
0  swift-frontend           0x0000000109f8ff3c llvm::sys::PrintStackTrace(llvm::raw_ostream&, int) + 56
1  swift-frontend           0x0000000109f8f0f8 llvm::sys::RunSignalHandlers() + 112
2  swift-frontend           0x0000000109f90544 SignalHandler(int) + 360
3  libsystem_platform.dylib 0x000000019385f584 _sigtramp + 56
4  swift-frontend           0x0000000107b0fdf4 llvm::ValueEnumerator::ValueEnumerator(llvm::Module const&, bool) + 6044
5  swift-frontend           0x0000000107af29a8 (anonymous namespace)::ModuleBitcodeWriterBase::ModuleBitcodeWriterBase(llvm::Module const&, llvm::StringTableBuilder&, llvm::BitstreamWriter&, bool, llvm::ModuleSummaryIndex const*) + 60
6  swift-frontend           0x0000000107ae5b10 llvm::BitcodeWriter::writeModule(llvm::Module const&, bool, llvm::ModuleSummaryIndex const*, bool, std::__1::array<unsigned int, 5ul>*) + 288
7  swift-frontend           0x0000000107af042c llvm::WriteBitcodeToFile(llvm::Module const&, llvm::raw_ostream&, bool, llvm::ModuleSummaryIndex const*, bool, std::__1::array<unsigned int, 5ul>*) + 488
8  swift-frontend           0x0000000104d60364 swift::performLLVM(swift::IRGenOptions const&, swift::DiagnosticEngine&, llvm::sys::SmartMutex<false>*, llvm::GlobalVariable*, llvm::Module*, llvm::TargetMachine*, llvm::StringRef, llvm::vfs::OutputBackend&, swift::UnifiedStatsReporter*) + 180
9  swift-frontend           0x0000000104d68e70 (anonymous namespace)::LLVMCodeGenThreads::Thread::run() + 156
10 swift-frontend           0x0000000104d68dc8 (anonymous namespace)::LLVMCodeGenThreads::runThread(void*) + 12
11 libsystem_pthread.dylib  0x000000019382ef94 _pthread_start + 136
12 libsystem_pthread.dylib  0x0000000193829d34 thread_start + 8

Could you please give me a hand? Any help is highly appreciated

Please follow the link from the compiler crash: https://swift.org/contributing/#reporting-bugs and report a bug with some more context of the code and preferably a small reproducer.

Please include what Swift and/or Xcode version you're using etc.

We can't really help out from just such message on the forums, we'll need more context than just this crash backtrace -- what's the source change that made this start happening etc.

1 Like

Thanks. Got it. Yeah, the question does not seem to be detailed enough.
Either way, looks like my issue is identical to this [Concurrency] Task created from local variable `didSet` leads to `dispatch_assert_queue_fail` · Issue #76068 · swiftlang/swift · GitHub
So I think I have to delete the post