open All Channels
seplocked EVE Technology Lab
blankseplocked Yapeal PHP API library (revision 1203 branches/keys/)
 
This thread is older than 90 days and has been locked due to inactivity.


 
Pages: first : previous : 1 [2] 3 4 5 6 7 8 9 ... : last (24)

Author Topic

Tanja Torture
Posted - 2008.12.19 06:00:00 - [31]
 

Thx for your fast response. I've changed now the trace settings to trace_all. And yes the isActive field is set to 1. Now I get the following:
Quote:

[2008-12-19 05:43:34.747] DATABASE: Before connect for mysqlt://webX:password@localhost/eve_dbo?new in common_db.in
[2008-12-19 05:43:34.754] DATABASE: Before connect for mysqlt://webX:password@localhost/eve_dbo?new in common_db.in
[2008-12-19 05:43:34.755] Tired of waiting! Getting eve-api-pull for 0
[2008-12-19 05:43:34.756] DATABASE: Before connect for mysqlt://webX:password@localhost/eve_dbo?new in common_db.in
[2008-12-19 05:43:34.756] DATABASE: Before connect for mysqlt://webX:password@localhost/eve_dbo?new in common_db.in
[2008-12-19 05:43:34.757] CHAR: Connect before section in eve-api-pull.php
[2008-12-19 05:43:34.757] DATABASE: Before connect for mysqlt://webX:password@localhost/eve_dbo?new in common_db.in
[2008-12-19 05:43:34.757] CHAR: Before GetAll $charList in eve-api-pull.php
[2008-12-19 05:43:34.758] CHAR: Before require pulls_char.inc
[2008-12-19 05:43:34.761] DATABASE: Before connect for mysqlt://webX:password@localhost/eve_dbo?new in common_db.in
[2008-12-19 05:43:34.762] Tired of waiting! Getting CharacterSheet for 9XXXXXXX


The chache directory only contains the Yapeal_notice.log which contains the messages from my last post. I have no clue if it is something with the database. But the chachedUntil field gets filled. So it can't be that wrong, I think... but I've never used AdoDB before...
I can also send you the configuration files etc. via E-Mail if that helps. Would be nice if I can get it to work. I just love the idea of yapeal.

greets Tanja

Dragonaire
Caldari
Corax.
PURgE Alliance
Posted - 2008.12.19 07:38:00 - [32]
 

You're the second one to have problems in that area on Yapeal so I've added some more tracing code to revision 313 to try to narrow it down a little bit more if you could grab it and we'll see if that help me figure out why. I've never had any problem with that part of the code on my test server so it's really got me puzzled what's going on. For the other guy we just copied over my code from my test server and it started work but by that time he'd also changed host so wasn't totally certain what had cause the problem before.

I'm also going to do some checking and see if it's something where I change it on my test server that didn't get back into the subversion some how. If we can't figure it out after you try new version we'll get together with E-mail and I'll take a look at your config too

Tanja Torture
Posted - 2008.12.19 08:12:00 - [33]
 

Well plz tell me which options and debugging lvl's should be enabled to help you. I've checked out the newsest version, but I can't see a diffrence in the messages.

Dragonaire
Caldari
Corax.
PURgE Alliance
Posted - 2008.12.19 08:44:00 - [34]
 

Looks like you have the ones I need on already but trace_section=YAPEAL_TRACE_CHAR|YAPEAL_TRACE_DATABASE are the only ones I should need to track it down more. If that doesn't seem to add any more output try adding |YAPEAL_TRACE_REQUEST.

I'm sure you've notice but just in case you missed it Yapeal never clears the log files it just keeps added to end so you have to always scroll down to see latest run or delete them so they start fresh.

We might also try getting together in-game or on IM if we don't figure it out soon and report back to thread what we figure out the problem.

Tanja Torture
Posted - 2008.12.19 09:24:00 - [35]
 

Well I added those options, no success. I wrote you an email with my configuration and stuff.

greets!

Dragonaire
Caldari
Corax.
PURgE Alliance
Posted - 2008.12.19 23:12:00 - [36]
 

Ok a little update for everyone make sure curl is install on your server and phpinfo() shows something about curl because it has to be added as ext to php as well. That usually means other package has to be installed on linux system or have curl compiled into php I'll be adding some addition check to Yapeal soon also so you get error messages if it not setup right.

Ryel Theon
Take A Wish Foundation
Posted - 2008.12.20 00:32:00 - [37]
 

There's a bug in the table structure of MarketOrders. An API pull attempts to insert with a column named accountKey. However the table structure as defined in the .sql file in the distribution does not create MarketOrders with that column.

Adding it with the same definition found in other tables containing accountKey allows the API pull to properly populate MarketOrders.

This was with an svn checkout from today.

Thanks for the work on this. I'm only just starting to play with it but it looks good so far.

Dragonaire
Caldari
Corax.
PURgE Alliance
Posted - 2008.12.20 02:04:00 - [38]
 

Edited by: Dragonaire on 20/12/2008 02:04:36
Thanks for the bug report but the SQL was right was bad copy&paste on my part in pulls-corp.inc that needed fixed. Market orders don't have accountKeys just ownerIDs. Razz I've updated subversion with fix.

Ryel Theon
Take A Wish Foundation
Posted - 2008.12.20 18:12:00 - [39]
 

Thanks for the update. I've got another bug. I'm at svn rev 318 and running an api pull results in:

Missing file: /home/cpueve/public_html/yapeal/ADOdb/drivers/adodb-mysqlt.inc.php


Dragonaire
Caldari
Corax.
PURgE Alliance
Posted - 2008.12.20 20:11:00 - [40]
 

Sorry about that forgot to post that you'll need to update your yapeal.ini file I change to using the mysqli driver for ADOdb and I noted it in svn commit but forgot to do so here. You'll need to change the line that reads driver="mysqlt://" to driver="mysqli://" and you'll be good. Should have been using it to start with since it's for the newer MySQL DBs not sure why I got started with the other one but thought I should change. Also means only need one file for driver instead of 2 which is always nicer Smile You can also look in the sample ini which has the new line now too. I'm thinking about adding some kind of version info for ini file that it will check for so Yapeal can issue a warning if it's incompatible with your current one instead of just failing or that you can at least check manual for which is current and what the changes are. I don't change it very often but be nicer to have something in place.

Dragonaire
Caldari
Corax.
PURgE Alliance
Posted - 2008.12.21 00:21:00 - [41]
 

Ryel Theon - You were right to add it. There is a accountKey field for MarketOrders. I've now corrected pulls-corp.inc, pulls-char.inc, and the SQL file and added it to them all. I shouldn't try reading the forum and making changes to code when I'm half asleep I sometimes try short cutting and not double check myself against the XML files or Eve-Dev like I should Razz So sorry everyone and reason it hadn't been caught much soon was the alt I'd been using to test with didn't have any market orders so I'd never notice it didn't work right I've now made a couple orders with that character so in the future maybe I'll notice when I break something like that Very Happy The only API I wouldn't be able to test now will be StarbaseList and if I get around to adding it back StarbaseDetails.

I've push out the change to subversion revision 319

Juloshko
Caldari
Sphere Industries
Posted - 2008.12.22 10:59:00 - [42]
 

I just cant figure this out, the readme is....non existent and i dont have a clue after over 14 hours of trying

please can you help me

server windows xp with Wamp server 2.0c
MySql 5.1.3


(and wtf is a cronjob?)

Eldstrom
Posted - 2008.12.22 12:51:00 - [43]
 

Schedule task would be the windows equivalent to a cronjob.

Eld

Juloshko
Caldari
Sphere Industries
Posted - 2008.12.22 14:49:00 - [44]
 

Originally by: Eldstrom
Schedule task would be the windows equivalent to a cronjob.

Eld


but what am i scheduling? is it one of the php files
(never done anything like cronjob before)

Eldstrom
Posted - 2008.12.22 15:21:00 - [45]
 

Originally by: Juloshko
Originally by: Eldstrom
Schedule task would be the windows equivalent to a cronjob.

Eld


but what am i scheduling? is it one of the php files
(never done anything like cronjob before)


Sorry Juloshko I am unfamiliar with the workings of this particular API library. I would assume it would be one or more of the .php files.

Eld.

Ryel Theon
Take A Wish Foundation
Posted - 2008.12.22 17:24:00 - [46]
 

Originally by: Juloshko


but what am i scheduling? is it one of the php files
(never done anything like cronjob before)


These are the steps I used to get started. I doubt this constitutes documentation of any type. Smile

  1. Create a database in MySQL for your tables. Call it something like yapeal

  2. You'll want to run the Yapeal.sql file in that database to create all of the tables

  3. Copy the sample config in config/ to config/yapeal.ini and update it with the values appropriate for your system (database location, username, password)

  4. Create a row in yapeal.RegisteredUser containing your userid/api key info

  5. Create rows in yapeal.RegisteredCharacter and yapeal.RegisteredCorporation appropriate for your char/corp info and set isActive to 1 in those rows

  6. Run backend/eve-api-pull.php and it should populate all of those tables with the info associated with your user/corp as set above. Set it to run periodically to automatically keep your data up to date.

  7. Now write your favorite web applications to interact with those tables



Hope that helps.

Dragonaire
Caldari
Corax.
PURgE Alliance
Posted - 2008.12.22 18:01:00 - [47]
 

Ryel Theon's instructions is a good summary of how to get started and yes the documentation is lacking still for how to use it. You will find the start of a user guide in the Docs directory but it is very lacking at this point and somewhat outdated.

I've only tested Yapeal on Linux myself but I did try to design it so it could be adapted for use in Windows. If someone does adapt it for a Windows system I'd like to hear about it and any changes in the code that might be needed to make it easier.

I'll try to put up some kind of summary or whatever of some of the key files in Yapeal on the wiki if I get a chance that might make it a bit easier to understand.

Dragonaire
Caldari
Corax.
PURgE Alliance
Posted - 2008.12.23 06:17:00 - [48]
 

Hi everyone been working on Yapeal some more in a branch to update some stuff and thought I'd post about some of the highlights or at least what I remember doing anyway Laughing


  • Added a new class for tracing and changed code to use it. The tracing code was starting to get overwhelming and had some limitations that I'm trying to overcome.

  • Added new required setting in yapeal.ini needed by new tracing code. There is now another variable named trace_output that needs to be set to "file", "database", or "both". Sending the tracing information to the database isn't active yet but is being looked at for the future.

  • Removed the old unused setting in yapeal.ini for use_exception since all the code had already been updated to no longer use it. It was left over from time when code used both errors and exception in areas. Code now only uses exceptions so this setting is no longer needed.

  • Changed location and how the CachedUntil table is updated. In some error conditions when the database wasn't update the cachedUntil time still would be, now the cachedUntil time is set slightly in to the future and only set to cachedUntil time from XML if we actual update the related table(s). This should also let Yapeal recover quicker from temporary error conditions by API server.

  • Moved the function getAPIinfo() used to get data from API into it's own file inc/common_api.inc instead of having it in the inc/common_db.inc file.

  • Fixed some typos in trace and error messages and probably made some new ones Very Happy Also did varies other small changes here and there to code formatting etc.



Soon as I finish posting this message I move my changes into trunk and push it out for you to get. Don't forget to update your yapeal.ini file with new settings as missing the added one will stop it from running.

revision 355 is up with the new changes enjoy.

Ramov Tinoga
Tinoga Enterprises
Posted - 2008.12.23 11:43:00 - [49]
 

Edited by: Ramov Tinoga on 23/12/2008 12:34:21
Originally by: Dragonaire

  • Moved the function getAPIinfo() used to get data from API into it's own file inc/common_api.inc instead of having it in the inc/common_db.inc file.



revision 355 is up with the new changes enjoy.

Could you please submit the new inc/common_api.inc so we can use it too? Embarassed Wink

[Edit: Temporarily i'm using rev 351 from the "New-Tracing" branch. Now I get

Message: Undefined variable: tracing
File: E:\eclipse\workspace-eve\yapeal\backend\eve-api-pull.php
Line: 105

I'm using XAMPP 1.6.8 on Windows XP SP3 for development.
]

[Edit2: Ok, the above one was a notification because of trace=FALSE. It works! It's filling my database with.. stuff!]


Thank you very much for Yapeal. I look forward to do crazy stuff with it. ugh

Thanks also Ryel for the hints on what was missing on my DB.

Dragonaire
Caldari
Corax.
PURgE Alliance
Posted - 2008.12.23 15:16:00 - [50]
 

Sorry I copied over that file here but forgot to add it to the subversion for trunk Razz revision 357 should be complete with inc/common_api.inc

Dragonaire
Caldari
Corax.
PURgE Alliance
Posted - 2008.12.24 00:46:00 - [51]
 

Edited by: Dragonaire on 24/12/2008 01:31:40
Hi again someone that's been testing Yapeal for their application has found an error with the IndustryJobs table. Seems that the `installedItemLicensedProductionRunsRemaining` field is set to -1 at times but I'd made it an unsigned bigint which doesn't work so well Razz I'm putting out an updated yapeal.sql file for everyone. Here's also the SQL to change your active tables so you shouldn't have to dump and reload your data but I would recommend doing a backup just in case anyway Wink

ALTER TABLE `IndustryJobs` CHANGE `installedItemLicensedProductionRunsRemaining` `installedItemLicensedProductionRunsRemaining` BIGINT( 20 ) NOT NULL

Thanks to ThyShiva for finding this and sending me the fix with the alter table included.

revision 358

EDIT: Changed case of table name in alter table.

Juloshko
Caldari
Sphere Industries
Posted - 2008.12.27 03:33:00 - [52]
 

Finaly got it running

now just gotta make a cool looking page for it
(when i learn php)

Iskandara Cho
Posted - 2008.12.27 17:20:00 - [53]
 

Hi,

I would like to use yapeal to pull the personal information for my 3 alts as well as for my corporation, but I am having more than a little difficulty figuring out what I need to modify or not in the .ini file. Then there is the question of where I find the information needed for the registered characters and corporations.

A little help?


Dragonaire
Caldari
Corax.
PURgE Alliance
Posted - 2008.12.27 19:12:00 - [54]
 

Edited by: Dragonaire on 27/12/2008 19:26:40
See post 46 by Ryel Theon for a quick outline of what you'll need to have/do to use Yapeal or go to the wiki pages and look at what I've wrote up there.

There are a couple ways to get the data you need but the easiest is to go to eve-online

  • Then go to Eve Insider > My Character and sign in as needed

  • Click on the character you want information for

  • Click link to get XML data and from there you can get your characterID and corporationID

  • Go back to character info page and scroll down to the API section and click the link there

  • Read the info on the page about API keys then click button to get full API Key and either copy & paste it to a text file to save it or just write down your userID and API Key

  • Now you'll need to add the information you've collect to the RegisteredUser and RegisteredCharacter tables



Hope that enough to get you started.

Iskandara Cho
Posted - 2008.12.28 14:38:00 - [55]
 

Edited by: Iskandara Cho on 29/12/2008 08:25:45
Hi,
Thanks, that did help.

I've gone through your sample.ini file and come up with two separate documents:

An [Example yapeal.ini for a single database] and a first pass at [Documentation for the yapeal.ini file].(both links broke, see post below)

If you could take a look at them and see if I've made any mistakes I'd be grateful.

I also ended up with a few questions:

QuestionWhat is the behaviour of conflicting settings between the database and the database-xxx "active" fields?

QuestionWhat is the database named in any dbname field used for if the active field is set to FALSE? ie is it necessary to have a db name in the default section if the db-xxx sections have named db's?

QuestionShould each of the sub-db's have the same structure as the main db (as defined by the sql file provided)?

QuestionDoes the username:password pairing need to be the same across all databases? Though there is a field in each db-xxx section they all share the same name "writer". If there is a pairing in the default Db section and a different pairing in a database-xxx section, which takes precedent?

QuestionIs the required section [DEBUGGING] really called [TRACING]?

Thanks!

Dragonaire
Caldari
Corax.
PURgE Alliance
Posted - 2008.12.28 23:51:00 - [56]
 

Glad it helped. I tried going to the files you linked and I get '404
Sorry, the stargate denies you access.' errors so think you need to check the links.

Now on to you're questions.

The [database] section sets the defaults for all the [database-xxx] sections. So if you have something set in both of them the [database-xxx] setting will over ride what's in the [database] section. If you set all required settings in each active [database-xxx] section then you don't have to set any of the ones in [database] at all but it is easier to use just it if you're only using a single DB. In the original application that Yapeal developed from I use a separate DB for each API group (char, corp, eve, etc) and I've so far kept that ability to allow for more versatility by anyone using it.

If you decide to use multiple DBs say to have separate character and corporation DBs then you would have to duplicate the overlapping tables like MarketOrders, WalletJournals, etc. for each DB.

Each DB can have their own user/password pair if you want. You could probably even have all tables from the same API groups (char, corp, etc) have different user/password pair if you wanted in a single DB because of the way they are used. Each [database-xxx] section has several constants set from the yapeal.ini settings which are then used throughout Yapeal to access each 'DB' even though in most cases they are all set to the same values when using a single DB. Using a single user/password pair and one DB for all the tables is by far the easiest way to use Yapeal but if you need the more complex setup with multiple DBs and/or users it was build to allow for that. I will say though that the single DB with multiple users hasn't been tested by me but I see no reason why it shouldn't work.

There is both a tracing and debugging section for now I have looked at combining them but they do have different purposes even though they often overlap when you are actually trying to debug something. I use the tracing sometimes to track the program flow where the debugging code and error messages are either missing or not as helpful as they could be. A good example of when this has happened was with a couple users that had no error messages but Yapeal still wouldn't download their API information. What it turned out to be was they had cURL installed but not the php extension you need so php can use it and php didn't throw any kind of error messages that we could find because it had been build with cURL in an extension module and it just wasn't loaded. I thought it would have give us some kind of error message when I called the cURL function but instead it just quietly failed Razz

Okay I think I've covered all your questions and hopefully you can fix those links and I'll have a look at what you've done and thanks for the interest in trying to help document Yapeal for everyone.

Mintoko
Gallente
Taedium In Perpetuam
Posted - 2008.12.29 06:27:00 - [57]
 

Edited by: Mintoko on 29/12/2008 06:42:17
This is absolutely wonderful. I finally got it to work, but have a request...

I want to be able to add a prefix to the table names so that I can place them into my current database and still keep them together instead of having them spread throughout the list. I'm looking at the possibility of doing this myself, but will probably still be fiddling with it a lot longer than it would take you to do it. :)

Perhaps, a default yap_ or something manually configurable.

Iskandara Cho
Posted - 2008.12.29 08:22:00 - [58]
 

Edited by: Iskandara Cho on 29/12/2008 10:53:02
Thanks for the answers Dragonaire.

docs and sample ini files in a zip

It seems eve files didn't think they were appropriate content, so I've tried it as a zip. Let me know if there are still problems and I'll find another host.


I am getting an error when attempting to run the pull:

Parse error: syntax error, unexpected '{' in /[big file path]/yapeal.rab/backend/eve-api-pull.php on line 102

sorry if it's something simple and obvious Rolling Eyes

Dragonaire
Caldari
Corax.
PURgE Alliance
Posted - 2008.12.29 19:24:00 - [59]
 

Seems Eve-files still doesn't like something it's still got the same error Sad

An error on line 102 of backend/eve-api-pull.php which is the try { line would suggest to me that you've got a bad file some how probably through an unintentional edit while looking at one of them.
I've put out a new revision 363 which you might try getting and overwrite the existing files see if that clears it up. Yapeal's been running without error on my test server for the last several versions so that's the most likely cause. I've done it myself a few times while looking around at stuff before Wink If you can when opening a file in your editor just to look at it try opening it read-only.

Dragonaire
Caldari
Corax.
PURgE Alliance
Posted - 2008.12.29 19:55:00 - [60]
 

Mintoko - I've been looking at adding some kind of prefix to all the table names because some of the API re-use the same names in the rowsets but with different columns (fields) Razz An example would be 'skills' in both the CharacterSheet and SkillTree. To add any kind of prefix though will require editing most the SQL queries in Yapeal since most places the table names are hard coded into the SQL Razz Probably a bit of lack of foresight on my part but something that often gets overlooked when try to get something working.

I'm working on some changes to Yapeal that should make adding more APIs in the future easier and as part of that I plan on adding some kind of prefixing system so it's less of a problem. I'm not sure when I'll release these changes since it's very much in an early stage of development and I haven't even got any running code yet so best I can say now is it's on the list of things I plan to do Smile

If you decide you can't wait and go ahead on your own and make something hopefully you'll share it back with us and maybe I'll be able to add it into Yapeal for everyone else that might have the same need.


Pages: first : previous : 1 [2] 3 4 5 6 7 8 9 ... : last (24)

This thread is older than 90 days and has been locked due to inactivity.


 


The new forums are live

Please adjust your bookmarks to https://forums.eveonline.com

These forums are archived and read-only