-
Notifications
You must be signed in to change notification settings - Fork 88
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
EAS Custom Build issues #2261
Comments
Hi @dannyBies, Thanks for the feedback! We really appreciate it!
We are planning to add this functionality soon. Thanks for the suggestion! Meanwhile (as you probably noticed) it's probably necessary to maintain two separate configs for each platform for now.
You can try to do something like this to make it work for you really similarly {
"build": {
"my-build-profile": {
"config": "my-config.yml",
"android": {
"env": {
"SLACK_URL": "android-specific-url"
}
},
"ios": {
"env": {
"SLACK_URL": "ios-specific-url"
}
}
}
}
} build:
name: My config
steps:
...
- eas/send_slack_message:
if: ${ always() }
name: Send Slack message when the build finishes
inputs:
slack_hook_url: ${ eas.env.SLACK_URL } For iOS the
Sounds like a real bug, we will try to replicate it and resolve the issue. Thanks for the report!
I will get back to you on this |
Hi @dannyBies , thank you for reporting
I have replicated the issue and can confirm that it is a bug. I will be working on the fix and let you know when it is done |
Thanks for the quick updates, much appreciated!
Thanks for the workaround! Ideally I don't want to use |
Hi @dannyBies , the fix for
is in review and should be live later today |
I just finished setting up a slack bot to retrieve eas build info with slash commands. With this fix I'll be able to fully implement all of the slack integration points I was planning to make. |
Added escape character fix to value getter in BuildStepInput.ts See: expo/eas-cli#2261
Added tests for global fix for new line escape characters See: expo/eas-cli#2261
* [build-tools] Fix text messages Added test to check if the multiline message gets sent properly See: https://linear.app/expo/issue/ENG-11196/create-custom-build-example-slacking-team-members * [build-tools] Fix text messages Replacing all occurrences of `\\n` with `\n` after `JSON.stringify()` See: https://linear.app/expo/issue/ENG-11196/create-custom-build-example-slacking-team-members * [build-tools] Fix text messages Extracted the logic to a separate function and added tests for the case that came up during testing See: https://linear.app/expo/issue/ENG-11196/create-custom-build-example-slacking-team-members * [build-tools] Revert change Removed fixing escape characters from sendSlackMessage.ts to make it more global See: https://linear.app/expo/issue/ENG-11196/create-custom-build-example-slacking-team-members * [steps] Globally fix escape characters Added escape character fix to value getter in BuildStepInput.ts See: expo/eas-cli#2261 * [steps] Add tests Added tests for global fix for new line escape characters See: expo/eas-cli#2261
@dannyBies Messages with newline characters generated as output from other steps should work now |
Build/Submit details page URL
No response
Summary
Hi!
I'm using Custom EAS Builds to set up slack integration with
eas/send_slack_message
. I appreciate this might belong in https://github.com/expo/eas-build but I'm not able to create a new issue there.I have created two almost identical build configs for android and ios.
IOS:
Android:
Whilst trying to configure this I'm running into a couple issues:
1) Unable to conditionally execute a step depending on the platform
Ideally I want to use a single
yml
file where I configure my build steps. I would then be able to use2) Unable to pass parameters into the config
My
eas.json
currently looks likeDepending on the config I want to use a different
slack_url
, ideally I can do something like:3) Unable to generate a string inside of a custom function with newlines
I've tried to create a custom function that would generate a custom slack message, set that as it's output and then use this output inside the
eas/send_slack_message
. Unfortunately I could not get this to work properly. I would get the expected data in my slack channel but was unable to get it formatted correctly with newlines. I tried everything I could think of but had no luck. Using themessage:
input directly did work without issues so I've gone with this approach for now.4) Custom builds that do not run
- eas/build
cost the same amount as a normal buildDue to running into the above mentioned issues I had to create around 60 builds. To make it faster to test my various approaches I disabled the
eas/build
step and only had the slack integration running. I was surprised to find out that this costs the same amount as actually creating a full build. I'm wondering if in the future there could be a free/discounted rate for this?Managed or bare?
Managed
Environment
expo-env-info 1.2.0 environment info:
System:
OS: Windows 11 10.0.22631
Binaries:
Node: 20.11.1 - C:\Program Files\nodejs\node.EXE
Yarn: 1.22.21 - ~\AppData\Roaming\npm\yarn.CMD
npm: 9.8.0 - C:\Program Files\nodejs\npm.CMD
Expo Workflow: managed
Error output
No response
Reproducible demo or steps to reproduce from a blank project
My projectId is
a5c2db3f-5810-4a9e-8e9a-54a463a29af9
. You should be able to see all the builds I've created on there.The text was updated successfully, but these errors were encountered: