We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I can't send media group.
Here is the code that gave me error:
` ...
$m = new SendMediaGroup(); $m->chat_id = $update->message->chat->id; foreach($cursor as $item){ $photo = new Photo(); $photo->media = "https://REALURL.EXT/medium/public{$item['_id']}"; $m->media[] = $photo; }
`
But if I try to send single photos, with
foreach($cursor as $item){ $m = new SendPhoto(); $m->chat_id = $update->message->chat->id; $m->photo = "https://REALURL.EXT/medium/public{$item['_id']}";
} ` it works perfectly.
I hope the info I gave is useful :-)
This is the error: [2018-01-04 22:00:50] MegaBotMain.ERROR: unreal4u\TelegramAPI\Exceptions\ClientException: Bad Request: media to send are not specified in /home/eliosh/PhpstormProjects/MegaBot/megabot/vendor/unreal4u/telegram-api/src/InternalFunctionality/TelegramResponse.php:50 Stack trace: #0 /home/eliosh/PhpstormProjects/MegaBot/megabot/vendor/unreal4u/telegram-api/src/InternalFunctionality/TelegramResponse.php(33): unreal4u\TelegramAPI\InternalFunctionality\TelegramResponse->fillRawData('{"ok":false,"er...') #1 /home/eliosh/PhpstormProjects/MegaBot/megabot/vendor/unreal4u/telegram-api/src/HttpClientRequestHandler.php(73): unreal4u\TelegramAPI\InternalFunctionality\TelegramResponse->__construct('{"ok":false,"er...', Array) #2 /home/eliosh/PhpstormProjects/MegaBot/megabot/vendor/evenement/evenement/src/Evenement/EventEmitterTrait.php(123): unreal4u\TelegramAPI\HttpClientRequestHandler->unreal4u\TelegramAPI\{closure}() #3 /home/eliosh/PhpstormProjects/MegaBot/megabot/vendor/react/http-client/src/Response.php(92): Evenement\EventEmitter->emit('end') #4 /home/eliosh/PhpstormProjects/MegaBot/megabot/vendor/evenement/evenement/src/Evenement/EventEmitterTrait.php(123): React\HttpClient\Response->handleEnd() #5 /home/eliosh/PhpstormProjects/MegaBot/megabot/vendor/react/stream/src/Util.php(71): Evenement\EventEmitter->emit('end', Array) #6 /home/eliosh/PhpstormProjects/MegaBot/megabot/vendor/evenement/evenement/src/Evenement/EventEmitterTrait.php(123): React\Stream\Util::React\Stream\{closure}() #7 /home/eliosh/PhpstormProjects/MegaBot/megabot/vendor/react/stream/src/DuplexResourceStream.php(196): Evenement\EventEmitter->emit('end') #8 [internal function]: React\Stream\DuplexResourceStream->handleData(Resource id #144, Object(React\EventLoop\StreamSelectLoop)) #9 /home/eliosh/PhpstormProjects/MegaBot/megabot/vendor/react/event-loop/src/StreamSelectLoop.php(236): call_user_func(Array, Resource id #144, Object(React\EventLoop\StreamSelectLoop)) #10 /home/eliosh/PhpstormProjects/MegaBot/megabot/vendor/react/event-loop/src/StreamSelectLoop.php(205): React\EventLoop\StreamSelectLoop->waitForStreamActivity(NULL) #11 /home/eliosh/PhpstormProjects/MegaBot/megabot/src/MegaMain.php(68): React\EventLoop\StreamSelectLoop->run() #12 /home/eliosh/PhpstormProjects/MegaBot/megabot/main.php(19): MegaBot7\MegaMain->process() #13 {main} [] []
[2018-01-04 22:00:50] MegaBotMain.ERROR: unreal4u\TelegramAPI\Exceptions\ClientException: Bad Request: media to send are not specified in /home/eliosh/PhpstormProjects/MegaBot/megabot/vendor/unreal4u/telegram-api/src/InternalFunctionality/TelegramResponse.php:50 Stack trace: #0 /home/eliosh/PhpstormProjects/MegaBot/megabot/vendor/unreal4u/telegram-api/src/InternalFunctionality/TelegramResponse.php(33): unreal4u\TelegramAPI\InternalFunctionality\TelegramResponse->fillRawData('{"ok":false,"er...') #1 /home/eliosh/PhpstormProjects/MegaBot/megabot/vendor/unreal4u/telegram-api/src/HttpClientRequestHandler.php(73): unreal4u\TelegramAPI\InternalFunctionality\TelegramResponse->__construct('{"ok":false,"er...', Array) #2 /home/eliosh/PhpstormProjects/MegaBot/megabot/vendor/evenement/evenement/src/Evenement/EventEmitterTrait.php(123): unreal4u\TelegramAPI\HttpClientRequestHandler->unreal4u\TelegramAPI\{closure}() #3 /home/eliosh/PhpstormProjects/MegaBot/megabot/vendor/react/http-client/src/Response.php(92): Evenement\EventEmitter->emit('end') #4 /home/eliosh/PhpstormProjects/MegaBot/megabot/vendor/evenement/evenement/src/Evenement/EventEmitterTrait.php(123): React\HttpClient\Response->handleEnd() #5 /home/eliosh/PhpstormProjects/MegaBot/megabot/vendor/react/stream/src/Util.php(71): Evenement\EventEmitter->emit('end', Array) #6 /home/eliosh/PhpstormProjects/MegaBot/megabot/vendor/evenement/evenement/src/Evenement/EventEmitterTrait.php(123): React\Stream\Util::React\Stream\{closure}() #7 /home/eliosh/PhpstormProjects/MegaBot/megabot/vendor/react/stream/src/DuplexResourceStream.php(196): Evenement\EventEmitter->emit('end') #8 [internal function]: React\Stream\DuplexResourceStream->handleData(Resource id #144, Object(React\EventLoop\StreamSelectLoop)) #9 /home/eliosh/PhpstormProjects/MegaBot/megabot/vendor/react/event-loop/src/StreamSelectLoop.php(236): call_user_func(Array, Resource id #144, Object(React\EventLoop\StreamSelectLoop)) #10 /home/eliosh/PhpstormProjects/MegaBot/megabot/vendor/react/event-loop/src/StreamSelectLoop.php(205): React\EventLoop\StreamSelectLoop->waitForStreamActivity(NULL) #11 /home/eliosh/PhpstormProjects/MegaBot/megabot/src/MegaMain.php(68): React\EventLoop\StreamSelectLoop->run() #12 /home/eliosh/PhpstormProjects/MegaBot/megabot/main.php(19): MegaBot7\MegaMain->process() #13 {main} [] []
The text was updated successfully, but these errors were encountered:
The stack trace will be certainly a lot of help!
Will look into this as soon as I have some time (maybe tonight or tomorrow)
Thanks for reporting this!
Sorry, something went wrong.
Thanks to you for your great work!
Hi!
v2.9.4 and v3.3.4 implement the fix for this bug, thank you for reporting it!
unreal4u
No branches or pull requests
I can't send media group.
Here is the code that gave me error:
` ...
`
But if I try to send single photos, with
` ...
}
`
it works perfectly.
I hope the info I gave is useful :-)
This is the error:
[2018-01-04 22:00:50] MegaBotMain.ERROR: unreal4u\TelegramAPI\Exceptions\ClientException: Bad Request: media to send are not specified in /home/eliosh/PhpstormProjects/MegaBot/megabot/vendor/unreal4u/telegram-api/src/InternalFunctionality/TelegramResponse.php:50 Stack trace: #0 /home/eliosh/PhpstormProjects/MegaBot/megabot/vendor/unreal4u/telegram-api/src/InternalFunctionality/TelegramResponse.php(33): unreal4u\TelegramAPI\InternalFunctionality\TelegramResponse->fillRawData('{"ok":false,"er...') #1 /home/eliosh/PhpstormProjects/MegaBot/megabot/vendor/unreal4u/telegram-api/src/HttpClientRequestHandler.php(73): unreal4u\TelegramAPI\InternalFunctionality\TelegramResponse->__construct('{"ok":false,"er...', Array) #2 /home/eliosh/PhpstormProjects/MegaBot/megabot/vendor/evenement/evenement/src/Evenement/EventEmitterTrait.php(123): unreal4u\TelegramAPI\HttpClientRequestHandler->unreal4u\TelegramAPI\{closure}() #3 /home/eliosh/PhpstormProjects/MegaBot/megabot/vendor/react/http-client/src/Response.php(92): Evenement\EventEmitter->emit('end') #4 /home/eliosh/PhpstormProjects/MegaBot/megabot/vendor/evenement/evenement/src/Evenement/EventEmitterTrait.php(123): React\HttpClient\Response->handleEnd() #5 /home/eliosh/PhpstormProjects/MegaBot/megabot/vendor/react/stream/src/Util.php(71): Evenement\EventEmitter->emit('end', Array) #6 /home/eliosh/PhpstormProjects/MegaBot/megabot/vendor/evenement/evenement/src/Evenement/EventEmitterTrait.php(123): React\Stream\Util::React\Stream\{closure}() #7 /home/eliosh/PhpstormProjects/MegaBot/megabot/vendor/react/stream/src/DuplexResourceStream.php(196): Evenement\EventEmitter->emit('end') #8 [internal function]: React\Stream\DuplexResourceStream->handleData(Resource id #144, Object(React\EventLoop\StreamSelectLoop)) #9 /home/eliosh/PhpstormProjects/MegaBot/megabot/vendor/react/event-loop/src/StreamSelectLoop.php(236): call_user_func(Array, Resource id #144, Object(React\EventLoop\StreamSelectLoop)) #10 /home/eliosh/PhpstormProjects/MegaBot/megabot/vendor/react/event-loop/src/StreamSelectLoop.php(205): React\EventLoop\StreamSelectLoop->waitForStreamActivity(NULL) #11 /home/eliosh/PhpstormProjects/MegaBot/megabot/src/MegaMain.php(68): React\EventLoop\StreamSelectLoop->run() #12 /home/eliosh/PhpstormProjects/MegaBot/megabot/main.php(19): MegaBot7\MegaMain->process() #13 {main} [] []
The text was updated successfully, but these errors were encountered: