Summary:
Small potential bug from the last diff, if you had two folders with the same collapsed name at different places in the tree, they would get collapsed at the same time because we just used the folder name as the key to look them up.
For example:
```
isl/
src/
file1.txt
file2.txt
isl-server/
src/
file3.txt
file4.txt
```
Since file1 and file3 both live in folders that end up being labelled `src`, clicking either "src" would have collapsed both of them.
To prevent this we need to use a full accumulated path from the root, passed through the recursion.
Reviewed By: quark-zju
Differential Revision: D44775133
fbshipit-source-id: 571fa3c97be2f0cceb1087f0bee294019654b6ba
Summary:
Use the new `buildPathTree` and `changedFilesDisplayType` state to actually render changed files differently.
'short', 'fullPaths' and 'fish' are pretty easy, they're basically like before but we tweak the display slightly.
'tree' is of course the harder one. We use the newly built tree and recursively map that into components. We also need to handle collapsing paths.
Reviewed By: quark-zju
Differential Revision: D44774137
fbshipit-source-id: 77f93a87e537591223c34b2ee1c76be8e027aca9
Summary:
Add a component to let you change your current display method for files in the uncommitted changes file list.
This component is backed by an atom which itself is backed by an sl config. This means if you reload the page, it will remember what you changed the display type to last time.
I found one bug in the `persistAtomToConfigEffect` code while doing this, it was not distinguishing between different config IDs so they would trample each other.
Reviewed By: quark-zju
Differential Revision: D44774139
fbshipit-source-id: 0f77baef78189d34c9ea4b29589ffc61056d4d83
Summary:
In the next diffs, I'll add an option to render uncommitted changes as a tree instead of as a linear list
To do this, we'll extract the tree structure from the list of file paths, so we can render as a tree in the DOM.
Here I add a very simple algorithm to construct a map of maps recursively to represent each layer in the tree, to hold an arbitrary data structure per file.
I believe we can assume `/` as the pathsep here, even on windows—though it's probably worth confirming that's what we get from `sl status` since I don't remember and haven't tested windows in a while.
Reviewed By: quark-zju
Differential Revision: D44774138
fbshipit-source-id: 20217d02904e89db0cc535d3b53c3315ccc0607f
Summary:
This adds the configuration `doctor.ignored-problem-class-names` so that we can
make doctor ignore individual problem classes via config rollout.
This doesn't actually stop the checks from running, but it stops reporting (or
attempting fixes for) ignored problems. Ignored tests will still be logged in the
edenfs_events table's
Reviewed By: xavierd
Differential Revision: D44720584
fbshipit-source-id: 954d1131dfbbf6a3264abf55b5e0f01ab61836d0
Summary: Warn user about potentially confusing duplicate config entries when we are making automated edits to repo/user config file.
Reviewed By: quark-zju
Differential Revision: D44876243
fbshipit-source-id: 7d50df7f55e68f3655f6086156e803e52a2b4154
Summary: When there are duplicate config keys present, we now update the final (load bearing) one instead of the first one.
Reviewed By: quark-zju
Differential Revision: D44875407
fbshipit-source-id: fa546482cbbdb432fb7d02a716e4692022388dc5
Summary:
We've seen cases where invalidation is happening concurrently to
`PrjfsChannel::stop`. In that case, `getInner` would return a `nullptr` and
thus crash EdenFS as the code doesn't handle `nullptr` gracefully.
The root cause of why `stop` is being called on a mount that is still being
used is not entirely clear at this point due to the complexity of the
mount/unmount code which chadaustin is currently looking into. While this diff
should be revisited once Chad has reworked mount/unmount, we can make the code
correct by simply handling the `nullptr` case to avoid crashing.
Reviewed By: chadaustin
Differential Revision: D44875003
fbshipit-source-id: 977c59af9fcf0ae2c66929f22489370c18b92f94
Summary: If auth_proxy.unix_socket_path is configured, use that when testing for Mononoke HTTP connectivity.
Reviewed By: johansglock
Differential Revision: D44883873
fbshipit-source-id: 1c30645072842391ad9aa6b2548ee87bd1449896
Summary:
Added a config option `experimental.rebase-long-labels`. Once set to true,
produce more descriptive conflict markers "dest (rebasing onto)" and
"source (being rebased)" on conflicts.
Eventually we probably want this to be the default everywhere. For now, not
all users are compatible with this change so it's not yet the default.
Reviewed By: muirdm
Differential Revision: D44847924
fbshipit-source-id: b832f362cc1dd80e25a3fd80e0f334bffc4b12d8
Summary: This avoids revlog and its problematic code paths for all `pull` commands.
Reviewed By: sggutier
Differential Revision: D44805076
fbshipit-source-id: a4efacf111f03cda5752fe1b25d26a278c25f242
Summary: The previous diffs added support in SCS and remote-gitimport for including the `git-extra-headers` as part of the mirrored commits in Mononoke. This diff adds similar support for gitimport.
Differential Revision: D44869271
fbshipit-source-id: 5941b0c8729cd972188cc758837c6c1f1b0f72a1
Summary: The current healing logs just mention that a CMv2 blob was healed, but there is no mention of the actual blobstore key that it healed. This diff updates that.
Reviewed By: mitrandir77
Differential Revision: D44164682
fbshipit-source-id: c156a930716499fb1b5c7b248ce11d6bf88f8281
Summary: To maintain backwards compatibility for a while, we will be writing both the new `ContentMetadataV2` and the old `ContentMetadata` blobs. This will be behind a tunable which will be removed once we can verify that the code works as expected with `ContentMetadataV2`
Reviewed By: markbt
Differential Revision: D44221076
fbshipit-source-id: 95c01a96198a99e53ab3ea4f1b04b1ba78f4b298
Summary: D44136799 was the backout diff for backing out all the ContentMetadataV2 changes made so far. This was due to the reason that the changes were landed before the backfilling was completed. This diff is the revert of the backout, to be landed when the backfilling is properly completed.
Reviewed By: YousefSalama
Differential Revision: D44195175
fbshipit-source-id: 2872c699cc7c41cf436a1c7123e01a5190db7ece
Summary:
Eden's readdir and getfileAttribute endpoint returns an error when an entry in
a directory has a type that is not: regular file, directory, or symlink.
This causes issues for Buck2 because it propagates this error to the user. For
Buck2 a directory having a file that isn't a regular file, directory, or
symlink isn't an error case, it's just a file Buck2 wants to skip over. Buck2
would like to be able to differentiate real errors getting the filetype (like
say a network error) and having a weird file in some directory.
From chatting with Thomas, Buck2 is unlikely to ever care what type the file
is (if its not a file, dir or symlink). So it's sufficient just let buck2
know it's some "other" type of file. I think it makes sense to just add a non
source control type here. I also considered adding dtype as an attribute, but
I don't think we need it, but we could add that too.
In some cases it can be dangerous to add values to thrift enumeration
(SourceControlType enum we change below)
(reference post: https://fb.workplace.com/groups/thriftusers/permalink/785884732120941/).
But in our case, rust + Buck2 handles new enum types gracefully
(and with exactly the behavior we want):
https://our.intern.facebook.com/intern/diffusion/FBS/browse/master/fbcode/buck2/app/buck2_common/src/io/eden.rs?lines=157
so adding a value to the enum is safe (for buck2).
hack is our other client. they are going to handle it less gracefully:
https://www.internalfb.com/code/fbsource/[65673fd318750984372aeb5b44036a259a0d85d2]/fbcode/hphp/hack/src/facebook/hh_distc/package/package.rs?lines=441 but from what I can tell hack would also
error if they tried to list a directory with a socket in it with out this
change. Will confirm with them that this change is ok with them.
Reviewed By: chadaustin
Differential Revision: D44794698
fbshipit-source-id: 4e3ab7964fa2c0932b0363fb9ad62f24af74480c
Summary:
Because we have our server token in the URL query, we need to be careful not to leak the URL otuside of ISL. Requests to third party resources by default have a referer [sic] header which includes the search query.
By adding a meta `referrer` tag with `no-referrer`, we can disable these referer headers. Yes, the spelling difference is extremely weird.
See the spec: https://www.w3.org/TR/referrer-policy/#referrer-policy-delivery
Reviewed By: muirdm
Differential Revision: D44837405
fbshipit-source-id: eda375ef11b4075f5cc42feb5a7f3d292f1f0c9f
Summary:
I saw builds/tests were failing for centos due to a warning "egrep: warning: egrep is obsolescent; using grep -E".
We can instead use grep -E as recommended.
Note: this isn't every single test, but somehow only these tests had failures in the Centos CI job.
Reviewed By: muirdm
Differential Revision: D44848131
fbshipit-source-id: ba182e8c866ac6bd649f820b76097e4677295105
Summary: Configure post pull "debugmarklanded" hook in the requisite extension to avoid trying to run the hook when the extension is disabled.
Reviewed By: zzl0
Differential Revision: D44646572
fbshipit-source-id: 1ac2dd97d35616683b87223a97ebbe7aecaa0a91
Summary:
Don't crash on the "m" flag used to mark submodules in the manifest.
Also, deprecrate "sl manifest" in favor of "sl files". The "sl manifest --all" flag doesn't work anymore, anyway.
Reviewed By: sggutier
Differential Revision: D44772327
fbshipit-source-id: bad76f0defe95c4a11df9b606e56983583dc5e32
Summary: We offer the `--force` flag with the python implementation, this adds it for the C++ implementation in preparation for migration
Reviewed By: kmancini
Differential Revision: D44473785
fbshipit-source-id: 041613ff0d4048b40b02f7d8f024c78d659516f0
Summary:
Noticed that this was running while looking at a log on Linux. This does nothing on Linux/macOS besides loading inodes (ie: extra overhead), thus disable it.
Created from CodeHub with https://fburl.com/edit-in-codehub
Reviewed By: genevievehelsel
Differential Revision: D44835074
fbshipit-source-id: 3b80e4ccf0f63d50de395002c6a8d05a5e99952c
Summary: Fixes a wacky bug with one of our internal tools
Reviewed By: pushpakrajgautam
Differential Revision: D44811936
fbshipit-source-id: f3b6f07ff035c8d535792dec5add5146c1314f36
Summary:
Grammar update:
"eden debugedenimporthelper command command will be sent to this file."
Removed repeated ‘command’
Created from CodeHub with https://fburl.com/edit-in-codehub
Reviewed By: chadaustin
Differential Revision: D44799690
fbshipit-source-id: 03e70a8ec300d2b635ea02f9e03802a4f44e9d32