Skip to content

TestGoCollectorAllowList tests fail in v1.13.0 with Go 1.19 #1135

@dswarbrick

Description

@dswarbrick

The following tests fail in v1.13.0 and main branch (as of writing).

=== RUN   TestGoCollectorAllowList
=== RUN   TestGoCollectorAllowList/Without_any_rules
=== RUN   TestGoCollectorAllowList/allow_all
    go_collector_latest_test.go:193: got [go_cgo_go_to_c_calls_calls_total go_gc_cycles_automatic_gc_cycles_total go_gc_cycles_forced_gc_cycles_total go_gc_cycles_total_gc_cycles_total go_gc_duration_seconds go_gc_heap_allocs_by_size_bytes go_gc_heap_allocs_bytes_total go_gc_heap_allocs_objects_total go_gc_heap_frees_by_size_bytes go_gc_heap_frees_bytes_total go_gc_heap_frees_objects_total go_gc_heap_goal_bytes go_gc_heap_objects_objects go_gc_heap_tiny_allocs_objects_total go_gc_limiter_last_enabled_gc_cycle go_gc_pauses_seconds go_gc_stack_starting_size_bytes go_goroutines go_info go_memory_classes_heap_free_bytes go_memory_classes_heap_objects_bytes go_memory_classes_heap_released_bytes go_memory_classes_heap_stacks_bytes go_memory_classes_heap_unused_bytes go_memory_classes_metadata_mcache_free_bytes go_memory_classes_metadata_mcache_inuse_bytes go_memory_classes_metadata_mspan_free_bytes go_memory_classes_metadata_mspan_inuse_bytes go_memory_classes_metadata_other_bytes go_memory_classes_os_stacks_bytes go_memory_classes_other_bytes go_memory_classes_profiling_buckets_bytes go_memory_classes_total_bytes go_memstats_last_gc_time_seconds go_sched_gomaxprocs_threads go_sched_goroutines_goroutines go_sched_latencies_seconds go_threads],
                                    want [go_gc_cycles_automatic_gc_cycles_total go_gc_cycles_forced_gc_cycles_total go_gc_cycles_total_gc_cycles_total go_gc_duration_seconds go_gc_heap_allocs_by_size_bytes go_gc_heap_allocs_bytes_total go_gc_heap_allocs_objects_total go_gc_heap_frees_by_size_bytes go_gc_heap_frees_bytes_total go_gc_heap_frees_objects_total go_gc_heap_goal_bytes go_gc_heap_objects_objects go_gc_heap_tiny_allocs_objects_total go_gc_pauses_seconds go_goroutines go_info go_memory_classes_heap_free_bytes go_memory_classes_heap_objects_bytes go_memory_classes_heap_released_bytes go_memory_classes_heap_stacks_bytes go_memory_classes_heap_unused_bytes go_memory_classes_metadata_mcache_free_bytes go_memory_classes_metadata_mcache_inuse_bytes go_memory_classes_metadata_mspan_free_bytes go_memory_classes_metadata_mspan_inuse_bytes go_memory_classes_metadata_other_bytes go_memory_classes_os_stacks_bytes go_memory_classes_other_bytes go_memory_classes_profiling_buckets_bytes go_memory_classes_total_bytes go_memstats_last_gc_time_seconds go_sched_goroutines_goroutines go_sched_latencies_seconds go_threads]
=== RUN   TestGoCollectorAllowList/allow_GC
    go_collector_latest_test.go:193: got [go_gc_cycles_automatic_gc_cycles_total go_gc_cycles_forced_gc_cycles_total go_gc_cycles_total_gc_cycles_total go_gc_duration_seconds go_gc_heap_allocs_by_size_bytes go_gc_heap_allocs_bytes_total go_gc_heap_allocs_objects_total go_gc_heap_frees_by_size_bytes go_gc_heap_frees_bytes_total go_gc_heap_frees_objects_total go_gc_heap_goal_bytes go_gc_heap_objects_objects go_gc_heap_tiny_allocs_objects_total go_gc_limiter_last_enabled_gc_cycle go_gc_pauses_seconds go_gc_stack_starting_size_bytes go_goroutines go_info go_memstats_last_gc_time_seconds go_threads],
                                    want [go_gc_cycles_automatic_gc_cycles_total go_gc_cycles_forced_gc_cycles_total go_gc_cycles_total_gc_cycles_total go_gc_duration_seconds go_gc_heap_allocs_by_size_bytes go_gc_heap_allocs_bytes_total go_gc_heap_allocs_objects_total go_gc_heap_frees_by_size_bytes go_gc_heap_frees_bytes_total go_gc_heap_frees_objects_total go_gc_heap_goal_bytes go_gc_heap_objects_objects go_gc_heap_tiny_allocs_objects_total go_gc_pauses_seconds go_goroutines go_info go_memstats_last_gc_time_seconds go_threads]
=== RUN   TestGoCollectorAllowList/allow_Memory
=== RUN   TestGoCollectorAllowList/allow_Scheduler
    go_collector_latest_test.go:193: got [go_gc_duration_seconds go_goroutines go_info go_memstats_last_gc_time_seconds go_sched_gomaxprocs_threads go_sched_goroutines_goroutines go_sched_latencies_seconds go_threads],
                                    want [go_gc_duration_seconds go_goroutines go_info go_memstats_last_gc_time_seconds go_sched_goroutines_goroutines go_sched_latencies_seconds go_threads]
--- FAIL: TestGoCollectorAllowList (0.00s)
    --- PASS: TestGoCollectorAllowList/Without_any_rules (0.00s)
    --- FAIL: TestGoCollectorAllowList/allow_all (0.00s)
    --- FAIL: TestGoCollectorAllowList/allow_GC (0.00s)
    --- PASS: TestGoCollectorAllowList/allow_Memory (0.00s)
    --- FAIL: TestGoCollectorAllowList/allow_Scheduler (0.00s)

Tested with Go 1.19.1 on linux/amd64, running kernel 5.19.

I'm not sure how this got past Circle CI, assuming that it runs tests. The release notes state "we also test client_golang against the new 1.19 version", but this doesn't appear to be true:

workflows:
  version: 2
  client_golang:
    jobs:
      # Refer to README.md for the currently supported versions.
      - test:
          name: go-1-17
          go_version: "1.17"
          run_lint: true
      - test:
          name: go-1-18
          go_version: "1.18"
          run_lint: true
          # Style and unused/missing packages are only checked against
          # the latest supported Go version.
          run_style_and_unused: true

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions