Repository Analysis

apache/fory

A blazingly fast multi-language serialization framework for idiomatic domain objects, schema IDL, and cross-language data exchange.

4.8 Likely human-written View on GitHub

Analysis Overview

This report presents the forensic synthetic code analysis of apache/fory, a Java project with 4,520 GitHub stars. SynthScan v2.0 examined 867,683 lines of code across 2573 source files, recording 3308 pattern matches distributed across 22 syntactic categories. The overall adjusted score of 4.8 places this repository in the Likely human-written band.

The scanner applied 160+ deterministic lexical heuristics, multi-line block detectors, abstract syntax tree depth profilers, and a cross-file Jaccard similarity matrix to construct a statistically normalised synthetic code estimate. All matches are individually weighted by severity coefficient and contextual multiplier before summation, and the resulting headline score is temporally discounted to account for the repository's development history relative to the commercial emergence of large language model coding tooling (November 2022 onward).

4.8
Adjusted Score
4.8
Raw Score
100%
Time Factor
2026-08-29
Last Push
4.5K
Stars
Java
Language
867.7K
Lines of Code
2.6K
Files
3.3K
Pattern Hits
2026-08-29
Scan Date
0.06
HC Hit Rate

What These Metrics Mean

Adjusted Score
Primary synthetic code indicator. Raw score normalised per 1,000 lines of code and multiplied by the temporal discount factor. This is the definitive comparative metric — use it to rank repositories by AI authorship density.
Raw Score
The unmodified sum of all severity-weighted, context-multiplied pattern match scores before temporal discounting. Reflects the absolute signal strength independent of when the repository was last active.
Time Factor
The temporal discount multiplier (0–100%) applied to the raw score. Repositories last updated before ChatGPT's launch (Nov 2022) receive a 5% factor. Full signal is only assigned to repositories active in the post-adoption era (Jan 2024+).
Pattern Hits
Total count of individual pattern matches across all files and categories. A high hit count with a low score may indicate a very large codebase with isolated AI snippets; a low count with a high score indicates dense, concentrated AI signatures.
HC Hit Rate
High+Critical pattern hits per file, averaged across the repository. This orthogonal signal catches repositories where a few files are densely packed with high-severity AI tells — a strong indicator even when the normalised score appears moderate due to codebase size.
Lines of Code / Files
Total lines and files analysed. The scanner examines 94 file extensions. These denominators are used to normalise the score, enabling fair comparison between repositories of vastly different sizes.

Score History

This chart maps the temporal evolution of the adjusted synthetic code score across successive scan runs. An upward trajectory indicates ongoing incorporation of AI-generated code or expanding LLM-assisted scaffolding; a stable or declining trajectory may reflect active human refactoring, code removal, or the adoption of stricter authorship policies. The dashed secondary line (right axis) independently tracks total raw pattern hit count, which can diverge from the normalised score when codebase size changes significantly between scans.

Severity Breakdown

Classifies detected patterns by their diagnostic confidence and structural impact. CRITICAL patterns (coefficient 10) represent definitive synthetic signatures — hallucinated imports, explicit LLM attribution metadata — virtually never produced by human authors. HIGH (5) indicates strong structural tells such as cross-file repetition or cross-linguistic idioms. MEDIUM (2) covers recognisable conversational padding and AI-specific vocabulary. LOW (1) captures subtle indicators like tautological comments and generic boilerplate that require density to carry independent signal.

CRITICAL 44HIGH 113MEDIUM 95LOW 3056

Directory Score Breakdown

This horizontal bar chart decomposes the repository's raw synthetic code score by top-level directory, allowing you to pinpoint precisely which modules or components carry the highest AI authorship density. Directories with disproportionately high scores relative to their size warrant targeted manual review: concentrated AI signatures often trace back to mass-generated configuration layers, auto-ported test suites, LLM-scaffolded boilerplate classes, or entire subsystems authored under heavy copilot assistance. Use this view to prioritise your human code-review effort.

Pattern Findings

The scanner identified 3308 distinct pattern matches across 22 syntactic categories. Each entry below represents a discrete location in the source code where the engine recorded a statistically significant AI authorship indicator. Expand any category row to inspect the individual file paths, line numbers, code snippets, and the lexical context (CODE, COMMENT, or STRING) in which each match was detected.

Reading the findings table: The Severity column indicates the diagnostic confidence level (CRITICAL / HIGH / MEDIUM / LOW). The Context column identifies whether the match occurred inside executable code, an inline comment, or a string literal — comment-context matches receive a ×1.5 weight because LLMs systematically over-annotate. The ⚡ bolt icon marks clustered matches: three or more patterns within a 10-line window, each receiving an additional ×1.5 density multiplier as dense clusters constitute far stronger evidence of synthetic authorship than isolated hits.

Hyper-Verbose Identifiers1438 hits · 1237 pts
SeverityFileLineSnippetContext
LOWpython/setup.py68def _is_retryable_network_error(output: str) -> bool:CODE
LOWpython/pyfory/registry.py190def _accepts_n_positional_args(factory, nargs: int) -> bool:CODE
LOWpython/pyfory/registry.py330 def get_or_create_encoded_meta_string(self, data: bytes, hashcode: int) -> EncodedMetaString:CODE
LOWpython/pyfory/registry.py1031 def get_registered_user_type_id(self, cls):CODE
LOWpython/pyfory/registry.py1043 def _load_metabytes_to_type_info(self, ns_metabytes, type_metabytes):CODE
LOWpython/pyfory/registry.py1162 def _get_nonexist_enum_type_info(self):CODE
LOWpython/pyfory/registry.py1207 def _write_unknown_struct_type_info(self, write_context, type_def):CODE
LOWpython/pyfory/registry.py1245 def _build_type_info_from_typedef(self, type_def):CODE
LOWpython/pyfory/registry.py1263 def _local_type_info_for_typedef(self, type_def):CODE
LOWpython/pyfory/registry.py1284 def _check_remote_type_def_key(self, type_key):CODE
LOWpython/pyfory/registry.py1321 def _check_remote_type_def_limit(self, type_def):CODE
LOWpython/pyfory/registry.py1352 def _read_and_build_type_info(self, buffer, expected_typeinfo=None):CODE
LOWpython/pyfory/policy.py469 def check_restored_reduced_object(self, obj, **kwargs):CODE
LOWpython/pyfory/converter.py94def supports_compatible_scalar_conversion(remote_type_id: int, local_type_id: int) -> bool:CODE
LOWpython/pyfory/converter.py214def _compatible_decimal_from_parts(scale: int, unscaled: int) -> decimal.Decimal:CODE
LOWpython/pyfory/converter.py291def _decimal_from_float_value(value: float) -> decimal.Decimal:CODE
LOWpython/pyfory/converter.py436def compatible_scalar_convert(value, remote_type_id: int, local_type_id: int):CODE
LOWpython/pyfory/converter.py448def _read_compatible_scalar_value(read_context, remote_serializer, remote_type_id: int, local_type_id: int):CODE
LOWpython/pyfory/types.py71def _is_special_compiled_primitive_type(type_) -> bool:CODE
LOWpython/pyfory/types.py193def _is_special_compiled_primitive_array_type(type_) -> bool:CODE
LOWpython/pyfory/context.py107 def write_encoded_meta_string(self, buffer, encoded_meta_string: EncodedMetaString):CODE
LOWpython/pyfory/context.py562 def reserve_unbacked_container_items(self, num_items):CODE
LOWpython/pyfory/context.py568 def _raise_unbacked_container_items(self, num_items, remaining):CODE
LOWpython/pyfory/type_util.py339def get_homogeneous_tuple_elem_type(type_or_args):CODE
LOWpython/pyfory/type_util.py520def _resolve_static_module_attr(module, attr_name):CODE
LOWpython/pyfory/type_util.py527def _resolve_static_module_qualname(module, qualname, policy):CODE
LOWpython/pyfory/collection.py47def _raise_invalid_map_chunk_size(chunk_size, remaining):CODE
LOWpython/pyfory/collection.py51def _ensure_container_allocation(read_context, count):CODE
LOWpython/pyfory/collection.py57def _settle_unbacked_container_items(read_context, completed, start_index):CODE
LOWpython/pyfory/collection.py165 def _write_same_type_has_null(self, write_context, value, serializer):CODE
LOWpython/pyfory/collection.py262 def _read_same_type_no_ref_guarded(self, read_context, length, collection_, serializer):CODE
LOWpython/pyfory/serializer.py75def _resolve_validated_module_attr(policy, module_name, attr_name, is_local=False):CODE
LOWpython/pyfory/serializer.py83def _resolve_validated_module_qualname(policy, module_name, qualname):CODE
LOWpython/pyfory/serializer.py123def _is_local_receiver_static(obj):CODE
LOWpython/pyfory/serializer.py128def _is_local_callable_static(obj):CODE
LOWpython/pyfory/serializer.py156def _is_bound_method_value_static(obj):CODE
LOWpython/pyfory/serializer.py192def _authorize_callable_materialization(policy, callable_type, **kwargs):CODE
LOWpython/pyfory/serializer.py197def _require_registered_reduce_type(type_resolver, callable_obj):CODE
LOWpython/pyfory/serializer.py231def _resolve_validated_bound_method(policy, obj, method_name, is_local):CODE
LOWpython/pyfory/serializer.py412def _can_use_small_decimal_encoding(unscaled: int) -> bool:CODE
LOWpython/pyfory/serializer.py623def _build_pyarray_typecode_tables():CODE
LOWpython/pyfory/serializer.py731def fory_array_serializer_type(type_id):CODE
LOWpython/pyfory/serializer.py781 def _build_pyarray_serializer(self, type_resolver, type_id):CODE
LOWpython/pyfory/serializer.py788 def _build_ndarray_serializer(self, type_resolver, type_id):CODE
LOWpython/pyfory/serializer.py1012def _object_ndarray_element_count(shape):CODE
LOWpython/pyfory/codegen.py64def gen_write_nullable_basic_stmts(CODE
LOWpython/pyfory/codegen.py83def gen_read_nullable_basic_stmts(CODE
LOWpython/pyfory/struct.py354def _is_dynamic_nullable_default(type_hint: type) -> bool:CODE
LOWpython/pyfory/struct.py525def resolve_missing_field_default(CODE
LOWpython/pyfory/struct.py574def _resolve_missing_field_default(dc_field, type_resolver, type_hints):CODE
LOWpython/pyfory/struct.py578def build_default_values_factory(type_resolver, type_hints, dc_fields=()):CODE
LOWpython/pyfory/struct.py724 def _build_missing_field_defaults(self):CODE
LOWpython/pyfory/struct.py1255def compute_struct_fingerprint(type_resolver, field_names, serializers, nullable_map=None, field_infos_list=None):CODE
LOWpython/pyfory/struct.py1326def _normalize_schema_fingerprint_type_id(type_id):CODE
LOWpython/pyfory/struct.py1345def _leaf_schema_fingerprint_type_id(type_resolver, type_hint):CODE
LOWpython/pyfory/struct.py1363def _build_schema_fingerprint_type(type_resolver, type_hint, nullable, track_ref, include_ref, include_nullable=True):CODE
LOWpython/pyfory/tests/test_ref_tracking.py102def test_collection_list_mixed_type_shared_reference(xlang):CODE
LOWpython/pyfory/tests/test_ref_tracking.py113def test_collection_tuple_shared_reference_python_mode():CODE
LOWpython/pyfory/tests/test_ref_tracking.py123def test_collection_set_element_alias_with_outer_reference_python_mode():CODE
LOWpython/pyfory/tests/test_ref_tracking.py134def test_map_shared_value_aliases_with_none_key(xlang):CODE
1378 more matches not shown…
Over-Commented Block1024 hits · 1002 pts
SeverityFileLineSnippetContext
LOW.asf.yaml1# Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOWPackage.swift1// swift-tools-version: 6.0COMMENT
LOW.spi.yml1# Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOWlicenserc.toml1# Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOW.markdownlint.yml1# Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOWgo/fory/struct_test.go1// Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOWgo/fory/array_primitive.go1// Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOWgo/fory/skip.go1// Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOWgo/fory/type_def.go1// Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOWgo/fory/graph_memory_budget_test.go1// Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOWgo/fory/deserialization_hardening_test.go1// Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOWgo/fory/slice.go1// Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOWgo/fory/map_primitive_test.go1// Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOWgo/fory/union_test.go1// Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOWgo/fory/field_serializer.go1// Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOWgo/fory/fory.go1// Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOWgo/fory/fory.go501// RegisterExtensionByName registers an extension type by name for cross-language serialization.COMMENT
LOWgo/fory/fory.go541// Reset clears internal state for reuseCOMMENT
LOWgo/fory/fory.go721COMMENT
LOWgo/fory/fory.go901}COMMENT
LOWgo/fory/type_resolver_test.go1// Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOWgo/fory/time.go1// Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOWgo/fory/util_test.go1// Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOWgo/fory/field_info.go1// Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOWgo/fory/field_info.go581 Ref boolCOMMENT
LOWgo/fory/stream.go1// Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOWgo/fory/types.go1// Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOWgo/fory/decimal.go1// Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOWgo/fory/test_helper_test.go1// Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOWgo/fory/buffer_bench_test.go1// Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOWgo/fory/string_test.go1// Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOWgo/fory/fory_test.go1// Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOWgo/fory/util.go1// Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOWgo/fory/util.go81// Float32frombits returns the floating-point number correspondingCOMMENT
LOWgo/fory/endian_big.go1// Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOWgo/fory/optional_serializer.go1// Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOWgo/fory/serializer.go1// Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOWgo/fory/serializer.go21 "reflect"COMMENT
LOWgo/fory/serializer.go41 // - refMode: controls reference/null handling behavior:COMMENT
LOWgo/fory/serializer.go61 // type information validation, and delegating to ReadData for the actual data deserialization.COMMENT
LOWgo/fory/serializer.go81COMMENT
LOWgo/fory/serializer.go101 // - typeInfo: pre-read type information; do NOT read type info again from bufferCOMMENT
LOWgo/fory/serializer.go121//COMMENT
LOWgo/fory/ref_override_test.go1// Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOWgo/fory/map_set_null_test.go1// Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOWgo/fory/ref_resolver.go1// Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOWgo/fory/writer.go1// Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOWgo/fory/buffer_test.go1// Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOWgo/fory/buffer.go1// Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOWgo/fory/enum_test.go1// Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOWgo/fory/evolving.go1// Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOWgo/fory/doc.go1// Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOWgo/fory/extension.go1// Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOWgo/fory/tag_test.go1// Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOWgo/fory/primitive.go1// Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOWgo/fory/struct_init.go1// Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOWgo/fory/primitive_test.go1// Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOWgo/fory/slice_primitive_test.go1// Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOWgo/fory/type_resolver.go1// Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
LOWgo/fory/type_def_test.go1// Licensed to the Apache Software Foundation (ASF) under oneCOMMENT
964 more matches not shown…
Cross-Language Confusion82 hits · 494 pts
SeverityFileLineSnippetContext
HIGHpython/pyfory/tests/xlang_test_main.py1362 # Group 2: Java sends null, Python receives null (like C++)COMMENT
HIGHpython/pyfory/tests/xlang_test_main.py1398 # Verify Group 2: Java sent null, Python receives null (like C++ with std::optional)COMMENT
HIGHpython/pyfory/tests/xlang_test_main.py1330 Java sends: Group 1 (non-nullable with values) + Group 2 (nullable with null)STRING
HIGHpython/pyfory/tests/test_serializer.py917 assert df2.equals(df)CODE
HIGHpython/pyfory/format/columnar.py112 """Append a value (can be None for null)."""STRING
HIGHci/release.py188 "git add LICENSE && git commit -m 'remove benchmark from license'", shell=TrueCODE
HIGHcompiler/fory_compiler/tests/test_generated_code.py659 "registerGeneratedStruct(fory, _envelopeForySchema, id: null, name: 'demo.Envelope');"CODE
HIGHcompiler/fory_compiler/tests/test_generated_code.py663 "registerGeneratedEnum(fory, _envelopeKindForySchema, id: null, name: 'demo.Envelope.Kind');"CODE
HIGHcompiler/fory_compiler/tests/test_generated_code.py667 "fory.registerSerializer(Envelope_Choice, const _Envelope_ChoiceForySerializer(), id: null, name: 'demo.EnvelopeCODE
HIGHcompiler/fory_compiler/tests/test_generated_code.py717 assert "\n id: null," not in dart_outputCODE
HIGHcompiler/fory_compiler/tests/test_generated_code.py916 assert "Objects.equals(f16, that.f16)" in java_outputCODE
HIGHcompiler/fory_compiler/tests/test_generated_code.py917 assert "Objects.equals(optF16, that.optF16)" in java_outputCODE
HIGHcompiler/fory_compiler/tests/test_generated_code.py965 assert "index == that.index && deepValueEquals(value, that.value)" in java_outputCODE
HIGHcompiler/fory_compiler/tests/test_javascript_codegen.py86 assert "email?: string | null;" in outputCODE
HIGHcompiler/fory_compiler/tests/test_dart_generator.py350 "registerGeneratedStruct(fory, _envelopeForySchema, id: null, name: 'demo.Envelope');"CODE
HIGHcompiler/fory_compiler/tests/test_dart_generator.py354 "registerGeneratedStruct(fory, _envelopePayloadForySchema, id: null, name: 'demo.Envelope.Payload');"CODE
HIGHcompiler/fory_compiler/tests/test_dart_generator.py71 "registerGeneratedStruct(fory, _scalarForySchema, id: 100, name: null);"CODE
HIGHcompiler/fory_compiler/tests/test_dart_generator.py118 "registerGeneratedEnum(fory, _statusForySchema, id: 101, name: null);"CODE
HIGHcompiler/fory_compiler/tests/test_dart_generator.py160 "fory.registerSerializer(Animal, const _AnimalForySerializer(), id: 101, name: null);"CODE
HIGHcompiler/fory_compiler/tests/test_dart_generator.py189 assert "List<int>? maybeInts = null;" in file.contentCODE
HIGHcompiler/fory_compiler/tests/test_service_codegen.py2772 Greeter.BindService(metadataBinder, null);CODE
HIGHcompiler/fory_compiler/tests/test_service_codegen.py2775 metadataBinder.Handlers.TrueForAll(static handler => handler is null),CODE
HIGHcompiler/fory_compiler/tests/test_service_codegen.py2873 return (Method<TRequest, TResponse>)field.GetValue(null)!;CODE
HIGHcompiler/fory_compiler/generators/java.py924 f"{ind} return index == that.index && deepValueEquals(value, that.value);"CODE
HIGHcompiler/fory_compiler/generators/java.py928 f"{ind} return index == that.index && Objects.equals(value, that.value);"CODE
HIGHcompiler/fory_compiler/generators/java.py928 f"{ind} return index == that.index && Objects.equals(value, that.value);"CODE
HIGHcompiler/fory_compiler/generators/java.py1901 lines.append(" return sb.toString();")CODE
HIGHcompiler/fory_compiler/generators/java.py1913 " if (left == null || right == null) {",CODE
HIGHcompiler/fory_compiler/generators/java.py1913 " if (left == null || right == null) {",CODE
HIGHcompiler/fory_compiler/generators/java.py1919 " if (left instanceof java.util.List && right instanceof java.util.List) {",CODE
HIGHcompiler/fory_compiler/generators/java.py1949 " return Objects.equals(left, right);",CODE
HIGHcompiler/fory_compiler/generators/java.py1954 " return Arrays.equals((boolean[]) left, (boolean[]) right);",CODE
HIGHcompiler/fory_compiler/generators/java.py1957 " return Arrays.equals((byte[]) left, (byte[]) right);",CODE
HIGHcompiler/fory_compiler/generators/java.py1960 " return Arrays.equals((short[]) left, (short[]) right);",CODE
HIGHcompiler/fory_compiler/generators/java.py1963 " return Arrays.equals((int[]) left, (int[]) right);",CODE
HIGHcompiler/fory_compiler/generators/java.py1966 " return Arrays.equals((long[]) left, (long[]) right);",CODE
HIGHcompiler/fory_compiler/generators/java.py1969 " return Arrays.equals((float[]) left, (float[]) right);",CODE
HIGHcompiler/fory_compiler/generators/java.py1972 " return Arrays.equals((double[]) left, (double[]) right);",CODE
HIGHcompiler/fory_compiler/generators/java.py1981 " if (value == null) {",CODE
HIGHcompiler/fory_compiler/generators/java.py813 lines.append(f"{ind} if (v == null) {{")CODE
HIGHcompiler/fory_compiler/generators/java.py895 lines.append(f"{ind} if (v == null) {{")CODE
HIGHcompiler/fory_compiler/generators/java.py1932 " if (left instanceof java.util.Map && right instanceof java.util.Map) {",CODE
HIGHcompiler/fory_compiler/generators/java.py2033 lines.append(" if (o == null || getClass() != o.getClass()) return false;")CODE
HIGHcompiler/fory_compiler/generators/java.py2044 f"Arrays.equals({field_name}, that.{field_name})"CODE
HIGHcompiler/fory_compiler/generators/java.py2074 f"Objects.equals({field_name}, that.{field_name})"CODE
HIGHcompiler/fory_compiler/generators/java.py2078 f"Objects.equals({field_name}, that.{field_name})"CODE
HIGHcompiler/fory_compiler/generators/dart.py905 f"{self.indent_str * (indent + 1)}bool operator ==(Object other) => identical(this, other) || (other is CODE
HIGHcompiler/fory_compiler/generators/dart.py1298 f"{self.indent_str * (indent + 2)}if (existing != null) return existing;",CODE
HIGHcompiler/fory_compiler/generators/cpp.py2115 lines.append(" if (!remote || remote->type_id != expected->type_id) {")CODE
HIGHcompiler/fory_compiler/generators/cpp.py2128 lines.append(" if (ref_mode == RefMode::Tracking && ctx.track_ref()) {")CODE
HIGHcompiler/fory_compiler/generators/cpp.py2187 " if (ref_flag != NOT_NULL_VALUE_FLAG && ref_flag != REF_VALUE_FLAG) {"CODE
HIGHcompiler/fory_compiler/generators/cpp.py2244 " if (ref_flag != NOT_NULL_VALUE_FLAG && ref_flag != REF_VALUE_FLAG) {"CODE
HIGHcompiler/fory_compiler/generators/go.py549 f"func (u {type_name}) IsSet() bool {{ return u.case_ != {case_type}Invalid && u.value != nil }}"CODE
HIGHcompiler/fory_compiler/generators/go.py575 lines.append(f"\tif u.case_ == {case_type}Invalid || u.value == nil {{")CODE
HIGHcompiler/fory_compiler/generators/javascript.py1195 " serialize: (value: T | null) => Uint8Array;",CODE
HIGHcompiler/fory_compiler/generators/services/java.py208 lines.append(" if (local == null) {")CODE
HIGHcompiler/fory_compiler/generators/services/java.py211 lines.append(" if (local == null) {")CODE
HIGHcompiler/fory_compiler/generators/services/cpp.py392 " if (buffer == nullptr || own_buffer == nullptr) {",CODE
HIGHcompiler/fory_compiler/generators/services/cpp.py422 " if (buffer == nullptr || message == nullptr || !buffer->Valid()) {",CODE
HIGHcompiler/fory_compiler/generators/services/csharp.py332 f"{self.indent_str * 2}public virtual {response_type} {method_name}({request_type} request, grpc::Metadata? CODE
22 more matches not shown…
Hallucination Indicators44 hits · 480 pts
SeverityFileLineSnippetContext
CRITICAL…ache/fory/integration_tests/JpmsFieldAccessorTest.java45 org.apache.fory.integration_tests.Test.verifyKotlinJson();CODE
CRITICAL…/org/apache/fory/idl_tests/ScalaIdlRoundTripTest.scala159 enumListInfo.genericType.getTypeParameter0.getTypeRef.getTypeExtMeta.typeId() shouldBeCODE
CRITICAL…/java/org/apache/fory/GuavaOptionalDependencyTest.java195 byte[] bytes = fory.serialize(com.google.common.collect.ImmutableList.of("fory"));CODE
CRITICAL…/java/org/apache/fory/GuavaOptionalDependencyTest.java197 if (!com.google.common.collect.ImmutableList.of("fory").equals(value)) {CODE
CRITICAL…t/java/org/apache/fory/codegen/CodegenContextTest.java117 org.apache.fory.codegen.javalangnameconflict.Object.class.getPackage().getName());CODE
CRITICAL…st/java/org/apache/fory/xlang/PyCrossLanguageTest.java498 org.apache.fory.serializer.DeferedLazySerializer.class.getDeclaredMethod("getSerializer");CODE
CRITICAL…src/test/java/org/apache/fory/xlang/XlangTestBase.java1036 struct1.union = org.apache.fory.type.union.Union2.ofT1("hello");CODE
CRITICAL…src/test/java/org/apache/fory/xlang/XlangTestBase.java1040 struct2.union = org.apache.fory.type.union.Union2.ofT2(42L);CODE
CRITICAL…t/java/org/apache/fory/resolver/ClassResolverTest.java1127 org.apache.fory.test.bean.Foo.create(), org.apache.fory.test.bean.Foo.create());CODE
CRITICAL…/java/org/apache/fory/resolver/DisallowedListTest.java58 java.lang.invoke.MethodHandle.class.getName(),CODE
CRITICAL…/java/org/apache/fory/resolver/DisallowedListTest.java59 java.lang.invoke.MethodHandles.Lookup.class.getName(),CODE
CRITICAL…/main/java/org/apache/fory/serializer/FieldGroups.java282 org.apache.fory.serializer.collection.PrimitiveListSerializers.createArraySerializer(CODE
CRITICAL…main/java/org/apache/fory/reflect/ReflectionUtils.java713 org.apache.fory.collection.Collections.newClassKeyCacheMap();CODE
CRITICAL…/main/java/org/apache/fory/resolver/ClassResolver.java1627 org.apache.fory.serializer.CodegenSerializer.loadCodegenSerializer(CODE
CRITICAL…/main/java/org/apache/fory/resolver/XtypeResolver.java1068 new org.apache.fory.serializer.BufferSerializers.ByteBufferSerializer(CODE
CRITICAL…/main/java/org/apache/fory/resolver/XtypeResolver.java1076 new org.apache.fory.serializer.BufferSerializers.ByteBufferSerializer(CODE
CRITICAL…ory/annotation/processing/ForyStructProcessorTest.java1130 org.apache.fory.type.Float16.fromBits((short) 0x0000),CODE
CRITICAL…ory/annotation/processing/ForyStructProcessorTest.java1131 org.apache.fory.type.Float16.fromBits((short) 0x3C00)));CODE
CRITICAL…/org/apache/fory/format/type/ArrowSchemaConverter.java118 new org.apache.arrow.vector.types.pojo.Field(CODE
CRITICAL…/org/apache/fory/format/type/ArrowSchemaConverter.java123 return new org.apache.arrow.vector.types.pojo.Field(CODE
CRITICAL…/org/apache/fory/format/type/ArrowSchemaConverter.java138 return new org.apache.arrow.vector.types.pojo.Schema(arrowFields, forySchema.metadata());CODE
CRITICAL…va/org/apache/fory/json/codegen/Utf8WriterCodegen.java403 .append("org.apache.fory.memory.LittleEndian.putInt64(prefixBuffer")CODE
CRITICAL…va/org/apache/fory/json/codegen/Utf8WriterCodegen.java411 code.append("org.apache.fory.memory.LittleEndian.putInt64(prefixBuffer")CODE
CRITICAL…/org/apache/fory/json/resolver/JsonSharedRegistry.java1692 long hash = org.apache.fory.json.meta.JsonFieldNameHash.hash(name);CODE
CRITICAL…/org/apache/fory/json/resolver/JsonSharedRegistry.java1837 long hash = org.apache.fory.json.meta.JsonFieldNameHash.hash(name);CODE
CRITICAL…he/fory/json/kotlin/ksp/JavaSubtypeGenerationWriter.kt27 append("@org.apache.fory.json.codec.GeneratedJsonSubtypeTable.Generation(")CODE
CRITICAL…/scala/org/apache/fory/json/scala/ScalaJsonSuite.scala95 @org.apache.fory.json.annotation.JsonCodec(value = classOf[WeekdayCodec]) day: Weekday.ValueCODE
CRITICAL…/scala/org/apache/fory/json/scala/ScalaJsonSuite.scala99 @org.apache.fory.json.annotation.JsonCodec(elementCodec = classOf[TaggedStringCodec])CODE
CRITICAL…/scala/org/apache/fory/json/scala/ScalaJsonSuite.scala101 @org.apache.fory.json.annotation.JsonCodec(contentCodec = classOf[TaggedStringCodec])CODE
CRITICAL…/scala/org/apache/fory/json/scala/ScalaJsonSuite.scala103 @org.apache.fory.json.annotation.JsonCodec(CODE
CRITICAL…ache/fory/json/scala/internal/ScalaTypeRefMacros.scala38 org.apache.fory.reflect.TypeRef.ofDeclaredTypeArguments(CODE
CRITICAL…ache/fory/json/scala/internal/ScalaTypeRefMacros.scala45 case _ => '{ org.apache.fory.reflect.TypeRef.of($rawClass) }CODE
CRITICAL…ache/fory/json/scala/internal/ScalaTypeRefMacros.scala42 q"_root_.org.apache.fory.reflect.TypeRef.of($clazz)"CODE
CRITICAL…ache/fory/json/scala/internal/ScalaTypeRefMacros.scala45 q"_root_.org.apache.fory.reflect.TypeRef.ofDeclaredTypeArguments($clazz, null, _root_.java.util.Arrays.asList(..CODE
CRITICAL…/apache/fory/scala/internal/ForySerializerMacros.scala1120 org.apache.fory.util.DefaultValueUtils.getScalaDefaultValue(CODE
CRITICAL…/apache/fory/scala/internal/ForySerializerMacros.scala1314 org.apache.fory.reflect.FieldAccessor.createAccessor(CODE
CRITICAL…/apache/fory/scala/internal/ForySerializerMacros.scala1365 org.apache.fory.serializer.GraphMemoryEstimates.shallowObjectBytes(cls).toLongCODE
CRITICALbenchmarks/java/run.sh182BENCHMARK_REGEX="org.apache.fory.benchmark.XlangBenchmark.BM_(${SERIALIZERS})_(${DATA_TYPES})_(Serialize|Deserialize)"CODE
CRITICAL…main/java/org/apache/fory/benchmark/ZeroCopySuite.java270 return org.apache.fory.benchmark.state.FstState.FstBenchmarkState.serialize(CODE
CRITICAL…main/java/org/apache/fory/benchmark/ZeroCopySuite.java275 return org.apache.fory.benchmark.state.FstState.FstBenchmarkState.deserialize(CODE
CRITICAL…c/main/java/org/apache/fory/benchmark/data/Struct.java148 + " return org.apache.fory.benchmark.data.Struct.toString(this);\n"CODE
CRITICAL…c/main/java/org/apache/fory/benchmark/data/Struct.java151 + " return org.apache.fory.benchmark.data.Struct.equalsWith(this, o);\n"CODE
CRITICAL…c/main/java/org/apache/fory/benchmark/data/Struct.java154 + " return org.apache.fory.benchmark.data.Struct.calcHashCode(this);\n"CODE
CRITICALcompiler/fory_compiler/generators/services/scala.py500 " com.google.common.util.concurrent.MoreExecutors.directExecutor())",CODE
Unused Imports289 hits · 197 pts
SeverityFileLineSnippetContext
LOWpython/pyfory/annotation.py29CODE
LOWpython/pyfory/annotation.py29CODE
LOWpython/pyfory/annotation.py29CODE
LOWpython/pyfory/annotation.py29CODE
LOWpython/pyfory/annotation.py29CODE
LOWpython/pyfory/annotation.py29CODE
LOWpython/pyfory/annotation.py29CODE
LOWpython/pyfory/annotation.py29CODE
LOWpython/pyfory/annotation.py29CODE
LOWpython/pyfory/annotation.py29CODE
LOWpython/pyfory/annotation.py29CODE
LOWpython/pyfory/annotation.py29CODE
LOWpython/pyfory/annotation.py29CODE
LOWpython/pyfory/__init__.py18CODE
LOWpython/pyfory/__init__.py19CODE
LOWpython/pyfory/__init__.py19CODE
LOWpython/pyfory/__init__.py29CODE
LOWpython/pyfory/__init__.py34CODE
LOWpython/pyfory/__init__.py36CODE
LOWpython/pyfory/__init__.py36CODE
LOWpython/pyfory/__init__.py36CODE
LOWpython/pyfory/__init__.py36CODE
LOWpython/pyfory/__init__.py36CODE
LOWpython/pyfory/__init__.py36CODE
LOWpython/pyfory/__init__.py36CODE
LOWpython/pyfory/__init__.py36CODE
LOWpython/pyfory/__init__.py36CODE
LOWpython/pyfory/__init__.py36CODE
LOWpython/pyfory/__init__.py36CODE
LOWpython/pyfory/__init__.py36CODE
LOWpython/pyfory/__init__.py36CODE
LOWpython/pyfory/__init__.py36CODE
LOWpython/pyfory/__init__.py36CODE
LOWpython/pyfory/__init__.py36CODE
LOWpython/pyfory/__init__.py36CODE
LOWpython/pyfory/__init__.py36CODE
LOWpython/pyfory/__init__.py36CODE
LOWpython/pyfory/__init__.py36CODE
LOWpython/pyfory/__init__.py36CODE
LOWpython/pyfory/__init__.py36CODE
LOWpython/pyfory/__init__.py36CODE
LOWpython/pyfory/__init__.py36CODE
LOWpython/pyfory/__init__.py36CODE
LOWpython/pyfory/__init__.py36CODE
LOWpython/pyfory/__init__.py36CODE
LOWpython/pyfory/__init__.py36CODE
LOWpython/pyfory/__init__.py36CODE
LOWpython/pyfory/__init__.py36CODE
LOWpython/pyfory/__init__.py36CODE
LOWpython/pyfory/__init__.py36CODE
LOWpython/pyfory/__init__.py36CODE
LOWpython/pyfory/__init__.py36CODE
LOWpython/pyfory/__init__.py36CODE
LOWpython/pyfory/__init__.py36CODE
LOWpython/pyfory/__init__.py36CODE
LOWpython/pyfory/__init__.py36CODE
LOWpython/pyfory/__init__.py36CODE
LOWpython/pyfory/__init__.py36CODE
LOWpython/pyfory/__init__.py36CODE
LOWpython/pyfory/__init__.py36CODE
229 more matches not shown…
Decorative Section Separators42 hits · 135 pts
SeverityFileLineSnippetContext
MEDIUMpython/pyfory/policy.py147 # ============================================================================COMMENT
MEDIUMpython/pyfory/policy.py149 # ============================================================================COMMENT
MEDIUMpython/pyfory/policy.py193 # ============================================================================COMMENT
MEDIUMpython/pyfory/policy.py195 # ============================================================================COMMENT
MEDIUMpython/pyfory/policy.py357 # ============================================================================COMMENT
MEDIUMpython/pyfory/policy.py359 # ============================================================================COMMENT
MEDIUMpython/pyfory/tests/xlang_test_main.py1094# ============================================================================COMMENT
MEDIUMpython/pyfory/tests/xlang_test_main.py1096# ============================================================================COMMENT
MEDIUMpython/pyfory/tests/xlang_test_main.py1414# ============================================================================COMMENT
MEDIUMpython/pyfory/tests/xlang_test_main.py1416# ============================================================================COMMENT
MEDIUMpython/pyfory/tests/xlang_test_main.py1609# ============================================================================COMMENT
MEDIUMpython/pyfory/tests/xlang_test_main.py1611# ============================================================================COMMENT
MEDIUMpython/pyfory/tests/xlang_test_main.py1627# ============================================================================COMMENT
MEDIUMpython/pyfory/tests/xlang_test_main.py1629# ============================================================================COMMENT
MEDIUMpython/pyfory/tests/xlang_test_main.py1768# ============================================================================COMMENT
MEDIUMpython/pyfory/tests/xlang_test_main.py1770# ============================================================================COMMENT
MEDIUMpython/pyfory/tests/xlang_test_main.py87# ============================================================================COMMENT
MEDIUMpython/pyfory/tests/xlang_test_main.py89# ============================================================================COMMENT
MEDIUMpython/pyfory/tests/xlang_test_main.py261# ============================================================================COMMENT
MEDIUMpython/pyfory/tests/xlang_test_main.py263# ============================================================================COMMENT
MEDIUMpython/pyfory/tests/xlang_test_main.py299# ============================================================================COMMENT
MEDIUMpython/pyfory/tests/xlang_test_main.py301# ============================================================================COMMENT
MEDIUMpython/pyfory/tests/xlang_test_main.py344# ============================================================================COMMENT
MEDIUMpython/pyfory/tests/xlang_test_main.py346# ============================================================================COMMENT
MEDIUMpython/pyfory/tests/xlang_test_main.py432# ============================================================================COMMENT
MEDIUMpython/pyfory/tests/xlang_test_main.py434# ============================================================================COMMENT
MEDIUMpython/pyfory/tests/xlang_test_main.py1695# ============================================================================COMMENT
MEDIUMpython/pyfory/tests/xlang_test_main.py1697# ============================================================================COMMENT
MEDIUMpython/pyfory/tests/test_struct.py1846# ============================================================================COMMENT
MEDIUMpython/pyfory/tests/test_struct.py1848# ============================================================================COMMENT
MEDIUMexamples/cpp/hello_world/CMakeLists.txt30# =============================================================================COMMENT
MEDIUMexamples/cpp/hello_world/CMakeLists.txt32# =============================================================================COMMENT
MEDIUMexamples/cpp/hello_row/CMakeLists.txt30# =============================================================================COMMENT
MEDIUMexamples/cpp/hello_row/CMakeLists.txt32# =============================================================================COMMENT
MEDIUMbenchmarks/cpp/CMakeLists.txt40# =============================================================================COMMENT
MEDIUMbenchmarks/cpp/CMakeLists.txt42# =============================================================================COMMENT
MEDIUMbenchmarks/cpp/CMakeLists.txt94# =============================================================================COMMENT
MEDIUMbenchmarks/cpp/CMakeLists.txt96# =============================================================================COMMENT
MEDIUMbenchmarks/cpp/CMakeLists.txt127# =============================================================================COMMENT
MEDIUMbenchmarks/cpp/CMakeLists.txt129# =============================================================================COMMENT
MEDIUMbenchmarks/cpp/CMakeLists.txt154# =============================================================================COMMENT
MEDIUMbenchmarks/cpp/CMakeLists.txt156# =============================================================================COMMENT
Cross-File Repetition23 hits · 115 pts
SeverityFileLineSnippetContext
HIGHcompiler/fory_compiler/tests/test_scala_generator.py0import "common.fdl"; message holder [id=201] { optional common common = 1; }STRING
HIGHcompiler/fory_compiler/tests/test_kotlin_generator.py0import "common.fdl"; message holder [id=201] { optional common common = 1; }STRING
HIGHcompiler/fory_compiler/tests/test_generated_code.py0import "common.fdl"; message holder [id=201] { optional common common = 1; }STRING
HIGHcompiler/fory_compiler/tests/test_scala_generator.py0package app; import "common.fdl"; message holder [id=201] { common common = 1; }STRING
HIGHcompiler/fory_compiler/tests/test_kotlin_generator.py0package app; import "common.fdl"; message holder [id=201] { common common = 1; }STRING
HIGHcompiler/fory_compiler/tests/test_generated_code.py0package app; import "common.fdl"; message holder [id=201] { common common = 1; }STRING
HIGHcompiler/fory_compiler/tests/test_swift_generator.py0package demo; message money [id=100] { decimal amount = 1; } union valueunion [id=101] { decimal amount = 1; money moneySTRING
HIGHcompiler/fory_compiler/tests/test_javascript_codegen.py0package demo; message money [id=100] { decimal amount = 1; } union valueunion [id=101] { decimal amount = 1; money moneySTRING
HIGHcompiler/fory_compiler/tests/test_dart_generator.py0package demo; message money [id=100] { decimal amount = 1; } union valueunion [id=101] { decimal amount = 1; money moneySTRING
HIGHcompiler/fory_compiler/generators/java.py0return true if a type definition comes from an imported idl file.STRING
HIGHcompiler/fory_compiler/generators/cpp.py0return true if a type definition comes from an imported idl file.STRING
HIGHcompiler/fory_compiler/generators/python.py0return true if a type definition comes from an imported idl file.STRING
HIGHcompiler/fory_compiler/generators/go.py0return true if a type definition comes from an imported idl file.STRING
HIGHcompiler/fory_compiler/generators/javascript.py0return true if a type definition comes from an imported idl file.STRING
HIGHcompiler/fory_compiler/generators/rust.py0return true if a type definition comes from an imported idl file.STRING
HIGHcompiler/fory_compiler/generators/java.py0collect imports for a message and its nested types recursively.STRING
HIGHcompiler/fory_compiler/generators/python.py0collect imports for a message and its nested types recursively.STRING
HIGHcompiler/fory_compiler/generators/go.py0collect imports for a message and its nested types recursively.STRING
HIGHcompiler/fory_compiler/generators/java.py0generate registration code for a message and its nested types.STRING
HIGHcompiler/fory_compiler/generators/cpp.py0generate registration code for a message and its nested types.STRING
HIGHcompiler/fory_compiler/generators/python.py0generate registration code for a message and its nested types.STRING
HIGHcompiler/fory_compiler/generators/go.py0generate registration code for a message and its nested types.STRING
HIGHcompiler/fory_compiler/generators/rust.py0generate registration code for a message and its nested types.STRING
Excessive Try-Catch Wrapping78 hits · 114 pts
SeverityFileLineSnippetContext
LOWpython/README.md887except Exception as e:CODE
LOWpython/README.md1037except Exception as e:CODE
LOWpython/README.md1045except Exception as e:CODE
LOWpython/pyfory/codegen.py164 except Exception as e:CODE
LOWpython/pyfory/tests/test_stateful_reproduction.py127 except Exception as e:CODE
MEDIUMpython/pyfory/tests/test_stateful_reproduction.py128 print(f"Error in repr/comparison: {e}")CODE
LOWpython/pyfory/tests/test_thread_safe.py68 except Exception as e:CODE
LOWpython/pyfory/tests/test_thread_safe.py165 except Exception as e:CODE
MEDIUMpython/pyfory/tests/test_thread_safe.py62def serialize_deserialize(thread_id):CODE
MEDIUMpython/pyfory/tests/test_thread_safe.py159def serialize_data(thread_id):CODE
LOWpython/pyfory/meta/test_meta_compressor.py97 except Exception as e:CODE
MEDIUMpython/pyfory/meta/test_meta_compressor.py87def compress_worker():CODE
MEDIUMpython/pyfory/meta/typedef.py1031def _numpy_uint8_type():CODE
LOWpython/pyfory/meta/typedef.py258 except Exception:CODE
LOWpython/pyfory/meta/typedef.py479 except Exception:CODE
LOWpython/pyfory/meta/typedef.py496 except Exception:CODE
LOWpython/pyfory/meta/typedef.py502 except Exception:CODE
LOWpython/pyfory/meta/typedef.py1331 except Exception as e:CODE
LOWpython/pyfory/meta/typedef.py1461 except Exception as e:CODE
LOW…egration_tests/idl_tests/python/idl_tests/roundtrip.py214 except Exception:CODE
MEDIUMci/build_linux_wheels.py202 print(f"Error running docker: {e}", file=sys.stderr)CODE
LOWci/tasks/java.py47 except Exception:CODE
MEDIUMci/tasks/java.py25def get_jdk_major_version():CODE
LOWci/tasks/rust.py55 except Exception as e:CODE
LOWci/tasks/rust.py63 except Exception as e:CODE
LOWdocs/object-serialization/python/troubleshooting.md159except Exception as e:CODE
LOWdocs/object-serialization/python/troubleshooting.md167except Exception as e:CODE
MEDIUMbenchmarks/go/benchmark_report.py448 print("Error: No benchmark results found.")CODE
MEDIUMbenchmarks/go/benchmark_report.py453 print("Error: Could not parse benchmark results.")CODE
MEDIUMbenchmarks/python/fory_benchmark.py544 print(f"Error: Invalid benchmark names: {', '.join(invalid)}")CODE
MEDIUMbenchmarks/python/fory_benchmark.py559 print(f"Error: Invalid serializer names: {', '.join(invalid)}")CODE
MEDIUMbenchmarks/python/fory_benchmark.py563 print("Error: msgpack is not installed.")CODE
LOWbenchmarks/dart/benchmark_report.py128 except Exception:CODE
MEDIUMbenchmarks/dart/benchmark_report.py121def detect_memory_gb() -> str:CODE
LOWbenchmarks/cpp/benchmark_report.py113 except Exception as e:CODE
MEDIUMbenchmarks/cpp/benchmark_report.py102def get_system_info():CODE
MEDIUMcompiler/fory_compiler/cli.py1147 print(f"Error: Root not found: {root}", file=sys.stderr)CODE
MEDIUMcompiler/fory_compiler/cli.py1150 print(f"Error: Root is not a directory: {root}", file=sys.stderr)CODE
MEDIUMcompiler/fory_compiler/cli.py1159 print(f"Error deleting {file_path}: {e}", file=sys.stderr)CODE
MEDIUMcompiler/fory_compiler/cli.py228 print(f"Error reading {file_path}: {e}", file=sys.stderr)CODE
MEDIUMcompiler/fory_compiler/cli.py232 print(f"Error: {e}", file=sys.stderr)CODE
MEDIUMcompiler/fory_compiler/cli.py340 print(f"Error: {e}", file=sys.stderr)CODE
MEDIUMcompiler/fory_compiler/cli.py361 print(f"Error: {e}", file=sys.stderr)CODE
MEDIUMcompiler/fory_compiler/cli.py720 print(f"Error: Unknown language(s): {', '.join(invalid)}", file=sys.stderr)CODE
MEDIUMcompiler/fory_compiler/cli.py763 print(f"Error reading {file_path}: {e}", file=sys.stderr)CODE
MEDIUMcompiler/fory_compiler/cli.py766 print(f"Error: {e}", file=sys.stderr)CODE
MEDIUMcompiler/fory_compiler/cli.py801 print(f"Error: {error}", file=sys.stderr)CODE
MEDIUMcompiler/fory_compiler/cli.py826 print(f"Error: {e}", file=sys.stderr)CODE
MEDIUMcompiler/fory_compiler/cli.py923 print(f"Error reading {file_path}: {e}", file=sys.stderr)CODE
MEDIUMcompiler/fory_compiler/cli.py927 print(f"Error: {e}", file=sys.stderr)CODE
MEDIUMcompiler/fory_compiler/cli.py1041 print("Error: No target languages specified.", file=sys.stderr)CODE
MEDIUMcompiler/fory_compiler/cli.py1048 print(f"Error: Unknown language(s): {', '.join(invalid)}", file=sys.stderr)CODE
MEDIUMcompiler/fory_compiler/cli.py1092 print("Error: --grpc-python-mode requires --grpc.", file=sys.stderr)CODE
MEDIUMcompiler/fory_compiler/cli.py1112 print(f"Error: File not found: {file_path}", file=sys.stderr)CODE
LOWcompiler/fory_compiler/generators/java.py151 except Exception:CODE
LOWcompiler/fory_compiler/generators/java.py171 except Exception:CODE
LOWcompiler/fory_compiler/generators/dart.py361 except Exception:CODE
LOWcompiler/fory_compiler/generators/dart.py370 except Exception:CODE
LOWcompiler/fory_compiler/generators/cpp.py795 except Exception:CODE
LOWcompiler/fory_compiler/generators/cpp.py821 except Exception:CODE
18 more matches not shown…
Deep Nesting132 hits · 108 pts
SeverityFileLineSnippetContext
LOWpython/pyfory/field.py107CODE
LOWpython/pyfory/registry.py679CODE
LOWpython/pyfory/registry.py737CODE
LOWpython/pyfory/registry.py847CODE
LOWpython/pyfory/registry.py929CODE
LOWpython/pyfory/registry.py1092CODE
LOWpython/pyfory/converter.py116CODE
LOWpython/pyfory/type_util.py81CODE
LOWpython/pyfory/type_util.py357CODE
LOWpython/pyfory/type_util.py527CODE
LOWpython/pyfory/collection.py101CODE
LOWpython/pyfory/collection.py205CODE
LOWpython/pyfory/collection.py420CODE
LOWpython/pyfory/collection.py526CODE
LOWpython/pyfory/serializer.py205CODE
LOWpython/pyfory/serializer.py1043CODE
LOWpython/pyfory/serializer.py1275CODE
LOWpython/pyfory/serializer.py1320CODE
LOWpython/pyfory/serializer.py1370CODE
LOWpython/pyfory/serializer.py1630CODE
LOWpython/pyfory/struct.py392CODE
LOWpython/pyfory/struct.py290CODE
LOWpython/pyfory/struct.py314CODE
LOWpython/pyfory/struct.py585CODE
LOWpython/pyfory/struct.py854CODE
LOWpython/pyfory/struct.py1064CODE
LOWpython/pyfory/tests/test_metastring.py62CODE
LOWpython/pyfory/meta/metastring.py104CODE
LOWpython/pyfory/meta/metastring.py177CODE
LOWpython/pyfory/meta/metastring.py200CODE
LOWpython/pyfory/meta/metastring.py301CODE
LOWpython/pyfory/meta/metastring.py379CODE
LOWpython/pyfory/meta/metastring.py534CODE
LOWpython/pyfory/meta/typedef.py1106CODE
LOWpython/pyfory/meta/typedef.py1150CODE
LOWpython/pyfory/meta/typedef.py1335CODE
LOWpython/pyfory/meta/typedef.py1465CODE
LOWpython/pyfory/meta/typedef.py204CODE
LOWpython/pyfory/meta/typedef.py253CODE
LOWpython/pyfory/format/columnar.py28CODE
LOWpython/pyfory/format/columnar.py70CODE
LOWpython/pyfory/format/infer.py229CODE
LOWpython/pyfory/format/infer.py257CODE
LOWpython/pyfory/format/infer.py319CODE
LOWpython/pyfory/format/infer.py276CODE
LOWpython/pyfory/format/infer.py338CODE
LOWpython/pyfory/format/schema.py158CODE
LOWpython/pyfory/format/schema.py192CODE
LOWpython/pyfory/format/schema.py231CODE
LOWpython/pyfory/format/schema.py267CODE
LOWci/release.py253CODE
LOWci/release.py898CODE
LOWci/release.py1032CODE
LOWci/release.py1767CODE
LOWci/release.py1913CODE
LOWci/extract_cpp_doc_code.py51CODE
LOWci/generate_release_note.py21CODE
LOWci/run_ci.py246CODE
LOWci/tasks/java.py398CODE
LOWci/tasks/kotlin.py221CODE
72 more matches not shown…
Self-Referential Comments16 hits · 51 pts
SeverityFileLineSnippetContext
MEDIUMpython/pyfory/utils.py24# This method is derived from https://github.com/mars-project/mars/blob/c36c53fa22e10ef9477d9c454401a2f281375f31/mars/utCOMMENT
MEDIUMpython/pyfory/type_util.py581# This method is derived from https://github.com/ericvsmith/dataclasses/blob/5f6568c3468f872e8f447dc20666628387786397/daCOMMENT
MEDIUMpython/pyfory/type_util.py590 # Create a new dict for our new class.COMMENT
MEDIUMpython/pyfory/serializer.py1395 # Create the object using the callable and argsCOMMENT
MEDIUMpython/pyfory/serializer.py1803 # Create a globals dictionary with module's globals as the baseCOMMENT
MEDIUMpython/pyfory/tests/test_class_serializer.py40 # Create an instance of the local classCOMMENT
MEDIUMpython/pyfory/tests/test_class_serializer.py78 # Create a local class with closureCOMMENT
MEDIUMpython/pyfory/tests/test_class_serializer.py186 # Define a nested global class (defined at module level but nested in structure)COMMENT
MEDIUMpython/pyfory/tests/test_typedef_encoding.py310 # Create a mock resolverCOMMENT
MEDIUMpython/pyfory/tests/test_typedef_encoding.py320 # Create a buffer from the encoded dataCOMMENT
MEDIUMpython/pyfory/tests/test_stateful_serializer.py260 # Create a list with the same object referenced twiceCOMMENT
MEDIUMpython/pyfory/tests/test_function.py102 # Create a nested functionCOMMENT
MEDIUMpython/pyfory/meta/typedef_decoder.py131 # Create a new buffer for meta dataCOMMENT
MEDIUMci/tasks/java.py171 # Create the root elementCOMMENT
MEDIUMbenchmarks/java/plot_map_benchmark.py75# Create the subplots for datatype "int"COMMENT
MEDIUMbenchmarks/java/plot_map_benchmark.py117# Create the subplots for datatype "string"COMMENT
Fake / Example Data45 hits · 49 pts
SeverityFileLineSnippetContext
LOWintegration_tests/idl_tests/go/idl_roundtrip_test.go48 Number: "555-0100",CODE
LOWintegration_tests/idl_tests/go/idl_roundtrip_test.go52 Number: "555-0111",CODE
LOW…egration_tests/idl_tests/python/idl_tests/roundtrip.py60 number="555-0100",CODE
LOW…egration_tests/idl_tests/python/idl_tests/roundtrip.py64 number="555-0111",CODE
LOW…tion_tests/idl_tests/dart/test/idl_roundtrip_test.dart64 ..number = '555-0100'CODE
LOW…tion_tests/idl_tests/dart/test/idl_roundtrip_test.dart67 ..number = '555-0111'CODE
LOWintegration_tests/idl_tests/rust/tests/idl_roundtrip.rs49 number: "555-0100".to_string(),CODE
LOWintegration_tests/idl_tests/rust/tests/idl_roundtrip.rs53 number: "555-0111".to_string(),CODE
LOW…t/java/org/apache/fory/idl_tests/IdlRoundTripTest.java953 mobile.setNumber("555-0100");CODE
LOW…t/java/org/apache/fory/idl_tests/IdlRoundTripTest.java957 work.setNumber("555-0111");CODE
LOW…ackage/Tests/IdlRoundTripTests/IdlRoundTripTests.swift342 let mobile = Addressbook.Person.PhoneNumber(number: "555-0100", phoneType: .mobile)CODE
LOW…ackage/Tests/IdlRoundTripTests/IdlRoundTripTests.swift343 let work = Addressbook.Person.PhoneNumber(number: "555-0111", phoneType: .work)CODE
LOW…tion_tests/idl_tests/csharp/IdlTests/RoundtripTests.cs409 Number = "555-0100",CODE
LOW…tion_tests/idl_tests/csharp/IdlTests/RoundtripTests.cs414 Number = "555-0111",CODE
LOWintegration_tests/idl_tests/javascript/roundtrip.ts272 buildPhoneNumber("555-0100", Person.PhoneType.MOBILE),CODE
LOWintegration_tests/idl_tests/javascript/roundtrip.ts273 buildPhoneNumber("555-0111", Person.PhoneType.WORK),CODE
LOW…tion_tests/idl_tests/javascript/test/roundtrip.test.ts212 buildPhoneNumber("555-0100", Person.PhoneType.MOBILE),CODE
LOW…tion_tests/idl_tests/javascript/test/roundtrip.test.ts213 buildPhoneNumber("555-0111", Person.PhoneType.WORK),CODE
LOWrust/README.md124 name: "John Doe".to_string(),CODE
LOWrust/README.md127 street: "123 Main St".to_string(),CODE
LOWrust/README.md377 address: "123 Main St".to_string(),CODE
LOWrust/tests/tests/test_box.rs59 name: "John Doe".to_string(),CODE
LOWrust/tests/tests/test_box.rs83 name: "Jane Doe".to_string(),CODE
LOWrust/tests/tests/test_field_meta.rs1080 street_address: "123 Main Street".to_string(),CODE
LOWrust/tests/tests/test_field_meta.rs1088 street_address: "123 Main Street".to_string(),CODE
LOWrust/fory-core/src/util/string_util.rs652 assert!(murmurhash3_x64_128("Lorem ipsum dolor sit amet, consectetur adipiscing elit. Etiam at consequat massa. CODE
LOWrust/fory-core/src/util/string_util.rs652 assert!(murmurhash3_x64_128("Lorem ipsum dolor sit amet, consectetur adipiscing elit. Etiam at consequat massa. CODE
LOWdocs/object-serialization/rust/schema-evolution.md59 address: "123 Main St".to_string(),CODE
LOWdocs/object-serialization/rust/basic-serialization.md62 name: "John Doe".to_string(),CODE
LOWdocs/object-serialization/rust/basic-serialization.md65 street: "123 Main St".to_string(),CODE
LOWdocs/object-serialization/scala/native.md174 Company("Acme", Address("123 Main St", "Springfield")),CODE
LOWdocs/object-serialization/cpp/schema-evolution.md247EmployeeV1 emp_v1{"Jane Doe", {"123 Main St", "NYC"}};CODE
LOWdocs/object-serialization/cpp/schema-evolution.md247EmployeeV1 emp_v1{"Jane Doe", {"123 Main St", "NYC"}};CODE
LOWdocs/object-serialization/cpp/schema-evolution.md252assert(emp_v2.name == "Jane Doe");CODE
LOWdocs/object-serialization/cpp/schema-evolution.md253assert(emp_v2.home_address.street == "123 Main St");CODE
LOWdocs/object-serialization/cpp/basic-serialization.md78 "John Doe",CODE
LOWdocs/object-serialization/cpp/basic-serialization.md80 {"123 Main St", "New York", "USA"},CODE
LOWcpp/README.md120 "John Doe",CODE
LOWcpp/README.md122 Address{"123 Main St", "New York", "USA"},CODE
LOWcpp/README.md220PersonV1 v1{"Alice", 30, "123 Main St"};CODE
LOWjavascript/benchmark/index.js96 name: "John Doe",CODE
LOWjavascript/benchmark/index.js100 street: "123 Main St",CODE
LOWjavascript/benchmark/index.js108 number: "555-1234",CODE
LOWjavascript/benchmark/index.js112 number: "555-5678",CODE
LOWjavascript/benchmark/platform-buffer.js26 name: "John Doe",CODE
Structural Annotation Overuse21 hits · 40 pts
SeverityFileLineSnippetContext
LOW…pache/fory/serializer/UnknownClassSerializersTest.java550 // Step 1: Serialize with fory1COMMENT
LOW…pache/fory/serializer/UnknownClassSerializersTest.java556 // Step 2: Deserialize with fory2 (gets UnknownStruct)COMMENT
LOW…pache/fory/serializer/UnknownClassSerializersTest.java561 // Step 3: Serialize UnknownStruct with fory2COMMENT
LOW…pache/fory/serializer/UnknownClassSerializersTest.java564 // Step 4: Deserialize again with fory2 (should get UnknownStruct with same values)COMMENT
LOW…g/apache/fory/serializer/WriteReplaceCrossJvmTest.java315 // Step 1: Serialize proxy on "JVM A"COMMENT
LOW…g/apache/fory/serializer/WriteReplaceCrossJvmTest.java319 // Step 2: Deserialize on "JVM B" (no ProxyEntity class)COMMENT
LOW…g/apache/fory/serializer/WriteReplaceCrossJvmTest.java323 // Step 3: Re-serialize on "JVM B"COMMENT
LOW…g/apache/fory/serializer/WriteReplaceCrossJvmTest.java326 // Step 4: Deserialize back on "JVM A"COMMENT
LOWdocs/specification/xlang_serialization_spec.md1727##### Step 1: Field identifierCOMMENT
LOWdocs/specification/xlang_serialization_spec.md1748##### Step 2: Group assignmentCOMMENT
LOWdocs/specification/xlang_serialization_spec.md1758##### Step 3: Intra-group orderingCOMMENT
LOWdocs/object-serialization/javascript/references.md30## Step 1: Enable Reference Tracking on the `Fory` InstanceCOMMENT
LOWdocs/object-serialization/javascript/references.md36## Step 2: Mark the Fields That Can Have Shared or Circular ReferencesCOMMENT
LOWdocs/compiler/protobuf-idl.md294### Step 1: Translate Schema SyntaxCOMMENT
LOWdocs/compiler/protobuf-idl.md300### Step 2: Convert `oneof` and Special TypesCOMMENT
LOWdocs/compiler/protobuf-idl.md305### Step 3: Replace Protobuf Workarounds with `ref`COMMENT
LOWdocs/compiler/protobuf-idl.md310### Step 4: Update Build/CodegenCOMMENT
LOWdocs/compiler/protobuf-idl.md336### Step 5: Run Compatibility ChecksCOMMENT
LOWbenchmarks/cpp/run.sh170# Step 1: BuildCOMMENT
LOWbenchmarks/cpp/run.sh194# Step 2: Run benchmarkCOMMENT
LOWbenchmarks/cpp/run.sh209# Step 3: Generate reportCOMMENT
Docstring Block Structure8 hits · 40 pts
SeverityFileLineSnippetContext
HIGHpython/pyfory/policy.py152Authorize instantiation of a class during deserialization. This hook is called before creating an instance of aSTRING
HIGHpython/pyfory/policy.py362Intercept and validate __reduce__ protocol callable invocation. This hook is called when deserializing an objecSTRING
HIGHpython/pyfory/policy.py423Inspect and validate an object after __reduce__ protocol reconstruction. This hook is called after an object haSTRING
HIGHpython/pyfory/policy.py474Intercept and validate __setstate__ protocol before state restoration. This hook is called when deserializing aSTRING
HIGHpython/pyfory/format/infer.py258Convert an Arrow Schema to a Fory Schema. This is for compatibility with code that uses PyArrow schemas. Args:STRING
HIGHpython/pyfory/format/infer.py320Convert a Fory Schema to an Arrow Schema. This is for compatibility with ArrowWriter which requires Arrow schemas. STRING
HIGHpython/pyfory/format/schema.py32 Convert an Arrow data type to a Fory TypeId value. Args: arrow_type: A PyArrow DataType instance. STRING
HIGHpython/pyfory/format/schema.py96 Convert a Fory TypeId value to an Arrow data type. Args: type_id: The Fory TypeId value (int). STRING
Redundant / Tautological Comments23 hits · 34 pts
SeverityFileLineSnippetContext
LOWpython/pyfory/registry.py932 # Check if it's a Union type firstCOMMENT
LOWpython/pyfory/serializer.py1322 # Check if the object has a custom __reduce_ex__ method (not just the default from object)COMMENT
LOWpython/pyfory/struct.py347 # Check if it's an abstract class using inspect.isabstractCOMMENT
LOWpython/pyfory/struct.py429 # Check if fory has field_nullable global settingCOMMENT
LOWpython/pyfory/tests/xlang_test_main.py893 # Set f2 to empty string for serialization (match Go behavior)COMMENT
LOWpython/pyfory/meta/meta_compressor.py160 # Check if the compressor has custom __eq__ and __hash__ methodsCOMMENT
LOWci/release.py171 # Check if branch exists, if not create itCOMMENT
LOWci/extract_cpp_doc_code.py52 # Check if the code block is a complete, runnable example.A complete example should have a main function with all coCOMMENT
LOWci/extract_cpp_doc_code.py56 # Check if there are statements outside of any functionCOMMENT
LOWci/extract_cpp_doc_code.py75 # Check if entering mainCOMMENT
LOWci/deploy.sh56 # Check if the tag starts with 'v' and strip itCOMMENT
LOWci/tasks/python_container_build_script.sh36 # Check if GITHUB_REF_NAME is available and use it for verificationCOMMENT
LOWbenchmarks/go/run.sh156# Check if protoc is installedCOMMENT
LOWbenchmarks/go/run.sh167# Check if protoc-gen-go is installedCOMMENT
LOWbenchmarks/go/run.sh233 # Check if Python is availableCOMMENT
LOWbenchmarks/cpp/profile.sh113# Check if benchmark existsCOMMENT
LOWbenchmarks/cpp/profile.sh197 # Check if process is runningCOMMENT
LOWcompiler/fory_compiler/cli.py874 # Check if distinct source files map to the same output file, e.g. due to naming normalizationCOMMENT
LOWcompiler/fory_compiler/frontend/fdl/parser.py1056 # Check if it's a primitive typeCOMMENT
LOWcompiler/fory_compiler/generators/javascript.py497 # Check if this NamedType matches a primitive type nameCOMMENT
LOWcompiler/fory_compiler/generators/javascript.py511 # Check if it matches any primitive kind directlyCOMMENT
LOWcompiler/fory_compiler/generators/base.py279 # Check if value_name starts with the prefixCOMMENT
LOWcompiler/fory_compiler/generators/base.py286 # Check if remainder is a valid identifier (starts with letter)COMMENT
Verbosity Indicators11 hits · 22 pts
SeverityFileLineSnippetContext
LOW…pache/fory/serializer/UnknownClassSerializersTest.java550 // Step 1: Serialize with fory1COMMENT
LOW…pache/fory/serializer/UnknownClassSerializersTest.java556 // Step 2: Deserialize with fory2 (gets UnknownStruct)COMMENT
LOW…pache/fory/serializer/UnknownClassSerializersTest.java561 // Step 3: Serialize UnknownStruct with fory2COMMENT
LOW…pache/fory/serializer/UnknownClassSerializersTest.java564 // Step 4: Deserialize again with fory2 (should get UnknownStruct with same values)COMMENT
LOW…g/apache/fory/serializer/WriteReplaceCrossJvmTest.java315 // Step 1: Serialize proxy on "JVM A"COMMENT
LOW…g/apache/fory/serializer/WriteReplaceCrossJvmTest.java319 // Step 2: Deserialize on "JVM B" (no ProxyEntity class)COMMENT
LOW…g/apache/fory/serializer/WriteReplaceCrossJvmTest.java323 // Step 3: Re-serialize on "JVM B"COMMENT
LOW…g/apache/fory/serializer/WriteReplaceCrossJvmTest.java326 // Step 4: Deserialize back on "JVM A"COMMENT
LOWbenchmarks/cpp/run.sh170# Step 1: BuildCOMMENT
LOWbenchmarks/cpp/run.sh194# Step 2: Run benchmarkCOMMENT
LOWbenchmarks/cpp/run.sh209# Step 3: Generate reportCOMMENT
Modern Structural Boilerplate17 hits · 17 pts
SeverityFileLineSnippetContext
LOWpython/pyfory/annotation.py172__all__ = [CODE
LOWpython/pyfory/registry.py156logger = logging.getLogger(__name__)CODE
LOWpython/pyfory/type_id.py173__all__ = ["TypeId"]CODE
LOWpython/pyfory/__init__.py140__all__ = [CODE
LOWpython/pyfory/types.py44__all__ = ["TypeId"]CODE
LOWpython/pyfory/utils.py110__all__ = [CODE
LOWpython/pyfory/serializer.py2019__all__ = [CODE
LOWpython/pyfory/_serializer.py55logger = logging.getLogger(__name__)CODE
LOWpython/pyfory/struct.py83logger = logging.getLogger(__name__)CODE
LOWci/release.py37logger = logging.getLogger(__name__)CODE
LOWcompiler/fory_compiler/__init__.py27__all__ = [CODE
LOWcompiler/fory_compiler/frontend/__init__.py23__all__ = ["BaseFrontend", "FrontendError", "FBSFrontend"]CODE
LOWcompiler/fory_compiler/frontend/fbs/__init__.py47__all__ = ["FBSFrontend", "Lexer", "Parser", "LexerError", "ParseError"]CODE
LOWcompiler/fory_compiler/frontend/fdl/__init__.py42__all__ = ["FDLFrontend"]CODE
LOWcompiler/fory_compiler/ir/__init__.py38__all__ = [CODE
LOWcompiler/fory_compiler/ir/types.py89__all__ = [CODE
LOWcompiler/fory_compiler/generators/__init__.py47__all__ = [CODE
AI Slop Vocabulary2 hits · 6 pts
SeverityFileLineSnippetContext
MEDIUMgo/fory/stream.go25// InputStream supports robust sequential deserialization from a stream.COMMENT
MEDIUMgo/fory/float16/float16.go115 // Actually pure bit manipulation is robust if careful.COMMENT
Slop Phrases2 hits · 6 pts
SeverityFileLineSnippetContext
MEDIUM.github/workflows/pr-lint.yml72 # If `subjectPattern` is configured, you can use this property to overrideCOMMENT
MEDIUM.github/workflows/pr-lint.yml89 # Commits spec, you can use these options to customize the parsing of the type, scope andCOMMENT
AI Structural Patterns6 hits · 5 pts
SeverityFileLineSnippetContext
LOWpython/pyfory/field.py107CODE
LOWpython/pyfory/registry.py260CODE
LOWpython/pyfory/_fory.py133CODE
LOWpython/pyfory/meta/typedef_encoder.py130CODE
LOWcompiler/fory_compiler/cli.py727CODE
LOWcompiler/fory_compiler/generators/cpp.py2294CODE
Modern AI Meta-Vocabulary1 hit · 3 pts
SeverityFileLineSnippetContext
MEDIUM…/apache/fory/serializer/converter/FieldConverters.java200 // guardrails remain owned by descriptor-level conversion above.COMMENT
Example Usage Blocks2 hits · 3 pts
SeverityFileLineSnippetContext
LOWcpp/fory/serialization/serializer.h45/// Example usage:COMMENT
LOWcpp/fory/row/schema.h31/// Usage example:COMMENT
Overly Generic Function Names2 hits · 2 pts
SeverityFileLineSnippetContext
LOWpython/pyfory/tests/test_serializer.py1091def test_function(track_ref):CODE
LOWbenchmarks/java/analyze.py497def process_data(filepath: str):CODE