seraphx2 / ESI.NET

A C# wrapper for the Eve Online ESI API.
https://www.nuget.org/packages/ESI.NET/
MIT License
42 stars 25 forks source link

Type_id under MarketLogic.RegionOrders #11

Closed DanFraserUK closed 5 years ago

DanFraserUK commented 5 years ago

I can successfully pull data if this is null (as direct in the method parameters or as a separate variable) but when I use an int to look for a particular type_id it always returns zero results. Do I have to be more specific with my variable int or is there something wrong?

seraphx2 commented 5 years ago

_client.Market.RegionOrders(10000002, order_type: MarketOrderType.Sell, type_id: 34).Result; seems to work for me.

DanFraserUK commented 5 years ago

Now it returns results instead of nothing, but they come back as if I had set null anyway and I have 1000 orders of varying type_id's.

seraphx2 commented 5 years ago

Can you give some examples of data you are trying to pass in?

DanFraserUK commented 5 years ago

Client = new EsiClient(ESINetConfig); // <-- details are correct

then I have this:

private static List RegionOrders(int regionID, MarketOrderType orderType, int page, int typeID) { // this is extreme, but even leaving it as a plain int does the same, or not having the cast etc int? newTypeID = (int?)typeID; return myESI.Client.Market.RegionOrders(region_id: regionID, order_type: orderType, page: page, type_id: newTypeID).Result.Data; }

which is called from

// from the above call List orders = RegionOrders(10000002, MarketOrderType.Sell, 1, 34);

using the return line above as 'normal'

var a= myESI.Client.Market.RegionOrders(region_id: 10000002, order_type: MarketOrderType.Sell, page: 1, type_id: newTypeID);

still returns similar results, 1000 orders of varying typeIDs.

DanFraserUK commented 5 years ago

i'm also on slack Tweetfleet btw, in #esi-net-csharp

seraphx2 commented 5 years ago

I'm looking into your thing. But just FYI, I moved everything to Discord since I can have total control over the channel and webhooks. If you want to talk in a chatting environment, I am trying to get people to go there. It has a help channel and automatic messaging for when builds happen. I couldn't have that level of control on tweetfleet and they were having webhook limitation issues. There's an invite link in the readme.

seraphx2 commented 5 years ago

What is the value of newTypeID

DanFraserUK commented 5 years ago

34 in my tests.

I've figured out why, I can't seem to use ESI.NET in a console application. I've got it running fine in a windows form application.

seraphx2 commented 5 years ago

That really shouldn't be a problem. I know someone else is using a Windows Service/Console App to do his. as long as you can get the pilot authenticated, there shouldn't be problems based on project type. I couldn't imagine why the project type should matter.

seraphx2 commented 5 years ago

Also, I saw your wallet issue on tweetfleet (slack wasn't playing nice and I couldn't see any messages in the phone app for some reason) did you get that resolved?

DanFraserUK commented 5 years ago

Yeah I got it resolved. Thank you.

The project type is weird. I can create a working basic version (just pulling the wallet amount for example) in a winforms app, as soon as i copy over the code structure it drops out with a 0x0 exit on the verify line.

I copied across the code for the verify section and then it craps out on what is line 79 of _SSOLogic. I gave up, lol.

DanFraserUK commented 5 years ago

Ok, the issue raised (type id thing) has been resolved of course, so I'll close this. I've got it working in a console app by changing the Verify() line on the front page of this github to

auth_char = Verify().Result;

Otherwise the program just outright quits there.