feat(cryptpilot-verity): add label support to format and dump commands#113
Merged
feat(cryptpilot-verity): add label support to format and dump commands#113
Conversation
…ump commands - Add MetadataInfo struct with labels BTreeMap - Update serialize_metadata to accept and serialize labels - Update deserialize_metadata to parse labels from metadata - Update open.rs and verify.rs to use MetadataInfo return type - Display labels in dump --print-metadata output
…nt-label handler - Pass CLI labels from FormatOptions to serialize_metadata - Add --print-label handler in dump command - Ignore docs/superpowers/ in .gitignore
- Add --print-labels option to dump command (prints all labels) - Update README and README_zh with label options documentation - Add label tests to Makefile test target
- Use div_ceil() instead of manual calculation in verity-fuse - Format open.rs to satisfy cargo fmt
|
@imlk0 ,您好,您的请求已接收,请耐心等待结果。 |
|
@imlk0 ,您好,未检测到有镜像需要构建,如需重新检测请评论 /start 。 |
- Commit metadata_generated.rs files so CI cargo fmt --check can resolve modules - Empty the metadata/.gitignore since generated files are now tracked - Add .shellcheckrc to exclude SC2155 style warnings in benchmark scripts
|
@imlk0 ,您好,您的请求已接收,请耐心等待结果。 |
|
@imlk0 ,您好,未检测到有镜像需要构建,如需重新检测请评论 /start 。 |
…cript Split combined local declarations and command substitutions to avoid masking return values. Replace sed-based leading-zero fix with bash parameter expansion. Remove .shellcheckrc workaround.
|
@imlk0 ,您好,您的请求已接收,请耐心等待结果。 |
|
@imlk0 ,您好,未检测到有镜像需要构建,如需重新检测请评论 /start 。 |
…ility dh_shlibdeps auto-generates libfuse3-3 on Ubuntu 24.04, but Debian trixie provides libfuse3-4 with the same SONAME. Exclude libfuse from auto-detection and rely on the explicit fuse3 dependency in control.
|
@imlk0 ,您好,您的请求已接收,请耐心等待结果。 |
|
@imlk0 ,您好,未检测到有镜像需要构建,如需重新检测请评论 /start 。 |
… and remove generated FlatBuffers files from git Add verity-testfiles target to Makefile that generates testfiles in verity-core/ before running cargo test. This fixes test_testfiles CI failure where fixtures were never committed due to .gitignore. Remove metadata_generated.rs and metadata_hash_generated.rs from git tracking — they are build artifacts generated by flatc. Update .gitignore to continue ignoring them. Comment out longfile generation in make_testfiles.py (~192MB) as it is not used by any test (only referenced in a comment).
|
@imlk0 ,您好,您的请求已接收,请耐心等待结果。 |
|
@imlk0 ,您好,未检测到有镜像需要构建,如需重新检测请评论 /start 。 |
The -X flag is not a valid dpkg-shlibdeps option. Use -x<package> instead to exclude the libfuse3 package from auto-generated dependencies, avoiding libfuse3-3 vs libfuse3-4 cross-distro issues.
|
@imlk0 ,您好,您的请求已接收,请耐心等待结果。 |
|
@imlk0 ,您好,未检测到有镜像需要构建,如需重新检测请评论 /start 。 |
…rom DEB test matrix Restore metadata_generated.rs and metadata_hash_generated.rs as tracked files — they are required by cargo fmt and the Rust module system. Remove from .gitignore. Drop debian:trixie from DEB test matrix. Ubuntu 24.04 ships libfuse3 with SONAME .so.3 while Debian trixie ships .so.4. A binary built on Ubuntu cannot run on trixie due to the incompatible SONAME.
|
@imlk0 ,您好,您的请求已接收,请耐心等待结果。 |
|
@imlk0 ,您好,未检测到有镜像需要构建,如需重新检测请评论 /start 。 |
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
formatanddumpcommands ofcryptpilot-verity--print-labelsoption to dump all labels at oncemanual_div_ceilwarning in verity-fuseChanges
FlatBuffers schema
KeyValuetable (key: string,value: string) tometadata.fbslabels: [KeyValue]field to theMetadatatablemetadata_hash.fbsunchanged — labels are naturally excluded from root hashCLI
format: new--label key=value(repeatable), e.g.--label env=prod --label owner=team-adump: new--print-label <key>to get a single label value,--print-labelsto list allMetadata module
MetadataInfostruct withfile_infos: Vec<FileVerityInfo>andlabels: BTreeMap<String, String>serialize_metadataaccepts and serializes labelsdeserialize_metadataparses labels from metadataopen.rsandverify.rsto use the newMetadataInforeturn typeTesting
make testnow includes 6 new steps:--print-labelsoutput--print-labelvalue verificationTest plan
make clippypassescargo fmt --checkpassesmake testpasses (all 15 steps including 6 label tests)--print-labelsoutputs all labels--print-label <key>returns correct value🤖 Generated with Claude Code