Skip to content

fix: changed L to L_PRIME in enc_bfv#1221

Closed
zahrajavar wants to merge 2 commits into
mainfrom
pvss-config-verification
Closed

fix: changed L to L_PRIME in enc_bfv#1221
zahrajavar wants to merge 2 commits into
mainfrom
pvss-config-verification

Conversation

@zahrajavar

@zahrajavar zahrajavar commented Jan 28, 2026

Copy link
Copy Markdown
Contributor

This PR addresses issue #1220

Summary by CodeRabbit

  • Refactor
    • Updated encryption circuit implementations with standardized type parameters for improved consistency across all circuit variants.

✏️ Tip: You can customize this high-level summary in your review settings.

@zahrajavar zahrajavar requested a review from 0xjei January 28, 2026 02:05
@vercel

vercel Bot commented Jan 28, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Review Updated (UTC)
crisp Ready Ready Preview, Comment Jan 28, 2026 5:18pm
enclave-docs Ready Ready Preview, Comment Jan 28, 2026 5:18pm

Request Review

@coderabbitai

coderabbitai Bot commented Jan 28, 2026

Copy link
Copy Markdown
Contributor
📝 Walkthrough

Walkthrough

This PR systematically renames the generic size parameter L to L_PRIME across BFV encryption structures, affecting public APIs, struct field definitions, method signatures, and loop bounds in both core library and implementation files.

Changes

Cohort / File(s) Summary
Core BFV Library
circuits/lib/src/core/bfv_enc.nr
Renamed generic parameter L to L_PRIME in Configs and EncryptionBfv struct definitions, all field declarations (qis, k0is, bounds arrays, polynomial arrays), constructor signatures, impl blocks, loop ranges (e.g., for i in 0..L), and method calls to verification functions
Insecure Implementations
circuits/bin/insecure/enc_bfv_e_sm/src/main.nr, circuits/bin/insecure/enc_bfv_sk/src/main.nr
Updated main function signatures to use L_PRIME for all array-typed public parameters (pk0is, pk1is, ct0is, ct1is, e0is, e0_quotients, r1is, r2is, p1is, p2is) and EncryptionBfv instantiation generic parameter
Production Implementations
circuits/bin/production/enc_bfv_e_sm/src/main.nr, circuits/bin/production/enc_bfv_sk/src/main.nr
Updated main function signatures to use L_PRIME for all array-typed public parameters (pk0is, pk1is, ct0is, ct1is, e0is, e0_quotients, r1is, r2is, p1is, p2is) and EncryptionBfv instantiation generic parameter

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Possibly related issues

Possibly related PRs

Suggested labels

noir

Suggested reviewers

  • 0xjei
  • cedoor
  • ctrlc03

Poem

🐰 A parameter's name from L to L_PRIME,
Through circuits and configs, a refactoring time,
Each struct and loop now sings the same song,
Consistency flows where it should all along! ✨

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Title check ✅ Passed The title 'fix: changed L to L_PRIME in enc_bfv' clearly and specifically describes the main change: a systematic rename of the generic parameter L to L_PRIME across encryption BFV-related code.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing touches
  • 📝 Generate docstrings

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@0xjei 0xjei changed the title changed L to L_PRIME in enc_bfv fix: changed L to L_PRIME in enc_bfv Jan 28, 2026
@theinterfold theinterfold deleted a comment from github-actions Bot Jan 28, 2026
@0xjei

0xjei commented Jan 28, 2026

Copy link
Copy Markdown
Contributor

left some comments in chat - we might end up having breaking changes with the transfer of generator in enclave and rename most of the configs.

Base automatically changed from feat/codegen-compute to main January 28, 2026 17:35
@0xjei

0xjei commented Jan 30, 2026

Copy link
Copy Markdown
Contributor

this is not straightforward at changing just the configs or templates, is an error at generator level as well since we are producing L = L_BFV and not L_PRIME configs & inputs

@0xjei

0xjei commented Feb 2, 2026

Copy link
Copy Markdown
Contributor

might be closed by #1244

@zahrajavar zahrajavar closed this Feb 2, 2026
@zahrajavar zahrajavar deleted the pvss-config-verification branch February 2, 2026 18:53
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.

2 participants