Problem/Motivation
When creating a new video programatically and not providing an ingestion profile, PHP throws the following notice and the upload fails:
Undefined index: in docroot/modules/contrib/brightcove/src/Services/Ingestion.php on line 263
Workaround: always provide an ingestion profile.
Steps to reproduce
$video = BrightcoveVideo::create();
$video->setApiClient($client);
$video->setName($video_name);
$video->setDescription($video_description);
$video->setLongDescription($video_description);
$video->setVideoUrl($url);
// do NOT call $video->setProfile(...);
$video->save(TRUE);
Proposed resolution
Provide a default ingestion profile. This would also solve https://www.drupal.org/project/brightcove/issues/3270084
Remaining tasks
User interface changes
API changes
Data model changes
Comments
Comment #2
yce commentedHi,
You can always get the default profile from the Brightcove API if you need it.
If you think it would benefit the module feel free to create a patch for it.
Comment #3
chandreshgiri gauswami commentedI really want to work on this issue but I don't have Brightcove api credentials. I tried creating test account but that account is limited and not providing api feature. Can someone please let me know how to get test api credentials so I can start work on it.
Thank you
Comment #4
yce commentedI'm going to close this ticket in favour of https://www.drupal.org/project/brightcove/issues/3270084