Giter Site home page Giter Site logo

kmm-networking-and-data-storage's Introduction

kmm-networking-and-data-storage's People

Contributors

danil-pavlov avatar katerinapetrova avatar pahill avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

kmm-networking-and-data-storage's Issues

Project not compatible with latest Android Studio version (Bumblebee 2021.1.1)

Upon cloning this project and opening in Android Studio, version Bumblebee 2021.1.1, an error is thrown during gradle sync. The error looks like this:
Screen Shot 2022-02-02 at 11 42 06 AM
"

When I select "Cancel (and update build files manually), I get the error The project is using an incompatible version (7.0.0-beta05) of the Android Gradle plugin. Upgrade to the latest version

When I select "Begin Upgrade" and then "Upgrade", it tries to build and then gives the error "Please initialize at least one Kotlin target in 'shared (:shared)'."

Unable to build due to unrecognized imports (Ktor)

Came here to finding a working example of importing Ktor into a shared KMM module (e.g. in commonMain) after spending hours with the tutorial and docs and trying multiple combinations of lib and IDE versions. Have also invalidated caches and restarted multiple times. Completely unable to import Ktor. And this project doesn't work for me either. Ktor also not recognized when I try to build this project. (Have also tried invalidating caches with this project).

Screen Shot 2021-04-07 at 9 18 07 AM

Can't run iosApp

Hi, I'm trying to run this project in android studio. But getting this error:

Error: Please check specified Xcode project file: can't grab Xcode schemes with /usr/bin/xcodebuild -project /Users/alfianyabdullah/Downloads/kmm-networking-and-data-storage-master/./iosApp/iosApp.xcodeproj -list

what should I do to fix that?

Branch "outdated"

I've noticed that the "final" branch is not using the same dependencies versions used in the tutorial

eg.

branch tutorial
Sql Delight 1.4.2 (gradle properties) 1.5.3
plugin.serialization 1.6.21 1.7.21

and some other discrepancies
eg. AppDatabase.sq

Unresolved reference: com.squareup.sqldelight.drivers.native.NativeSqliteDriver

Hi,

KMM looks awesome. KUDOS to you guys for making it happen.

I tried following the official Hands On exercise, but I quickly ran into a problem. Android Studio can't resolve the reference to com.squareup.sqldelight.drivers.native.NativeSqliteDriver.

I tried importing the final version of this project, but I got the same problem again.

This is my build file:

import org.jetbrains.kotlin.gradle.plugin.mpp.KotlinNativeTarget

plugins {
    kotlin("multiplatform")
    id("com.android.library")
    id("kotlin-android-extensions")
    kotlin("plugin.serialization")
    id("com.squareup.sqldelight")
}
group = "bg.dalexiev.kmmexample"
version = "1.0-SNAPSHOT"

val coroutinesVersion = "1.3.9-native-mt"
val serializationVersion = "1.0.0-RC"
val ktorVersion = "1.4.0"
val sqlDelightVersion: String by project

repositories {
    gradlePluginPortal()
    google()
    jcenter()
    mavenCentral()
}

kotlin {
    android()
    ios() {
        binaries {
            framework {
                baseName = "shared"
            }
        }
    }

    sourceSets {
        val commonMain by getting {
            dependencies {
                implementation("org.jetbrains.kotlinx:kotlinx-coroutines-core:$coroutinesVersion")

                implementation("org.jetbrains.kotlinx:kotlinx-serialization-core:$serializationVersion")

                implementation("io.ktor:ktor-client-core:$ktorVersion")
                implementation("io.ktor:ktor-client-serialization:$ktorVersion")

                implementation("com.squareup.sqldelight:runtime:$sqlDelightVersion")
            }
        }
        val commonTest by getting {
            dependencies {
                implementation(kotlin("test-common"))
                implementation(kotlin("test-annotations-common"))
            }
        }
        val androidMain by getting {
            dependencies {
                implementation("com.google.android.material:material:1.2.1")

                implementation("io.ktor:ktor-client-android:$ktorVersion")

                implementation("com.squareup.sqldelight:android-driver:$sqlDelightVersion")
            }
        }
        val androidTest by getting {
            dependencies {
                implementation(kotlin("test-junit"))
                implementation("junit:junit:4.12")
            }
        }
        val iosMain by getting {
            dependencies {
                implementation("io.ktor:ktor-client-ios:$ktorVersion")

                implementation("com.squareup.sqldelight:native-driver:$sqlDelightVersion")
            }
        }
        val iosTest by getting
    }
}

android {
    compileSdkVersion(29)
    sourceSets["main"].manifest.srcFile("src/androidMain/AndroidManifest.xml")
    defaultConfig {
        minSdkVersion(24)
        targetSdkVersion(29)
        versionCode = 1
        versionName = "1.0"
    }
    buildTypes {
        getByName("release") {
            isMinifyEnabled = false
        }
    }
}

sqldelight {
    database("AppDatabase") {
        packageName = "bg.dalexiev.kmmexample.shared.data.local"
    }
}

val packForXcode by tasks.creating(Sync::class) {
    group = "build"
    val mode = System.getenv("CONFIGURATION") ?: "DEBUG"
    val sdkName = System.getenv("SDK_NAME") ?: "iphonesimulator"
    val targetName = "ios" + if (sdkName.startsWith("iphoneos")) "Arm64" else "X64"
    val framework = kotlin.targets.getByName<KotlinNativeTarget>(targetName).binaries.getFramework(mode)
    inputs.property("mode", mode)
    dependsOn(framework.linkTask)
    val targetDir = File(buildDir, "xcode-frameworks")
    from({ framework.outputDirectory })
    into(targetDir)
}
tasks.getByName("build").dependsOn(packForXcode)

I tried to define separate iOS targets for the simulator and actual device, as proposed in this stackoverflow thread, but then gradle couldn't fine the iOSX64 target.

I tried on Android Studio 4.0.1, Android Studio 4.1.0-RC3 and IntelliJ IDEA.

Do you have any idea how to fix this or work around it?

Blank screen on real iOS device

I cloned the final branch of this project. When running it in the simulator, everything seems to work as expected and I can see the UI. Running on a real device (iPad mini 4, iOS 13.3), the screen is just blank after app startup. No errors are shown. Am I missing some configuration?

When replacing the body block like the following inside ContentView.swift, I can see the text.

var body: some View {
        /*NavigationView {
            listView()
            .navigationBarTitle("SpaceX Launches")
            .navigationBarItems(trailing:
                Button("Reload") {
                    self.viewModel.loadLaunches(forceReload: true)
            })
        }*/
        Text("Some content")
    }

Gradle throws error

I'm trying to follow the steps from the tutorial, however It throws an error when trying to build the project after I added the dependencies. I double checked and they seem to be properly added. I would appreciate if the project is being kept up to date with the latest KMM build configuration. I'm coming from the iOS ecosystem and I'm fairly new with gradle build system and Android platform.

I've attached the project and a screenshot.

I would highly appreciate any help 🙏 ,
Thank you

Screenshot 2022-04-23 at 00 18 41
Archive.zip

Question about Coroutine dependency

Good day, I just wanted to ask why we use org.jetbrains.kotlinx:kotlinx-coroutines-android:1.5.0-native-mt instead of the regular org.jetbrains.kotlinx:kotlinx-coroutines-android:$version here. Is there any specific reason or is it mandatory when working with KMM?

Thanks

iOS build fails

First of all I wanna state out that the idea behind KMM is awesome! Unfortunately I ran into an issue when trying it out.

Using the final branch, I cannot build the iOS app. After building the project in Android Studio 4.1 RC 3, switching to XCode 12.0 and hitting Product -> Build, I get the error No such module 'shared' inside ContentView.swift. When doing the same on a newly generated KMM application, this works fine. I noticed, that Android Studio does not generate the xcode-frameworks folder, so it's no surprise that XCode can't find it.

Moreover, I cannot run the iOS simulator from Android Studio. The build fails with:

ld: warning: ignoring file /Users/****/kmm/shared/build/xcode-frameworks/shared.framework/shared, building for iOS Simulator-arm64 but attempting to link with file built for iOS Simulator-x86_64
Undefined symbols for architecture arm64:
  "_OBJC_CLASS_$_SharedGreeting", referenced from:
      objc-class-ref in ContentView.o
ld: symbol(s) not found for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)

** BUILD FAILED ** 

Am I missing something?

AndroidApp: Blank screen on data load success

Hi team,

Firstly, thank you for the wonderful demo. It has been really helpful in understanding the configuration. Just like to highlight a slight issue in activity_main.xml below which is causing a blank screen when data fetch is successful.

<androidx.swiperefreshlayout.widget.SwipeRefreshLayout android:id="@+id/swipeContainer" **android:layout_width="0dp" android:layout_height="0dp"** app:layout_constraintBottom_toBottomOf="parent" app:layout_constraintEnd_toEndOf="parent" app:layout_constraintStart_toStartOf="parent" app:layout_constraintTop_toTopOf="parent">

Setting the above from 0dp to match_parent should solve the issue.

Generated AppDatabase interface does not have appDatabaseQueries field

I'm at this step: https://www.jetbrains.com/help/kotlin-multiplatform-dev/multiplatform-ktor-sqldelight.html#implement-cache, and could upon checking the generated AppDatabase interface does not have the appDatabaseQueries field:

public interface AppDatabase : Transacter {
  public companion object {
    public val Schema: SqlSchema<QueryResult.Value<Unit>>
      get() = AppDatabase::class.schema

    public operator fun invoke(driver: SqlDriver): AppDatabase =
        AppDatabase::class.newInstance(driver)
  }
}

I can see a separate AppDatabaseQueries class that looks like this though:

public class AppDatabaseQueries(
  driver: SqlDriver,
  private val LaunchAdapter: Launch.Adapter,
) : TransacterImpl(driver) {
  public fun <T : Any> selectAllLaunchesInfo(mapper: (
    flightNumber: Long,
    missionName: String,
    details: String?,
    launchSuccess: Boolean?,
    launchDateUTC: String,
    patchUrlSmall: String?,
    patchUrlLarge: String?,
    articleUrl: String?,
  ) -> T): Query<T> = Query(-686_265_875, arrayOf("Launch"), driver, "AppDatabase.sq",
      "selectAllLaunchesInfo", """
  |SELECT Launch.*
  |FROM Launch
  """.trimMargin()) { cursor ->
    mapper(
      cursor.getLong(0)!!,
      cursor.getString(1)!!,
      cursor.getString(2),
      cursor.getLong(3)?.let { LaunchAdapter.launchSuccessAdapter.decode(it) },
      cursor.getString(4)!!,
      cursor.getString(5),
      cursor.getString(6),
      cursor.getString(7)
    )
  }
// ...

It seems that the tutorial is using SQLDelight 1.x, and that there is a new version, can we please get an updated version of this tutorial?

iOS example not working correctly, throws: mutation attempt of frozen kotlin.collections.HashMap

Hi,

I was following the tutorial Kotlin Multiplatform Hands-on: Networking and Data Storage from scratch using Android Studio Arctic Fox Beta 4 and KMM plugin v0.2.6.

The Android demo works great, the iOS demo seems to have a problem trying to retrieve the data from the shared KMM module.

I also noticed that the iOS template that's generated with KMM plugin v0.2.6 is different from the one in the tutorial and this repo. The plugin now generates a template with iOSApp.swift and ContentView.swift only (there is no AppDelegate.swift or SceneDelegate). In my fork I made some changes to make it run, unfortunately, it gives me the following error when launching: "mutation attempt of frozen kotlin.collections.HashMap@1cad628"

Screen Shot 2021-06-29 at 5 07 08 PM

Steps to replicate:

Any ideas how to fix the demo code?

I'm using:

  • Kotlin: 1.5.20
  • Coroutines: 1.5.0-native-mt
  • Serialization: 1.2.1
  • ktor: 1.6.0
  • sqldelight: 1.5.0

edit June 30th 2021
I also tried updated the existing final branch to see if it was some XCode proj issue (but it gives the same result):

iOS App should assign the loaded result at main queue

The following code will trigger the XCode warning

func loadLaunches(forceReload: Bool) {
    self.launches = .loading
    sdk.getLaunches(forceReload: forceReload, completionHandler: { launches, error in
        if let launches = launches {
            self.launches = .result(launches)
        } else {
            self.launches = .error(error?.localizedDescription ?? "error")
        }
    })
}

The warning is as the bellow:

Publishing changes from background threads is not allowed; make sure to publish values from the main thread (via operators like receive(on:)) on model updates.

I think we can fix the problem by using the following code:

func loadLaunches(forceReload: Bool) {
    self.launches = .loading
    sdk.getLaunches(forceReload: forceReload, completionHandler: { launches, error in
        DispatchQueue.main.async {
            if let launches = launches {
                self.launches = .result(launches)
            } else {
                self.launches = .error(error?.localizedDescription ?? "error")
            }
        }
    })
}

Or use the following code:

@MainActor
func loadLaunches(forceReload: Bool) async {
    do {
        self.launches = .loading
        let launches = try await sdk.getLaunches(forceReload: forceReload)
        self.launches = .result(launches)
    } catch {
        self.launches = .error(error.localizedDescription)
    }
}

Ios application crashes in the emulator - comment 6ce52dd on upd-final branch

Hi:

First some context.

I tried to run the demo using the current version of Android Studio (2021.2.1 Patch 1 built on May 18, 2022), Kotlin (Android studio won't display the full plugin version but it looks like it was built on Jul 7, 2022 and it's in the 1.7 series) and it's associated libraries (
current versions of the serialization, sql delight, and tor libraries). I had issues running the Android app, an exception trying to deserialize the response from spacex service.

Because I had manually tried to update the project references and this is one of my first hmm projects, I gave up on that experiment and attempted to use the current version of the demo on the bpd-final branch.

The android app works and the iso app crashes with the exception below.

I haven't included references and version detail (other than the Android and Kotlin version above) as I assume that you can find it from the commit. Let me know if you need more information.

[Note that I removed some of the file system path information from the exception in a lame attempt to obfuscate some of the possibly personal data - I hope that doesn't confused the issue]

/xxx/AndroidStudioProjects/kmm-networking-and-data-storage/build/ios/Debug-iphonesimulator/iosApp.app
2022-07-12 12:05:26.685267-0400 iosApp[8420:340254] [LayoutConstraints] Unable to simultaneously satisfy constraints.
	Probably at least one of the constraints in the following list is one you don't want. 
	Try this: 
		(1) look at each constraint and try to figure out which you don't expect; 
		(2) find the code that added the unwanted constraint or constraints and fix it. 
(
    "<NSLayoutConstraint:0x6000004d5d60 'BIB_Leading_Leading' H:|-(0)-[_UIModernBarButton:0x13a01a150]   (active, names: '|':_UIButtonBarButton:0x13a016f80 )>",
    "<NSLayoutConstraint:0x6000004f7d40 'UINav_static_button_horiz_position' _UIModernBarButton:0x13a01a150.leading == UILayoutGuide:0x600001ef1340'UIViewLayoutMarginsGuide'.leading   (active)>",
    "<NSLayoutConstraint:0x6000004f7d90 'UINavItemContentGuide-leading' H:[_UIButtonBarButton:0x13a016f80]-(6)-[UILayoutGuide:0x600001ef1260'UINavigationBarItemContentLayoutGuide']   (active)>",
    "<NSLayoutConstraint:0x6000004fd630 'UINavItemContentGuide-trailing' UILayoutGuide:0x600001ef1260'UINavigationBarItemContentLayoutGuide'.trailing == _UINavigationBarContentView:0x13a20e820.trailing   (active)>",
    "<NSLayoutConstraint:0x6000004fb930 'UIView-Encapsulated-Layout-Width' _UINavigationBarContentView:0x13a20e820.width == 0   (active)>",
    "<NSLayoutConstraint:0x6000004fd2c0 'UIView-leftMargin-guide-constraint' H:|-(8)-[UILayoutGuide:0x600001ef1340'UIViewLayoutMarginsGuide'](LTR)   (active, names: '|':_UINavigationBarContentView:0x13a20e820 )>"
)

Will attempt to recover by breaking constraint 
<NSLayoutConstraint:0x6000004d5d60 'BIB_Leading_Leading' H:|-(0)-[_UIModernBarButton:0x13a01a150]   (active, names: '|':_UIButtonBarButton:0x13a016f80 )>

Make a symbolic breakpoint at UIViewAlertForUnsatisfiableConstraints to catch this in the debugger.
The methods in the UIConstraintBasedLayoutDebugging category on UIView listed in <UIKitCore/UIView.h> may also be helpful.
2022-07-12 12:05:26.686456-0400 iosApp[8420:340254] [LayoutConstraints] Unable to simultaneously satisfy constraints.
	Probably at least one of the constraints in the following list is one you don't want. 
	Try this: 
		(1) look at each constraint and try to figure out which you don't expect; 
		(2) find the code that added the unwanted constraint or constraints and fix it. 
(
    "<NSLayoutConstraint:0x6000004d5270 UIView:0x137712610.trailing == _UIBackButtonMaskView:0x137710e70.trailing   (active)>",
    "<NSLayoutConstraint:0x6000004d63a0 'Mask_Trailing_Trailing' _UIBackButtonMaskView:0x137710e70.trailing == _UIButtonBarButton:0x13a016f80.trailing   (active)>",
    "<NSLayoutConstraint:0x6000004d64e0 'MaskEV_Leading_BIB_Trailing' H:[_UIModernBarButton:0x13a01a150]-(0)-[UIView:0x137712610]   (active)>",
    "<NSLayoutConstraint:0x6000004f7d40 'UINav_static_button_horiz_position' _UIModernBarButton:0x13a01a150.leading == UILayoutGuide:0x600001ef1340'UIViewLayoutMarginsGuide'.leading   (active)>",
    "<NSLayoutConstraint:0x6000004f7d90 'UINavItemContentGuide-leading' H:[_UIButtonBarButton:0x13a016f80]-(6)-[UILayoutGuide:0x600001ef1260'UINavigationBarItemContentLayoutGuide']   (active)>",
    "<NSLayoutConstraint:0x6000004fd630 'UINavItemContentGuide-trailing' UILayoutGuide:0x600001ef1260'UINavigationBarItemContentLayoutGuide'.trailing == _UINavigationBarContentView:0x13a20e820.trailing   (active)>",
    "<NSLayoutConstraint:0x6000004fb930 'UIView-Encapsulated-Layout-Width' _UINavigationBarContentView:0x13a20e820.width == 0   (active)>",
    "<NSLayoutConstraint:0x6000004fd2c0 'UIView-leftMargin-guide-constraint' H:|-(8)-[UILayoutGuide:0x600001ef1340'UIViewLayoutMarginsGuide'](LTR)   (active, names: '|':_UINavigationBarContentView:0x13a20e820 )>"
)

Will attempt to recover by breaking constraint 
<NSLayoutConstraint:0x6000004d5270 UIView:0x137712610.trailing == _UIBackButtonMaskView:0x137710e70.trailing   (active)>

Make a symbolic breakpoint at UIViewAlertForUnsatisfiableConstraints to catch this in the debugger.
The methods in the UIConstraintBasedLayoutDebugging category on UIView listed in <UIKitCore/UIView.h> may also be helpful.
2022-07-12 12:05:26.689307-0400 iosApp[8420:340254] [LayoutConstraints] Unable to simultaneously satisfy constraints.
	Probably at least one of the constraints in the following list is one you don't want. 
	Try this: 
		(1) look at each constraint and try to figure out which you don't expect; 
		(2) find the code that added the unwanted constraint or constraints and fix it. 
(
    "<NSLayoutConstraint:0x6000004d5db0 'BIB_Trailing_CB_Leading' H:[_UIModernBarButton:0x13a01a150]-(6)-[_UIModernBarButton:0x13a018230'SpaceX Launches']   (active)>",
    "<NSLayoutConstraint:0x6000004d5e00 'CB_Trailing_Trailing' _UIModernBarButton:0x13a018230'SpaceX Launches'.trailing <= _UIButtonBarButton:0x13a016f80.trailing   (active)>",
    "<NSLayoutConstraint:0x6000004f7d40 'UINav_static_button_horiz_position' _UIModernBarButton:0x13a01a150.leading == UILayoutGuide:0x600001ef1340'UIViewLayoutMarginsGuide'.leading   (active)>",
    "<NSLayoutConstraint:0x6000004f7d90 'UINavItemContentGuide-leading' H:[_UIButtonBarButton:0x13a016f80]-(6)-[UILayoutGuide:0x600001ef1260'UINavigationBarItemContentLayoutGuide']   (active)>",
    "<NSLayoutConstraint:0x6000004fd630 'UINavItemContentGuide-trailing' UILayoutGuide:0x600001ef1260'UINavigationBarItemContentLayoutGuide'.trailing == _UINavigationBarContentView:0x13a20e820.trailing   (active)>",
    "<NSLayoutConstraint:0x6000004fb930 'UIView-Encapsulated-Layout-Width' _UINavigationBarContentView:0x13a20e820.width == 0   (active)>",
    "<NSLayoutConstraint:0x6000004fd2c0 'UIView-leftMargin-guide-constraint' H:|-(8)-[UILayoutGuide:0x600001ef1340'UIViewLayoutMarginsGuide'](LTR)   (active, names: '|':_UINavigationBarContentView:0x13a20e820 )>"
)

Will attempt to recover by breaking constraint 
<NSLayoutConstraint:0x6000004d5db0 'BIB_Trailing_CB_Leading' H:[_UIModernBarButton:0x13a01a150]-(6)-[_UIModernBarButton:0x13a018230'SpaceX Launches']   (active)>

Make a symbolic breakpoint at UIViewAlertForUnsatisfiableConstraints to catch this in the debugger.
The methods in the UIConstraintBasedLayoutDebugging category on UIView listed in <UIKitCore/UIView.h> may also be helpful.
Uncaught Kotlin exception: kotlin.native.IncorrectDereferenceException: illegal attempt to access non-shared <object>@27deba8 from other thread
    at 0   shared                              0x101211a43        kfun:kotlin.Throwable#<init>(kotlin.String?){} + 95 (/opt/buildAgent/work/c3a91df21e46e2c8/kotlin/kotlin-native/runtime/src/main/kotlin/kotlin/Throwable.kt:24:37)
    at 1   shared                              0x10120b047        kfun:kotlin.Exception#<init>(kotlin.String?){} + 91 (/opt/buildAgent/work/c3a91df21e46e2c8/kotlin/kotlin-native/runtime/src/main/kotlin/kotlin/Exceptions.kt:23:44)
    at 2   shared                              0x10120b27b        kfun:kotlin.RuntimeException#<init>(kotlin.String?){} + 91 (/opt/buildAgent/work/c3a91df21e46e2c8/kotlin/kotlin-native/runtime/src/main/kotlin/kotlin/Exceptions.kt:34:44)
    at 3   shared                              0x10121d73f        kfun:kotlin.native.IncorrectDereferenceException#<init>(kotlin.String){} + 91 (/opt/buildAgent/work/c3a91df21e46e2c8/kotlin/kotlin-native/runtime/src/main/kotlin/kotlin/native/Runtime.kt:34:36)
    at 4   shared                              0x10122041f        ThrowIllegalObjectSharingException + 423 (/opt/buildAgent/work/c3a91df21e46e2c8/kotlin/kotlin-native/runtime/src/main/kotlin/kotlin/native/concurrent/Internal.kt:115:11)
    at 5   shared                              0x10135e3a3        _ZN12_GLOBAL__N_128throwIllegalSharingExceptionEP9ObjHeader + 27 
    at 6   shared                              0x10135f97b        _ZN12_GLOBAL__N_136terminateWithIllegalSharingExceptionEP9ObjHeader + 11 
    at 7   shared                              0x10135fb2b        _ZNK27BackRefFromAssociatedObject3refIL11ErrorPolicy3EEEP9ObjHeaderv + 231 
    at 8   shared                              0x10135ebef        _ZN12_GLOBAL__N_111toKotlinImpEP11objc_objectP13objc_selectorPP9ObjHeader + 51 
    at 9   shared                              0x101355427        Kotlin_Interop_refFromObjC + 111 
    at 10  shared                              0x1015612af        _696f2e6b746f723a6b746f722d636c69656e742d64617277696e_knbridge160 + 207 (/xxx/Documents/agent/work/8d547b974a7be21f/ktor-client/ktor-client-darwin/darwin/src/io/ktor/client/engine/darwin/internal/DarwinResponseReader.kt:63:14)
    at 11  shared                              0x10156a9ff        _696f2e6b746f723a6b746f722d636c69656e742d64617277696e_kncfun162 + 79 
    at 12  CFNetwork                           0x183c22beb        _CFHostIsDomainTopLevelForCertificatePolicy + 13587 
    at 13  Foundation                          0x1807ec16f        __NSBLOCKOPERATION_IS_CALLING_OUT_TO_A_BLOCK__ + 15 
    at 14  Foundation                          0x1807ec04b        -[NSBlockOperation main] + 99 
    at 15  Foundation                          0x1807ef16f        __NSOPERATION_IS_INVOKING_MAIN__ + 19 
    at 16  Foundation                          0x1807eb1cf        -[NSOperation start] + 759 
    at 17  Foundation                          0x1807efb07        __NSOPERATIONQUEUE_IS_STARTING_AN_OPERATION__ + 19 
    at 18  Foundation                          0x1807ef60f        __NSOQSchedule_f + 179 
    at 19  libdispatch.dylib                   0x18011cca3        _dispatch_block_async_invoke2 + 103 
    at 20  libdispatch.dylib                   0x18010ea97        _dispatch_client_callout + 15 
    at 21  libdispatch.dylib                   0x180111bff        _dispatch_continuation_pop + 447 
    at 22  libdispatch.dylib                   0x180111323        _dispatch_async_redirect_invoke + 667 
    at 23  libdispatch.dylib                   0x18011f773        _dispatch_root_queue_drain + 431 
    at 24  libdispatch.dylib                   0x1801200f3        _dispatch_worker_thread2 + 159 
    at 25  libsystem_pthread.dylib             0x1cc0adb03        _pthread_wqthread + 223 
    at 26  libsystem_pthread.dylib             0x1cc0ac903        start_wqthread + 7 

Process finished with exit code 0

[FR] Add Unit Tests

Do please consider adding unit tests to the project as well as the hands on codelab.

cancel request on IOS

why not we cancel the request Task on IOS ? is that going to lead to memory leak

  override fun onDestroy() {
        super.onDestroy()
        mainScope.cancel()
    }
    ```

Tutorial Out of Date

In the tutorial for this project during step 3 you inform us to add sqlDelightVersion=1.4.1.

Version 1.4.1 has a bug that only marks the generated SQL files as iOS.

In your project you are using 1.4.2 to get around this issue.

Please update the tutorial.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.