Skip to content

Unable to generate logs at the specified location. #6811

Open

Description

@awasthishubh

Describe the bug
I am currently working on updating Hackage builder to cabal v2 as a part of GSoC Project.
The objective was to build the package, run tests, create Haddock doc and run code-coverage.
I need the report of each of these tasks in the specified files. I tried setting the flags to make cabal write test log, build-summary, logs and docs at the specified location but it doesn't seem to work.

To Reproduce
In the root directory of a package (async in this case), I ran the following code.

$ cabal v2-build \
	--enable-tests \
	--run-tests \
	--test-log="/home/USER/haskell/test.log" \
	--haddock-for-hackage \
	--enable-doc \
	--docdir="/home/USER/haskell/" \
	--enable-coverage \
	--build-summary="/home/USER/haskell/r.report" \
	--build-log="/home/USER/haskell/r.log" \
	--remote-build-reporting=detailed \
	--report-planning-failure

Expected behavior
Specified files must have a log or report content.

System information

  • Ubuntu 20.0.4
  • ghc version: 8.8.3
  • cabal version: 3.2.0.0

Additional context
How can we set coverage report, doc tarball location?

Activity

  1. gbaz commented on May 17, 2020

    @gbaz
    Collaborator

    I think there are two independent questions here. The test stuff can at least get rum from the test command. Even without that though, the build-summary and build-log don't seem to get generated at all from my experiments? What's the correct way to get them in v2?

  2. self-assigned this
    on Aug 28, 2021
  3. ulysses4ever commented on Jun 7, 2022

    @ulysses4ever
    Collaborator

    @jneira could you comment on the label “not our bug” (which you added): I don’t quite get why it’s not “our”…

  4. jneira commented on Jun 7, 2022

    @jneira
    Member

    me neither 😅
    it was a misclick I suppose, thanks for noting it

  5. ulysses4ever commented on Jun 11, 2022

    @ulysses4ever
    Collaborator

    Looks similar to #5901.

  6. andreabedini commented on Jul 11, 2023

    @andreabedini
    Collaborator

    TIL about --run-tests; it seems confusing though as the documentation says "Run the package test suite upon installation" but there's no installation if you pass it to cabal build; it also mentions a hash maybe it means the store? It sounds dangerous to mix up installation with the cabal store as they are different concepts.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions