SnapshotPlugin question redux

48 views
Skip to first unread message

Chris Eichenberg

unread,
Sep 1, 2023, 9:28:25 AM9/1/23
to TiddlyWikiClassic
I search through old posts and the closest entry I could find was . . . 
https://groups.google.com/g/tiddlywiki/c/Llh2xOl5YkM/m/tWsraRiaxvsJ

I'm using the form and data plugins to create a template to create a narrative to which to which I would plug in data, output the finish product. 

Like the poster above I am not getting the output with the data. It is outputting the template as blank not populated.

I guess first, does anyone recall if there was ever a solution? Second can anyone think of tweak that would get the data to output?

Yakov

unread,
Sep 2, 2023, 8:04:49 AM9/2/23
to TiddlyWikiClassic
Hi Kometman,

could you provide the links to the plugins you've mentioned (beside the SnapshotPlugin)? What saver do you use? Is the resulting file empty, or it is not, but it is displayed empty?

If the problem is about SnapshotPlugin not saving the file at all, you probably need a saver that support saveFile functionality, for instance Timimi (in Firefox), nwTWcSaver, or tiddly-node-saver (I'm not sure if core "download saving" works with it, too).

пятница, 1 сентября 2023 г. в 16:28:25 UTC+3, komet...@gmail.com:

Chris Eichenberg

unread,
Sep 2, 2023, 5:02:20 PM9/2/23
to TiddlyWikiClassic
Udo Borkowski's DataTiddlerPlugin and FormTiddlerPlugin. The tiddlywiki file saves fine, the issue is the SnapshotPlugin, it just prints the template without data transcluded data. I always used TiddlyDesktop or the *.hta trick as I save to flash or HD. I got into Tiddlywikis around version 2.6.3 or thereabouts, when you could still save on Firefox; those were ones that worked when that no longer became an option * wistful sigh *. And if it ain't broke . . . 


Okido

unread,
Sep 3, 2023, 4:39:59 AM9/3/23
to TiddlyWikiClassic
Hello Kometman,

Can you explain how your output file should look like, do you expect a static HTML file, a pdf or something else.
I use the DataTiddlerPlugin and FormTiddlerPlugin a lot and output the information in nicely formatted pdf's, but I only use the data, the generation of tables, headers, bold, italic etc. is done with pdfMake.

Have a nice day, Okido
Op zaterdag 2 september 2023 om 23:02:20 UTC+2 schreef komet...@gmail.com:

Yakov

unread,
Sep 3, 2023, 10:31:55 AM9/3/23
to TiddlyWikiClassic
Ok, if it's not a problem of saving ("it just prints the template without data transcluded data" = it saves the snapshot, but the data is not populated, right?), it can be a plugin compatibility issue. We can debug this using either approach:
  • comparing the actual and the expected behaviors (that's what Okido is talking about);
  • comparing a setup that worked and the current one that doesn't.
Either way, it will be helpful if you provide a TW with the plugins you use (attach it here) and explain how to reproduce what you're experiencing. By the way, I didn't get what saver are you using now? You have only mentioned some savers in the past tense :)

Have you tried using Timimi with Firefox?

A side note: you may want to take a look at this issue, where William Shallum shared how the .hta trick can be still used today (I haven't added the potential fix to the core yet, though).
воскресенье, 3 сентября 2023 г. в 11:39:59 UTC+3, Okido:

Chris Eichenberg

unread,
Sep 3, 2023, 9:09:40 PM9/3/23
to TiddlyWikiClassic
click on Udo name, some how it linked. 

I use TiddlyDesktop. Yep, I've switch a random file of mine to *.hta every once to see if it works.

the tiddler on the screen shows "something something ____data____ something", but the snapshot only shows "something something _________ something". 

miight scripting issue. I have two old files I for resumes, that I the *.hta trick on. both produced snapshot files with the data. the versions I tried 2.6.2 and 2.8.1. I then I tried it with the file in question, it throws up an error but still produces the desired output. I forgotten how *.hta doesn't render CSS very well.

image_2023-09-03_210838746.png

Yakov

unread,
Oct 31, 2023, 4:38:18 AM10/31/23
to TiddlyWikiClassic
Ouch, my previous message was lost due to an internet issue, I'll try to reconstruct as much as I can.

Hello Kometman, sorry for the late reply, but we really need more detail to reproduce the issue to help with it. Describe (or share) what a tiddler with data contains (or rather a minimal bit that's not rendered), what a tiddler that's snapshotted contains (or better a minimal markup that shows the issue), how do you do the snapshot (with what macro/toolbar command), etc. Pretend that we know nothing.

For instance, in the attached TW 2.9.4, I've installed SnapshotPlugin and added snapshotSave to ToolbarCommands; installed DataTiddlerPlugin and FormTiddlerPlugin (I suspect that it's not needed to reproduce the issue, but I may be wrong) – all latest from TT and Udo's site. I've also ForEachTiddlerPlugin, just to hide an error in DataTiddlerPlugin, but it's probably not needed as well.

I'm using the latest Firefox (118.0.2) with Timimi for saving, and I'm on Windows.

I've created [[Data holder]] tiddler with this content:

<data>{"name":"John Brown","age":34}</data>
<<showData>>

I've also tweaked SnapshotPlugin to fix it for contemporary Firefox (see the line below // YL tweak), as it failed on an attempt to pick path when using the snap command.

Finally, I've clicked the snap command for the [[Data holder]] tiddler, chose "tiddler: 'Data holder' (content only)", inserted the full path, and confirmed. As a result, my snapshot.html was successfully saved (I'm attaching it as well).

Feel free to reuse the attached TW to build a minimal reproducible example of the issue. Once you provide enough info to reproduce the issue, we'll definitely be able to help with this.

Best regards,
Yakov.
понедельник, 4 сентября 2023 г. в 04:09:40 UTC+3, komet...@gmail.com:
reproducing Kometman's issue in 2.9.4.html
snapshot.html

Chris Eichenberg

unread,
Nov 8, 2023, 3:44:07 PM11/8/23
to TiddlyWikiClassic
of course after posting that question while going through some old tiddlers i found my own answer. 

<<forEachTiddler
where 'tiddler.tags.contains("personChronicle")'
write
'"<hr>{{bookT{"+tiddler.data("p.given")+" "+tiddler.data("p.surname")+"}}}<hr>\nHark, for the parchment unveils the tale of a &#x0283;oul&#x0027;s journey through the annals of time . . . \n\nGreetings. Today we gather to illuminate the life of a fellow traveler in this earthly realm. Let us &#x0283;hare in the recollections of {{aside{"+tiddler.data("p.given")+"}}}, a name etched in the chronicles of our age.\n\nLet us delve into the very roots of this tale. {{aside{"+tiddler.data("p.given")+"}}}, born on . . . \n\n\n "'
>>


Reply all
Reply to author
Forward
0 new messages