Jump to content

Compatibility Notice


Valik
 Share

Recommended Posts

The upcoming release of AutoIt (3.2.11.0) is going to have several compatibility issues with 3.2.10.0. The following is a list of current (known and intentional) compatibility changes. These items are not backwards compatible:

  • GUIConstants.au3 is identical to GUIConstantsEx.au3. This means that many scripts using advanced GUI functionality will need to use additional #include statements to include files containing constants that were previously and erroneously included.
  • GUIDefaultConstants.au3 no longer exists. You must now #include the corresponding constants file for the control type you need the default constant for.
  • StdoutRead(), StderrRead() and ConsoleRead() have undergone significant changes. They no longer block, they return immediately. The parameters have changed as well. It's no longer possible to read count parameters. The peek parameter has moved to the second parameter. The third parameter now specifies you want the data to be returned in binary format (default is text). The macro @extended now holds the number of bytes/characters read.
  • StdinWrite(), ConsoleWrite() and ConsoleWriteError() will now behave differently when given binary data. The binary data is written as-is instead of converting it to a string. Also, the return value from these functions is the number of bytes written instead of a generic value of 1.
  • The option RunErrorsFatal has been removed. Run, RunWait, ShellExecute and ShellExecuteWait now all set @error when they fail to run the application. AutoIt will no longer throw a fatal error when an application fails to run.
  • RunAsSet() has been removed. Use the new RunAs() and RunAsWait() functions instead. They have been enhanced with slightly better security (It is still not recommended to store important passwords in your scripts) and more functionality.
  • _ArrayCreate() documentation has been removed. The function is still present but may be removed at a later time. Scripts should be updated to use the array initialization syntax.
Some of these changes you can make now. For example, you can switch to using GUIConstantsEx.au3 to get prepared for when GUIConstants.au3 is changed. You can temporarily use Opt("RunErrorsFatal", 0) and modify your related process-creation statements to check @error to prepare for that becoming the new standard behavior (You will just have to remove the Opt() line later as opposed to doing all the work at once).

Also, when updating, be very careful, especially concerning StdoutRead(), StderrRead() and ConsoleRead(). The function's still take the same amount of arguments but those arguments do different things. For example, code that used to peek now reads binary data since the same combination of arguments that previously peeked now reads the stream in binary mode. Also, any code which relied on those functions blocking will now fail. The functions no longer block. If there is no data, they return an empty string. They must be called in a loop to drain all the data from the buffer. Alternatively, if you do not need the output in real-time, it's now safe to use ProcessWaitClose() and then read the data after the process has ended. This will no longer deadlock AutoIt in cases where there is a lot of data.

This list will be updated. There are other planned changes and they will be added to the list as they are completed. Please do not add things you want to see changed to this thread. Use the issue tracker for that. This is just a heads up so you guys can know going in what's not going to work like it used to and in some cases give you the opportunity to update your scripts in advance.

Edited by Valik
Link to comment
Share on other sites

  • 4 weeks later...

Guys, the StdXXX functions are DIFFERENT. Please re-read the documentation carefully. Treat it like learning new functions. I just received a question about the new versions which could have been answered by re-reading the documentation. Don't just assume that because the function has the same name and looks similar that it's the same function. Read the documentation closely, don't just skim over it.

Link to comment
Share on other sites

I searched but I couldn't find that _ArraySearch has also been changed: v3.2.10.0 --> v3.2.11.X

only this:

3.2.1.14 - Updated _ArraySearch() to Start/End/Case and Partial search.(gcriaco)

From:

#include <Array.au3>
_ArraySearch ( $avArray, $vWhat2Find,  $iStart = 0, $iEnd = 0, $iCaseSense = 0, $fPartialSearch = False )oÝ÷ Ù«­¢+Ø%¹±Õ±ÐíÉÉä¹ÔÌÐì)}ÉÉåMÉ ¡
½¹ÍР   åIÀÌØíÙÉÉä°ÀÌØíÙY±Õl°ÀÌØí¥MÑÉÐôÁl°ÀÌØí¥¹ôÁl°ÀÌØí¥
ÍôÁl°ÀÌØí¥AÉÑ¥°ôÁl°ÀÌØí¥½ÉÝÉôÅl°ÀÌØí¥MÕ%Ñ´ôÁuuuuut¤

@Mods: If this is crab then just delete it

Mega

Edited by Xenobiologist

Scripts & functions Organize Includes Let Scite organize the include files

Yahtzee The game "Yahtzee" (Kniffel, DiceLion)

LoginWrapper Secure scripts by adding a query (authentication)

_RunOnlyOnThis UDF Make sure that a script can only be executed on ... (Windows / HD / ...)

Internet-Café Server/Client Application Open CD, Start Browser, Lock remote client, etc.

MultipleFuncsWithOneHotkey Start different funcs by hitting one hotkey different times

Link to comment
Share on other sites

I searched but I couldn't find that _ArraySearch has also been changed: v3.2.10.0 --> v3.2.11.X

only this:

3.2.1.14 - Updated _ArraySearch() to Start/End/Case and Partial search.(gcriaco)

From:

#include <Array.au3>
_ArraySearch ( $avArray, $vWhat2Find,  $iStart = 0, $iEnd = 0, $iCaseSense = 0, $fPartialSearch = False )oÝ÷ Ù«­¢+Ø%¹±Õ±ÐíÉÉä¹ÔÌÐì)}ÉÉåMÉ ¡
½¹ÍР   åIÀÌØíÙÉÉä°ÀÌØíÙY±Õl°ÀÌØí¥MÑÉÐôÁl°ÀÌØí¥¹ôÁl°ÀÌØí¥
ÍôÁl°ÀÌØí¥AÉÑ¥°ôÁl°ÀÌØí¥½ÉÝÉôÅl°ÀÌØí¥MÕ%Ñ´ôÁuuuuut¤

@Mods: If this is crab then just delete it

Mega

3.2.11.0 (1/25/2008)

Changed: _Arrayxxxx functions/examples (-Ultima-)

It's in the UDF History

SciTE for AutoItDirections for Submitting Standard UDFs

 

Don't argue with an idiot; people watching may not be able to tell the difference.

 

Link to comment
Share on other sites

It's in the UDF History

Thanks, I didn't even recognized that. But what I really meant is, that I didn't find the info that the changes are not backwards compatible.

Scripts & functions Organize Includes Let Scite organize the include files

Yahtzee The game "Yahtzee" (Kniffel, DiceLion)

LoginWrapper Secure scripts by adding a query (authentication)

_RunOnlyOnThis UDF Make sure that a script can only be executed on ... (Windows / HD / ...)

Internet-Café Server/Client Application Open CD, Start Browser, Lock remote client, etc.

MultipleFuncsWithOneHotkey Start different funcs by hitting one hotkey different times

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...