Giter VIP home page Giter VIP logo

Comments (10)

kortchang avatar kortchang commented on August 24, 2024 2

I faced a similar issue in compose-plugin = 1.7.0-alpha01, and I resolved it by doing a clean build.

from compose-multiplatform.

terrakok avatar terrakok commented on August 24, 2024 1

I couldn't reproduce the problem. Could you share a reproducer project.

kotlin = "2.0.0"
compose = "1.7.0-dev1703"
image image

from compose-multiplatform.

terrakok avatar terrakok commented on August 24, 2024 1

Reproduced. The fix is in progress

from compose-multiplatform.

terrakok avatar terrakok commented on August 24, 2024 1

The reason of the issue on the AGP side: https://issuetracker.google.com/issues/348208777#comment5

I reproduced it without the compose

from compose-multiplatform.

Holetzky avatar Holetzky commented on August 24, 2024

For some reason I am also no longer able to reproduce the problem today.
Next time I will share a reproducer project.
Thank you for the help.

from compose-multiplatform.

Junzz0 avatar Junzz0 commented on August 24, 2024

I faced a similar issue in compose-plugin = 1.7.0-alpha01, and I resolved it by doing a clean build.

kotlin = "2.0.0"
compose = "1.7.0-alpha01"
gradle = 8.8
AGP = 8.2.0

Ran into this issue as well.

It's normal to start editing the string, but then it will report an error, I thought it was caused by the values without the corresponding string, but the default string in the values still reported an error.

from compose-multiplatform.

Junzz0 avatar Junzz0 commented on August 24, 2024

clean and then re-run without reporting errors.

from compose-multiplatform.

kortchang avatar kortchang commented on August 24, 2024

I faced a similar issue in compose-plugin = 1.7.0-alpha01, and I resolved it by doing a clean build.

kotlin = "2.0.0" compose = "1.7.0-alpha01" gradle = 8.8 AGP = 8.2.0

Ran into this issue as well.

It's normal to start editing the string, but then it will report an error, I thought it was caused by the values without the corresponding string, but the default string in the values still reported an error.

I need to clean build every time I edit the strings.xml resources.

from compose-multiplatform.

terrakok avatar terrakok commented on August 24, 2024

OK. I found the problem. It happens due my workaround the AGP issue with assets:
https://issuetracker.google.com/348208777

if I remove this code:

if (androidComponents.pluginVersion >= agp_8_1_0) {
    // addGeneratedSourceDirectory doesn't mark the output directory as assets hence AS Compose Preview doesn't work
    tasks.configureEach { task ->
        if (task.name == kgpCopyAssetsTaskName) {
            task.outputs.files.forEach { file ->
                addStaticSourceDirectory(file.path)
            }
        }
    }
}

the problem will be fixed BUT AndroidStudio previews stop to work 😢

from compose-multiplatform.

okushnikov avatar okushnikov commented on August 24, 2024

Please check the following ticket on YouTrack for follow-ups to this issue. GitHub issues will be closed in the coming weeks.

from compose-multiplatform.

Related Issues (20)

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.