-
Notifications
You must be signed in to change notification settings - Fork 608
[build] Fix flatc #8816
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
[build] Fix flatc #8816
Conversation
We need to install `build/pip_data_bin_init.py.in` into `<executorch root>/data/bin/__init__.py`. This PR rewrite the logic into a `BuiltFile` so that it works well in editable mode. Test: ``` python -c "from executorch.data.bin import flatc" ``` Will add unit test in next PR. [ghstack-poisoned]
🔗 Helpful Links🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/executorch/8816
Note: Links to docs will display an error until the docs builds have been completed. ⏳ No Failures, 1 PendingAs of commit 226bc15 with merge base 76fb844 ( This comment was automatically generated by Dr. CI and updates every 15 minutes. |
Fixes #8784 We need to install `build/pip_data_bin_init.py.in` into `<executorch root>/data/bin/__init__.py`. This PR rewrite the logic into a `BuiltFile` so that it works well in editable mode. Since `BuiltFile` by default looks into cmake cache directory, this PR adds a placeholder `%CMAKE_CACHE_DIR%` for those are actually built by CMake and for `build/pip_data_bin_init.py.in` we don't add this placeholder. Test: ``` python -c "from executorch.data.bin import flatc" ``` Will add unit test in next PR. [ghstack-poisoned]
We need to install `build/pip_data_bin_init.py.in` into `<executorch root>/data/bin/__init__.py`. This PR rewrite the logic into a `BuiltFile` so that it works well in editable mode. Test: ``` python -c "from executorch.data.bin import flatc" ``` Will add unit test in next PR. ghstack-source-id: 433f50c Pull Request resolved: #8816
Fixes #8784 We need to install `build/pip_data_bin_init.py.in` into `<executorch root>/data/bin/__init__.py`. This PR rewrite the logic into a `BuiltFile` so that it works well in editable mode. Since `BuiltFile` by default looks into cmake cache directory, this PR adds a placeholder `%CMAKE_CACHE_DIR%` for those are actually built by CMake and for `build/pip_data_bin_init.py.in` we don't add this placeholder. Test: ``` python -c "from executorch.data.bin import flatc" ``` Will add unit test in next PR. [ghstack-poisoned]
Fixes #8784 We need to install `build/pip_data_bin_init.py.in` into `<executorch root>/data/bin/__init__.py`. This PR rewrite the logic into a `BuiltFile` so that it works well in editable mode. Since `BuiltFile` by default looks into cmake cache directory, this PR adds a placeholder `%CMAKE_CACHE_DIR%` for those are actually built by CMake and for `build/pip_data_bin_init.py.in` we don't add this placeholder. Test: ``` python -c "from executorch.data.bin import flatc" ``` Will add unit test in next PR. [ghstack-poisoned]
Fixes #8784 We need to install `build/pip_data_bin_init.py.in` into `<executorch root>/data/bin/__init__.py`. This PR rewrite the logic into a `BuiltFile` so that it works well in editable mode. Since `BuiltFile` by default looks into cmake cache directory, this PR adds a placeholder `%CMAKE_CACHE_DIR%` for those are actually built by CMake and for `build/pip_data_bin_init.py.in` we don't add this placeholder. Test: ``` python -c "from executorch.data.bin import flatc" ``` Will add unit test in next PR. [ghstack-poisoned]
We need to install `build/pip_data_bin_init.py.in` into `<executorch root>/data/bin/__init__.py`. This PR rewrite the logic into a `BuiltFile` so that it works well in editable mode. Test: ``` python -c "from executorch.data.bin import flatc" ``` Will add unit test in next PR. ghstack-source-id: 015cf34 Pull Request resolved: #8816
@pytorchbot -h |
PyTorchBot Help
Merge
Revert
Rebase
Label
Dr CI
cherry-pick
Closeusage: @pytorchbot close Close a PR [Can be used on issues] |
@pytorchbot cherry-pick --onto main |
❌ 🤖 pytorchbot command failed:
Try |
@pytorchbot cherry-pick --onto main -c fixnewfeature |
* [build] Fix flatc We need to install `build/pip_data_bin_init.py.in` into `<executorch root>/data/bin/__init__.py`. This PR rewrite the logic into a `BuiltFile` so that it works well in editable mode. Test: ``` python -c "from executorch.data.bin import flatc" ``` Will add unit test in next PR. [ghstack-poisoned] * Update on "[build] Fix flatc" Fixes #8784 We need to install `build/pip_data_bin_init.py.in` into `<executorch root>/data/bin/__init__.py`. This PR rewrite the logic into a `BuiltFile` so that it works well in editable mode. Since `BuiltFile` by default looks into cmake cache directory, this PR adds a placeholder `%CMAKE_CACHE_DIR%` for those are actually built by CMake and for `build/pip_data_bin_init.py.in` we don't add this placeholder. Test: ``` python -c "from executorch.data.bin import flatc" ``` Will add unit test in next PR. [ghstack-poisoned] * Update on "[build] Fix flatc" Fixes #8784 We need to install `build/pip_data_bin_init.py.in` into `<executorch root>/data/bin/__init__.py`. This PR rewrite the logic into a `BuiltFile` so that it works well in editable mode. Since `BuiltFile` by default looks into cmake cache directory, this PR adds a placeholder `%CMAKE_CACHE_DIR%` for those are actually built by CMake and for `build/pip_data_bin_init.py.in` we don't add this placeholder. Test: ``` python -c "from executorch.data.bin import flatc" ``` Will add unit test in next PR. [ghstack-poisoned] * Update on "[build] Fix flatc" Fixes #8784 We need to install `build/pip_data_bin_init.py.in` into `<executorch root>/data/bin/__init__.py`. This PR rewrite the logic into a `BuiltFile` so that it works well in editable mode. Since `BuiltFile` by default looks into cmake cache directory, this PR adds a placeholder `%CMAKE_CACHE_DIR%` for those are actually built by CMake and for `build/pip_data_bin_init.py.in` we don't add this placeholder. Test: ``` python -c "from executorch.data.bin import flatc" ``` Will add unit test in next PR. [ghstack-poisoned] (cherry picked from commit d0b27b5)
Cherry picking #8816The cherry pick PR is at #8858 and it is recommended to link a fixnewfeature cherry pick PR with an issue. Details for Dev Infra teamRaised by workflow job |
[build] Fix flatc (#8816) * [build] Fix flatc We need to install `build/pip_data_bin_init.py.in` into `<executorch root>/data/bin/__init__.py`. This PR rewrite the logic into a `BuiltFile` so that it works well in editable mode. Test: ``` python -c "from executorch.data.bin import flatc" ``` Will add unit test in next PR. [ghstack-poisoned] * Update on "[build] Fix flatc" Fixes #8784 We need to install `build/pip_data_bin_init.py.in` into `<executorch root>/data/bin/__init__.py`. This PR rewrite the logic into a `BuiltFile` so that it works well in editable mode. Since `BuiltFile` by default looks into cmake cache directory, this PR adds a placeholder `%CMAKE_CACHE_DIR%` for those are actually built by CMake and for `build/pip_data_bin_init.py.in` we don't add this placeholder. Test: ``` python -c "from executorch.data.bin import flatc" ``` Will add unit test in next PR. [ghstack-poisoned] * Update on "[build] Fix flatc" Fixes #8784 We need to install `build/pip_data_bin_init.py.in` into `<executorch root>/data/bin/__init__.py`. This PR rewrite the logic into a `BuiltFile` so that it works well in editable mode. Since `BuiltFile` by default looks into cmake cache directory, this PR adds a placeholder `%CMAKE_CACHE_DIR%` for those are actually built by CMake and for `build/pip_data_bin_init.py.in` we don't add this placeholder. Test: ``` python -c "from executorch.data.bin import flatc" ``` Will add unit test in next PR. [ghstack-poisoned] * Update on "[build] Fix flatc" Fixes #8784 We need to install `build/pip_data_bin_init.py.in` into `<executorch root>/data/bin/__init__.py`. This PR rewrite the logic into a `BuiltFile` so that it works well in editable mode. Since `BuiltFile` by default looks into cmake cache directory, this PR adds a placeholder `%CMAKE_CACHE_DIR%` for those are actually built by CMake and for `build/pip_data_bin_init.py.in` we don't add this placeholder. Test: ``` python -c "from executorch.data.bin import flatc" ``` Will add unit test in next PR. [ghstack-poisoned] (cherry picked from commit d0b27b5) Co-authored-by: Mengwei Liu <[email protected]>
Stack from ghstack (oldest at bottom):
Fixes #8784
We need to install
build/pip_data_bin_init.py.in
into<executorch root>/data/bin/__init__.py
. This PR rewrite the logic into aBuiltFile
so that it works well in editable mode.Since
BuiltFile
by default looks into cmake cache directory, this PR adds a placeholder%CMAKE_CACHE_DIR%
for those are actually built by CMake and forbuild/pip_data_bin_init.py.in
we don't add this placeholder.Since editable mode doesn't support creating a directory in
build
command and install it as a new module, I need to createexecutorch/data/bin/
and add it to thepyproject.toml
file, so thatexecutorch.data.bin
can be installed by editable mode.Test:
Added
unittest-editable
for Linux and Mac