Commit Graph

421 Commits

Author SHA1 Message Date
Adam Obuchowicz
e8077253c9
Finish integration refactoring (#3206)
All other things from the old integration layer were rewritten to some kind of presenter. The big integration module was removed.
2021-12-29 13:44:13 +01:00
Michał Wawrzyniec Urbańczyk
66c256a1f7
Self-hosted Engine CI for Windows and Linux (#3182) 2021-12-27 17:56:35 +01:00
Ilya Bogdanov
90ddba15dc
Add source maps for JS and TS files (#3204) 2021-12-27 09:32:23 +01:00
Ilya Bogdanov
fc953ec055
Fix regression in names of the template-based projects (#3201) 2021-12-24 11:29:06 +03:00
Mateusz Czapliński
895291876c
Fix problems related to error visualisation evaluation (#3193)
- Add parser & handler in IDE for `executionContext/visualisationEvaluationFailed` message from Engine (fixes a developer console error "Failed to decode a notification: unknown variant `executionContext/visualisationEvaluationFailed`"). The contents of the error message will now be properly deserialized and printed to Dev Console with appropriate details.
- Fix a bug in an Enso code snippet used internally by the IDE for error visualizations preprocessing. The snippet was using not currently supported double-quote escaping in double-quote delimited strings. This lack of processing is actually a bug in the Engine, and it was reported to the Engine team, but changing the strings to single-quoted makes the snippet also more readable, so it sounds like a win anyway.
    - A test is also added to the Engine CI, verifying that the snippet compiles & works correctly, to protect against similar regressions in the future.

Related: #2815
2021-12-21 10:00:57 +01:00
Adam Obuchowicz
567ddd701c
Developers should find the ide-gui controller codebase logical and easy to work with. (#3188) 2021-12-15 13:40:14 +03:00
Mateusz Czapliński
050e52bfcc
Fix some edits not being sent to LangServ (#3186)
Some edits were not being sent by IDE to Language Server, resulting in 3003 "Invalid version" errors being returned by LangServ, and forcing full invalidation (resynchronization) of text contents in LangServ.

This change fixes such errors observed when opening a new project, creating a new project, or adding a new node to a project. 

Fixes #3094

### Important Notes

The root cause showed up to be actually two separate issues, both of them reproduced by an "opening a new project" scenario:

 1. The automatic addition of `import Standard.Visualization` line, [done internally when opening a new project in `controller::Project::initialize()`](c14a2d8169/app/gui/src/controller/project.rs (L137-L141)), was not reaching the Language Server. The cause of it was a race condition with [`self.model.subscribe()` in `Module::runner()`](c14a2d8169/app/gui/src/model/module/synchronized.rs (L268)). In particular, the addition of the import was executed before the subscription, which resulted in an edition notification being lost and not sent to LangServer. The fix employed for this is to make the `subscribe()` call synchronous during the initialization of a project, instead of scheduling it for a non-deterministic later time.
 2. There was [a bug in `synchronized::Module::edit_for_snipped()`](7467efda59/app/gui/src/model/module/synchronized.rs (L362)), making it erroneously "optimize out" any code insertions detected by `TextEdit::from_prefix_postfix_differences()`. The fix employed for this was to improve the "optimizing out" condition, together with adding an accompanying test case verifying correct behavior (protecting against a future regression).

Additionally, as a drive-by improvement, some statements in `ParsedSourceFile<>::serialize()` were reordered, to make them better match how the actual contents of an .enso file are structured, and thus make it easier to read/analyze the code.
2021-12-13 18:18:20 +01:00
IsaacTell
10dac4fb21
Fix links to gui folder (#3190) 2021-12-12 23:43:25 +01:00
Ilya Bogdanov
81d6338cef
Finish up Rust Welcome Screen (#3167)
The old JS-based Welcome Screen was removed and replaced with the Rusty one.

Co-authored-by: Adam Obuchowicz <adam.obuchowicz@enso.org>
Co-authored-by: Adam Obuchowicz <adam.obuchowicz@luna-lang.org>
2021-12-11 00:01:45 +03:00
Mateusz Czapliński
5e5abac8ae
Register Views before creating them (#3181) 2021-12-08 10:11:58 +03:00
Mateusz Czapliński
a704baf91c
Minor CONTRIBUTING tweaks after onboarding (#3178) 2021-12-06 15:45:10 +03:00
Adam Obuchowicz
c4d22102cf
Switch to 2021 edition (#3173) 2021-12-01 16:06:57 +01:00
Adam Obuchowicz
215cd76bce
After creating a new project, nodes are not laid out. (#3174) 2021-12-01 14:25:48 +01:00
Adam Obuchowicz
850a16cb40
Fix location_of_text_end method (#3170) 2021-12-01 09:12:42 +00:00
Ilya Bogdanov
73abebf7aa
Add Root View and Welcome Screen View (#3164) 2021-11-30 16:23:46 +01:00
Adam Obuchowicz
99b0c46d87
While testing, developers should not have to wait for each crate to be re-built. (#3168)
Split all the EnsoGL components, examples and debug scenes to separate crates, so the work on the single component should be quicker than before.
2021-11-30 12:27:50 +01:00
Ilya Bogdanov
d44ca85197
Refactor integration level so "no project opened" state is possible (#3160)
* refactor: remove invalid comment in ide/lib.rs

* refactor: current_project() returns Option

* refactor: create IDE controller without project

* refactor: handle missing project param in Cloud environment

* refactor: store project name in searcher

So no need in current_project call

* chore: apply rustfmt

* chore: fix tests

* refactor: rename maybe_project_name to project_name

* refactor: move project_name to BackendService::LanguageServer

* refactor: do not use early return in integration.rs

* refactor: use CloneCell instead of RefCell for current_project

* refactor: store model::Project in Searcher controller

* refactor: use expect instead of unwrap in searcher tests

* feat: add new_with_project_model constructor for desktop controller

It might be useful in tests

* chore: fix searcher tests
2021-11-30 11:48:12 +03:00
Adam Obuchowicz
9ab4f45e72
Refactored enso-data crate and text utilities. (#3166) 2021-11-25 11:45:42 +01:00
Ilya Bogdanov
787a2c78e1
Fix link to Rust style guide (#3128) 2021-11-22 12:14:30 +00:00
Ilya Bogdanov
03c85d780e
Colorful Histograms (#3153) 2021-11-18 14:17:38 +00:00
Adam Obuchowicz
bb3b145af5
Refactor gui/src/rust/ide to two app/gui and app/ide-desktop (#3157) 2021-11-16 10:04:56 +01:00