Skip to content

Rename build files from TARGETS to BUCK (group ID: -1063234892916970392)#19424

Open
bigfootjon wants to merge 1 commit intomainfrom
export-D104414963
Open

Rename build files from TARGETS to BUCK (group ID: -1063234892916970392)#19424
bigfootjon wants to merge 1 commit intomainfrom
export-D104414963

Conversation

@bigfootjon
Copy link
Copy Markdown
Member

Reviewed By: bigfootjon

Differential Revision: D104414963

Reviewed By: bigfootjon

Differential Revision: D104414963
Copilot AI review requested due to automatic review settings May 8, 2026 23:20
@pytorch-bot
Copy link
Copy Markdown

pytorch-bot Bot commented May 8, 2026

🔗 Helpful Links

🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/executorch/19424

Note: Links to docs will display an error until the docs builds have been completed.

❌ 1 Cancelled Job, 5 Pending

As of commit 479ecf2 with merge base 9889c7c (image):

CANCELLED JOB - The following job was cancelled. Please retry:

This comment was automatically generated by Dr. CI and updates every 15 minutes.

@meta-cla meta-cla Bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label May 8, 2026
@meta-codesync
Copy link
Copy Markdown
Contributor

meta-codesync Bot commented May 8, 2026

@bigfootjon has exported this pull request. If you are a Meta employee, you can view the originating Diff in D104414963.

@github-actions
Copy link
Copy Markdown

github-actions Bot commented May 8, 2026

This PR needs a release notes: label

If your change should be included in the release notes (i.e. would users of this library care about this change?), please use a label starting with release notes:. This helps us keep track and include your important work in the next release notes.

To add a label, you can comment to pytorchbot, for example
@pytorchbot label "release notes: none"

For more information, see
https://github.com/pytorch/pytorch/wiki/PyTorch-AutoLabel-Bot#why-categorize-for-release-notes-and-how-does-it-work.

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Migrates extension/pytree Buck build definitions from separate TARGETS (fbcode) + BUCK (xplat) files into unified BUCK files using fbcode_target / non_fbcode_target wrappers, and updates one existing BUCK file to use the migration wrapper.

Changes:

  • Deleted TARGETS files under extension/pytree/** and merged their fbcode-only rules into the corresponding BUCK files.
  • Added build_file_migration.bzl wrappers to select fbcode vs non-fbcode target definitions from a single BUCK.
  • Wrapped extension/pybindings/test/BUCK rules with fbcode_target.

Reviewed changes

Copilot reviewed 7 out of 7 changed files in this pull request and generated 5 comments.

Show a summary per file
File Description
extension/pytree/TARGETS Deleted; fbcode-only targets moved into extension/pytree/BUCK.
extension/pytree/BUCK Now contains both non-fbcode and fbcode target definitions via migration wrappers.
extension/pytree/aten_util/TARGETS Deleted; contents migrated into extension/pytree/aten_util/BUCK.
extension/pytree/aten_util/BUCK Now dispatches common targets via non_fbcode_target / fbcode_target.
extension/pytree/aten_util/test/TARGETS Deleted; contents migrated into extension/pytree/aten_util/test/BUCK.
extension/pytree/aten_util/test/BUCK Now dispatches common targets via non_fbcode_target / fbcode_target.
extension/pybindings/test/BUCK Wraps existing python rules with fbcode_target and loads migration helpers.
Comments suppressed due to low confidence (1)

extension/pybindings/test/BUCK:2

  • non_fbcode_target is loaded here but not used anywhere in the file. Removing unused loads makes it clearer which targets are intended to be fbcode-vs-xplat and reduces migration boilerplate.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread extension/pytree/BUCK
load("@fbcode_macros//build_defs:build_file_migration.bzl", "fbcode_target", "non_fbcode_target")
oncall("executorch")
# Any targets that should be shared between fbcode and xplat must be defined in
# targets.bzl. This file can contain xplat-only targets.
Comment thread extension/pytree/BUCK
define_common_targets()
non_fbcode_target(_kind = define_common_targets,)

# !!!! fbcode/executorch/extension/pytree/TARGETS was merged into this file, see https://fburl.com/workplace/xl8l9yuo for more info !!!!
Comment thread extension/pytree/BUCK
# targets.bzl. This file can contain fbcode-only targets.

load("@fbsource//xplat/executorch/build:runtime_wrapper.bzl", "runtime")
load(":targets.bzl", "define_common_targets")

# Any targets that should be shared between fbcode and xplat must be defined in
# targets.bzl. This file can contain fbcode-only targets.
load(":targets.bzl", "define_common_targets")
Comment on lines +16 to +18
load(":targets.bzl", "define_common_targets")


Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. fb-exported meta-exported

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants