Commit 72e7787
committed
feat: Add backup codec support to publish_track API
Add support for backup_codec_policy and backup_codec parameters in the
LocalParticipant.publish_track() method, bringing Python SDK feature
parity with the JavaScript SDK.
Changes:
- Import and export BackupCodecPolicy enum from livekit.protocol.models
- Extend publish_track() with backup_codec_policy parameter
- Extend publish_track() with backup_codec parameter
- Add graceful fallback if FFI protocol fields not available
The implementation is backward compatible and includes error handling
for cases where the underlying FFI protocol may not yet support these
fields.
Resolves: Support for codec fallback behavior during track publishing1 parent 4ce788b commit 72e7787
2 files changed
+39
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
38 | 38 | | |
39 | 39 | | |
40 | 40 | | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
41 | 48 | | |
42 | 49 | | |
43 | 50 | | |
| |||
118 | 125 | | |
119 | 126 | | |
120 | 127 | | |
| 128 | + | |
121 | 129 | | |
122 | 130 | | |
123 | 131 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
665 | 665 | | |
666 | 666 | | |
667 | 667 | | |
668 | | - | |
| 668 | + | |
| 669 | + | |
| 670 | + | |
| 671 | + | |
| 672 | + | |
| 673 | + | |
669 | 674 | | |
670 | 675 | | |
671 | 676 | | |
672 | 677 | | |
673 | 678 | | |
674 | 679 | | |
675 | 680 | | |
| 681 | + | |
| 682 | + | |
| 683 | + | |
676 | 684 | | |
677 | 685 | | |
678 | 686 | | |
| |||
685 | 693 | | |
686 | 694 | | |
687 | 695 | | |
| 696 | + | |
| 697 | + | |
| 698 | + | |
| 699 | + | |
| 700 | + | |
| 701 | + | |
| 702 | + | |
| 703 | + | |
| 704 | + | |
| 705 | + | |
| 706 | + | |
| 707 | + | |
| 708 | + | |
| 709 | + | |
| 710 | + | |
| 711 | + | |
| 712 | + | |
| 713 | + | |
| 714 | + | |
| 715 | + | |
| 716 | + | |
| 717 | + | |
688 | 718 | | |
689 | 719 | | |
690 | 720 | | |
| |||
0 commit comments