Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Release v0.16.0 #447

Merged
merged 59 commits into from
Apr 14, 2024
Merged

Release v0.16.0 #447

merged 59 commits into from
Apr 14, 2024

Conversation

martinhpedersen
Copy link
Member

(Work in progress)

Preliminary changelog:

  • Major overhaul of the template/forms engine (bug fixes and enhancements)
  • Add low-level support for packet node traversal (connection pre-hook)
  • Add support for administering Winlink password recovery email address
  • Always auto-convert images when using CLI composer (remove prompt)
  • Fix missing /tmp folder in Docker image
  • Fix error handling in interactive command 'freq'

Improved error handling, more efficient search and make sure we don't
escape the Forms root directory. Also adds debug logging and fixes some
reply templates we missed before.
Makes it possible to load templates outside the Standard Forms folder.
Mostly applicable for `composeform --template [path]`.
No need to traverse the whole file system when the exact location to the
.dat file is already known.
This was making the code more complex, as it made an unnecessary
fragmentation between the cli composer and the web gui. Many of the
fields exposed via the web api was in fact unused.
Fixes ignored MsgTo, MsgBcc and other common fields.
We have been auto-converting images for the web gui, while prompting the
user from the CLI composer. Given that the CLI prompt is causing issues
with the new "non-interactive" cli composer, I believe it's reasonable
to avoid this complexity by doing auto-convertion on the command line
aswell.

We could consider adding a config options to let the user control this
behavior in the future. But until then, let's keep it simple.

Resolves #431
Also make the search case-insentitive since caseness is not strictly
handled in HTML forms. Unsupported insertion tags are logged (debug).
For use when spawning a child process, i.e. the session prehook for
scripted packet node traversal.

Ref #114
Implemented by spawning a user-defined process communicating with the
remote station over stdio.

Issue #114
Probably not required anyway :)
This caused issues in various areas where Pat (and/or dependencies)
relied on os.TempDir() store temporary files. E.g. when running `pat
updateforms`.

We can't do this inside the build container, as there is no way of
specifying file permissions when doing COPY --from. The solution
(inspired by the distroless images) is to ADD a pre-prepared tarball
with the correct file permissions.

`mkdir -m 01777 tmp && tar --owner=root --group=root -cf tmp.tar tmp`
This was requested by the Winlink Development Team.

Resolves #442
Forms-enabled templates is not written with a CLI user in mind. By
echoing the template line before prompting for a <Var ...>, it will
hopefully be possible to understand the meaning of the variable (by
context).

Also apply a hack to refresh the regular expressions used by
varReplacer, to avoid prompting for the same variable multiple times.
<Day>, <UDay>, <GPSLatitude> and <GPSLongitude>
Also fixed issue of inconsistent output due to unstable ordering of form
variables.
This fixes an issue where, when searching for a html viewer, we ended up
using a non-existent HTML file.
Some templates references HTML Forms and reply templates located in
adjecent folders, without specifying a relative path. Examples of this
can be found in `MAPPING-GIS FORMS`.
By referencing the template instead of the "initial_uri" (Forms
composer), the backend is able to more precisely identify the correct
HTML file for any given template. It also makes handling of reply
templates much easier.

In addition to a less complex implementation, this simplifies the API as
we no longer need to supply the frontend with URIs for all HTML
variants. We also get increased performance because of the simplified
file search, and by not having to parse reply templates upfront.

This also opens up the possibility of serving a specialized HTML-based
composer for text-only templates in the future, without having to change
the existing frontend.
`./make,bash web` for 8fcca1c.
Winlink Express does include this, and neither should we.
I found this difference when comparing against Winlink Express's output
using the same Form template. Winlink Express trims trailing whitespace
before writing the form variables as XML.
Gofmt did not agree with my zero-padded numeric constants.
@martinhpedersen martinhpedersen added this to the v0.16.0 milestone Apr 13, 2024
@martinhpedersen martinhpedersen self-assigned this Apr 13, 2024
@martinhpedersen martinhpedersen marked this pull request as ready for review April 14, 2024 10:00
@martinhpedersen martinhpedersen merged commit 823b991 into master Apr 14, 2024
5 checks passed
@martinhpedersen martinhpedersen deleted the release/v0.16.0 branch April 14, 2024 10:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant