Installing KVM Broke Current asp.net vnext Web Project - asp.net-core

I installed the KVM using command line and my web project in VS2015 preview broke not compiling, but if add a new web project all works fine, how do uninstall the KVM so I can get my old project working. In this video Scott mention the issue but no solution, please see link, the video mention the issue at the 8:00 minute
video
1: http://channel9.msdn.com/Series/Whats-New-with-ASPNET-5/05 I change the to use the default alias but that did not work
NuGet Settings

I believe your versions are out of sync. Check your project.json and make sure you are not using different versions. I found that when I had 1 dependency that used 3.0.0-* it upgraded to beta2 from beta1. All of my other dependencies had beta1 actually defined. (Ex: 1.0.0-beta1). If the beta2 assembly shares the same dependency as one of your assemblies using beta1 it will override the older version of the shared assembly that is being used and causes your older version to fail.

You can remove any KRE package by deleting it from c:\Users\<user>\.kre\packages\. If you want to remove KRE and KVM then remove both the .kre folder completely.
However, you don't have to remove it to use a different version. You can either use kvm use <version> or, from VS, select the target framework in the project properties.

I have similar issue and I solved it by following steps.
In NUget Package Manager I selected only one nuget.org ( Disable myget.org by unselecting it)
I goto C:\Users\<>.kre\alias directory. Here you will find default.txt and I replace default.txt value with KRE-CLR-x86.1.0.0-beta1 ( If you downloaded latest version of Kre then this file change and it create problem for VS 2015 Preview)
After this close your solution and open it again. If possible then open as Administrator.
I hope this works for you as well.

Related

Adding AddRazorRuntimeCompilation() to the container in .NET CORE 6 will break the CSS footer

I create a brand new ASP.NET Core MVC project using VS 2022 and .NET Core 6.
VS will generate the base template and when I run it without touching any code, everything is fine.
So far so good.
Now I add the NuGet dependency Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation version 6.0.0.
In Program.cs file, I add a line
// Add services to the container.
builder.Services.AddControllersWithViews();
builder.Services.AddRazorPages().AddRazorRuntimeCompilation(); //Add this line of code
var app = builder.Build();
Rebuild the program and run it. Now I see the footer is not at the bottom of the page anymore.
Is it a bug or did I do something wrong here? Thanks.
I was struggling the same problem as well,
while trying the versions of Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation nuget package and found the solution with 5.0.13 version.
If you downgrade the package from 6.0.1 to 5.0.13, the problem goes away and footer will be on bottom again.
In Visual Studio 2022, there's an option for hot reload on file save. this fixed my issue without having the need to install Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation
What is happening is that when you enable runtime editing, the .NET Core built in bundle and minification is removed. If you look at shared/_layout.cshtml, there is a _layout.cshtml.css file. This is the runtime bundle/include you are missing. Since this is your core layout, move the contents from this file to your wwwroot/css/site.css file and the footer and other elements will render as before.
Is it your intention to actually use RazorPages? It looks like you just want to add runtime compilation to the standard MVC views.
If you intend to use controllers and views, just add:
builder.Services.AddControllersWithViews().AddRazorRuntimeCompilation();
But, I tried your code as well and in my environment, the footer is present in both cases, even if I downgrade Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation from version 6.0.1 to 6.0.0.
I think there's no need to add the runtime compilation since in the newest update/version hot-reload has been officially released.
PS. I am currently following an asp.net tutorial and I encountered this problem. Here's the link: https://youtu.be/hZ1DASYd9rk
I'm watching same video series as you do and i had the same error. I upgraded Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation to v6.0.11 and I don't get any error anymore I
Installing Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation version 5.0.17 Nugget Package cleared the error for me.
You may try to install any version from 5.0.0 - 5.0.17

My Netbeans 12.2 on Ubuntu only has lightweight & temporary C++ IDE, can't find the real one

In Netbeans 12.2 on Ubuntu 18.04 (using that snap install), for my C++ plugin I have that first image. When I try to create a new project I get that second image. That is some kind of a lightweight version that does not do your makefiles for you. If I try to open an existing C++ project it just never IDs any project file or folder as the right one. And notice that this version does not include a "Create from source code".
Does anyone know how I can install the "real" c++ plugin? I've looked in a lot of tutorials but they all say it should be there under Available Plugins, but it is not there.
This comes very late but it seems that Netbeans 12 lacks some components for this.
Therefore you must enable Netbeans 8.2 Plugin Portal from Plugins Settings.
Then deactivate the C/C++ and then force updates from Updates -> Check for Updates. Restart IDE and install 8.2 C/C++ plugin.
Note: I have lead into this problem now because unpack2000 is no more present.
The validation of downloaded plugins cannot be completed, cause: NBM ../.netbeans/12.4/update/download/org-netbeans-modules-cnd-kit.nbm needs unpack200 to process following entries:
netbeans/modules/locale/org-netbeans-modules-cnd-kit_ja.jar.pack.gz
netbeans/modules/locale/org-netbeans-modules-cnd-kit_pt_BR.jar.pack.gz
netbeans/modules/locale/org-netbeans-modules-cnd-kit_ru.jar.pack.gz
netbeans/modules/locale/org-netbeans-modules-cnd-kit_zh_CN.jar.pack.gz
netbeans/modules/org-netbeans-modules-cnd-kit.jar.pack.gz
This can be resolved by installing jre-11 (if it is not present already. I have it on Opensuse Thubleweed amogst with jre-16).
So then you just start netbeans from terminal with:
$ netbeans --jdkhome "/usr/lib64/jvm/jre-11"
...and then install blugin, and when it is ready close netbeans and start it normally again.
Just wanted to report that the answer from Devspain also works with Netbeans 14, in Ubuntu 22.04.

How to obtain all versions of KRE?

Problem
I want to both use stable versions of KRE and the bleeding edge nightly built KRE. One ASP.NET5 application may be beta2, but another I may want to be beta4. So what I did was install both in powershell as found here.
What happened is that the stable KVM installed in C:/Users/derp/.kre and the nightly build KVM installed in C:/Users/derp/.k
Worse yet, I can only see this now
Attempts
I tried kvm install KRE-CLR-x86.1.0.0-beta2 and it failed
Shall I try moving the packages from /kre file to the /.k file? This seems hacky and like a really bad idea
RTFM - Tried to use the install feature and including the -a, but failed.
I'm doing something the hard way and can't see the obvious.
I search on here
I feel if there is an answer to what I am trying to do above, it is worth being on here for others to find as well. Thank you all for your patience.
ASP.NET 5 is under development and there is no guarantee that changes between different pre-release version are backward compatible (sorry!).
The /.kre -> ./k rename is not backward compatible and you cannot have both the old and the new kvm simultaneously on the PATH. However, you can get can have two versions of kvm on your machine but you will have to use the full path for at least one of them.
I think the key is the path environment variable of your system. You have to use two set of "kvm", one for night builds, one for public beta, to download and set correct path environment variable.
For instance, I get one kvm from Entity Framework 7 repository, which can download and use beta 4 builds. I also have another kvm from Home repository which can download and use public beta builds.
You can use either kvm with "upgrade" or "use" command to set correct path environment variable, then run your application on the runtime you need. I think even Visual Studio 2015 CTP runs your projects based on the Runtime specified in your path environment variable. For the time being, only beta 3 run times can display in the project property dialog of VS 2015 CTP, but when hitting ctrl + F5, my website starts to load beta 4 runtime and assemblies, I can see the loading in output window, I think this is because I have .k folder prior to the .kre folder in the path environment variable.
Can you try the following?
$cmd-prompt>kpm Install KRE-CLR-x86
It worked for me.

Worklight fails to install customization jar

I have three projects in my workspace, two deploy to the server correctly, the third has just begun to give this error:
Failed to install and start project customization from file <path>MyProj-customization.jar
I've seen this before on other projects and usually it's sufficient to start the server for another project and come back to the one with problems. When that doesn't work the next recipe (found on developer works) is
Exit Eclipse/Worklight Studio
Delete <workspace>/WorkLightServerHome
delete project bin
Start Studio, rebuild
That also doesn't work. Finally there's a further recipe on developer works
When Eclipse is not running, go to:
1. <path-to-your-Eclipse-folder>\configuration\org.eclipse.osgi
2. Delete the .bundle* files
3. Start Eclipse
4. Build and deploy
Again this does not clear the problem, assuming I've understood step 2 correctly, I found exactly one file whose name is of the form .bundle* and a bundles directory with several sub-directories. I deleted only the .bundlexxx file.
Any other suggestions?
I would have expected that creating a new workspace would fix it, but on this occasion no such luck.
No true solution on this occasion. Normally a new workspace as a method of last resot has always worked in the past. In this case I found no alternative to reinstallation of Worklight.
In addition to the attempts you have tried, also try creating a new workspace and import the 'offending' project to it.
If all fails, have a new instance of Eclipse (Java EE, 4.2.2 SR2), re-install Worklight Studio and import the project.

Worklight 5.0.6 wipes out native customizations in shell

I upgraded my environment to v5.0.6. Problem is that everytime i start Eclipse it does this:
[2013-04-19 18:38:41] FWLST1017I: [AppShell] upgraded to the latest
platform version.
When this upgrade takes place, it reverts my templates and adds class files to the iphone\native folder and removes the plugins I configured in the shell:
Removes all my custom plugins from components/AppShell/iphone/native/Classes
Resets project.pbxproj.wltemplate.wluser to stock removing includes for my classes
Resets config.xml.wluser removing all mappings to my plugins
It also always shows at the end of the upgrade process:
Failed to upgrade Worklight project 'AppMobile' to the latest platform
version. [null]
Is that why it keeps running the upgrade and reverting my changes?
According to your question, you have some .wluser files, which means that something is wrong with your project.
Can you please let me know whether the problem still exists and whether you still have those files in you project?