Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
39 commits
Select commit Hold shift + click to select a range
5882d7d
Revert D87985301
Dec 2, 2025
54be06c
Stop depending on blobimport for test-server-new-repo.t
Dec 2, 2025
d572727
Add debouncing to SLOC fetching to prevent request spam
stbfb Dec 2, 2025
e699714
4
Dec 2, 2025
dd5d30a
migrate test-server-init.t from blobimport to testtool_drawdag
Dec 2, 2025
df6b532
Add ability to ratelimit atlas
Dec 2, 2025
bccfd66
docs: add comprehensive high-level documentation
markbt Dec 2, 2025
426ef46
Update `notify` from version 5 to 6.1.1
rchen152 Dec 2, 2025
7e8b268
Add nupkg builder for eden
Alramech Dec 2, 2025
dcece8e
Add targets.bzl file defining rpm/fbpkg/nupkg targets
Alramech Dec 2, 2025
e600b9d
Add suggested edits confirmation before merge continue
stbfb Dec 2, 2025
a2aff44
Updating hashes
Dec 2, 2025
31ebf80
Remove recommended bookmarks GK
babyleafy Dec 3, 2025
5040b53
graphmod: make dagwalker support custom id generators
zzl0 Dec 3, 2025
cc50fb8
pyrenderdag: make renderdag support (u8, i64) node id
zzl0 Dec 3, 2025
f10b30a
graphmod: add XREPOPARENT type
zzl0 Dec 3, 2025
ad9d9d1
debug: add repo attr to dummyctx
zzl0 Dec 3, 2025
ac9c2be
cmdutil: use the ctx.repo() for displaygraph
zzl0 Dec 3, 2025
16bb788
cmdutil: use graphnodeid instead rev for renderdag's node id
zzl0 Dec 3, 2025
492526b
cmdutil: fix a bug where it should use ctx.rev()
zzl0 Dec 3, 2025
991ca2b
iterutil: add mark_fist and mark_last utils
zzl0 Dec 3, 2025
9f2a795
cmdutil: refactor displaygraph to accept dict-based parameters
zzl0 Dec 3, 2025
dc59ad9
cmdutil: extract _logdagwalker helper function
zzl0 Dec 3, 2025
d8b03af
cmdutil: move & rename _getxrepoinfo() to cmdutil
zzl0 Dec 3, 2025
b93673b
cmdutil: add type annotations to graphlog() and fix callsites
zzl0 Dec 3, 2025
69f8a04
cmdutil: make _logdagwalker() support cross-repo log history
zzl0 Dec 3, 2025
d657c8f
cmdutil: make _logdagwalker() support custom node id func
zzl0 Dec 3, 2025
588531c
cmdutil: set xreponame for cross-repo log history
zzl0 Dec 3, 2025
2c7db0b
cmdutil: add a config to disable cross-repo follow logic
zzl0 Dec 3, 2025
9a80303
graphmod: remove nodes() and its usage
zzl0 Dec 3, 2025
9f27cd2
fbcode//eden/fs/cli:edenfsctl
Dec 3, 2025
c960565
scs: remove CrossRepoPushSource enum
markbt Dec 3, 2025
3442f5e
Migrate test-blobstore-healer.t from blobimport to testtool
Dec 3, 2025
ab5a312
enable OSS CI now build is fixed (#1157)
ahornby Dec 3, 2025
2d790fd
Updating hashes
Dec 3, 2025
da2c6b1
Re-sync with internal repository
facebook-github-bot Dec 3, 2025
7652002
Updating hashes
Dec 2, 2025
08022e2
Add additional repos to JK Experiment for diff_service
Dec 3, 2025
cb5f042
renable github actions for linux (#1135)
ahornby Dec 3, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
79 changes: 42 additions & 37 deletions .github/workflows/mononoke_linux.yml

Large diffs are not rendered by default.

68 changes: 34 additions & 34 deletions .github/workflows/mononoke_mac.yml

Large diffs are not rendered by default.

7 changes: 6 additions & 1 deletion .github/workflows/sapling-cli-getdeps_linux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,12 @@
name: Sapling CLI Getdeps Linux

on:
workflow_dispatch
push:
branches:
- main
pull_request:
branches:
- main

permissions:
contents: read # to fetch code (actions/checkout)
Expand Down
7 changes: 2 additions & 5 deletions addons/isl/src/Bookmark.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@ import {
REMOTE_MASTER_BOOKMARK,
} from './BookmarksData';
import {Row} from './ComponentUtils';
import {useFeatureFlagSync} from './featureFlags';
import {T, t} from './i18n';
import {Internal} from './Internal';
import {BookmarkCreateOperation} from './operations/BookmarkCreateOperation';
Expand Down Expand Up @@ -144,7 +143,6 @@ export function AllBookmarksTruncated({
}) {
const bookmarksData = useAtomValue(bookmarksDataStorage);
const recommendedBookmarks = useAtomValue(recommendedBookmarksAtom);
const recommendedBookmarksGK = useFeatureFlagSync(Internal.featureFlags?.RecommendedBookmarks);
const recommendedBookmarksAvailable = useAtomValue(recommendedBookmarksAvailableAtom);

const FullRepoBranchBookmark = Internal.FullRepoBranchBookmark;
Expand All @@ -171,9 +169,8 @@ export function AllBookmarksTruncated({
.map(bookmark => {
const value = typeof bookmark === 'string' ? bookmark : bookmark.value;
const isRecommended =
recommendedBookmarksGK &&
(recommendedBookmarks.has(value) ||
(typeof bookmark === 'object' && bookmark.isRecommended === true));
recommendedBookmarks.has(value) ||
(typeof bookmark === 'object' && bookmark.isRecommended === true);
const tooltipOverride = typeof bookmark === 'string' ? undefined : bookmark.description;
const {icon, tooltip} = getBookmarkAddons(
value,
Expand Down
6 changes: 0 additions & 6 deletions addons/isl/src/BookmarksData.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ import type {StableLocationData} from './types';
import {atom} from 'jotai';
import {tracker} from './analytics';
import serverAPI from './ClientToServerAPI';
import {featureFlagLoadable} from './featureFlags';
import {Internal} from './Internal';
import {lazyAtom, localStorageBackedAtom, readAtom, writeAtom} from './jotaiUtils';
import {latestCommits} from './serverAPIState';
Expand Down Expand Up @@ -124,11 +123,6 @@ export const recommendedBookmarksOnboarding = localStorageBackedAtom<boolean>(
true,
);

export const recommendedBookmarksGKAtom = atom(get => {
const flag = get(featureFlagLoadable(Internal.featureFlags?.RecommendedBookmarks));
return flag.state === 'hasData' ? flag.data : false;
});

export const recommendedBookmarksAtom = lazyAtom(async _get => {
const recommendedBookmarks = await (Internal.getRecommendedBookmarks?.() ??
Promise.resolve(new Set<string>()));
Expand Down
13 changes: 3 additions & 10 deletions addons/isl/src/BookmarksManager.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,6 @@ import {Column, Row, ScrollY} from './ComponentUtils';
import {DropdownFields} from './DropdownFields';
import {useCommandEvent} from './ISLShortcuts';
import {Internal} from './Internal';
import {useFeatureFlagSync} from './featureFlags';
import {T, t} from './i18n';
import {readAtom} from './jotaiUtils';
import {latestDag} from './serverAPIState';
Expand Down Expand Up @@ -100,10 +99,7 @@ function BookmarksManager(_props: {dismiss: () => void}) {
const bookmarksData = useAtomValue(bookmarksDataStorage);
const recommendedBookmarks = useAtomValue(recommendedBookmarksAtom);
const recommendedBookmarksAvailable = useAtomValue(recommendedBookmarksAvailableAtom);
const enableRecommended =
useFeatureFlagSync(Internal.featureFlags?.RecommendedBookmarks) &&
bookmarksData.useRecommendedBookmark &&
recommendedBookmarksAvailable;
const enableRecommended = bookmarksData.useRecommendedBookmark && recommendedBookmarksAvailable;

// Place recommended bookmarks (and remote/master) first if enabled, then the rest
const priority = new Set(recommendedBookmarks).add(REMOTE_MASTER_BOOKMARK);
Expand Down Expand Up @@ -347,7 +343,6 @@ function BookmarksList({
kind: BookmarkKind;
}) {
const [bookmarksData, setBookmarksData] = useAtom(bookmarksDataStorage);
const recommendedBookmarksGK = useFeatureFlagSync(Internal.featureFlags?.RecommendedBookmarks);
const recommendedBookmarks = useAtomValue(recommendedBookmarksAtom);
const recommendedBookmarksAvailable = useAtomValue(recommendedBookmarksAvailableAtom);

Expand All @@ -364,10 +359,8 @@ function BookmarksList({
const name = typeof bookmark === 'string' ? bookmark : bookmark.name;
const extra = typeof bookmark === 'string' ? undefined : bookmark.extra;
const enableRecommended =
recommendedBookmarksGK &&
bookmarksData.useRecommendedBookmark &&
recommendedBookmarksAvailable;
const isRecommended = recommendedBookmarksGK && recommendedBookmarks.has(name);
bookmarksData.useRecommendedBookmark && recommendedBookmarksAvailable;
const isRecommended = recommendedBookmarks.has(name);
const tooltipOverride = typeof bookmark === 'string' ? undefined : bookmark.info;
const {icon, tooltip} = getBookmarkAddons(
name,
Expand Down
8 changes: 7 additions & 1 deletion addons/isl/src/UncommittedChanges.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -877,7 +877,13 @@ function MergeConflictButtons({
key="continue"
disabled={!allConflictsResolved || shouldDisableButtons}
data-testid="conflict-continue-button"
onClick={() => {
onClick={async () => {
const conflictFiles =
conflicts.state === 'loaded' ? conflicts.files.map(f => f.path) : [];
if (!(await confirmSuggestedEditsForFiles('merge-continue', 'accept', conflictFiles))) {
return;
}

if (readAtom(shouldAutoResolveAllBeforeContinue)) {
runOperation(new RunMergeDriversOperation());
}
Expand Down
6 changes: 1 addition & 5 deletions addons/isl/src/serverAPIState.ts
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@ import {
bookmarksDataStorage,
recommendedBookmarksAtom,
recommendedBookmarksAvailableAtom,
recommendedBookmarksGKAtom,
REMOTE_MASTER_BOOKMARK,
} from './BookmarksData';
import serverAPI from './ClientToServerAPI';
Expand Down Expand Up @@ -307,10 +306,7 @@ export const latestDag = atom(get => {
const successorMap = get(latestSuccessorsMapAtom);
const bookmarksData = get(bookmarksDataStorage);
const recommendedBookmarksAvailable = get(recommendedBookmarksAvailableAtom);
const enableRecommended =
get(recommendedBookmarksGKAtom) &&
bookmarksData.useRecommendedBookmark &&
recommendedBookmarksAvailable;
const enableRecommended = bookmarksData.useRecommendedBookmark && recommendedBookmarksAvailable;
const recommendedBookmarks = get(recommendedBookmarksAtom);
const commitDag = undefined; // will be populated from `commits`

Expand Down
77 changes: 58 additions & 19 deletions addons/isl/src/sloc/useFetchSignificantLinesOfCode.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import type {CommitInfo, RepoRelativePath, SlocInfo} from '../types';

import {atom, useAtomValue} from 'jotai';
import {loadable} from 'jotai/utils';
import {useRef} from 'react';
import {useEffect, useMemo, useRef, useState} from 'react';
import serverAPI from '../ClientToServerAPI';
import {commitInfoViewCurrentCommits} from '../CommitInfoView/CommitInfoState';
import {getGeneratedFilesFrom} from '../GeneratedFile';
Expand Down Expand Up @@ -168,12 +168,6 @@ const fetchPendingAmendSloc = async (
return slocInfo;
};

let pendingAmendRequestId = 0;
const pendingAmendSlocAtom = atom(get => {
const selectedFiles = get(selectedFilesAtom);
return fetchPendingAmendSloc(get, selectedFiles, pendingAmendRequestId++);
});

/**
* FETCH PENDING SLOC
*/
Expand Down Expand Up @@ -230,16 +224,6 @@ const fetchPendingSloc = async (
return pendingLocData;
};

let pendingRequestId = 0;

const pendingChangesSlocAtom = atom(get => {
const selectedFiles = get(selectedFilesAtom);
return fetchPendingSloc(get, selectedFiles, pendingRequestId++);
});

const pendingAmendSlocLoadableAtom = loadable(pendingAmendSlocAtom);
const pendingChangesSlocLoadableAtom = loadable(pendingChangesSlocAtom);

function useFetchWithPrevious(atom: Atom<Loadable<Promise<SlocInfo | undefined>>>): {
slocInfo: SlocInfo | undefined;
isLoading: boolean;
Expand Down Expand Up @@ -274,10 +258,65 @@ export function useFetchSignificantLinesOfCode(commit: CommitInfo) {
return {slocInfo: result.data, isLoading: false};
}

// Debounce delay for SLOC requests to prevent spamming when many files are selected quickly
const DEBOUNCE_DELAY_MS = 300;

// Hook that debounces an atom value
function useDebouncedAtomValue<T>(sourceAtom: Atom<T>, debounceMs: number): T {
const currentValue = useAtomValue(sourceAtom);
const [debouncedValue, setDebouncedValue] = useState(currentValue);
const timeoutRef = useRef<ReturnType<typeof setTimeout> | null>(null);

useEffect(() => {
if (timeoutRef.current) {
clearTimeout(timeoutRef.current);
}

timeoutRef.current = setTimeout(() => {
setDebouncedValue(currentValue);
}, debounceMs);

return () => {
if (timeoutRef.current) {
clearTimeout(timeoutRef.current);
}
};
}, [currentValue, debounceMs]);

return debouncedValue;
}

let pendingRequestId = 0;
export function useFetchPendingSignificantLinesOfCode() {
return useFetchWithPrevious(pendingChangesSlocLoadableAtom);
// Debounce selected files to prevent spamming SLOC requests
const debouncedSelectedFiles = useDebouncedAtomValue(selectedFilesAtom, DEBOUNCE_DELAY_MS);

// Use a derived atom that depends on the debounced value
const debouncedAtom = useMemo(() => {
return atom(get => {
// Force the atom to use the debounced value by creating a dependency
// Note: we can't pass debouncedSelectedFiles directly to the atom,
// so we create a new fetch call with it
return fetchPendingSloc(get, debouncedSelectedFiles, pendingRequestId++);
});
}, [debouncedSelectedFiles]);

const loadableAtom = loadable(debouncedAtom);
return useFetchWithPrevious(loadableAtom);
}

let pendingAmendRequestId = 0;
export function useFetchPendingAmendSignificantLinesOfCode() {
return useFetchWithPrevious(pendingAmendSlocLoadableAtom);
// Debounce selected files to prevent spamming SLOC requests
const debouncedSelectedFiles = useDebouncedAtomValue(selectedFilesAtom, DEBOUNCE_DELAY_MS);

// Use a derived atom that depends on the debounced value
const debouncedAtom = useMemo(() => {
return atom(get => {
return fetchPendingAmendSloc(get, debouncedSelectedFiles, pendingAmendRequestId++);
});
}, [debouncedSelectedFiles]);

const loadableAtom = loadable(debouncedAtom);
return useFetchWithPrevious(loadableAtom);
}
2 changes: 1 addition & 1 deletion build/deps/github_hashes/facebook/fb303-rev.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
Subproject commit faed614f7626964abc445ff94e467a8d5de90b10
Subproject commit 1aca35e24e638a0db4c9e70817af432634e16f5e
2 changes: 1 addition & 1 deletion build/deps/github_hashes/facebook/fbthrift-rev.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
Subproject commit 4ce92f46fc271e173fce705a3b790ee14149751c
Subproject commit 674867a3c8e254f5be9519d26a7a5b531932c62a
2 changes: 1 addition & 1 deletion build/deps/github_hashes/facebook/folly-rev.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
Subproject commit 3f1fa35e63aee37dd25857d13d796857186b3aa0
Subproject commit 6a4ddcd5ccd0bc91b25d3f3c1820d556ff975cf1
1 change: 1 addition & 0 deletions build/deps/github_hashes/facebook/mvfst-rev.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Subproject commit a5683c792479a16d2faae915fffd6a2b29559d37
2 changes: 1 addition & 1 deletion build/deps/github_hashes/facebook/wangle-rev.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
Subproject commit 34f740cfa86fd27fa039487071d319b46cab1ca2
Subproject commit 45ff542aca0d2449bc5d3e150d2aae297e761d6d
Original file line number Diff line number Diff line change
@@ -1 +1 @@
Subproject commit 414b40088d33efbc70b0b19591a8e82771462cd0
Subproject commit 3fd57cafad19ed5fe6f3dd534868b92bb804e1dc
Original file line number Diff line number Diff line change
@@ -1 +1 @@
Subproject commit 4f3216b7bbfa27da8a3920b1c28f851ca8a5e1b6
Subproject commit cac1924e50c59baf47428538f99288bbc82bcd0e
2 changes: 1 addition & 1 deletion build/deps/github_hashes/facebookincubator/fizz-rev.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
Subproject commit 05415a3e812e3116d08006701381e632c2cbf206
Subproject commit 01b31be94b35e1e000baa2b40942403e78e4b935
24 changes: 19 additions & 5 deletions build/fbcode_builder/getdeps.py
Original file line number Diff line number Diff line change
Expand Up @@ -964,6 +964,13 @@ def setup_project_cmd_parser(self, parser):
default=None,
help="Timeout in seconds for each individual test",
)
parser.add_argument(
"--build-type",
help="Set the build type explicitly. Cmake and cargo builders act on them. Only Debug and RelWithDebInfo widely supported.",
choices=["Debug", "Release", "RelWithDebInfo", "MinSizeRel"],
action="store",
default=None,
)


@cmd(
Expand Down Expand Up @@ -1049,6 +1056,13 @@ def write_job_for_platform(self, platform, args): # noqa: C901
args.enable_tests
and manifest.get("github.actions", "run_tests", ctx=manifest_ctx) != "off"
)
rust_version = (
manifest.get("github.actions", "rust_version", ctx=manifest_ctx) or "stable"
)

override_build_type = args.build_type or manifest.get(
"github.actions", "build_type", ctx=manifest_ctx
)
if run_tests:
manifest_ctx.set("test", "on")
run_on = self.get_run_on(args)
Expand Down Expand Up @@ -1163,8 +1177,8 @@ def write_job_for_platform(self, platform, args): # noqa: C901
out.write(" - uses: actions/checkout@v4\n")

build_type_arg = ""
if args.build_type:
build_type_arg = f"--build-type {args.build_type} "
if override_build_type:
build_type_arg = f"--build-type {override_build_type} "

if build_opts.free_up_disk:
free_up_disk = "--free-up-disk "
Expand Down Expand Up @@ -1241,8 +1255,8 @@ def write_job_for_platform(self, platform, args): # noqa: C901
or builder_name == "cargo"
or mbuilder_name == "cargo"
):
out.write(" - name: Install Rust Stable\n")
out.write(" uses: dtolnay/rust-toolchain@stable\n")
out.write(f" - name: Install Rust {rust_version.capitalize()}\n")
out.write(f" uses: dtolnay/rust-toolchain@{rust_version}\n")
break

# Normal deps that have manifests
Expand Down Expand Up @@ -1360,7 +1374,7 @@ def write_job_for_platform(self, platform, args): # noqa: C901

out.write(" - name: Test %s\n" % manifest.name)
out.write(
f" run: {getdepscmd}{allow_sys_arg} test {num_jobs_arg}--src-dir=. {manifest.name}{project_prefix}\n"
f" run: {getdepscmd}{allow_sys_arg} test {build_type_arg}{num_jobs_arg}--src-dir=. {manifest.name}{project_prefix}\n"
)
if build_opts.free_up_disk and not build_opts.is_windows():
out.write(" - name: Show disk space at end\n")
Expand Down
28 changes: 19 additions & 9 deletions build/fbcode_builder/getdeps/cargo.py
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ def cargo_config_file(self):
if self.cargo_config_file_subdir:
return os.path.join(build_source_dir, self.cargo_config_file_subdir)
else:
return os.path.join(build_source_dir, ".cargo", "config")
return os.path.join(build_source_dir, ".cargo", "config.toml")

def _create_cargo_config(self):
cargo_config_file = self.cargo_config_file()
Expand All @@ -122,8 +122,12 @@ def _create_cargo_config(self):
[profile.dev]
debug = false
incremental = false

[profile.release]
opt-level = "{}"
""".format(
self.build_dir.replace("\\", "\\\\")
self.build_dir.replace("\\", "\\\\"),
"z" if self.build_opts.build_type == "MinSizeRel" else "s",
)

# Point to vendored sources from getdeps manifests
Expand Down Expand Up @@ -173,7 +177,7 @@ def _build(self, reconfigure) -> None:
build_source_dir = self.build_source_dir()

build_args = [
"--out-dir",
"--artifact-dir",
os.path.join(self.inst_dir, "bin"),
"-Zunstable-options",
]
Expand Down Expand Up @@ -206,20 +210,26 @@ def _build(self, reconfigure) -> None:
def run_tests(
self, schedule_type, owner, test_filter, retry, no_testpilot, timeout=None
) -> None:
build_args = []
if self.build_opts.build_type != "Debug":
build_args.append("--release")

if test_filter:
args = ["--", test_filter]
filter_args = ["--", test_filter]
else:
args = []
filter_args = []

if self.manifests_to_build is None:
self.run_cargo(self.install_dirs, "test", args)
if self.build_doc:
self.run_cargo(self.install_dirs, "test", build_args + filter_args)
if self.build_doc and not filter_args:
self.run_cargo(self.install_dirs, "doc", ["--no-deps"])
else:
for manifest in self.manifests_to_build:
margs = ["--manifest-path", self.manifest_dir(manifest)]
self.run_cargo(self.install_dirs, "test", args + margs)
if self.build_doc:
self.run_cargo(
self.install_dirs, "test", build_args + filter_args + margs
)
if self.build_doc and not filter_args:
self.run_cargo(self.install_dirs, "doc", ["--no-deps"] + margs)

def _patchup_workspace(self, dep_to_git) -> None:
Expand Down
Loading
Loading