Telegram.Bot icon indicating copy to clipboard operation
Telegram.Bot copied to clipboard

my console application running in a long time , but i see this error : please help me

Open kiarashourang opened this issue 9 years ago • 1 comments

Unhandled Exception: System.Net.Http.HttpRequestException: Error while copying c ontent to a stream. ---> System.IO.IOException: Unable to read data from the tra nsport connection: The connection was closed. at System.Net.ConnectStream.InternalWrite(Boolean async, Byte[] buffer, Int32 offset, Int32 size, AsyncCallback callback, Object state) at System.Net.ConnectStream.BeginWrite(Byte[] buffer, Int32 offset, Int32 siz e, AsyncCallback callback, Object state) at System.Threading.Tasks.TaskFactory1.FromAsyncImpl[TArg1,TArg2,TArg3](Func 6 beginMethod, Func2 endFunction, Action1 endAction, TArg1 arg1, TArg2 arg2, TArg3 arg3, Object state, TaskCreationOptions creationOptions) at System.Net.Http.ByteArrayContent.SerializeToStreamAsync(Stream stream, Tra nsportContext context) at System.Net.Http.HttpContent.CopyToAsync(Stream stream, TransportContext co ntext) --- End of inner exception stack trace --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNot ification(Task task) at System.Runtime.CompilerServices.TaskAwaiter.ValidateEnd(Task task) at Telegram.Bot.TelegramBotClient.d__139`1.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNot ification(Task task) at Telegram.Bot.TelegramBotClient.d__68.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.AsyncMethodBuilderCore.<>c.b__ 6_1(Object state) at System.Threading.QueueUserWorkItemCallback.WaitCallback_Context(Object sta te) at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionCo ntext, ContextCallback callback, Object state, Boolean preserveSyncCtx) at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, C ontextCallback callback, Object state, Boolean preserveSyncCtx) at System.Threading.QueueUserWorkItemCallback.System.Threading.IThreadPoolWor kItem.ExecuteWorkItem() at System.Threading.ThreadPoolWorkQueue.Dispatch() at System.Threading._ThreadPoolWaitCallback.PerformWaitCallback()

kiarashourang avatar Dec 12 '16 06:12 kiarashourang

Hi, Please provide more information and your code.

matiuspico avatar Dec 15 '16 14:12 matiuspico