Thanks for the screenshots.
In the screenshot where ‘// Database Credentials’ is displayed, I am assuming this line of code is generated by Copilot4Eclipse and not committed to the editor’s document/file. If yes, this is a code suggestion generated by Copilot4Eclipse. Code suggestions are displayed in a light gray text color known as ghost-text and is not actually part of your document until you accept/commit it. Also know that code suggestions are ephemeral and will disappear when you move your cursor. If you hit the TAB key when a code suggestion is being displayed, the suggestion will be insert into the editor as proper text at the current cursor location. After that it can be saved.
See Brian’s video at the 35 second mark, https://www.youtube.com/watch?v=q2dhnulEYFk&t=2s
If you are already committing code suggestions into your editor’s document, then there could be an error. If that is the case please check the Eclipse Error Log view for any interesting log messages that may appear when saving your document. Share any details here and we can work with that info.
Wayne
Copilot4Eclipse Team