# EF6 Error: Method not found

**URL:** <https://community.miniprofiler.com/t/ef6-error-method-not-found/276>\
**Category:** .NET\
**Created:** [May 6, 2014, 10:21pm UTC](https://community.miniprofiler.com/t/ef6-error-method-not-found/276 "2014-05-06T22:21:31Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![GFoley83](https://sea2.discourse-cdn.com/flex016/user_avatar/community.miniprofiler.com/gfoley83/32/962_2.png) [@GFoley83](https://community.miniprofiler.com/u/GFoley83)\
**Post date:** [May 6, 2014, 10:21pm UTC](https://community.miniprofiler.com/t/ef6-error-method-not-found/276/1 "2014-05-06T22:21:31Z")

</div>

I’m getting the following error when I try to pull an item out of the Db using my repository with EF6:

```
Method not found: 
'System.Data.Common.DbDataReader StackExchange.Profiling.Data.ProfiledDbDataReader.get_WrappedReader()'.

Exception Details: 
System.MissingMethodException: Method not found: 'System.Data.Common.DbDataReader StackExchange.Profiling.Data.ProfiledDbDataReader.get_WrappedReader()'.

Line 42: public T GetById(int id){
Line 43: return _dbSet.Find(id); <-- This
Line 44: }

```

I’m using version 3.0.10-beta5 and I’m calling `MiniProfilerEF6.Initialize();` before I bootstrap all my dependencies (with Castle Windsor) in `Application_Start`.

---

<div class="post-metadata">

**Author:** ![Yaakov\_Ellis](https://sea2.discourse-cdn.com/flex016/user_avatar/community.miniprofiler.com/yaakov_ellis/32/961_2.png) [@Yaakov\_Ellis](https://community.miniprofiler.com/u/Yaakov_Ellis)\
**Post date:** [May 7, 2014, 5:45am UTC](https://community.miniprofiler.com/t/ef6-error-method-not-found/276/2 "2014-05-07T05:45:18Z")

</div>

Can you please confirm that you are using MiniProfiler 3.0.10 ( **not** beta) for the main MiniProfiler nuget?

---

<div class="post-metadata">

**Author:** ![GFoley83](https://sea2.discourse-cdn.com/flex016/user_avatar/community.miniprofiler.com/gfoley83/32/962_2.png) [@GFoley83](https://community.miniprofiler.com/u/GFoley83)\
**Post date:** [May 7, 2014, 7:44am UTC](https://community.miniprofiler.com/t/ef6-error-method-not-found/276/3 "2014-05-07T07:44:07Z")

</div>

Hi Yaakov. According to Nuget, version 3.0.10-beta5 is the latest version that’s available. There is no non beta version that I can see.

> **[MiniProfiler.EF6 3.0.10-beta5](https://www.nuget.org/packages/MiniProfiler.EF6/3.0.10-beta5)**
>
> MiniProfiler integration for Entity Framework 6

---

<div class="post-metadata">

**Author:** ![Yaakov\_Ellis](https://sea2.discourse-cdn.com/flex016/user_avatar/community.miniprofiler.com/yaakov_ellis/32/961_2.png) [@Yaakov\_Ellis](https://community.miniprofiler.com/u/Yaakov_Ellis)\
**Post date:** [May 7, 2014, 7:56am UTC](https://community.miniprofiler.com/t/ef6-error-method-not-found/276/4 "2014-05-07T07:56:16Z")

</div>

I am talking about the nuget 3.0.10 for [the main miniprofiler nuget](https://www.nuget.org/packages/MiniProfiler/3.0.10).

The requirements for EF6 beta5 incorrectly list 3.0.9 as a minimum - I think that upgrading the main package to 3.0.10 might help.

---

<div class="post-metadata">

**Author:** ![GFoley83](https://sea2.discourse-cdn.com/flex016/user_avatar/community.miniprofiler.com/gfoley83/32/962_2.png) [@GFoley83](https://community.miniprofiler.com/u/GFoley83)\
**Post date:** [May 7, 2014, 9:37am UTC](https://community.miniprofiler.com/t/ef6-error-method-not-found/276/5 "2014-05-07T09:37:32Z")

</div>

I only installed MiniProfiler.EF6 yesterday for the first time and that came with version 3.0.10 of MiniProfile core.  
I just did a fresh install and I can confirm that I have:  
MiniProfiler.EF6 - 3.0.10-beta5  
MiniProfile Core - 3.0.10

The error is still present.

---

<div class="post-metadata">

**Author:** ![Yaakov\_Ellis](https://sea2.discourse-cdn.com/flex016/user_avatar/community.miniprofiler.com/yaakov_ellis/32/961_2.png) [@Yaakov\_Ellis](https://community.miniprofiler.com/u/Yaakov_Ellis)\
**Post date:** [May 11, 2014, 7:49am UTC](https://community.miniprofiler.com/t/ef6-error-method-not-found/276/6 "2014-05-11T07:49:16Z")

</div>

Can you open up the MiniProfiler dll in Object Browser in Visual Studio, and confirm for me that under MiniProfiler \> StackExchange.Profiling.Data.ProfiledDbData Reader that thereis a public `WrappedReader` property available?

---

<div class="post-metadata">

**Author:** ![GFoley83](https://sea2.discourse-cdn.com/flex016/user_avatar/community.miniprofiler.com/gfoley83/32/962_2.png) [@GFoley83](https://community.miniprofiler.com/u/GFoley83)\
**Post date:** [May 11, 2014, 9:21pm UTC](https://community.miniprofiler.com/t/ef6-error-method-not-found/276/7 "2014-05-11T21:21:45Z")

</div>

Have to offer apologies here, seems as though I had a conflict with DLLs from Nuget; it was incorrectly reporting I had version MiniProfile Core - 3.0.10 installed when infact it was MiniProfile Core - 3.0.10-beta7. Once I deleted that and re-installed again the issue went away.

For those that get the same error, make sure you install MiniProfile Core (stable) first, then MiniProfiler.EF6.
