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.

SyntaxError: '=' expected

See original GitHub issue

Description

I saw the recent v4 release and I wanted to upgrade to it in my solidity-template, but there is no CHANGELOG explaining what changed since v2 or v3.

Simply installing typechain@4.0.0 and @typechain/ethers-v5@3.0.0 gets me this error:

SyntaxError: '=' expected. (8:15)
   6 |   import { Contract, ContractFactory, Overrides } from "@ethersproject/contracts";
   7 |
>  8 |   import type { Greeter } from "./Greeter";
     |               ^
   9 |
  10 |   export class GreeterFactory extends ContractFactory {

See the full stack trace here.

How to Reproduce

  1. Clone paulrberg/solidity-template
  2. Switch to the typechain-v4 branch
  3. Install dependencies with yarn
  4. Run yarn typechain

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:13 (13 by maintainers)

github_iconTop GitHub Comments

1reaction
krzkaczorcommented, Nov 9, 2020

Fixed in: 0f661c6 (#300)

Btw. bonus q: is it possible in semver to say that everything above 3.8 including next major is fine?

0reactions
krzkaczorcommented, Nov 10, 2020

Oh, actually it seems that it works (at least according to: https://jubianchi.github.io/semver-check/#/>%3D3.8.0/5 ) KISS! 😄

Read more comments on GitHub >

github_iconTop Results From Across the Web

SyntaxError: Unexpected token - JavaScript - MDN Web Docs
The JavaScript exceptions "unexpected token" occur when a specific language construct was expected, but something else was provided.
Read more >
SyntaxError: expected expression, got '.' - Codecademy
No matter what I try, I cant get rid of this SyntaxError: SyntaxError: expected expression, got '.' here is my code $(document).ready(function() ...
Read more >
SyntaxError: expected expression, got '<' - Stack Overflow
tells Express that no matter what the browser requests, your server should return index.html . So when the browser requests JavaScript files ...
Read more >
SyntaxError: expected ':' : r/learnpython - Reddit
Getting an error when I run the script below. import requests import re link = "https://pastebin.com/{}/VmHgxSPK/".format(type) list =…
Read more >
I get the error: "SyntaxError: expected expression, got ...
I have bring it back to just a simple hardcoded string. In my console.log I get the message: SyntaxError: expected expression, got '&',...
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