Gamestudio Links
Zorro Links
Newest Posts
Data from CSV not parsed correctly
by EternallyCurious. 04/18/24 10:45
StartWeek not working as it should
by Zheka. 04/18/24 10:11
folder management functions
by VoroneTZ. 04/17/24 06:52
lookback setting performance issue
by 7th_zorro. 04/16/24 03:08
zorro 64bit command line support
by 7th_zorro. 04/15/24 09:36
Zorro FIX plugin - Experimental
by flink. 04/14/24 07:48
Zorro FIX plugin - Experimental
by flink. 04/14/24 07:46
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
1 registered members (AndrewAMD), 552 guests, and 1 spider.
Key: Admin, Global Mod, Mod
Newest Members
EternallyCurious, 11honza11, ccorrea, sakolin, rajesh7827
19046 Registered Users
Previous Thread
Next Thread
Print Thread
Rating: 5
Page 1 of 17 1 2 3 16 17
IG plugin initial release #465410
04/25/17 19:54
04/25/17 19:54
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
Hi,

I have developed a plugin to use IG with Zorro, and today I'm releasing the initial version. You can find instructions on how to install here:
https://github.com/dan-lind/igzplugin

Please let me now of any issues you encounter, problems with the documentation, or other questions that you might have. I'll answer as fast as I can :-)

As pointed out, this is the first release. Don't expect it to be free of bugs just yet :-)

Regards,
Daniel

Last edited by Dalla; 04/25/17 19:54.
Re: IG plugin initial release [Re: Dalla] #465428
04/26/17 20:00
04/26/17 20:00
Joined: Feb 2015
Posts: 652
Milano, Italy
M
MatPed Offline
User
MatPed  Offline
User
M

Joined: Feb 2015
Posts: 652
Milano, Italy
Thank you Dalla, nice job!

Re: IG plugin initial release [Re: MatPed] #465486
04/30/17 12:59
04/30/17 12:59
Joined: Mar 2017
Posts: 48
Bologna
K
kmerlo Offline
Newbie
kmerlo  Offline
Newbie
K

Joined: Mar 2017
Posts: 48
Bologna
Hello,
I'm tryng to install the plugin.
I have followed the istruction
https://github.com/dan-lind/igzplugin

but at the and of the procedure the plugin does not compare in zorro's menu list "Account"

For sure I have done some mistakes

I have a doubt about point 2 for the second part :
"2.) Add *${yourJREinstallPath}jrebin* and ${yourJREinstallPath}jrebincom.iggroup.api.client to the front of your Path environment variable(here is a howto)."

I suppose that I should have this file
"com.iggroup.api.client"
in the directory "${yourJREinstallPath}jrebin" but I haven't this file ....
Maybe the problem is this?

another question:
insise the zip file "igplugin.zip" there is the file"igplugin-0.1.jar" I must to launch before zorro? I tried but I failed frown


PS
as JRE I have
C:Program FilesJavajre1.8.0_131bin

I hope someone can help me

Thanks

Re: IG plugin initial release [Re: kmerlo] #465491
04/30/17 16:54
04/30/17 16:54
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
Hi

Thanks for the feedback. There was a typo in step 2 of the instructions, I have updated them now. Please check again. Also please download the zip-file again, I'm not sure I had the correct compiler options the first time around, but I have verified that it's correct this time around.

Also, you shouldn't start the jar-file yourself, Zorro will do that by itself.

/Daniel

Re: IG plugin initial release [Re: Dalla] #465494
04/30/17 19:53
04/30/17 19:53
Joined: Mar 2017
Posts: 48
Bologna
K
kmerlo Offline
Newbie
kmerlo  Offline
Newbie
K

Joined: Mar 2017
Posts: 48
Bologna
Hi Daniel
thanks a lot!!
you are very kind .
I hope in the future that I will be able to return the favor....

With the new zip file and the new PATH , now its Ok!! :-)
The plugin is visible in zorro's menu Account

Now all the market are closed so I can't test anymore...
I will try tommorrow (if some market will be open)

I have another doubt about how I have to change the assetFix

For example for EUR/USD I supposed that I have to set the two variables like this

Name= EUR/USD
Symbol= CS.D.EURUSD.CFD.IP

or as an alternative
Name= CS.D.EURUSD.CFD.IP
Symbol= EUR/USD

(of course there are the other columns in the AssetsFix.csv)

Re: IG plugin initial release [Re: kmerlo] #465500
05/01/17 05:44
05/01/17 05:44
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
Great to hear!

The first alternative is correct. Name is the name that will be displayed in zorros asset drop down, so that can be whatever you want it to be, as long as you set symbol to be the value expected by the broker.

Re: IG plugin initial release [Re: Dalla] #465501
05/01/17 07:54
05/01/17 07:54
Joined: Mar 2017
Posts: 48
Bologna
K
kmerlo Offline
Newbie
kmerlo  Offline
Newbie
K

Joined: Mar 2017
Posts: 48
Bologna
GoodMorning Daniel
I m tring now and it's OK
I used the zorro's script "trade test" and I have bought and the I have sold one lot
In the same time I was checking in the IG's web site (my private area) and the position and the order are the same that I have commanded with zorro :-)

Next step will be launch a z script :-)

in the istruction
https://github.com/dan-lind/igzplugin
you write:
"Start Zorro and check if the Account drop-down-box shows IG as an available broker. Enter your login details, pick a script of your choice and press Trade."

maybe it's more clear if you specify that the "Login details" is not the first IG' account but that created for the companion API
praticaly the same that peoplet have to use

https://labs.ig.com/sample-apps/api-companion/index.html


post scriptum
Sorry for my English, I suppose that there are many errors but I hope that The concept is understandable (also with the help of google translate :-) )

Re: IG plugin initial release [Re: kmerlo] #465517
05/02/17 11:07
05/02/17 11:07
Joined: Mar 2017
Posts: 48
Bologna
K
kmerlo Offline
Newbie
kmerlo  Offline
Newbie
K

Joined: Mar 2017
Posts: 48
Bologna
One Info for all
I have a sever in EC2 Amazon with "windows server 2012"
To configure the Environment Variables "Path" I follow the istruction

https://lsdbtech.wordpress.com/2015/05/28/windows-server-2012-r2-change-environment-variables/

Last edited by kmerlo; 05/02/17 11:08.
Re: IG plugin initial release [Re: kmerlo] #465538
05/02/17 18:59
05/02/17 18:59
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
Great to know!

However I'm not sure what you mean when you say "that the "Login details" is not the first IG' account but that created for the companion API praticaly the same that peoplet have to use "

What to you mean with "first IG account" ? It almost sounds like you created a separate account just to create the api key?

Re: IG plugin initial release [Re: Dalla] #465549
05/03/17 11:42
05/03/17 11:42
Joined: Mar 2017
Posts: 48
Bologna
K
kmerlo Offline
Newbie
kmerlo  Offline
Newbie
K

Joined: Mar 2017
Posts: 48
Bologna
Hello
I mean : "first IG account" is the first account created when I opened the account with IG
I use it here
https://www.ig.com/it/login
to enter in the private area of the web site

Then I created API Key and (both for real and demo account)

Later
Following the istruction here "http://labs.ig.com/gettingstarted"

Getting started
To begin using our API all you need to do is:
Create an account
Generate your API key
Start coding


I create a new account (I mean , ID and passowrd) to use
in this link
http://labs.ig.com/sample-apps/api-companion/index.html
Buy this second account has only this functionality to check API request like to find the IG'S symbol of EUR/USD

Re: IG plugin initial release [Re: kmerlo] #465550
05/03/17 11:50
05/03/17 11:50
Joined: Mar 2017
Posts: 48
Bologna
K
kmerlo Offline
Newbie
kmerlo  Offline
Newbie
K

Joined: Mar 2017
Posts: 48
Bologna
Daniel
are you using zorro with z script?

I m using z7 it 's work but I think it isn't ok to 100%
indeed today Zorro have stil in on the market with a currency, Instead in the ig platforms I was FLTAT

I think there are strange Behaviors and some messages appear
"!Severe error occured, check igzplugin.log logfile!"

I am carrying on to try zorro's z7 (in demo of course) :-)

Re: IG plugin initial release [Re: kmerlo] #465552
05/03/17 13:39
05/03/17 13:39
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
Hi

You dont need to create a second account if you dont want to, you can create an api key on your original account.

What does the igplugin.log say? Check in the ig folder under the plugin directory of zorro

I don't trade any z systems myself at this point.

Last edited by Dalla; 05/03/17 13:41.
Re: IG plugin initial release [Re: Dalla] #465560
05/03/17 19:24
05/03/17 19:24
Joined: Mar 2017
Posts: 48
Bologna
K
kmerlo Offline
Newbie
kmerlo  Offline
Newbie
K

Joined: Mar 2017
Posts: 48
Bologna
Hi Daniel

Today the zorro's Behavior seems to be correct
But there are still the message error in zorro'log

I have attached the log in this message

In the files log I have replaced my username with "XXXXX" and my key with "YYYYYY"

in the zorro's file log "Z7demo.log" the last message that I founded:

"[Wed 03.05.17 17:03] 30175 +106 +22 /// 1.0922/1.09241.0915/1.0916
!Severe error occured, check igzplugin.log logfile!
[Wed 03.05.17 18:03] 30171 +106 +19 /// 1.0916/1.09281.0904/1.0914"

and in file "igzplugin.log" I founded:


2017-05-03 17:29:22.124 [ThreadPoolTaskScheduler4] ERROR c.danlind.igz.adapter.RestApiAdapter - Exception when refreshing session token
org.springframework.web.client.ResourceAccessException: I/O error on POST request for "https://demo-api.ig.com/gateway/deal/session/refresh-token": demo-api.ig.com:443 failed to respond; nested exception is org.apache.http.NoHttpResponseException: demo-api.ig.com:443 failed to respond
at org.springframework.web.client.RestTemplate.doExecute(RestTemplate.java:666)
at org.springframework.web.client.RestTemplate.execute(RestTemplate.java:613)
at org.springframework.web.client.RestTemplate.exchange(RestTemplate.java:531)
at com.danlind.igz.ig.api.client.RestAPI.refreshSessionV1(RestAPI.java:758)
at com.danlind.igz.adapter.RestApiAdapter.refreshSessionV1(RestApiAdapter.java:282)
at com.danlind.igz.brokerapi.BrokerLogin.refreshAccessToken(BrokerLogin.java:82)
at com.danlind.igz.brokerapi.BrokerLogin.lambda$startRefreshAccessTokenScheduler$12(BrokerLogin.java:88)
at org.springframework.scheduling.support.DelegatingErrorHandlingRunnable.run(DelegatingErrorHandlingRunnable.java:54)
at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
at java.util.concurrent.FutureTask.runAndReset(Unknown Source)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(Unknown Source)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
Caused by: org.apache.http.NoHttpResponseException: demo-api.ig.com:443 failed to respond
at org.apache.http.impl.conn.DefaultHttpResponseParser.parseHead(DefaultHttpResponseParser.java:141)
at org.apache.http.impl.conn.DefaultHttpResponseParser.parseHead(DefaultHttpResponseParser.java:56)
at org.apache.http.impl.io.AbstractMessageParser.parse(AbstractMessageParser.java:259)
at org.apache.http.impl.DefaultBHttpClientConnection.receiveResponseHeader(DefaultBHttpClientConnection.java:163)
at org.apache.http.impl.conn.CPoolProxy.receiveResponseHeader(CPoolProxy.java:165)
at org.apache.http.protocol.HttpRequestExecutor.doReceiveResponse(HttpRequestExecutor.java:273)
at org.apache.http.protocol.HttpRequestExecutor.execute(HttpRequestExecutor.java:125)
at org.apache.http.impl.execchain.MainClientExec.execute(MainClientExec.java:272)
at org.apache.http.impl.execchain.ProtocolExec.execute(ProtocolExec.java:185)
at org.apache.http.impl.execchain.RetryExec.execute(RetryExec.java:89)
at org.apache.http.impl.execchain.RedirectExec.execute(RedirectExec.java:111)
at org.apache.http.impl.client.InternalHttpClient.doExecute(InternalHttpClient.java:185)
at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:83)
at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:56)
at org.springframework.http.client.HttpComponentsClientHttpRequest.executeInternal(HttpComponentsClientHttpRequest.java:89)
at org.springframework.http.client.AbstractBufferingClientHttpRequest.executeInternal(AbstractBufferingClientHttpRequest.java:48)
at org.springframework.http.client.AbstractClientHttpRequest.execute(AbstractClientHttpRequest.java:53)
at org.springframework.web.client.RestTemplate.doExecute(RestTemplate.java:652)
... 14 common frames omitted
2017-05-03 17:29:22.128 [ThreadPoolTaskScheduler4] ERROR o.s.s.s.TaskUtils$LoggingErrorHandler - Unexpected error occurred in scheduled task.
java.lang.RuntimeException: null
at com.danlind.igz.adapter.RestApiAdapter.refreshSessionV1(RestApiAdapter.java:290)
at com.danlind.igz.brokerapi.BrokerLogin.refreshAccessToken(BrokerLogin.java:82)
at com.danlind.igz.brokerapi.BrokerLogin.lambda$startRefreshAccessTokenScheduler$12(BrokerLogin.java:88)
at org.springframework.scheduling.support.DelegatingErrorHandlingRunnable.run(DelegatingErrorHandlingRunnable.java:54)
at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
at java.util.concurrent.FutureTask.runAndReset(Unknown Source)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(Unknown Source)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)

Attached Files
log.zip (314 downloads)
Re: IG plugin initial release [Re: kmerlo] #465561
05/03/17 20:07
05/03/17 20:07
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
That's weird. Seems to be happening almost exactly every two hours, at least of you look at the last three occurrences in your log. But it doesn't seem to affect trading as a long position was opened after one of the failures? Please let me know if this is not the case.

I'll try to look more into this issue later this week.

Re: IG plugin initial release [Re: Dalla] #465567
05/03/17 21:26
05/03/17 21:26
Joined: Mar 2017
Posts: 48
Bologna
K
kmerlo Offline
Newbie
kmerlo  Offline
Newbie
K

Joined: Mar 2017
Posts: 48
Bologna
Hi Daniel
I confitm that it doesn't seem to affect trading as a long position was opened after one of the failure

If could help you I saw that you can the report in real time here
http://54.93.127.181/z7.htm

Good Night

Re: IG plugin initial release [Re: kmerlo] #465574
05/04/17 09:17
05/04/17 09:17
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
Thanks for confirming.

I have verified the issue locally as well now.
I think I may have found a fix as well, but I want to run some more tests locally before preparing a new release.

/Daniel

Last edited by Dalla; 05/04/17 11:10.
Re: IG plugin initial release [Re: Dalla] #465630
05/06/17 18:25
05/06/17 18:25
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
Quick update: I think I have fixed the issue which caused the errors you are seeing. However I also found another potential issue that I fixed. Since the markets are closed I can't verify the fix right now, so I'll try to confirm and hopefully release an update on Monday.

Re: IG plugin initial release [Re: Dalla] #465637
05/07/17 09:55
05/07/17 09:55
Joined: Mar 2017
Posts: 48
Bologna
K
kmerlo Offline
Newbie
kmerlo  Offline
Newbie
K

Joined: Mar 2017
Posts: 48
Bologna
Hi Daniel
Great Job! :-)
When you will released an update me too I will try the news release

Thanks

Have a good sunday

Re: IG plugin initial release [Re: kmerlo] #465649
05/08/17 06:43
05/08/17 06:43
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
Hi,

A new version has been released that should hopefully make connections more stable.
Download it here: https://github.com/dan-lind/igzplugin/releases/tag/v0.12

/Daniel

Re: IG plugin initial release [Re: Dalla] #465654
05/08/17 14:06
05/08/17 14:06
Joined: Mar 2017
Posts: 48
Bologna
K
kmerlo Offline
Newbie
kmerlo  Offline
Newbie
K

Joined: Mar 2017
Posts: 48
Bologna
Hi Daniel
I Have installed the new versions
In the next days I will report the outcome of the test

Thanks

Re: IG plugin initial release [Re: kmerlo] #465687
05/09/17 18:57
05/09/17 18:57
Joined: Mar 2017
Posts: 48
Bologna
K
kmerlo Offline
Newbie
kmerlo  Offline
Newbie
K

Joined: Mar 2017
Posts: 48
Bologna
Hi Daniel
there are still some errors
Maybe it seems there are less errors

The log is attached

Attached Files
igzplugin.zip (351 downloads)
Last edited by kmerlo; 05/09/17 18:59.
Re: IG plugin initial release [Re: kmerlo] #465701
05/10/17 04:08
05/10/17 04:08
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
Hi

These errors suggests that there were problems connecting to the demo API, i.e. the server is not responding at all or not responding in a time. I saw that too when running my own tests. It's not that worrying as I think the demo server is also used for development purposes for IG, that is they will sometimes restart it to push new releases etc to the demo environment.

If you plan to run additional tests, could you please delete your log-file before starting Zorro? It makes it easier for me to determine exactly what is relevant and not in the log.

Thanks for your help :-)

Last edited by Dalla; 05/10/17 05:20.
Re: IG plugin initial release [Re: Dalla] #465852
05/15/17 10:09
05/15/17 10:09
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
@kmerlo, wanted to check if you ran any more tests? Any new issues?

Re: IG plugin initial release [Re: Dalla] #465876
05/16/17 07:49
05/16/17 07:49
Joined: Mar 2017
Posts: 48
Bologna
K
kmerlo Offline
Newbie
kmerlo  Offline
Newbie
K

Joined: Mar 2017
Posts: 48
Bologna
Hi Dalla
I still using the api, but sorry in this day I have some other commitments. I hope to be more precise in the next days :-)

Menatime I have detected some minor strange Behaviour, maybe tree....

For the first now I don't remember exactely (I ' sorry), but should be that in zorro the position was flat instead in IG the position still open...

the second : in zorro
System State: 30414 +35 +0
instead in IG the account is 30427
I have stoped Zorro and then I have restarted it, but the money still different

third:
some message errors during the week end, so I changed in file the Z.INI the variable Weekend from "2" to "3"
I will check the next week end if the modify is usefull:-)

Attached Files
igzplugin.zip (314 downloads)
Re: IG plugin initial release [Re: kmerlo] #465877
05/16/17 08:24
05/16/17 08:24
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
I understand, just curious to hear any results :-)

The most obvious issue is that there are still a lot of instances where IGs servers does not seem to be responding at all. I'll see if I can confirm if there are some times where at least the demo server is expected to be down.

There are also some issues related to exceeding the api key limits, which is a bit more of an issue. How many assets is this system using?

Re: IG plugin initial release [Re: Dalla] #465882
05/16/17 12:03
05/16/17 12:03
Joined: Mar 2017
Posts: 48
Bologna
K
kmerlo Offline
Newbie
kmerlo  Offline
Newbie
K

Joined: Mar 2017
Posts: 48
Bologna
Hi daniel,
I am testing only z7, so only 3 assets

Re: IG plugin initial release [Re: kmerlo] #465885
05/16/17 14:05
05/16/17 14:05
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
Hmm, that´s strange. Did you at any time restart the strategy?
3 assets shouldn't be enough to hit the limit unless you restart many times over. Or if there is a bug of course

Re: IG plugin initial release [Re: Dalla] #465888
05/16/17 14:34
05/16/17 14:34
Joined: Mar 2017
Posts: 48
Bologna
K
kmerlo Offline
Newbie
kmerlo  Offline
Newbie
K

Joined: Mar 2017
Posts: 48
Bologna
hi
I think to have restar the strategy 4 o 5 time.

today there ara this error message


2017-05-16 15:36:59.613 [ThreadPoolTaskScheduler1] ERROR c.danlind.igz.adapter.RestApiAdapter - Exception when refreshing session token
org.springframework.web.client.HttpServerErrorException: 503 Service Unavailable
at org.springframework.web.client.DefaultResponseErrorHandler.handleError(DefaultResponseErrorHandler.java:94)
at org.springframework.web.client.RestTemplate.handleResponse(RestTemplate.java:700)
at org.springframework.web.client.RestTemplate.doExecute(RestTemplate.java:653)
at org.springframework.web.client.RestTemplate.execute(RestTemplate.java:613)
at org.springframework.web.client.RestTemplate.exchange(RestTemplate.java:531)
at com.danlind.igz.ig.api.client.RestAPI.refreshSessionV1(RestAPI.java:758)
at com.danlind.igz.adapter.RestApiAdapter.refreshSessionV1(RestApiAdapter.java:275)
at com.danlind.igz.brokerapi.BrokerLogin.refreshAccessToken(BrokerLogin.java:82)
at com.danlind.igz.brokerapi.BrokerLogin.lambda$startRefreshAccessTokenScheduler$13(BrokerLogin.java:92)
at org.springframework.scheduling.support.DelegatingErrorHandlingRunnable.run(DelegatingErrorHandlingRunnable.java:54)
at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
at java.util.concurrent.FutureTask.runAndReset(Unknown Source)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(Unknown Source)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
2017-05-16 15:36:59.632 [ThreadPoolTaskScheduler1] ERROR o.s.s.s.TaskUtils$LoggingErrorHandler - Unexpected error occurred in scheduled task.
java.lang.RuntimeException: 503 Service Unavailable
at com.danlind.igz.adapter.RestApiAdapter.refreshSessionV1(RestApiAdapter.java:287)
at com.danlind.igz.brokerapi.BrokerLogin.refreshAccessToken(BrokerLogin.java:82)
at com.danlind.igz.brokerapi.BrokerLogin.lambda$startRefreshAccessTokenScheduler$13(BrokerLogin.java:92)
at org.springframework.scheduling.support.DelegatingErrorHandlingRunnable.run(DelegatingErrorHandlingRunnable.java:54)
at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
at java.util.concurrent.FutureTask.runAndReset(Unknown Source)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(Unknown Source)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)

Re: IG plugin initial release [Re: kmerlo] #465891
05/16/17 15:15
05/16/17 15:15
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
Same as before then.
The part "503 Service Unavailable" means that the server is not responding.

Re: IG plugin initial release [Re: Dalla] #466034
05/22/17 13:03
05/22/17 13:03
Joined: Mar 2017
Posts: 48
Bologna
K
kmerlo Offline
Newbie
kmerlo  Offline
Newbie
K

Joined: Mar 2017
Posts: 48
Bologna
I Daniel
today I tried z12

http://54.93.127.181/z12.htm

when I have launched the script I have received this message

"
Error 030: asset USD/JPY missing in INITRUN
Error 011: Function ATR called with invalid parameters (no price)
Error 011: Function BBANDS called with invalid parameters (no price).
"

plus other messages

But do you use the API and all it's fine for you o also you have some strange error messages?


PS
later the script has open some position so, it was working but I can't know if se the first message cause that some trade will done badly... :-(

Attached Files
AssetsFix.zip (297 downloads)
igzplugin.zip (295 downloads)
Re: IG plugin initial release [Re: kmerlo] #466035
05/22/17 13:28
05/22/17 13:28
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
Hi

I will check the details later, but it looks like you haven't set up the symbol name for USD/JPY in the AssetsFix file. I'm doing testing also and have fixed a couple of issues. Hoping to push a new release this week.

Re: IG plugin initial release [Re: Dalla] #466037
05/22/17 13:58
05/22/17 13:58
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
You have a character in your AssetsFix for USD/JPY has an extra character at the end that you need to remove. So change

CS.D.USDJPY.MINI.IP"
to
CS.D.USDJPY.MINI.IP

Re: IG plugin initial release [Re: Dalla] #466041
05/22/17 16:56
05/22/17 16:56
Joined: Mar 2017
Posts: 48
Bologna
K
kmerlo Offline
Newbie
kmerlo  Offline
Newbie
K

Joined: Mar 2017
Posts: 48
Bologna
I done a stupid error

I found an other similar error
IX.D.NASDAQ.IFM.IP"

I correct the two errors

But now I have an other stange error
Error 053: CS.D.GBPUSD.IP unavailable at this time

But with the same "AssetFix.csv" when I test the z7 script I haven't this error... :-(

and I have only "z.ini" I don't make the fiel z7.ini or z12.ini

Thanks

Roberto

Re: IG plugin initial release [Re: kmerlo] #466042
05/22/17 17:04
05/22/17 17:04
Joined: Mar 2017
Posts: 48
Bologna
K
kmerlo Offline
Newbie
kmerlo  Offline
Newbie
K

Joined: Mar 2017
Posts: 48
Bologna
In the file log "igzplugin.log" I found for other symbol this messagge
.....error was {"errorCode":"error.public-api.exceeded-api-key-allowance"}....

Re: IG plugin initial release [Re: kmerlo] #466051
05/23/17 04:30
05/23/17 04:30
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
Unfortunately the default API limits are quite low for IG, and the error message is telling you that you have exceeded your limit.

Try to raise this setting in application.properties (same directory as the igzplugin.log)

Change
plugin.refreshMarketDataInterval=30000
to a higher value, like 45000, 60000, or even 70000.

This will reduce the number of requests per minute.

You could probably extend the quotas, but you would have to contact IG support for that, and I'm not sure it would be free anymore.

Re: IG plugin initial release [Re: Dalla] #466131
05/26/17 12:15
05/26/17 12:15
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
I have release v0.13 of the plugin. Some of the errors related to not finding order confirmations should be gone now.

Re: IG plugin initial release [Re: Dalla] #466143
05/26/17 21:45
05/26/17 21:45
Joined: Mar 2017
Posts: 48
Bologna
K
kmerlo Offline
Newbie
kmerlo  Offline
Newbie
K

Joined: Mar 2017
Posts: 48
Bologna
I Daniel
in your site "https://github.com/dan-lind/igzplugin/releases" I find only the source code file
The last time you made the executable file too
Are you planning to put the executable file also this time ?
If not, now how I can to compile the source code?

Thanks

Bye

R

Last edited by kmerlo; 05/26/17 21:53.
Re: IG plugin initial release [Re: kmerlo] #466144
05/27/17 04:50
05/27/17 04:50
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
There was a problem with the uoload apparently. The zip-file is there now.

I suspect though that you might still have issues with Z12?
Let me know how it goes.

Re: IG plugin initial release [Re: Dalla] #466168
05/28/17 18:00
05/28/17 18:00
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
One thing to try if you still get {"errorCode":"error.public-api.exceeded-api-key-allowance"} when starting Z12 (or other systems for that matter).

Try setting
Preload = 1 for the Z-system.
Explained how here under "Setup & Trading":
http://www.zorro-trader.com/manual/en/zsystems.htm

Re: IG plugin initial release [Re: Dalla] #466175
05/29/17 08:16
05/29/17 08:16
Joined: Mar 2017
Posts: 48
Bologna
K
kmerlo Offline
Newbie
kmerlo  Offline
Newbie
K

Joined: Mar 2017
Posts: 48
Bologna
Hi Daniel
I still have problems
Here the log for z7

NB
I am using zorro 1.58

Attached Files
debug.zip (279 downloads)
Re: IG plugin initial release [Re: kmerlo] #466183
05/29/17 19:08
05/29/17 19:08
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
Hi,

Are you running multiple strategies in parallell with Z7?
There are two errors here:
error.public-api.exceeded-account-historical-data-allowance
and
error.public-api.exceeded-api-key-allowance

The first is saying that you are trying to download more ticks than you are allowed each week (default 10000 per week).

The second is same as before, too many API calls during 1 minute.
Since this shows up directly when you start this strategy, it must mean you have something else running that is already consuming your API quota.

Re: IG plugin initial release [Re: Dalla] #466261
06/04/17 14:40
06/04/17 14:40
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
Another release has been published, small fix for timing issues when confirming orders.

@kmerlo, still issues running Z systems?

Re: IG plugin initial release [Re: Dalla] #466265
06/04/17 19:23
06/04/17 19:23
Joined: Mar 2017
Posts: 48
Bologna
K
kmerlo Offline
Newbie
kmerlo  Offline
Newbie
K

Joined: Mar 2017
Posts: 48
Bologna
Hi Daniel
no I had some issues with my VPN server after to be installed zorro 1.58
I could not fix it because this week I'am in holiday and here I haven't wire line internet.
In the next days I will try the new release

PS
It is very strange that last time I had consumed my API quota because for one week I had not use the IGplugin but only the MT4plugin... :-(

Last edited by kmerlo; 06/04/17 19:23.
Re: IG plugin initial release [Re: kmerlo] #466292
06/06/17 10:21
06/06/17 10:21
Joined: Aug 2016
Posts: 27
M
MaskOfZorro Offline
Newbie
MaskOfZorro  Offline
Newbie
M

Joined: Aug 2016
Posts: 27
Hi. I've trying to trade Sprint markets. Previously I've been doign this via the MT4 bridge by making requests to the IG API through there. Problem is, I need to trade using bars of 15s and 30s, and can't do this via the MT4 bridge. So I was thinking of grabbing the bars via another bridge, say FXCM, and then just makign the http requests from within Zorro. But I've had no luck with getting POST to work to login to IG yet.

Any ideas on how to accomplish this? (I doubt the data allowances from the IG API are sufficient).

Last edited by MaskOfZorro; 06/06/17 10:22.
Re: IG plugin initial release [Re: MaskOfZorro] #466298
06/06/17 19:53
06/06/17 19:53
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
Hi

I'll help if I can of course, however I'd like to keep this thread as a discussion for the plugin only. Please PM me or start a new thread, and I'll try to answer there.

Regards
Daniel

Re: IG plugin initial release [Re: MaskOfZorro] #466324
06/08/17 15:39
06/08/17 15:39
Joined: Oct 2013
Posts: 15
New York
Jason_Rogers Offline
Newbie
Jason_Rogers  Offline
Newbie

Joined: Oct 2013
Posts: 15
New York
Originally Posted By: MaskOfZorro
Hi. I've trying to trade Sprint markets. Previously I've been doign this via the MT4 bridge by making requests to the IG API through there. Problem is, I need to trade using bars of 15s and 30s, and can't do this via the MT4 bridge. So I was thinking of grabbing the bars via another bridge, say FXCM, and then just makign the http requests from within Zorro. But I've had no luck with getting POST to work to login to IG yet.

Any ideas on how to accomplish this? (I doubt the data allowances from the IG API are sufficient).


Hi MaskofZorro,

You can download up to 10 years of free data using FXCM's Basic Historical Data Downloader https://www.fxcmapps.com/apps/basic-historical-data-downloader/ . Hope it helps with what you're looking for.

Jason

Last edited by Jason_Rogers; 06/08/17 15:39.
Re: IG plugin initial release [Re: Jason_Rogers] #466376
06/12/17 09:09
06/12/17 09:09
Joined: Mar 2017
Posts: 48
Bologna
K
kmerlo Offline
Newbie
kmerlo  Offline
Newbie
K

Joined: Mar 2017
Posts: 48
Bologna
Hi Daniel

unlucky I still have issues running Z systems
I use zorro 1.58 and the new igplugin

I tested z7
Zorro stalled (goes in freeze) :-(

Attached Files
igzplugin.zip (287 downloads)
Re: IG plugin initial release [Re: kmerlo] #466377
06/12/17 09:22
06/12/17 09:22
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
It looks to me like you are not running the latest plugin, can you please double check and also make sure you restarted Zorro after updating the plugin?
These errors
404 Not Found
happened frequently in an earlier version of the plugin.

You mentioned Zorro stalled, did this happen during the weekend?
This has happened to me too.
Try setting Weekend = 7 in the Z.ini file

Re: IG plugin initial release [Re: Dalla] #466382
06/12/17 12:55
06/12/17 12:55
Joined: Mar 2017
Posts: 48
Bologna
K
kmerlo Offline
Newbie
kmerlo  Offline
Newbie
K

Joined: Mar 2017
Posts: 48
Bologna
yeh during the week end
Ok I will retry with : Weekend = 7 in the Z.ini

Re: IG plugin initial release [Re: kmerlo] #466383
06/12/17 13:38
06/12/17 13:38
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
I saw also that there seems to be issues with some of the orders, most likely related to a rounding error. Will try to look into that during the week.

Re: IG plugin initial release [Re: Dalla] #466407
06/13/17 08:00
06/13/17 08:00
Joined: Mar 2017
Posts: 48
Bologna
K
kmerlo Offline
Newbie
kmerlo  Offline
Newbie
K

Joined: Mar 2017
Posts: 48
Bologna
Hi Daniel
Zorro this morning was blocked
I closed it now
I will use MT4 Bridge for understanding if the problem is IG's Plugin o some configuration in my VPN server...

Re: IG plugin initial release [Re: kmerlo] #466408
06/13/17 08:25
06/13/17 08:25
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
I'm currently running Z7 on an EC2 instance, will check if this happens to me as well.

Re: IG plugin initial release [Re: Dalla] #466563
06/21/17 08:47
06/21/17 08:47
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
A new version of the IG plugin has been release.
Most importantly this release fixes an issue where Zorro would sometimes block/freeze after not getting any return values from the plugin

https://github.com/dan-lind/igzplugin/releases/tag/v0.2

Re: IG plugin initial release [Re: Dalla] #466565
06/21/17 13:26
06/21/17 13:26
Joined: Feb 2017
Posts: 9
D
dhrv Offline
Newbie
dhrv  Offline
Newbie
D

Joined: Feb 2017
Posts: 9
Thanks for your efforts in creating this plugin Daniel! I have not tested it deeply yet and also just on a demo account, but the basic functions from the TradeTest script work nicely (almost, see below*).
It's quite unfortunate that IG limits the non-trading requests to 30 per minute/account. With this limit I can only update 8 assets (e.g. with the Download script, saving all assets to AssetsNew.csv) before hitting the limit. I've asked for an increased limit, let's see if they comply with my request.

* When opening a position on a currency pair with Hedge=4, Zorro freezes. Other symbols work fine, see the logs below:

EUR/USD Mini, Hedge=4, Buy Long from TradeTest.c --> freeze
Code:
2017-06-21 14:56:57.113 [main] INFO  com.danlind.igz.brokerapi.BrokerBuy - >>> Creating long position epic=CS.D.EURUSD.MINI.IP, 
direction=BUY, 
expiry=-, 
size=1.0, 
orderType=MARKET, 
currency=USD, 
stop loss distance=0.5017
2017-06-21 15:17:58.759 [RxComputationThreadPool-3] WARN  c.danlind.igz.adapter.RestApiAdapter - Order with deal id DIAAAABCHXQZ5AX was rejected with reason code ATTACHED_ORDER_LEVEL_ERROR



Germany 30 Cash 1-EUR, Hedge=4, Buy Long from TradeTest.c --> works
Code:
2017-06-21 15:20:43.330 [main] INFO  com.danlind.igz.brokerapi.BrokerBuy - >>> Creating long position epic=IX.D.DAX.IFMM.IP, 
direction=BUY, 
expiry=-, 
size=1.0, 
orderType=MARKET, 
currency=EUR, 
stop loss distance=5748.0


Re: IG plugin initial release [Re: dhrv] #466568
06/21/17 14:46
06/21/17 14:46
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
I assume you downloaded the latest version? :-)

It should not freeze of course, but your issue is that the API is complaining about your stop loss. Unfortunately the documentation of the API is not very helpful here, but your stop loss looks very big (0.5 will translate to 5000 pips). Does it work if you make it smaller?

Re: IG plugin initial release [Re: Dalla] #466570
06/21/17 15:40
06/21/17 15:40
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
Actually, I can't reproduce this with the latest version. Make sure you have the latest release, and restart Zorro after installing it.

Re: IG plugin initial release [Re: Dalla] #466581
06/22/17 07:35
06/22/17 07:35
Joined: Mar 2017
Posts: 48
Bologna
K
kmerlo Offline
Newbie
kmerlo  Offline
Newbie
K

Joined: Mar 2017
Posts: 48
Bologna
Hello Dalla,
thanks for your work
I have a doubt, when there is a new release of the plugin I have to replace all file or only ig.dll ?

I've decided to change the way you test the plugin, not using z script but with my script or the script tutorial's

I will keep you updated when I will have some results

Have a a good time

Re: IG plugin initial release [Re: kmerlo] #466582
06/22/17 07:46
06/22/17 07:46
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
Most important is to replace the ig.dll and the igplugin-x.x.jar .
And to restart Zorro to reload the new plugin.
Sometimes there can also be new entries in the application.properties, but I'll make sure to mention that specifically in the release notes going forward.

Last edited by Dalla; 06/22/17 07:47.
Re: IG plugin initial release [Re: Dalla] #466596
06/22/17 12:06
06/22/17 12:06
Joined: Feb 2017
Posts: 9
D
dhrv Offline
Newbie
dhrv  Offline
Newbie
D

Joined: Feb 2017
Posts: 9
Originally Posted By: Dalla
Actually, I can't reproduce this with the latest version. Make sure you have the latest release, and restart Zorro after installing it.


My bad, I checked for a new version yesterday in the morning and didn't read or see your post (had the forum tab opened since morning). It works fine now, no more freeze and the position is opened laugh

Re: IG plugin initial release [Re: dhrv] #466597
06/22/17 12:33
06/22/17 12:33
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
Good to know, this release was pretty much supposed to fix the exact issue you described. You got me worried there for a second ;-)

Re: IG plugin initial release [Re: Dalla] #466991
07/11/17 15:03
07/11/17 15:03
Joined: Jul 2016
Posts: 93
Düsseldorf, Germany
M
mhdus Offline
Junior Member
mhdus  Offline
Junior Member
M

Joined: Jul 2016
Posts: 93
Düsseldorf, Germany
Hi,
I followed the instructions and could successfully connect via the IG bridge. I did also successfully open and close a trade using the Zorro TradeTest script. I'm using the latest Zorro Beta 1.59.91 and the version of the IG plugin included there.
I'm just wondering why I'm constantly getting the message "!Multiple accounts are not yet supported!" in the Zorro message window? And my real account equity is not shown, it just shows 0. Maybe a related issue?
Assuming the error relates to the fact that I do have 3 live accounts with IG: the default CFD Trading account, a CFD MetaTrader account (so far used for trading with Zorro and the MT bridge) and a stocks trading account. I had to set up the MT account manually, the other 2 were automatically set up after registering with IG (in Germany). According to the logs the plugin is connecting to the intended account (the default CFD Trading account which is funded).
Can I just ignore the error message? Any chance to have the account equity shown correctly? I could not find anything related in the log, not even at debug level...

Re: IG plugin initial release [Re: mhdus] #466998
07/11/17 20:57
07/11/17 20:57
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
Hi,

The equity not showing is definitely related to the error message you are seeing. However I have no idea what causes it... I also have 3 live accounts with IG, Two for CFD (SEK & EUR) and an MT4 account. I have never seen this error message. It has to be some Zorro configuration I think. I'll try to get an answer from Zorro support and get back with an answer.

/Daniel

Re: IG plugin initial release [Re: Dalla] #467013
07/12/17 10:47
07/12/17 10:47
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
Hi,

I've released a new version which should fix this issue.
https://github.com/dan-lind/igzplugin/releases/tag/v0.15

Can you please download and see if this helps?
Instructions on how to install can be found here:
https://github.com/dan-lind/igzplugin

Re: IG plugin initial release [Re: Dalla] #467030
07/12/17 21:58
07/12/17 21:58
Joined: Jul 2016
Posts: 93
Düsseldorf, Germany
M
mhdus Offline
Junior Member
mhdus  Offline
Junior Member
M

Joined: Jul 2016
Posts: 93
Düsseldorf, Germany
Hi Daniel,
my apologies, I had no time to check back here until now - many thanks for your fast response and the fix! I will test it tomorrow during the day and let you know...
Thanks again,
Markus

Re: IG plugin initial release [Re: mhdus] #467038
07/13/17 08:23
07/13/17 08:23
Joined: Jul 2016
Posts: 93
Düsseldorf, Germany
M
mhdus Offline
Junior Member
mhdus  Offline
Junior Member
M

Joined: Jul 2016
Posts: 93
Düsseldorf, Germany
Hi Daniel,
just installed and tested: both problems fixed, no more error messages and the account equity is also shown correctly, great!
Many thanks
Markus

Re: IG plugin initial release [Re: mhdus] #467046
07/13/17 11:41
07/13/17 11:41
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
Great to hear!

Daniel

Re: IG plugin initial release [Re: Dalla] #467063
07/14/17 08:23
07/14/17 08:23
Joined: Jul 2016
Posts: 93
Düsseldorf, Germany
M
mhdus Offline
Junior Member
mhdus  Offline
Junior Member
M

Joined: Jul 2016
Posts: 93
Düsseldorf, Germany
I tried to run a Z system (tried Z12 and Z7) via the IG Plugin but quickly ran into the quota exceeded for historical data problem ... I guess it happened because I forgot to set Preload = 1 in Z.ini :-(
IG were so kind to reset the quota once but now I'd like to be 100% sure not to run into the same issue again.
So has anyone managed to successfully run one or more of the Z strategies via the IG Plugin and could provide some hints how to make sure there is no issue with the IG API quotas?
(By the way, enhancement idea for the IG plugin: add a configurable threshold for historical data requests per strategy launch...)
Many thanks in advance.

Re: IG plugin initial release [Re: mhdus] #467064
07/14/17 08:28
07/14/17 08:28
Joined: Jul 2016
Posts: 93
Düsseldorf, Germany
M
mhdus Offline
Junior Member
mhdus  Offline
Junior Member
M

Joined: Jul 2016
Posts: 93
Düsseldorf, Germany
Additional comment: it seems as if one can set up several API keys per IG account (one per "application") and the quota may be applied per key. I had tried again with a fresh key and Preload = 1 in Z.ini but still ran into the problem (not sure if that just happened because the quota was already exceeded by the first key, though).

Re: IG plugin initial release [Re: mhdus] #467074
07/14/17 15:07
07/14/17 15:07
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
Hi

This is unfortunately the biggest issue with the IG API.
Like mentioned in the installation instructions, the best way to avoid these kind of issues is to keep your historical data up to date, and use the PRELOAD flag.

I currently tend to download historical data from FXCM/Oanda before starting strategies. I know this is not optimal, but doing so will avoid the problems you are describing.
Doing this allowes me to start both Z12 and Z7.

Adding a threshold for data download would not really help; Zorro expects to get the data it is asking for, and if the plugin doesn't provide, it won't start the strategy.

Using multiple API keys might help for number of requests, but as far as I understand it will not increase the 10000 data point limit for historical data.

Re: IG plugin initial release [Re: Dalla] #467079
07/14/17 21:17
07/14/17 21:17
Joined: Jul 2016
Posts: 93
Düsseldorf, Germany
M
mhdus Offline
Junior Member
mhdus  Offline
Junior Member
M

Joined: Jul 2016
Posts: 93
Düsseldorf, Germany
A threshold would still help as it is much better to see a strategy not starting (and a message such as "warning: attempting to load too much historical data, check your local data and configuration") than just exceeding the quota limits and having to wait for one week before trying again... Ok, maybe not the highest-priority enhancement but not useless either. In fact the API should be doing that.
Anyway, I will try updating my local data from other sources and then give it another shot.

Re: IG plugin initial release [Re: mhdus] #467108
07/16/17 08:52
07/16/17 08:52
Joined: Mar 2017
Posts: 48
Bologna
K
kmerlo Offline
Newbie
kmerlo  Offline
Newbie
K

Joined: Mar 2017
Posts: 48
Bologna
I agree with this suggestion
Even myself once for error I finished the ig's quote..

PS for DALLA
in the next days I'll try the new release and I'll post the feedback
Thanks for all!


Originally Posted By: mhdus
A threshold would still help as it is much better to see a strategy not starting (and a message such as "warning: attempting to load too much historical data, check your local data and configuration") than just exceeding the quota limits and having to wait for one week before trying again... Ok, maybe not the highest-priority enhancement but not useless either. In fact the API should be doing that.
Anyway, I will try updating my local data from other sources and then give it another shot.

Re: IG plugin initial release [Re: kmerlo] #467112
07/16/17 14:07
07/16/17 14:07
Joined: Jul 2016
Posts: 93
Düsseldorf, Germany
M
mhdus Offline
Junior Member
mhdus  Offline
Junior Member
M

Joined: Jul 2016
Posts: 93
Düsseldorf, Germany
I updated all my history files via FXCM and tried starting Z7 and Z12 using the IG plugin. Deliberately on Sunday to be sure I am not missing any latest price data. I did also check the _2017.t6 files for completeness using ZHistoryEditor. As expected, data is included up to last Friday night and no gaps except the week-ends.

Z7 started without errors with the following Zorro messages:

Z7 .x ..
ig.dll => IG plugin mounted
Z7.55: PH PR M 100 H 5 W 2 V 2 .
Login IG.. at UTC 07-16 13:16.
Load EUR/USD prices.. 680+33 h, gap 41 h
Load USD/JPY prices.. 680+33 h, gap 41 h
Load GBP/USD prices.. 680+33 h, gap 41 h

Trade: Z7 2017-07-16
Lookback period (480 bars) .
Read Z7.c

I understand "gap 41h" is due to the weekend gap, so no issue. However, I don't understand where the +33h is coming from? 3 x 33h x 60 min/h = 5940 historical bars consumed ... :-(

Hoping IG will reset the quota at the beginning of the calendar week I tried starting Z12, too:

Z12
Login IG... at UTC 07-16 13:17
Z12.54: PH PR M 100 H 5 W 2 V 2
Load EUR/USD prices.. 2800+211 h, gap 41 h
Load USD/CHF prices.. 2800+211 h, gap 41 h
!Severe error occured, check igzplugin.log logfile!
!Severe error occured, check igzplugin.log logfile!
Error 053: CX.D.GBPUSD.CASH.IP unavailable at this time
!Severe error occured, check igzplugin.log logfile!

[...]

!Severe error occured, check igzplugin.log logfile!
Error 053: CX.D.XAGUSD.CASH.IP unavailable at this time
V 1.600 on Sun 17-07-16 15:17:06 (Zorro S subscription)

Trade: Z12 2017-07-16
Read Z12.fac
Read Z12.par
Lookback period (500 bars)
[184: Thu 17-03-16 16:09] 1.0722/1.07441.0713/1.0736
Error 033: GBP/USD missing in INITRUN
Error 011: Function ATR called with invalid parameters (no price)
Error 011: Function BBANDS called with invalid parameters (no price).
[185: Thu 17-03-16 20:09] 1.0736/1.07711.0708/1.0768

Of course, the igzplugin log shows:
ERROR c.danlind.igz.adapter.RestApiAdapter - Exception when getting historic prices for epic CX.D.GBPUSD.CASH.IP, error was {"errorCode":"error.public-api.exceeded-api-key-allowance"

Again, I wonder where the +211h is coming from? The data files were up-to-date ...

Obviously PRELOAD was set and recognized. So what else was wrong?
Any help much appreciated. Many thanks in advance!

Re: IG plugin initial release [Re: mhdus] #467114
07/16/17 20:03
07/16/17 20:03
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
From the manual

"Loading AUD/USD prices... 910+111 h

The PRELOAD flag was set and historic price data was available. Zorro read 910 hours price data from its history files and downloaded additional 111 hours price history from the broker's server. For portfolio strategies the number of downloaded hours can differ from asset to asset."

These messages however are generated by Zorro. You say that your files are up to date, but it looks like zorro disagrees. Also, are you running with BarPeriod 1? If not, then the historical bars consumed is probably not as bad as you think.

Re: IG plugin initial release [Re: Dalla] #467117
07/16/17 21:15
07/16/17 21:15
Joined: Jul 2016
Posts: 93
Düsseldorf, Germany
M
mhdus Offline
Junior Member
mhdus  Offline
Junior Member
M

Joined: Jul 2016
Posts: 93
Düsseldorf, Germany
I had seen this in the manual. And I understand your conclusion "zorro disagrees". However, it does not fit my previous checks of the data. Eventually the handling of (no) data during the week-end is not as I would expect (see the messages in the log below regarding EUR/USD data for this week-end).

Thanks for the hint regarding BarPeriod - indeed there should be much less bars consumed (hourly bars for Z7, 4h bars for Z12). Which even more confuses my why the quota is exceeded so quickly... Is it possible to debug what (amount of) data is requested from the API by the IG plugin?

What I realized later, after my previous post: the additional hours of data loaded are different, depending on which broker/plugin is used. Here are 2 logs from Z7 start (using Verbose = 3), first FXCM then IG immediately after:

Z7
Login FXCM.. at UTC 07-16 20:33
Z7.55: PH PR M 100 H 5 W 3 V 3
Load AssetsFix
!EUR/USD 07-14 21:13:00 to 07-16 20:33:42 failed
Preload EUR/USD 40800 min, gap 48 h
663 Bars 2017-06-06..2017-07-14 generated
EUR/USD: 0..49565, 2017-06-06..1899-12-30
Preload USD/JPY 40800 min, gap 48 h
USD/JPY: 0..49565, 2017-06-06..1899-12-30
Preload GBP/USD 40800 min, gap 48 h
GBP/USD: 0..49565, 2017-06-06..1899-12-30
V 1.600 on Sun 17-07-16 22:33:49 (Zorro S subscription)

Trade: Z7 2017-07-16
Lookback period (480 bars)
[182: Fri 17-06-16 08:03] 1.1155/1.11691.1152/1.1169

[...]

Session end at 20:33
Logout.. ok



Z7
Login IG... at UTC 07-16 20:34
Z7.55: PH PR M 100 H 5 W 3 V 3
Load AssetsIG
!CX.D.EURUSD.CASH.IP 07-14 21:13:00 to 07-16 20:34:34
!=> 07-13 18:45:00 to 20:30:00, 108 ticks
Load EUR/USD prices.. 680+27 h
663 Bars 2017-06-06..2017-07-14 generated
EUR/USD: 0..49673, 2017-06-06..1899-12-30
Load USD/JPY prices.. 680+26 h
USD/JPY: 0..49673, 2017-06-06..1899-12-30
Load GBP/USD prices.. 680+26 h
GBP/USD: 0..49673, 2017-06-06..1899-12-30
V 1.600 on Sun 17-07-16 22:34:36 (Zorro S subscription)

Trade: Z7 2017-07-16
Lookback period (480 bars)
[182: Fri 17-06-16 08:02] 1.1156/1.11681.1152/1.1168

[...]

Session end at 20:34
Logout.. ok


Based on the above message "07-13 18:45:00 to 20:30:00, 108 ticks" from the IG plugin I checked my local EURUSD_2017.t6 file once again: the data during this timeframe is included! So I wonder what the plugin was doing about these 108 ticks and why?

I just did the same test with Z12 now after 11PM (week-end is over) and have the same effect: with FXCM Zorro reports 2800 +1h for all prices, with IG it reports 2800 +205h for the first 5 price series, then the quota exceeded issue kicks in again:

2017-07-16 23:06:03.601 [main] INFO com.danlind.igz.handler.AssetHandler - Subscribing to Lightstreamer tick updates for market: CX.D.EURUSD.CASH.IP
2017-07-16 23:06:03.604 [main] INFO com.danlind.igz.handler.AssetHandler - Subscribing to Lightstreamer volume updates for market: CX.D.EURUSD.CASH.IP
2017-07-16 23:06:04.419 [main] INFO com.danlind.igz.handler.AssetHandler - Subscribing to Lightstreamer tick updates for market: CX.D.USDCHF.CASH.IP
2017-07-16 23:06:04.435 [main] INFO com.danlind.igz.handler.AssetHandler - Subscribing to Lightstreamer volume updates for market: CX.D.USDCHF.CASH.IP
2017-07-16 23:06:05.346 [main] INFO com.danlind.igz.handler.AssetHandler - Subscribing to Lightstreamer tick updates for market: CX.D.GBPUSD.CASH.IP
2017-07-16 23:06:05.347 [main] INFO com.danlind.igz.handler.AssetHandler - Subscribing to Lightstreamer volume updates for market: CX.D.GBPUSD.CASH.IP
2017-07-16 23:06:06.139 [main] INFO com.danlind.igz.handler.AssetHandler - Subscribing to Lightstreamer tick updates for market: CX.D.USDCAD.CASH.IP
2017-07-16 23:06:06.140 [main] INFO com.danlind.igz.handler.AssetHandler - Subscribing to Lightstreamer volume updates for market: CX.D.USDCAD.CASH.IP
2017-07-16 23:06:06.697 [main] INFO com.danlind.igz.handler.AssetHandler - Subscribing to Lightstreamer tick updates for market: CX.D.USDJPY.CASH.IP
2017-07-16 23:06:06.701 [main] INFO com.danlind.igz.handler.AssetHandler - Subscribing to Lightstreamer volume updates for market: CX.D.USDJPY.CASH.IP
2017-07-16 23:06:07.658 [main] INFO com.danlind.igz.handler.AssetHandler - Subscribing to Lightstreamer tick updates for market: CX.D.AUDUSD.CASH.IP
2017-07-16 23:06:07.659 [main] INFO com.danlind.igz.handler.AssetHandler - Subscribing to Lightstreamer volume updates for market: CX.D.AUDUSD.CASH.IP
2017-07-16 23:06:07.810 [main] ERROR c.danlind.igz.adapter.RestApiAdapter - Exception when getting broker account info: {"errorCode":"error.public-api.exceeded-api-key-allowance"}

Please let me know if there are any additional debugging options I should apply. The plugin could be really great but given the data limitations by IG debugging and eventually throttling data consumption appears to be a crucial prerequisite.

Re: IG plugin initial release [Re: mhdus] #467119
07/17/17 04:42
07/17/17 04:42
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
First thing first, just to make it clear.
The error you are seeing
errorCode":"error.public-api.exceeded-api-key-allowance"
Means that there has been too many calls in a too short time period. So your historical quota has not been consumed, when that happens the message is slightly different.

If you open the logback.xml (same directory as plugin log file) and change log level from info to debug for only for this line
<root level="info">

You should get some more info on exactly what data zorro is asking for.

Have you also made sure that you are indeed using the same assets for the IG plugin and FXCM? Could you please post your assets file for both?
The +1 vs +205 has nothing to do with the plugin as far as I know.

Re: IG plugin initial release [Re: Dalla] #467128
07/17/17 12:27
07/17/17 12:27
Joined: Jul 2016
Posts: 93
Düsseldorf, Germany
M
mhdus Offline
Junior Member
mhdus  Offline
Junior Member
M

Joined: Jul 2016
Posts: 93
Düsseldorf, Germany
Asset files are quite the same, except the Symbol names, of course:

AssetsFXCM.csv:
Name,Price,Spread,RollLong,RollShort,PIP,PIPCost,MarginCost,Leverage,LotAmount,Commission,Symbol
AUD/USD,0.77311,0.00005,0.2400,-0.5100,0.0001,0.087100,9.0000,74.820,1000.0,0.600,AUD/USD
EUR/CHF,1.07962,0.00004,0.0800,-0.2600,0.0001,0.092630,75.0000,13.334,1000.0,0.800,EUR/CHF
EUR/JPY,123.3590,0.00600,-0.3000,0.0900,0.0100,0.081066,10.0000,100.002,1000.0,0.800,EUR/JPY
EUR/USD,1.13795,0.00005,-0.0200,0.0100,0.0001,0.087100,10.0000,99.115,1000.0,0.600,EUR/USD
GBP/USD,1.51364,0.00003,0.0500,-0.1200,0.0001,0.087100,14.0000,94.170,1000.0,0.600,GBP/USD
GER30,10884.00,1.00000,-0.1000,0.0000,1.0000,0.100000,6.0000,181.400,0.1,0.000,GER30
NAS100,4185.00,2.0000,-0.1000,0.0000,1.0000,0.087100,2.0000,182.257,0.1,0.000,NAS100
NZD/USD,0.67752,0.00007,0.6000,-1.3200,0.0001,0.088713,7.0000,85.864,1000.0,0.800,NZD/USD
SPX500,2032.40,0.50000,-0.5000,0.0000,0.1000,0.087100,8.0000,221.278,1.0,0.000,SPX500
UK100,6869.00,2.0000,-0.1000,0.0000,1.0000,0.131830,6.0000,150.923,0.1,0.000,UK100
US30,17520.00,2.0000,-0.5000,0.0000,1.0000,0.087100,6.0000,254.332,0.1,0.000,US30
USD/CAD,1.24466,0.00010,-0.2100,0.0900,0.0001,0.069980,10.0000,87.101,1000.0,0.800,USD/CAD
USD/CHF,0.92203,0.00022,0.1500,-0.5800,0.0001,0.094460,50.0000,17.419,1000.0,0.600,USD/CHF
USD/JPY,117.4890,0.00400,0.0200,-0.0400,0.0100,0.074130,10.0000,87.095,1000.0,0.600,USD/JPY
XAG/USD,17.2350,0.04600,-0.0009,0.0000,0.0100,0.435470,5.0000,150.107,50.0,0.000,XAG/USD
XAU/USD,1260.82,0.47000,-0.0124,0.0000,0.0100,0.008710,11.0000,99.834,1.0,0.000,XAU/USD

AssetsIG.csv:
Name,Price,Spread,RollLong,RollShort,PIP,PIPCost,MarginCost,Leverage,LotAmount,Commission,Symbol
AUD/USD,0.77311,0.00005,0.24,-0.51,0.0001,0.0871,9,0,1000,0.6,CX.D.AUDUSD.CASH.IP
EUR/CHF,1.07962,0.00004,0.08,-0.26,0.0001,0.09263,75,0,1000,0.8,CX.D.EURCHF.CASH.IP
EUR/JPY,123.359,0.006,-0.3,0.09,0.01,0.081066,10,0,1000,0.8,CX.D.EURJPY.CASH.IP
EUR/USD,1.13795,0.00005,-0.02,0.01,0.0001,0.0871,10,0,1000,0.6,CX.D.EURUSD.CASH.IP
GBP/USD,1.51364,0.00003,0.05,-0.12,0.0001,0.0871,14,0,1000,0.6,CX.D.GBPUSD.CASH.IP
GER30,10884,1,-0.1,0,1,0.1,6,0,0.1,0,IX.D.DAX.IFD.IP
NAS100,4185,2,-0.1,0,1,0.0871,2,0,0.1,0,IX.D.NASDAQ.IFD.IP
NZD/USD,0.67752,0.00007,0.6,-1.32,0.0001,0.088713,7,0,1000,0.8,CX.D.NZDUSD.CASH.IP
SPX500,2032.4,0.5,-0.5,0,0.1,0.0871,8,0,1,0,IX.D.SPTRD.IFD.IP
UK100,6869,2,-0.1,0,1,0.13183,6,0,0.1,0,IX.D.FTSE.CFD.IP
US30,17520,2,-0.5,0,1,0.0871,6,0,0.1,0,IX.D.DOW.IFD.IP
USD/CAD,1.24466,0.0001,-0.21,0.09,0.0001,0.06998,10,0,1000,0.8,CX.D.USDCAD.CASH.IP
USD/CHF,0.92203,0.00022,0.15,-0.58,0.0001,0.09446,50,0,1000,0.6,CX.D.USDCHF.CASH.IP
USD/JPY,117.489,0.004,0.02,-0.04,0.01,0.07413,10,0,1000,0.6,CX.D.USDJPY.CASH.IP
XAG/USD,17.235,0.046,-0.0009,0,0.01,0.43547,5,0,50,0,CX.D.XAGUSD.CASH.IP
XAU/USD,1260.82,0.47,-0.0124,0,0.01,0.00871,11,0,1,0,CX.D.XAUUSD.CASH.IP


Thanks for the hint on "error.public-api.exceeded-api-key-allowance" vs. "error.public-api.exceeded-account-historical-data-allowance" (the latter I finally got just now after some more testing, unfortunately. So no more testing for one week). At least this confirms that the historical data consumption is not the main issue and the slight differences in the messages reported by Zorro about historical data were just distracting...

So what about this API limit (https://labs.ig.com/faq) then:
Per-account non-trading requests per minute: 30

Here is what I got while starting Z12 without any previous testing for (a lot) more than one minute:

2017-07-17 13:56:32.965 [main] INFO c.danlind.igz.brokerapi.BrokerLogin - Connecting to IG Real-account as xxxxxx
2017-07-17 13:56:34.630 [main] INFO com.danlind.igz.ZorroBridge - Login successful
2017-07-17 13:56:34.630 [main] INFO com.danlind.igz.brokerapi.BrokerTime - Subscribing to Lightstreamer heartbeat
2017-07-17 13:56:34.633 [main] INFO com.danlind.igz.handler.AssetHandler - Subscribing to Lightstreamer account updates for account: XXXXX
2017-07-17 13:56:34.778 [main] INFO com.danlind.igz.brokerapi.BrokerTime - Getting initial time from restAPI
2017-07-17 13:56:34.850 [main] INFO com.danlind.igz.handler.AssetHandler - Subscribing to Lightstreamer tick updates for market: CX.D.EURUSD.CASH.IP
2017-07-17 13:56:34.852 [main] INFO com.danlind.igz.handler.AssetHandler - Subscribing to Lightstreamer volume updates for market: CX.D.EURUSD.CASH.IP
2017-07-17 13:56:35.571 [main] INFO com.danlind.igz.handler.AssetHandler - Subscribing to Lightstreamer tick updates for market: CX.D.USDCHF.CASH.IP
2017-07-17 13:56:35.572 [main] INFO com.danlind.igz.handler.AssetHandler - Subscribing to Lightstreamer volume updates for market: CX.D.USDCHF.CASH.IP
2017-07-17 13:56:37.001 [main] INFO com.danlind.igz.handler.AssetHandler - Subscribing to Lightstreamer tick updates for market: CX.D.GBPUSD.CASH.IP
2017-07-17 13:56:37.002 [main] INFO com.danlind.igz.handler.AssetHandler - Subscribing to Lightstreamer volume updates for market: CX.D.GBPUSD.CASH.IP
2017-07-17 13:56:37.641 [main] INFO com.danlind.igz.handler.AssetHandler - Subscribing to Lightstreamer tick updates for market: CX.D.USDCAD.CASH.IP
2017-07-17 13:56:37.707 [main] INFO com.danlind.igz.handler.AssetHandler - Subscribing to Lightstreamer volume updates for market: CX.D.USDCAD.CASH.IP
2017-07-17 13:56:38.415 [main] INFO com.danlind.igz.handler.AssetHandler - Subscribing to Lightstreamer tick updates for market: CX.D.USDJPY.CASH.IP
2017-07-17 13:56:38.419 [main] INFO com.danlind.igz.handler.AssetHandler - Subscribing to Lightstreamer volume updates for market: CX.D.USDJPY.CASH.IP
2017-07-17 13:56:38.943 [main] INFO com.danlind.igz.handler.AssetHandler - Subscribing to Lightstreamer tick updates for market: CX.D.AUDUSD.CASH.IP
2017-07-17 13:56:38.944 [main] INFO com.danlind.igz.handler.AssetHandler - Subscribing to Lightstreamer volume updates for market: CX.D.AUDUSD.CASH.IP
2017-07-17 13:56:39.668 [main] INFO com.danlind.igz.handler.AssetHandler - Subscribing to Lightstreamer tick updates for market: IX.D.NASDAQ.IFD.IP
2017-07-17 13:56:39.670 [main] INFO com.danlind.igz.handler.AssetHandler - Subscribing to Lightstreamer volume updates for market: IX.D.NASDAQ.IFD.IP
2017-07-17 13:56:40.657 [main] INFO com.danlind.igz.handler.AssetHandler - Subscribing to Lightstreamer tick updates for market: IX.D.SPTRD.IFD.IP
2017-07-17 13:56:40.658 [main] INFO com.danlind.igz.handler.AssetHandler - Subscribing to Lightstreamer volume updates for market: IX.D.SPTRD.IFD.IP
2017-07-17 13:56:41.183 [main] INFO com.danlind.igz.handler.AssetHandler - Subscribing to Lightstreamer tick updates for market: IX.D.DOW.IFD.IP
2017-07-17 13:56:41.184 [main] INFO com.danlind.igz.handler.AssetHandler - Subscribing to Lightstreamer volume updates for market: IX.D.DOW.IFD.IP
2017-07-17 13:56:41.314 [main] ERROR c.danlind.igz.adapter.RestApiAdapter - Exception when getting historic prices for epic IX.D.DOW.IFD.IP, error was {"errorCode":"error.public-api.exceeded-api-key-allowance"}
org.springframework.web.client.HttpClientErrorException: 403 Forbidden

(I switched back from DEBUG to INFO for the above log as debug is extremely verbose)

I wonder if each of these subscription requests (I'm counting 19 or 20 of these before the error) is just one restAPI request or if there are a few more behind the scenes? If so, the 30 per minute limit could be hit. I guess this could only be avoided by active request pacing by the plugin.

Re: IG plugin initial release [Re: mhdus] #467136
07/17/17 19:57
07/17/17 19:57
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
I realize that I had a discussion with IG support some time ago when I had a similar issue. Basically their logs were saying that I was hitting the application limit of 60 requests per second even though I was nowhere near that rate.

I suggest you contact IG support just to see if you are running into that same issue. Provide them with the api key you are using, date, time and time zone when you hit the limit.
If it helps, the guy who helped was named Matt Bailey

Re: IG plugin initial release [Re: Dalla] #467146
07/18/17 07:54
07/18/17 07:54
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
BTW, if you want to count the exact number of requests being made, you should be able to do that with the DEBUG setting. There are a couple of other besides the ones that your are seeing (starting account subscription, getting account time zone, the actual login etc), but since you are not close to 60 this should not be the issue.

In my conversation with IG I actually mentioned the Per-account non-trading requests per minute: 30, but Matt was positive that this was not the limit I was hitting according to the logs.

Re: IG plugin initial release [Re: Dalla] #467147
07/18/17 08:15
07/18/17 08:15
Joined: Jul 2016
Posts: 93
Düsseldorf, Germany
M
mhdus Offline
Junior Member
mhdus  Offline
Junior Member
M

Joined: Jul 2016
Posts: 93
Düsseldorf, Germany
Ok, then this may well explain the issue. Even based on the INFO messages I'm counting 28 requests (2x13 for the instruments +2 for account and heartbeat). So if there are a few more the 30 per minute is reached. I don't think they put this in the FAQ and don't enforce it. Maybe they relaxed the limit for you individually as you are developing a plugin that has good potential to boost their client base?
I am in contact with IG support, let's see what they respond...

Re: IG plugin initial release [Re: mhdus] #467149
07/18/17 09:41
07/18/17 09:41
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
That sounds familiar also. I was close to 30, but not really at 30 when counting the requests.

Basically support said that my application API limit was also set to 30 rather than 60 for some reason. So they increased it to 60, and after that I've not had any problems.

To be honest I find the FAQ a bit confusing on the limits, specifically
Per-app non-trading requests per minute: 60
Per-account non-trading requests per minute: 30

To me it seems like the per-account limit of 30 would always be hit before the per-app limit, since all app keys belongs to an account.
I've sent a mail to support asking them to clarify this as well, I'll post back here when I get an answer.

Re: IG plugin initial release [Re: Dalla] #467273
07/24/17 13:49
07/24/17 13:49
Joined: Jul 2016
Posts: 93
Düsseldorf, Germany
M
mhdus Offline
Junior Member
mhdus  Offline
Junior Member
M

Joined: Jul 2016
Posts: 93
Düsseldorf, Germany
No feedback from the API experts at IG yet, despite several reminders to the helpdesk front line ...

Re: IG plugin initial release [Re: mhdus] #467280
07/24/17 18:07
07/24/17 18:07
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
That's weird. Vacation times? I've never had to wait more than a couple of days for answer from support, and that was true before I made this plugin as well

Re: IG plugin initial release [Re: mhdus] #467281
07/24/17 18:13
07/24/17 18:13
Joined: Feb 2017
Posts: 9
D
dhrv Offline
Newbie
dhrv  Offline
Newbie
D

Joined: Feb 2017
Posts: 9
For me, updating the Assets file (Download script -> "Save Assets to") triggers the limit at my IG account (the current limit is "Per-account non-trading requests per minute: 30"). The limit is triggered after the 12th asset in the list (it used to be after the 8th asset one month ago with previous versions of Zorro and the IG plugin). When I asked the Dev support for a limit raise, their response was:

Quote:
Thanks for your email. Unfortunately we access increasing REST API limits on a case by case basis. What we have noticed is that you are trying to access quite a few Forex pairs at a point in time hence why you hit you limit easily, what we suggest is that possibly instead of using REST API try using Streaming API, because it is based on real time data.

Since you're already using the Lightstreamer lib, is there a way to prevent reaching the limit, e.g. by queuing the requests or using this trick?

Re: IG plugin initial release [Re: dhrv] #467282
07/24/17 19:20
07/24/17 19:20
Joined: Jul 2016
Posts: 93
Düsseldorf, Germany
M
mhdus Offline
Junior Member
mhdus  Offline
Junior Member
M

Joined: Jul 2016
Posts: 93
Düsseldorf, Germany
I'm getting quick answers to each request but only from first line support: "I will follow up with the developers again to get a response from the as quickly as possible."...

Anyway, since these limits appear to be a showstopper for the plugin so far, could you consider dhrv's suggestion?

Re: IG plugin initial release [Re: mhdus] #467293
07/25/17 07:55
07/25/17 07:55
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
Hi,

Using the download script, if you really need to download many assets, you should download one at a time rather than all at once. As mentioned in the installation notes, using IG to download lots of historical data is not a good idea.

I've also asked support about the limits for the rest api. All requests that require an api key (which is all requests made by the plugin) counts towards the application limit of 60. So rather than asking them to just raise your limit, ask why you are getting rate limited after 30 requests rather than 60.

I'm not sure rate limiting the api calls would even work, as I suspect Zorro would time out if the api call takes to long. I will check this with zorro support team. Anyways, I'm away on vacation for the next 5 weeks, so I won't prioritize this specific suggestion during that time.

Re: IG plugin initial release [Re: Dalla] #467298
07/25/17 09:50
07/25/17 09:50
Joined: Jul 2016
Posts: 93
Düsseldorf, Germany
M
mhdus Offline
Junior Member
mhdus  Offline
Junior Member
M

Joined: Jul 2016
Posts: 93
Düsseldorf, Germany
Thank you very much. I think the Zorro developers should be able to introduce a parameter to adjust for such delays ... enjoy your vacation!

Re: IG plugin initial release [Re: mhdus] #467301
07/25/17 11:30
07/25/17 11:30
Joined: Feb 2017
Posts: 9
D
dhrv Offline
Newbie
dhrv  Offline
Newbie
D

Joined: Feb 2017
Posts: 9
This was purely about updating the Asset list variables (spread etc.), not about downloading historic prices (.t6 files), but yes, I always update the Asset list successfully in small batches laugh Still I wanted to report this since you guys were discussing something similar. It really all comes down to IG's API limit. I imagine it's hard for the Zorro Devs and for you to implement a queuing or connection throttle while retaining the guarantee to be able to modify orders/close trades at all times. So don't worry about this too much and enjoy your holidays! laugh

Re: IG plugin initial release [Re: dhrv] #467302
07/25/17 12:36
07/25/17 12:36
Joined: Jul 2016
Posts: 93
Düsseldorf, Germany
M
mhdus Offline
Junior Member
mhdus  Offline
Junior Member
M

Joined: Jul 2016
Posts: 93
Düsseldorf, Germany
As long as the throttling would only affect the INITRUN of a strategy, it should be easy to implement into the Zorro core, at least. I'll continue bugging IG for an increase of the 30 requests limit as this doesn't make sense to me either.

Re: IG plugin initial release [Re: mhdus] #467304
07/25/17 15:42
07/25/17 15:42
Joined: Jul 2016
Posts: 93
Düsseldorf, Germany
M
mhdus Offline
Junior Member
mhdus  Offline
Junior Member
M

Joined: Jul 2016
Posts: 93
Düsseldorf, Germany
Finally IG have increased my limits: "account non trading request per minute to 60 and account trading requests per minute to 100" - an I could successfully start Z12, Z3, and Z7. Of course I have been waiting 2-3 mins between starting each of the strategies.
Ok, one issue fixed, now let's see how it looks while trading ...

Re: IG plugin initial release [Re: mhdus] #467305
07/25/17 17:25
07/25/17 17:25
Joined: Jul 2000
Posts: 27,978
Frankfurt
jcl Offline

Chief Engineer
jcl  Offline

Chief Engineer

Joined: Jul 2000
Posts: 27,978
Frankfurt
Zorro provides two functions for adjusting delays: SET_DELAY and SET_WAIT. But they must be realized in the plugin. Most broker plugins support them, but I don't know if they are implemented in the IG plugin.

Re: IG plugin initial release [Re: jcl] #468083
09/17/17 22:54
09/17/17 22:54
Joined: Sep 2017
Posts: 13
Y
Yop127 Offline
Newbie
Yop127  Offline
Newbie
Y

Joined: Sep 2017
Posts: 13
Hello,
I am pretty new to this coding, I am trying to connect a demo account to Zorro using your plugin, but I do not succeed. The message is get from Zorro is:
Login IG..
!java.lang.NoClassDefFoundError!com/danlind/igz/ZorroBridge
BrokerLogin:No Data!

I do not really know what to do as I think I followed all the steps from the readme file. Any hint on what to do?
Thank you

Re: IG plugin initial release [Re: Yop127] #468086
09/18/17 05:27
09/18/17 05:27
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
If you are using the latest zorro release there might be an issue which I discovered only yesterday. Will try to post an update today.

Re: IG plugin initial release [Re: Dalla] #468087
09/18/17 06:22
09/18/17 06:22
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
Can you try with this new release?

https://github.com/dan-lind/igzplugin/releases/tag/v0.22

Also make sure you've followed these instructions
https://github.com/dan-lind/igzplugin

Re: IG plugin initial release [Re: Dalla] #468088
09/18/17 07:20
09/18/17 07:20
Joined: Sep 2017
Posts: 13
Y
Yop127 Offline
Newbie
Yop127  Offline
Newbie
Y

Joined: Sep 2017
Posts: 13
Hello I am at work currently so I will only try at noon. I indeed use the latest version of Zorro. I will keep you posted. Thank you

Re: IG plugin initial release [Re: Yop127] #468091
09/18/17 08:55
09/18/17 08:55
Joined: Sep 2017
Posts: 13
Y
Yop127 Offline
Newbie
Yop127  Offline
Newbie
Y

Joined: Sep 2017
Posts: 13
Hi,
Now I have an error message. Link to the log file is here: https://pastebin.com/ygvn5yzG

Re: IG plugin initial release [Re: Yop127] #468103
09/18/17 15:48
09/18/17 15:48
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
It looks like you didn't read the Readme after all? &#128539;
The error message is pretty obvious

Exception when creating session with api key <your demo key here>, error was {"errorCode":"error.security.api-key-invalid"}

Re: IG plugin initial release [Re: Dalla] #468104
09/18/17 18:12
09/18/17 18:12
Joined: Sep 2017
Posts: 13
Y
Yop127 Offline
Newbie
Yop127  Offline
Newbie
Y

Joined: Sep 2017
Posts: 13
I did, my bad didn't really know where to look in the log file. Now I have a different error. I updated the symbols name as requested (I took the CSV displayed previous posts ago), but I am not sure if the error is due to this. Is it ok if I created a AssetsIG.csv file with the following:

Name,Price,Spread,RollLong,RollShort,PIP,PIPCost,MarginCost,Leverage,LotAmount,Commission,Symbol
AUD/USD,0.77311,0.00005,0.24,-0.51,0.0001,0.0871,9,0,1000,0.6,CX.D.AUDUSD.CASH.IP
EUR/CHF,1.07962,0.00004,0.08,-0.26,0.0001,0.09263,75,0,1000,0.8,CX.D.EURCHF.CASH.IP
EUR/JPY,123.359,0.006,-0.3,0.09,0.01,0.081066,10,0,1000,0.8,CX.D.EURJPY.CASH.IP
EUR/USD,1.13795,0.00005,-0.02,0.01,0.0001,0.0871,10,0,1000,0.6,CX.D.EURUSD.CASH.IP
GBP/USD,1.51364,0.00003,0.05,-0.12,0.0001,0.0871,14,0,1000,0.6,CX.D.GBPUSD.CASH.IP
GER30,10884,1,-0.1,0,1,0.1,6,0,0.1,0,IX.D.DAX.IFD.IP
NAS100,4185,2,-0.1,0,1,0.0871,2,0,0.1,0,IX.D.NASDAQ.IFD.IP
NZD/USD,0.67752,0.00007,0.6,-1.32,0.0001,0.088713,7,0,1000,0.8,CX.D.NZDUSD.CASH.IP
SPX500,2032.4,0.5,-0.5,0,0.1,0.0871,8,0,1,0,IX.D.SPTRD.IFD.IP
UK100,6869,2,-0.1,0,1,0.13183,6,0,0.1,0,IX.D.FTSE.CFD.IP
US30,17520,2,-0.5,0,1,0.0871,6,0,0.1,0,IX.D.DOW.IFD.IP
USD/CAD,1.24466,0.0001,-0.21,0.09,0.0001,0.06998,10,0,1000,0.8,CX.D.USDCAD.CASH.IP
USD/CHF,0.92203,0.00022,0.15,-0.58,0.0001,0.09446,50,0,1000,0.6,CX.D.USDCHF.CASH.IP
USD/JPY,117.489,0.004,0.02,-0.04,0.01,0.07413,10,0,1000,0.6,CX.D.USDJPY.CASH.IP
XAG/USD,17.235,0.046,-0.0009,0,0.01,0.43547,5,0,50,0,CX.D.XAGUSD.CASH.IP
XAU/USD,1260.82,0.47,-0.0124,0,0.01,0.00871,11,0,1,0,CX.D.XAUUSD.CASH.IP


Error messages:

2017-09-18 20:05:04.852 [main] ERROR c.danlind.igz.adapter.RestApiAdapter - Exception when getting historic prices for epic EUR/USD, error was <html><head><title>Page Not Found</title><h3>Error 404</h3><h3>Sorry, the requested page is not available.</h3></body></html>
org.springframework.web.client.HttpClientErrorException: 404 Not Found

2017-09-18 20:05:04.853 [main] ERROR c.danlind.igz.brokerapi.BrokerAsset - Error when subscribing to EUR/USD
org.springframework.web.client.HttpClientErrorException: 404 Not Found

2017-09-18 20:05:04.975 [RxCachedThreadScheduler-6] ERROR c.danlind.igz.brokerapi.BrokerAsset - Error subscribing to volume observable for EUR/USD
com.lightstreamer.ls_client.PushUserException: Incorrect instrument setup

I really appreciate the time & effort you put into this plugin!

Last edited by Yop127; 09/18/17 18:14.
Re: IG plugin initial release [Re: Yop127] #468105
09/18/17 18:24
09/18/17 18:24
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
If you want to use another asset list than asset fix, load it with assetList in your strategy like this

assetList("AssetsIG");

http://zorro-project.com/manual/en/asset.htm

Re: IG plugin initial release [Re: Dalla] #468107
09/18/17 18:59
09/18/17 18:59
Joined: Sep 2017
Posts: 13
Y
Yop127 Offline
Newbie
Yop127  Offline
Newbie
Y

Joined: Sep 2017
Posts: 13
Editting my previous post, the symbols were not ok.
Now I think I have the correct one, but I do get this:

2017-09-18 21:13:32.126 [main] ERROR c.danlind.igz.adapter.RestApiAdapter - Exception when getting historic prices for epic EUR/USD, error was <html><head><title>Page Not Found</title><h3>Error 404</h3><h3>Sorry, the requested page is not available.</h3></body></html>
org.springframework.web.client.HttpClientErrorException: 404 Not Found

2017-09-18 21:13:32.127 [main] ERROR c.danlind.igz.brokerapi.BrokerAsset - Error when subscribing to EUR/USD
org.springframework.web.client.HttpClientErrorException: 404 Not Found

and if I try the GER30, I get this:

2017-09-18 21:14:24.574 [RxCachedThreadScheduler-3] ERROR c.danlind.igz.brokerapi.BrokerAsset - Error subscribing to tick observable for IX.D.DAX.IFD.IP
com.lightstreamer.ls_client.PushUserException: Insufficient permissions

2017-09-18 21:14:24.710 [RxCachedThreadScheduler-5] ERROR c.danlind.igz.brokerapi.BrokerAsset - Error subscribing to volume observable for IX.D.DAX.IFD.IP
com.lightstreamer.ls_client.PushUserException: Insufficient permissions

I am a bit lost, sorry for this... I do not understand if my settings are wrong or if I cannot access the value due to any other limitation

Last edited by Yop127; 09/18/17 20:23.
Re: IG plugin initial release [Re: Yop127] #468112
09/19/17 00:51
09/19/17 00:51
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
EUR/USD is not a correct symbol name, it should be more in line with the other examples you have given. Not sure about Insufficient permission, you would need to ask IG support about that.

Re: IG plugin initial release [Re: Dalla] #468118
09/19/17 04:53
09/19/17 04:53
Joined: Sep 2017
Posts: 13
Y
Yop127 Offline
Newbie
Yop127  Offline
Newbie
Y

Joined: Sep 2017
Posts: 13
I will get to IG and keep you posted. Regarding EUR/USD, I do not understand one point: my line in the Assets.csv file is the following:
EUR/USD,1.13795,0.00005,-0.0200,0.0100,0.0001,0.087100,10.0000,99.115,1000.0,0.600,CS.D.EURUSD.CFD.IP

It is pressty close to the example I saw before. The symbol name I put is not EUR/USD but CS.D.EURUSD.CFD.IP which is what I get from the API companion. Then why Zorro is telling me about EUR/USD?

Re: IG plugin initial release [Re: Yop127] #468119
09/19/17 05:04
09/19/17 05:04
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
Can you post your strategy and your current AssetsIG file?

Re: IG plugin initial release [Re: Dalla] #468139
09/19/17 19:34
09/19/17 19:34
Joined: Sep 2017
Posts: 13
Y
Yop127 Offline
Newbie
Yop127  Offline
Newbie
Y

Joined: Sep 2017
Posts: 13
Here is the AssetsIG.csv file saved in the History folder, and here is the strategy: https://pastebin.com/6BFHZVJA. Nothing fancy, just the test trade strategy with the assetList("AssetsIG"); line added
Log file here: https://pastebin.com/F1vLBtuS

Last edited by Yop127; 09/19/17 19:35.
Re: IG plugin initial release [Re: Yop127] #468141
09/20/17 03:58
09/20/17 03:58
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
Can't see the asset file? My suspicion would be that something is wrong with that, because apparently it's trying to subscribe to EUR/USD rather than the long weird epic name used by IG.

Re: IG plugin initial release [Re: Dalla] #468151
09/20/17 18:45
09/20/17 18:45
Joined: Sep 2017
Posts: 13
Y
Yop127 Offline
Newbie
Yop127  Offline
Newbie
Y

Joined: Sep 2017
Posts: 13
Here are the log file, the assetIG file and the asset file. Strategy is the same as previous. I get the code is trying to subscribe to EUR/USD but I don't get why it would use the epic name for DAX and not for EUR/USD

Attached Files
Nouveau dossier.rar (250 downloads)
Last edited by Yop127; 09/20/17 20:08.
Re: IG plugin initial release [Re: Yop127] #468153
09/20/17 19:53
09/20/17 19:53
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
Not sure why you have both an Assets and an AssetsIG? Anyway, I cannot see anything obvisouly wrong with the AssetsIG file. I would try a much simpler strategy first without all PanelGet etc, just to see if you can make it work. I'm pretty confident that the issue you are experiencing is not connected to the plugin.

Re: IG plugin initial release [Re: Dalla] #468154
09/20/17 20:34
09/20/17 20:34
Joined: Sep 2017
Posts: 13
Y
Yop127 Offline
Newbie
Yop127  Offline
Newbie
Y

Joined: Sep 2017
Posts: 13
Ok I think I figured it out, and your plugin is working fine. Many thanks for the support.

Re: IG plugin initial release [Re: Yop127] #468207
09/24/17 16:23
09/24/17 16:23
Joined: Sep 2017
Posts: 13
Y
Yop127 Offline
Newbie
Yop127  Offline
Newbie
Y

Joined: Sep 2017
Posts: 13
Hello,
Sorry to disturb again, I am trying to download data using the download script. I entered the correst symbol for EUR/USD, and I get this message:

2017-09-24 17:59:01.357 [main] WARN c.d.igz.brokerapi.BrokerHistory - Zero ticks returned for requested date range 2017-09-24T12:59:01 - 2017-09-24T17:59:01

If I change the years (instead of 2017-2017 I input 2016-2017) I also get the same error message plus another one:

2017-09-24 18:08:23.391 [main] WARN c.d.igz.brokerapi.BrokerHistory - Zero ticks returned for requested date range 2016-12-31T20:48:59 - 2017-01-01T01:48:59

Is the download script working with the plugin or should I write my own script? What is the reason of such an error?

Sorry to bother you again, I am still learning!

Re: IG plugin initial release [Re: Yop127] #468208
09/24/17 16:45
09/24/17 16:45
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
I would not recommend using the plugin to download historical data, other than to backfill the lookback period when starting a script. IGs limits for historical data is VERY low, which means you will easily exhaust your weekly limit. If you do, you will not even be able to start a script if even a single minute of data is missing.

That said, it should work with the download script, IF you stay within the time range given in the FAQ: https://labs.ig.com/faq.

My guess for the error message: You have tried to download data from today = Sunday. IG is not open until late in the evening on Sundays, so there are no ticks to be found within the range stated in the error message.

The second error is probably because you are trying to fetch data too far back in time, again refer to the FAQ.

Re: IG plugin initial release [Re: Dalla] #468245
09/27/17 03:38
09/27/17 03:38
Joined: Sep 2017
Posts: 13
Singapore
K
krisbaum Offline
Newbie
krisbaum  Offline
Newbie
K

Joined: Sep 2017
Posts: 13
Singapore
Hello Dalla & community,

I attempted to connect to IG using the IG plugin. I read through this thread but was not able to resolve this on my own leaving me with a bit of a bruised ego.

These are the steps I performed:
- Installed Zorro V1.60
- Installed IG plugin as per instructions in the manual and on GitHub
- Generated API keys for both real and demo IG accounts
- Updated API keys in application properties.file of IG plugin
- Updated File AssetsFix.csv with IG symbols extracted from IG API Companion

I failed when attempting to run any of the scripts, for example 'TradeTest'and 'Download'scripts receiving the error message: Severe error occured, check igzplugin.log logfile! Can't connect!.

The result is the same after multiple attempts over several days. I also tried using (1) username + password and (2) username + API key to connect to the server, again with the same result.

Any advice on how to tackle this would be greatly appreciated.

Best regards,
Kris

Attached Files
Re: IG plugin initial release [Re: krisbaum] #468252
09/27/17 09:13
09/27/17 09:13
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
Hi

You said that you installed Zorro 1.60. The newest version is 1.66. Try with that first.
To be honest I don't really know what the problem is, can't remember seeing error 400. I would expect 403 if something was wrong with the login credentials.

Re: IG plugin initial release [Re: Dalla] #468255
09/27/17 09:33
09/27/17 09:33
Joined: Sep 2017
Posts: 13
Singapore
K
krisbaum Offline
Newbie
krisbaum  Offline
Newbie
K

Joined: Sep 2017
Posts: 13
Singapore
Hi Dalla,

Thanks for the quick response, I will try with V1.66. In the meantime I found out that IG has a login restriction for Singapore where I am located:

**************************************************************************
Login Restrictions
The /session API is subject to the following country-specific restrictions:
Singapore - all login passwords must first be encrypted using the relevant IG SDK function below.

To encrypt a password:
call /session/encryptionKey which gives a key and timestamp
create a RSA token using the key.
encrypt password + "|" + timestamp
See sample applications for further details.

**************************************************************************

Source: https://labs.ig.com/loginrestrictions

Could this be a problem for the plugin?

Thanks,
Kris

Re: IG plugin initial release [Re: krisbaum] #468258
09/27/17 10:54
09/27/17 10:54
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
The password is not encrypted at this point, although that might be a good thing to implement in a future version. Unfortunately I don't have that much time at the moment, so I wouldn't expect this to change soon. I'd be happy to take a pull request if your up for implementing it yourself.

Re: IG plugin initial release [Re: Dalla] #468288
09/28/17 09:02
09/28/17 09:02
Joined: Sep 2017
Posts: 13
Singapore
K
krisbaum Offline
Newbie
krisbaum  Offline
Newbie
K

Joined: Sep 2017
Posts: 13
Singapore
Hi Dalla,

I am not exactly a skilled coder but I might give it a shot...

Re: IG plugin initial release [Re: Dalla] #468340
10/01/17 16:09
10/01/17 16:09
Joined: Sep 2017
Posts: 13
Y
Yop127 Offline
Newbie
Yop127  Offline
Newbie
Y

Joined: Sep 2017
Posts: 13
Dalla,to let you know, I have been able to download data from IG. Thanks for your help. I am now working on getting more historical data from FXCM plugin & develop my first strategies
Again, thank you for your support

Last edited by Yop127; 10/01/17 20:07.
Re: IG plugin initial release [Re: Yop127] #468344
10/01/17 18:10
10/01/17 18:10
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
Great to hear!

Re: IG plugin initial release [Re: Dalla] #468427
10/04/17 06:42
10/04/17 06:42
Joined: Dec 2016
Posts: 71
F
firecrest Offline
Junior Member
firecrest  Offline
Junior Member
F

Joined: Dec 2016
Posts: 71
Hi Krisbaum, did you manage to encrypt password? Maybe you can try mt4 plugin.

Re: IG plugin initial release [Re: firecrest] #468431
10/04/17 08:18
10/04/17 08:18
Joined: Sep 2017
Posts: 13
Singapore
K
krisbaum Offline
Newbie
krisbaum  Offline
Newbie
K

Joined: Sep 2017
Posts: 13
Singapore
Hi Firecrest, not yet. I haven't found time to look into this further. I would post any updates here. Cheers

Re: IG plugin initial release [Re: krisbaum] #468623
10/11/17 17:46
10/11/17 17:46
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
I have looked into encrypting the password for IG. Unfortunately it looks like that's only possible using an older login API which I have currently not implemented at all in the plugin. If someone feels like making the necessary changes and sending a pull request on the project, I'd be happy to take a look at it. But for now I will not implement it myself, given the fact that this only affects Singapore users.

Re: IG plugin initial release [Re: Dalla] #468658
10/12/17 13:23
10/12/17 13:23
Joined: Sep 2017
Posts: 13
Singapore
K
krisbaum Offline
Newbie
krisbaum  Offline
Newbie
K

Joined: Sep 2017
Posts: 13
Singapore
Hi Dalla, thanks for looking into this. Understood, it doesn't impact a lot of users. For myself I switched to Oanda now at least for the time being, not having any issues there (yet).

Re: IG plugin initial release [Re: krisbaum] #468916
10/27/17 13:13
10/27/17 13:13
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
Released a new version of the plugin.
https://github.com/dan-lind/igzplugin/releases/tag/v0.3

This release includes stability fixes, and support for broker command to set order text.

Re: IG plugin initial release [Re: Dalla] #468959
10/30/17 07:11
10/30/17 07:11
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
Another release, 0.31
https://github.com/dan-lind/igzplugin/releases/tag/v0.31

This will fix an issue where trade ids could collide when running multiple instances of Zorro and using the IG plugin.

Re: IG plugin initial release [Re: kmerlo] #469511
11/19/17 03:35
11/19/17 03:35
Joined: Nov 2017
Posts: 17
A
Andy60 Offline
Newbie
Andy60  Offline
Newbie
A

Joined: Nov 2017
Posts: 17
Hi, thx for your works. I am new to Zorro and plugins. In help page you write to insert:

Zorro fields for IG
User: IG Account ID
Password: IG Password

What userid and password? mt4 userid and password or generic userid and password for ig access?

Thx for your attention..

Last edited by Andy60; 11/19/17 10:17.
Re: IG plugin initial release [Re: Andy60] #469533
11/20/17 07:39
11/20/17 07:39
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
Hi,

You should input your IG account user name and password

Regards
Daniel

Re: IG plugin initial release [Re: Dalla] #469551
11/21/17 03:29
11/21/17 03:29
Joined: Nov 2017
Posts: 17
A
Andy60 Offline
Newbie
Andy60  Offline
Newbie
A

Joined: Nov 2017
Posts: 17
Thx, what about Avatrade? It has a very long list of indices and stocks. It would be interesting develop a spread trading system.

Re: IG plugin initial release [Re: Andy60] #469553
11/21/17 06:44
11/21/17 06:44
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
Never heard of it.
If it´s another broker, I suggest you start a new thread on that topic.

Re: IG plugin initial release [Re: Dalla] #471784
03/19/18 18:57
03/19/18 18:57
Joined: Mar 2018
Posts: 12
Austria_VIENNA
IMMO_VIE Offline
Newbie
IMMO_VIE  Offline
Newbie

Joined: Mar 2018
Posts: 12
Austria_VIENNA
Hello Dalla! Master of IG-Plugin!

Could u be so kind and help me with following problem?
when i try to download (download skript from zorro) prices of eur/usd or any other asset:



Download compiling...........

Download...
Login 0 IG.. at UTC 03-19 18:56.
!Severe error occured, check igzplugin.log logfile!
!Command 43 not yet supported.
!Severe error occured, check igzplugin.log logfile!
!Severe error occured, check igzplugin.log logfile!..
Done
Logout.. ok



thx!

Last edited by IMMO_VIE; 03/19/18 18:57.
Re: IG plugin initial release [Re: IMMO_VIE] #471785
03/19/18 19:23
03/19/18 19:23
Joined: Feb 2017
Posts: 1,725
Chicago
AndrewAMD Online
Serious User
AndrewAMD  Online
Serious User

Joined: Feb 2017
Posts: 1,725
Chicago
Originally Posted By: IMMO_VIE
!Command 43 not yet supported.
This error can be ignored. However...
Originally Posted By: IMMO_VIE
!Severe error occured, check igzplugin.log logfile!
Did you check the contents of the aforementioned log file? If you're still confused, please post the logfile.

Re: IG plugin initial release [Re: Dalla] #471797
03/19/18 21:22
03/19/18 21:22
Joined: Mar 2018
Posts: 12
Austria_VIENNA
IMMO_VIE Offline
Newbie
IMMO_VIE  Offline
Newbie

Joined: Mar 2018
Posts: 12
Austria_VIENNA
thx for ur support!
but when u tell me its not important... thx anyway!

Attached Files
igzplugin.txt (612 downloads)
Re: IG plugin initial release [Re: IMMO_VIE] #471799
03/19/18 21:35
03/19/18 21:35
Joined: Feb 2017
Posts: 1,725
Chicago
AndrewAMD Online
Serious User
AndrewAMD  Online
Serious User

Joined: Feb 2017
Posts: 1,725
Chicago
Command 43 is a Zorro feature that I requested so that I can use it for my own plugin, so I knew it was irrelevant.

In any case, Dalla should have enough context to help you now. laugh

Re: IG plugin initial release [Re: AndrewAMD] #471805
03/20/18 06:14
03/20/18 06:14
Joined: Mar 2018
Posts: 12
Austria_VIENNA
IMMO_VIE Offline
Newbie
IMMO_VIE  Offline
Newbie

Joined: Mar 2018
Posts: 12
Austria_VIENNA
thank u so much!
waiting for dalla now laugh

Re: IG plugin initial release [Re: IMMO_VIE] #472085
04/05/18 16:28
04/05/18 16:28
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
It appears that you did not read the manual? :-)

The log is full of these kinds of messages
"Exception when getting historic prices for epic GER30, API call failed with status code 404 and body {"errorCode":"error.price-history.io-error"}"

The first remark mentioned in the manual here http://zorro-project.com/manual/en/ig.htm is this

"You need a dedicated asset list for IG, since the asset symbols are very different to the asset names. For instance, the EUR/USD symbol is CS.D.EURUSD.CFD.IP You can find the correct symbol names with the IG API Companion. Log in with you user name, password and api key, then scroll down to Market Search, enter your search String, e.g. DAX. Now look in the response for the "epic" key, e.g. "epic": "IX.D.DAX.IFD.IP""

Also sorry for the late reply, I realised today that I was logged out and therefor not receiving any notifications

Last edited by Dalla; 04/05/18 16:31.
Re: IG plugin initial release [Re: Dalla] #472122
04/09/18 16:11
04/09/18 16:11
Joined: Mar 2018
Posts: 12
Austria_VIENNA
IMMO_VIE Offline
Newbie
IMMO_VIE  Offline
Newbie

Joined: Mar 2018
Posts: 12
Austria_VIENNA
hello dalla!

thx for the help!

Re: IG plugin initial release [Re: IMMO_VIE] #476995
05/01/19 07:56
05/01/19 07:56
Joined: Nov 2017
Posts: 17
A
Andy60 Offline
Newbie
Andy60  Offline
Newbie
A

Joined: Nov 2017
Posts: 17
Hi Dalla

===Configuration===
Win10
MT4 Build 1770
IG Markets Broker with demo and live userid and master password
Java8 Build 211
Zorro 2.09
IG plugin 0.31
2 demo and real api ig keys generated
AssetFix ig modified

application.properties api inserted with this:
plugin.realApiKey=api
plugin.demoApiKey=api
without < and >
=== end configuration

If I select both account's types (real or demo) I see:

TradeTest compiling...........
Login 0 IG..
Can't connect!.

Have u suggestions? Thx for your attention

Re: IG plugin initial release [Re: Andy60] #476998
05/01/19 09:57
05/01/19 09:57
Joined: Nov 2017
Posts: 17
A
Andy60 Offline
Newbie
Andy60  Offline
Newbie
A

Joined: Nov 2017
Posts: 17
I can enter but I have errors:

REAL
!Severe error occured, check igzplugin.log logfile!
!Severe error occured, check igzplugin.log logfile!
Error 053: CS.D.CFDSILVER.MC1.IP unavailable at this time

Trade: Z1 2019-05-01
Read Z12.fac
Lookback period (500 bars)
Error 011: ATR XAG/USD invalid parameters (uninitialized) at bar 224
Error 011: RSI XAG/USD invalid parameters (uninitialized) at bar 224.

[Stop] at 09:52
Logout.. ok.

DEMO
!Severe error occured, check igzplugin.log logfile!
!Severe error occured, check igzplugin.log logfile!
Error 053: UK100 unavailable at this time
!Severe error occured, check igzplugin.log logfile!
!Severe error occured, check igzplugin.log logfile!
Error 053: CS.D.CFDGOLD.MC1.IP unavailable at this time
!Severe error occured, check igzplugin.log logfile!
!Severe error occured, check igzplugin.log logfile!
Error 053: CS.D.CFDSILVER.MC1.IP unavailable at this time
Error 055: No bars generated
Logout.. ok
!Severe error occured, check igzplugin.log logfile!

AssetsFix.csv:
Name,Price,Spread,RollLong,RollShort,PIP,PIPCost,MarginCost,Leverage,LotAmount,Commission,Symbol
AUD/CAD,0.96837,0.00013,0.19,-0.48,0.0001,0.06946,8,0,1000,0.000,CS.D.AUDCAD.MT1.IP
AUD/CHF,0.72544,0.00008,0.35,-0.82,0.0001,0.09272,40,0,1000,0.000,CS.D.AUDCHF.MT1.IP
AUD/JPY,91.817,0.005,0.27,-0.6,0.01,0.07325,8,0,1000,0.000,CS.D.AUDJPY.MT1.IP
AUD/NZD,1.12018,0.00015,-0.29,0.12,0.0001,0.06004,8,0,1000,0.000,CS.D.AUDNZD.MT1.IP
AUD/USD,0.73677,0.00003,0.24,-0.51,0.0001,0.09129,8,0,1000,0.000,CS.D.AUDUSD.MT1.IP
CAD/CHF,0.74917,0.00007,0.13,-0.33,0.0001,0.09272,40,0,1000,0.000,CS.D.CADCHF.MT1.IP
CAD/JPY,94.824,0.007,0.03,-0.13,0.01,0.07325,8,0,1000,0.000,CS.D.CADJPY.MT1.IP
CHF/JPY,126.575,0.006,-0.32,0.12,0.01,0.07325,55,0,1000,0.000,CS.D.CHFJPY.MT1.IP
EUR/AUD,1.48693,0.00011,-0.87,0.41,0.0001,0.06726,10,0,1000,0.000,CS.D.EURAUD.MT1.IP
EUR/CAD,1.43979,0.00012,-0.26,0.1,0.0001,0.06946,10,0,1000,0.000,CS.D.EURCAD.MT1.IP
EUR/CHF,1.0786,0.00006,0.09,-0.26,0.0001,0.09272,75,0,1000,0.000,CS.D.EURCHF.MT1.IP
EUR/GBP,0.70724,0.00005,-0.24,0.11,0.0001,0.1414,10,0,1000,0.000,CS.D.EURGBP.MT1.IP
EUR/JPY,136.52,0.007,-0.08,0.03,0.01,0.07325,10,0,1000,0.000,CS.D.EURJPY.MT1.IP
EUR/NZD,1.66552,0.00025,-1.3,0.6,0.0001,0.06005,10,0,1000,0.000,CS.D.EURNZD.MT1.IP
EUR/USD,1.09546,0.00003,-0.14,0.06,0.0001,0.09129,10,0,1000,0.000,CS.D.EURUSD.MT1.IP
GBP/AUD,2.1026,0.00018,-0.94,0.44,0.0001,0.06726,16,0,1000,0.000,CS.D.GBPAUD.MT1.IP
GBP/CAD,2.0359,0.00021,0.03,-0.09,0.0001,0.06946,16,0,1000,0.000,CS.D.GBPCAD.MT1.IP
GBP/CHF,1.52516,0.00012,0.31,-0.7,0.0001,0.09272,80,0,1000,0.000,CS.D.GBPCHF.MT1.IP
GBP/JPY,193.04,0.009,0.12,-0.28,0.01,0.07325,16,0,1000,0.000,CS.D.GBPJPY.MT1.IP
GBP/NZD,2.3551,0.00044,-1.48,0.68,0.0001,0.06005,16,0,1000,0.000,CS.D.GBPNZD.MT1.IP
GBP/USD,1.54901,0.00006,0.07,-0.15,0.0001,0.09129,16,0,1000,0.000,CS.D.GBPUSD.MT1.IP
NZD/CAD,0.86456,0.00015,0.27,-0.6,0.0001,0.06946,7,0,1000,0.000,CS.D.NZDCAD.MT1.IP
NZD/CHF,0.64768,0.00011,0.41,-0.9,0.0001,0.09272,35,0,1000,0.000,CS.D.NZDCHF.MT1.IP
NZD/JPY,81.976,0.012,0.34,-0.74,0.01,0.07325,7,0,1000,0.000,CS.D.NZDJPY.MT1.IP
NZD/USD,0.65779,0.00007,0.31,-0.69,0.0001,0.09129,7,0,1000,0.000,CS.D.NZDUSD.MT1.IP
USD/CAD,1.3143,0.00004,-0.08,0.02,0.0001,0.06946,10,0,1000,0.000,CS.D.USDCAD.MT1.IP
USD/CHF,0.98462,0.00005,0.14,-0.36,0.0001,0.09272,50,0,1000,0.000,CS.D.USDCHF.MT1.IP
USD/JPY,124.622,0.002,0.03,-0.08,0.01,0.07325,10,0,1000,0.000,CS.D.USDJPY.MT1.IP
GER30,12418,1,-0.5151,0.0859,1.00000,1.140490,0,100,1.00,0.000,IX.D.DAX.MT1.IP
NAS100,7417,1,0.0210,-0.1892,1.00000,1.000000,0,100,1.00,0.000,IX.D.NASDAQ.MT1.IP
SPX500,2838,0.5,0.0645,-0.1439,1.00000,1.000000,0,100,1.00,0.000,IX.D.SPTRD.MT1.IP
US30,25319,2,0.6794,-1.3588,1.00000,1.000000,0,100,1.00,0.000,IX.D.DOW.MT1.IP
XAG/USD,15.35795,0.046,-0.0002,-0.0004,0.00010,0.100,0,100,1000,0.000,CS.D.CFDSILVER.MC1.IP
XAU/USD,1210.69,0.31,-0.0199,-0.0290,0.01000,0.010000,0,100,1.00,0.000,CS.D.CFDGOLD.MC1.IP

Re: IG plugin initial release [Re: Andy60] #477028
05/03/19 19:09
05/03/19 19:09
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
How did you find those symbols?

For example
AUDCAD = CS.D.AUDCAD.MT1.IP

If I search the markets API for AUDCAD:
https://demo-api.ig.com/gateway/deal/markets?searchTerm=AUDCAD

I only get two hits
CS.D.AUDCAD.CFD.IP
CS.D.AUDCAD.MINI.IP
you will also see that
"streamingPricesAvailable": true,

If I search for your symbol
https://demo-api.ig.com/gateway/deal/markets/CS.D.AUDCAD.MT1.IP
"streamingPricesAvailable": false,

So you need to go through your asset list and correct the symbol names.

Re: IG plugin initial release [Re: Dalla] #477037
05/05/19 06:46
05/05/19 06:46
Joined: Nov 2017
Posts: 17
A
Andy60 Offline
Newbie
Andy60  Offline
Newbie
A

Joined: Nov 2017
Posts: 17
Thx I try today

Re: IG plugin initial release [Re: Andy60] #477038
05/05/19 06:54
05/05/19 06:54
Joined: Nov 2017
Posts: 17
A
Andy60 Offline
Newbie
Andy60  Offline
Newbie
A

Joined: Nov 2017
Posts: 17
ACCOUNT LIVE
======
https://api.ig.com/gateway/deal/markets?searchTerm=AUDCAD
I get:
CS.D.AUDCAD.MT1.IP and streamingPricesAvailable: true

ACCOUNT DEMO
======
url changes to:https://demo-api.ig.com/gateway/deal/markets?searchTerm=AUDCAD
I get:
CS.D.AUDCAD.CFD.IP and streamingPricesAvailable: true

I made asset list for live, my question is: Zorro free works for both asset lists demo and live?

Last edited by Andy60; 05/05/19 07:10.
Re: IG plugin initial release [Re: Andy60] #477051
05/07/19 15:17
05/07/19 15:17
Joined: Nov 2017
Posts: 17
A
Andy60 Offline
Newbie
Andy60  Offline
Newbie
A

Joined: Nov 2017
Posts: 17
What do you suggest to be able? Thx Dalla

Re: IG plugin initial release [Re: Andy60] #477052
05/07/19 18:03
05/07/19 18:03
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
I'm trading mini contracts and have been using the symbols in this assetlist for about a year

Code:
Name,Price,Spread,RollLong,RollShort,PIP,PIPCost,MarginCost,Leverage,LotAmount,Commission,Symbol
AUD/CAD,0.98797,0.00020,0.2400,-0.5100,0.00010,0.653582,64.5719,100.000,10000.00,0.000,CS.D.AUDCAD.MINI.IP
AUD/CAD,0.98808,0.00020,0.2400,-0.5100,0.00010,0.653518,64.5728,100.000,10000.00,0.000,CS.D.AUDCAD.MINI.IP
AUD/CHF,0.74985,0.00025,0.2400,-0.5100,0.00010,0.861189,96.8644,66.667,10000.00,0.000,CS.D.AUDCHF.MINI.IP
AUD/JPY,83.75,0.01,0.2400,-0.5100,0.01000,0.771034,64.5710,100.000,10000.00,0.000,CS.D.AUDJPY.MINI.IP
AUD/NZD,1.08348,0.00030,0.2400,-0.5100,0.00010,0.595951,64.5701,100.000,10000.00,0.000,CS.D.AUDNZD.MINI.IP
AUD/USD,0.76102,0.00015,0.2400,-0.5100,0.00010,0.848482,64.5712,100.000,10000.00,0.000,CS.D.AUDUSD.MINI.IP
CAD/CHF,0.75898,0.00025,0.2400,-0.5100,0.00010,0.861208,98.0459,66.667,10000.00,0.000,CS.D.CADCHF.MINI.IP
CAD/JPY,84.78,0.04,0.2400,-0.5100,0.01000,0.771028,49.0235,133.333,10000.00,0.000,CS.D.CADJPY.MINI.IP
CHF/JPY,111.71,0.02,0.2400,-0.5100,0.01000,0.771028,129.1915,66.667,10000.00,0.000,CS.D.CHFJPY.MINI.IP
EUR/CAD,1.53034,0.00030,-0.0200,0.0100,0.00010,0.653516,50.0051,200.000,10000.00,0.000,CS.D.EURCAD.MINI.IP
EUR/CHF,1.16126,0.00020,-0.0200,0.0100,0.00010,0.861208,150.0129,66.667,10000.00,0.000,CS.D.EURCHF.MINI.IP
EUR/GBP,0.88074,0.00009,-0.0200,0.0100,0.00010,1.135465,100.0049,100.000,10000.00,0.000,CS.D.EURGBP.MINI.IP
EUR/JPY,129.71,0.02,-0.0200,0.0100,0.01000,0.771028,50.0031,200.000,10000.00,0.000,CS.D.EURJPY.MINI.IP
EUR/NZD,1.67843,0.00030,-0.0200,0.0100,0.00010,0.595919,100.0209,100.000,10000.00,0.000,CS.D.EURNZD.MINI.IP
EUR/USD,1.17861,0.0001,-0.0200,0.0100,0.00010,0.848482,50.0015,200.000,10000.00,0.000,CS.D.EURUSD.MINI.IP
GBP/AUD,1.75874,0.00019,0.0500,-0.1200,0.00010,0.645653,113.5535,100.000,10000.00,0.000,CS.D.GBPAUD.MINI.IP
GBP/CAD,1.73782,0.00070,0.0500,-0.1200,0.00010,0.653520,113.5700,100.000,10000.00,0.000,CS.D.GBPCAD.MINI.IP
GBP/CHF,1.31861,0.00030,0.0500,-0.1200,0.00010,0.861200,170.3381,66.667,10000.00,0.000,CS.D.GBPCHF.MINI.IP
GBP/JPY,147.28,0.03,0.0500,-0.1200,0.01000,0.771025,113.5573,100.000,10000.00,0.000,CS.D.GBPJPY.MINI.IP
GBP/NZD,1.90560,0.00050,0.0500,-0.1200,0.00010,0.595955,113.5651,100.000,10000.00,0.000,CS.D.GBPNZD.MINI.IP
GBP/USD,1.33839,0.00009,0.0500,-0.1200,0.00010,0.848482,113.5600,100.000,10000.00,0.000,CS.D.GBPUSD.MINI.IP
GER30,12886,5,-0.1000,0.0000,1.00000,1.000000,64.4320,200.000,1.00,0.000,IX.D.DAX.IFMM.IP
NAS100,7170,3,-0.1000,0.0000,1.00000,1.000000,35.8490,200.000,1.00,0.000,IX.D.NASDAQ.IFE.IP
NZD/CAD,0.91211,0.00035,0.1500,-0.5800,0.00010,0.653520,59.6082,100.000,10000.00,0.000,CS.D.NZDCAD.MINI.IP
NZD/CHF,0.69228,0.00060,0.1500,-0.5800,0.00010,0.861208,89.4295,66.667,10000.00,0.000,CS.D.NZDCHF.MINI.IP
NZD/JPY,77.30,0.03,0.1500,-0.5800,0.01000,0.771031,59.6038,100.000,10000.00,0.000,CS.D.NZDJPY.MINI.IP
NZD/USD,0.70250,0.00020,0.1500,-0.5800,0.00010,0.848486,59.6061,100.000,10000.00,0.000,CS.D.NZDUSD.MINI.IP
SPX500,2783,1,-0.5000,0.0000,1.00000,1.000000,13.9141,200.000,1.00,0.000,IX.D.SPTRD.IFE.IP
TEST,12886,5,-0.1000,0.0000,1.00000,1.000000,64.4320,200.000,1.00,0.000,IX.D.DAX.IFMM.IP
UK100,7757,4,-0.1000,0.0000,1.00000,2.271140,88.0828,200.000,2.00,0.000,IX.D.FTSE.IFM.IP
US30,25328,6,-0.5000,0.0000,1.00000,1.696972,214.9054,200.000,2.00,0.000,IX.D.DOW.IFM.IP
USD/CAD,1.29834,0.00025,-0.2100,0.0900,0.00010,0.653595,42.4294,200.000,10000.00,0.000,CS.D.USDCAD.MINI.IP
USD/CHF,0.98532,0.00015,0.1500,-0.5800,0.00010,0.861208,127.2848,66.667,10000.00,0.000,CS.D.USDCHF.MINI.IP
USD/JPY,110.05,0.01,0.0200,-0.0400,0.01000,0.771034,42.4254,200.000,10000.00,0.000,CS.D.USDJPY.MINI.IP
XAG/USD,1694,2,0.0200,-0.0400,1.00000,4.242429,143.6996,50.000,500.00,0.000,CS.D.CFDSILVER.CFM.IP
XAU/USD,1295,0.3,0.0200,-0.0400,1.00000,1.000000,9.0661,142.857,1.00,0.000,CS.D.CFEGOLD.CFE.IP


Re: IG plugin initial release [Re: kmerlo] #477055
05/09/19 03:39
05/09/19 03:39
Joined: Oct 2018
Posts: 90
7
7th_zorro Offline
Junior Member
7th_zorro  Offline
Junior Member
7

Joined: Oct 2018
Posts: 90
When visual studio strategy development and debugging, IG Plugin cause some problem of visual studio debugging execution delay.

when visual studio debugging start, IG plugin cause visual studio parsing delay about 30 seconds.



Last edited by 7th_zorro; 05/09/19 03:44.
Re: IG plugin initial release [Re: 7th_zorro] #477056
05/09/19 06:00
05/09/19 06:00
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
I have never tried building strategies with visual studio, so I can't tell why that is.
If someone wants to submit a PR for this I'm all for it.

Re: IG plugin initial release [Re: Dalla] #477058
05/10/19 19:38
05/10/19 19:38
Joined: Nov 2017
Posts: 17
A
Andy60 Offline
Newbie
Andy60  Offline
Newbie
A

Joined: Nov 2017
Posts: 17
thx Dalla i will try it.

Re: IG plugin initial release [Re: Andy60] #477059
05/11/19 06:51
05/11/19 06:51
Joined: Oct 2018
Posts: 90
7
7th_zorro Offline
Junior Member
7th_zorro  Offline
Junior Member
7

Joined: Oct 2018
Posts: 90
This is sample visual studio strategy code.

To build this,
1) install visual studio 2017 with c++ development settings.
2) Register windows environment variable, add "ZORRO_ROOT" to indicate your zorro's install folder. something like this "C:/Users/username/Zorro"
3) open "dll_strategy_test.sln" file using visual studio
4) execute debugging will automatically popup zorro program and start backtest after long delay time.
5) Remove IG.dll file in your Zorro's plugin folder, then try again. This time you can see no delay execution.

Thank you!




Attached Files
dll_strategy_test.zip (129 downloads)
Last edited by 7th_zorro; 05/11/19 07:08.
Re: IG plugin initial release [Re: 7th_zorro] #477251
06/06/19 19:01
06/06/19 19:01
Joined: Jun 2019
Posts: 14
D
dh85 Offline
Newbie
dh85  Offline
Newbie
D

Joined: Jun 2019
Posts: 14
Hello,

I'm using the IG plugin with an IG demo account and my Zorro log gets flooded with the following error messages:

!Command 132 not yet supported.
!Command 132 not yet supported.
!Command 132 not yet supported.

What does this error message indicate and is there any way to prevent this error from happening?

Many thanks in advance.

Re: IG plugin initial release [Re: dh85] #477252
06/06/19 19:29
06/06/19 19:29
Joined: Feb 2017
Posts: 1,725
Chicago
AndrewAMD Online
Serious User
AndrewAMD  Online
Serious User

Joined: Feb 2017
Posts: 1,725
Chicago
It means either Zorro or your script is calling SET_SYMBOL, which the IG plugin does not support.

Re: IG plugin initial release [Re: AndrewAMD] #477283
06/12/19 18:47
06/12/19 18:47
Joined: Jun 2019
Posts: 14
D
dh85 Offline
Newbie
dh85  Offline
Newbie
D

Joined: Jun 2019
Posts: 14
Originally Posted by AndrewAMD
It means either Zorro or your script is calling SET_SYMBOL, which the IG plugin does not support.


Many thanks for your feedback. I'm using Zorro's Z12 strategy for which I cannot change the underlying code. Is there any way to ignore this error in the plugin?

Re: IG plugin initial release [Re: dh85] #477285
06/12/19 20:07
06/12/19 20:07
Joined: Feb 2017
Posts: 1,725
Chicago
AndrewAMD Online
Serious User
AndrewAMD  Online
Serious User

Joined: Feb 2017
Posts: 1,725
Chicago
Originally Posted by dh85
Many thanks for your feedback. I'm using Zorro's Z12 strategy for which I cannot change the underlying code. Is there any way to ignore this error in the plugin?

Either ignore it or kindly ask the plugin author to suppress the message.

Re: IG plugin initial release [Re: AndrewAMD] #477577
07/10/19 04:25
07/10/19 04:25
Joined: Jun 2019
Posts: 14
D
dh85 Offline
Newbie
dh85  Offline
Newbie
D

Joined: Jun 2019
Posts: 14
Originally Posted by AndrewAMD
It means either Zorro or your script is calling SET_SYMBOL, which the IG plugin does not support.


Hi AndrewAMD, just out of curiosity, how do you know that broker command 132 maps to SET_SYMBOL? I wasn't able to find this information in the Zorro manual.

Re: IG plugin initial release [Re: Dalla] #477579
07/10/19 10:35
07/10/19 10:35
Joined: Feb 2017
Posts: 1,725
Chicago
AndrewAMD Online
Serious User
AndrewAMD  Online
Serious User

Joined: Feb 2017
Posts: 1,725
Chicago
Hint: Look for SET_SYMBOL in your header files.

I have to know this stuff because I’m a plugin writer.

Re: IG plugin initial release [Re: Dalla] #477592
07/11/19 19:17
07/11/19 19:17
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
I have released a new version that should remove error logging for unsupported broker commands. Feel free to try it out here: https://github.com/dan-lind/igzplugin/releases/tag/v0.32

Re: IG plugin initial release [Re: Dalla] #477615
07/16/19 10:02
07/16/19 10:02
Joined: May 2018
Posts: 21
Y
YG8 Offline
Newbie
YG8  Offline
Newbie
Y

Joined: May 2018
Posts: 21
Hi

I am new to this so sorry for the stupid questions. I installed Zorro, and want to use IG as broker as thats what I use today. I tried to follow the instructions

https://manual.zorro-project.com/ig.htm - to the best of my abilities (not a tech wiz) but IG does not show up as a option. So first things first, I used this Java version (Windows x86 202.62 MB jdk-8u211-windows-i586.exe)

Can anyone confirm that its the one I should be using? (I installed Zorro on an VPS)

Regards

YG

Last edited by YG8; 07/16/19 10:03.
Re: IG plugin initial release [Re: Dalla] #477948
08/17/19 13:51
08/17/19 13:51
Joined: Aug 2019
Posts: 2
Stockholm
S
Southqvist Offline
Guest
Southqvist  Offline
Guest
S

Joined: Aug 2019
Posts: 2
Stockholm
Hi,


Thanks for this plugin!

I'm using workshop 6 and got required capital to 26 millions with the data form assets.csv and the original price history.

My account is in SEK.

Is there some kind of currency conversion problem?

Also, all rollover fees are zero. Is that correct?

Regards, Jonas

Re: IG plugin initial release [Re: Dalla] #477993
08/22/19 17:56
08/22/19 17:56
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
Where did you get your assets.csv?

Re: IG plugin initial release [Re: Dalla] #477994
08/23/19 07:07
08/23/19 07:07
Joined: Aug 2019
Posts: 2
Stockholm
S
Southqvist Offline
Guest
Southqvist  Offline
Guest
S

Joined: Aug 2019
Posts: 2
Stockholm
Hi, Dalla,

Thanks for you response!

Got it from the generated assets.csv in the Log folder. But it was my misstake, I had chosen an instrument with much lager lot size. When I changed to Mini-version everything looked good again.

But now I have a different problem, with the price history. Since it´s not easy to download data from IG, I downloaded the history from Darwinex and placed it in the History folder.

I put this in the AssetsIG.csv
[...],CS.D.EURUSD.MINI.IP!CS.D.EURUSD.MINI.IP!EUR/USD

So I should get IG's symbol for trading and live price, but history from EUR/USD.

But I get this error:
Workshop7 compiling...............
Login 0 IG.. at UTC 08-23 06:47. - EUR/USD history unavailable!
Error 055: No bars generated
Logout.. ok

Best,
Jonas

Re: IG plugin initial release [Re: Dalla] #478001
08/24/19 06:06
08/24/19 06:06
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
You converted the Darwinex data to t6 first I presume?

Re: IG plugin initial release [Re: YG8] #478230
09/23/19 07:40
09/23/19 07:40
Joined: Nov 2017
Posts: 17
A
Andy60 Offline
Newbie
Andy60  Offline
Newbie
A

Joined: Nov 2017
Posts: 17
I have problem with AssetsFix file and IG, if you resolve please report to forum, thx

Re: IG plugin initial release [Re: Dalla] #478572
11/10/19 11:57
11/10/19 11:57
Joined: Nov 2019
Posts: 1
K
KKelk Offline
Guest
KKelk  Offline
Guest
K

Joined: Nov 2019
Posts: 1
Hi everyone, I am a new to this API and am trying to set it up with Zorro 2.15.3.

I have followed all the steps and can see in the log that the API is connecting, but I get this error: "c.danlind.igz.adapter.RestApiAdapter - Exception when getting contract details blocking for CS.D.AUDCAD.MT1.IP, API call failed java.lang.IndexOutOfBoundsException: Index: 0, Size: 0"

On the Zorro print out, its as follows:
!Severe error occured, check igzplugin.log logfile!
Error 053: CS.D.AUDCAD.MT1.IP unavailable at this time
Error 055: No bars generated
Logout.. ok..............................................

Can anyone point me to what I am missing? The above epic code (CS.D.AUDCAD.MT1.IP) is as per what I get from the IG API companion, however the above problem persists when I tried Dalla's Asset file (post #477052, 05/07/19)

Will appreciate any help from anyone, many thanks in advance

Re: IG plugin initial release [Re: KKelk] #478587
11/11/19 23:32
11/11/19 23:32
Joined: Nov 2019
Posts: 6
T
TTT Offline
Newbie
TTT  Offline
Newbie
T

Joined: Nov 2019
Posts: 6
Originally Posted by KKelk
Hi everyone, I am a new to this API and am trying to set it up with Zorro 2.15.3.

I have followed all the steps and can see in the log that the API is connecting, but I get this error: "c.danlind.igz.adapter.RestApiAdapter - Exception when getting contract details blocking for CS.D.AUDCAD.MT1.IP, API call failed java.lang.IndexOutOfBoundsException: Index: 0, Size: 0"

On the Zorro print out, its as follows:
!Severe error occured, check igzplugin.log logfile!
Error 053: CS.D.AUDCAD.MT1.IP unavailable at this time
Error 055: No bars generated
Logout.. ok..............................................

Can anyone point me to what I am missing? The above epic code (CS.D.AUDCAD.MT1.IP) is as per what I get from the IG API companion, however the above problem persists when I tried Dalla's Asset file (post #477052, 05/07/19)

Will appreciate any help from anyone, many thanks in advance


Hi there

it seems that you and I are almost at the same stage except you are ahead of me a bit.

I can't get ig plugin to connect. can you please send the contents of your application.properties file for me to see what am i missing??

I already made a post and please check it through my profile. Thnx in advance.

Re: IG plugin initial release [Re: Andy60] #478590
11/12/19 10:27
11/12/19 10:27
Joined: Nov 2019
Posts: 6
T
TTT Offline
Newbie
TTT  Offline
Newbie
T

Joined: Nov 2019
Posts: 6
Originally Posted by Andy60
Hi Dalla

===Configuration===
Win10
MT4 Build 1770
IG Markets Broker with demo and live userid and master password
Java8 Build 211
Zorro 2.09
IG plugin 0.31
2 demo and real api ig keys generated
AssetFix ig modified

application.properties api inserted with this:
plugin.realApiKey=api
plugin.demoApiKey=api
without < and >
=== end configuration

If I select both account's types (real or demo) I see:

TradeTest compiling...........
Login 0 IG..
Can't connect!.

Have u suggestions? Thx for your attention


How did you fix the Can't connect man?

Re: IG plugin initial release [Re: Dalla] #478607
11/13/19 19:07
11/13/19 19:07
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
An advice TTT: one post of sufficient. You've posted the same question in at least three different posts. It won't help get you help any faster

Re: IG plugin initial release [Re: Dalla] #479843
04/30/20 18:06
04/30/20 18:06
Joined: Aug 2017
Posts: 294
Netherlands
G
Grant Offline
Member
Grant  Offline
Member
G

Joined: Aug 2017
Posts: 294
Netherlands
Greetings Dalla,

First of all, I want to thank you for your useful contribution to the Zorro project laugh

I'm running Zorro in a Wine environment, which might play a role in the following problem.
IG isn't selected as a broker when I select a 'demo' or 'real' account in Zorro. In fact, IG is not even on the broker list, far right.

What I also notice, is that Zorro isn't able to open the ig library, when I execute the TradeTest script -> "Error: Can't open ig.dll!".

I've enabled the log functionality in logback.xml, but nothing gets logged.

Please find attached my Accounts.csv setup and the environment variable paths I have made to my Java platform.

Best regards,

Grant

Attached Files IGaccounts.jpgpath.jpg
Last edited by Grant; 05/04/20 17:13. Reason: typo
Re: IG plugin initial release [Re: Dalla] #480024
05/13/20 19:47
05/13/20 19:47
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
Hi, sorry for late reply.
The only reason I know of that would make the plugin not appear in the list is the path to jdk being wrong.

I can see you have a i386 jdk, which is not strictly speaking the same as x86. But I can understand the confusion 😀

Try here
https://adoptopenjdk.net/releases.html?variant=openjdk8&jvmVariant=hotspot

Haven't tried with wine myself but I think it should work

Re: IG plugin initial release [Re: Dalla] #480034
05/15/20 08:24
05/15/20 08:24
Joined: Aug 2017
Posts: 294
Netherlands
G
Grant Offline
Member
Grant  Offline
Member
G

Joined: Aug 2017
Posts: 294
Netherlands
Thank you for your feedback Dalla. We're facing difficult times, so I can understand the late reply smile

I saw multiple Java JRE/JDK alternatives, but I haven't seen this one, so I will give this built a try.

2 questions, does your plugin rely on the Windows version of Java and does it matter if I use a JRE instead of a JDK?

Thank you and stay safe,

Grant

Last edited by Grant; 05/16/20 13:20. Reason: typo
Re: IG plugin initial release [Re: Dalla] #480036
05/15/20 11:48
05/15/20 11:48
Joined: Feb 2017
Posts: 369
D
Dalla Offline OP
Senior Member
Dalla  Offline OP
Senior Member
D

Joined: Feb 2017
Posts: 369
Since Zorro requires Windows I don't think you have much of a choice.

You must use the JDK

Re: IG plugin initial release [Re: Dalla] #481250
08/17/20 08:05
08/17/20 08:05
Joined: Aug 2020
Posts: 59
London
Neb Offline
Junior Member
Neb  Offline
Junior Member

Joined: Aug 2020
Posts: 59
London
Hi,

I have problem with Zorro and IG plugin.
Connection is popping up in dropdown menu.
Already edited:

plugin.demoApiKey

I suppose I should use Web API key , username and pass.
At the moment getting error:

TestConnection compiling...........
Login 0 IG..
Can't connect!

Thanks in advance for help !

Re: IG plugin initial release [Re: Neb] #481510
09/22/20 20:53
09/22/20 20:53
Joined: Feb 2017
Posts: 24
sodiumchloride Offline
Newbie
sodiumchloride  Offline
Newbie

Joined: Feb 2017
Posts: 24
what about the error logfile?

Re: IG plugin initial release [Re: Dalla] #481974
11/29/20 19:19
11/29/20 19:19
Joined: Mar 2017
Posts: 48
Bologna
K
kmerlo Offline
Newbie
kmerlo  Offline
Newbie
K

Joined: Mar 2017
Posts: 48
Bologna
Hi
I ask to someone that use the plugin right.
what is the right combination of versios of Zorro , plugin and SDK?

In the past , i used it in demo.
Today I restart to study the plugin

with the old configuration
zorro: 2.30.7
plugin : 0.31
SDK: jdk1.8.0_241

Zorro it is OK

instead with
zorro: 2.30.7
plugin : 0.32
SDK: jdk1.8.0_241

Zorro doesn't work

in both case for the test I launched the script "Download" and "TradeTest"

PS
sorry for my English, I am Italian


Thanks

Roberto

Attached Files
Download_real.log (172 downloads)
igzplugin.log (172 downloads)
Page 1 of 17 1 2 3 16 17

Moderated by  Petra 

Gamestudio download | chip programmers | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1