Bug Reporting

All posts which do not fit into any other sections of the forum.

Moderator: admin

Re: Bug Reporting

Postby moomoofx » Wed Nov 20, 2013 9:28 am

I have now found on two occasions my LIVE strategies getting their configuration messed up. This is pretty serious because tweaking these configurations can easily lead to significant losses.

I don't have a list of steps to reproduce, but I suspect the problem is related to having multiple instances of the same strategy running (on different currency pairs for example) and somehow the configuration gets messed up. Either it's not saving properly, or modifying one is impacting other one etc etc.

Anyone else noticed this?
User avatar
moomoofx
FXCodeBase: Confirmed User
 
Posts: 193
Joined: Wed Oct 23, 2013 10:26 pm
Location: Okinawa, Japan. http://moomooforex.com

Re: Bug Reporting

Postby Apprentice » Wed Nov 20, 2013 3:09 pm

It is completely possible that a strategy will close open positions in the same currency.
Most of the old strategy does not recognize position by creation type.
User avatar
Apprentice
FXCodeBase: Confirmed User
 
Posts: 36341
Joined: Thu Dec 31, 2009 11:59 am
Location: Zagreb, Croatia

Re: Bug Reporting

Postby moomoofx » Wed Nov 20, 2013 5:10 pm

Hi Apprentice,

Not sure if that post was in reply to my comment, but if so I'd like to clarify. I'm not talking about opening/closing trades clashing between different instances of strategies running. I mean the actual configuration is getting messed up.

For example, suppose I had one instance of STRATEGY running on AUD/JPY and it had a parameter called Stop, which was set to 60 pips. Then I had another instance of STRATEGY running on USD/JPY, and it had a parameter called Stop set to 100 pips.

I'm not sure what happens, but at some stage their 'configuration' becomes messed up, so in this example let's say suddenly the AUD/JPY STRATEGY ends up with a Stop of 100 pips.

Just asking if anyone else has noticed this.
User avatar
moomoofx
FXCodeBase: Confirmed User
 
Posts: 193
Joined: Wed Oct 23, 2013 10:26 pm
Location: Okinawa, Japan. http://moomooforex.com

Re: Bug Reporting

Postby Valeria » Thu Nov 21, 2013 10:59 pm

Hi moomoofx,

For example, suppose I had one instance of STRATEGY running on AUD/JPY and it had a parameter called Stop, which was set to 60 pips. Then I had another instance of STRATEGY running on USD/JPY, and it had a parameter called Stop set to 100 pips.

I'm not sure what happens, but at some stage their 'configuration' becomes messed up, so in this example let's say suddenly the AUD/JPY STRATEGY ends up with a Stop of 100 pips.


It looks like the issue is in the code of your strategy. Possibly, the default value of stop is 100. And in the particular moment the strategy sets it to default and then does not set it back to 60.
Or maybe you just accidentally mixed the strategies and manually changed the options of the other strategy instance.
Valeria
 

View indicators bug

Postby robocod » Fri Jan 17, 2014 12:09 pm

I am using the View Indicator example from the SDK, and I noticed that trades are not placed correctly on the chart. See the attached screenshot.

screenshot.png


The trade was placed today, but the arrows for the trade P/L are on yesterday's candle.

I suspect the routine for drawing the trade positions / history is not calculating the date correctly.

In the screenshot I also comment on an error with the View Indicator example itself - the pips are a factor of 10 out, but I will raise that in the Indicator Development section.
User avatar
robocod
FXCodeBase: Graduate
 
Posts: 298
Joined: Thu May 10, 2012 4:25 pm

Two strategy instances messed up

Postby mstreck » Fri Jan 17, 2014 12:57 pm

Hi,

running two instances of the same strategy on two different instruments, there is a mess-up of variables between the two instances.

The test case is that I applied the first instance of a GRAB strategy on EUR/USD. The debug message marked in red at 17:19 below is the last line of code of Prepare().

At 17:20, I started a second instance of the same strategy on USD/JPY. Although the user menu already correctly names it GRAB Strategy #2, the debug message does not align to the second instance, but to the first instance name. Afterwards,when the first instance triggered a market entry, it did it on USD/JPY, and not on EUR/USD, which means that the OfferID variable of the first instance must have been overwritten by the Prepare() routine of the second instance.

See attached screen shot.

I have used multiple instances in the past without this Problem. Please advise.

I know I can generate multiple copies with Instrument name being part of the file name as a work-around. Still, please advise on this wrong behaviour.

Thanks,
Martin

P.S. This is apparently the same issue reported earlier in the post by MooMooFX.
P.S. 2: The GRAB strategy is not the one from the site, it is a modified implementation, but still, you can test case this yourself by verifying that variables will get written over in the first instance running from the second instance once getting started up.
Attachments
BUG.zip
(273.36 KiB) Downloaded 1128 times
mstreck
FXCodeBase: Initiate
 
Posts: 161
Joined: Wed May 30, 2012 1:42 am

Re: Bug Reporting

Postby moomoofx » Mon Jan 20, 2014 7:46 am

Nice work Martin, good to see someone else find the same bug. Valeria, I don't think this has anything to do with my strategy but it is worth mentioning that I haven't seen it happen in a while either.
User avatar
moomoofx
FXCodeBase: Confirmed User
 
Posts: 193
Joined: Wed Oct 23, 2013 10:26 pm
Location: Okinawa, Japan. http://moomooforex.com

Re: Bug Reporting

Postby Valeria » Mon Jan 20, 2014 7:49 am

Hi robocod,

Thank you for the report. We will further investigate the bug. Currently it looks like there are several defects in views:
1. A trade is displayed on the previous day;
2. Ruler works incorrectly;
3. View ignores Fractional pip Format option.
Valeria
 

Re: Bug Reporting

Postby robocod » Mon Jan 20, 2014 12:27 pm

Valeria wrote:Hi robocod,

Thank you for the report. We will further investigate the bug. Currently it looks like there are several defects in views:
1. A trade is displayed on the previous day;
2. Ruler works incorrectly;
3. View ignores Fractional pip Format option.


I found a couple more issues.
4. Export to Excel or Indicore (when using a View Indicator) crashed MarketScope & Trading Station
5. I use the "Show current market price" option on my charts. When I am using a View Indicator, it only seems to show the line at the Bid price, even though I have the chart set to using the Ask prices.
User avatar
robocod
FXCodeBase: Graduate
 
Posts: 298
Joined: Thu May 10, 2012 4:25 pm

Re: Bug Reporting

Postby Valeria » Mon Jan 20, 2014 10:18 pm

Hi mstreck,

It would be great if you send me (via PM or e-mail) your strategy or at least the snip of code which describes the work with offers (how the strategy gets them and stores).
Valeria
 

PreviousNext

Return to General Discussions

Who is online

Users browsing this forum: No registered users and 5 guests