Other B4J v10.0 is available for download!

Erel

B4X founder
Staff member
Licensed User
Longtime User
I'm happy to release a new version of B4J.
This update includes a new IDE feature - code snippets. It will take some time for this feature to become effective. I do believe that in the near future we will find it to be a very useful feature.

B4J_czkcESZ48U.gif


  • Code snippets: https://www.b4x.com/android/forum/threads/b4x-code-snippets.152450/
  • For Each iterator works with Java HashMap and other non-standard maps.
  • Image.WriteToStream disposes resources properly.
  • IDE shortcut to go to a layout file: 'ide://goto?Layout=MainPage
  • New #ModuleVisibility attribute. Value can be Public - default visibility, or B4XLib. B4XLib means that the module methods and fields will not be visible once the module is packed as a b4xlib. Note that it is an IDE feature and is ignored by the compiler (might be changed in the future).
  • B4XView.Alpha / SetAlphaAnimated property and method.
  • B4XLibs modules and files can be overridden. This is done by adding the module or file to the project. The compiler now accepts it and gives higher precedence to the project files.
  • Debugger improvements including performance improvements and bug fixes.
  • Ctrl + Alt + W closes the current code window.
  • OBFUSCATED automatic conditional symbol - note that it is set at compilation time, never during editing.
  • Internal libraries updated since last version released: B4XFormatter v1.04, BCTextEngine v1.95, Xml2Map v1.01, SimpleMediaManager v1.14, jOkHttpUtils2 v3.03, B4XPages v1.12, DesignerUtils v1.04
  • Bug fixes and other minor improvements.
Download link: https://www.b4x.com/b4j.html
 

m4.s

Member
Licensed User
Longtime User
Hello @Erel ,

I've been waiting to see if others in the forum would report this new and strange B4J v10.0 problem, but no one has yet - which may mean it's something specific to my PC...if nobody else can reproduce,

When any backslash character (\) is present in code files opened in the IDE editor pane, and also if/when manually typed into the IDE editor pane via keyboard entry, the special ASCII character shown below is displayed:

1698377339560.png


However, no compiler errors occur as a result. Plus when the same code files are opened outside the [B4J] IDE, say using Windows Notepad, the backslash characters display (and can be typed/entered) properly.

Note: I am using Windows 11, set with USA - English language.
 
Upvote 0

aeric

Expert
Licensed User
Longtime User
Hello @Erel ,

I've been waiting to see if others in the forum would report this new and strange B4J v10.0 problem, but no one has yet - which may mean it's something specific to my PC...if nobody else can reproduce,

When any backslash character (\) is present in code files opened in the IDE editor pane, and also if/when manually typed into the IDE editor pane via keyboard entry, the special ASCII character shown below is displayed:

View attachment 147272

However, no compiler errors occur as a result. Plus when the same code files are opened outside the [B4J] IDE, say using Windows Notepad, the backslash characters display (and can be typed/entered) properly.

Note: I am using Windows 11, set with USA - English language.
You should create a post in Bugs? section. I am using Windows 11 Pro. I don't have this issue.

Check Time & Language > Language & region. Make sure you have "English (United States)". If yes, click the 3 dots on the right to go to Language options. At the bottom, make sure under Keyboards, it is showing US QWERTY.
 
Upvote 0

Erel

B4X founder
Staff member
Licensed User
Longtime User
I've decompiled the jServer.jar that is included in v10.0 and the modification is there:

B4X:
 public void onWebSocketError(final Throwable cause) {
            super.onWebSocketError(cause);
            if (cause instanceof SocketTimeoutException || cause instanceof EOFException || cause instanceof ClosedChannelException) {
                System.err.println("onWebSocketError: " + cause.getMessage());
            }
            else {
                cause.printStackTrace();
            }
        }
 
Upvote 0

alwaysbusy

Expert
Licensed User
Longtime User
@Erel Thanks for letting me know, I would've been surprised if it was otherwise. ;) It is going to be a long weekend trying to figure out what else is causing my logs to blow up with similar stack dumps then. I'm suspecting some client's browser is in a loop trying to reconnect the websocket (I can see it in the apache logs), but as it is a long weekend here in Belgium around november 11th, that person is probably enjoying it and left his browser open in this error state at work. This night, we even restarted the physical server, but it didn't help. Stubborn browser it seems. I'll figure it out somehow.

Overnight, I found indeed this piece of code in the class WebSocket in jServer is causing the stack trace in the log, now it is a matter of finding out why...
B4X:
public void Flush() throws IOException {
        if (shouldFlushOutput) {
            session.getRemote().flush();  // <-------------
            shouldFlushOutput = false;
        }
}
 
Upvote 0
Top