question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Typescript check not passing after Deno 1.13.2

See original GitHub issue

Environment

OS: Linux 5.10.70-1-MANJARO Deno version: deno 1.14.0 V8 version: v8 9.4.146.15 TS version: typescript 4.4.2

Issue

Importing denodb causes TS check to not pass after deno 1.13.2.

code

import { DataTypes, Database, Model, PostgresConnector } from 'https://deno.land/x/denodb/mod.ts';

outputs

error: TS2578 [ERROR]: Unused '@ts-expect-error' directive.
      // @ts-expect-error
      ~~~~~~~~~~~~~~~~~~~
    at https://deno.land/std@0.106.0/node/events.ts:100:7

TS2578 [ERROR]: Unused '@ts-expect-error' directive.
        // @ts-expect-error
        ~~~~~~~~~~~~~~~~~~~
    at https://deno.land/std@0.106.0/node/events.ts:105:9

TS2578 [ERROR]: Unused '@ts-expect-error' directive.
      // @ts-expect-error
      ~~~~~~~~~~~~~~~~~~~
    at https://deno.land/std@0.106.0/node/events.ts:116:7

TS2578 [ERROR]: Unused '@ts-expect-error' directive.
      // @ts-expect-error
      ~~~~~~~~~~~~~~~~~~~
    at https://deno.land/std@0.106.0/node/events.ts:200:7

TS2578 [ERROR]: Unused '@ts-expect-error' directive.
    // @ts-expect-error
    ~~~~~~~~~~~~~~~~~~~
    at https://deno.land/std@0.106.0/node/events.ts:225:5

TS2578 [ERROR]: Unused '@ts-expect-error' directive.
        // @ts-expect-error
        ~~~~~~~~~~~~~~~~~~~
    at https://deno.land/std@0.106.0/node/events.ts:391:9

TS2578 [ERROR]: Unused '@ts-expect-error' directive.
      // @ts-expect-error
      ~~~~~~~~~~~~~~~~~~~
    at https://deno.land/std@0.106.0/node/events.ts:424:7

TS2578 [ERROR]: Unused '@ts-expect-error' directive.
          // @ts-expect-error
          ~~~~~~~~~~~~~~~~~~~
    at https://deno.land/std@0.106.0/node/events.ts:446:11

TS2578 [ERROR]: Unused '@ts-expect-error' directive.
          // @ts-expect-error
          ~~~~~~~~~~~~~~~~~~~
    at https://deno.land/std@0.106.0/node/events.ts:451:11

TS2578 [ERROR]: Unused '@ts-expect-error' directive.
    // @ts-expect-error
    ~~~~~~~~~~~~~~~~~~~
    at https://deno.land/std@0.106.0/node/events.ts:646:5

TS2578 [ERROR]: Unused '@ts-expect-error' directive.
    // @ts-expect-error
    ~~~~~~~~~~~~~~~~~~~
    at https://deno.land/std@0.106.0/node/events.ts:667:5

Found 11 errors.

I suppose this is caused by one of the dependencies that depends on the std library, maybe bumping the offending dependency would resolve this issue?

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Reactions:2
  • Comments:12 (1 by maintainers)

github_iconTop GitHub Comments

6reactions
Zhomartcommented, Nov 21, 2021

This pull #307 solves the compatibility issues with the latest deno (v.1.16.2).

The problem was with the dex library as @lejacobroy pointed out above, postgres lib, mysql, mongodb and sqlite dependencies.

I haven’t tested the PR on serious projects.

2reactions
kinghatcommented, Nov 9, 2021

I can’t seem to use it, because this error keeps coming up. Is the only workaround to downgrade to a version earlier than the above?

you could use an import map like this:

{
  "imports": {
    "https://deno.land/std@0.106.0/node/events.ts": "https://deno.land/std@0.114.0/node/events.ts",
    "https://deno.land/std@0.83.0/async/pool.ts": "https://deno.land/std@0.114.0/async/pool.ts"
  }
}
Read more comments on GitHub >

github_iconTop Results From Across the Web

Deno 1.13 Release Notes
Type check code examples in Markdown files; Spawn subprocess with clean environment; Permissions APIs accept URLs; FFI replaces native plugin ...
Read more >
Error converting the result for "op_respond" #12646 - GitHub
I just had this today for the first time and sometimes reproduce it, sometimes not. In general, the typescript phase before running the...
Read more >
Simple Deno test fails with superoak - Stack Overflow
Context: deno 1.13.2 (release, aarch64-apple-darwin) => on mac m1. ... the test fails, even before having the error after the failures list.
Read more >
Foreign Function Interface | Manual - Deno
As of Deno 1.13 and later, the FFI (foreign function interface) API allows users to call ... It is no longer safe to...
Read more >
Using TypeScript | Manual - Deno
Deno supports both JavaScript and TypeScript as first class languages at runtime. ... To make the most of skipping type checks, --no-check transpiles...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found