Skip to content

promote TARGETS content into placeholder BUCK files (#20407) #69

promote TARGETS content into placeholder BUCK files (#20407)

promote TARGETS content into placeholder BUCK files (#20407) #69

name: Validate Flatbuffer Generation
on:
workflow_dispatch:
pull_request:
paths:
- "schema/**"
- "devtools/bundled_program/schema/**"
- "exir/_serialize/generated/**"
- "devtools/bundled_program/serialize/generated/**"
jobs:
exir-flatbuffer:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: setup python
uses: actions/setup-python@v5
with:
python-version: "3.12"
- name: install executorch (with flatc)
run: ./install_executorch.sh -e
- name: Generate flatbuffer Python
run: python exir/_serialize/generate_program.py
- name: Validate executorch_flatbuffer is unchanged
run: |
git add -A exir/_serialize/generated/executorch_flatbuffer
if ! git diff --cached --quiet -- exir/_serialize/generated/executorch_flatbuffer; then
echo "Error: executorch_flatbuffer has uncommitted changes."
echo "Please run 'python exir/_serialize/generate_program.py' to regenerate the files and commit the changes."
exit 1
fi
- name: Generate bundled program flatbuffer Python
run: python devtools/bundled_program/serialize/generate_bundled_program.py
- name: Validate bundled_program_flatbuffer is unchanged
run: |
git add -A devtools/bundled_program/serialize/generated
if ! git diff --cached --quiet -- devtools/bundled_program/serialize/generated; then
echo "Error: bundled_program_flatbuffer has uncommitted changes."
echo "Please run 'python devtools/bundled_program/serialize/generate_bundled_program.py' to regenerate the files and commit the changes."
exit 1
fi