Skip to content

4.0.0-beta.2

Pre-release
Pre-release

Choose a tag to compare

@ArthurkaX ArthurkaX released this 20 Oct 07:16
· 182 commits to main since this release

Fixes and additions since 4.0.0-beta.1, most of them found by running cts against a real project. Install or update with the same PowerShell line as before (L, the main branch). The full list is in CHANGELOG.md.

Upgrading: what changes

  • The built-in deny list no longer has delete_pou: deleting all of an object's files deletes it in the IDE unless the project denies that key, and a denied delete refuses the whole import, which the refusal says.
  • cts commit and the quick window's 5 Commit the disk and 6 Commit the disk, publish commit the folder as it is on disk, not the IDE; they warn when the IDE differs, and the message prompt counts the IDE edits 2 IDE -> Disk would carry first.

Sync

  • Folders of the POUs tab work like the folders below an application: export writes <Folder>/.cds-object.xml with its objects inside (before, they landed at the root of project-view/), and import creates objects and folders in them and moves objects between them. A new folder at the root of project-view/ goes to the POUs tab, and an object moves between the POUs and the Devices tab and to the root of project-view/ both ways. A folder renamed on disk or in the IDE keeps its GUID; cts sync removes a folder the IDE deleted with its files, and import --force brings a folder and its objects the IDE deleted back from disk. An IDE body added to an object whose .st had no // --- implementation --- line reaches the file.
  • An object goes into the folder of its parents' names even where CODESYS records other labels for them (a project a script made: a task configuration named TaskConfiguration, labelled Task Configuration, below Plc Logic, labelled PLC Logic), so its files no longer split into two folders that differ in case or spacing. cts compare names folders git tracks in two spellings that differ only in case, which Windows holds as one.
  • A view file changed on disk while cts import, cts export or cts sync runs (by an editor or another program; cts commands wait for each other) is not overwritten, and its sync base does not take that change: the answer names it (changed_meanwhile) and the next cts compare shows it. A new file whose object the IDE did not take (unapplied) stays out of the sync base, so the next sync carries it again instead of taking the IDE's side.
  • An object, text list or save the agent refuses during cts import or cts sync is named (unapplied, save_error) and the rest still lands and is answered; a call with no reply in time or over a broken connection ends the command, its outcome unknown, and the answer says the IDE may hold part of the changes: cts compare shows what still differs and running the command again carries the rest.
  • cts import and cts sync of several large screens read every one back; before, a screen past the agent's first reply was reported unapplied though it had landed.
  • cts compare names an ignored file the IDE holds otherwise than the disk, and cts import --include-ignored PATH carries one; its sync base then takes the file, so carrying it back later works the same way.
  • An XML object saved by one CODESYS version and exported by another (an SP16 Library Manager opened in SP22, which writes an unset field as <Null> where SP16 wrote an empty <Array> and adds empty fields) compares unchanged.
  • A folder on a mapped network drive, a subst drive or behind a link is the repository's root when git's own root is (git names it by its UNC path or target). cts set-sync-folder without a path offers the git repository a project lies in, where a folder beside the project inside that repository was always refused.

IDE, PLC and dialogs

  • Every call of a command names the project it began with, and the agent refuses it (project_changed, nothing done) once the IDE has another project open. With a copy of the project open in a second IDE, a command without --target names both project files and CTS_TARGET.
  • A question the IDE showed and closed again while a command ran is named under its line (dialog seen meanwhile, dialogs_seen in --json). cts project open names a dialog the load leaves on screen (Project Environment) with its answer line, cts agent list names the dialog an IDE is blocked by, and cts project open --launch refuses at once in session 0.
  • cts project close --save|--discard --quit closes the project and exits CODESYS; the refusal for unsaved changes names --save and --discard.
  • cts reset answers once the application has stopped, so a cts start right after it starts the application; a reset the deny list refuses points to the download it allows.
  • cts write confirms a number only when the read-back is the value written: a whole number exactly, a REAL as one float, any other number as one double.
  • cts connect and cts download say under their line that the IDE stays online. cts download and cts test say saved=by-ide when CODESYS saved the project on its own while they ran; in a repository with no commit yet, cts download says that, not each uncommitted file.
  • cts plc-log --tail 0 prints every entry. cts project device-types names --filter first when its list is long.

Tests and build

  • cts test --plc runs the tests on the device's PLC, and --repeat N runs them N times (a warm reset between runs when the deny list allows it) and names each failing test with its run. Each run waits for its own records, which reach the runtime's log a moment after TestResult.Done; a run whose TEST_START does not come did not run and fails.
  • cts build --all-objects marks the messages of objects no task calls not called by any task (not_called in --json); errors that name an unknown type or identifier come with the namespaces of the libraries the Library Manager references qualified-only.

Libraries and docs

  • New cts lib lists the library references, and cts lib set --qualified-only, lib add and lib remove change them on disk for cts import.
  • cts docs --show NAME prints one library symbol (Standard.TON, NBS.TCP_Client) without writing the bundle.