Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
45 changes: 0 additions & 45 deletions .changeset/diagnostics-related-information.md

This file was deleted.

7 changes: 0 additions & 7 deletions .changeset/global-date-gate-by-kind.md

This file was deleted.

9 changes: 0 additions & 9 deletions .changeset/reuse-api-stability-session.md

This file was deleted.

11 changes: 0 additions & 11 deletions .changeset/typeparser-node-store-churn.md

This file was deleted.

2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ When running in dedicated diagnostics mode, the Effect diagnostics can be emitte
<!-- supported-components:start -->
## Supported Package Versions

The following target package versions are supported by `@effect/tsgo@0.53.2`:
The following target package versions are supported by `@effect/tsgo@0.53.3`:

| Component | Supported versions |
|---|---|
Expand Down
2 changes: 2 additions & 0 deletions _packages/tsgo-darwin-arm64/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# @effect/tsgo-darwin-arm64

## 0.53.3

## 0.53.2

## 0.53.1
Expand Down
2 changes: 1 addition & 1 deletion _packages/tsgo-darwin-arm64/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@effect/tsgo-darwin-arm64",
"version": "0.53.2",
"version": "0.53.3",
"description": "Effect Language Service for TypeScript-Go — Effect-specific diagnostics and hover features.",
"license": "MIT",
"repository": {
Expand Down
2 changes: 2 additions & 0 deletions _packages/tsgo-darwin-x64/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# @effect/tsgo-darwin-x64

## 0.53.3

## 0.53.2

## 0.53.1
Expand Down
2 changes: 1 addition & 1 deletion _packages/tsgo-darwin-x64/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@effect/tsgo-darwin-x64",
"version": "0.53.2",
"version": "0.53.3",
"description": "Effect Language Service for TypeScript-Go — Effect-specific diagnostics and hover features.",
"license": "MIT",
"repository": {
Expand Down
2 changes: 2 additions & 0 deletions _packages/tsgo-linux-arm/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# @effect/tsgo-linux-arm

## 0.53.3

## 0.53.2

## 0.53.1
Expand Down
2 changes: 1 addition & 1 deletion _packages/tsgo-linux-arm/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@effect/tsgo-linux-arm",
"version": "0.53.2",
"version": "0.53.3",
"description": "Effect Language Service for TypeScript-Go — Effect-specific diagnostics and hover features.",
"license": "MIT",
"repository": {
Expand Down
2 changes: 2 additions & 0 deletions _packages/tsgo-linux-arm64/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# @effect/tsgo-linux-arm64

## 0.53.3

## 0.53.2

## 0.53.1
Expand Down
2 changes: 1 addition & 1 deletion _packages/tsgo-linux-arm64/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@effect/tsgo-linux-arm64",
"version": "0.53.2",
"version": "0.53.3",
"description": "Effect Language Service for TypeScript-Go — Effect-specific diagnostics and hover features.",
"license": "MIT",
"repository": {
Expand Down
2 changes: 2 additions & 0 deletions _packages/tsgo-linux-x64/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# @effect/tsgo-linux-x64

## 0.53.3

## 0.53.2

## 0.53.1
Expand Down
2 changes: 1 addition & 1 deletion _packages/tsgo-linux-x64/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@effect/tsgo-linux-x64",
"version": "0.53.2",
"version": "0.53.3",
"description": "Effect Language Service for TypeScript-Go — Effect-specific diagnostics and hover features.",
"license": "MIT",
"repository": {
Expand Down
2 changes: 2 additions & 0 deletions _packages/tsgo-win32-arm64/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# @effect/tsgo-win32-arm64

## 0.53.3

## 0.53.2

## 0.53.1
Expand Down
2 changes: 1 addition & 1 deletion _packages/tsgo-win32-arm64/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@effect/tsgo-win32-arm64",
"version": "0.53.2",
"version": "0.53.3",
"description": "Effect Language Service for TypeScript-Go — Effect-specific diagnostics and hover features.",
"license": "MIT",
"repository": {
Expand Down
2 changes: 2 additions & 0 deletions _packages/tsgo-win32-x64/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# @effect/tsgo-win32-x64

## 0.53.3

## 0.53.2

## 0.53.1
Expand Down
2 changes: 1 addition & 1 deletion _packages/tsgo-win32-x64/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@effect/tsgo-win32-x64",
"version": "0.53.2",
"version": "0.53.3",
"description": "Effect Language Service for TypeScript-Go — Effect-specific diagnostics and hover features.",
"license": "MIT",
"repository": {
Expand Down
61 changes: 61 additions & 0 deletions _packages/tsgo/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,66 @@
# @effect/tsgo

## 0.53.3

### Patch Changes

- 1ab5264: `effect-tsgo diagnostics` now reports a diagnostic's related locations. They used to be dropped in every format, so `missingEffectContext` never showed which layer could provide the missing service and `apiStabilityLeak` never showed where the unstable declaration lives.

With `--format json`, each diagnostic that has related locations gets a `relatedInformation` array. Each entry has the same location fields as the diagnostic, plus its own `code` and `message`. Diagnostics without related locations are unchanged.

```json
{
"line": 23,
"column": 3,
"code": 377004,
"name": "missingEffectContext",
"message": "This Effect requires a service that is missing from the expected Effect context: `Db | Fs`.",
"relatedInformation": [
{
"file": ".../src/index.ts",
"start": 662,
"length": 14,
"line": 22,
"column": 3,
"endLine": 22,
"endColumn": 17,
"code": 377059,
"message": "Adjusting this layer composition could provide the missing service."
}
]
}
```

With `--format pretty`, the related locations are printed under the diagnostic, each with its own code snippet, as `tsc --pretty` does:

```
src/index.ts:23:3 - error effect(missingEffectContext): This Effect requires a service that is missing from the expected Effect context: `Db | Fs`.

23 Effect.runPromise
~~~~~~~~~~~~~~~~~

src/index.ts:22:3 - Adjusting this layer composition could provide the missing service.
22 Effect.provide(live),
~~~~~~~~~~~~~~
```

The `~` markers in pretty output are also aligned again on lines 10 and above. They used to sit one column to the left of the code.
- 4672ba1: Make `globalDate` and `globalDateInEffect` do less work per file. Their shared walker used to look up the Effect context flags of every node it visited, although only call expressions (`Date.now()`) and `new` expressions (`new Date()`) can produce a diagnostic. It now looks up the flags only on those two node kinds, like `globalFetch`, `globalConsole`, `globalTimers`, `globalRandom` and `cryptoRandomUUID` already do.

Reported diagnostics are unchanged.
- b5df4e9: Speed up `apiStabilityLeak` by reusing one stability analysis per file.

The rule used to allocate a fresh analysis, with its maps and work queues, for every export of a file. It now keeps one analysis per file and resets it before each export. The reset analysis behaves exactly like a fresh one, so the reported diagnostics are unchanged. A published surface that a later export reads from the shared cache is no longer queued for publication again, and a published surface without retained findings no longer allocates a findings map.

On `packages/effect` of effect 4.0.5 with every rule enabled, the rule allocates 252 MB → 140 MB.
- d3b53a7: Make the Effect diagnostics write less to the checker's per-node caches. Rules run on the checker goroutine right after each file is checked, and on the Effect monorepo most of their cost was cache traffic (map misses, nil inserts, map growth) and the garbage collection it caused, not type computation.

- Reference checks such as "is this node `Effect.gen`?" no longer probe or fill the symbol cache for statements, blocks, clauses and tokens, which can never resolve to a symbol.
- The analysis that tracks whether code runs inside `Effect.gen`, `Effect.fn` or an Effect thunk stores an entry only where the answer changes, about 2% of nodes, instead of two entries for every node of every file.
- Type lookups reject nodes that can never have a type before touching the cache, the strict Effect type check caches only types named `Effect`, and whether a file has been checked is asked once per file instead of on every query.

Reported diagnostics are unchanged.

## 0.53.2

### Patch Changes
Expand Down
2 changes: 1 addition & 1 deletion _packages/tsgo/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@effect/tsgo",
"version": "0.53.2",
"version": "0.53.3",
"type": "module",
"description": "Effect Language Service for TypeScript-Go — Effect-specific diagnostics and hover features.",
"license": "MIT",
Expand Down
2 changes: 1 addition & 1 deletion etscore/version_generated.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.