Bump tx-per-tick to 4096, release v2, drop pkg/errors - #17
Merged
Conversation
- Raise MaxNumberOfTransactionsPerTick from 1024 to 4096 (breaking wire-format change). - Replace stray literal [1024] sizings in TickData.ContractFees and contractFeesToProto with the constant. - Bump module path to github.com/qubic/go-qubic/v2 and update all internal imports. - Update proto go_package to github.com/qubic/go-qubic/v2/proto/v1;qubicpb (also fixes prior path inconsistency) and regenerate .pb.go files.
Convert errors.Wrap/Wrapf to fmt.Errorf with %w wrapping, errors.Errorf to fmt.Errorf, and resolve errors.New/Is from the stdlib errors package. Drop github.com/pkg/errors from go.mod.
qubicmio
approved these changes
May 13, 2026
…sPerTick ContractFees is indexed by contract ID, not by transaction slot. Introduce MaxNumberOfContracts = 1024 and use it for the array and the contractFeesToProto helper signature.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
MaxNumberOfTransactionsPerTickfrom 1024 to 4096 (breaking wire-format change). Replace two stray literal[1024]array sizings with the constant.github.com/qubic/go-qubic/v2; rewrite all internal imports. Update protogo_packagetogithub.com/qubic/go-qubic/v2/proto/v1;qubicpb(also fixes a prior inconsistency where the directive didn't match the actual import path) and regenerate.pb.gofiles.github.com/pkg/errorswith stdlib:errors.Wrap/Wrapf→fmt.Errorf("...: %w", ...),errors.Errorf→fmt.Errorf,errors.New/errors.Isresolved from stdliberrors. Droppkg/errorsfromgo.mod.Test plan
go build ./...clean (excluding untrackedapp/main.gowith pre-existing API mismatches)go test ./...green acrosscommon,common/smartcontracts/qutil,connector,sdk/core/nodetypes,sdk/events,sdk/qx,smartcontracts/qutilgo list -mreportsgithub.com/qubic/go-qubic/v2go mod tidyclean; nopkg/errorsingo.mod/go.sumTickDataand confirm it unmarshals against the new 4096-sized buffers