Why is Eclipse's HTML viewer randomly showing previous output and an error? - eclipse

Well, this video shows my problem best : http://www.youtube.com/watch?v=yDeChV254Ck&feature=youtu.be
If I have a page that is proper/ok, everything works fine and as expected.
If I purposely induce an error (which I have been doing loads of whilst learning!), Eclipse doesn't show an error at all inline/red underline, and, when I try to run, it will either display an error (which I expect it should be doing every time), or it will randomly display the last successful build.
I can (remotely) understand the logic of alternating, maybe someone would want to see the previous output, but, this is just completely random - no logic at all, so, I just don't understand why it is happening.
Does anyone know what is going on?
edit - been able to recreate this on a brand new install. What is going on!?

Related

VSCode exits while debugging a flutter app

It seems like vscode is trying to present data in the Locals and/or Watch for a large object but after about 10 seconds, it will kill the app and give the message "Exited (sigterm)" in the debug console. I can pinpoint it to one example where I break on a line immediately after this line:
Uint8List inputBytes = Uint8List.fromList(List.filled(100000000, 0));
I can see "Locals" spinning around but nothing happens and then the app terminates. Is there a setting that can prevent this somehow? Maybe it can cap the represented data at a certain length instead of trying to print it all out?
(I believe this is a vscode specific problem because when I repeat these steps in Android Studio, it doesn't have this issue)
Thanks.
This is a bug in the debug adapter. It should know this is a list and fetch a paged view of the elements, but it's currently fetching them all. For me it doesn't crash, but it also doesn't respond within several minutes.
I'm working on a fix that will let VS Code page through the data:
This will ship in an upcoming Dart/Flutter SDK release.

Confusing error from libasound function snd_pcm_hw_params

My question has to do with the libasound function named "snd_pcm_hw_params" in connection with code to play a sound file. I am new to ALSA programming. Using a coding example I found on the internet, I wrote a small program to play a 7 second .wav file to the default sound card. When I run this code several times in a row, occasionally (but not always) the requisite call to snd_pcm_hw_params to write the previously filled in snd_hw_params_t struct to the driver, I get back an error code of -2 (ENOENT). I have no idea what this means, nor how to handle nor prevent it. My code just emits an error message and bails. Usually, if I run it again, the code runs fine. Its fine for my use, but eventually, this code is supposed to be given to a non-programmer to use, and I'd like to either prevent the error, or resolve it internally without involving said non-programming user. I note hear that the user is supposed to be able to cause an early abort of the program by clicking a button, and when this happens, my code calls snd_pcm_drop, followed by snd_pcm_close. If the program runs to completion, and plays all 7 seconds of the wav file, then it finishes up by calling snd_pcm_drain, followed by snd_pcm_close. Any help or suggestions would be greatly appreciated. :)

Suddenly conv.user.storage data is not persisting or acting in a strange way

Conv.user.storage data is not persisting, when using an alpha tester account it resets every time. When using the simulator the data goes back to some snapshot it took at some point and has some values associated with a previous session.
I know this is vague but I was wondering if anyone ever had this problem.
I'm guessing the most reliable solution is to just use Google sign in if you are in anyway depending on that conv.user.storage data, is that right?
Let me add this snippet from Response section in the simulator, here you can user storage in the middle of the game, then I close and start again and all the values change completely going to a previous set of values from some point in the past, but this same set of values appears no matter how many times I reset, how can user storage find some previous snapsnot of values like this?
Before:
"userStorage": "{\"data\":{\"questionorder\":\"19,29,27,18,30,20,16,22,12,11,17,28,14,25,6,21,8,4,5,3,1,23,10,26,13,24,7,2,15\",\"thisquestionnum\":9,\"randmozier\":true,\"visited\":true,\"questioncode\":111,\"popularity\":50,\"population\":100,\"rounds\":1}}"
After:
"userStorage": "{\"data\":{\"questionorder\":\"5,20,13,18,6,19,12,9,1,21,11,10,22,25,24,8,14,3,16,17,7,26\" ,\"thisquestionnum\":4,\"randmozier\":true,\"visited\":true,\"questioncode\":111,\"popularity\":30,\"population\":100,\"rounds\":2}}"
What is weird about this is, no matter what user storage starts out at, it will return to the second "After" values if I restart the game -- nowhere in the code is this being set, it's a previous set of values from some point, how can this issue suddenly appear?
I have even reset the code back 1 month so it is not possible at all to choose up to 26 questions like is shown in "questionorder" above -- but still it returns to that second state of user storage which is impossible in the code as it is, this is some major error in actions-on-google library or something which has changed in the last few days, has anyone had this issue with conv.user.storage?

GWT Selenium Tests sometimes fails

we currently have a nice problem with our selenium tests in a gwt powered gui.
The application contains two sections (filter and grid). Our tests sometimes fails with a NoSuchElementException.
Crazy is the following: I stop the test in eclipse with a breakpoint and inspect the page with firefox firebug or any other addon. And okay - I cannot find the desired element. But (without restarting the application or any other changes in eclipse), if i try again and search the element it is there and a resume in eclipse the test goes green. For me it seems like a synchronize problem in firefox.
A explicitly wait command
new WebDriverWait(getDriver(), 10).until(condition);
has the only effect, that the timeout (10 seconds) happens.
As I said - sometimes the test is green and sometimes it fails.
Has anybody an idea?
Sounds like you load some data asynchronous (RPC) from the server? The data and thus the element which presents the data in the UI is not there yet, when Selenium is looking for it. Depending on how long your queries take on the database or what latency you have on the network the wait time may vary from test-run to test-run.
I have a workaround for this problem and would share this.
The following piece of code is executed before the explicit wait command is running.
Window window = getDriver().manage().window();
Dimension dimension = window.getSize();
Dimension tmp = new Dimension(dimension.getWidth() - 1, dimension.getHeight());
window.setSize(tmp);
window.setSize(dimension);
I figured out, that the DOM is in "synchronized" state after the browser window is resized. So I decrement the width and than set it back to the old value.
If anybody has a better suggestion - let us know ;-)

Crystal Report takes a LONG time to load through app, but in VS 2008 it's fast

I have a report that is taking about 10 minutes to load when opened through the application, but only 2 seconds when opened through VS 2008. There are many other reports which all work fine and I don't know what could be different about this one.
In the application, all of the code to load and setup the report runs fine but when I launch the form that has the viewer on it it displays the form, but hangs for several minutes before the report comes up. It's clear that it's not the query itself that is the problem since it only takes a second to run in VS, and all that is on the form is just the viewer.
After setting up my report into a variable named rDoc, I run the following code:
CrystalReportViewerForm frm = new CrystalReportViewerForm();
frm.CrystalReportViewer.ReportSource = rDoc;
Application.Run(frm);
CrystalReportViewerForm has the viewer control on it, and a public property called CrystalReportViewer that exposes the viewer so the calling code can set the ReportSource before opening the form, as you can see in the code. That is literally all the form consists of. When Application.Run(frm); is run it shows the form and viewer, but the report doesn't load for about 10 minutes.
If anyone else has run into this and solved it please let me know what you did!!
Thanks!
I'll go ahead and post the way I fixed it here in case it helps anyone, but I'd still like to hear if anyone else knows what the problem actually is...
My report was using the built in features of CR to select tables with data expert. I got rid of all the tables and added a command with the sql needed to get the data. This solution would obviously be faster because it doesn't return as much data and the processing is all done in SQL. However, it worked fine the way it was when run through VS so I know that's not the whole of the problem. At least it works now though.