codegreen 0.4.7__tar.gz → 0.4.8__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {codegreen-0.4.7/codegreen.egg-info → codegreen-0.4.8}/PKG-INFO +1 -1
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen/__init__.py +1 -1
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen/cli/cli.py +7 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen/instrumentation/language_runtimes/python/codegreen_runtime.py +24 -0
- {codegreen-0.4.7 → codegreen-0.4.8/codegreen.egg-info}/PKG-INFO +1 -1
- {codegreen-0.4.7 → codegreen-0.4.8}/pyproject.toml +1 -1
- {codegreen-0.4.7 → codegreen-0.4.8}/tests/test_report_audit.py +55 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/CMakeLists.txt +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/LICENSE +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/MANIFEST.in +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/README.md +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/benchmark/__init__.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/benchmark/__main__.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/benchmark/_workload_gpt2.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/benchmark/_workload_gpt2_session.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/benchmark/_workload_gpt2_session_staged.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/benchmark/cg_modes_compare.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/benchmark/compilers.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/benchmark/config.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/benchmark/harness.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/benchmark/profilers.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/benchmark/results.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/benchmark/suites/__init__.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/benchmark/suites/base.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/benchmark/suites/benchmarksgame.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/benchmark/suites/dacapo.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/benchmark/suites/perfopt.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/benchmark/suites/renaissance.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/benchmark/validation/__init__.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/benchmark/validation/analysis.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/benchmark/validation/experiments.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/benchmark/validation/reporting.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen/analysis/__init__.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen/analysis/_ts_java.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen/analysis/cfg/__init__.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen/analysis/cfg/builder.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen/analysis/cfg/callgraph.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen/analysis/cfg/dataflow.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen/analysis/cfg/energy_flow.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen/analysis/cfg/features.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen/analysis/cfg/pdg.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen/analysis/cfg/types.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen/analysis/cfg/visualization.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen/analyzer/__init__.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen/analyzer/plot.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen/cli/__init__.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen/cli/entrypoint.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen/config.json +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen/instrumentation/__init__.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen/instrumentation/ast_processor.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen/instrumentation/bridge_analyze.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen/instrumentation/bridge_instrument.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen/instrumentation/config.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen/instrumentation/configs/TEMPLATE.json +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen/instrumentation/configs/c.json +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen/instrumentation/configs/cpp.json +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen/instrumentation/configs/java.json +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen/instrumentation/configs/javascript.json +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen/instrumentation/configs/python.json +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen/instrumentation/engine.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen/instrumentation/language_configs.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen/instrumentation/language_engine.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen/instrumentation/language_runtimes/c/codegreen_runtime.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen/instrumentation/language_runtimes/cpp/codegreen/runtime.hpp +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen/instrumentation/language_runtimes/java/codegreen/runtime/CodeGreenRuntime.java +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen/instrumentation/language_runtimes/java/codegreen/runtime/CodeGreenStandaloneRuntime.java +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen/utils/__init__.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen/utils/binary.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen/utils/platform.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen.egg-info/SOURCES.txt +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen.egg-info/dependency_links.txt +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen.egg-info/entry_points.txt +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen.egg-info/not-zip-safe +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen.egg-info/requires.txt +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/codegreen.egg-info/top_level.txt +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/requirements.txt +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/setup.cfg +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/setup.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/tests/test_instrumentation.py +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/Programming-Language-Benchmarks/bench/algorithm/binarytrees/2.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/Programming-Language-Benchmarks/bench/algorithm/helloworld/1.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/Programming-Language-Benchmarks/bench/algorithm/knucleotide/1.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/Programming-Language-Benchmarks/bench/algorithm/mandelbrot/1-ffi.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/Programming-Language-Benchmarks/bench/algorithm/mandelbrot/1-mffi.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/Programming-Language-Benchmarks/bench/algorithm/nbody/2.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/Programming-Language-Benchmarks/bench/algorithm/nbody/5.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/Programming-Language-Benchmarks/bench/algorithm/nbody/8-i.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/Programming-Language-Benchmarks/bench/algorithm/nsieve/1.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/Programming-Language-Benchmarks/bench/algorithm/spectral-norm/3.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/Programming-Language-Benchmarks/bench/algorithm/spectral-norm/4.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/Programming-Language-Benchmarks/bench/algorithm/spectral-norm/5-im.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/Programming-Language-Benchmarks/bench/algorithm/spectral-norm/6-im.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/nvim-treesitter/tests/indent/c/aligned_indent.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/nvim-treesitter/tests/indent/c/array.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/nvim-treesitter/tests/indent/c/comment.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/nvim-treesitter/tests/indent/c/compound_lit.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/nvim-treesitter/tests/indent/c/cond.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/nvim-treesitter/tests/indent/c/enum.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/nvim-treesitter/tests/indent/c/expr.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/nvim-treesitter/tests/indent/c/func.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/nvim-treesitter/tests/indent/c/if_else.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/nvim-treesitter/tests/indent/c/issue-1568.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/nvim-treesitter/tests/indent/c/issue-2086.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/nvim-treesitter/tests/indent/c/issue-4079.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/nvim-treesitter/tests/indent/c/issue-4117.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/nvim-treesitter/tests/indent/c/issue-4525.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/nvim-treesitter/tests/indent/c/label.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/nvim-treesitter/tests/indent/c/loop.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/nvim-treesitter/tests/indent/c/no_braces.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/nvim-treesitter/tests/indent/c/preproc_cond.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/nvim-treesitter/tests/indent/c/preproc_func.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/nvim-treesitter/tests/indent/c/string.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/nvim-treesitter/tests/indent/c/struct.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/nvim-treesitter/tests/indent/c/switch.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/nvim-treesitter/tests/indent/c/ternary.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/nvim-treesitter/tests/indent/c/unfinished_comment.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/nvim-treesitter/tests/query/highlights/c/enums-as-constants.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/crates/cli/src/templates/PARSER_NAME.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/crates/cli/src/templates/py-binding.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/crates/generate/src/templates/alloc.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/crates/generate/src/templates/array.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/crates/highlight/include/tree_sitter/highlight.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/crates/tags/include/tree_sitter/tags.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/CMakeLists.txt +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/binding_web/lib/tree-sitter.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/include/tree_sitter/api.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/src/alloc.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/src/alloc.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/src/array.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/src/atomic.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/src/clock.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/src/error_costs.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/src/get_changed_ranges.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/src/get_changed_ranges.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/src/host.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/src/language.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/src/language.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/src/length.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/src/lexer.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/src/lexer.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/src/lib.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/src/node.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/src/parser.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/src/parser.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/src/point.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/src/portable/endian.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/src/query.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/src/reduce_action.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/src/reusable_node.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/src/stack.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/src/stack.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/src/subtree.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/src/subtree.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/src/tree.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/src/tree.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/src/tree_cursor.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/src/tree_cursor.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/src/ts_assert.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/src/unicode/ptypes.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/src/unicode/umachine.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/src/unicode/urename.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/src/unicode/utf.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/src/unicode/utf16.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/src/unicode/utf8.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/src/unicode.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/src/wasm/stdlib.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/src/wasm/wasm-stdlib.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/src/wasm_store.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/src/wasm_store.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/test/fixtures/test_grammars/depends_on_column/scanner.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/test/fixtures/test_grammars/epsilon_external_extra_tokens/scanner.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/test/fixtures/test_grammars/epsilon_external_tokens/scanner.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/test/fixtures/test_grammars/external_and_internal_anonymous_tokens/scanner.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/test/fixtures/test_grammars/external_and_internal_tokens/scanner.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/test/fixtures/test_grammars/external_extra_tokens/scanner.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/test/fixtures/test_grammars/external_tokens/scanner.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/test/fixtures/test_grammars/external_unicode_column_alignment/scanner.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/test/fixtures/test_grammars/get_col_eof/scanner.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/test/fixtures/test_grammars/get_col_should_hang_not_crash/scanner.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/test/fixtures/test_grammars/inverted_external_token/scanner.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/test/fixtures/test_grammars/uses_current_column/scanner.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-c/CMakeLists.txt +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-c/bindings/c/tree_sitter/tree-sitter-c.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-c/bindings/python/tree_sitter_c/binding.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-c/bindings/swift/TreeSitterC/c.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-c/examples/cluster.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-c/examples/malloc.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-c/examples/parser.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-c/src/parser.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-c/src/tree_sitter/alloc.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-c/src/tree_sitter/array.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-c/src/tree_sitter/parser.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-c/test/highlight/keywords.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-c/test/highlight/names.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-cpp/CMakeLists.txt +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-cpp/bindings/c/tree-sitter-cpp.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-cpp/bindings/python/tree_sitter_cpp/binding.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-cpp/bindings/swift/TreeSitterCPP/cpp.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-cpp/examples/marker-index.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-cpp/src/parser.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-cpp/src/scanner.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-cpp/src/tree_sitter/alloc.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-cpp/src/tree_sitter/array.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-cpp/src/tree_sitter/parser.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-java/CMakeLists.txt +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-java/bindings/c/tree-sitter-java.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-java/bindings/python/tree_sitter_java/binding.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-java/bindings/swift/TreeSitterJava/java.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-java/src/parser.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-java/src/tree_sitter/alloc.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-java/src/tree_sitter/array.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-java/src/tree_sitter/parser.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-python/CMakeLists.txt +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-python/bindings/c/tree-sitter-python.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-python/bindings/python/tree_sitter_python/binding.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-python/bindings/swift/TreeSitterPython/python.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-python/src/parser.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-python/src/scanner.c +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-python/src/tree_sitter/alloc.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-python/src/tree_sitter/array.h +0 -0
- {codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-python/src/tree_sitter/parser.h +0 -0
|
@@ -12,7 +12,7 @@ try:
|
|
|
12
12
|
from importlib.metadata import version as _pkg_version
|
|
13
13
|
__version__ = _pkg_version("codegreen")
|
|
14
14
|
except Exception:
|
|
15
|
-
__version__ = "0.4.
|
|
15
|
+
__version__ = "0.4.8" # fallback for dev/editable installs
|
|
16
16
|
__author__ = "Saurabhsingh Rajput"
|
|
17
17
|
__email__ = "saurabh@dal.ca"
|
|
18
18
|
__description__ = "Know the true energy cost of your code"
|
|
@@ -2676,9 +2676,11 @@ def run_command(
|
|
|
2676
2676
|
from datetime import timezone as _tz
|
|
2677
2677
|
from codegreen.instrumentation.language_runtimes.python.codegreen_runtime import (
|
|
2678
2678
|
build_meta_block as _build_meta,
|
|
2679
|
+
_iso_local_now,
|
|
2679
2680
|
)
|
|
2680
2681
|
|
|
2681
2682
|
_meta_started_at = datetime.now(_tz.utc).isoformat(timespec="microseconds")
|
|
2683
|
+
_meta_started_at_local = _iso_local_now()
|
|
2682
2684
|
_meta_t0_mono = time.monotonic()
|
|
2683
2685
|
try:
|
|
2684
2686
|
_meta_hostname = _socket.gethostname()
|
|
@@ -2713,6 +2715,8 @@ def run_command(
|
|
|
2713
2715
|
run_id=_meta_run_id,
|
|
2714
2716
|
started_at_iso=_meta_started_at,
|
|
2715
2717
|
ended_at_iso=datetime.now(_tz.utc).isoformat(timespec="microseconds"),
|
|
2718
|
+
started_at_local_iso=_meta_started_at_local,
|
|
2719
|
+
ended_at_local_iso=_iso_local_now(),
|
|
2716
2720
|
duration_total_s=time.monotonic() - _meta_t0_mono,
|
|
2717
2721
|
hostname=_meta_hostname,
|
|
2718
2722
|
session_name=None,
|
|
@@ -2831,10 +2835,13 @@ def run_command(
|
|
|
2831
2835
|
|
|
2832
2836
|
if json_output:
|
|
2833
2837
|
_meta_ended_at = datetime.now(_tz.utc).isoformat(timespec="microseconds")
|
|
2838
|
+
_meta_ended_at_local = _iso_local_now()
|
|
2834
2839
|
meta_obj = _build_meta(
|
|
2835
2840
|
run_id=_meta_run_id,
|
|
2836
2841
|
started_at_iso=_meta_started_at,
|
|
2837
2842
|
ended_at_iso=_meta_ended_at,
|
|
2843
|
+
started_at_local_iso=_meta_started_at_local,
|
|
2844
|
+
ended_at_local_iso=_meta_ended_at_local,
|
|
2838
2845
|
duration_total_s=time.monotonic() - _meta_t0_mono,
|
|
2839
2846
|
hostname=_meta_hostname,
|
|
2840
2847
|
session_name=None,
|
|
@@ -30,6 +30,19 @@ def _iso_utc_now() -> str:
|
|
|
30
30
|
return datetime.now(timezone.utc).isoformat(timespec="microseconds")
|
|
31
31
|
|
|
32
32
|
|
|
33
|
+
def _iso_local_now() -> str:
|
|
34
|
+
"""Same instant as `_iso_utc_now()` rendered in the host's local timezone
|
|
35
|
+
with explicit offset, e.g. "2026-05-10T11:16:56.209074-07:00". Display-only
|
|
36
|
+
companion to the canonical UTC field; never use for joins/sorts."""
|
|
37
|
+
return datetime.now().astimezone().isoformat(timespec="microseconds")
|
|
38
|
+
|
|
39
|
+
|
|
40
|
+
def _host_timezone_label() -> str:
|
|
41
|
+
"""Best-effort local timezone label, e.g. 'PDT' or '+05:30'."""
|
|
42
|
+
tz = datetime.now().astimezone().tzinfo
|
|
43
|
+
return tz.tzname(datetime.now()) if tz else "unknown"
|
|
44
|
+
|
|
45
|
+
|
|
33
46
|
def _runtime_version() -> str:
|
|
34
47
|
try:
|
|
35
48
|
from importlib.metadata import version as _v
|
|
@@ -145,6 +158,8 @@ def build_meta_block(
|
|
|
145
158
|
domain_support: str = "none",
|
|
146
159
|
domains: Optional[Dict[str, float]] = None,
|
|
147
160
|
record_time_series: bool = False,
|
|
161
|
+
started_at_local_iso: str = "",
|
|
162
|
+
ended_at_local_iso: str = "",
|
|
148
163
|
extras: Optional[Dict] = None,
|
|
149
164
|
) -> Dict:
|
|
150
165
|
"""Single canonical meta-block builder. Shared by Session._build_report()
|
|
@@ -171,6 +186,9 @@ def build_meta_block(
|
|
|
171
186
|
"domain_support": domain_support,
|
|
172
187
|
"outlier_method": rcfg["outlier_method"],
|
|
173
188
|
"iso_timestamp_format": rcfg["iso_timestamp_format"],
|
|
189
|
+
"started_at_local": started_at_local_iso or _iso_local_now(),
|
|
190
|
+
"ended_at_local": ended_at_local_iso or _iso_local_now(),
|
|
191
|
+
"host_timezone": _host_timezone_label(),
|
|
174
192
|
"nemb_abi_version": nemb_abi_version,
|
|
175
193
|
"domain_topology": _domain_topology(domains or {}),
|
|
176
194
|
"timeseries": ({
|
|
@@ -675,6 +693,8 @@ class Session:
|
|
|
675
693
|
self._t0_mono: float = 0.0
|
|
676
694
|
self._started_at_iso: str = ""
|
|
677
695
|
self._ended_at_iso: str = ""
|
|
696
|
+
self._started_at_local_iso: str = ""
|
|
697
|
+
self._ended_at_local_iso: str = ""
|
|
678
698
|
self._run_id: str = uuid.uuid4().hex[:12]
|
|
679
699
|
try:
|
|
680
700
|
self._hostname: str = socket.gethostname()
|
|
@@ -763,6 +783,7 @@ class Session:
|
|
|
763
783
|
self._t0_wall = time.time()
|
|
764
784
|
self._t0_mono = time.monotonic()
|
|
765
785
|
self._started_at_iso = _iso_utc_now()
|
|
786
|
+
self._started_at_local_iso = _iso_local_now()
|
|
766
787
|
_register_pid()
|
|
767
788
|
_ensure_atexit()
|
|
768
789
|
if self._record_ts:
|
|
@@ -974,6 +995,7 @@ class Session:
|
|
|
974
995
|
return self._finalized_report
|
|
975
996
|
if not self._ended_at_iso:
|
|
976
997
|
self._ended_at_iso = _iso_utc_now()
|
|
998
|
+
self._ended_at_local_iso = _iso_local_now()
|
|
977
999
|
total_e = sum(t.energy_j for t in self._tasks if t.depth == 0)
|
|
978
1000
|
wall_d = (time.monotonic() - self._t0_mono) if self._started else 0.0
|
|
979
1001
|
depth0 = [t for t in self._tasks if t.depth == 0]
|
|
@@ -1074,6 +1096,8 @@ class Session:
|
|
|
1074
1096
|
run_id=self._run_id,
|
|
1075
1097
|
started_at_iso=self._started_at_iso,
|
|
1076
1098
|
ended_at_iso=self._ended_at_iso,
|
|
1099
|
+
started_at_local_iso=self._started_at_local_iso,
|
|
1100
|
+
ended_at_local_iso=self._ended_at_local_iso,
|
|
1077
1101
|
duration_total_s=wall_d,
|
|
1078
1102
|
hostname=self._hostname,
|
|
1079
1103
|
session_name=self.name,
|
|
@@ -177,6 +177,61 @@ class TestNamingContract:
|
|
|
177
177
|
assert len(rid) == 12
|
|
178
178
|
int(rid, 16)
|
|
179
179
|
|
|
180
|
+
def test_canonical_started_at_unchanged_with_local_field(self, workload_session: Dict) -> None:
|
|
181
|
+
"""v0.4.8: adding started_at_local must NOT change started_at's UTC contract."""
|
|
182
|
+
v = workload_session["meta"]["started_at"]
|
|
183
|
+
assert v.endswith("+00:00")
|
|
184
|
+
assert "+00:00" in v
|
|
185
|
+
|
|
186
|
+
|
|
187
|
+
# ===========================================================================
|
|
188
|
+
# 2b. LOCAL TIMESTAMPS (v0.4.8+; additive, never replaces UTC fields)
|
|
189
|
+
# ===========================================================================
|
|
190
|
+
class TestLocalTimestamps:
|
|
191
|
+
"""started_at_local, ended_at_local, host_timezone — display-only companions."""
|
|
192
|
+
|
|
193
|
+
def test_local_fields_present(self, workload_session: Dict) -> None:
|
|
194
|
+
m = workload_session["meta"]
|
|
195
|
+
for k in ("started_at_local", "ended_at_local", "host_timezone"):
|
|
196
|
+
assert k in m
|
|
197
|
+
|
|
198
|
+
def test_local_carries_offset_not_naive(self, workload_session: Dict) -> None:
|
|
199
|
+
m = workload_session["meta"]
|
|
200
|
+
s_local = m["started_at_local"]
|
|
201
|
+
e_local = m["ended_at_local"]
|
|
202
|
+
for v in (s_local, e_local):
|
|
203
|
+
parsed = datetime.fromisoformat(v)
|
|
204
|
+
assert parsed.tzinfo is not None, (
|
|
205
|
+
f"local timestamp must carry explicit offset, got {v!r}"
|
|
206
|
+
)
|
|
207
|
+
|
|
208
|
+
def test_local_and_utc_describe_same_instant(self, workload_session: Dict) -> None:
|
|
209
|
+
m = workload_session["meta"]
|
|
210
|
+
s_utc = datetime.fromisoformat(m["started_at"])
|
|
211
|
+
s_local = datetime.fromisoformat(m["started_at_local"])
|
|
212
|
+
delta = abs((s_utc - s_local).total_seconds())
|
|
213
|
+
assert delta < 0.001, (
|
|
214
|
+
f"started_at and started_at_local must point to the same instant; "
|
|
215
|
+
f"delta={delta}s"
|
|
216
|
+
)
|
|
217
|
+
|
|
218
|
+
def test_local_ordered_with_utc(self, workload_session: Dict) -> None:
|
|
219
|
+
m = workload_session["meta"]
|
|
220
|
+
s_local = datetime.fromisoformat(m["started_at_local"])
|
|
221
|
+
e_local = datetime.fromisoformat(m["ended_at_local"])
|
|
222
|
+
assert e_local > s_local
|
|
223
|
+
|
|
224
|
+
def test_host_timezone_label_nonempty(self, workload_session: Dict) -> None:
|
|
225
|
+
assert workload_session["meta"]["host_timezone"]
|
|
226
|
+
assert workload_session["meta"]["host_timezone"] != "unknown" or True
|
|
227
|
+
|
|
228
|
+
def test_canonical_utc_unaffected_when_local_present(self, workload_session: Dict) -> None:
|
|
229
|
+
"""Sanity: the UTC field stays UTC even though local is also emitted."""
|
|
230
|
+
m = workload_session["meta"]
|
|
231
|
+
assert m["iso_timestamp_format"] == "rfc3339_utc"
|
|
232
|
+
assert m["started_at"].endswith("+00:00")
|
|
233
|
+
assert m["ended_at"].endswith("+00:00")
|
|
234
|
+
|
|
180
235
|
|
|
181
236
|
# ===========================================================================
|
|
182
237
|
# 3. LOGICAL CORRECTNESS
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{codegreen-0.4.7 → codegreen-0.4.8}/third_party/nvim-treesitter/tests/indent/c/aligned_indent.c
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{codegreen-0.4.7 → codegreen-0.4.8}/third_party/nvim-treesitter/tests/indent/c/compound_lit.c
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{codegreen-0.4.7 → codegreen-0.4.8}/third_party/nvim-treesitter/tests/indent/c/preproc_cond.c
RENAMED
|
File without changes
|
{codegreen-0.4.7 → codegreen-0.4.8}/third_party/nvim-treesitter/tests/indent/c/preproc_func.c
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{codegreen-0.4.7 → codegreen-0.4.8}/third_party/nvim-treesitter/tests/indent/c/unfinished_comment.c
RENAMED
|
File without changes
|
|
File without changes
|
{codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/crates/cli/src/templates/PARSER_NAME.h
RENAMED
|
File without changes
|
{codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/crates/cli/src/templates/py-binding.c
RENAMED
|
File without changes
|
{codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/crates/generate/src/templates/alloc.h
RENAMED
|
File without changes
|
{codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/crates/generate/src/templates/array.h
RENAMED
|
File without changes
|
|
File without changes
|
{codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/crates/tags/include/tree_sitter/tags.h
RENAMED
|
File without changes
|
|
File without changes
|
{codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter/lib/binding_web/lib/tree-sitter.c
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-c/bindings/c/tree_sitter/tree-sitter-c.h
RENAMED
|
File without changes
|
|
File without changes
|
{codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-c/bindings/swift/TreeSitterC/c.h
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-cpp/bindings/c/tree-sitter-cpp.h
RENAMED
|
File without changes
|
|
File without changes
|
{codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-cpp/bindings/swift/TreeSitterCPP/cpp.h
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-java/bindings/c/tree-sitter-java.h
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{codegreen-0.4.7 → codegreen-0.4.8}/third_party/tree-sitter-python/bindings/c/tree-sitter-python.h
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|