Skip to content

Paket 5.207.4 broke the FAKE release process and creates empty packages #3599

Closed

Description

@matthid

Description

You can see how I managed to pin it to that particular Paket release: fsprojects/FAKE#2341

In fact, I cannot even reproduce this locally, this only seems to happen in CI and in particular only Azure DevOps and sometimes in GitLab, but only Azure DevOps reproduces 100%

The diff is quite small and only a single PR was involved: 5.207.3...5.207.4

/cc @enricosada

What's really bad is that the packaging process works but creates corrupt packages. The release process did catch the issue, because we bootstrap some of the packages.

You can download and inspect the packages from the build: https://dev.azure.com/fakebuild/FSProjects/_build/results?buildId=1123&view=results

image

I tried to figure out what the problem is as only a single line changed, for example with this commit, but I couldn't figure it out.

So I boiled it down to a single line change in the targets file but I have no clue why or how it leads to broken packages.

Repro steps

Update to 5.207.4 (or newer), see this commit

Expected behavior

Release process should work as it did before

Actual behavior

Paket-change leads to broken packages, which might be detected only after the package has been released without proper validation.

Known workarounds

  • Stay on 5.207.3 or lower
  • Use previous targets file (and force paket to use it, by not calling paket restore or by checking out the old targets afterwards)

Activity

  1. matthid commented on Jun 22, 2019

    @matthid
    MemberAuthor

    It seems like the change leads to paket fix-nuspec not being called anymore in the dotnet pack Fake.sln command

  2. matthid commented on Jun 22, 2019

    @matthid
    MemberAuthor

    Oh my god I figured it out, it took a bit longer because paket was restoring the targets file within the process so all my attempts to add logging failed miserably.

    I added the following warning message:
    <Warning Text='TEST: OutputPath: $(AdjustedNuspecOutputPath), All: "@(MyPaketNuspecFiles)", Version: "$(PackageVersion)", Command: $(PaketCommand) fix-nuspecs files "@(_NuspecFiles)" project-file "$(PaketProjectFile)" ' />

    This is the result:

    TEST: OutputPath: obj\Release, All: "obj\Release\Fake.Api.Slack.5.15.1-alpha.1129.nuspec", Version: "5.15.1-alpha.1129+vsts.2fdb5b21981edf02be1fe6bf2b748197d9ead56d", Command: "d:\a\1\s\.paket\paket.exe" fix-nuspecs files "" project-file "d:\a\1\s\src\app\Fake.Api.Slack/Fake.Api.Slack.fsproj"

    So the problem is that PackageVersion includes the Semver "Build metadata" while the file doesn't...

    @enricosada Any idea how to fix? Is there another msbuild variable we could use?

  3. matthid commented on Jun 22, 2019

    @matthid
    MemberAuthor

    I think we need at least:

    • Error out if we cannot found a nuspec at all
    • Fix the issue at hand and add a test ...
  4. forki commented on Jun 23, 2019

    @forki
    Member
  5. matthid commented on Jun 23, 2019

    @matthid
    MemberAuthor

    @forki I'd like to but I don't know how to fix, the only thing that probably works is reverting that PR :/

  6. forki commented on Jun 23, 2019

    @forki
    Member

    Ok. Please send me a pr with the revert and then we need to talk to @enricosada to find a new approach

  7. forki commented on Jun 23, 2019

    @forki
    Member

    Or never mind. I'll do the revert myself

  8. matthid commented on Jun 23, 2019

    @matthid
    MemberAuthor

    Give me a bit, I might find another solution

  9. added a commit that references this issue on Jun 23, 2019
    b5c8b14
  10. matthid commented on Jun 23, 2019

    @matthid
    MemberAuthor

    See #3600, it is a bit of a hack so we probably should let the CI test it

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions