Repository navigation
Description
I found this while updating my paket dependencies in my project FReD and I am able to reproduce in a newly created project.
I haven't tested on Windows yet and TravisCI was able to build without problems:
It may be related to fsprojects/FSharp.Formatting#328
Environment
OSX 10.10.4
$ mono --version
Mono JIT compiler version 4.0.3 ((detached/d6946b4 Wed Jul 29 14:46:23 EDT 2015)
Copyright (C) 2002-2014 Novell, Inc, Xamarin Inc and Contributors. www.mono-project.com
TLS: normal
SIGSEGV: altstack
Notification: kqueue
Architecture: x86
Disabled: none
Misc: softdebug
LLVM: yes(3.6.0svn-mono-(detached/a173357)
GC: sgen
Updated today to the latest stable version of Xamarin Studio
$ fsharpc
F# Compiler for F# 3.1 (Open Source Edition)
Freely distributed under the Apache 2.0 Open Source License
packet.dependencies
source https://nuget.org/api/v2 nuget FSharp.Formatting nuget NUnit nuget NUnit.Runners nuget FAKE nuget SourceLink.Fake nuget FSharp.Data github fsharp/FAKE modules/Octokit/Octokit.fsx
Steps to reproduce
- Clone ProjectScaffold repository
- run build.sh
- Fill in the project name and answer (or leave blank) all other questions
Expected behaviour
- A new project should be scaffolded and configured
- Build should complete successfully
Actual Behaviour
- A new project is generated and configured
- An error is reported on first build:
Generating '/Users/edhzsz/random_github_repos/testPS/ProjectScaffold/docs/tools/../content/index.html' FSharp.Formatting Critical: 0 : Processing the file 'docpage' failed Source written to: '/var/folders/14/k9w9t10j2s1dxc8yrpjxrr040000gn/T/tmp221b3e9a.tmp.cs' Compilation errors: - warning: (0, 0) Assuming assembly reference `FSharp.Core, Version=4.3.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' matches assembly `FSharp.Core, Version=4.3.1.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'. You may need to supply runtime policy - error: (0, 0) Assembly `FakeLib, Version=4.1.1.0, Culture=neutral, PublicKeyToken=null' references `FSharp.Core, Version=4.4.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' which has a higher version number than imported assembly `FSharp.Core, Version=4.3.1.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'
FAKE is referencing FSharp.Code 4.4 since FAKE 4.1.0
Workaround
Modify packet.dependencies and use FAKE version 4.0.0
nuget FAKE = 4.0.0
Build is successful with FAKE 4.0.0
Activity
edhzsz commentedon Oct 10, 2015
I am still able to reproduce the issue after updating everything to the latests.
Updated Environment
OSX 10.11
$ mono --version Mono JIT compiler version 4.0.4 ((detached/d481017 Mon Sep 28 17:32:19 EDT 2015) Copyright (C) 2002-2014 Novell, Inc, Xamarin Inc and Contributors. www.mono-project.com TLS: normal SIGSEGV: altstack Notification: kqueue Architecture: x86 Disabled: none Misc: softdebug LLVM: yes(3.6.0svn-mono-(detached/a173357) GC: sgenUpdated today to the latest stable version of Xamarin Studio
packet.dependencies
packet.lock
NUGET remote: https://nuget.org/api/v2 specs: FAKE (4.0.0) FSharp.Compiler.Service (0.0.90) FSharp.Data (2.2.5) Zlib.Portable (>= 1.10.0) - framework: portable-net40+sl50+wp80+win80 FSharp.Formatting (2.11.0) FSharp.Compiler.Service (>= 0.0.90 <= 1.3) FSharpVSPowerTools.Core (1.9.0) FSharpVSPowerTools.Core (1.9.0) FSharp.Compiler.Service (>= 0.0.90) Microsoft.Bcl (1.1.10) Microsoft.Bcl.Build (>= 1.0.14) Microsoft.Bcl.Build (1.0.21) - import_targets: false Microsoft.Net.Http (2.2.29) Microsoft.Bcl (>= 1.1.10) Microsoft.Bcl.Build (>= 1.0.14) NUnit (2.6.4) NUnit.Runners (2.6.4) Octokit (0.16.0) Microsoft.Net.Http SourceLink.Fake (1.1.0) Zlib.Portable (1.11.0) - framework: portable-net40+sl50+wp80+win80 GITHUB remote: fsharp/FAKE specs: modules/Octokit/Octokit.fsx (7543f29800c1245a04f96b5f1be063b0568fd5d6) OctokitUpdating packages
Building
With FAKE version 4.0.0 the build is successful.
matthid commentedon Nov 22, 2015
fixed in #217.
Problem is FakeLib references F#4 while we are running with F#3.1. RazorEngine uses the loaded assemblies as references for compiling templates and the C# compiler doesn't like the missmatch...