( )⚙ D3902 prefetch: do not attempt to prefetch treemanifests as files

This is an archive of the discontinued Mercurial Phabricator instance.

prefetch: do not attempt to prefetch treemanifests as files
ClosedPublic

Authored by spectral on Jul 10 2018, 2:39 PM.
Tags
None
Subscribers
None

Details

Summary

When using narrow, we get entries from ctx.walk() that aren't files, they're the
roots of ignored/excluded trees. These paths end with a /, so just skip them
when doing the walk.

Example narrowspec:

[include]
path:foo/bar
[exclude]

Example repo:

foo/bar/file1.txt
foo/baz/file2.txt

When walking, we'll see:

foo/bar/file1.txt
foo/baz/

Diff Detail

Repository
rFBHGX Facebook Mercurial Extensions
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

spectral created this revision.Jul 10 2018, 2:39 PM
Herald added a reviewer: Restricted Project. · View Herald TranscriptJul 10 2018, 2:39 PM
quark accepted this revision.Jul 10 2018, 5:53 PM
This revision is now accepted and ready to land.Jul 10 2018, 5:53 PM
This revision was automatically updated to reflect the committed changes.