DataBinding not working after Upgrade Android Studio 2.3

后端 未结 7 1317
挽巷
挽巷 2021-02-05 10:47

DataBinding worked very well in my project, But after upgrade Android Studio 2.3 today . Run \'app\' failed because following error :

Error:(1         


        
7条回答
  •  借酒劲吻你
    2021-02-05 11:07

    Data binding also broke for us following the update to Android Studio v2.3. The GoLang Bind plugin became unable to generate library .aar files

    Our problem was resolved via a combination of GoMobile version "+eb90329 Mar 7 2017" update and GoBind plugin revert to version "0.2.6" (although the current version is "0.2.8")

    Update GoMobile:

      $ go get -u -x golang.org/x/mobile/cmd/gomobile
      $ gomobile init -x
    

    Revert GoBind plugin in build.gradle:

      plugins {
        id "org.golang.mobile.bind" version "0.2.6"
      }
    

    This solution is working on systems with go version 1.7.1 and 1.8 as well as Android Studio versions 2.1.2, 2.2.3, and 2.3.

提交回复
热议问题