Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork209
Closed
Description
When parsing a file that was copied in a raw pull request .diff, UnifiedDiffReader will fail with:
com.github.difflib.unifieddiff.UnifiedDiffParserException: expected file start line not foundat com.github.difflib.unifieddiff.UnifiedDiffReader.parse(UnifiedDiffReader.java:120)To Reproduce
- Obtain the .diffs via bitbucket API of a PR that has a copy of a file, e.g.:
diff --git src://modules/configuration/config/web/pcf/account/AccountContactCV.pcf dst://modules/configuration/config/web/pcf/account/AccountContactCV.default.pcfsimilarity index 99%copy from modules/configuration/config/web/pcf/account/AccountContactCV.pcfcopy to modules/configuration/config/web/pcf/account/AccountContactCV.default.pcfindex 13efef5778..1a08b0befc 100644--- src://modules/configuration/config/web/pcf/account/AccountContactCV.pcf+++ dst://modules/configuration/config/web/pcf/account/AccountContactCV.default.pcf@@ -1,16 +1,17 @@ <?xml version="1.0"?> <PCF xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../pcf.xsd"> <CardViewPanel- >+ + mode="default"> <Require name="acctContact" type="AccountContact"/> <Require name="showAddressTools" type="boolean"/> <Require name="showRolesTab" type="boolean"/> <VariableNotice how the file that was being looked by UnifiedParseDiff does not exist here, and the new copy should have been used instead (AccountContactCV.default.pcf)
Expected behavior
The correct file should be parsed and/or consider the original one removed.
System
- Java 17
- 4.12(latest)
Metadata
Metadata
Assignees
Labels
No labels

