Comments (8)
- Which version of fsautocomplete are you using?
- Which versions of VS do you have installed, and which did you use to create this project file?
- Please can you post the whole project file so I can try to reproduce?
from fsautocomplete.
Hello @rneatherway :) Thank you for the quick reply.
- I'm using version 0.23.0 of fsautocomplete. EDIT: I checked and it doesn't work on 0.24.1 either.
- Visual Studio Community 2015, Version 14.0.23107.0
- The project file is nothing more than the
fs
file given above, used inside a template project (Visual F#: Console Application).
Here is a copy-paste:
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="14.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<SchemaVersion>2.0</SchemaVersion>
<ProjectGuid>ed7b037a-ea4f-4892-aa77-5595939ae3f7</ProjectGuid>
<OutputType>Exe</OutputType>
<RootNamespace>FsAutoComplete_repro</RootNamespace>
<AssemblyName>FsAutoComplete_repro</AssemblyName>
<TargetFrameworkVersion>v4.5.2</TargetFrameworkVersion>
<AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects>
<TargetFSharpCoreVersion>4.4.0.0</TargetFSharpCoreVersion>
<Name>FsAutoComplete-repro</Name>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<Tailcalls>false</Tailcalls>
<OutputPath>bin\Debug\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<WarningLevel>3</WarningLevel>
<PlatformTarget>AnyCPU</PlatformTarget>
<DocumentationFile>bin\Debug\FsAutoComplete_repro.XML</DocumentationFile>
<Prefer32Bit>true</Prefer32Bit>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<Tailcalls>true</Tailcalls>
<OutputPath>bin\Release\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<WarningLevel>3</WarningLevel>
<PlatformTarget>AnyCPU</PlatformTarget>
<DocumentationFile>bin\Release\FsAutoComplete_repro.XML</DocumentationFile>
<Prefer32Bit>true</Prefer32Bit>
</PropertyGroup>
<ItemGroup>
<Reference Include="mscorlib" />
<Reference Include="FSharp.Core, Version=$(TargetFSharpCoreVersion), Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<Private>True</Private>
</Reference>
<Reference Include="System" />
<Reference Include="System.Core" />
<Reference Include="System.Numerics" />
</ItemGroup>
<ItemGroup>
<Compile Include="AssemblyInfo.fs" />
<Compile Include="Program.fs" />
<None Include="App.config" />
</ItemGroup>
<PropertyGroup>
<MinimumVisualStudioVersion Condition="'$(MinimumVisualStudioVersion)' == ''">11</MinimumVisualStudioVersion>
</PropertyGroup>
<Choose>
<When Condition="'$(VisualStudioVersion)' == '11.0'">
<PropertyGroup Condition="Exists('$(MSBuildExtensionsPath32)\..\Microsoft SDKs\F#\3.0\Framework\v4.0\Microsoft.FSharp.Targets')">
<FSharpTargetsPath>$(MSBuildExtensionsPath32)\..\Microsoft SDKs\F#\3.0\Framework\v4.0\Microsoft.FSharp.Targets</FSharpTargetsPath>
</PropertyGroup>
</When>
<Otherwise>
<PropertyGroup Condition="Exists('$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)\FSharp\Microsoft.FSharp.Targets')">
<FSharpTargetsPath>$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)\FSharp\Microsoft.FSharp.Targets</FSharpTargetsPath>
</PropertyGroup>
</Otherwise>
</Choose>
<Import Project="$(FSharpTargetsPath)" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
</Target>
<Target Name="AfterBuild">
</Target>
-->
</Project>
from fsautocomplete.
Note that it compiles fine with fsc
and with MSBuild
from the command line.
Also, the same error occurs in fsautocomplete even if I don't provide a project file:
fsautocomplete.exe
parse "Project.fs"
module M
open System.Diagnostics
let p = Process.GetProcessesByName "fsi"
<<EOF>>
{"Kind":"info","Data":"Background parsing started"}
{"Kind":"errors","Data":[{"FileName":"D:\\Code\\fsharp-repro\\FsAutoComplete-repro\\Project.fs","StartLine":2,"EndLine":2,"StartColumn":9,"EndColumn":16,"Severity":"Error","Message":"The namespace or module 'Process' is not defined","Subcategory":"typecheck"}]}
But no error if I try to use, for instance, System.Console.WriteLine
:
fsautocomplete.exe
parse "Project.fs"
module M
open System
System.Console.WriteLine "hello world"
<<EOF>>
{"Kind":"info","Data":"Background parsing started"}
{"Kind":"errors","Data":[]}
from fsautocomplete.
Can you paste the output of the compilation from the command line, most importantly the arguments given to fsc
by msbuild
.
from fsautocomplete.
Microsoft (R) Build Engine version 14.0.23107.0
Copyright (C) Microsoft Corporation. All rights reserved.
Build started 30/09/2015 12:34:08.
Project "D:\Code\fsharp-repro\FsAutoComplete-repro\FsAutoComplete-repro.fsproj" on node 1 (default targets).
GenerateBindingRedirects:
No suggested binding redirects from ResolveAssemblyReferences.
GenerateTargetFrameworkMonikerAttribute:
Skipping target "GenerateTargetFrameworkMonikerAttribute" because all output files are up-to-date with respect to the input files.
CoreCompile:
C:\Program Files (x86)\Microsoft SDKs\F#\4.0\Framework\v4.0\fsc.exe -o:obj\Debug\FsAutoComplete_repro.exe -g --debug:full --noframework --define:DEBUG --define:TRACE --doc:bin\Debug\FsAutoComplete_repro.XML --optimize- --tailcalls- --platform:anycpu32bitpreferred -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\FSharp\.NETFramework\v4.0\4.4.0.0\FSharp.Core.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.5.2\mscorlib.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.5.2\System.Core.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.5.2\System.dll" -r:"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.5.2\System.Numerics.dll" --target:exe --warn:3 --warnaserror:76 --fullpaths --flaterrors --subsystemversion:6.00 --highentropyva+ "D:\cygwin64\tmp\.NETFramework,Version=v4.5.2.AssemblyAttributes.fs" AssemblyInfo.fs Program.fs
_CopyFilesMarkedCopyLocal:
Copying file from "C:\Program Files (x86)\Reference Assemblies\Microsoft\FSharp\.NETFramework\v4.0\4.4.0.0\FSharp.Core.dll" to "bin\Debug\FSharp.Core.dll".
Copying file from "C:\Program Files (x86)\Reference Assemblies\Microsoft\FSharp\.NETFramework\v4.0\4.4.0.0\FSharp.Core.xml" to "bin\Debug\FSharp.Core.xml".
_CopyAppConfigFile:
Copying file from "App.config" to "bin\Debug\FsAutoComplete_repro.exe.config".
CopyFilesToOutputDirectory:
Copying file from "obj\Debug\FsAutoComplete_repro.exe" to "bin\Debug\FsAutoComplete_repro.exe".
FsAutoComplete-repro -> D:\Code\fsharp-repro\FsAutoComplete-repro\bin\Debug\FsAutoComplete_repro.exe
Copying file from "obj\Debug\FsAutoComplete_repro.pdb" to "bin\Debug\FsAutoComplete_repro.pdb".
Done Building Project "D:\Code\fsharp-repro\FsAutoComplete-repro\FsAutoComplete-repro.fsproj" (default targets).
Build succeeded.
0 Warning(s)
0 Error(s)
Time Elapsed 00:00:00.58
But a simple call to fsc Program.fs
succeeds just as well.
from fsautocomplete.
OK, it does seem like a bug. I will have to try to reproduce in my VM, I'll post back here once I learn something. In the meantime, if you want to keep using VIM, I could recommend a few ideas that might help:
- Try lowering the .NET Framework version to 4.5
- Find a project file generated by VS2013 (there are examples in the http://github.com/fsharp/fsharp repo among other places)
- Generate a project file using http://github.com/fsprojects/projekt
from fsautocomplete.
@yever I reproduced this using your project file. When I enabled more logging, I found that the issue was the absence of the App.config file referenced by the project. After I removed that entry from the project file, I received the following output:
{"Kind":"project","Data":{"Project":"C:\\Users\\test\\FsAutoComplete\\test.fspro
j","Files":["C:\\Users\\test\\FsAutoComplete\\AssemblyInfo.fs","C:\\Users\\test\
\FsAutoComplete\\Program.fs"],"Output":"C:\\Users\\test\\FsAutoComplete\\bin\\De
bug\\FsAutoComplete_repro.exe","References":["C:\\Program Files (x86)\\Reference
Assemblies\\Microsoft\\FSharp\\.NETFramework\\v4.0\\4.4.0.0\\FSharp.Core.dll","
C:\\Program Files (x86)\\Reference Assemblies\\Microsoft\\Framework\\.NETFramewo
rk\\v4.5.2\\System.Core.dll","C:\\Program Files (x86)\\Reference Assemblies\\Mic
rosoft\\Framework\\.NETFramework\\v4.5.2\\System.Numerics.dll","C:\\Program File
s (x86)\\Reference Assemblies\\Microsoft\\Framework\\.NETFramework\\v4.5.2\\Syst
em.dll","C:\\Program Files (x86)\\Reference Assemblies\\Microsoft\\Framework\\.N
ETFramework\\v4.5.2\\mscorlib.dll"],"Framework":"v4.5.2"}}
from fsautocomplete.
@yever as far as I can tell this is just a problem due to the missing AssemblyInfo.fs, so closing for now. If that isn't the case let me know.
from fsautocomplete.
Related Issues (20)
- Handle Project Reloads when adding files to wildcard patterns HOT 1
- Better Codefix onboarding process HOT 2
- Mac m1 Sonoma - FSautocomplete not working HOT 7
- Neovim, Lsp Mode Crashed, range not found in JSON, diagnostics related HOT 10
- Code-fix for _.Property / _.MethodCall() / _.IndexerAccess[idx] shorthand for accessor functions
- Add Support for Breaking Down Type Signatures in Tooltips HOT 4
- fsiExtraParameters break error hints in editor while editing .fsx files HOT 14
- Remove inline values that replace pipeline hints
- Improve .NET POCO Initialiser Constructor object documentation, unit -> unit is not useful, we want to see the signature HOT 2
- F# interactive directives not showing docs once written down, also true for #nowarn, coloring is not conistent (purple?) HOT 1
- Refactoring: Extract Interface from Type member declaration (refactoring)
- Should we move this to Ionide or fsprojects? HOT 5
- #r "nuget: System.Data.Common" doesn't seem to work in .fsx HOT 4
- Format tooltips using client input HOT 4
- Invalid `This qualifier is redundant` when a variable is shadowed by a property with the same name and compatible signature
- `get ()` should not be renamed when renaming a property
- Code action: suggest to create missing parameter as local binding HOT 1
- AutomaticWorkspaceInit is ignored if rootUri is used instead of rootPath
- Convert to NuGet Central Package Management
- Work list for .NET 8.0.300-based releases HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from fsautocomplete.