I decided to try to create the Chromecast extension by myself, I have managed to solve the problem related to Classes and jar files, so I need to create the methods
One of the methods that the library includes is ChromeCasts.get(), this returns a List type, but I have to convert it to YailList, what would be the most correct way to do that?
error: incompatible types: List<ChromeCast> cannot be converted to YailList
[javac] return ChromeCasts.get();
[javac] ^
[javac] 1 error
You can return a straight List type from a method, you don’t need to return YailList. The runtime will coerce the List into a YailList. However, we generally don’t try to expose non-YAIL types in the blocks since one can’t do anything with them. Instead we provide methods to access information about the internal objects (cf. BluetoothClient). You may want to consider a similar pattern.
Ok, @Krishjha07 has helped me solve some problems, however it still returns an empty list
I found this Issue in the Repository of the used library, but I think it affects only computers, since I have seen other Android projects using this library
@Alexander Are you able to build a very basic app in Android Studio using the library? At least that would allow us to ensure that you have code that works, in which case it’s just a matter of figuring out how to integrate it into an extension.
Unfortunately, I can’t really speak to any stability issues in Kodular w.r.t. to the use of AsynchUtil there. In App Inventor, we use AsynchUtil in many different components in App Inventor, so if there were an actual problem with it I would expect that we’d be seeing a lot of reports (we had almost 650k users in the last 30 days). For example, it’s used as part of the WebRTC negotiation when you connect your companion to the browser.
According to an analysis with IntelliJ, AsynchUtil is used in the following components:
BluetoothServer
File
Map
FeatureCollection
MediaUtil; for loading images from the web and called from a plethora of components, including:
ButtonBase and its associated subclasses (Button and all Picker elements)
Hi @ewpatton
First of all thanks for sharing so much knowledge.
Honestly I haven’t used most of the AI2 components.
I mostly use AI2 for testing my extensions.So I am aware of those uses of AsychUtil.
But recently I have experienced a lot of issues by using AsynchUtill such as unexpected closing of application.
That’s is why I wrote above post on Kodular Community.
I also thought to report bug here but somehow I was able overcome the issues using AsyncTask so didn’t reported bug here.And I am feeling very sorry for that.
But I don’t know how it is working now
I experienced issues on both builders.First on Kodular because users reported bugs there then I tested on App Inventor and found that it is not working on both.
Sorry I use android 4.4 so either I have not so much options for debugging or I don't have proper knowledge about debugging.
Can I get logcat now?