This is a migrated thread and some comments may be shown as answers.

VS Online Build Failed - Kendo namespace not found

9 Answers 1358 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
King Wilder
Top achievements
Rank 2
King Wilder asked on 04 Feb 2014, 07:46 PM
I've been building an an MVC 4.5 app in VS 2013 and checking it into my Visual Studio Online account.  I then set it up for automatic Windows Azure deployment after it builds.

This was all working fine until I had to create a controller used for Ajax calls to a Kendo ListView MVC Wrapper.

Here's the HTML:

@(Html.Kendo().ListView(Model.Top100ResortList)
                    .Name("Top100Resort")
                    .TagName("ul")
                    .ClientTemplateId("top100template")
                    .DataSource(ds =>
                    {
                        ds.Read(read => read.Action("_ResortCourses_Read", "Courses"));
                        ds.PageSize(10);
                    })
                    .Pageable()
                )

Here's the controller code initially.  It does not have the Kendo namespace in the method itself.  The namespace is in the class usings:

using Kendo.Mvc.UI;
public virtual ActionResult _ResortCourses_Read([DataSourceRequest] DataSourceRequest request)
{
    var json = _coursesService.GetTop100Courses(Top100Types.GolfWeekResort).ToDataSourceResult(request);

    return Json(json);
}

Here's the controller code after I saw the build fail, so I removed the class using, and added it directly to the method.  Everything still works, but the build still fails in VS Online.

public virtual ActionResult _ResortCourses_Read([Kendo.Mvc.UI.DataSourceRequest] Kendo.Mvc.UI.DataSourceRequest request)
{
    var json = _coursesService.GetTop100Courses(Top100Types.GolfWeekResort).ToDataSourceResult(request);

    return Json(json);
}

Any idea why my builds are failing and why VS Online tells me it cannot find the type or namespace for Kendo?

dhruv
Top achievements
Rank 1
commented on 12 Sep 2022, 09:24 AM

in 2022 i still suffer from this issue
Angel Petrov
Telerik team
commented on 06 Oct 2022, 12:43 PM

Could you please describe the problem in detail? What exactly does not work? Does the documentation article proved helpful?

9 Answers, 1 is accepted

Sort by
0
Atanas Korchev
Telerik team
answered on 05 Feb 2014, 10:04 AM
Hello,

The only reason we can think if is a missing assembly reference. If the Kendo.Mvc.dll isn't correctly deployed compilation will fail.

Regards,
Atanas Korchev
Telerik
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
0
King Wilder
Top achievements
Rank 2
answered on 05 Feb 2014, 04:52 PM
Hi Atanas,

Is there a different way to deploy to Visual Studio Online than to anywhere else?  Just to clarify, the application has been working and building fine for a month, before I created those methods where I needed the Kendo DataSourceRequest objects in the arguments of the action method.  The prior builds were not complaining about not finding Kendo previously.

The Kendo.Mvc assembly is marked as "Copy Local".

Ok, I just looked at my Visual Studio Online Code section and it's weird that there's no /bin folder for any project in my solution, but all the prior publishes have built.  I'm also noticing that on the successful builds there's also a warning about the missing Kendo.Mvc reference.

I'll continue to try and figure this out.
0
Atanas Korchev
Telerik team
answered on 06 Feb 2014, 07:29 AM
Hello King,

We don't know if Visual Studio Online has a different option of deploying dll files. Kendo UI is just another assembly and should be deployed with the rest of your application. What happens with any other third party dlls that your application is using?

Regards,
Atanas Korchev
Telerik
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
0
King Wilder
Top achievements
Rank 2
answered on 06 Feb 2014, 06:00 PM
Hi Atanas,

The other third-party assemblies like Ninject seem to work fine.  I'll keep digging.

Thanks.
0
Mark
Top achievements
Rank 1
answered on 17 Sep 2015, 03:52 AM
Did you find a solution to this?  I am experiencing the same issue with VS online and my deployed Azure site not picking up my Kendo.MVc.dll - it doesn't look like the Kendo binary is being copied across, and igoring Copy Local set to true.
0
King Wilder
Top achievements
Rank 2
answered on 17 Sep 2015, 04:11 AM
Hi Mark, this was such a long time ago, I honestly don't remember what I did to fix the issue, but it's working on my live site, but it's not on Azure.  If I remember anything, I'll post what I remembered here.
0
Ody
Top achievements
Rank 1
Veteran
answered on 06 Dec 2017, 08:04 PM

I know this is from a long time ago and has probably been figured out elsewhere, but this page is a top hit when searching the problem.

Visual Studio and its source control features allow you to ignore particular files and folders from being checked in.  Typically the entire nuget Packages folder is ignored.  The idea is you shouldn't have to waste space/time on checking in specific api binaries.  Wherever you build should have the ability to restore nuget packages independently and use those to build your project against.

 

Now when using Telerik's special nuget server to install your Kendo.MVC api, Visual Studio can fetch and refresh the Kendo.MVC binaries, but Visual Studio Online, and it's build system, does not have that same access to Telerik's private nuget server.  It cannot get the binaries and thus cannot build your project.

I am still researching to best solution. Ideally Visual Studio Online would allow you to add private binaries to its build system, without needing to check them in per project.

 

0
Ody
Top achievements
Rank 1
Veteran
answered on 06 Dec 2017, 10:48 PM

Telerik has a few pages dealing with nuget in their documentation, which is one of the reasons I have always preferred Telerik: Extensive documentation (and forums with a lot of troubleshooting history).

 

Anywho - If you are using VSTS aka VSO, you can figure out what you need to do with your build definitions and nuget.config files here:

https://docs.telerik.com/aspnet-core/how-to/setup-private-nuget-feed-azure

In my case, I did need to create a new nuget.config file and point my nuget restore task to that file.

 

Cheers.

dhruv
Top achievements
Rank 1
commented on 12 Sep 2022, 09:23 AM

how you created the new nuget.config file ???????????????

 

0
Petya
Telerik team
answered on 12 Dec 2017, 05:29 PM
Thanks for following-up with the solution you found, Ody. I'm happy to hear you figured it out.

Regards,
Petya
Progress Telerik
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
Tags
General Discussions
Asked by
King Wilder
Top achievements
Rank 2
Answers by
Atanas Korchev
Telerik team
King Wilder
Top achievements
Rank 2
Mark
Top achievements
Rank 1
Ody
Top achievements
Rank 1
Veteran
Petya
Telerik team
Share this question
or