Test Code Completion has been added to Pharo 8!

Myroslava Romaniuk
2 min readJul 2, 2019

--

Short version: we added an intermediate version of code completion and it would be cool if you tested it.

In the settings, by typing up ‘completion’ in the search bar, you can see the different completion options, which now should read as NECController, which is the main code completion used in Pharo by default, and TestCompletionController, which is the one we now added. Choose the second option and let us know what works and what doesn’t. Now, in more detail about what specifically did we implement:

The test version of code completion still heavily reuses the models of the old completion (models plural, as in typed, untyped and empty NECModel subclasses — more can be read about here under point #2). We had been playing with creating a single model for the new completion by ourselves, in the obvious quest to simplify the architecture, and only last Friday did we manage to make a model that more or less works for both the Playground and the (Calypso) Editor, which is quite amazing and a big step forward, but! It is still unstable enough for us to keep working on it, and so instead, the intermediate version is with the old models. However, in the intermediate version the typing implementation is our own (we don’t need the SHParserST80 and instead just use AST) and thus it’s already fun to test it and it gives a good sneak peak into what the future completion will be like.

So for us it would be cool if you started using this test version while working in Pharo (it’s stable enough that it shouldn’t break) and report your results and give us your feedback. For example, there’s an “issues” section on github (link) where you can submit your ideas for what to fix or improve, and of course, there’s twitter, the mailing list, discord, or the comment section here.

Now, a more detailed explanation regarding how to enable it in Pharo:

Option 1. (already mentioned) Go to Settings Browser, search for ‘completion’ in the search bar.
Option 2. Go to Settings Browser, expand the Code Browsing section, and then expand the Code Completion section.

After performing either of the two above steps, select a controller to use. TestCompletionController if you want to give our completion a try, NECController to go back to the default. See screenshot:

selecting the right controller, which determines which completion you are using

That’s it with updates! More useful links:

  1. pull request of the test completion into Pharo 8 — link
  2. more about the whole roadmap of the project — link

-M

--

--

Myroslava Romaniuk

CS grad. wannabe blogger. two-time social media quitter. she/her