Skip to content

Build fails with Octokit path not found #62

Open

Description

@houstonhaynes

I'm working on my own fork of tryFSharp for my personal site - fsharpnotes.net

I've updated the global.json to using .NET 6 and otherwise haven't done anything special. When I run

fake run build.fsx -t "WatchApp"

I get a path error that (by the eye, at least) should resolve. In fact there are multiple references to the path, which in and of itself is a bit odd. Can anyone weigh in on why this is happening? Is there something I missed along the way - beyond paket restore/build ? Thanks!

image

Activity

  1. houstonhaynes commented on Aug 19, 2023

    @houstonhaynes
    Author

    Update - I hand-jammed a path to the ref and started getting a smaller set of slighly more interesting errors. Most of them were asking for specific type annotations for FakeHelpers such as

    let loadReleaseNotes projFile =
        let projDir =
            if (Path.HasExtension(projFile: string)) // **here**
            then Path.GetDirectoryName(projFile)
            else projFile
        findFileUpwards RELEASE_NOTES projDir
        |> ReleaseNotesHelper.LoadReleaseNotes
    
    let needsPublishing silent (readVersionInLine: string->string option) (releaseNotes: ReleaseNotes) projFile =
        let print msg =
            if not silent then
                let projName =
                    let projName : string = Path.GetFileNameWithoutExtension(projFile: string) // **here**
                    if projName = "package" // package.json
                    then Path.GetFileName(Path.GetDirectoryName(projFile))
                    else projName
                printfn "%s > %s" projName msg
        if releaseNotes.NugetVersion.ToUpper().EndsWith("NEXT")
        then
            print "Version in Release Notes ends with NEXT, don't publish yet."
            false
        else
            File.ReadLines(projFile)
            |> Seq.tryPick readVersionInLine
            |> function
                | None -> failwithf "Couldn't find version in %s" projFile
                | Some version ->
                    let sameVersion = version = releaseNotes.NugetVersion
                    if sameVersion then
                        sprintf "Already version %s, no need to publish" releaseNotes.NugetVersion |> print
                    not sameVersion

    This got me as far as this (verbose) output. Again - it seems to not know how to find FakeLib, which is present in the folder structure. I suspect this might be a "Fake upgrade" issue as suggested in the log but I'm not sure how to proceeed - as the instructions don't line up with what I see in the project. Perhaps his is a pre-v4 version of Fake?

    console_log.ps1.txt

  2. houstonhaynes commented on Aug 22, 2023

    @houstonhaynes
    Author

    So I'm making progress - but still a bit befuddled by an error message which shouldn't exist. I'm looking right at the DLL file and the build.fsx referencing the path. I have no idea why the script error is occurring.

    image

  3. MangelMaxime commented on Aug 22, 2023

    @MangelMaxime

    Right now, I don't have a lot of ideas.

    Are you able to load the .dll file and use it from a "normal" fsx file? Running it using dotnet fsi my-file.fsx.

    In the past FAKE, was doing additional stuff for loading dependencies so perhaps something is wrong with it.

  4. houstonhaynes commented on Aug 23, 2023

    @houstonhaynes
    Author

    OK - thanks for chiming in. I'll keep banging away at it. My hope was that the "path not found" (where the path is clearly present) was actually some other error. I'll try what you suggest and do a bit more digging later in the day (local time).

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