Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

加入booster后,约束布局Group 解析不了 #5

Closed
xie123 opened this issue Apr 28, 2019 · 15 comments
Closed

加入booster后,约束布局Group 解析不了 #5

xie123 opened this issue Apr 28, 2019 · 15 comments
Assignees
Labels
booster-transform-shrink issues of booster-transform-shrink bug Something isn't working
Milestone

Comments

@xie123
Copy link

xie123 commented Apr 28, 2019

image

之后尝试去掉 booster后,一切正常~~~

@johnsonlee
Copy link
Collaborator

临时解决方案:在 buildscriptdependencies 中把 booster-transform-all 替换为:

classpath "com.didiglobal.booster:booster-transform-bugfix-toast:$booster_version"
classpath "com.didiglobal.booster:booster-transform-lint:$booster_version"
classpath "com.didiglobal.booster:booster-transform-usage:$booster_version"

@johnsonlee
Copy link
Collaborator

image

之后尝试去掉 booster后,一切正常~~~

原因是因为 ConstraintHelper 用 resource name 反查 resource id,而 R$idbooster-transform-shrink 移除了

@johnsonlee johnsonlee self-assigned this Apr 28, 2019
@johnsonlee johnsonlee added the enhancement New feature or request label Apr 28, 2019
@johnsonlee johnsonlee changed the title 加入booster后,约束布局Group 解析不了 [booster-transform-shrink] 加入booster后,约束布局Group 解析不了 Apr 29, 2019
@johnsonlee johnsonlee changed the title [booster-transform-shrink] 加入booster后,约束布局Group 解析不了 加入booster后,约束布局Group 解析不了 Apr 29, 2019
@johnsonlee johnsonlee added booster-transform-shrink issues of booster-transform-shrink bug Something isn't working and removed enhancement New feature or request labels Apr 29, 2019
@johnsonlee
Copy link
Collaborator

Booster v0.1.4 is available

@johnsonlee johnsonlee added this to the booster-v0.2 milestone Apr 29, 2019
@xie123
Copy link
Author

xie123 commented May 6, 2019

image

ext.booster_version = '0.2.0'
classpath 'com.android.tools.build:gradle:3.4.0'
distributionUrl=https://services.gradle.org/distributions/gradle-5.1.1-all.zip

@xie123
Copy link
Author

xie123 commented May 6, 2019

在我不使用Group时 ,就可以了

@johnsonlee
Copy link
Collaborator

麻烦粘一下 layout xml

@johnsonlee
Copy link
Collaborator

麻烦提供一下 constraint-layout 的版本

@xie123
Copy link
Author

xie123 commented May 6, 2019

image

@xie123
Copy link
Author

xie123 commented May 6, 2019

image
布局太长了,约束布局中Group 的使用

@johnsonlee johnsonlee reopened this May 6, 2019
johnsonlee added a commit that referenced this issue May 6, 2019
@johnsonlee
Copy link
Collaborator

试试 Booster v0.2.1-SNAPSHOT

@xie123
Copy link
Author

xie123 commented May 6, 2019

好像还是一样的

@johnsonlee
Copy link
Collaborator

看下 build/reports/booster-transform-shrink/report.txt 的第一行,像这样:

booster.transform.shrink.ignores=[android/support/constraint/R$id.class]

@xie123
Copy link
Author

xie123 commented May 6, 2019

image
我是zhiq直接 debug。

@johnsonlee
Copy link
Collaborator

貌似 Booster 的版本不对

@johnsonlee
Copy link
Collaborator

johnsonlee commented May 7, 2019

试试 Booster v0.2.1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
booster-transform-shrink issues of booster-transform-shrink bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants