Commit Graph
1352 Commits
Author SHA1 Message Date
JilunSun7274andXubin Ren e5179aa7db delete redundant whitespaces in subagent prompts 2026-03-20 13:30:21 +08:00
JilunSun7274andXubin Ren 517de6b731 docs: add subagent workspace assignment hint to spawn tool description 2026-03-20 13:30:21 +08:00
mamamiyearandXubin Ren d70ed0d97a fix: nanobot onboard update config crash
when use onboard and choose N,
maybe sometimes will be crash and
config file will be invalid.
2026-03-20 13:16:56 +08:00
0b1beb0e9f Fix TypeError for MCP tools with nullable JSON Schema params
MCP servers (e.g. Zapier) return JSON Schema union types like
`"type": ["string", "null"]` for nullable parameters. The existing
`validate_params()` and `cast_params()` methods expected only simple
strings as `type`, causing `TypeError: unhashable type: 'list'` on
every MCP tool call with nullable parameters.

Add `_resolve_type()` helper that extracts the first non-null type
from union types, and use it in `_cast_value()` and `_validate()`.
Also handle `None` values correctly when the schema declares a
nullable type.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-20 13:13:11 +08:00
Xubin RenandXubin Ren dd7e3e499f fix: separate Telegram connection pools and add timeout retry to prevent pool exhaustion
The root cause of "Pool timeout" errors is that long-polling (getUpdates)
and outbound API calls (send_message, send_photo, etc.) shared the same
HTTPXRequest pool — polling holds connections indefinitely, starving sends
under concurrent load (e.g. cron jobs + user chat).

- Split into two independent pools: API calls (default 32) and polling (4)
- Expose connection_pool_size / pool_timeout in TelegramConfig for tuning
- Add _call_with_retry() with exponential backoff (3 attempts) on TimedOut
- Apply retry to _send_text and remote media URL sends
2026-03-19 16:15:41 +08:00
mamamiyearandXubin Ren d9cb729596 feat: support feishu code block 2026-03-19 13:59:31 +08:00
Xubin Ren 214bf66a29 docs(readme): clarify nanobot is unrelated to crypto 2026-03-18 15:18:38 +00:00
Xubin RenandXubin Ren 4b052287cb fix(telegram): validate remote media URLs 2026-03-18 23:12:11 +08:00
h4nz4andXubin Ren a7bd0f2957 feat(telegram): support HTTP(S) URLs for media in TelegramChannel
Fixes #1792
2026-03-18 23:12:11 +08:00
Xubin RenandXubin Ren 728d4e88a9 fix(providers): lazy-load provider exports 2026-03-18 22:01:29 +08:00
Javis486andXubin Ren 28127d5210 When using custom_provider, a prompt "LiteLLM:WARNING" will still appear during conversation 2026-03-18 22:01:29 +08:00
Xubin Ren 4e40f0aa03 docs: MiniMax gifts to the nanobot community 2026-03-18 05:09:03 +00:00
vivganesandXubin Ren e6910becb6 logo: transparent background
Also useful when we build the gateway.  Dark and bright modes can use the same logo.
2026-03-18 12:41:38 +08:00
Xubin RenandXubin Ren 5bd1c9ab8f fix(cron): preserve exact intervals in list output 2026-03-18 12:39:06 +08:00
12aa7d7aca test(cron): add unit tests for _format_timing and _format_state helpers
Tests the helpers directly without needing CronService, covering all
schedule kinds, edge cases (missing fields, unknown status), and
combined state output.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-18 12:39:06 +08:00
8d45fedce7 refactor(cron): extract _format_timing and _format_state helpers
Addresses review feedback: moves schedule formatting and state
formatting into dedicated static methods, removes duplicate
in-loop imports, and simplifies _list_jobs() to a clean loop.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-18 12:39:06 +08:00
228e1bb3de style: apply ruff format to cron tool
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-18 12:39:06 +08:00
5d8c5d2d25 style(test): fix import sorting and remove unused imports
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-18 12:39:06 +08:00
787e667dc9 test(cron): add tests for _list_jobs() schedule and state formatting
Covers all three schedule kinds (cron/every/at), human-readable interval
formatting, run state display (last run, status, errors, next run),
and disabled job filtering.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-18 12:39:06 +08:00
eb83778f50 fix(cron): show schedule details and run state in _list_jobs() output
_list_jobs() only displayed job name, id, and schedule kind (e.g. "cron"),
omitting the actual timing and run state. The agent couldn't answer
"when does this run?" or "did it run?" even though CronSchedule and
CronJobState had all the data.

Now surfaces:
- Cron expression + timezone for cron jobs
- Human-readable interval for every jobs
- ISO timestamp for one-shot at jobs
- Enabled/disabled status
- Last run time + status (ok/error/skipped) + error message
- Next scheduled run time

Fixes #1496

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-18 12:39:06 +08:00
zhangxiaoyu.yorkandXubin Ren f72ceb7a3c fix:set subagent result message role = assistant 2026-03-18 00:43:46 +08:00
angleyanalbedoandXubin Ren 20e3eb8fce docs(readme): fix broken link to Channel Plugin Guide 2026-03-17 23:09:35 +08:00
Xubin RenandXubin Ren 8cf11a0291 fix: preserve image paths in fallback and session history 2026-03-17 22:37:09 +08:00
Xubin RenandXubin Ren 7086f57d05 test(feishu): cover media msg_type mapping 2026-03-17 17:05:13 +08:00
weipeng0098andXubin Ren 47e2a1e8d7 fix(feishu): use correct msg_type for audio/video files 2026-03-17 17:05:13 +08:00
Xubin RenandXubin Ren 41d59c3b89 test(feishu): cover heading and table markdown rendering 2026-03-17 16:51:02 +08:00
Your NameandXubin Ren 9afbf386c4 fix(feishu): fix markdown rendering issues in headings and tables
- Fix double bold markers (****) when heading text already contains **
- Strip markdown formatting (**bold**, *italic*, ~~strike~~) from table cells
  since Feishu table elements do not support markdown rendering

Fixes rendering issues where:
1. Headings like '**text**' were rendered as '****text****'
2. Table cells with '**bold**' showed raw markdown instead of plain text
2026-03-17 16:51:02 +08:00
Xubin RenandXubin Ren 91ca82035a feat(slack): add default done reaction on completion 2026-03-17 16:19:08 +08:00
Sihyeon JangandXubin Ren 8aebe20cac feat(slack): update reaction emoji on task completion
Remove the in-progress reaction (reactEmoji) and optionally add a
done reaction (doneEmoji) when the final response is sent, so users
get visual feedback that processing has finished.

Signed-off-by: Sihyeon Jang <sihyeon.jang@navercorp.com>
2026-03-17 16:19:08 +08:00
Xubin RenandXubin Ren 49fc50b1e6 test(custom): cover empty choices response handling 2026-03-17 14:24:55 +08:00
Jiajun XieandXubin Ren 2eb0c283e9 fix(providers): handle empty choices in custom provider response 2026-03-17 14:24:55 +08:00
Xubin RenandGitHub b939a916f0 Merge PR #1763: align onboard with config and workspace overrides
align onboard with config and workspace overrides
2026-03-17 14:03:50 +08:00
Xubin Ren 499d0e1588 docs(readme): update multi-instance onboard examples 2026-03-17 05:58:13 +00:00
Xubin Ren b2a550176e feat(onboard): align setup with config and workspace flags 2026-03-17 05:42:49 +00:00
Xubin RenandGitHub a9621e109f Merge PR #1136: fix: workspace path in onboard command ignores config setting
fix: workspace path in onboard command ignores config setting
2026-03-17 13:10:32 +08:00
Xubin Ren 40a022afd9 fix(onboard): use configured workspace path on setup 2026-03-17 05:01:34 +00:00
Xubin Ren c4cc2a9fb4 Merge remote-tracking branch 'origin/main' into pr-1136 2026-03-17 04:42:01 +00:00
Xubin Ren db37ecbfd2 fix(custom): support extraHeaders for OpenAI-compatible endpoints 2026-03-17 04:28:24 +00:00
Xubin Ren 84565d702c docs: update v0.1.4.post5 release news 2026-03-16 15:28:41 +00:00
Xubin Ren df7ad91c57 docs: update to v0.1.4.post5 release 2026-03-16 15:27:40 +00:00
Xubin Ren 337c4600f3 bump version to 0.1.4.post5 2026-03-16 15:11:15 +00:00
Xubin Ren dbe9cbc78e docs: update news section 2026-03-16 14:27:28 +00:00
PeterandXubin Ren 4e67bea697 Delete .claude directory 2026-03-16 22:17:40 +08:00
Peter van EijkandXubin Ren 93f363d4d3 qol: add version id to logging 2026-03-16 22:17:40 +08:00
Peter van EijkandXubin Ren ad1e9b2093 pull remote 2026-03-16 22:17:40 +08:00
Xubin RenandXubin Ren 2eceb6ce8a fix(cli): pause spinner cleanly before printing progress output 2026-03-16 22:17:29 +08:00
who96andXubin Ren 9a652fdd35 refactor(cli): restore context manager pattern for spinner lifecycle
Replace manual _active_spinner + _pause_spinner/_resume_spinner with
_ThinkingSpinner class that owns the spinner lifecycle via __enter__/
__exit__ and provides a pause() context manager for temporarily
stopping the spinner during progress output.

Benefits:
- Restores Pythonic context manager pattern matching original code
- Eliminates duplicated start/stop boilerplate between single-message
  and interactive modes
- pause() context manager guarantees resume even if print raises
- _active flag prevents post-teardown resume from async callbacks
2026-03-16 22:17:29 +08:00
who96andXubin Ren 48fe92a8ad fix(cli): stop spinner before printing tool progress lines
The Rich console.status() spinner ('nanobot is thinking...') was not
cleared when tool call progress lines were printed during processing,
causing overlapping/garbled terminal output.

Replace the context-manager approach with explicit start/stop lifecycle:
- _pause_spinner() stops the spinner before any progress line is printed
- _resume_spinner() restarts it after printing
- Applied to both single-message mode (_cli_progress) and interactive
  mode (_consume_outbound)

Closes #1956
2026-03-16 22:17:29 +08:00
Xubin RenandXubin Ren 92f3d5a8b3 fix: keep truncated session history tool-call consistent 2026-03-16 17:25:30 +08:00
riseandXubin Ren db276bdf2b Fix orphan tool results in truncated session history 2026-03-16 17:25:30 +08:00