Closed StevenJNPearce closed 5 years ago
@raulk I was a little busy these last couple of days. I should have plenty of time to work on this tomorrow.
@StevenJNPearce just checking in to see if you've got any follow-up questions?
I was just busy, sorry about the wait. Will let you know if I have any questions.
@StevenJNPearce any chance we can get an ETC here? We have other things inflight which depend on the ENS integration now.
@raulk I took another look at this today and have resolved most of the issues that came up in the review expect one. The one I've not dealt with is https://github.com/ConsenSys/ethql/pull/111#discussion_r223181936 . Whilst I could understand the exmaples in the tests with the commit referenced in your comment, I couldn't get my head round how to implement it - I found the combination of the reduce, merge and functions with (prev, next) arguments a bit confusing.
@StevenJNPearce yeah, that's a tricky part. I'm happy to accept suggestions regarding a clearer API.
The idea here is that some plugins are "decorator" plugins. This is the case of ens. It should not explicitly refer to other resolvers, but it should take any existing ones and "wrap" them in custom logic.
Let me have a look and propose a change on your PR.
@raulk Commenting here as you may have missed my comment on having fixed the last change requested above.
@raulk I don't see a way to make a pull request against the wiki repository. Maybe you can take the contents of README.md from my last commit and add them to the wiki.
@StevenJNPearce looking, thanks!
@StevenJNPearce Good job here. Unfortunately, this PR did introduce a serious regression: non-ENS addresses stopped working. And there were no test cases covering queries with normal addresses with the ENS plugin, so it went unnoticed. Luckily I noticed this, and fixed it for you in https://github.com/ConsenSys/ethql/pull/111/commits/4f6cd81acfbd6a1ecca53fa0eb8718d45003f7c3.
Strangely, the ConsenSys/ethql CircleCI account hasn't picked up this PR. Looking into that, as I'd like to see a green CircleCI before I merge.
Fixes #106