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

bug: private kernel always pushes the current contract to new_contracts (even if is_contract_deployment=false) #684

Closed
dbanks12 opened this issue May 24, 2023 · 0 comments · Fixed by #699
Assignees
Labels
C-protocol-circuits Component: Protocol circuits (kernel & rollup) T-bug Type: Bug. Something is broken.

Comments

@dbanks12
Copy link
Collaborator

dbanks12 commented May 24, 2023

From slack:

Jean:
If I move the following code region:
https://github.com/AztecProtocol/aztec-packages/blob/db-jm/intial-private-kernel/circuits/cpp/src/aztec3/circuits/kernel/private/common.cpp#L129-L143
into the if (is_contract_deployment) clause just afterwards, a cpp unit test will fail.
Is this really expected that we might have new contract data to push into public_inputs.end.new_contracts even when the boolean is_contract_deployment is false?

David:
I think this is a bug. It should be moved into the if statement and should not fail.

@dbanks12 dbanks12 added this to A3 May 24, 2023
@dbanks12 dbanks12 converted this from a draft issue May 24, 2023
@dbanks12 dbanks12 added T-bug Type: Bug. Something is broken. C-protocol-circuits Component: Protocol circuits (kernel & rollup) labels May 24, 2023
@jeanmon jeanmon moved this from Todo to In Progress in A3 May 25, 2023
@jeanmon jeanmon moved this from In Progress to In Review in A3 May 26, 2023
@github-project-automation github-project-automation bot moved this from In Review to Done in A3 May 26, 2023
@iAmMichaelConnor iAmMichaelConnor removed this from A3 Jul 26, 2023
codygunton pushed a commit that referenced this issue Sep 15, 2023
This PR introduces the concept of an `Instance` and slightly reworks the
components of Honk as follows:
* an `Instance` contains and is responsible for creating all the
polynomials resulting from a circuit and required to generate a proof
(the functionality that performs these operations has been hence moved
from the Composer and Prover to the Instance). This abstraction is
necessary for implementing ProtoGalaxy since we are going to fold
polynomials. Moreover, it makes certain tests in Honk more lightweight
as we no longer have to create a full Prover to produce polynomials from
a finalised circuit.
* the `Composer` now creates an `Instance` from a finalised circuit and
creates a Prover and Verifier from an Instance (or several Instances in
the case of ProtoGalaxy).

The `Instance` abstraction is currently only supported by UltraHonk.

Then, I introduced shells for the `ProtoGalaxyProver` and
`ProtoGalaxyVerifier` and data structures involved in folding.

Resolves
[#684](AztecProtocol/barretenberg#684) and
partially resolves
[#681](AztecProtocol/barretenberg#681) (might
also need to provide some shell in the circuits library to fully resolve
this one).

# Checklist:
Remove the checklist to signal you've completed it. Enable auto-merge if
the PR is ready to merge.
- [ ] If the pull request requires a cryptography review (e.g.
cryptographic algorithm implementations) I have added the 'crypto' tag.
- [ ] I have reviewed my diff in github, line by line and removed
unexpected formatting changes, testing logs, or commented-out code.
- [ ] Every change is related to the PR description.
- [ ] I have
[linked](https://docs.github.com/en/issues/tracking-your-work-with-issues/linking-a-pull-request-to-an-issue)
this pull request to relevant issues (if any exist).

---------

Co-authored-by: ludamad <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-protocol-circuits Component: Protocol circuits (kernel & rollup) T-bug Type: Bug. Something is broken.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants