omniJS – failing to return values for user-defined checkBox columns


If we create a user-defined checkbox column (rather than making a built-in state column visible), the omniJS interface seems to choke on attempts to read the checkbox values:

// // Error: Attempted to return result on invalid instance of Object: 
Error: Proxy target Optional("<OOOneOfOnePopulation:0x60000001d760>") 
of type Optional<AnyObject> is not ScriptingTargetValidatable

For example, given this UI selection of a row including a user-defined checkbox column called ‘Checks’:

We get a terminal session in which the topic and other columns can be read, but attempts to read the ‘Checks’ column raise up an error from the deep. See the red dot and green text:

OO 5.1.1 (v181.17.7 r293373)


A console-pasteable snippet to get testing started:

show = (...x) =>
        null, x.length > 1 ? [x[1], null, x[0]] : x
ns = document.editors[0].selectedNodes
rs = => n.object)
n = ns[0]
r = rs[0]
strText = r.topic
cs = document.outline.columns
cns = => show({name: c.title, type: c.type.identifier.split('.').slice(-1)[0]}))


Similar read-fail with Popup columns (see red dot and green text in screen shot)

( OmniJS reading of duration, date, number and text columns all working well )

Early days, of course, for the omniJS API to OmniOutliner – but it would very welcome if all column data were to become readable.

( I can’t speak for others, but personally, when I reach for OmniOutliner, it’s always for the columns, which for me are the really striking and useful USP.

For purely textual outlining, I happen to like clear and fast widget-free screens, and tend to reach for purely textual outliners, like TaskPaper and FoldingText )