100 Commits
Author SHA1 Message Date
Brad ArantandClaude Sonnet 5 867ace3cb3 Give jetc a dedicated, fully inert <comment> handler at compile time
<comment> had no special-case in jetc's compiler at all - it fell
through to parseFallback(), the generic unknown-tag path, which hunts
for a tag's own closing tag via scanBody()/skipQuotedValue(), the same
quote-aware, backslash-escape-interpreting scanning real Jet attribute
syntax needs. A comment containing an explanatory " sequence (a JSON
example in prose, say) or a literal <else>/<if>-looking word - both
already confirmed, separately, to corrupt jetc when they turn up
inside a JS // comment - hit the exact same corruption here too, just
triggered from inside a <comment> block instead.

Added skipCommentTag(), which only tracks same-tag-name nesting depth
via the existing case-insensitive matchTagOpen/matchTagClose and
otherwise ignores every character - no quote tracking, no other-tag
recognition, nothing a comment's own body could ever trip over. Wired
into parseNodes() alongside the other recognized top-level tags;
unlike those, it pushes no node at all; the comment contributes
nothing to the compiled output, matching the runtime interpreters own
__comment behavior but now safe at compile time too.

Verified directly: a scratch .jet with five <comment> blocks (plain,
a bare quote, a backslash-quote JSON example, literal <else>/<if>
text, and nested comments with their own quotes) all compiled clean
and left zero trace in the generated code, with the <if> immediately
following them compiling correctly too - confirming nothing after a
tricky comment gets corrupted either.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-10-10 16:49:53 +00:00
Brad ArantandClaude Sonnet 5 b8f7793773 Add global music player, invoicing/payment system, account subpages, mail account admin, and the qualityiron.vegas Jet 2.0 port
Jet interpreter (Tag.cpp, __call.cpp, __imap*.cpp/h, __smtpsend.cpp/h,
__imapemptyfolder.cpp/h - new): assorted parser/tag fixes found across
this work - a stray literal-tag-in-comment and backslash-quote parser
corruption class, a dangling-pointer fix, a __call.cpp fd leak, IMAP
folder-management tags, multi-account/per-host IMAP support, and a
smtpsend Message-ID fix.

barant.com site (jetc/barant-site/):
- A site-wide persistent music player (header band, playlist/queue,
  stereo FFT EQ, session-persisted state) fed by new library/
  ianslibrary/music song-list subpages.
- /account split into info/phones/invoices subpages; a full invoicing
  and Square payment system (create/edit/copy/pay/email invoice);
  admin invoice management and mail-account management subpages.
- /services split into overview/hosting/siptrunking/documents
  subpages, retiring the old standalone pages.
- SIPPHONE.tag: a Jet 2.0 WebRTC softphone tag.
- main.css/spa.js/email.js: the SPA loading indicator, the music
  player band styling, and assorted fixes accumulated alongside this
  work.

qualityiron-site/: the qualityiron.vegas job/contractor/customer/
document management app, ported from its original Jet 1.4 codebase to
Jet 2.0 as barant.coms APIServers second multi-tenant site.

wcwc/wcwc.jet: the WCWC site Jet source (wcwc.jtc build output not
included).

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-10-06 17:42:01 +00:00
Brad ArantandClaude Sonnet 5 905fbafa5a Fix <sql> silent-failure bug; split /vst into overview + subpage; misc site fixes
- __mysql.cpp: <sql> never checked mysql_real_query's own return code,
  so a genuine query failure was indistinguishable from "ran fine, zero
  rows" - <try>/<catch> around a failing <sql> never actually caught
  anything anywhere. Now throws on a real failure.
- spa.js: dynamically re-injected scripts now run in true sequential
  order (wait for each external script's load event before running the
  next), fixing checkout's Square card field never building on the
  first client-side navigation to /checkout (only after a refresh) -
  async=false alone only orders multiple external scripts relative to
  each other, it doesn't delay a plain inline sibling.
- /vst split into a real overview + /vst/modular1 subpage with a left
  menu, reusing opensource.page's existing subpage-tier pattern
  (opensource.menu/main.css's submenuitem-active highlighting, and
  several other subpage-tier retirements, were already finished earlier
  this session but never committed - included here too).

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-13 15:14:25 +00:00
Brad Arant 46ef67b735 Bump email.js cache-buster for pagination change 2026-09-07 04:20:53 +00:00
Brad Arant 41fbf0b7d9 Add pagination to the email list (was hardcoded to newest 50, no way to see older mail)
listMessages() only ever fetched everything then kept the newest
limit (default 50) messages, with no offset parameter and no way for
the client to know how many messages existed beyond what it was
shown - older mail was completely unreachable through the webmail UI.

__imap::listMessages() now takes an offset (counted back from the
newest message) and returns {"total":N,"messages":[...]} instead of
a bare array, so the client can page backward/forward and know when
it has reached either end. __imaplist tag and /email/list both pass
offset through; /email/search is unchanged (search results are not
paginated). email.js tracks currentOffset (reset alongside
currentFolder/currentUid at every existing reset site), and renders
Prev/Next controls next to the unread count showing the current
1-based range and total.
2026-09-07 04:20:42 +00:00
Brad Arant dcfe2a667c Restyle htmleditor.page to match site theme, remove email disconnect button
htmleditor.page previously used hardcoded blue/gray Windows-95-era
inline styles (#678, #abc, #808080, #def) totally disconnected from
the site current dark/gold Bond theme (main.css --bond-* variables) -
this is what showed up as "the old page with the blue stylesheet"
when opening a file to edit. Restyled the window chrome, toolbar,
title bar, and buttons to use the same custom properties/.button
class the rest of the site uses; left the #mainpage content-preview
canvas white since it renders the actual page being edited.

email.js: removed the Disconnect button/handler and its unused icon
from the email toolbar per request. Bumped its cache-buster in
admin-email.subpage.
2026-09-07 04:09:12 +00:00
Brad Arant c1491b044b Add IMAP webmail tag, admin/opensource subpage tiers, store/cart, htmleditor, uploads
New __imap*/__smtpsend/__eval Jet tags give templates real IMAP
(list/message/flag/delete/move/search/folders/accounts) and SMTP-send
capability, backing the new /email webmail client (email.jet/
email.menu, assets/images/email.js + newemail.js) and its
mainpagetemplate.jet-based page shell. Most of this tag family's
source was already being built into the live site (Tag.cpp already
registered __imap/__imaplist/__imapmessage/__imapflag/__imapdelete/
__eval) but had never actually been committed; this also registers
and commits the remaining five (__imapmove/__imapfolders/
__imapsearch/__smtpsend/__imapaccounts).

admin.page/admin.menu gain a real subpage tier (admin-email,
admin-newemail, admin-invoices, admin-products, admin-users) replacing
several previously top-level pages, mirrored by a similar
opensource.page subpage tier (opensource-overview/asm1802/barantmail/
jet/serverframework/synthmax) - old top-level pages retired via git
rename (asm1802.page, jet.page, serverframework.page,
admin_invoices.page); barantmail.page is dropped outright, folded into
opensource-barantmail.subpage.

New storefront (store.page, store-createstore.subpage,
barantstore.page) and cart flow (cart.jet, updatecartqty.proc,
removecartitem.proc, editproduct.page/selectproduct.proc/
update_product.proc for inventory maintenance against the barant
database).

New document upload/download manager (documents.jet, documents_api.jet,
documents_upload.proc, documents_delete.proc,
assets/images/documents.js + documents-page.js) with a persistent
floating panel, and a rich-text page editor (htmleditor.jet/.page,
createhtmleditor.proc, savehtmleditor.proc, assets/images/htmleditor.js
+ its icon/logo assets).

SESSIONCTL.tag: login now redirects back to the originally-requested
page instead of always landing on /account ($[start:0] vs $[start]
variable-name mismatch).

main.css/menu.bar/invoices.menu/jet_overview.section/login.menu:
styling and navigation updates for the above; new site assets (fonts,
images, audio) referenced by them.

jetc/build-assets.sh, list_jet_files.sh, lowercase_jet.py,
strip_fragments.py: small dev tooling used while building the above.
2026-09-06 04:14:00 +00:00
Brad Arant b0cadc3f08 Multi-day accumulated fixes: tag dispatch, session/pooling correctness, SPA rollout, jetc compiler
JetCore engine (Tag.cpp/.h, Global.cpp/.h, __*.cpp tag classes):
- Numerous __mysql.cpp connection-pooling correctness fixes (stale
  result sets, double-indirection sessionid bugs, field caching,
  pool keying) and a session-registration-before-connection-confirmed
  ordering fix (dangling pointer on a failed connect)
- Tag.cpp: large body of fixes to the tag-dispatch/container-scanning
  logic (bare-name fallback, database aliasing, single-quote handling,
  @-prefix session variable resolution, TAGDEF caching, nested split-tag
  scanning for if/while/until/ifrow so an inner one doesn't corrupt an
  outer one's own boundary scan) plus the process-first rendering
  order fix (a <process> now runs before <checksession>/page
  resolution, fixing a real "blank page after successful login" bug)
- Global.h/.cpp: added imapSessions (parallel to the existing __mysql*
  session map) for the new <imap> tag family
- __whiledir.cpp/__include.cpp: caching and directory-name-aliasing
  fixes
- __call.cpp/.h: fixed a dangling-pointer bug
- __write.cpp: fixed an O_WRONLY-only open that couldn't create a new
  file
- __ifrow.cpp/__sql.cpp: fixed the same sessionid double-indirection
  bug __mysql.cpp had (resolveKeyword's result was being used as a map
  key lookup instead of the resolved value itself)

jetc compiler (jetc/JetParser.cpp/.h, JetCodegen.cpp/.h, JetAST.h,
jetc.cpp, build-shared.sh, build-compiled.sh):
- Parser fixes: inline <include>, nested-quote handling, void-tag
  recognition
- Codegen fixes and expanded AST support
- build-shared.sh: atomic rename into place for a freshly-built .jtc
  (a live server dlopen()ing the same path mid-rebuild was corrupting
  its own already-mapped view of the old file) and a staleness check
  so a cached JetCore .o doesn't silently keep serving yesterday's
  fixes forever
- Added -lssl to both build scripts' link lines (needed once the new
  <imap> tag's client-side TLS code existed - previously nothing in
  this codebase used OpenSSL's SSL/TLS client API, only libcrypto)

Site content (jetc/barant-site/): SPA (fetch-and-swap navigation)
rollout across essentially every .page/.jet/.section/.tag/.proc/.method
file - dynamic-content fixes, fragment-mode stripping, native
$[@name] session variables replacing older mechanisms, and this
session's own checkout.page redesign, login start-param redirect fix,
and per-page side-menu (menu.bar/$[PAGE].menu) refresh support.
Completed the earlier main.css/control.css move from assets/ to
assets/images/ (git still showed the old paths as tracked-but-deleted
until now).

Deliberately left out of this commit: dozens of .pre-<description>-
<date> manual backup files (this session's and earlier ones' own
before/after snapshots, not meant for permanent history), compiled
.jtc build outputs, ad hoc test binaries and scripts under jetc/
(login_asan, wcwc_test, optest2_bin, etc.), and jetc/__pycache__/ -
none of these are meant to be tracked; a .gitignore covering them
would be worth adding separately.
2026-09-03 05:20:48 +00:00
Brad Arant 54b6e522f9 build-shared.sh: rebuild on stale objects, skip needless re-archiving, link atomically
Three correctness fixes to the --shared build path:

- Only skipped rebuilding a .pic.o when it existed at all, never checking
  whether the source .cpp was newer - confirmed live: Tag.pic.o (and 6
  other JetCore objects) sat uncompiled since 2026-08-25 while Tag.cpp
  itself picked up same-day fixes, so every .jtc silently ran yesterday's
  JetCore code.
- Only re-archive libCoreUtils_pic.a when a member object actually changed,
  instead of unconditionally on every build.
- Link to a temp file in the same directory, then rename() it into place,
  instead of linking directly onto the live .jtc path. A running APIServer
  may already have that exact path dlopen()ed (hot-reload watches this
  directory) - overwriting it in place corrupts the live mapping's code
  pages out from under the process, causing a dlclose() SIGSEGV the next
  time it reloads. rename() never touches the old inode, so anything with
  it still mapped keeps seeing the unmodified original.
2026-09-01 00:04:25 +00:00
Brad Arant d0f2551e89 Still working out cgi variable stuff. 2025-12-10 16:48:23 -08:00
Brad Arant e6ebb34366 Continued work on cgi interfaces. 2025-12-09 16:40:15 -08:00
Brad Arant 3bd9ea124f Continued work on cgi interfaces. 2025-12-09 12:29:39 -08:00
Brad Arant ac0865d2da CGI parsing work in progress. 2025-12-08 16:36:14 -08:00
Brad Arant 7e835e5073 Working on CGI session stuff. 2025-12-04 17:05:57 -08:00
Brad Arant 8b38617b00 Setup font capability on documentation. 2025-12-03 16:14:25 -08:00
Brad Arant 50a29a4238 Added stub for DATEDIFF function. 2025-12-03 14:55:26 -08:00
Brad Arant db59e9e87c fixed output of numeric output from expr(). 2025-12-02 15:56:31 -08:00
Brad Arant 3f14b28435 New test for expression priorities. 2025-11-25 13:58:23 -08:00
Brad Arant a91d78f524 Fixed * and / operators to prioritize over + and -. 2025-11-25 13:16:26 -08:00
Brad Arant 61216a2296 Some docuemtation updats. 2025-11-24 13:50:27 -08:00
Brad Arant 63916cc32a Added FLOOR and CEIL function in operand. 2025-11-24 13:19:31 -08:00
Brad Arant 5e0523619d Added new tests for MIN and MAX. 2025-11-24 12:19:25 -08:00
Brad Arant 3314a410e0 Added MIN and MAX functions for operand. 2025-11-24 12:15:56 -08:00
Brad Arant c21f27f14d add some items to gitignore for document workspace. 2025-11-24 09:45:45 -08:00
Brad Arant 4e47d6aaf7 add some items to gitignore for document workspace. 2025-11-24 09:42:15 -08:00
brad Arant 6e25db1e44 Doc updates. 2025-11-21 19:15:48 -08:00
brad Arant c4f0fab8c7 Added a bunch of functions. 2025-11-08 20:04:45 -08:00
brad Arant 96302e1d27 Added ability for call tag to use container as input stream. 2025-11-07 19:35:07 -08:00
brad Arant bdbae9e397 Added CGI stuff and unixtime function. 2025-11-07 10:22:40 -08:00
brad Arant 078a73664c Added CGI stuff and unixtime function. 2025-11-07 10:22:20 -08:00
brad Arant 280d4b8aa2 Clean up the transparent markers function. 2025-10-20 16:22:22 -07:00
brad Arant 7b6342b8d7 Fixed not a number issue with expression. 2025-10-20 10:56:30 -07:00
Brad Arant 94c8833f2a Merge branch 'master' of ssh://barant.com/git/JetCore 2025-05-22 09:26:03 -07:00
Brad Arant 0cb8a08a73 New sessionid object. 2025-05-22 09:25:55 -07:00
Brad Arant 2f30b3f8c4 Broke out session object. 2025-05-06 07:33:04 -07:00
brad Arant ddf0595fb1 Merge branch 'master' of ssh://barant.com/git/JetCore 2025-05-01 19:02:25 -07:00
brad Arant 0159050b7d changes 2025-05-01 19:02:17 -07:00
Brad Arant fd5069f69f Moving session id out of jet tag. 2025-05-01 15:01:16 -07:00
Brad Arant 24035c9d28 Update to documentation. 2025-04-30 16:25:39 -07:00
Brad Arant 078ba7f81c significant work on cookies and cgi formdata variables. 2025-03-18 16:46:39 -07:00
Brad Arant 050b5f2b87 more formdata work. 2025-03-17 16:46:50 -07:00
brad Arant d3cd5f3c9a More session work. 2025-03-17 07:44:36 -07:00
brad Arant 60affa288e Merge branch 'master' of ssh://barant.com/git/JetCore 2025-03-09 14:59:24 -07:00
brad Arant d74093b48a moe testing work. 2025-03-09 14:58:22 -07:00
Brad Arant f150389672 worked on cgi session stuff. 2025-03-06 14:54:54 -08:00
Brad Arant 167ee75658 add upper and lower to operand functions. 2025-02-13 10:27:44 -08:00
brad Arant 80d31540d9 Some cgi work. 2025-02-10 07:12:31 -08:00
brad Arant adf5449a6f fixed header tag. 2025-02-07 19:29:18 -08:00
brad Arant d34ff928d9 fixed __jet.cpp merge for cgi work. 2025-02-07 16:12:09 -08:00
brad Arant c0f44a3bc5 work on cgi. 2025-02-07 16:10:13 -08:00
Brad Arant 6e097d8433 some small testvar updates. 2025-02-06 16:06:41 -08:00
Brad Arant 10db0e9c70 created INTEGER function on operand. 2025-02-04 09:28:28 -08:00
Brad Arant ce6b163d5d added some logic for session controls. 2025-01-30 15:54:35 -08:00
Brad Arant 92d34ee689 updated TOTO. 2025-01-16 16:22:47 -08:00
Brad Arant c11d5abcd0 Fixed some bugs in include and jet tags for cgi handling. 2025-01-16 15:45:15 -08:00
Brad Arant 5cefb0974b added trim operand function. 2025-01-16 13:39:09 -08:00
Brad Arant f7812821b3 fixed right() expression. 2025-01-16 09:56:22 -08:00
Brad Arant f1f45af332 some notes on jet tag. 2025-01-15 15:44:53 -08:00
Brad Arant edebae34b1 allow cookie, header and stream only in cgi mode. 2025-01-15 14:51:15 -08:00
brad Arant b0e3cd85c7 reversion of tag work to ordered tag process. 2025-01-12 20:30:48 -08:00
brad Arant 779c6b0148 merge 2025-01-10 17:09:58 -08:00
barant 6516aee6cc Some operand work for right. Needs work. 2025-01-09 17:11:15 -08:00
barant 3f4ca13f3f fixed call tag completely. Should be done for now. 2025-01-09 13:57:12 -08:00
barant 4f616021f3 fixed if conditionals. 2025-01-09 09:16:34 -08:00
barant b65d8d4396 fixed the whiledir tag. 2025-01-09 08:02:38 -08:00
barant 4a17002d22 fixed the call tag. 2025-01-09 07:54:22 -08:00
barant 83321a2f43 fixed the for tag. 2025-01-09 07:49:11 -08:00
barant ebb6dc4ca9 think i fixed if tag. 2025-01-09 07:01:58 -08:00
barant b3693e8017 think migration is almost done, at least for set tag. 2025-01-08 17:04:36 -08:00
barant 5c27df59da work towards a clean compile on migrating set and get variables from Tag. 2025-01-08 10:27:30 -08:00
barant 2549220914 migrating getvariable and setvarable to Tag. Needs alot of work. 2025-01-06 14:57:48 -08:00
barant 229394310d some documentation changes. 2025-01-06 09:09:49 -08:00
brad Arant 6959bd8f85 Fixed scope problem on ResolveKeyword. 2025-01-03 11:24:48 -08:00
brad Arant f6dda8496c Made $[%name] to retrieve keyword values in a tag. Has bugs. 2025-01-03 10:50:31 -08:00
brad Arant 9622b5cf8c Moved keywords from local variables to keywords map. 2025-01-02 16:43:53 -08:00
brad Arant 907f449ecc Started the cookie tag. Still needs work. 2025-01-02 09:48:31 -08:00
barant af4f615799 document updates. 2024-12-23 15:48:13 -08:00
barant 3d246063e5 cleanup for valgrind. 2024-12-23 11:16:15 -08:00
barant de55071aad bug fix on operand operation for left(). 2024-12-23 09:51:50 -08:00
brad Arant e86633f506 minor test updates.;
;
2024-12-21 21:16:57 -08:00
brad Arant af7080e011 fixed local scoping on call tag. 2024-12-21 21:03:17 -08:00
brad Arant 9a9abab92d fixed scoping for local on for tag. 2024-12-21 20:26:46 -08:00
barant f3b66d9770 make uninitialized global and local variables cause exception. 2024-12-09 16:24:19 -08:00
Brad Arant 90540d3c44 cleanup 2024-12-02 15:46:49 -08:00
brad Arant ae57e06778 fixed mysql tag to give values for ?# # and field name using #n. 2024-11-27 15:37:58 -08:00
brad Arant 6d2da98024 major scope work completed. Works well!!! 2024-11-27 09:47:17 -08:00
Brad Arant 90d7d07e7e more work on scoping. 2024-11-26 17:02:59 -08:00
Brad Arant ca7aabd73f more sever scoping work. 2024-11-26 16:57:03 -08:00
Brad Arant 07e43d3f5a serious scoping work unfinished. 2024-11-26 15:25:30 -08:00
Brad Arant bd8aa1c089 fixed some bugs. Added resolveContainerParent flag to resolve set container issue not reading local variables appropriately. 2024-11-26 13:32:15 -08:00
Brad Arant e3d788bc92 error reporting now reports accurately to the line. 2024-11-26 11:17:22 -08:00
Brad Arant 79d68d6c34 minor changes on testtag.jet 2024-11-25 17:00:07 -08:00
Brad Arant 4d6b1e80b3 fixed tag to process containers in appropriate order instead of inline. 2024-11-25 13:57:35 -08:00
brad Arant 1c7edf3118 added dump tag. 2024-11-24 14:25:39 -08:00
brad Arant a9ce087939 urlencoded forms data is now workng as well. 2024-11-24 13:21:44 -08:00
brad Arant c90c7353c7 multipart/formdata now works for cgi variables. Created base for dump tag. 2024-11-24 11:20:30 -08:00
brad Arant c21dea1411 some cgi variable work. 2024-11-23 19:25:14 -08:00
brad Arant 64fd81d6ed merge 2024-11-20 08:51:29 -08:00
brad Arant 71b5f5a05e Some doc updates and test update. 2024-11-20 08:47:23 -08:00
Brad Arant b65403243a updated some documentation. 2024-11-19 16:44:15 -08:00