Skip to content

Regression: local repository file+noindex ignores noindex part #9891

@alt-romes

Description

Describe the bug
Having a cabal project with a local repository using url: file+noindex://... works with cabal 3.10.2.1 but fails with HEAD.

To Reproduce

cabal init -m -n --simple --lib
mkdir repo
echo "packages: ." > cabal.project
echo "repository local" >> cabal.project
echo "  url: file+noindex://$(pwd)/repo" >> cabal.project

Then, building with cabal from HEAD will produce an error message like the following:

Error during construction of local+noindex local repository index:
/var/folders/tv/35hlch6s3y15hfvndc71l6d40000gn/T/tmp.umaedU6Xpe/repo/noindex.cache:
openBinaryFile: does not exist (No such file or directory)

If your package depends on a package from the local repository the build will simply fail.

Then, building with cabal-3.10.2.1 will succeed. In fact, it looks like cabal-3.10.2.1 will create a noindex.cache file in the repository.

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions