Commit 218bed4
committed
Post-rebase fixes
line_profiler/_line_profiler.pyx
_SysMonitoringState.line_tracing_events, .line_tracing_event_set
New class attributes
_LineProfilerManager
_base_callback()
- Updated call signature
- Now using `._call_callback()` to handle stored callbacks
_call_callback()
New helper method for calling the stored callback which:
- Fetches changes to the `sys.monitoring` events and
callables to `self.mon_state`
- Restores the global event list and tool-id lock to ensure
continued profiling if necessary
tests/test_sys_trace.py
suspend_tracing
Updated implementation to also suspend `sys.monitoring`-based
line profiling
_test_helper_callback_preservation()
Updated to skip the legacy-tracing check when using
`sys.monitoring`-based line profiling
test_callback_wrapping()
Updated implementation to reflect non-interference with legacy
trace functions when using `sys.monitoring`-based line profiling
test_wrapping_thread_local_callbacks()
- Updated parametrization to reflect non-interference with
legacy trace functions when using `sys.monitoring`-based line
profiling
- Updated assertion to give more informative errors1 parent 77d82ae commit 218bed4
2 files changed
Lines changed: 91 additions & 45 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
314 | 314 | | |
315 | 315 | | |
316 | 316 | | |
| 317 | + | |
| 318 | + | |
| 319 | + | |
| 320 | + | |
| 321 | + | |
| 322 | + | |
| 323 | + | |
| 324 | + | |
| 325 | + | |
| 326 | + | |
| 327 | + | |
| 328 | + | |
317 | 329 | | |
318 | 330 | | |
319 | 331 | | |
| |||
342 | 354 | | |
343 | 355 | | |
344 | 356 | | |
345 | | - | |
346 | | - | |
347 | | - | |
348 | | - | |
349 | | - | |
| 357 | + | |
350 | 358 | | |
351 | 359 | | |
352 | 360 | | |
| |||
435 | 443 | | |
436 | 444 | | |
437 | 445 | | |
438 | | - | |
| 446 | + | |
439 | 447 | | |
440 | 448 | | |
441 | 449 | | |
| |||
467 | 475 | | |
468 | 476 | | |
469 | 477 | | |
470 | | - | |
471 | | - | |
472 | | - | |
473 | | - | |
| 478 | + | |
| 479 | + | |
474 | 480 | | |
475 | 481 | | |
476 | | - | |
| 482 | + | |
| 483 | + | |
477 | 484 | | |
478 | 485 | | |
479 | | - | |
480 | | - | |
| 486 | + | |
481 | 487 | | |
482 | 488 | | |
483 | 489 | | |
484 | 490 | | |
485 | 491 | | |
486 | | - | |
487 | | - | |
488 | | - | |
489 | | - | |
490 | | - | |
491 | | - | |
492 | | - | |
493 | | - | |
494 | | - | |
| 492 | + | |
| 493 | + | |
| 494 | + | |
| 495 | + | |
| 496 | + | |
| 497 | + | |
| 498 | + | |
| 499 | + | |
| 500 | + | |
| 501 | + | |
| 502 | + | |
495 | 503 | | |
496 | | - | |
497 | | - | |
498 | | - | |
| 504 | + | |
| 505 | + | |
| 506 | + | |
| 507 | + | |
| 508 | + | |
| 509 | + | |
| 510 | + | |
| 511 | + | |
| 512 | + | |
| 513 | + | |
| 514 | + | |
| 515 | + | |
| 516 | + | |
| 517 | + | |
| 518 | + | |
| 519 | + | |
499 | 520 | | |
500 | | - | |
| 521 | + | |
| 522 | + | |
| 523 | + | |
501 | 524 | | |
502 | 525 | | |
503 | 526 | | |
504 | | - | |
505 | | - | |
506 | | - | |
507 | | - | |
508 | | - | |
509 | | - | |
510 | | - | |
| 527 | + | |
| 528 | + | |
| 529 | + | |
| 530 | + | |
| 531 | + | |
| 532 | + | |
| 533 | + | |
| 534 | + | |
| 535 | + | |
| 536 | + | |
| 537 | + | |
| 538 | + | |
| 539 | + | |
| 540 | + | |
511 | 541 | | |
512 | 542 | | |
513 | 543 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
26 | 26 | | |
27 | 27 | | |
28 | 28 | | |
29 | | - | |
| 29 | + | |
30 | 30 | | |
31 | 31 | | |
32 | 32 | | |
33 | 33 | | |
34 | 34 | | |
35 | 35 | | |
36 | 36 | | |
| 37 | + | |
37 | 38 | | |
38 | 39 | | |
39 | 40 | | |
| |||
163 | 164 | | |
164 | 165 | | |
165 | 166 | | |
| 167 | + | |
166 | 168 | | |
167 | 169 | | |
168 | | - | |
169 | | - | |
| 170 | + | |
| 171 | + | |
| 172 | + | |
| 173 | + | |
| 174 | + | |
| 175 | + | |
| 176 | + | |
170 | 177 | | |
171 | 178 | | |
172 | | - | |
173 | | - | |
| 179 | + | |
| 180 | + | |
| 181 | + | |
| 182 | + | |
| 183 | + | |
| 184 | + | |
| 185 | + | |
174 | 186 | | |
175 | 187 | | |
176 | 188 | | |
| |||
270 | 282 | | |
271 | 283 | | |
272 | 284 | | |
273 | | - | |
274 | | - | |
| 285 | + | |
| 286 | + | |
| 287 | + | |
275 | 288 | | |
276 | 289 | | |
277 | 290 | | |
| |||
311 | 324 | | |
312 | 325 | | |
313 | 326 | | |
314 | | - | |
| 327 | + | |
315 | 328 | | |
316 | 329 | | |
317 | 330 | | |
| |||
558 | 571 | | |
559 | 572 | | |
560 | 573 | | |
561 | | - | |
562 | | - | |
563 | | - | |
| 574 | + | |
| 575 | + | |
| 576 | + | |
| 577 | + | |
| 578 | + | |
| 579 | + | |
564 | 580 | | |
565 | 581 | | |
566 | 582 | | |
| |||
621 | 637 | | |
622 | 638 | | |
623 | 639 | | |
624 | | - | |
| 640 | + | |
0 commit comments