Skip to content

Lite Terminal: syntax color pasted input that ends with a newline - #1866

Merged
isc-klu merged 19 commits into
intersystems-community:masterfrom
isc-klu:fix/paste-coloring
Sep 9, 2026
Merged

isc-klu merged 19 commits into
intersystems-community:masterfrom
isc-klu:fix/paste-coloring

Conversation

@isc-klu

@isc-klu isc-klu commented Sep 9, 2026

Copy link
Copy Markdown
Collaborator

Fixes #1862 by treating a pasted input that ends with a newline as the same input without it, followed by a 100ms wait and then Enter. The wait gives the syntax coloring time to arrive before the submit moves the input off the current line.

Also tightens the types:

  • WebSocketMessage is now a discriminated union, removing the message.text! / message.ns! assertions.
  • currentNs becomes optional, since ns is only sent by IRIS 2025.3+.

Verified against IRIS 2026.3 with the reproduction from #1862.

@isc-klu isc-klu changed the title Fix/paste coloring Lite Terminal: syntax color pasted input that ends with a newline Sep 9, 2026
@isc-klu
isc-klu marked this pull request as ready for review September 9, 2026 21:47
isc-klu and others added 2 commits September 9, 2026 17:58
A pasted input that ends in a shell-integration submit marker was never sent
for syntax coloring at all: the coloring request sat in an `else if` branch that
only ran when the input wasn't being submitted.

Requesting the coloring unconditionally isn't enough on its own, because
submitting writes a newline, so a coloring that arrives afterwards would repaint
the input over the output. Wait briefly for the coloring before submitting, and
discard one that still arrives too late.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Every field but `type` was optional, so reading any of them needed a non-null
assertion. Spelling out one member per message type lets the compiler tell
which fields a message actually has.

`currentNs` becomes optional to match: `ns` is only sent by IRIS 2025.3+, so
the old `message.ns!` was writing `undefined` into a field declared `string`.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@isc-klu
isc-klu merged commit f6b82c5 into intersystems-community:master Sep 9, 2026
5 checks passed
@isc-klu
isc-klu deleted the fix/paste-coloring branch September 9, 2026 23:04
ricxJr added a commit to consistem/vscode-objectscript that referenced this pull request Sep 11, 2026
* Bump fast-uri from 3.1.0 to 3.1.2 (intersystems-community#1779)

Bumps [fast-uri](https://github.com/fastify/fast-uri) from 3.1.0 to 3.1.2.
- [Release notes](https://github.com/fastify/fast-uri/releases)
- [Commits](fastify/fast-uri@v3.1.0...v3.1.2)

---
updated-dependencies:
- dependency-name: fast-uri
  dependency-version: 3.1.2
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Bump axios from 1.15.0 to 1.15.2 (intersystems-community#1778)

Bumps [axios](https://github.com/axios/axios) from 1.15.0 to 1.15.2.
- [Release notes](https://github.com/axios/axios/releases)
- [Changelog](https://github.com/axios/axios/blob/v1.x/CHANGELOG.md)
- [Commits](axios/axios@v1.15.0...v1.15.2)

---
updated-dependencies:
- dependency-name: axios
  dependency-version: 1.15.2
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Kuang-Chen (KC) Lu <klu@intersystems.com>

* Bump @nevware21/ts-utils from 0.12.5 to 0.14.0 (intersystems-community#1785)

Bumps [@nevware21/ts-utils](https://github.com/nevware21/ts-utils) from 0.12.5 to 0.14.0.
- [Release notes](https://github.com/nevware21/ts-utils/releases)
- [Changelog](https://github.com/nevware21/ts-utils/blob/main/CHANGELOG.md)
- [Commits](nevware21/ts-utils@0.12.5...0.14.0)

---
updated-dependencies:
- dependency-name: "@nevware21/ts-utils"
  dependency-version: 0.14.0
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Bump ws from 8.20.0 to 8.20.1 (intersystems-community#1786)

Bumps [ws](https://github.com/websockets/ws) from 8.20.0 to 8.20.1.
- [Release notes](https://github.com/websockets/ws/releases)
- [Commits](websockets/ws@8.20.0...8.20.1)

---
updated-dependencies:
- dependency-name: ws
  dependency-version: 8.20.1
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Bump axios from 1.15.2 to 1.16.0 (intersystems-community#1789)

Bumps [axios](https://github.com/axios/axios) from 1.15.2 to 1.16.0.
- [Release notes](https://github.com/axios/axios/releases)
- [Changelog](https://github.com/axios/axios/blob/v1.x/CHANGELOG.md)
- [Commits](axios/axios@v1.15.2...v1.16.0)

---
updated-dependencies:
- dependency-name: axios
  dependency-version: 1.16.0
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Reinstate reconnect option from status bar panel of isfs-type workspace (fix intersystems-community#1787) (intersystems-community#1788)

* Update status of document after running server-side source control action on it when `respectEditableStatus` is set (intersystems-community#1792)

* Ensure cookies are always fresh before starting a Lite Terminal (intersystems-community#1793)

* Update release CI script to use `softprops/action-gh-release@v3` for Node 24 compatibility (intersystems-community#1790)

* Prepare 3.8.2 release (intersystems-community#1794)

* auto bump version with release

* CI: bump actions/download-artifact to v8 for Node 24 compatibility (intersystems-community#1795)

* Always overwrite entire class for `Pull Server Changes` when there's a conflict between the local copy and server copy (intersystems-community#1797)

* Bump form-data from 4.0.5 to 4.0.6 (intersystems-community#1798)

* Bump js-yaml from 4.1.1 to 4.2.0 (intersystems-community#1800)

* Improve performance of server-side project query (intersystems-community#1809)

* Bump axios from 1.17.0 to 1.18.0 (intersystems-community#1811)

Bumps [axios](https://github.com/axios/axios) from 1.17.0 to 1.18.0.
- [Release notes](https://github.com/axios/axios/releases)
- [Changelog](https://github.com/axios/axios/blob/v1.x/CHANGELOG.md)
- [Commits](axios/axios@v1.17.0...v1.18.0)

---
updated-dependencies:
- dependency-name: axios
  dependency-version: 1.18.0
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Bump fast-uri from 3.1.2 to 3.1.4 (intersystems-community#1812)

Bumps [fast-uri](https://github.com/fastify/fast-uri) from 3.1.2 to 3.1.4.
- [Release notes](https://github.com/fastify/fast-uri/releases)
- [Commits](fastify/fast-uri@v3.1.2...v3.1.4)

---
updated-dependencies:
- dependency-name: fast-uri
  dependency-version: 3.1.4
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Update issue templates with new support statement (intersystems-community#1813)

* Improve management of web sessions when connection changes (intersystems-community#1808)

* Only timeout server connection check during extension activation (intersystems-community#1814)

* Update `Open InterSystems Document...` command to show a flat list of documents (intersystems-community#1804)

* Bump brace-expansion (intersystems-community#1816)

Bumps  and [brace-expansion](https://github.com/juliangruber/brace-expansion). These dependencies needed to be updated together.

Updates `brace-expansion` from 5.0.6 to 5.0.9
- [Release notes](https://github.com/juliangruber/brace-expansion/releases)
- [Commits](juliangruber/brace-expansion@v5.0.6...v5.0.9)

Updates `brace-expansion` from 1.1.13 to 1.1.18
- [Release notes](https://github.com/juliangruber/brace-expansion/releases)
- [Commits](juliangruber/brace-expansion@v5.0.6...v5.0.9)

Updates `brace-expansion` from 2.0.3 to 2.1.4
- [Release notes](https://github.com/juliangruber/brace-expansion/releases)
- [Commits](juliangruber/brace-expansion@v5.0.6...v5.0.9)

---
updated-dependencies:
- dependency-name: brace-expansion
  dependency-version: 5.0.9
  dependency-type: indirect
- dependency-name: brace-expansion
  dependency-version: 1.1.18
  dependency-type: indirect
- dependency-name: brace-expansion
  dependency-version: 2.1.4
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Bump fast-uri from 3.1.4 to 3.1.5 (intersystems-community#1817)

Bumps [fast-uri](https://github.com/fastify/fast-uri) from 3.1.4 to 3.1.5.
- [Release notes](https://github.com/fastify/fast-uri/releases)
- [Commits](fastify/fast-uri@v3.1.4...v3.1.5)

---
updated-dependencies:
- dependency-name: fast-uri
  dependency-version: 3.1.5
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Sync server-side web app files as raw bytes (intersystems-community#1818)

* OAuth2 VSCode (intersystems-community#1799)

* Bump js-yaml from 4.2.0 to 4.3.1 (intersystems-community#1819)

Bumps [js-yaml](https://github.com/nodeca/js-yaml) from 4.2.0 to 4.3.1.
- [Changelog](https://github.com/nodeca/js-yaml/blob/4.3.1/CHANGELOG.md)
- [Commits](nodeca/js-yaml@4.2.0...4.3.1)

---
updated-dependencies:
- dependency-name: js-yaml
  dependency-version: 4.3.1
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Fix incompatibilities with pre-OAuth2 version of Server Manager (intersystems-community#1820)

* Prepare 3.8.3 release (intersystems-community#1821)

* auto bump version with release

* Fix password disclosure via serverForUri and stale cookie reuse after logout/401 (intersystems-community#1824)

* Support abstract documents when importing a client-side folder (intersystems-community#1827)

* Retry once and delete cookies on failed (intersystems-community#1830)

* Prepare 3.8.4 release (intersystems-community#1831)

* auto bump version with release

* Fix crash when opening a file with no workspace folder open (intersystems-community#1834)

* fix intersystems-community#1750

* Fix crash when opening a file with no workspace folder open (intersystems-community#1833)

vscode.workspace.workspaceFolders is undefined when no folder/workspace
is open, so the non-null assertion threw on every active editor change.

* Fix crash from unresolved auth on named-server connections (intersystems-community#1836)

* Restore unauthenticated-connection support (regression from OAuth2 rewrite) (intersystems-community#1840)

* Fix intermittent issues when importing a client-side folder on Windows (intersystems-community#1839)

* Fix server-side projects when connected to a very old server (intersystems-community#1842)

* Skip credential resolution for inactive connections during activation (intersystems-community#1835)

* save locally

* save

* Revert "save locally"; Add branchProtection

This reverts commit 45b23b9.

* Revert master to efe63d3 (before accidental personal-branch merge)

Undoes 45b23b9, c48471c, 469ee89, c7afd54, which landed on master via
an unintended fast-forward from a personal branch.

* `serverForUri` should either set ns or be undefined (intersystems-community#1843)

* Relax server-side URI validation for routines whose dotted section before the extension is only digits (intersystems-community#1845)

* Deprecate configuring a server host/port/credentials in `objectscript.conn` (intersystems-community#1844)

* `serverForUri` should preserve passwords stored in `settings.json["objectscript.conn"]` (intersystems-community#1846)

* fix intersystems-community#1750

* no need to clear password

* save

* Prepare 3.8.5 release (intersystems-community#1850)

* Bump browserslist from 4.28.1 to 4.28.8 (intersystems-community#1851)

Bumps [browserslist](https://github.com/browserslist/browserslist) from 4.28.1 to 4.28.8.
- [Release notes](https://github.com/browserslist/browserslist/releases)
- [Changelog](https://github.com/browserslist/browserslist/blob/main/CHANGELOG.md)
- [Commits](browserslist/browserslist@4.28.1...4.28.8)

---
updated-dependencies:
- dependency-name: browserslist
  dependency-version: 4.28.8
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Bump serialize-javascript and mocha (intersystems-community#1852)

Bumps [serialize-javascript](https://github.com/yahoo/serialize-javascript) to 7.1.1 and updates ancestor dependency [mocha](https://github.com/mochajs/mocha). These dependencies need to be updated together.


Updates `serialize-javascript` from 6.0.2 to 7.1.1
- [Release notes](https://github.com/yahoo/serialize-javascript/releases)
- [Commits](yahoo/serialize-javascript@v6.0.2...v7.1.1)

Updates `mocha` from 11.8.0 to 12.0.0
- [Release notes](https://github.com/mochajs/mocha/releases)
- [Changelog](https://github.com/mochajs/mocha/blob/main/CHANGELOG.md)
- [Commits](mochajs/mocha@v11.8.0...v12.0.0)

---
updated-dependencies:
- dependency-name: serialize-javascript
  dependency-version: 7.1.1
  dependency-type: indirect
- dependency-name: mocha
  dependency-version: 12.0.0
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* auto bump version with release

* Bump @xmldom/xmldom from 0.9.10 to 0.9.12 (intersystems-community#1854)

* Bump @humanfs/node from 0.16.6 to 0.16.8 (intersystems-community#1855)

* Bump fast-uri from 3.1.5 to 3.1.7 (intersystems-community#1856)

* Fix docker-compose connections always prompting for password (intersystems-community#1860)

* fix intersystems-community#1750

* Fix docker-compose connections always prompting for password

resolveConnectionSpec's docker-compose branch built connSpec.auth as
an empty BasicAuthorization(), discarding the plaintext password
already resolved by serverForUri from objectscript.conn.password.

* Fix broken Marketplace badges, drop superfluous ones in README (intersystems-community#1857)

* fix intersystems-community#1750

* Fix broken Marketplace badges, drop superfluous ones in README

shields.io retired its visual-studio-marketplace badge category (both
now render "retired badge"); switch to vsmarketplacebadges.dev, which
queries the Marketplace API directly.

Also drop the Snyk badge and the redundant Caché/Ensemble badges,
which now all link to the same InterSystems IRIS product page.

* Switch packaging/publishing from deprecated vsce to @vscode/vsce

The legacy `vsce` package's last published version (2.15.0, which npx
resolves to since the package is no longer updated) hardcodes an SVG
badge-host allowlist that only trusts the now-dead
vsmarketplacebadge.apphb.com, not its replacement
vsmarketplacebadges.dev. @vscode/vsce is the actively maintained
successor and already trusts vsmarketplacebadges.dev.

* Lite Terminal: syntax color pasted input that ends with a newline (intersystems-community#1866)

* Podman support (intersystems-community#1859)

* Bump js-yaml from 4.3.1 to 4.3.2 (intersystems-community#1868)

Bumps [js-yaml](https://github.com/nodeca/js-yaml) from 4.3.1 to 4.3.2.
- [Changelog](https://github.com/nodeca/js-yaml/blob/4.3.2/CHANGELOG.md)
- [Commits](nodeca/js-yaml@4.3.1...4.3.2)

---
updated-dependencies:
- dependency-name: js-yaml
  dependency-version: 4.3.2
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Fix connection check prompting/disabling on a merely-stale session (intersystems-community#1864)

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Kuang-Chen (KC) Lu <klu@intersystems.com>
Co-authored-by: John Murray <johnm@georgejames.com>
Co-authored-by: Brett Saviano <bsaviano@intersystems.com>
Co-authored-by: ProjectBot <bot@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Lite Terminal: pasted input that ends with a newline is not syntax colored

2 participants