It seems it is case sensitive. I dont think OGS usernames are case sensitive
The one I’m using is OGS search, so it should be exactly like OGS search
Hmm. stats page can’t find pempu but it will correctly find Pempu. OGS search(on the OGS top bar) finds Pempu with both pempu and Pempu
Also if I repeat my search it will fetch all the data again. Would it be good idea to cache it somewhere or is it too expensive in terms of storage / coding?
It’s not too expensive, I’m just bad
For the searching it’s case sensitive because I can’t find a way to send case-insensitive search request to OGS. Normally the decision of search result is done by the server, and I was told (by @matburt I think?) that this is the same search string OGS uses. So, well, case-insensitive searching probably need dev support I guess.
Do it the new way! http://vatcss.info/games/gotstats/#/user/Fairgo
btw @Pempu actually the idea of caching games result is pretty tempting, I’m looking into it
We do have case insensitive searching, and sub-string searching use
__icontains for case insensitivity, just be careful… hopefully you are using an oauth2 client token which has higher limits than anonymous api requests. If you cross the api request throttling threshold and you are using an oauth2 client token then we will throttle you and return a 429 until the throttle timeout. If you are using anonymous requests and we notice that it’s consuming too much traffic then we will block you permanently.
Thanks matburt, I see. I don’t like contains though, since it’s supposed to be a “quick & be done with it” kind of thing, I don’t want people to have to choose from an auto complete menu to choose the user they want >.<
On the request numbers I think it’s not many unless someone open 100 tabs and search simultaneously, in that case well just block them they deserve it xD
@Pempu the search result is save-able now
Guaranteed to reduce the chance @matburt will ip block you by 90%.
This is generally why it’s a good reason to use an oauth2 client… we can work with you for expanding limits or analyzing usage.
@matburt I’m not really a back end guy so having to write an oauth2 client is kind of a hassle to me. Also it seems using socket.io & node.js mean the app will require a server to run on. As it is now, even if my host die people could just get the source code and run the html, and I prefer it that way.
I don’t use any concurrent requests spamming to boost the search speed, so even if someone search continuously it would be just like when he’s clicking through pages, so I’m quite sure they won’t get auto-blocked by the server. The requests are made from their own PC so it doesn’t increase workload on my server as well (it’s a very cheap one )
What happens if I click the button “This player is you”?
Do you fetch my IP and include it in my page?
No, the game data is saved to your browser, so next time you search you don’t have to fetch those game again. But the browser only allow for 5mb of data so it’s only enough to store games of 1 player.
BTW, on the bottom right of the g0tstats page I just clicked here, out of curiosity:
And then I got this:
WHAT? What download?
I don’t even… how…
It just link to the main site where I plan to link to stuffs I make in the future. A plain text/image page to be precise.
There’s not even Google Analytic there… I don’t even know what’s being downloaded…
Does the link www.vatcss.info work for you? Could it be the addon blocked the link because it doesn’t have the www part?
[quote=“AlphaGo_2_0, post:36, topic:6524”]
Does the link www.vatcss.info work for you? [/quote]Yes it does (see below), AND I get that same AdBlock message again. No difference whether I use the “www.” prefix or not.
[quote]Could it be the addon blocked the link because it doesn’t have the www part?[/quote]The page loads fine, it’s just that AdBlock tells me that some dubious download was blocked … and I wonder what that may be.
It’s probably just a false positive with the adblocker you’re using. uBlock Origin shows nothing for me.
Check the F12 Dev tools if you’re suspicious.
Thanks, @timuzhti … I also checked with umatrix
And funny thing happened: Curious as I am, I disabled Adblock for vatcss.info, then enabled it again … and now I get no more of these warnings
Thats a very nice tool! Reminds me that I should find time to play again