Troubleshooting

BWEB fails quietly far more often than it raises. This page is ordered by what the symptom actually means, because the instinctive guess is usually wrong.

The whole site returns 404, on every URL

Including /_claude/ping, and the page shown is the generic "Wakanda" one.

BSPK_WEB_ON_CONNECTION does not compile. It is not routing, not the domain, not your page. bspk.log stays empty — only the 4D compiler window names the error. Compare the If / End if balance against git HEAD.

One page is entirely blank or broken

A single block killed the render. The dev toast names the block, its uuid and the error. If the message mentions a collection or an object being expected, suspect a null where {} is required, or a flat V20 CSS cube.

A block renders empty, with no error

In order:

  1. #4DCODE raised. An error inside 4D code renders the block empty with no message. Put a trace at the top.
  2. A mandatory property is missing — the block is incomplete, not broken.
  3. For a listbox: vt_TableName is missing.
  4. For a select or checkbox group: the filling function does not match the WF signature, or BSPK_REFRESH_STORAGE has not been run.

A button does nothing

  1. The security check refused the POST. Look for a JSON answer with an error code on /bweb/call-action. Your function was never called.
  2. The function is not loaded — a call to an unloaded function hangs, it does not error.
  3. The name is not camelCase (it is camel-cased before lookup).
  4. The class has no extends, so the panel never offered it properly.

How to actually see the answer

bspk.js uses XHR, not fetch — a hook on fetch captures nothing. In the console:

const o = XMLHttpRequest.prototype.open, s = XMLHttpRequest.prototype.send;
XMLHttpRequest.prototype.open = function(m,u,...r){ this.__u=u; return o.call(this,m,u,...r); };
XMLHttpRequest.prototype.send = function(b){
  if (String(this.__u).includes('call-action'))
    this.addEventListener('load', () => console.log(this.responseText.slice(0,600)));
  return s.call(this,b);
};

A function missing from the dispatch whitelist answers HTTP 200 with an empty response — {"vc_Action":[],"vb_Continue":true,…}. No error, no toast, nothing written. The function was never executed, so even a Try/Catch returning Last errors stays silent.

Trap: that empty answer is the signature of a missing BSPK_REFRESH_STORAGE. It sends developers debugging business logic for hours.

Server-side tracing: BSPK_LOG(<text>) writes to bspk.log in the project's Data folder — the only practical trace, since the debugger is unreachable from a web-driven request. The current data folder path is recorded in <project>/userPreferences.<USERNAME>/preferences.4DPreferences; read <USERNAME> from the environment, never hard-code it.

A save reports success and writes nothing

  1. The field has no vt_FieldName — it is stripped by the whitelist.
  2. The field is outside the container named by vt_SendAllObjectsOfBlocName.
  3. vt_SendAllObjectsOfBlocName holds a uuid or a block name instead of the name of the other parameter — vt_FieldValue then arrives as {}.
  4. The field has no onChange — the generic save writes only the triggering field.

Diagnosis is always the same gesture: read the request body of /bweb/call-action in the browser's network tab, and compare it with what 4D received.

A style does not apply

  1. A *Unit is missing — 11 properties generate nothing without it.
  2. The class was never compiled into output.css, because the string it lives in does not start with a Tailwind prefix (see Styling: the CSS cube and Tailwind).
  3. The rule is beaten on specificity inside the panel's shadow root.

My code change has no effect

  1. You changed component code and only reloaded (a reload never touches the component).
  2. You changed a template and did not run BSPK_REFRESH_STORAGE.
  3. RELOAD PROJECT ran with no Design environment, so it silently did nothing.
  4. The result is cached in the session — a changed column formula or conditional display keeps showing the old value until you log out and back in. F5 is not enough. This one makes correct code look broken for a long time.

Always finish on a trace only the new code could produce.

Everything broke at once, unrelated things

One class does not compile. A syntax error in a single function makes the entire class unloadable, so every function it holds disappears at once. Suspect that before suspecting your change.

See also