These forums have been archived and are now read-only.

The new forums are live and can be found at https://forums.eveonline.com/

EVE Technology Lab

 
  • Topic is locked indefinitely.
 

TEA (v1.2.1) - Member Management Mod for SMF 2, TeamSpeak 3 and Jabber

First post
Author
Shin Chogan
Federal Navy Academy
Gallente Federation
#281 - 2013-01-11 16:07:48 UTC  |  Edited by: Shin Chogan
Troy can you do me a favour stop your TEA_Cron.php cronjob and put

var_dump(method_exists($this, 'get_cache'));

After line 207 : $cache = FALSE;
and before 208 : if($type != 'standings' && $type != 'alliances' && method_exists($this, 'get_cache'))

Then run TEA_Cron.php manually or even safer make a copy and use it to update a single member ... change the line : $tea -> update_api(FALSE); so that FALSE is replaced by a valid member id.

Are all the values printed to the screen "true" or are some "false" ?
Troy Aihaken
Quekz
#282 - 2013-01-11 16:11:49 UTC
Yo man i have 11 lines in my TEA_Cron.php

NodeJS Developer | Frontend Development | Programming Enthusiast

Shin Chogan
Federal Navy Academy
Gallente Federation
#283 - 2013-01-11 16:13:10 UTC
Doh I new I'd forgotten something ... Oops

The line to add is in TEAC.php :)
Troy Aihaken
Quekz
#284 - 2013-01-11 16:15:02 UTC
Ok can you rewrite what i need to do so i dont F anything up

NodeJS Developer | Frontend Development | Programming Enthusiast

Shin Chogan
Federal Navy Academy
Gallente Federation
#285 - 2013-01-11 16:19:27 UTC
1/ Add : var_dump(method_exists($this, 'get_cache'));

After line 207 : $cache = FALSE;
and before 208 : if($type != 'standings' && $type != 'alliances' && method_exists($this, 'get_cache'))

in the file TEAC.php

2/ Then run TEA_Cron.php manually

Optionally If you change the word FALSE to a number that is a valid Member ID on your forums in TEA_Cron.php it will only update a single account

I'm interested in the output :)
Troy Aihaken
Quekz
#286 - 2013-01-11 16:32:28 UTC
bool(true) bool(true) bool(true) bool(true) bool(true) bool(true) bool(false) bool(false) bool(false) bool(true) bool(true) bool(false) bool(false) bool(false) bool(false) bool(false) bool(true) bool(true) bool(true) bool(true) bool(false) bool(false) bool(false) bool(false) bool(false) bool(true) bool(true) bool(false) bool(false) bool(false) bool(false) bool(true) bool(true) bool(false) bool(false) bool(false) bool(false) bool(false) bool(true) bool(true) bool(false) bool(false) bool(false) bool(false) bool(true) bool(true) bool(false) bool(false) bool(false) bool(false) bool(false) bool(true) bool(true) bool(false) bool(false) bool(true) bool(true) bool(true) bool(true) bool(false) bool(false) bool(false) bool(false) bool(false) bool(false) bool(true) bool(true) bool(false) bool(false) bool(false) bool(true) bool(true) bool(false) bool(false) bool(false) bool(false) bool(false) bool(true) bool(true) bool(true) bool(true) bool(false) bool(false) bool(false) bool(true) bool(true) bool(false) bool(false) bool(false) bool(false) bool(false) bool(true) bool(true)


LOL

NodeJS Developer | Frontend Development | Programming Enthusiast

Shin Chogan
Federal Navy Academy
Gallente Federation
#287 - 2013-01-11 16:40:56 UTC  |  Edited by: Shin Chogan
Troy Aihaken wrote:
bool(true) bool(true) bool(true) bool(true) bool(true) bool(true) bool(false) bool(false) bool(false) bool(true) bool(true) bool(false) bool(false) bool(false) bool(false) bool(false) bool(true) bool(true) bool(true) bool(true) bool(false) bool(false) bool(false) bool(false) bool(false) bool(true) bool(true) bool(false) bool(false) bool(false) bool(false) bool(true) bool(true) bool(false) bool(false) bool(false) bool(false) bool(false) bool(true) bool(true) bool(false) bool(false) bool(false) bool(false) bool(true) bool(true) bool(false) bool(false) bool(false) bool(false) bool(false) bool(true) bool(true) bool(false) bool(false) bool(true) bool(true) bool(true) bool(true) bool(false) bool(false) bool(false) bool(false) bool(false) bool(false) bool(true) bool(true) bool(false) bool(false) bool(false) bool(true) bool(true) bool(false) bool(false) bool(false) bool(false) bool(false) bool(true) bool(true) bool(true) bool(true) bool(false) bool(false) bool(false) bool(true) bool(true) bool(false) bool(false) bool(false) bool(false) bool(false) bool(true) bool(true)


LOL



Cool ... so that confirms that for a significant number of calls the caching methods aren't in scope so it can't put into or fetch from the cache :)

That said you had a lot more trues than I did when I ran my tests but that could have been because I was looking at this when the api system was having a bad day recently and giving a load of runtime errors Big smile

You might want to remove that line from TEAC.php now or you are going to get a LOT of cron spam
Troy Aihaken
Quekz
#288 - 2013-01-11 16:45:41 UTC
Shin Chogan wrote:
Troy Aihaken wrote:
bool(true) bool(true) bool(true) bool(true) bool(true) bool(true) bool(false) bool(false) bool(false) bool(true) bool(true) bool(false) bool(false) bool(false) bool(false) bool(false) bool(true) bool(true) bool(true) bool(true) bool(false) bool(false) bool(false) bool(false) bool(false) bool(true) bool(true) bool(false) bool(false) bool(false) bool(false) bool(true) bool(true) bool(false) bool(false) bool(false) bool(false) bool(false) bool(true) bool(true) bool(false) bool(false) bool(false) bool(false) bool(true) bool(true) bool(false) bool(false) bool(false) bool(false) bool(false) bool(true) bool(true) bool(false) bool(false) bool(true) bool(true) bool(true) bool(true) bool(false) bool(false) bool(false) bool(false) bool(false) bool(false) bool(true) bool(true) bool(false) bool(false) bool(false) bool(true) bool(true) bool(false) bool(false) bool(false) bool(false) bool(false) bool(true) bool(true) bool(true) bool(true) bool(false) bool(false) bool(false) bool(true) bool(true) bool(false) bool(false) bool(false) bool(false) bool(false) bool(true) bool(true)


LOL



Cool ... so that confirms that for a significant number of calls the caching methods aren't in scope so it can't put into or fetch from the cache :)

That said you had a lot more trues than I did when I ran my tests but that could have been because I was looking at this when the api system was having a bad day recently and giving a load of runtime errors Big smile

You might want to remove that line from TEAC.php now or you are going to get a LOT of cron spam


All ready have but it doesnt matter thats my test server :)

NodeJS Developer | Frontend Development | Programming Enthusiast

medoix
KarmaFleet
Goonswarm Federation
#289 - 2013-01-13 03:18:57 UTC  |  Edited by: medoix
Thanks for uploading the modified version of this! works a treat.

I have one issue when users attempt to register with teamspeak, i get the green box and it says successful but it shows "[ERROR] Unknown method" instead and does not actually do anything, any ideas?
Troy Aihaken
Quekz
#290 - 2013-01-13 09:50:41 UTC
Are you using a mysql database?

NodeJS Developer | Frontend Development | Programming Enthusiast

Impudent Dragon
Native Freshfood
Minmatar Republic
#291 - 2013-01-13 13:40:36 UTC
TDS1-6 Kaptur wrote:
real spacer wrote:
Which file do I need to set the cron job up to?

I set it up to TEA_Cron.php , but that doesn't seem to work. I've tested it by manually executing it and it still doesnt work.



Maybe my expectations are wrong? What I am expecting it to run a full member check to make sure all api's are still valid and if they arent to disable any accounts that don't have valid apis.


Yes i need some help also, getting the cron job to work
any help will be welcome

I need this help too
Shin Chogan
Federal Navy Academy
Gallente Federation
#292 - 2013-01-13 14:11:01 UTC
The way the system works is that the cron job will do as many accounts as it can in a period of time less than 1 minute. You then have the TEA_Cron.php script run every minute.

so in /etc/cron.d/smf I have :

* * * * * user /usr/bin/php5 path/TEA_Cron.php
medoix
KarmaFleet
Goonswarm Federation
#293 - 2013-01-14 10:00:53 UTC
Troy Aihaken wrote:
Are you using a mysql database?


Using MySQL for EveBB but not for TS3...
Troy Aihaken
Quekz
#294 - 2013-01-14 15:48:29 UTC
I recommend using a mysql for ts but i believe you can do it with the sqlite file!! I will look into it but if anyone can confirm this please do!!

NodeJS Developer | Frontend Development | Programming Enthusiast

ShadowandLight
Trigger Happy Capsuleers
#295 - 2013-01-15 06:13:01 UTC
hey troy~

using your file i have 2 issues

1 - the get api is very slow on the forums, sometimes it times out. Clicking on the "eve api" button sometimes fixes it. When people reg they often get emails before the page tells them they are registered.

2 - i too am finding sometimes people are told they dont have the right API, even when I checked it myself.

Using a mysql DB btw.
Shin Chogan
Federal Navy Academy
Gallente Federation
#296 - 2013-01-15 11:33:07 UTC
ShadowandLight wrote:
hey troy~

using your file i have 2 issues

1 - the get api is very slow on the forums, sometimes it times out. Clicking on the "eve api" button sometimes fixes it. When people reg they often get emails before the page tells them they are registered.


There are 2 parts to this ... first up sometimes the api servers can be pretty slow but I also believe that there are some problems with the code that compound this as things are not being cached when they should be.

Quote:

2 - i too am finding sometimes people are told they dont have the right API, even when I checked it myself.


It is possible vital api calls are timing out which would result in it not having the info it needs. Also make sure it is an api key that lists ALL the characters on the account and not just one of them.
ShadowandLight
Trigger Happy Capsuleers
#297 - 2013-01-15 13:59:23 UTC  |  Edited by: ShadowandLight
ShadowandLight
Trigger Happy Capsuleers
#298 - 2013-01-15 14:05:22 UTC
Shin Chogan wrote:
ShadowandLight wrote:
hey troy~

using your file i have 2 issues

1 - the get api is very slow on the forums, sometimes it times out. Clicking on the "eve api" button sometimes fixes it. When people reg they often get emails before the page tells them they are registered.


There are 2 parts to this ... first up sometimes the api servers can be pretty slow but I also believe that there are some problems with the code that compound this as things are not being cached when they should be.

Quote:

2 - i too am finding sometimes people are told they dont have the right API, even when I checked it myself.


It is possible vital api calls are timing out which would result in it not having the info it needs. Also make sure it is an api key that lists ALL the characters on the account and not just one of them.



If there is any improvement to be had in the code it would help a ton, as this is a pretty annoying problem atm.

Also with all the API's i've used in testing i've made sure its "all characters" as the option.

Shin Chogan
Federal Navy Academy
Gallente Federation
#299 - 2013-01-15 15:19:31 UTC  |  Edited by: Shin Chogan
ShadowandLight wrote:

If there is any improvement to be had in the code it would help a ton, as this is a pretty annoying problem atm.

The errors you linked are symptomatic of when the CCP servers return an Application error rather than valid xml. I was writing a bit of test code and made a mistake and managed to cause this type of response which has given me a direction to look into in the TEA code to see if there is something it is doing to cause these responses or if it is just CCP's api servers sometimes have issues.

I've been working on some more changes that certainly appear to make it use the cache when it is supposed to, updating profiles certainly happen a lot quicker now (the more rules you have the worse it gets) ... and just running a "check all" through the forums and it is now checking about 20 at a time rather than about 5 :) I'm not sure if it is ready for primetime just yet though

Quote:

Also with all the API's i've used in testing i've made sure its "all characters" as the option.


Hey it was worth checking ... You would be amazed at how many people miss that Big smile
Nutbolt
University of Caille
Gallente Federation
#300 - 2013-01-17 11:11:01 UTC  |  Edited by: Nutbolt
ShadowandLight wrote:


I am also getting this error when I try and register a new user on the forums. They go through the registration page, enter in the correct API info, then Get Characters, select the right char, then click register, and this error occurs after about 3 minutes (also have the speed issues with api as mentioned above).

Edit: I also now get this when running the full check of everyones API keys. Goes for a couple of minutes, then displays the error.

www.avalonproject.co.uk/forums