Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Verification with Standard JSON Input #980

Merged
merged 14 commits into from
Apr 26, 2023
Merged

Conversation

kuzdogan
Copy link
Member

@kuzdogan kuzdogan commented Apr 17, 2023

Closes #945

  • Adds session and non session endpoints
  • Adds tests
  • Adds solc json verification to the UI:
    • Remove CustomSelectSearch and instead use the SelectSearch from the library itself with the correct types. CustomSelectSearch was there for a type workaround of the onChange prop: first removes the type, then adds the custom type. With the correct type from the library itself, there's no need for that.
    • Refactor fuzzySearch to its own module as it's reused.
    • Refactor ChainSelect GithubBranchSelect
    • Add the new SolcJsonInput.tsx with the out-of-the-box SelectSearch.

View in Huly HI-715

Refactor SearchSelect's onChange function and its types to be able to
reuse SearchSelect consistently.

Initial naive implementation of using solcJson as input in session
@kuzdogan kuzdogan changed the title Refactor UI for shared SerchSelect,init json endp. JSON Input Apr 17, 2023
@kuzdogan kuzdogan linked an issue Apr 19, 2023 that may be closed by this pull request
3 tasks
@kuzdogan kuzdogan changed the title JSON Input Verification with Standard JSON Input Apr 19, 2023
@codecov-commenter
Copy link

codecov-commenter commented Apr 19, 2023

Codecov Report

Patch coverage: 64.15% and project coverage change: -3.03 ⚠️

Comparison is base (9f586b2) 77.85% compared to head (a368986) 74.82%.

Additional details and impacted files
@@             Coverage Diff             @@
##           staging     #980      +/-   ##
===========================================
- Coverage    77.85%   74.82%   -3.03%     
===========================================
  Files           29       36       +7     
  Lines         1368     2038     +670     
  Branches       252      390     +138     
===========================================
+ Hits          1065     1525     +460     
- Misses         177      307     +130     
- Partials       126      206      +80     
Flag Coverage Δ
lib-sourcify 68.23% <ø> (?)
server 77.69% <64.15%> (-0.16%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
src/server/controllers/VerificationController.ts 73.15% <64.15%> (-1.95%) ⬇️

... and 8 files with indirect coverage changes

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

@kuzdogan kuzdogan marked this pull request as ready for review April 20, 2023 00:21
Copy link
Member

@marcocastignoli marcocastignoli left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just two small things, great job! 🚀

src/server/controllers/VerificationController.ts Outdated Show resolved Hide resolved
@haltman-at
Copy link

Question from an interested outsider: What would happen if someone used this interface to attempt to verify a Yul contract, setting "language": "Yul" rather than "language": "Solidity"?

@kuzdogan
Copy link
Member Author

@haltman-at Thanks for pointing this out!

I tried with the examples in the Solidity docs Yul page. The compiler compiles just fine but since the compiler output JSON does not have .contracts, no source code and metadata file get added to the session.

So we should check if the language is "Solidity"

@kuzdogan kuzdogan merged commit 79d05f7 into staging Apr 26, 2023
@kuzdogan kuzdogan deleted the standard-json-verification branch May 10, 2023 14:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Solidity standard-json input verification
4 participants