Android Studio Relay插件(版本0.3.07)错误

huangapple go评论74阅读模式
英文:

Android Studio Relay plugin (version 0.3.07) error

问题

我在第一次尝试使用Relay插件时遵循了这个教程"https://developer.android.com/jetpack/compose/tooling/relay/convert-designs-android-studio"。我在遵循教程的前几个步骤时没有问题,但当我尝试从Figma导入设计到Android Studio时,我遇到了一个错误,我已经从idea.log文件中捕获到了这个错误信息:

2023-06-26 11:35:13,463 [1300963]   INFO - #c.g.r.a.p.i.FigmaService - 从Figma获取UI包
2023-06-26 11:35:13,466 [1300966]   WARN - #c.g.r.a.p.i.FigmaService - 无法设置权限于/home/ducanh/.local/share/Google/AndroidStudio2022.2/relay_android_studio/bin/linux_x86_64/figma_to_adin:/home/ducanh/.local/share/Google/AndroidStudio2022.2/relay_android_studio/bin/linux_x86_64/figma_to_adin
2023-06-26 11:35:13,467 [1300967]   INFO - #c.g.r.a.p.u.ShellCommand - 运行shell命令:/home/ducanh/.local/share/Google/AndroidStudio2022.2/relay_android_studio/bin/linux_x86_64/figma_to_adin
2023-06-26 11:35:13,511 [1301011] SEVERE - #c.g.r.a.p.i.FigmaImportWorker - 导入Figma文件时出现问题
java.io.IOException: 无法运行程序"/home/ducanh/.local/share/Google/AndroidStudio2022.2/relay_android_studio/bin/linux_x86_64/figma_to_adin"(在目录"/home/ducanh/.local/share/Google/AndroidStudio2022.2/relay_android_studio/bin/linux_x86_64"中):错误=2,没有该文件或目录
    ...

似乎缺少figma_to_adin文件在/home/ducanh/.local/share/Google/AndroidStudio2022.2/relay_android_studio/bin/linux_x86_64目录中。我也搜索了这个错误,但没有找到结果。我想知道是否有人遇到过这个错误并能够修复它。如果您需要任何额外的信息,请留下评论,这是我第一次提问,可能不太清楚。

英文:

I was following this tutorial "https://developer.android.com/jetpack/compose/tooling/relay/convert-designs-android-studio" to try out the Relay plugin for the first time. I have no problem following the previous steps of the tutorial, however when I get to import design from Figma to Android Studio, I encounter an error, which I have captured from the idea.log file:

2023-06-26 11:35:13,463 [1300963]   INFO - #c.g.r.a.p.i.FigmaService - fetching UI Package from Figma
2023-06-26 11:35:13,466 [1300966]   WARN - #c.g.r.a.p.i.FigmaService - Unable to set permissions on /home/ducanh/.local/share/Google/AndroidStudio2022.2/relay_android_studio/bin/linux_x86_64/figma_to_adin: /home/ducanh/.local/share/Google/AndroidStudio2022.2/relay_android_studio/bin/linux_x86_64/figma_to_adin
2023-06-26 11:35:13,467 [1300967]   INFO - #c.g.r.a.p.u.ShellCommand - Running shell command: /home/ducanh/.local/share/Google/AndroidStudio2022.2/relay_android_studio/bin/linux_x86_64/figma_to_adin
2023-06-26 11:35:13,511 [1301011] SEVERE - #c.g.r.a.p.i.FigmaImportWorker - There was a problem importing the Figma file
java.io.IOException: Cannot run program "/home/ducanh/.local/share/Google/AndroidStudio2022.2/relay_android_studio/bin/linux_x86_64/figma_to_adin" (in directory "/home/ducanh/.local/share/Google/AndroidStudio2022.2/relay_android_studio/bin/linux_x86_64"): error=2, No such file or directory
	at java.base/java.lang.ProcessBuilder.start(ProcessBuilder.java:1143)
	at java.base/java.lang.ProcessBuilder.start(ProcessBuilder.java:1073)
	at java.base/java.lang.Runtime.exec(Runtime.java:594)
	at com.google.relay.androidstudio.plugin.utilities.ShellCommand.run(ShellCommand.kt:33)
	at com.google.relay.androidstudio.plugin.utilities.ShellCommand.runUnchecked(ShellCommand.kt:77)
	at com.google.relay.androidstudio.plugin.importer.FigmaService.importFile(FigmaService.kt:263)
	at com.google.relay.androidstudio.plugin.importer.FigmaService.importPackagesToTemp(FigmaService.kt:127)
	at com.google.relay.androidstudio.plugin.importer.FigmaImportWorker.doInBackground(FigmaImportWorker.java:76)
	at com.google.relay.androidstudio.plugin.importer.FigmaImportWorker.doInBackground(FigmaImportWorker.java:31)
	at java.desktop/javax.swing.SwingWorker$1.call(SwingWorker.java:304)
	at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
	at java.desktop/javax.swing.SwingWorker.run(SwingWorker.java:343)
	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136)
	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
	at java.base/java.lang.Thread.run(Thread.java:833)
Caused by: java.io.IOException: error=2, No such file or directory
	at java.base/java.lang.ProcessImpl.forkAndExec(Native Method)
	at java.base/java.lang.ProcessImpl.<init>(ProcessImpl.java:314)
	at java.base/java.lang.ProcessImpl.start(ProcessImpl.java:244)
	at java.base/java.lang.ProcessBuilder.start(ProcessBuilder.java:1110)
	... 14 more
2023-06-26 11:35:13,513 [1301013] SEVERE - #c.g.r.a.p.i.FigmaImportWorker - Android Studio Flamingo | 2022.2.1 Patch 2  Build #AI-222.4459.24.2221.10121639
2023-06-26 11:35:13,513 [1301013] SEVERE - #c.g.r.a.p.i.FigmaImportWorker - JDK: 17.0.6; VM: OpenJDK 64-Bit Server VM; Vendor: JetBrains s.r.o.
2023-06-26 11:35:13,513 [1301013] SEVERE - #c.g.r.a.p.i.FigmaImportWorker - OS: Linux
2023-06-26 11:35:13,514 [1301014] SEVERE - #c.g.r.a.p.i.FigmaImportWorker - Plugin to blame: Relay for Android Studio version: 0.3.07

Seemed like it was missing the figma_to_adin file in the /home/ducanh/.local/share/Google/AndroidStudio2022.2/relay_android_studio/bin/linux_x86_64 directory. I was also searching for this error but no result found. I wonder if any one has encountered this error and abled to fix it. If you need any additional information, just comment, this is the first time I ask a question so it might not be too clear.

答案1

得分: 0

你找到解决办法了吗?我在安装了Android Studio中的Relay插件(0.3.07版本)后遇到了相同的问题,出现了“找不到文件错误”。看起来figma_to_adin文件被错误地添加到了relay_android_studio/bin/macos_x86_64而不是linux/x86_64下。

编辑:刚刚推送了更新版本(0.3.07-hotfix),已经修复了这个问题 Android Studio Relay插件(版本0.3.07)错误

英文:

Have you found a solution to this yet? I'm running into the same problem after installing the Relay plugin in Android Studio (0.3.07) with a "No such file error". Looks like the figma_to_adin file is being incorrectly added under relay_android_studio/bin/macos_x86_64 instead of linux/x86_64.

Edit: an updated version (0.3.07-hotfix) has just been pushed which fixes this issue Android Studio Relay插件(版本0.3.07)错误

huangapple
  • 本文由 发表于 2023年6月26日 12:49:02
  • 转载请务必保留本文链接:https://go.coder-hub.com/76553596.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定