Skip to content
Snippets Groups Projects
This project is mirrored from https://github.com/haskell/Cabal. Pull mirroring updated .
  1. Apr 07, 2024
  2. Apr 06, 2024
  3. Apr 04, 2024
    • Phil de Joux's avatar
      Show provenance of import constraint · f8cd5634
      Phil de Joux authored
      With this change to the solver message rendering, I also fix some bugs around project imports, adding tests for those cases. Reviewers asked that the Y-shaped import checks (using IORef) be made on a separate pull request. Removing those lead to cascading deletions.
      
      - Regenerate expected .out files
      - Show tree provenance of import constraint
      - Add trimmed down PackageTests/VersionPriority
      - Add changelog entry
      - Use NonEmpty
      - Fix check for cyclical import
      - Use primes for next iteration
      - Remove unused LANGUAGE pragmas
      - Rename to projectConfigPathRoot
      - Docs for ProjectConfigPath and showProjectConfigPath
      - Renaming
      - Add cyclical import tests with 1 and 2 hops in cycle
      - Use full path for cyclical error message
      - Expected output has project with full project path
      - Add fullPath local function
      - Project directory as FilePath, not Maybe FilePath
      - Use (_, projectFileName) binding splitFileName
      - Need full path to project parsing legacy
      - Inline seenImports conversion
      - Add cyclical checks with same file names and hops
      - Add noncyclical tests that hop over folders
      - Add a project testing skipping in and out of a folder
      - Update expectations of cyclical tests
      - Use canonicalizePath for collapsing .. when possible
      - Capture trace for later
      - Add module for ProjectConfigPath
      - Move functions for ProjectConfigPath to its module
      - Fetch URI is not prefixed with ./https://etc
      - Document normaliseConfigPath
      - Add doctests for normaliseConfigPath
      - Add doctest of canonicalizeConfigPath
      - Show an example of canonical paths
      - Use importer and importee in canonicalizeConfigPaths
      - Add logging
      - Use normLocPath, drop -XMultiWayIf
      - Remove seenImports parameter from parseProject
      - Follow hlint suggestion: Move brackets to avoid $
      - Follow hlint warning: Use mapM
      - Follow hlint warning: Use traverse_
      - Follow hlint suggestion: Use <$>
      - Add failing test skipping across folder
      - Remove normaliseConfigPath
      - Add hasDuplicatesConfigPath
      - Remove lengthConfigPath and nubConfigPath
      - Mention cabal-install-solver in the changelog
      - Left align project import tree with other content
      - Rerun tests to generate left-aligned tree output
      - Don't show "constraint from project requires ..."
      - Regenerate test outputs without (constraint from project ...)
      - Move fail reason printing to project config path module
      - Minimize diff of showFR
      - Show an "imported by: " list instead of a tree
      - Update info logging, avoiding leading spaces
      - When logging I found leading spaces were trimmed
      - Don't log relative location and path
      - Use unicode tree symbol in haddocks
      - A duplicate importing tests
      - Add Y-forking import test
      - A test for detecting when the same config is imported via many different paths
      - Fix a typo with ../noncyclical-same-filename-b.config
      - Add an intercepting cabal-testsuite/cabal.project
      - Use IORef to detect seen imports
      - Get rid of seenImports
      - Use IORef [FilePath] of uniqueImports
      - Add consProjectConfigPath
      - Expand the haddocks of newtype ProjectConfigPath
      - Clarify, it's the project root directory
      - Rename a function to makeRelativeConfigPath
      - Fix whitespace
      - Update output snippet in changelog
      - Put the info logging together
      - Split cycles and duplicates detection
      - Add fixes and duplicate import to the change log
      - Better reporting of duplicate imports
      - Report cycles and duplicates using unique file name
      - This is after canonicalizeConfigPath, relative to the project directory
      - Get rid of fullLocPath, use normLocPath only
      - Do reporting using paths relative to the directory of the project
      - Issue a warning for Y-shaped duplicate imports
      - Add duplicateImportMsg
      - Use pretty printing for duplicate import message
      - Use pretty printing for all ProjectConfigPath printing
      - Drop a parameter from duplicateImportMsg
      - Correct haddocks on docProjectConfigPath
      - Satisfy fourmolu
      - Remove the surplus space in "imported by "
      - Log project parsing at the debug level, up from info
      - Simplify the changelog snippet
      - Use normalized paths for solver messages
      - Satisfy fourmolu
      - Relative to the directory of the project
      - Duplicate imports are reported as warnings
      - No need to mention v2-build
      - Remove IORef
      - Subdue a check for duplicate imports
      - TODO: Catch duplicates across different import paths. We know how to do this
      - Remove check for duplicate imports
      - Improve the canonicalizeConfigPath doctests
      - Add haddocks, drop configPath from go
      - Make importsBy NonEmpty
      - Use testDir in doctests
      - Use canonical test directory
      - Regenerate expected outputs
      - Assume head of the path is the duplicate
      - Get rid of duplicateImportMsg
      - Remove unused imports in ProjectConfigPath
      - Follow hlint suggestion: use fewer imports
      - Remove fullConfigPathRoot
      - Follow hlint suggestion: redundant bracket
      - Use the original "source" variable name
      - Put the source next to its contents
      - Go with the original "seenImports" variable name
      - Avoid -XMultiWayIf
      - Not needed since we aren't checking for duplicates right now
      - Be consistent in naming sources
      - Move project dir alongside related params
      - Rename to pathRequiresVersion
      - Add back "constraint from"
      - Talk only of cycles and not duplicates
      - Don't report line number for cyclical import
      - Remove 2nd example in changelog
      - Remove Y-forked duplicate import test
      - Add "imported by" to assertOutputContains
      - Cull excess doctests of canonicalizeConfigPath
      - Add deep path doctest
      - Update haddocks of canonicalizeConfigPath
      - remove idempotent speculation (it isn't idempotent)
      - use "indirection" to describe "." and ".."
      - makes the path relative to the given directory
      - Remove seenImports
      - Use Explicit ProjectConfigPath
      - Missed one "constraint from" in changelog example
      - Don't check (verbosity >= verbose) separately
      - While the same level of verbosity as info, it is clearer to not check the level separately.
      - Might calculate the path but not use it.
      - Add AbsoluteDir
      - Keep provenance normalised for display
      - Remove stale REVIEW comment
      - Storing provenance normalized avoids this
      - Fix whitespace
      - Satisfy HLint warning: Redundant flip
      - Gut the repo/hashable packages
      - Revert AbsoluteDir to FilePath
  4. Apr 03, 2024
    • mergify[bot]'s avatar
      Merge pull request #9718 from mpickering/wip/work-dir · 738e4192
      mergify[bot] authored
      Make Cabal agnostic about working directory
    • sheaf's avatar
      Make Cabal agnostic about working directory · 7b905832
      sheaf authored
      This commit makes the library functions in Cabal agnostic of the working
      directory. In practice, this means that we distinguish `FilePath`s
      from un-interpreted `SymbolicPath`s. The latter may be paths that are
      relative to the working directory, and need to be interpreted with
      respect to a passed-in argument specifying the working directory,
      instead of using the working directory of the current process.
      See Note [Symbolic paths] in Distribution.Utils.Path.
      
      In particular, paths in the package description now use the SymbolicPath
      abstraction, which allows specifying whether they are allowed to be
      absolute, and, if they are relative, what they are relative to.
      For example, source files are relative to a source search directory,
      data files are relative to the data directory, and doc files are
      relative to the package root.
      
      Fixes #9702
      7b905832
  5. Apr 02, 2024
  6. Mar 31, 2024
  7. Mar 30, 2024
  8. Mar 29, 2024
  9. Mar 26, 2024
    • Phil de Joux's avatar
      Ignore testdb/intree generated files · 57b961ca
      Phil de Joux authored
    • Phil de Joux's avatar
      Merge pull request #9565 from cabalism/import/pkg-groups · 7e085faf
      Phil de Joux authored
      Use package groups
    • Phil de Joux's avatar
      Remove projects; weeder, doctest & libonly · 72be26bd
      Phil de Joux authored
      * Remove cabal.project.libonly
      
      It was only referenced once in a stale Makefile comment about doctests.
      
      * Remove weeder
      
      - remove weeder's configuration
      - remove its recipe from Makefile
      - remove its project
      
      * Delete cabal.project.doctest
      
      - Adding --ghc-options="-Wwarn" is sufficient to avoid the numerous <interactive> failures seen otherwise
      - write-ghc-environment-files has a default of never
    • Phil de Joux's avatar
    • Phil de Joux's avatar
    • Phil de Joux's avatar
      Add an intercepting cabal-testsuite/cabal.project · d3362759
      Phil de Joux authored
      - Reduce duplication in test flag setup
      - Avoid "New config" picking cabal's own project
      
      Before this change, this was the test failure:
      
      Unit Tests
        UnitTests.Distribution.Client.Configure
          Configure tests
            New config:                     FAIL
              Exception: project-cabal/pkgs/cabal.config: withBinaryFile: does not exist (No such file or directory)
              Use -p '/New config/' to rerun this test only.
            Replacement + new config:       OK
            Old + new config:               OK
            Old + new config, no appending: OK
            Old + new config, backup check: OK
            Local program options:          OK
      
      1 out of 6 tests failed (0.02s)
    • Phil de Joux's avatar
      Build all local packages with -Werror · 8453ee0b
      Phil de Joux authored
      - Satisfy -Wmissing-signatures in test-runtime-deps
      - Satisfy -Wx-partial in HackageBenchmark
      - Satisfy -Wunused-imports in QuickCheck.Instances.Cabal
      - Use partial pattern for filtering in list comprehension
      - Don't error on deprecated import
    • Phil de Joux's avatar
      Import packages from project-cabal/pkgs · 0876e187
      Phil de Joux authored
      - Move constraints to project-cabal/constraints.config
      - Remove duplicate package groups
      - Groups coverage, doctest and validate are the same as the default group
      - Remove duplicate validate-libonly package group
      - Both validate and validate-libonly are the same
      - Move Cabal & Cabal-syntax to pkgs/cabal.config
      - Add install package group
      - Add benchmarks package group
      - Add tests package group
      - Both default and libonly groups were the same set of packages that I renamed to tests
      - Put install group before tests and benchmarks
      - Don't repeat packages
      - Add TODO and REVIEW comments on allow-newer exceptions
      - Move latest.ghc configuration
      - Put program-options first & separate imports
      - Remove optional-packages
      - Don't reiterate default value for tests and benchmarks
      - Don't reiterate default value for optimization
      - Add ghc-options.config
      - Rename to ghc-latest.config
      - Use -Werror in ghc-options.config
      - Don't include ghc-options.config for doctest project
      - Add project-config/pkgs.config
      - Add project-config/pkgs.config importing all package groups
      - Move Cabal-described to the cabal package group
      - Remove cabal.project.buildinfo
      - Have cabal.project.doctest import cabal.project
      - Split integration tests into their own package group.
      - Add back trailing newlines at EOF in projects
      - Integration-tests.config needed for libonly
      - Add a README for projects.
  10. Mar 22, 2024
  11. Mar 20, 2024
Loading