Commit Graph

80648 Commits

Author SHA1 Message Date
Open Source Bot
5492b9d524 Updating submodules
Summary:
GitHub commits:

e6a8d782cd
fcd816d534

Reviewed By: jurajh-fb

fbshipit-source-id: 256d8edc649b5d2232714e5ac334a0d1d54430bd
2023-02-18 19:11:49 -08:00
Open Source Bot
74d5047ff7 Updating submodules
Summary:
GitHub commits:

3b00d58af9

Reviewed By: jurajh-fb

fbshipit-source-id: 23ecb07e7e9ebd4dfbf3980de141ea1ebe36bb12
2023-02-18 11:28:38 -08:00
Thomas Orozco
4ca78aae6b mkscratch: allow optionally providing a shorter path using a hash
Summary:
Like it says in the title. Sometimes it's helpful to reuse mkscratch's
configuration to place scratch files in the right place, but the paths it
provides might be too long for some applications.

Reviewed By: quark-zju

Differential Revision: D43390592

fbshipit-source-id: b10246be1552c92c0a184f1d9f7ab3e64654163a
2023-02-18 10:33:30 -08:00
Open Source Bot
d6aa619e13 Updating submodules
Summary:
GitHub commits:

b680677af1
7915dea4a7

Reviewed By: jurajh-fb

fbshipit-source-id: ad36b2425f8f4835ef3f607fc913d3ef1dabdd10
2023-02-18 06:37:28 -08:00
Open Source Bot
68f99986cc Updating submodules
Summary:
GitHub commits:

20d236ea80
a1f083bfd9
b6640c3117
686ea7628d
7c69105525
40ff6006a5
d4101b7967
4752f14234

Reviewed By: jurajh-fb

fbshipit-source-id: 8e084a6af86ca5b65df22bf2a5daafca618a0567
2023-02-17 13:44:01 -08:00
Mark Shroyer
c192c6cec6 Make --retroactive trace status characters more legiible
Summary:
Replaces the dashed and solid arrow emoji, used to represent start and finish
events respectively, with an arrow and checkmark.

With my terminal font, I never noticed there were actually two different arrow
types in the output...

Reviewed By: kmancini

Differential Revision: D42971357

fbshipit-source-id: 9e569a461d77b6df9993554b0edccd85fe77d9f2
2023-02-17 13:11:43 -08:00
Open Source Bot
b5a2610f46 Updating submodules
Summary:
GitHub commits:

ad8bfd693f
03ee032e9e
19dce10f8b
25e1365227
2303d22435

Reviewed By: jurajh-fb

fbshipit-source-id: 64d5737a2949092d9d6d53a146e24886df80aa97
2023-02-17 12:40:55 -08:00
Max 👨�‍💻 Coplan
9192b33fff feat(scm): Add revset aliases for next and prev (#448)
Summary:
feat(scm): Add revset aliases for `next` and `prev`

 In the same way you can `sl go top`, it seems logical to also have
`sl go next`. However, instead it is `sl next`.  While I normally remember to
do `sl prev`, I sometimes accidentally do `sl go prev` out of habbit and get an
error.  Instead, let's simply add two revset aliases for `next` and `prev` to
make sl more intuitive.

The revset functions were added by D43383303.
This change adds convenient aliases so one can use `next`, `prev` without typing `()`:

  next
  prev
  previous

Number of steps can still be specified using the function form:

  next(2)
  prev(3)
  previous(4)

Closes https://github.com/facebook/sapling/issues/444

Pull Request resolved: https://github.com/facebook/sapling/pull/448

Test Plan:
Automated tested blocked on https://github.com/facebook/sapling/issues/447

Manually tested by running `sl go next` and `sl go prev` and verifying I ended
up in the right spot.

Reviewed By: muirdm

Differential Revision: D43329058

Pulled By: quark-zju

fbshipit-source-id: 6fa5c6e6e41971f8f15b784586176b089c5f0027
2023-02-17 12:13:32 -08:00
Jun Wu
78c687be45 amend: expose movement revsets
Summary:
Expose stack movement logic as revset functions so they can be used like:

  # when stack forks in the middle and you want to histedit across the fork
  histedit 'bottom()'

  # when moving another stack on top of the current stack
  rebase -s X -d 'top()'

Reviewed By: muirdm

Differential Revision: D43383303

fbshipit-source-id: b1f68fe8bdb41988576fcb1ca0a17dcf235c5a55
2023-02-17 12:13:32 -08:00
Jun Wu
e8748a7dc1 types: remove stdlib conflicting module
Summary:
`types` conflicts with stdlib `types`. This prevents running doctests like:

  hg debugruntest revsetlang.py

Given its content is just the `ui` type, let's migrate its users to fully
qualified type `edenscm.ui.ui` explicitly.

Before:

  % lrt revsetlang.py
  Traceback (most recent call last):
    File "<string>", line 1, in <module>
    File "/usr/lib64/python3.8/multiprocessing/__init__.py", line 16, in <module>
      from . import context
    File "/usr/lib64/python3.8/multiprocessing/context.py", line 5, in <module>
      from . import process
    File "/usr/lib64/python3.8/multiprocessing/process.py", line 19, in <module>
      import signal
    File "/usr/lib64/python3.8/signal.py", line 4, in <module>
      from enum import IntEnum as _IntEnum
    File "/usr/lib64/python3.8/enum.py", line 2, in <module>
      from types import MappingProxyType, DynamicClassAttribute
    File "/data/users/quark/fbsource/fbcode/eden/scm/edenscm/types.py", line 16, in <module>
      from .ui import ui
  ImportError: attempted relative import with no known parent package
  Traceback (most recent call last):
    File "<string>", line 1, in <module>
    File "/usr/lib64/python3.8/multiprocessing/__init__.py", line 16, in <module>
      from . import context
    File "/usr/lib64/python3.8/multiprocessing/context.py", line 5, in <module>
      from . import process
    File "/usr/lib64/python3.8/multiprocessing/process.py", line 19, in <module>
      import signal
    File "/usr/lib64/python3.8/signal.py", line 4, in <module>
      from enum import IntEnum as _IntEnum
    File "/usr/lib64/python3.8/enum.py", line 2, in <module>
      from types import MappingProxyType, DynamicClassAttribute
    File "/data/users/quark/fbsource/fbcode/eden/scm/edenscm/types.py", line 16, in <module>
      from .ui import ui
  ImportError: attempted relative import with no known parent package
  # Ran 0 tests, 0 skipped, 0 failed.

After:

  % lrt revsetlang.py
  # Ran 1 tests, 0 skipped, 0 failed.

Reviewed By: muirdm

Differential Revision: D43383304

fbshipit-source-id: 1b30303046cd42ab730734f147ab51530b1916b3
2023-02-17 12:13:32 -08:00
Jun Wu
409c7aad8c revset: support alias overloading
Summary:
Revset aliases can be functions or symbols. Treat them and functions with
different number of args differently so:

  [revsetalias]
  f = g1
  f(a) = g2
  f(a,b) = g3

Can be defined without conflict on the name `f`. Revset expressions like `f`,
`f(x)`, `f(x,y)` will choose the right alias to expand.

Also forbid expanding a function name to a function call, since that does not
make sense. Revset functions always return a set. They never return a string.
Note template functions might return a string, but it seems extremely rare
for that to be useful in the alias function name case.

This allows defining more "interesting" aliases like:

  next = next()

which is used by an upcoming change.

Note extensions using `registrar.revsetpredicate` can only define revset
functions. Revset alias is the only way to make a symbol available without
requiring `()`.

Before this change, those aliases with the same name would simply clash,
and `f = f()` would infinite expand and error out.

Reviewed By: muirdm

Differential Revision: D43383302

fbshipit-source-id: 79796d4d67194e7221c2aa62f43bff5e9d55c953
2023-02-17 12:13:32 -08:00
Max 👨�‍💻 Coplan
7aeb0e47a8 Add completion for sapling (#369)
Summary:
Add completion for sapling

 Make completion work for `sl` by adding `sl=hg` to the compdef

Pull Request resolved: https://github.com/facebook/sapling/pull/369

Test Plan:
Manually
```sh
$ ln -sv ~+/eden/scm/contrib/zsh_completion /usr/local/share/zsh/site-functions
$ exec zsh # might have to clear compinit cache
$ sl g
gc       githelp  goto     graft    grep
```
(and this does not work on main at the time of writing)

Reviewed By: muirdm

Differential Revision: D43329103

Pulled By: quark-zju

fbshipit-source-id: a8220efa64acda0e988b92418321675a6e3dd7a5
2023-02-17 12:13:32 -08:00
Matthew strager Glazar
c0b8af3ea9 smartlog: add option to hide '~' marker for unlogged ancestors (#456)
Summary:
smartlog: add option to hide '~' marker for unlogged ancestors
I made a template for 'sl smartlog' which is compact compared to the default:

    o  a0f0b95622       my commit
    o  10 hours ago     remote/main
    |
    ~

Unfortunately, the '|' and '~' lines take up a lot of space. Add an option to
disable these lines, making the output nice and tidy:

    o  a0f0b95622       my commit
    o  10 hours ago     remote/main

Pull Request resolved: https://github.com/facebook/sapling/pull/456

Test Plan:
$ cd tests
    $ python run-tests.py test-log-graph-show-abbreviated-ancestors.t

Reviewed By: muirdm

Differential Revision: D43328964

Pulled By: quark-zju

fbshipit-source-id: f1cc1e081e50f780d6e7e7519c42f72ed5deaea1
2023-02-17 12:13:32 -08:00
kurtz.brandon@gmail.com
21703651e7 split commits_to_process into a function (#445)
Summary:
split commits_to_process into a function, future PRs (maybe in this stack) will utilize this function in other modules for implememting `sl pr land`. Even if `sl pr land` is not interesting, this still makes this functionality portable for future use cases

Pull Request resolved: https://github.com/facebook/sapling/pull/445

Reviewed By: muirdm

Differential Revision: D43328698

Pulled By: quark-zju

fbshipit-source-id: 9ea5607de3835620541d2306e9f5b45866678a58
2023-02-17 12:13:32 -08:00
Max 👨�‍💻 Coplan
17b8c310be util: show all dirty status indicators (#349)
Summary:
Instead of just showing `?` or `*`, show one of each symbol in the
dirty status.  This means there will be a maximum of 5 characters at the end of
the prompt, which is fine.

Pull Request resolved: https://github.com/facebook/sapling/pull/349

Test Plan:
Seems to work:

```
fbsource>scm % setopt PROMPT_SUBST
fbsource>scm % source contrib/scm-prompt.sh
fbsource>scm % export SHOW_DIRTY_STATE=1
fbsource>scm % export PS1='$(_scm_prompt)$USER@%m:%~%% '
(158b00d6b? M)muirdm@muirdm-mbp:~/fbsource/fbcode/eden/scm%

Reviewed By: muirdm

Differential Revision: D43326525

Pulled By: quark-zju

fbshipit-source-id: 94c0a85e4cf4ffcc5c7c8db9ed64f6ea6d1564a2
2023-02-17 12:13:32 -08:00
Mateusz Kwapich
6f1900cf13 refactor waiting for sync
Summary:
Let's decouple getting the latest id from waiting for it. This way we can wait
on arbitrary bookmark update log ids.

Reviewed By: yancouto

Differential Revision: D43363645

fbshipit-source-id: 8447ecd39e1eb1e957410fa1022b8c7a628a1eee
2023-02-17 12:05:09 -08:00
Mateusz Kwapich
ef33ddaef5 limit the number of commits when combining bundles
Summary:
slow_bookmark_mover's pushes often move bookmark by 100s of commits at the
time. We don't want to combine such pushes into a single bundle with others.

Reviewed By: yancouto

Differential Revision: D43356668

fbshipit-source-id: e9014f633c0d7c56b655c5b730d229b87736123f
2023-02-17 12:05:09 -08:00
Mateusz Kwapich
f3ae18126b gnerate bundles concurrently to sending them
Summary:
Currently the mononoke_hg_sync_job either prepares a bundle or sends it to hg
servers. Those steps could be done concurrently. This dfff creates a stream of
bundles that is buffered so the syncing to hg servers doesn't have to wait for
new bundle generation.

The implementation is a bit gross, unfortunately I couldn't get the lifetimes
arround `scan()` transofrmer to work without mutex and I hit higher-order
lifetime exception few times which caused me to wrap some things in Arc.

Reviewed By: yancouto

Differential Revision: D43306918

fbshipit-source-id: b2ec3da21f4791c57a02fcfe76c735f4fdb16efd
2023-02-17 12:05:09 -08:00
Mark Shroyer
ac6d40c320 git: respect 'default-push' path if present (#469)
Summary:
git: respect 'default-push' path if present
In non-Git mode, 'hg push' (without an explicit path) pushes to the
'default-push' path if present, falling back to the 'default' path.

In Git mode, 'sl push' (without an explicit path) always pushes to the 'default'
path. 'default-push' is ignored.

Teach Git mode to push to 'default-push' if present, similar to how it works in
non-Git mode.

This commit only affects 'sl push'. 'sl pr submit' still ignores the
'default-push' path.

Pull Request resolved: https://github.com/facebook/sapling/pull/469

Test Plan: $ (cd tests && python run-tests.py test-git-push-default-push.t)

Reviewed By: muirdm

Differential Revision: D43336914

Pulled By: quark-zju

fbshipit-source-id: f11c45fb2bd8678b6be7294bf15359131db0ee2e
2023-02-17 12:04:00 -08:00
Mads Kiilerich
1abfcbc16c Fedora rpm changes (#451)
Summary:
Various minor changes to the sapling repo while hacking on Fedora packaging.

These changes works with https://gist.github.com/kiilerix/b32cb9688d2d6e9e752e91e2ca4c30e6 .

Still a long way to go to be able to package offline and reproducible.

Pull Request resolved: https://github.com/facebook/sapling/pull/451

Reviewed By: muirdm

Differential Revision: D43327153

Pulled By: quark-zju

fbshipit-source-id: 33326188e17e451c9268038ac783c1fda86db5f8
2023-02-17 12:04:00 -08:00
Jun Wu
c3b9660c25 scmutil: merge same error handling logic
Summary: Certain error types have the same error handling logic. Merge them.

Reviewed By: muirdm

Differential Revision: D43335811

fbshipit-source-id: a3df1391a6d461f4713b5e92e8e005107337fddb
2023-02-17 12:04:00 -08:00
Jun Wu
c22a5a990a pyerror: rename RustError to UncategorizedNativeError
Summary:
The name RustError is kind of confusing:
- Some people confuse it and get bad impression on the Rust language.
- The name is not like Exception, or RuntimeError that are considered bad
  practice, but it is "one type catching all" type that is a bad practice.

Rename it to `UncategorizedNativeError` so it's clear:
- It's an uncategorized error that is unlikely a good practice.
- It does not intend to hurt reputation of the Rust language.
- It is from the native code, Rust, C, or C++.

Reviewed By: muirdm

Differential Revision: D43335812

fbshipit-source-id: 30ae3fa18d6f06963a7556399bee7dcb647ab1d5
2023-02-17 12:04:00 -08:00
Max Coplan
0de6043ff5 Allow sl init --git in non-empty directory (#463)
Summary:
Allow `sl init --git` in non-empty directory

 Currently, running `sl init --git` for a nonempty directory gives the
follwing error:
```
destination <..> already exists
```
This seems like an arbitary restriction to me, so I removed it.

It looks like this restriction was put in place because `sl init` and
`sl clone` share similar logic.  Is there any other reason for not allowing
`sl init` in non-empty directories?

Also, this commit fixes an imprecise error message when `init`ing a repository
in a non-directory (i.e. a file)

Pull Request resolved: https://github.com/facebook/sapling/pull/463

Test Plan:
Blocked by https://github.com/facebook/sapling/issues/447
manually tested with

(should pass, but didn't before)
```sh
DIR=/tmp/sl-clone-test zsh -c 'rm -rf $DIR; mkdir $DIR && cd $DIR && touch hi && CHGDISABLE=1 sl init --git .'
```

(should still fail)
```sh
DIR=/tmp/sl-clone-test REPO=git@github.com:97-things/97-things-every-programmer-should-know.git zsh -c 'rm -rf $DIR; mkdir $DIR && cd $DIR && CHGDISABLE=1 sl clone $REPO && CHGDISABLE=1 sl clone $REPO'
```

 ---
Stack created with [Sapling](https://sapling-scm.com). Best reviewed with [ReviewStack](https://reviewstack.dev/facebook/sapling/pull/463).
* __->__ https://github.com/facebook/sapling/issues/463

Reviewed By: muirdm

Differential Revision: D43328481

Pulled By: quark-zju

fbshipit-source-id: 0a82d88c393c847579e644b7c368db09cab51003
2023-02-17 12:04:00 -08:00
Jun Wu
fe0558b367 errors: handle repo::InitError
Summary:
If a directory is non-empty and init fails, it should not crash the program
(going through uncaught RustError code path).

Reviewed By: muirdm

Differential Revision: D43335814

fbshipit-source-id: c6e60b97e396548a5b3cd23ab9ffc46c2a6d2528
2023-02-17 12:04:00 -08:00
Michael Cuevas
0942f1b5f5 prefetch-profile: don't fail if profile is already active
Summary: `eden prefetch-profile activate` currently fails if the prefetch profile we're trying to activate is already active. I don't really consider this a failure, as the intended profile is already activated. Instead of returning an error, we should just return early.

Reviewed By: genevievehelsel

Differential Revision: D43377801

fbshipit-source-id: 59c34ada539dd0b0789ec48f3a2ed2d7e66558cb
2023-02-17 11:44:06 -08:00
Michael Cuevas
b02b56cd97 kill python prefetch-profiles
Summary:
We've had Rust prefetch-profiles for a while now. It's pretty safe at this point to delete the Python version.

quiet_delete

Reviewed By: genevievehelsel

Differential Revision: D43375605

fbshipit-source-id: f3670434b9884e2c7dc2c1429cf90b07334611af
2023-02-17 11:44:06 -08:00
Michael Cuevas
e08307ba0a fix eden rage stdout option
Reviewed By: genevievehelsel

Differential Revision: D43376778

fbshipit-source-id: f59caabf09c64514185bf686a297132c98ae46ef
2023-02-17 11:44:06 -08:00
Open Source Bot
7a834082a8 Updating submodules
Summary:
GitHub commits:

ba9dd68a1b
23208ff909
68b8a45ff0

Reviewed By: jurajh-fb

fbshipit-source-id: f8581e13cd1c0a2510d87f42c813ca2c65eaef1d
2023-02-17 11:40:50 -08:00
Marlon Dutra
e93c8babf6 Rust crate rsa 0.8.1 and required fixes
Summary:
Introduce Rust's crate rsa 0.8.1, that supports PSS signatures.
Fix usage of Rust crate rsa to be compatible with version 0.8.1

Reviewed By: zertosh, Imxset21

Differential Revision: D43263536

fbshipit-source-id: 7219e63b3be7a9065c2516e472ecfc677594e667
2023-02-16 17:03:23 -08:00
generatedunixname89002005307016
b76cc7ec3e Add annotations to eden/scm/edenscm/ext/github/github_repo_util.py
Reviewed By: quark-zju

Differential Revision: D43350954

fbshipit-source-id: e5b74bd3d53e855ff6e24e2444a89502d3b1b83b
2023-02-16 15:13:53 -08:00
generatedunixname89002005307016
9547da7cd8 Add annotations to eden/scm/edenscm/ext/catnotate.py
Reviewed By: quark-zju

Differential Revision: D43218517

fbshipit-source-id: 1c1ddb113c09997b420cdc4c2f79880f84a11465
2023-02-16 15:11:41 -08:00
generatedunixname89002005307016
419dba3f55 Add annotations to eden/scm/edenscm/ext/github/import_pull_request.py
Reviewed By: quark-zju

Differential Revision: D43234255

fbshipit-source-id: 0714bc3f45712e015685d9cc1067b3e9369f5c7a
2023-02-16 15:10:12 -08:00
generatedunixname89002005307016
915bba4aa6 Add annotations to eden/scm/edenscm/ext/amend/metaedit.py
Reviewed By: quark-zju

Differential Revision: D43271553

fbshipit-source-id: 3bed202cbf9b2d6a6aa235dcbac0271c6be766e4
2023-02-16 15:08:56 -08:00
Rajiv Sharma
b0f65ca23f Tests for upload_git_object method
Summary:
This diff has two major changes:
- Test for the upload_git_object method to ensure that the method behaves as expected in all cases
- Extension of the vallidations in the method to reject requests for uploading raw file blobs

Differential Revision: D43276298

fbshipit-source-id: 821a906b2bb5830f2162c432fc74db75f9ea11b8
2023-02-16 14:59:51 -08:00
Katie Mancini
a612b1300a fix fsck for renamed placeholders
Summary:
Our fsck does not properly handle renamed placeholders: renamed files
do not need to be present in scm and they may not be full or hydrated.

For example: clone a new repo, move a file. That file will just be a
placeholder. But eden materializes all renamed files. So the inode will
be materialized, but the contents will not be present on disk.

This works out ok, because when ProjFS reads the file, it will send a
"read" request for the old path. And EdenFS serves read requests
directly out of the source control state.

Our Fsck assumes that all files must have their contents present on
disk or exist in source control. Which generally make sense since
file contents should be read from disk or source control. But renamed
files are an exception.

Generally, this materializing renamed files without them being at least
hydrated when we gernally have a rule in windows eden that this should
not be the case, does feel kinda hacky. But we need to materialize them
for status and diff I think. So the option is to force hydrate things as they
are renamed. And this would mean unnecessarily fetching contents.
So I am not sure that its worth it.

We can at least fix this fsck issues for now, by fsck-ing renamed files
like populated & materialized ones. The inode should be materialized,
and we need to ensure the inode is the correct type. This diff teaches
fsck to detect renamed files and fix them up like materialized ones.

I discovered another fsck bug while fixing this. When files are removed
while eden is stoped, Eden will keep them in the overlay, but does not
add them back to disk. So the file will be removed from disk, but present
in the overlay. hg status does not match disk in this case ...To fix in a later
diff.

Reviewed By: xavierd

Differential Revision: D42268664

fbshipit-source-id: cb36a6513bb30a1c1951b5c8cc0ca66f78edbb67
2023-02-16 14:35:33 -08:00
Open Source Bot
b54ff6165f Updating submodules
Summary:
GitHub commits:

c51a2906c5
5e97023405
3710a32673
fd29800402
fca53d2d93
3d8a6d905c
75c5d75f7e
bae2d7ebe3
139c75dfb6
001332d5e9
ec0ea1fd5f

Reviewed By: jurajh-fb

fbshipit-source-id: a8a8ff6a7fddeaa7bbccb3faa6a737c50d22cfe2
2023-02-16 13:23:03 -08:00
Open Source Bot
d87c3e2fc2 Updating submodules
Summary:
GitHub commits:

18294192d9
9aeeaf4933
00487c1ef0
47dde7c249
a5896785bd
f49cabca9b
6360c716c4
0f4c5091d5
3b92270a17
c6a9eec37f
9eef2630ff
44c80b714f

Reviewed By: jurajh-fb

fbshipit-source-id: 646e16718698763a5ac2e47257e5106338b4385b
2023-02-16 12:26:17 -08:00
Saul Gutierrez
5623824c4a add track calls for operations being run
Summary: Adds analytics for commands run by `runOrQueueOperation`, (e.g., `hg pull`, `hg rebase`)

Reviewed By: evangrayk

Differential Revision: D43333621

fbshipit-source-id: 7b067712d85052501fb84b1ad349503c31b481b6
2023-02-16 11:37:36 -08:00
Mark Shroyer
aa1c841302 Fetch source archive if cached artifact's built_marker is missing (#4035)
Summary:
X-link: https://github.com/facebookincubator/velox/pull/4035

If getdeps finds a cached build artifact, it currently skips fetching the
source archive, which is done by calling `fetcher.update()`:
https://www.internalfb.com/code/fbsource/[f64171219e95f47c81929cde0a09e720e079dd31]/fbcode/opensource/fbcode_builder/getdeps.py?lines=691

But without the built_marker, the script will still create a builder for the
artifact:
https://www.internalfb.com/code/fbsource/[f64171219e95f47c81929cde0a09e720e079dd31]/fbcode/opensource/fbcode_builder/getdeps.py?lines=600

This then fails when the builder tries to extract the missing source archive.
In Boost's case:
https://www.internalfb.com/code/fbsource/[f64171219e95f47c81929cde0a09e720e079dd31]/fbcode/opensource/fbcode_builder/getdeps/builder.py?lines=1021

This logic seems to have been broken for a while, but became a problem after
watchman's Windows build started finding cached boost and ninja artifacts that
were missing the built_marker, presumably uploaded by other projects as a
result of D42996394 (e03e1e7a89).

This change fixes the broken watchman build, but itself doesn't get us back to
using cached artifacts.

Reviewed By: kmancini

Differential Revision: D43260530

fbshipit-source-id: ac0072f213a534aada4046d34fe090510fc5d618
2023-02-16 11:31:40 -08:00
Muir Manders
f8c485ea45 sparse: filter excluded files from "status" output
Summary:
Previously if the dirstate and working copy were out of sync with regard to the sparse profile, the Python "sl status" would report modified files even if they were excluded in the sparse profile. Fix by applying the sparse matcher in dirstate.status().

This fixes "sl status" to be consistent with "sl commit", "sl diff", etc. in that it filters out files not in the sparse profile.

Note that this does not fix the reverse case where a file was added to .hg/sparse without going through "hg". The file won't be tracked until "hg sparse include" or "hg sparse refresh" is called. Fixing this is more involved, but Jun suggests storing the sparse profile in the dirstate metadata so status can detect out-of-band sparse changes and automatically refresh the (minimal) differences.

Reviewed By: zzl0

Differential Revision: D43256615

fbshipit-source-id: fda28d4fb833ec36c2d57f3be626e325da3be654
2023-02-16 11:25:45 -08:00
Muir Manders
02a53ac21e sparse: add test for incorrect "status" behavior
Summary: The Python "status" command does not skip dirty dirstate entries that are excluded by the sparse profile. These files will not be included in a subsequent "sl commit", which is a good indication this behavior is incorrect.

Reviewed By: zzl0

Differential Revision: D43256616

fbshipit-source-id: f5ee102b15aac708255fc9278c88c414d7e4e0e8
2023-02-16 11:25:45 -08:00
Open Source Bot
ba754feb6f Updating submodules
Summary:
GitHub commits:

ab87d1bdf3
8aa87b270e

Reviewed By: jurajh-fb

fbshipit-source-id: 3916a4ea0655900c376889a7d994b62f6c93d60a
2023-02-16 11:21:36 -08:00
Muir Manders
71d6e67afd github: run "mark pr landed" inline instead of as hook
Summary:
Hooks are annoying since it is hard to control which "sl" binary is used to invoke the hook. Instead, let's just call the landed pr hook inline using the classic extension wrapping technique.

I made a lazy decision to disable the hide-landed-commits logic by default for tests since the additional GH activity requires tests to mock more stuff out that they aren't necessarily testing.

I also moved the enablement of the "github" extension from the sapling config (which is activated when $0 is "sl") to the git config (which is activated when in a git repo). It doesn't seem like GH integration needs to be coupled with the Sapling rebrand.

Fixes #457

Reviewed By: quark-zju

Differential Revision: D43276199

fbshipit-source-id: 3feb7621a037190044c41020e6a965f8b62bc432
2023-02-16 09:29:54 -08:00
Muir Manders
a46a99bd8c prmarker: collapse this extension into "github"
Summary: The "debugprmarker" command can be part of the github extension.

Reviewed By: quark-zju

Differential Revision: D43208768

fbshipit-source-id: efcba0728d9508c9a02cf1361c5e37b35757ac34
2023-02-16 09:29:54 -08:00
generatedunixname89002005287564
3242928a5a Reviewed By: zertosh
Differential Revision: D43345468

fbshipit-source-id: 7426a31a553982fcadbf7cb9ce1d7ceb9f8a49f4
2023-02-16 07:22:02 -08:00
Yan Soares Couto
f89dc068c5 admin: Verify bookmarks should use commit sync outcome
Summary:
This command was not working because it always needs a remapping of the commit, but on this case it was a `EquivalentWorkingCopyAncestor`.

This is probably out of data, as it uses a bunch of manual "CommitSyncer"s instead of using `Syncers` which have both directions and are easier to use.

Reviewed By: mitrandir77

Differential Revision: D43047554

fbshipit-source-id: 5f1050c0009355c735ceba93b3da9697661230b1
2023-02-16 04:57:11 -08:00
Liubov Dmitrieva
4471f2259c reduce logging
Summary: reduce logging

Reviewed By: quark-zju

Differential Revision: D43305544

fbshipit-source-id: d5ff2abc7cb9f95cd978b82d66fc7732c2ba97c9
2023-02-16 03:31:20 -08:00
Egor Tkachenko
593693625f Use poll method on the client side
Summary: Now as the server side has a new poll api, let's use it on the client side. I also improved some scuba logging.

Reviewed By: markbt

Differential Revision: D43143926

fbshipit-source-id: 78756ed7747e7d29ef67f632826a8a63ccef1091
2023-02-16 03:21:49 -08:00
Clara Rull
0367ed8980 logging: pass CAT while writing to "mononoke_bookmark" Scribe Category
Summary:
Writes for mononke_bookmark are failing open with no token attached:
https://fburl.com/scuba/scribe_permission_checker/g3nuspyl
Let's atttach the tokens to avoid this.

We already did this for mononke_new_commit, discussion: https://fb.workplace.com/groups/scribeusers/permalink/24297620729859880/

Reviewed By: genevievehelsel

Differential Revision: D43308218

fbshipit-source-id: 9a72f85afa9b7d181a28bb609e9dfd56e9e7564a
2023-02-16 01:15:14 -08:00
Open Source Bot
299ac6e752 Updating submodules
Summary:
GitHub commits:

f36e34bb34
727da6fdbe

Reviewed By: jurajh-fb

fbshipit-source-id: 1b8db8dc0ffb9a9270de5b79699b02013910cd84
2023-02-15 21:39:23 -08:00