Age | Commit message (Collapse) | Author |
|
`UnsafeWindowSurface` constructor (#24200)
Fixes https://github.com/denoland/deno/issues/23508
`width` and `height` are required to configure the wgpu surface because
Deno is headless and depends on user to create a window. The options
were non-standard extension of `GPUCanvasConfiguration#configure`.
This PR adds a required options parameter with the `width` and `height`
options to `Deno.UnsafeWindowSurface` constructor.
```typescript
// Old, non-standard extension of GPUCanvasConfiguration
const surface = new Deno.UnsafeWindowSurface("x11", displayHandle, windowHandle);
const context = surface.getContext();
context.configure({ width: 600, height: 800, /* ... */ });
```
```typescript
// New
const surface = new Deno.UnsafeWindowSurface({
system: "x11",
windowHandle,
displayHandle,
width: 600,
height: 800,
});
const context = surface.getContext();
context.configure({ /* ... */ });
```
|
|
Fixes #25777.
We were missing the "node" condition, so we were resolving to the wrong
conditional export, causing our analysis to be incorrect.
|
|
From
https://github.com/denoland/deno/commit/18b89d948dcb849c4dc577478794c3d5fb23b59
May have caused the recent flakiness of
parallel/test-child-process-ipc-next-tick.js
|
|
This PR optimizes the case when `performance.measure()` needs to find
the startMark by name. It is a simple change on `findMostRecent` fn to
avoiding copying and reversing the complete entries list.
Adds minor missing tests for:
- `clearMarks()`, general
- `clearMeasures()`, general
- `measure()`, case when the startMarks name exists more than once
### Benchmarks
#### main
```
CPU | AMD Ryzen 7 PRO 6850U with Radeon Graphics
Runtime | Deno 2.0.0-rc.4 (x86_64-unknown-linux-gnu)
benchmark time/iter (avg) iter/s (min … max) p75 p99 p995
---------------------- ----------------------------- --------------------- --------------------------
worst case measure() 2.1 ms 486.9 ( 1.7 ms … 2.4 ms) 2.2 ms 2.4 ms 2.4 ms
```
#### this PR
```
CPU | AMD Ryzen 7 PRO 6850U with Radeon Graphics
Runtime | Deno 2.0.0-rc.4 (x86_64-unknown-linux-gnu)
benchmark time/iter (avg) iter/s (min … max) p75 p99 p995
---------------------- ----------------------------- --------------------- --------------------------
worst case measure() 966.3 µs 1,035 (876.9 µs … 1.1 ms) 1.0 ms 1.1 ms 1.1 ms
```
```ts
Deno.bench("worst case measure()", (b) => {
performance.mark('start');
for (let i = 0; i < 1e5; i += 1) {
performance.mark(crypto.randomUUID());
}
b.start();
performance.measure('total', 'start');
b.end();
performance.clearMarks();
performance.clearMeasures();
});
```
|
|
Upgrades `deno_core`.
Closes https://github.com/denoland/deno/issues/25761
Closes https://github.com/denoland/deno/issues/25738
|
|
Fixes #25259
Fixes #25687
|
|
Fixes a regression where we were ignoring `--node-modules-dir` if there
was no value passed with it. We should instead default to "auto", to
maintain compat with deno 1
|
|
Towards https://github.com/denoland/deno/issues/25241
|
|
Closes https://github.com/denoland/deno/issues/25760
|
|
Fixes https://github.com/denoland/deno/issues/18050
|
|
Missed this line in https://github.com/denoland/deno/pull/25726
|
|
Fixes https://github.com/denoland/deno/issues/19051
|
|
|
|
|
|
|
|
Fixes cjs modules being loaded as esm.
|
|
(#25748)
Fixes rsbuild running in deno.
You can look at the test to see what was failing, the gist is that we
were trying to statically analyze the re-exports of a CJS script, and if
we couldn't find the source for the re-exported file we would fail.
Instead, we should just treat these as if they were too dynamic to
analyze, and let it fail (or succeed) at runtime. This aligns with
node's behavior.
|
|
Mac aarch64 is failing with timeout after 150 minutes :( we'll address
it after Deno 2 is released but for now just increase the timeout.
|
|
(#25743)
Fixes #25740
|
|
|
|
All these changes made CI fail consistently with random exit code 1
after successful upload.
|
|
Fixes https://github.com/denoland/deno/issues/25681
|
|
|
|
This CI action was using wrong variable to create release directory.
|
|
On Windows some of these steps were taking more than 1s
|
|
|
|
default (#25721)
When using the `ext` flag, it will still attempt formatting them with
the provided extension
|
|
While investigating something else, I noticed this typo which treated
`http_proxy` as `Filter::Https`.
|
|
Towards https://github.com/denoland/deno/issues/25269
|
|
Towards https://github.com/denoland/deno/issues/25269
|
|
(#25720)
This commit fixes issues with the pseudo test file generation logic,
namely:
- `export`s declared in snippets
- auto import insertion for `default export`
## Case 1: `export`s declared in snippets
In the previous implementation, `export`s declared in snippets were
moved to the top level of the module in the generated pseudo test file.
This is required because `export` must be at the top level.
This becomes a problem if such a `export` has a body, containing a
reference to a local variable. Suppose we extract this snippet from
JSDoc:
```ts
const logger = createLogger("my-awesome-module");
export function sum(a: number, b: number): number {
logger.debug("sum called");
return a + b;
}
```
This gets converted into the following invalid code (note that `export
function sum` is moved to the top level, but its body references
`logger` variable which can't be referenced from here):
```ts
export function sum(a: number, b: number): number {
logger.debug("sum called");
return a + b;
}
Deno.test("./base.ts$1-7.ts", async () => {
const logger = createLogger("my-awesome-module");
});
```
To resolve this issue, this commit adds a logic to remove the `export`
keyword, allowing the exported items to stay in the `Deno.test` block
scope, like so:
```ts
Deno.test("./base.ts$1-7.ts", async () => {
const logger = createLogger("my-awesome-module");
function sum(a: number, b: number): number {
logger.debug("sum called");
return a + b;
}
});
```
## Case 2: default export
Previously `default export foo` was not captured by the export
collector, so auto import insertion didn't work for this case. To put it
concretely, the following code snippet didn't work when run with `deno
test --doc` because `import foo from "file:///path/to/mod.ts"` didn't
get inserted automatically:
```ts
/**
* ```ts
* console.log(foo);
* ```
*
* @module
*/
const foo = 42;
export default foo;
```
This commit fixes this issue and the above example works fine.
---
Fixes #25718
|
|
Aligns the error messages in the ext/webgpu folder to be in-line with
the Deno style guide.
https://github.com/denoland/deno/issues/25269
|
|
(#25699)
|
|
Aligns the error messages in the ext/http and a few messages in the
ext/fetch folder to be in-line with the Deno style guide.
This change-set also removes some unnecessary checks in the 00_serve.ts.
These options were recently removed, so it doesn't make sense to check
for them anymore.
https://github.com/denoland/deno/issues/25269
|
|
Current mac arm canaries are failing to upload because the existing
latest commit hash
is more that 5 commits behind and it's not in the git history.
|
|
|
|
Ref https://github.com/denoland/deno/issues/25380
|
|
If a newer version was available the script was exiting with code 1.
|
|
Hides `deno cache` from `--help` output.
---------
Signed-off-by: Asher Gomez <ashersaupingomez@gmail.com>
Co-authored-by: Bartek Iwańczuk <biwanczuk@gmail.com>
|
|
scenarios (#25472)
Closes #11220
Currently does lint, fmt, and repl
|
|
Fixes #14371
|
|
Closes https://github.com/denoland/deno/issues/25604
Signed-off-by: Satya Rohith <me@satyarohith.com>
Co-authored-by: Satya Rohith <me@satyarohith.com>
|
|
packages (#25694)
This commit improves warning messages for deprecated npm packages
and packages that rely on lifecycle script.
|
|
Closes https://github.com/denoland/deno/issues/25679
|
|
Update the config schema to error when adding unsupported
`compilerOptions`.
Fixes https://github.com/denoland/deno/issues/25696
|
|
|
|
|
|
(#25684)
Closes #25676
---------
Co-authored-by: David Sherret <dsherret@gmail.com>
|
|
Reverts #25690
This was not an issue with the ts compiler anymore. Discussion here:
https://github.com/dprint/dprint-plugin-typescript/pull/664#issuecomment-2357000053
|
|
Co-authored-by: Bedis Nbiba <bedisnbiba@gmail.com>
|