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.

Library addresses interface in factories, are not human readable

See original GitHub issue

When I am generating typechain classes for ethers-v5, for a contract using a library with external calls, the library name in the interface is not human readable.

image

In the tests of the implementation of this feature in #178 , library contract name was human readable (Which makes me believe this is a bug)

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:7 (7 by maintainers)

github_iconTop GitHub Comments

1reaction
quezakcommented, Jul 5, 2021

Looks like this will be a simple extentsion for the exisitng logic – the linkReferences object is there, just under a different path. @Lumyo would you like to prepare a PR for this? You’d need to look for the linkReferences object in a few places before using it in the extractLinkReferences call here

waffle artifact:

{
  ...
  "evm": {
    "bytecode": {
      "linkReferences": {
        "contracts/TestLibrary.sol": {
          "TestLibrary": [
            {
              "length": 20,
              "start": 109
            }
          ]
        }
      },
      "object": ...,
      "opcodes": ...,
      "sourceMap": ...
    },
  },
  "bytecode": "<regular code>__$bd883744d816fd16f92b10543f972238fe$__<more code>"
}

hardhat artifact:

{
  ...
  "bytecode": "<regular code>__$bd883744d816fd16f92b10543f972238fe$__<more regular code>",
  "linkReferences": {
    "contracts/TestLibrary.sol": {
      "TestLibrary": [
        {
          "length": 20,
          "start": 105
        }
      ]
    }
  },
}
0reactions
krzkaczorcommented, Jul 19, 2021
Read more comments on GitHub >

github_iconTop Results From Across the Web

Documentation - Ethers.js
An ABI often comes from the Solidity or Vyper compiler, but you can use the Human-Readable ABI in code, which the following examples...
Read more >
Chapter 3. Beans, BeanFactory and the ApplicationContext
A BeanFactory is represented by the interface org.springframework.beans.factory.BeanFactory, for which there are multiple implementations.
Read more >
Factory Method - Refactoring.Guru
Factory Method is a creational design pattern that provides an interface for creating objects in a superclass, but allows subclasses to alter the...
Read more >
2020 Library Systems Report | American Libraries Magazine
ProQuest's acquisition of Innovative Interfaces, which closed in January, represents a seismic shift in the library technology industry.
Read more >
ipaddress — IPv4/IPv6 manipulation library — Python 3.11.1 ...
Convenience factory functions¶. The ipaddress module provides factory functions to conveniently create IP addresses, networks and interfaces: ipaddress.
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