-
Notifications
You must be signed in to change notification settings - Fork 696
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- A test for detecting when the same config is imported via many different paths - Error on duplicate imports - Do the filtering in duplicateImportMsg - Use duplicateImportMsg for cycles too - Add haddocks to IORef parameter - Add changelog entry - Use ordNub instead of nub - Use NubList - Share implement of duplicate and cyclical messages - Update expectation for non-cyclical duplicate import
- Loading branch information
1 parent
cc2c9d8
commit 06065fb
Showing
15 changed files
with
127 additions
and
19 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
7 changes: 7 additions & 0 deletions
7
cabal-testsuite/PackageTests/ConditionalAndImport/yops-0.project
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
packages: . | ||
|
||
import: yops/yops-1.config | ||
import: yops/yops-3.config | ||
import: yops/yops-5.config | ||
import: yops/yops-7.config | ||
import: yops/yops-9.config |
1 change: 1 addition & 0 deletions
1
cabal-testsuite/PackageTests/ConditionalAndImport/yops-2.config
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
import: yops/yops-3.config |
1 change: 1 addition & 0 deletions
1
cabal-testsuite/PackageTests/ConditionalAndImport/yops-4.config
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
import: yops/yops-5.config |
1 change: 1 addition & 0 deletions
1
cabal-testsuite/PackageTests/ConditionalAndImport/yops-6.config
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
import: yops/yops-7.config |
1 change: 1 addition & 0 deletions
1
cabal-testsuite/PackageTests/ConditionalAndImport/yops-8.config
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
import: yops/yops-9.config |
1 change: 1 addition & 0 deletions
1
cabal-testsuite/PackageTests/ConditionalAndImport/yops/yops-1.config
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
import: ../yops-2.config |
1 change: 1 addition & 0 deletions
1
cabal-testsuite/PackageTests/ConditionalAndImport/yops/yops-3.config
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
import: ../yops-4.config |
1 change: 1 addition & 0 deletions
1
cabal-testsuite/PackageTests/ConditionalAndImport/yops/yops-5.config
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
import: ../yops-6.config |
1 change: 1 addition & 0 deletions
1
cabal-testsuite/PackageTests/ConditionalAndImport/yops/yops-7.config
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
import: ../yops-8.config |
1 change: 1 addition & 0 deletions
1
cabal-testsuite/PackageTests/ConditionalAndImport/yops/yops-9.config
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
-- No imports here |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
synopsis: Detect non-cyclical duplicate project imports | ||
description: | ||
Detect and report on duplicate imports that are non-cyclical and expand the | ||
detail in cyclical import reporting, being more explicit and consistent with | ||
non-cyclical duplicate reporting. | ||
|
||
``` | ||
$ cabal build --project-file=yops-0.project | ||
... | ||
Error: [Cabal-7090] | ||
Error parsing project file yops-0.project: | ||
duplicate import of yops/yops-3.config; | ||
yops/yops-3.config | ||
imported by: yops-0.project | ||
yops/yops-3.config | ||
imported by: yops-2.config | ||
imported by: yops/yops-1.config | ||
imported by: yops-0.project | ||
``` | ||
|
||
packages: cabal-install-solver cabal-install | ||
prs: #9578 #9933 | ||
issues: #9562 |