Persistent "Invalid workflow file" / YAML parsing error in GitHub Actions for React App deployment #161933
Replies: 1 comment
-
💬 Your Product Feedback Has Been Submitted 🎉 Thank you for taking the time to share your insights with us! Your feedback is invaluable as we build a better GitHub experience for all our users. Here's what you can expect moving forward ⏩
Where to look to see what's shipping 👀
What you can do in the meantime 💻
As a member of the GitHub community, your participation is essential. While we can't promise that every suggestion will be implemented, we want to emphasize that your feedback is instrumental in guiding our decisions and priorities. Thank you once again for your contribution to making GitHub even better! We're grateful for your ongoing support and collaboration in shaping the future of our platform. ⭐ |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Why are you starting this discussion?
Bug
What GitHub Actions topic or product is this about?
Misc
Discussion Details
Hey everyone,
I'm encountering an extremely persistent and frustrating issue with GitHub Actions workflows in my repository (
superdupershaun/GymClientPortal
) that I'm using to deploy a React application to Firebase Hosting. Despite extensive troubleshooting, I consistently get anInvalid workflow file
error with a YAML syntax error on a specific line (e.g., line 16 or 18), even when the YAML appears perfectly valid.The Problem:
My GitHub Actions workflows fail immediately with an
Invalid workflow file
error, pointing to a YAML syntax issue. Here's a typical error message:This error occurs regardless of whether the file is
firebase-hosting-merge.yml
(auto-generated by Firebase CLI) or a manually createdmanual-deploy.yml
/test-workflow.yml
.Context:
https://github.com/superdupershaun/GymClientPortal
Troubleshooting Steps Already Taken (and consistently failing):
Firebase CLI Initialization:
firebase init hosting
multiple times, selecting an existing project,build
for the public directory, single-page app, and GitHub Actions integration.firebase login --reauth
, ensuring GitHub permissions were granted.**
package.json
Build Script Variations (last tried):"build": "node node_modules/react-scripts/scripts/build.js"
and"build": "sh -c \"npx react-scripts build\""
.GitHub Actions Workflow YAML (Consistently Failing to Parse):
This is the latest version I've tried to push, and it consistently throws the YAML error. I've also tried simpler versions.
Local Environment Checks:
cat
command locally consistently shows the YAML file with correct newlines and indentation.git config --global core.autocrlf input
.git reset --hard origin/main
andgit clean -f -d
to clear local state.Direct Editing on github.com:
.github/workflows/manual-deploy.yml
(and previouslyfirebase-hosting-merge.yml
) file directly in the GitHub web editor, pasting the exact YAML content provided above.Invalid workflow file
YAML syntax error on line 16 or 18 (as seen in the workflow logs).This issue is extremely persistent and occurs even when the YAML appears visually correct and is committed directly via the GitHub web interface. It seems like a deeper platform-level parsing issue or file corruption related to this repository.
Any insights or suggestions from the community would be greatly appreciated, as I'm unable to use GitHub Actions due to this fundamental parsing failure.
Beta Was this translation helpful? Give feedback.
All reactions