Metatrader known bugs ...

To add comments, please log in or register
Mladen Rakic
132587
Mladen Rakic  

This thread is opened as MrPip's idea ...

I suggest the following :
- if someone knows about some bug please report it in this thread

- in the info report the build of the metatrader

- int the info describe the nature of the bug

- if it is possible (not necessary) post an example as simple as it can be so that the other users can check for the bug too

IF someone else has some other suggestions, please post them here

Maybe a thread like this could help us in wasting time looking for coding errors when there is none (coding error)

Mladen Rakic
132587
Mladen Rakic  

Compiler bug ...

This example is simple : it is a compiler error and it extends from build 402 (found one on my PC) to build 419 (current build)

In this case metatrader does not report an error at all (and it should, since array initialize improperly, there are "," miising after "2"), then it reports the size of array wrongly (size 2 instead of 5 - if there is no compiler error, it has to be 5) and after that it somehow pulls "5" as the second element of the test array

the code (same as attached) :

#property indicator_chart_window

double testArray[] = {1,2 3 4 5};

int init() { Comment("Array size : ",ArraySize(testArray)," 2nd element : ",testArray[1]); }

int start() { return(0); }
Files:
_test_2.mq4 1 kb
Bob Fisher
316
Bob Fisher  

Compiler Errors

Here are a few of my pet peeves

1. Old EX4 indicators do not show up in the indicator list. I think it happened when the first 4xx version was released. They do not get recompiled by Metatrader whenever it decides it needs a complete recompilation as there is no MT4 source. Providing the source fixes the problem. But if you purchased an indicator you must get the new version from the vendor to include it in the Navigator list. But it seems that Profiles and Templates that use the old non loaded version do load and execute the "missing" indicator properly.

2. Related, A new MT4 indicator, say obtained as a download, requires one to start Metatrader, shut it down and restart again. During the first execution, the Navigator ceases loading when it identifies the uncompiled indicator.

3. There is an upper limit on the number of indicators displayed in the Navigator. When the limit is reached, the loading ceases. It seems the load requires two cycles, first indicators with MT4 source and then if that is successful, the EX4 only (and only the most recently compiled ones) are loaded. Sometimes the load aborts but it is difficult to detect.

4. Recompilation of all MT4 source code. For some totally unknown reason, the developers decided that there is a condition that requires Metatrader to recompile all of the MT4 files in the Indicator directory. Why they did not use the current profile and recompile only those showing and their associated iCustom calls, is beyond me, probably inexperienced staff as I pointed out in the 418 thread.

All of these issues occurred around the time Metatrader introduced the "protected" executables a year or so ago. I do not have any specific versions to identify

Tzuman

Mladen Rakic
132587
Mladen Rakic  

...

A problem with file names : metatrader does not allow ":" in file names (it is a consequence of XP OS but the problem is that it (metatrader) does not report any error at all, it is simply going to ignore the whole thing and do nothing) Here is an example for a snapshot indicator in which you can choose to use ":" or not, so you can test what am I talking about . If you set the UseColon to true, it will happily work, report no error at all, and do absolutely nothing of what it is supposed to do

Files:
Mladen Rakic
132587
Mladen Rakic  

...

A simple indicator that is showing a bug in the latest build (build 432)

The lower value that is a "mirror like" value of the upper value should not be visible on the chart at all. Indicator minimum and maximum are set to 0 and 2 and the empty value for buffers is set to 0. If you the set the value of any of the buffers to EMPTY_VALUE (0x7FFFFFFF -2147483647) it will do what you see on the example chart, regardless of what you set as the indicators minimal value. If you use any other value other than EMPTY_VALUE (as far as I could test the values) it will work correctly, so it is clearly a bug when EMPTY_VALUE is used as in the example indicator

Attached is the simple indicator that causes that bug to be visible.

Files:
example.gif 21 kb
test.mq4 2 kb
BigBe
228
BigBe  

More on the SetIndexEmptyValue Bug

I have an indicator that I made over a year ago. It worked great before.

With the latest MT builds, to 432, I have a display problem that I cannot fix.

This indicator must use SetIndexEmptyValue, which values get replaced when there is a valid signal. There can be one of two valid symbols, for each direction, which can change.

Now it adds a row of the graphicals (wingding symbols) along the bottom of the screen.

I have tried changing the SetIndexEmptyValue from 99999 to 0, and to EMPTY_VALUE, and even combinations, but it gets no better, and /or I mess up the indicator.

I believe something in MT got broken.

Big Be

BigBe
228
BigBe  

More Bug Reports

There are more bugs reported in this thread starting page 4, https://www.mql5.com/en/forum/181236, some of which have been fixed.

And thank you for the fixes, Metaquotes staffers.

Big Be

Mladen Rakic
132587
Mladen Rakic  

...

What, per moment, anoys me the most, is that I always have to close the metaeditor before downloading or externally opening a code (which, before I was able to do directly into metaeditor regardless if it was opened or not). Since some of the upgrades (not sure exactly which one, since there were so many) it simply refuses to read in the code if metaeditor is already opened and you try to read in a code outside the regular "open" menu

BigBe
228
BigBe  

MetaEditor

mladen,

Not quite sure what you mean. I can still drag an MQ4 file from Explorer into MetaEditor, build 432.

Big be

Mladen Rakic
132587
Mladen Rakic  

...

Big Be

I can too, if my metaeditor is not opened at the moment when i, for example, click on a mq4.

If my metaeditor is already opened (I am editing some code at that moment, for example), it simply ignores what I have tried to open and does nothing. I have to close metaeditor and then if I click on the same mq4 again it will read it in in metaeditor.

The funny thing is that metatrader 5 (and metaeditor 5) work just fine. I do not know when exactly did it sart doing so since there were so many new builds that I have not noticed it with which exact upgrade (or exactly when) it started to do it to me

Big Be:
mladen,

Not quite sure what you mean. I can still drag an MQ4 file from Explorer into MetaEditor, build 432.

Big be
Mladen Rakic
132587
Mladen Rakic  

...

This one is from metatrader 5 :

If you want it or not, if you make a separate window indicator metatrader 5 patches a level 0 to it. It would be partially OK if you could do something about it, but you can not. It is not in the list of levels, you can not remove it from the code, you can not do anything ... It is so from the start of metatrader 5 and they haven't corrected it ever since. If I want a level I will put it there. Here is an example of a built in stochastic that gets that phantom level patch to it too and it is clearly visible from the list of levels that it should not be there :

Files: