-
Notifications
You must be signed in to change notification settings - Fork 49
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Client-side improvements #1470
Client-side improvements #1470
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM but I haven't tested it.
Thanks John. I will give the issue reporter at least a few days to respond. |
Hi @isc-bsaviano, Thank you for your quick changes. Deleting and discard:
Adding and discard:
Modified:
Findings:
Some feature requests: |
@TwaHendrik Thank you for testing this! I'm glad that most of your issues have been resolved.
I will try to reproduce this.
The classes should only be compiled once, so if they are being compiled more than once then there's a bug. The compilation works by batching as many documents into one request as possible, until there's been 500ms with no activity. The the batch of documents is sent to the server to compile. The only exception is if the document in the active text editor is being compiled. In that case, that document and any others in the batch are compiled right away to avoid any perceived latency when a user saves the document they are working on. I might have to remove that special case and increase the delay so more batching occurs.
This has been considered in the past. I haven't done it because I'd have to ping the server a lot to make sure that decoration is accurate. |
I tried to reproduce this but I'm not sure what to do. If a file is created outside of VS Code then we won't try to sync it when VS Code starts up. Files are only synced when they are created/changed/deleted while VS Code is running. If VS Code is running but the server connection is inactive, VS Code will not attempt the sync. |
We have shut down the IRIS instance and thus deactivated the connection. Then we edited a file in VS Code and thus triggered an incositence between the client-side workspace and IRIS. Then we started IRIS again and VS Code tried to transfer the document to IRIS. The error message was then thrown. We have surmised that the extension is trying to retransmit the document after the connection has been activated again in order to resolve the inconsistency. If this function is not available, the point can be ignored. |
I just checked and the extension is not doing this automatically. If the server connection is inactive at the time the change was made, the change is not stored for later. Re-activating a server connection will not prompt a sync with the server. If you manually triggered a sync (by editing and saving the file or importing it) then I will try to replicate exactly what you did so I can see that error. |
Hi @TwaHendrik, can you test this vsix and let me know if it fixes your multiple-compile/locking race condition issue? |
Hi @isc-bsaviano, unfortunately the error is still there. We have saved only one class in vs code via ctrl + s and the class has been compiled 10 times. The output is:
For the error message
We have investigated the occurrence of the error message. We use a class extends %Studio.Extension.Base with OnBeforeCompile. This performs a static code analysis with every compile. This ensures a longer compilation time, which increases the probability of conflicts occurring during multiple compilation. However, we could not trigger Error 5864 without our %Studio.Extension.Base. It could be an indication that the possibility of this error is higher for large classes that take longer to compile. However, the problem of multiple compilation (without the error 5864) is independent of %Studio.Extension.Base. |
Thank you for testing again, and for the extra details. I'm still not able to replicate the multi-compile. Here's what I did:
Do you only see that 5864 message in the compiler output, or does it occur as a response to another request as well? For example, we make a GET |
Hi @isc-bsaviano , we perform a very simple test. Create a new class and save via ctrl + s
Compile 3 times.
We remove the property and save via ctrl + s
Compile 2 times.
Add a new ClassMethod and save via ctrl + s
Compiling error
We perfom the test on an empty iris instance. |
I have not heard from Hendrick in a while and have yet to reproduce his issue. I'd like to get this in since it's still an improvement. I can implement a fix for his issue in a new PR if it can be reproduced. |
This PR addresses feedback from a DC beta tester.
EMFILE
errors.