Timestamp (STRING):
RF_Timestamp creates a text timestamp from the current date and time when the node executes. It uses Python’s date-and-time formatting conventions, so you can choose a compact label for generated artwork, filenames, or workflow records. The timestamp reflects the machine’s local date and time at execution; it is not a fixed value captured when you first add the node. The node also signals that its result can change independently of edits to its settings, although the workflow determines when execution actually occurs.
Timestamp (STRING) Input Parameters:
format
A STRING that controls how the date and time are written. Formatting codes beginning with % stand for date or time components: for example, %Y is the four-digit year, %m is the month, and %d is the day. Ordinary characters, such as hyphens and underscores, appear as written. The default is %Y-%m-%d_%H%M%S, which produces a timestamp such as 2026-11-16_143025 for November 16, 2026, at 14:30:25 local time. Changing this setting changes the text’s appearance, not the moment being read. No minimum or maximum length, or list of allowed options, is specified in the node source.
Timestamp (STRING) Output Parameters:
time
A STRING containing the current local date and time formatted according to format when the node executes. With the default format, the result combines the date and 24-hour time down to the second, making it useful as a readable label or part of a filename. It is text rather than a date object or an elapsed-time measurement; its exact value depends on when execution happens and on the machine’s local clock.
Timestamp (STRING) Usage Tips:
- Keep the default
%Y-%m-%d_%H%M%Sfor compact, readable labels that include seconds. For a date-only label, use%Y-%m-%d; for a more human-readable display, use%Y-%m-%d %H:%M:%S. - When using the timestamp in a filename, prefer separators such as hyphens and underscores. Avoid adding characters that your destination filesystem may reject, such as a colon on Windows.
- If multiple executions can occur within the same second, the default format may produce identical text. Add
_%fto include microseconds when you need finer time detail, while keeping in mind that this is not a guarantee of unique filenames.
Timestamp (STRING) Common Errors and Solutions:
ValueError: Invalid format string
- Explanation: Python’s date formatter may reject an unsupported or malformed formatting code. The exact error text and which codes are accepted can depend on the operating system.
- Solution: Check each
%code informat. Start with the known default%Y-%m-%d_%H%M%S, then add or change one code at a time.
TypeError: strftime() argument 1 must be str, not ...
- Explanation: The formatting method needs text. This error can occur if an incompatible value reaches
formatinstead of a STRING; the exact wording may vary by Python version. - Solution: Supply a text format, such as
%Y-%m-%d, and check any connected value feeding this input.
The time output is blank
- Explanation: An empty
formatstring produces an empty string rather than a visible timestamp. - Solution: Enter formatting text, such as the default
%Y-%m-%d_%H%M%S.
The timestamp does not match the expected time zone
- Explanation: The node reads the executing machine’s local time. Its source does not provide a time-zone setting.
- Solution: Check the machine’s clock and time-zone configuration. If you need a particular time zone independently of that machine setting, use a separate time-zone-aware step.
Two results have the same timestamp
- Explanation: The default format shows time only to the second, so executions within the same second can produce the same text.
- Solution: Include
%ffor finer time detail, or use an additional unique identifier where distinct names are essential.
