Skip to content

ignore_files used to filter out directories doesn't work #17

@botman99

Description

@botman99

I want to transfer a stream from a remote Perforce server that I can't create virtual streams on (I don't have permissions to create one). I tried to use the 'ignore_files' list to filter out folders that I wanted to ignore, like so:

ignore_files:
- "/FolderOne/.*$"
- "/FolderTwo/.*$"
- "/FoderThree/Stuff/.*$

This fails with "Replication failure: missing elements in target changelist:" when validateSubmittedChange calls ChangelistComparer. The diff always contained files causing it to return false. The original code was this:

srcfiles = set([chRev.localFile for chRev in srclist if chRev.localFile not in filesToIgnore])
targfiles = set([chRev.localFile for chRev in targlist])

...but it seems like both the source and target lists of files should filter out the files being ignored. This seemed to work properly:

srcfiles = set([chRev.localFile for chRev in srclist if chRev.localFile not in filesToIgnore])
targfiles = set([chRev.localFile for chRev in targlist if chRev.localFile not in filesToIgnore])

...and the diff was empty with the 'ignore_files' being excluded and not submitted to the local Perforce server.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions