Urgent.News

What's breaking now, across thousands of outlets.

Tech

End every scheduled agent run with one line a script can read

I have a few scheduled Claude tasks that work while I'm away. One posts to X on a fixed schedule and records the numbers. Another runs a weekly review and writes the next week's drafts. Each run ends with a report in the chat. A model's prose report is easy to read and hard to add up. The fact you need can sit anywhere: a sales figure in the fourth paragraph, a deadline mentioned in passing. So…

To ensure accurate reporting from scheduled agent runs, follow these key principles:

1. Each report should conclude with a single line per result, containing a tag, JSON object, and a space. The prose remains separate above these lines.

2. Adhere to specific tags and required fields for each type of report:

- RPT_REVENUE requires fields like product, month, sales_mtd, count_mtd, currency, as_of, and source.

- RPT_EVENT needs kind, title, date, and status.

- RPT_RESULT requires task and status fields.

3. If a run couldn't retrieve a number (e.g., due to expired login), omit that line entirely. In such cases, the accompanying prose should indicate "not retrieved" along with the reason.

4. Maintain consistency in how numbers are reported. If a run looked up a figure and saw 0, the JSON should contain 0. However, if the run couldn't access the data, no line should be written for that number.

5. Each line represents confirmed results from the run's own data and previously recorded status. Avoid making estimates or repeating information that has already been reported.

6. The most crucial rule: distinguish between a zero value (when the run actually checked and found 0) and missing data (when the run couldn't retrieve the information). Zero values should be counted, while missing data should not contribute to the total.

7. If a task fails to run due to an issue (like a Windows update preventing it), the report should simply be absent for that time period. A parser can't detect a missing report, so manual checks are necessary to compare when the last run occurred with the expected frequency.

Written by urgent.news from Dev.to's reporting — not their text. Machine-written — may contain errors; check the original before relying on it.

Read the original at dev.to →

More in Tech

Cordiale Brings IRC to the Desktop Through Grappa

IRC still gives people a direct way to talk in real time. Azzurra, an Italian IRC network that has been online since 1997, lists more than 100 active channels.

  • Cordiale is a desktop IRC client for Windows, macOS, and Linux.
  • It communicates with Grappa via REST and Phoenix Channels over WebSocket.
  • Cordiale offers optional end-to-end encryption for private chats.

Arabic and English in one Django site: four bugs that weren't translation

I'm an architect, and I built Architectena , a professional site for architects (portfolio, CV, architecture-only jobs, office pages and a studio workspace) that runs fully in Arabic and English.

  • Year 2026 displayed as 2,026 due to thousand separator setting
  • Arabic filter bars persisted despite comprehensive .po catalogue
  • Arabic number formats corrected by overriding FORMATMODULEPATH

Constructor and Destructor in C++ - Explained in Simple Words

What is Constructor and Destructor in C++? In C++, Constructor and Destructor are special functions of a class. They are automatically called when we create or destroy an object.

  • Constructors automatically called when objects created
  • Initialize object properties upon creation
  • Same name as class, no return type

More from Thursday 19 November →