bitfab 0.42.0 → 0.43.1

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 69e485948bf6fd46a90f2a06dfb2bd620059eaffdd5cd82aed3d6d131da10798
4
- data.tar.gz: 8ed4ee8d1e27be2acf530f4a8b6c321d5bf66c05831bf159bd12ebe7061517ea
3
+ metadata.gz: d1073eb267b5c91b7a845d3abac599939b8838741bfa252b688f0dbe803276c5
4
+ data.tar.gz: 118f34e8a91a8a0cec3e4071098744fada2879b948577d8bebae275ed1771402
5
5
  SHA512:
6
- metadata.gz: e1e8e77298c773c996418690ac66013ecb91c1a38c85240ae418e31636bb3e1dbd751c8d5578a309c919ed6986d50b97a170257d26d6415ddba4a4db1c3bdd2c
7
- data.tar.gz: 3244754635e940000a0b47290c41434cd9a91a75ce9c299f4db8435642678a104c095267c5381d29d7abeb4fcfcc02fde68402e17d0ffa3383c99760201198b7
6
+ metadata.gz: 34f05d59438374486058802390023be43c61d0a103b30bec88ee431623dc8201253398d08e0a80600c6d0bf8d7f8861b6078748bfe1bdf8b5f4e0b92d2bb9960
7
+ data.tar.gz: 389a6a04ecbf88da123f48a806854f00e51b9f2cf8dc45ea25b698050f288829bfb81bf7e262e82fdaad80a0b0c2ac583f8c42e5d43e244d3259f544bd03e708
data/lib/bitfab/replay.rb CHANGED
@@ -369,6 +369,8 @@ module Bitfab
369
369
  # run's tokens (span-aggregated server-side), used below to fill each
370
370
  # item's :tokens.
371
371
  replay_tokens = complete_response&.dig("tokens") || {}
372
+ replay_outlines = complete_response&.dig("traceOutlines") || {}
373
+ original_outlines = complete_response&.dig("originalTraceOutlines") || {}
372
374
 
373
375
  # trace_id_map maps each item's client-side correlation id (:_sdk_trace_id,
374
376
  # which tagged that item's spans during the run) to the server's trace row
@@ -392,7 +394,11 @@ module Bitfab
392
394
  completed_count += 1
393
395
  missing << local_id if mapped.nil?
394
396
  end
395
- item[:tokens] = normalize_tokens(replay_tokens[mapped]) if mapped
397
+ if mapped
398
+ item[:tokens] = normalize_tokens(replay_tokens[mapped])
399
+ item[:trace_outline] = replay_outlines[mapped]
400
+ end
401
+ item[:original_trace_outline] = original_outlines[item[:original_trace_id]] if item[:original_trace_id]
396
402
  end
397
403
  # ALL completed items missing: systemic (the replayed method is not
398
404
  # traced, or uploads are wholesale broken). Raise; the run's traces
@@ -778,7 +784,9 @@ module Bitfab
778
784
  tokens: result[:tokens],
779
785
  model: result[:model],
780
786
  db_snapshot_ref: result[:db_snapshot_ref],
781
- db_branch_timings: result[:db_branch_timings]
787
+ db_branch_timings: result[:db_branch_timings],
788
+ trace_outline: result[:trace_outline],
789
+ original_trace_outline: result[:original_trace_outline]
782
790
  }
783
791
  })
784
792
  rescue => e
@@ -965,7 +973,9 @@ module Bitfab
965
973
  source_trace_id: original_trace_id,
966
974
  source_span_id: original_span_id,
967
975
  db_snapshot_ref:,
968
- db_branch_timings:
976
+ db_branch_timings:,
977
+ trace_outline: nil,
978
+ original_trace_outline: nil
969
979
  }
970
980
  ensure
971
981
  release_db_branch_lease(http_client, lease) if lease
@@ -1265,7 +1275,9 @@ module Bitfab
1265
1275
  source_trace_id: source_bitfab_trace_id,
1266
1276
  source_span_id: input_source_span_id,
1267
1277
  db_snapshot_ref:,
1268
- db_branch_timings:
1278
+ db_branch_timings:,
1279
+ trace_outline: nil,
1280
+ original_trace_outline: nil
1269
1281
  }
1270
1282
  end
1271
1283
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Bitfab
4
- VERSION = "0.42.0"
4
+ VERSION = "0.43.1"
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: bitfab
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.42.0
4
+ version: 0.43.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Harvest Team