hey24sheep / azure-flutter-tasks

Easily build and deploy with latest Flutter build tasks for Azure DevOps Pipelines Tasks
https://marketplace.visualstudio.com/items?itemName=Hey24sheep.flutter
MIT License
89 stars 22 forks source link

Target file "--no-sound-null-safety --no-tree-shake-icons" not found. #93

Closed eric2788 closed 1 year ago

eric2788 commented 1 year ago
- task: FlutterBuild@0
   inputs:
      target: 'mobile'
      projectDirectory: '.'
      buildNumber: '$(BUILD_NUM)'
      buildName: '$(VERSION)'
      extraArgs: '--no-sound-null-safety --no-tree-shake-icons'
      apkTargetPlatform: 'android-arm64'
      iosCodesign: false

got

Target file "--no-sound-null-safety --no-tree-shake-icons" not found.

downgraded to 0.3.6 solve the problem.

hey24sheep commented 1 year ago

Hi, thank you for logging the issue. I gather the latest changes created this bug.

Please give me a little time to fix it. I'll fix it at the earliest.

khalilyamoun commented 1 year ago

Flavors are also broken... C:\WINDOWS\system32\cmd.exe /D /S /C "C:\FlutterAgent.10_work_tool\Flutter\3.10.6\windows\flutter\bin\flutter.bat build apk "-t lib/production.dart""

Target file " lib/production.dart" not found.

Mslamah commented 1 year ago

We are also facing issue with flavors Target file "--target lib/main_development.dart --flavor development" not found. Our builds were working totally fine until last week. This morning builds are failing

hey24sheep commented 1 year ago

@khalilyamoun @Mslamah Yes, I know. I will try to push a fix today after work.

baris-yldrm commented 1 year ago

same error when we pass extra command like below. It is working when we send only one extra command. Also it is working we run the build task directly from terminal manually. "Target file "--no-tree-shake-icons --obfuscate --split-debug-info=./build/app/outputs/symbols --verbose" not found."

I changed build task to command task for workaround.

@hey24sheep thank you for your work.

hey24sheep commented 1 year ago

Hi all, I have updated the extension to 0.3.14 it introduces a new separator input param to fix the multiple arguments or multiple dart defines (containing whitespace within values). Please check the readme & changelogs for further details.

Builds must be fixed now, please let me know by closing your respective issues, thank you all.

nick-gallimore commented 1 year ago

Thanks for the fix, we were affected by this as well.

Unfortunately, it looks like buildWeb is broken (but different). All of the arguments are doubled-up. The split-by-separator lines were uncommented and adjusted, but the previous line that adds the extra args as a single string (args.push(extraArgs.trim());) was left as well. I've only checked buildWeb as that's the one we're using, not sure if the same problem is in any of the other targets.

Thanks.

eric2788 commented 1 year ago

Not sure if there is a delay here..... when I tried to use FlutterBuild@0 it downloaded 0.3.8 for me (instead of 0.3.14), but it fixed the issue. This problem was caused from 0.3.7 (got this version while usingFlutterBuild@0 as task)

image

Anyway I think this issue could be closed now

hey24sheep commented 1 year ago

@nick-gallimore Your issue must fixed now, I have updated the extension with that build fix 0.3.15

hey24sheep commented 1 year ago

@eric2788 Hi, the updates take time sometimes. There is a new update now, so build task is now on 0.3.9. So, all builds must be working now.

You all can test and check your builds. If something is not working fine, comment here and I will try to fix that. Otherwise, I will close this issue within two days of no activity, thanks.

Mslamah commented 1 year ago

Hi @hey24sheep thank you for the fix. Currently the builds are working fine

nick-gallimore commented 1 year ago

Thanks for the quick fix, I've just tested and confirmed it's running as expected again.