Error/Bug occurred when I was uploading "superfast.html" as task in missions

Application ID: 6F7DDA3F-9056-0864-FFF5-FFD541FF1100
Error UID: 6CC124F3-9341-AA3C-FF3A-787F16475800

Backendless encountered an error while handling the request. An internal trouble ticket with ID 6CC124F3-9341-AA3C-FF3A-787F16475800 has been created and we will be investigating the issue.
java.lang.IndexOutOfBoundsException: 0
java.lang.RuntimeException: java.lang.IndexOutOfBoundsException: 0
	at com.backendless.services.CheckDeveloperPermission.execute(CheckDeveloperPermission.java:38)
	at com.backendless.inject.interceptors.AbstractDeveloperOperationInterceptor.invoke(AbstractDeveloperOperationInterceptor.java:20)
	at router.Routes$$anonfun$routes$1.$anonfun$applyOrElse$791(Routes.scala:13573)
	at play.core.routing.HandlerInvokerFactory$$anon$8.resultCall(HandlerInvoker.scala:146)
	at play.core.routing.HandlerInvokerFactory$$anon$8.resultCall(HandlerInvoker.scala:145)
	at play.core.routing.HandlerInvokerFactory$JavaActionInvokerFactory$$anon$3$$anon$4$$anon$5.invocation(HandlerInvoker.scala:111)
	at play.core.j.JavaAction$$anon$1.call(JavaAction.scala:119)
	at play.http.DefaultActionCreator$1.call(DefaultActionCreator.java:33)
	at com.backendless.googleanalytic.ReportGoogleAnalyticsAction.call(ReportGoogleAnalyticsAction.java:43)
	at com.backendless.InitApiKeyForConsoleAction.call(InitApiKeyForConsoleAction.java:48)
	at com.backendless.SimultaneousApiCallLimitAction.call(SimultaneousApiCallLimitAction.java:26)
	at com.backendless.StaticHttpResponseHeadersAction.call(StaticHttpResponseHeadersAction.java:22)
	at com.backendless.StackOverflowHandlerAction.call(StackOverflowHandlerAction.java:21)
	at com.backendless.CloseEntityManagerAction.call(CloseEntityManagerAction.java:36)
	at com.backendless.CurrentRequestsNumberAction.call(CurrentRequestsNumberAction.java:31)
	at com.backendless.old.security.ConsoleOriginAction.call(ConsoleOriginAction.java:46)
	at com.backendless.management.developer.DeveloperApplicationAccessAction.call(DeveloperApplicationAccessAction.java:30)
	at com.backendless.old.security.ApplicationExistenceAndUseAction.call(ApplicationExistenceAndUseAction.java:39)
	at com.backendless.management.developer.AbstractAuthenticateDeveloperAction.call(AbstractAuthenticateDeveloperAction.java:50)
	at play.core.j.JavaAction.$anonfun$apply$8(JavaAction.scala:175)
	at scala.concurrent.Future$.$anonfun$apply$1(Future.scala:659)
	at scala.util.Success.$anonfun$map$1(Try.scala:255)
	at scala.util.Success.map(Try.scala:213)
	at scala.concurrent.Future.$anonfun$map$1(Future.scala:292)
	at scala.concurrent.impl.Promise.liftedTree1$1(Promise.scala:33)
	at scala.concurrent.impl.Promise.$anonfun$transform$1(Promise.scala:33)
	at scala.concurrent.impl.CallbackRunnable.run(Promise.scala:64)
	at play.core.j.HttpExecutionContext.$anonfun$execute$1(HttpExecutionContext.scala:63)
	at play.api.libs.streams.Execution$trampoline$.execute(Execution.scala:70)
	at play.core.j.HttpExecutionContext.execute(HttpExecutionContext.scala:58)
	at scala.concurrent.impl.CallbackRunnable.executeWithValue(Promise.scala:72)
	at scala.concurrent.impl.Promise$KeptPromise$Kept.onComplete(Promise.scala:372)
	at scala.concurrent.impl.Promise$KeptPromise$Kept.onComplete$(Promise.scala:371)
	at scala.concurrent.impl.Promise$KeptPromise$Successful.onComplete(Promise.scala:379)
	at scala.concurrent.impl.Promise.transform(Promise.scala:33)
	at scala.concurrent.impl.Promise.transform$(Promise.scala:31)
	at scala.concurrent.impl.Promise$KeptPromise$Successful.transform(Promise.scala:379)
	at scala.concurrent.Future.map(Future.scala:292)
	at scala.concurrent.Future.map$(Future.scala:292)
	at scala.concurrent.impl.Promise$KeptPromise$Successful.map(Promise.scala:379)
	at scala.concurrent.Future$.apply(Future.scala:659)
	at play.core.j.JavaAction.apply(JavaAction.scala:176)
	at play.api.mvc.Action.$anonfun$apply$4(Action.scala:82)
	at scala.concurrent.Future.$anonfun$flatMap$1(Future.scala:307)
	at scala.concurrent.impl.Promise.$anonfun$transformWith$1(Promise.scala:41)
	at scala.concurrent.impl.CallbackRunnable.run(Promise.scala:64)
	at akka.dispatch.BatchingExecutor$AbstractBatch.processBatch(BatchingExecutor.scala:55)
	at akka.dispatch.BatchingExecutor$BlockableBatch.$anonfun$run$1(BatchingExecutor.scala:92)
	at scala.runtime.java8.JFunction0$mcV$sp.apply(JFunction0$mcV$sp.java:23)
	at scala.concurrent.BlockContext$.withBlockContext(BlockContext.scala:85)
	at akka.dispatch.BatchingExecutor$BlockableBatch.run(BatchingExecutor.scala:92)
	at akka.dispatch.TaskInvocation.run(AbstractDispatcher.scala:47)
	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
	at java.base/java.lang.Thread.run(Thread.java:834)
Caused by: java.lang.IndexOutOfBoundsException: 0
	at scala.collection.immutable.Vector.checkRangeConvert(Vector.scala:127)
	at scala.collection.immutable.Vector.apply(Vector.scala:118)
	at scala.collection.convert.Wrappers$SeqWrapper.get(Wrappers.scala:67)
	at com.backendless.util.FileRequestHelper.getFileFromRequestBody(FileRequestHelper.java:55)
	at controllers.console.FileManagement.fileUpload(FileManagement.java:282)
	at com.backendless.inject.interceptors.AbstractDeveloperOperationInterceptor.lambda$invoke$0(AbstractDeveloperOperationInterceptor.java:23)
	at com.backendless.services.CheckDeveloperPermission.execute(CheckDeveloperPermission.java:27)
	... 54 more

Hello @Hassan_Serhan

Please tell me the name of the mission and task.

Mission: FILES MASTER
Task: Upload a file using API

What does your code look like?

superfast.html is an empty file.

What does your code look like?

I didn’t understand what do you mean by “my code”? Which one?

The task requires that you upload the file using API. When you use API, you write a program (which is code). I am asking you to show what your code looks like that uploads the file.

Aha, I was trying to upload it manually before I use the API then this happened.

Ok, that’s a separate issue then. I believe uploading empty files does not work. You can create empty files directly in console. For this task, the file should be uploaded using the API. See the instructions for that task for details.

1 Like

Okay thank you!!