These are chat archives for Ruhrpottpatriot/GW2.NET

23rd
Jun 2016
Darnell Williams
@Seeker1437
Jun 23 2016 02:48
Im lost at how to use the API key
Darnell Williams
@Seeker1437
Jun 23 2016 03:24
hey I have a slight issue using the GW2.NT Library, atm my application uses a higher version of Newtonsoft.Json than GW2.NET uses, so when GW2 is making a request it fails to load the verion you guys are using
Command failed: Could not load file or assembly 'Newtonsoft.Json, Version=6.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)
Darnell Williams
@Seeker1437
Jun 23 2016 03:57
Command failed: Could not load file or assembly 'Newtonsoft.Json, Version=6.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed' or one of its dependencies. The system cannot find the file specified.
Stack Trace:
at GW2NET.Common.Serializers.JsonSerializerFactory.GetSerializer[T]()
   at GW2NET.Common.ServiceClient.DeserializeResponse[TResult](HttpWebResponse response, ISerializerFactory serializerFactory, IConverter`2 gzipInflator)
   at GW2NET.Common.ServiceClient.OnSuccess[T](HttpWebResponse response, ISerializerFactory serializerFactory, IConverter`2 gzipInflator)
   at GW2NET.Common.ServiceClient.OnResponse[TResult](HttpWebResponse response)
   at GW2NET.Common.ServiceClient.Send[TResult](IRequest request)
   at GW2NET.V1.Guilds.GuildRepository.GW2NET.Guilds.IGuildRepository.FindByName(String name)
   at DangerBotCore.DangerBot.<>c.<<CreateCommands>b__12_3>d.MoveNext() in C:\Users\Darnell\Documents\Visual Studio 2015\Projects\DiscordBotCore\DangerBot\DangerBot.cs:line 74
@Ruhrpottpatriot @StevenLiekens
Steven Liekens
@StevenLiekens
Jun 23 2016 07:33
you could use a binding redirect in your config file
<configuration>
   <runtime>
      <assemblyBinding>
         <dependentAssembly>
            <assemblyIdentity name="Newtonsoft.Json"
                              publicKeyToken="30ad4fe6b2a6aeed"
                              culture="neutral" />
            <bindingRedirect oldVersion="6.0.0.0"
                             newVersion="8.0.0.0"/>
         </dependentAssembly>
      </assemblyBinding>
   </runtime>
</configuration>
Darnell Williams
@Seeker1437
Jun 23 2016 13:49
-FUnny thing is that is already there :O
OH!
okay
@StevenLiekens thanks,... the binding redirect was in the incorrect assembly for some reason LOL
Steven Liekens
@StevenLiekens
Jun 23 2016 13:53
yeah nuget tries to be smart about it but it doesn't always do the right thing
Steven Liekens
@StevenLiekens
Jun 23 2016 14:05
you're better off disabling automatic binding redirects and adding them manually
you'll know when and where you need them
Darnell Williams
@Seeker1437
Jun 23 2016 14:06

@StevenLiekens sorry to bug the last thing, I know the the V2 accounts it not a nuget package yet, can it still be used or is there some missing stuff for it?

It looks like basically all the authenticated APIs for v2 are not implemented?

Steven Liekens
@StevenLiekens
Jun 23 2016 14:06
I don't know what the state is of the master branch
Darnell Williams
@Seeker1437
Jun 23 2016 14:07
gottcha
Steven Liekens
@StevenLiekens
Jun 23 2016 14:07
I haven't developed for gw2net in a long time
but
Darnell Williams
@Seeker1437
Jun 23 2016 14:07
by request of a client they wanted the bot to be able to verify that a people joining their discord server is indeed a member of their guild, I just realized I don't have a good way of doing so atm XD
Steven Liekens
@StevenLiekens
Jun 23 2016 14:08
yeah maybe it's better if you implement that yourself until we figure out where we're going with gw2net
Darnell Williams
@Seeker1437
Jun 23 2016 14:09
sure thing :)
Thanks for your assistence