Update: Closing matlab and restarting my computer seems to fix the problem temporarily. Now when I enter a nonsense command such as ttt, the "Undefined function or variable 'ttt'" error appears immediately. But I've experienced the delay on more than one day leading me to believe there's some bottleneck that develops across time. Perhaps this forum isn't the best place to report potential issues on new releases(?).
>40 seconds waiting for Undefined function or variable error 2017b
19 ビュー (過去 30 日間)
古いコメントを表示
I'm using matlab 2017b on a windows 7 64 bit machine and when I accidentally reference a variable or function that doesn't exist, Matlab consumes a significant amount of time in 'busy' mode before throwing the error: 'Undefined function or variable'. I've paused the execution a few times to see where the bottleneck is and it has always opened the findUnlicensedFunctions() function. To cause this error, I type in any nonsense command such as "ttt" in the command window where ttt does not refer to any function or variable. Using tic/toc just before and after the call to ttt resulted in 43 seconds waiting for the error. Is anyone else experiencing this or might it be specific to my environment? I upgraded last week from 2016a and did not have this problem before.
3 件のコメント
採用された回答
Adam Danz
2018 年 4 月 22 日
編集済み: Adam Danz
2019 年 8 月 25 日
1 件のコメント
Borja Prieto
2022 年 5 月 18 日
Hi there,
I am a PC, R2020a user, and your function/GUI worked like a charm for me!
Thanks a million!
その他の回答 (6 件)
Jakub Krizan
2018 年 4 月 3 日
I have never experienced this issue in Matlab 2017b, but it started to happen since I have upgraded to Matlab 2018a. The behavior is the same as Adam Danz describes. I am using Windows 10 64bit (build 1709)
Mary Abbott
2017 年 11 月 2 日
Thank you for reporting this. We have been able to reproduce this on our end, and I have forwarded the details to our development team so that they can investigate it further.
0 件のコメント
Jose
2018 年 9 月 27 日
編集済み: Jose
2018 年 9 月 27 日
Today I installed the 2018b version and the problem is still there. So, I installed it, I ran it and I typed in the command line a variable that I didn t declare before, >> r and enter and it took 1 minute almost 2 to answer: Undefined function or variable 'r'.
Someone in Matlab is taking actions? I am really fed up of it.
ElCapitan OS
2 件のコメント
William Babbitt
2019 年 1 月 13 日
編集済み: William Babbitt
2019 年 1 月 13 日
I am also experiencing this problem - Long (~ 1 minute) wait for error of undefinted variables/funtions. This started after I installed 2018b. It also may be related to running a script from our server (though the server is not in my path anymore). The problem goes away if I disconnect from the internet, but that is not a practical solution.
EDITED COMMENT
Solution was posted at https://www.mathworks.com/matlabcentral/answers/395876-undefined-function-error-is-very-slow-to-occur?s_tid=answers_rc1-2_p2_MLT
It was not my path, but my history. Running these commands solved it:
s = settings;
s.matlab.desktop.currentfolder.History.PersonalValue = {''}
Zachary Eilon
2019 年 8 月 28 日
This solution did not fix it for me - I think the history is saved somewhere else, so as soon as one navigates to a new directory, it repopulates even having cleared it with the above code. However, selecting "Clear History" under the "Current Folder" tab of the MATLAB preferences did the trick for permanently clearing the history.
Jose
2018 年 10 月 15 日
In my case is solved. I was using external hard drives (usb connected). It turns out that by accident the power supply was off and I noticed that I was not having latencies anymore. I connected them and the latencies were there again. I am happy because I am not dealing with that delays anymore but in the other hand I can not use my hard drives during my working day with Matlab which is not nice.
0 件のコメント
Ryan Santos
2019 年 8 月 30 日
Hey all,
First off, sorry for the problems everyone has been facing with the error recovery system. We added the feature in 2017b where upon encountering an unknown function or identifier, MATLAB will search through a users "current working directory" history and make suggestions based on that. Unfortunately what could sometimes happen is that some items in that history could no longer be accessable, causing the delay you're seeing here.
The workaround, as you already know, is to remove those problematic directories from your history. Though we understand that it is still frustrating and not always realistic since some directories could become innaccessable as your working and still cause an initial delay. We've been seeing more and more of this feedback from customers, so we are going to take some steps to try to alleviate this problem in a future release. We're working on it!
Thanks,
Ryan Santos
0 件のコメント
参考
カテゴリ
Help Center および File Exchange で Entering Commands についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!