1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
|
%global _empty_manifest_terminate_build 0
Name: python-FRCUploader
Version: 3.6.2
Release: 1
Summary: A YouTube Uploader with FIRST Robotics Competition in mind
License: GNU Public License v3.0
URL: https://github.com/NikhilNarayana/FRC-YouTube-Uploader
Source0: https://mirrors.nju.edu.cn/pypi/web/packages/68/5f/7e658e9e7c3f7524f0d8bd31e255544b5553f0f9788446869f2117e36d19/FRCUploader-3.6.2.tar.gz
BuildArch: noarch
%description
**I'm no longer involved in FIRST so there will be no future feature updates. If anyone is interested in taking up this project feel free to do so. Otherwise I will review and merge PRs for cleaning up the codebase and adding features. Thank you to everyone in FIRST that has helped make this uploader as good as it is.**
# FRC-YouTube-Uploader
A YouTube Uploader for FRC Events
## Contributing
PRs are appreciated and will be reviewed quickly, the only code quality standard I have is to follow PEP8 standard except for the line length. If you have trouble understanding my code just ask me.
## Current Feature Set:
* Upload Videos (single or batch uploads possible)
* Queue and Dequeue Videos to Upload
* Add to a YouTube Playlist
* Include match results from TBA in description
* Add videos links to The Blue Alliance
* Mostly Automated Interface
* Saves and Loads form values
## How to Setup
1. Install [Python](https://www.python.org/downloads) for your OS with the PATH added and make sure there are no other versions of Python 3.
2. Install the program with `pip3 install -U FRCUploader`. If you want untested features you can download the repo and install with `pip3 install -U /path/to/repo`
3. Create a folder for storing your match videos.
4. Add the thumbnail to the match video folder as `thumbnail.png` (not required, but suggested).
5. Make your recording program follow this naming scheme: [MATCH TYPE] \(TIEBREAKER\) [MATCH NUM].[EXTENSION] ex. Qualification Match 1.mp4.
6. Start the program by running `frcuploader`.
7. Add in the necessary info in the Event Values and Match Values tabs
8. Hit submit every time a match finishes. No need to update any values unless you are entering eliminations or doing ceremonies.
9. Enjoy not having to deal with YouTube's front end 🎉.
### File Name Examples
File names are determined through substrings, you need the base of the match type and the match number at a minimum. Is this bad code design? Probably but it works and covers all known cases. Additionally all file names can be lowercase.
Bases:
Qualification -> qual
Quarter -> quarter + final
Semifinal -> semi + final
Final -> final
Tiebreaker -> tiebreak
QM15 = `Qualification Match 15.mp4` or `Qual 15.mp4`
SF2M3 = `Semifinal Tiebreaker 2.mp4` or `semi final tiebreak 2.mp4`
F1M3 = `Final 3.mp4` or `final tiebreaker.mp4` (The FMS shows Final 3, but I allow either tiebreaker or 3 for naming)
Opening Ceremonies = `Friday Opening Ceremonies.mp4` or `Day 1 Opening Ceremony.mp4`
Closing Ceremonies = `Awards Ceremony.mp4` or `Closing Ceremonies.mp4`
Alliance Selection = `Alliance Selection.mp4` or `alliance selection.mp4`
Highlight Reel = `Highlight Reel.mp4` or `Wrapup Video.mp4`
## UI Breakdown
### Event Values

##### Match File Location
Select the root directory for files by clicking open and then navigating to the directory you would like to pull match videos from.
##### Get Newest File
If your recording program doesn't support setting the file names with the necessary info each time you can use this simply get the newest file in the directory instead. This is great for programs like OBS, XSplit, and vMix.
##### Production Team/Facebook Name/Twitter Handle/Website Link
Constants that used to be in the script itself, you can now edit them as you see fit without going into the code.
##### Event Name
You can name this as you wish, but know that it goes at the start of the video's YouTube Title, if you don't like this I can make a toggle. Generally includes [YEAR] [NAME OF EVENT]
##### Event Code
Find this at TheBlueAlliance in the address bar of the event page. It generally follows [YEAR][EVENT_CODE] format such as 2018arc or 2016incmp.
##### Playlist ID
You can find the playlist ID on the playlist page's web address. Every playlist ID starts with PL making them easy to identify. A full link will be shortened after you submit it.
##### TBA Event ID/Secret
www.thebluealliance.com/request/apiwrite
Both of these must be obtained by requesting them from the link above for the keys to your event. If your event is not on TBA I suggest you just uncheck `Use TBA`.
##### Video Privacy Status
Select the privacy status you would like to upload with. If your channel allows monetization and you would like to monetize the videos, you should set the privacy status to `unlisted` and then update monetization later.
##### Video Description
The description used in the program is fairly lengthy, but adds a lot of info that can be nice to have. If you would like to change the description you can rearrange it as you see fit, but you must keep anything in curly braces to prevent the program from blowing up in your face when you hit submit.
Right clicking on the `Video Description` title text will bring up a reset button if necessary.
### Match Values

##### Match Code
This is hidden by default and can be accessed by toggling it in the menu bar.
This is an overriding function that will push any match you setup here to the correct TBA match and with the right info. This does not affect other parameters, you still need to set them up so it will find the correct match. For example, [2017 PCH Albany](https://www.thebluealliance.com/event/2017gaalb) had 5 replay matches in Semifinals 2 due to ties, the matches that counted were matches 4-6 on TBA, but the FMS kept the naming scheme from matches 1-3. To fix this you can input the match info like it was for `SF2M1` and name the file `Semifinal Match 2.mp4`, but then set match code to `SF2M4`. That would get the right scores and then update the right TBA match. This should almost never be used outside of cases like this.
##### Match Number
Fairly self-explanatory, just remember to reset the value when you go into each stage of eliminations. This value will increment each time you press "Submit".
##### Tiebreaker
Just adjusts the value of match number according to the tiebreaker scheme set down by FIRST. For example, Quarterfinals Tiebreaker 1 becomes Quarterfinal Match 9 internally because that is what TBA expects.
##### Tiebreaker
If you had a game get replayed, check this box and add `replay` to any part of the file name except the end.
##### Ceremonies
All the non-default options in this dropdown will tell the program to ignore various parameters like `Match Number`. Uploading Alliance Selection will then update all the necessary form fields for entering elimination matches.
For Opening Ceremonies you need to have `Day X` or put the current day of the week (eg. `Friday`) in the file name.
For Closing Ceremonies you need to just have `Closing` or `Award` in the file name.
For Alliance Selection you need to have `Alliance` and `Selection` in the file name.
For Highlight Reels you need to have `Highlight` or `Wrapup` in the file name
All terms are matched in a substring so `Award` will match with `Awards` and same for others.
##### Event Day
This is in conjunction with the above option. If you are not uploading live this is very important, you need to name the ceremony files with Day 1, 2, or 3 based on when they were in your event. Then select the same value in this dropdown and the program will find the correct one. Only Opening and Closing Ceremonies are affected, there is only one Alliance Selection so it don't change anything for that. If you are uploading live, I suggest you leave this at `Ignore` and just set the file name to include the current day name.
##### Last Match Number
If you want to batch upload a number of files you can do so with this. Every match between `Match Number` and this number, inclusive, will be uploaded and added to TBA. It will then replace this field with 0 and update Match Number to the last match uploaded + 1.
### Status Output

##### Output
This will display any information you need to know about an ongoing upload, the same info will be written to the command prompt as a backup and any errors will be written to a file in your root user directory. It is currently set to auto scroll to the bottom, but if you hit an infinite loop you can toggle the auto scrolling with the button.
##### Queue
The queue shows upcoming uploads with the top most item being the currently uploaded match.
Double clicking on a row in the Queue will remove it from the Queue. Be careful because you can't undo it unless you resubmit a new job.
#### Menu Bar
This is a bit different if you are on MacOS vs Windows. The menu bar is a part of the main window on Windows and it is a part of the native menu bar on MacOS.
##### Reset Form Values
Resets the form values to all the default values and resets the form value file.
##### Remove Youtube Credentials
Deletes the Youtube credentials and kills the program. Killing the program is intentional and necessary. You will be prompted for new credentials after you restart the program.
##### Show/Hide Match Code
Will toggle the match code's visiblity.
##### Toggle Uploads/Save Queue/Load Queue
These three options are meant to be used together to provide an easy way to upload matches after an event, especially if you choose to use `Get Newest File`. Before submitting any uploads, you should select `Toggle Uploads` and then just submit as necessary. You can choose to save the queue after every submission or save at the very end. When you decide to finally upload you can just open the program, select `Load Queue`, and wait for the uploads to finish. **Note** the filesystem and computer used to upload must be maintained for the uploads to work.
If you are still in need of assistance, feel free to contact me.
### Credits
* Google - Authentication and Video Uploading
* Phil Lopreiato - TBA Trusted API Integration
* Wes Jordan - Python TBA API Layer (https://github.com/Thing342/pyTBA) *no longer used*
* tbapy - New Python TBA API Layer
* Josh Klar - Bug Fixes during 2017 St. Joseph District
* Matthew Zacune - Testing and Feature Ideas
* The Internet - Bug Fixes
## Extra Scripts
All scripts are written in python 3 and can be called as arguments to the main script as listed below.
### updatePlaylistThumbnails.py (`frcuploader -t`)
This script will prompt for a playlist link and a file name for the thumbnail. It will then update every the thumbnails of every video in that playlist to the one you provide. This makes it simple to update older playlists with a new thumbnail so you can keep your look consistent.
### updateTBA.py (`frcuploader -u`)
Forcefully update thebluealliance.com with a match video. The prompts will ask you for the necessary links. If you want to post the event's opening ceremonies or other non-match videos please link to www.thebluealliance.com/event/[event_code]#media.
### playlistToTBA.py (`frcuploader -p`)
If for whatever reason you failed to post to TBA while using this uploader you can use this script afterwards to automatically link match videos to the event's page. Again the program will prompt you for links, once you do that it will take over and update TBA.
%package -n python3-FRCUploader
Summary: A YouTube Uploader with FIRST Robotics Competition in mind
Provides: python-FRCUploader
BuildRequires: python3-devel
BuildRequires: python3-setuptools
BuildRequires: python3-pip
%description -n python3-FRCUploader
**I'm no longer involved in FIRST so there will be no future feature updates. If anyone is interested in taking up this project feel free to do so. Otherwise I will review and merge PRs for cleaning up the codebase and adding features. Thank you to everyone in FIRST that has helped make this uploader as good as it is.**
# FRC-YouTube-Uploader
A YouTube Uploader for FRC Events
## Contributing
PRs are appreciated and will be reviewed quickly, the only code quality standard I have is to follow PEP8 standard except for the line length. If you have trouble understanding my code just ask me.
## Current Feature Set:
* Upload Videos (single or batch uploads possible)
* Queue and Dequeue Videos to Upload
* Add to a YouTube Playlist
* Include match results from TBA in description
* Add videos links to The Blue Alliance
* Mostly Automated Interface
* Saves and Loads form values
## How to Setup
1. Install [Python](https://www.python.org/downloads) for your OS with the PATH added and make sure there are no other versions of Python 3.
2. Install the program with `pip3 install -U FRCUploader`. If you want untested features you can download the repo and install with `pip3 install -U /path/to/repo`
3. Create a folder for storing your match videos.
4. Add the thumbnail to the match video folder as `thumbnail.png` (not required, but suggested).
5. Make your recording program follow this naming scheme: [MATCH TYPE] \(TIEBREAKER\) [MATCH NUM].[EXTENSION] ex. Qualification Match 1.mp4.
6. Start the program by running `frcuploader`.
7. Add in the necessary info in the Event Values and Match Values tabs
8. Hit submit every time a match finishes. No need to update any values unless you are entering eliminations or doing ceremonies.
9. Enjoy not having to deal with YouTube's front end 🎉.
### File Name Examples
File names are determined through substrings, you need the base of the match type and the match number at a minimum. Is this bad code design? Probably but it works and covers all known cases. Additionally all file names can be lowercase.
Bases:
Qualification -> qual
Quarter -> quarter + final
Semifinal -> semi + final
Final -> final
Tiebreaker -> tiebreak
QM15 = `Qualification Match 15.mp4` or `Qual 15.mp4`
SF2M3 = `Semifinal Tiebreaker 2.mp4` or `semi final tiebreak 2.mp4`
F1M3 = `Final 3.mp4` or `final tiebreaker.mp4` (The FMS shows Final 3, but I allow either tiebreaker or 3 for naming)
Opening Ceremonies = `Friday Opening Ceremonies.mp4` or `Day 1 Opening Ceremony.mp4`
Closing Ceremonies = `Awards Ceremony.mp4` or `Closing Ceremonies.mp4`
Alliance Selection = `Alliance Selection.mp4` or `alliance selection.mp4`
Highlight Reel = `Highlight Reel.mp4` or `Wrapup Video.mp4`
## UI Breakdown
### Event Values

##### Match File Location
Select the root directory for files by clicking open and then navigating to the directory you would like to pull match videos from.
##### Get Newest File
If your recording program doesn't support setting the file names with the necessary info each time you can use this simply get the newest file in the directory instead. This is great for programs like OBS, XSplit, and vMix.
##### Production Team/Facebook Name/Twitter Handle/Website Link
Constants that used to be in the script itself, you can now edit them as you see fit without going into the code.
##### Event Name
You can name this as you wish, but know that it goes at the start of the video's YouTube Title, if you don't like this I can make a toggle. Generally includes [YEAR] [NAME OF EVENT]
##### Event Code
Find this at TheBlueAlliance in the address bar of the event page. It generally follows [YEAR][EVENT_CODE] format such as 2018arc or 2016incmp.
##### Playlist ID
You can find the playlist ID on the playlist page's web address. Every playlist ID starts with PL making them easy to identify. A full link will be shortened after you submit it.
##### TBA Event ID/Secret
www.thebluealliance.com/request/apiwrite
Both of these must be obtained by requesting them from the link above for the keys to your event. If your event is not on TBA I suggest you just uncheck `Use TBA`.
##### Video Privacy Status
Select the privacy status you would like to upload with. If your channel allows monetization and you would like to monetize the videos, you should set the privacy status to `unlisted` and then update monetization later.
##### Video Description
The description used in the program is fairly lengthy, but adds a lot of info that can be nice to have. If you would like to change the description you can rearrange it as you see fit, but you must keep anything in curly braces to prevent the program from blowing up in your face when you hit submit.
Right clicking on the `Video Description` title text will bring up a reset button if necessary.
### Match Values

##### Match Code
This is hidden by default and can be accessed by toggling it in the menu bar.
This is an overriding function that will push any match you setup here to the correct TBA match and with the right info. This does not affect other parameters, you still need to set them up so it will find the correct match. For example, [2017 PCH Albany](https://www.thebluealliance.com/event/2017gaalb) had 5 replay matches in Semifinals 2 due to ties, the matches that counted were matches 4-6 on TBA, but the FMS kept the naming scheme from matches 1-3. To fix this you can input the match info like it was for `SF2M1` and name the file `Semifinal Match 2.mp4`, but then set match code to `SF2M4`. That would get the right scores and then update the right TBA match. This should almost never be used outside of cases like this.
##### Match Number
Fairly self-explanatory, just remember to reset the value when you go into each stage of eliminations. This value will increment each time you press "Submit".
##### Tiebreaker
Just adjusts the value of match number according to the tiebreaker scheme set down by FIRST. For example, Quarterfinals Tiebreaker 1 becomes Quarterfinal Match 9 internally because that is what TBA expects.
##### Tiebreaker
If you had a game get replayed, check this box and add `replay` to any part of the file name except the end.
##### Ceremonies
All the non-default options in this dropdown will tell the program to ignore various parameters like `Match Number`. Uploading Alliance Selection will then update all the necessary form fields for entering elimination matches.
For Opening Ceremonies you need to have `Day X` or put the current day of the week (eg. `Friday`) in the file name.
For Closing Ceremonies you need to just have `Closing` or `Award` in the file name.
For Alliance Selection you need to have `Alliance` and `Selection` in the file name.
For Highlight Reels you need to have `Highlight` or `Wrapup` in the file name
All terms are matched in a substring so `Award` will match with `Awards` and same for others.
##### Event Day
This is in conjunction with the above option. If you are not uploading live this is very important, you need to name the ceremony files with Day 1, 2, or 3 based on when they were in your event. Then select the same value in this dropdown and the program will find the correct one. Only Opening and Closing Ceremonies are affected, there is only one Alliance Selection so it don't change anything for that. If you are uploading live, I suggest you leave this at `Ignore` and just set the file name to include the current day name.
##### Last Match Number
If you want to batch upload a number of files you can do so with this. Every match between `Match Number` and this number, inclusive, will be uploaded and added to TBA. It will then replace this field with 0 and update Match Number to the last match uploaded + 1.
### Status Output

##### Output
This will display any information you need to know about an ongoing upload, the same info will be written to the command prompt as a backup and any errors will be written to a file in your root user directory. It is currently set to auto scroll to the bottom, but if you hit an infinite loop you can toggle the auto scrolling with the button.
##### Queue
The queue shows upcoming uploads with the top most item being the currently uploaded match.
Double clicking on a row in the Queue will remove it from the Queue. Be careful because you can't undo it unless you resubmit a new job.
#### Menu Bar
This is a bit different if you are on MacOS vs Windows. The menu bar is a part of the main window on Windows and it is a part of the native menu bar on MacOS.
##### Reset Form Values
Resets the form values to all the default values and resets the form value file.
##### Remove Youtube Credentials
Deletes the Youtube credentials and kills the program. Killing the program is intentional and necessary. You will be prompted for new credentials after you restart the program.
##### Show/Hide Match Code
Will toggle the match code's visiblity.
##### Toggle Uploads/Save Queue/Load Queue
These three options are meant to be used together to provide an easy way to upload matches after an event, especially if you choose to use `Get Newest File`. Before submitting any uploads, you should select `Toggle Uploads` and then just submit as necessary. You can choose to save the queue after every submission or save at the very end. When you decide to finally upload you can just open the program, select `Load Queue`, and wait for the uploads to finish. **Note** the filesystem and computer used to upload must be maintained for the uploads to work.
If you are still in need of assistance, feel free to contact me.
### Credits
* Google - Authentication and Video Uploading
* Phil Lopreiato - TBA Trusted API Integration
* Wes Jordan - Python TBA API Layer (https://github.com/Thing342/pyTBA) *no longer used*
* tbapy - New Python TBA API Layer
* Josh Klar - Bug Fixes during 2017 St. Joseph District
* Matthew Zacune - Testing and Feature Ideas
* The Internet - Bug Fixes
## Extra Scripts
All scripts are written in python 3 and can be called as arguments to the main script as listed below.
### updatePlaylistThumbnails.py (`frcuploader -t`)
This script will prompt for a playlist link and a file name for the thumbnail. It will then update every the thumbnails of every video in that playlist to the one you provide. This makes it simple to update older playlists with a new thumbnail so you can keep your look consistent.
### updateTBA.py (`frcuploader -u`)
Forcefully update thebluealliance.com with a match video. The prompts will ask you for the necessary links. If you want to post the event's opening ceremonies or other non-match videos please link to www.thebluealliance.com/event/[event_code]#media.
### playlistToTBA.py (`frcuploader -p`)
If for whatever reason you failed to post to TBA while using this uploader you can use this script afterwards to automatically link match videos to the event's page. Again the program will prompt you for links, once you do that it will take over and update TBA.
%package help
Summary: Development documents and examples for FRCUploader
Provides: python3-FRCUploader-doc
%description help
**I'm no longer involved in FIRST so there will be no future feature updates. If anyone is interested in taking up this project feel free to do so. Otherwise I will review and merge PRs for cleaning up the codebase and adding features. Thank you to everyone in FIRST that has helped make this uploader as good as it is.**
# FRC-YouTube-Uploader
A YouTube Uploader for FRC Events
## Contributing
PRs are appreciated and will be reviewed quickly, the only code quality standard I have is to follow PEP8 standard except for the line length. If you have trouble understanding my code just ask me.
## Current Feature Set:
* Upload Videos (single or batch uploads possible)
* Queue and Dequeue Videos to Upload
* Add to a YouTube Playlist
* Include match results from TBA in description
* Add videos links to The Blue Alliance
* Mostly Automated Interface
* Saves and Loads form values
## How to Setup
1. Install [Python](https://www.python.org/downloads) for your OS with the PATH added and make sure there are no other versions of Python 3.
2. Install the program with `pip3 install -U FRCUploader`. If you want untested features you can download the repo and install with `pip3 install -U /path/to/repo`
3. Create a folder for storing your match videos.
4. Add the thumbnail to the match video folder as `thumbnail.png` (not required, but suggested).
5. Make your recording program follow this naming scheme: [MATCH TYPE] \(TIEBREAKER\) [MATCH NUM].[EXTENSION] ex. Qualification Match 1.mp4.
6. Start the program by running `frcuploader`.
7. Add in the necessary info in the Event Values and Match Values tabs
8. Hit submit every time a match finishes. No need to update any values unless you are entering eliminations or doing ceremonies.
9. Enjoy not having to deal with YouTube's front end 🎉.
### File Name Examples
File names are determined through substrings, you need the base of the match type and the match number at a minimum. Is this bad code design? Probably but it works and covers all known cases. Additionally all file names can be lowercase.
Bases:
Qualification -> qual
Quarter -> quarter + final
Semifinal -> semi + final
Final -> final
Tiebreaker -> tiebreak
QM15 = `Qualification Match 15.mp4` or `Qual 15.mp4`
SF2M3 = `Semifinal Tiebreaker 2.mp4` or `semi final tiebreak 2.mp4`
F1M3 = `Final 3.mp4` or `final tiebreaker.mp4` (The FMS shows Final 3, but I allow either tiebreaker or 3 for naming)
Opening Ceremonies = `Friday Opening Ceremonies.mp4` or `Day 1 Opening Ceremony.mp4`
Closing Ceremonies = `Awards Ceremony.mp4` or `Closing Ceremonies.mp4`
Alliance Selection = `Alliance Selection.mp4` or `alliance selection.mp4`
Highlight Reel = `Highlight Reel.mp4` or `Wrapup Video.mp4`
## UI Breakdown
### Event Values

##### Match File Location
Select the root directory for files by clicking open and then navigating to the directory you would like to pull match videos from.
##### Get Newest File
If your recording program doesn't support setting the file names with the necessary info each time you can use this simply get the newest file in the directory instead. This is great for programs like OBS, XSplit, and vMix.
##### Production Team/Facebook Name/Twitter Handle/Website Link
Constants that used to be in the script itself, you can now edit them as you see fit without going into the code.
##### Event Name
You can name this as you wish, but know that it goes at the start of the video's YouTube Title, if you don't like this I can make a toggle. Generally includes [YEAR] [NAME OF EVENT]
##### Event Code
Find this at TheBlueAlliance in the address bar of the event page. It generally follows [YEAR][EVENT_CODE] format such as 2018arc or 2016incmp.
##### Playlist ID
You can find the playlist ID on the playlist page's web address. Every playlist ID starts with PL making them easy to identify. A full link will be shortened after you submit it.
##### TBA Event ID/Secret
www.thebluealliance.com/request/apiwrite
Both of these must be obtained by requesting them from the link above for the keys to your event. If your event is not on TBA I suggest you just uncheck `Use TBA`.
##### Video Privacy Status
Select the privacy status you would like to upload with. If your channel allows monetization and you would like to monetize the videos, you should set the privacy status to `unlisted` and then update monetization later.
##### Video Description
The description used in the program is fairly lengthy, but adds a lot of info that can be nice to have. If you would like to change the description you can rearrange it as you see fit, but you must keep anything in curly braces to prevent the program from blowing up in your face when you hit submit.
Right clicking on the `Video Description` title text will bring up a reset button if necessary.
### Match Values

##### Match Code
This is hidden by default and can be accessed by toggling it in the menu bar.
This is an overriding function that will push any match you setup here to the correct TBA match and with the right info. This does not affect other parameters, you still need to set them up so it will find the correct match. For example, [2017 PCH Albany](https://www.thebluealliance.com/event/2017gaalb) had 5 replay matches in Semifinals 2 due to ties, the matches that counted were matches 4-6 on TBA, but the FMS kept the naming scheme from matches 1-3. To fix this you can input the match info like it was for `SF2M1` and name the file `Semifinal Match 2.mp4`, but then set match code to `SF2M4`. That would get the right scores and then update the right TBA match. This should almost never be used outside of cases like this.
##### Match Number
Fairly self-explanatory, just remember to reset the value when you go into each stage of eliminations. This value will increment each time you press "Submit".
##### Tiebreaker
Just adjusts the value of match number according to the tiebreaker scheme set down by FIRST. For example, Quarterfinals Tiebreaker 1 becomes Quarterfinal Match 9 internally because that is what TBA expects.
##### Tiebreaker
If you had a game get replayed, check this box and add `replay` to any part of the file name except the end.
##### Ceremonies
All the non-default options in this dropdown will tell the program to ignore various parameters like `Match Number`. Uploading Alliance Selection will then update all the necessary form fields for entering elimination matches.
For Opening Ceremonies you need to have `Day X` or put the current day of the week (eg. `Friday`) in the file name.
For Closing Ceremonies you need to just have `Closing` or `Award` in the file name.
For Alliance Selection you need to have `Alliance` and `Selection` in the file name.
For Highlight Reels you need to have `Highlight` or `Wrapup` in the file name
All terms are matched in a substring so `Award` will match with `Awards` and same for others.
##### Event Day
This is in conjunction with the above option. If you are not uploading live this is very important, you need to name the ceremony files with Day 1, 2, or 3 based on when they were in your event. Then select the same value in this dropdown and the program will find the correct one. Only Opening and Closing Ceremonies are affected, there is only one Alliance Selection so it don't change anything for that. If you are uploading live, I suggest you leave this at `Ignore` and just set the file name to include the current day name.
##### Last Match Number
If you want to batch upload a number of files you can do so with this. Every match between `Match Number` and this number, inclusive, will be uploaded and added to TBA. It will then replace this field with 0 and update Match Number to the last match uploaded + 1.
### Status Output

##### Output
This will display any information you need to know about an ongoing upload, the same info will be written to the command prompt as a backup and any errors will be written to a file in your root user directory. It is currently set to auto scroll to the bottom, but if you hit an infinite loop you can toggle the auto scrolling with the button.
##### Queue
The queue shows upcoming uploads with the top most item being the currently uploaded match.
Double clicking on a row in the Queue will remove it from the Queue. Be careful because you can't undo it unless you resubmit a new job.
#### Menu Bar
This is a bit different if you are on MacOS vs Windows. The menu bar is a part of the main window on Windows and it is a part of the native menu bar on MacOS.
##### Reset Form Values
Resets the form values to all the default values and resets the form value file.
##### Remove Youtube Credentials
Deletes the Youtube credentials and kills the program. Killing the program is intentional and necessary. You will be prompted for new credentials after you restart the program.
##### Show/Hide Match Code
Will toggle the match code's visiblity.
##### Toggle Uploads/Save Queue/Load Queue
These three options are meant to be used together to provide an easy way to upload matches after an event, especially if you choose to use `Get Newest File`. Before submitting any uploads, you should select `Toggle Uploads` and then just submit as necessary. You can choose to save the queue after every submission or save at the very end. When you decide to finally upload you can just open the program, select `Load Queue`, and wait for the uploads to finish. **Note** the filesystem and computer used to upload must be maintained for the uploads to work.
If you are still in need of assistance, feel free to contact me.
### Credits
* Google - Authentication and Video Uploading
* Phil Lopreiato - TBA Trusted API Integration
* Wes Jordan - Python TBA API Layer (https://github.com/Thing342/pyTBA) *no longer used*
* tbapy - New Python TBA API Layer
* Josh Klar - Bug Fixes during 2017 St. Joseph District
* Matthew Zacune - Testing and Feature Ideas
* The Internet - Bug Fixes
## Extra Scripts
All scripts are written in python 3 and can be called as arguments to the main script as listed below.
### updatePlaylistThumbnails.py (`frcuploader -t`)
This script will prompt for a playlist link and a file name for the thumbnail. It will then update every the thumbnails of every video in that playlist to the one you provide. This makes it simple to update older playlists with a new thumbnail so you can keep your look consistent.
### updateTBA.py (`frcuploader -u`)
Forcefully update thebluealliance.com with a match video. The prompts will ask you for the necessary links. If you want to post the event's opening ceremonies or other non-match videos please link to www.thebluealliance.com/event/[event_code]#media.
### playlistToTBA.py (`frcuploader -p`)
If for whatever reason you failed to post to TBA while using this uploader you can use this script afterwards to automatically link match videos to the event's page. Again the program will prompt you for links, once you do that it will take over and update TBA.
%prep
%autosetup -n FRCUploader-3.6.2
%build
%py3_build
%install
%py3_install
install -d -m755 %{buildroot}/%{_pkgdocdir}
if [ -d doc ]; then cp -arf doc %{buildroot}/%{_pkgdocdir}; fi
if [ -d docs ]; then cp -arf docs %{buildroot}/%{_pkgdocdir}; fi
if [ -d example ]; then cp -arf example %{buildroot}/%{_pkgdocdir}; fi
if [ -d examples ]; then cp -arf examples %{buildroot}/%{_pkgdocdir}; fi
pushd %{buildroot}
if [ -d usr/lib ]; then
find usr/lib -type f -printf "/%h/%f\n" >> filelist.lst
fi
if [ -d usr/lib64 ]; then
find usr/lib64 -type f -printf "/%h/%f\n" >> filelist.lst
fi
if [ -d usr/bin ]; then
find usr/bin -type f -printf "/%h/%f\n" >> filelist.lst
fi
if [ -d usr/sbin ]; then
find usr/sbin -type f -printf "/%h/%f\n" >> filelist.lst
fi
touch doclist.lst
if [ -d usr/share/man ]; then
find usr/share/man -type f -printf "/%h/%f.gz\n" >> doclist.lst
fi
popd
mv %{buildroot}/filelist.lst .
mv %{buildroot}/doclist.lst .
%files -n python3-FRCUploader -f filelist.lst
%dir %{python3_sitelib}/*
%files help -f doclist.lst
%{_docdir}/*
%changelog
* Tue May 30 2023 Python_Bot <Python_Bot@openeuler.org> - 3.6.2-1
- Package Spec generated
|