Commit Graph

3577 Commits

Author SHA1 Message Date
Arya Dasgupta 0028b41fe3 docs: add example for streaming with function calling (#2365)
Docker Image CI / build-and-push-image (push) Has been cancelled
Maintain Release Merge PR / update-release-pr (push) Has been cancelled
release-please / release-please (push) Has been cancelled
* docs: add example for streaming with function calling

* Minor fix and add example to playground

---------

Co-authored-by: Reynaldi Chernando <reynaldichernando@gmail.com>
2026-01-28 18:01:28 +07:00
jelveh fc8117df1e add login indicator with animated spinner
Docker Image CI / build-and-push-image (push) Has been cancelled
Maintain Release Merge PR / update-release-pr (push) Has been cancelled
release-please / release-please (push) Has been cancelled
test / test-backend (24.x) (push) Has been cancelled
test / API tests (node env, api-test) (24.x) (push) Has been cancelled
test / puterjs (node env, vitest) (24.x) (push) Has been cancelled
2026-01-27 23:39:18 -08:00
Daniel Salazar 89c49902b6 otel: add spans to all kv methods (#2358) 2026-01-27 19:16:04 -08:00
Daniel Salazar 4183d5de06 [PUT-466] fix: count request costs in openrouter models with request cost present (#2356) 2026-01-27 18:32:43 -08:00
Daniel Salazar cc5285f88a fix: only rate limit login when failed (#2355) 2026-01-27 18:24:05 -08:00
KernelDeimos e7443338fb fix: more reliable 404 responses for .api endpoint
Docker Image CI / build-and-push-image (push) Has been cancelled
Maintain Release Merge PR / update-release-pr (push) Has been cancelled
release-please / release-please (push) Has been cancelled
test / test-backend (24.x) (push) Has been cancelled
test / API tests (node env, api-test) (24.x) (push) Has been cancelled
test / puterjs (node env, vitest) (24.x) (push) Has been cancelled
This fix avoids some situations where a non-existing route hangs instead
of responding with 404.
2026-01-27 15:46:28 -05:00
KernelDeimos a8dc62ef80 fix: header resend issue with catch-all handler
WebDAVService catches `/*`, which shouldn't be a problem because it is
on the `dav.` subdomain - however, other middlewares were being invoked
before the subdomain check. Thanks to the `'route'` parameter for the
`next` function we can handle subdomain checks in a more reliable way
2026-01-27 15:46:28 -05:00
Lui Duarte bbe6f9dc27 Feat: Add system info (Client + Server metrics) (#2311)
* Add ststem info to user options extensions - Add UIWindowSystemInfo, add ui sections for client and server, add basic getClientinfo function

* Fix typo

* Replace accidentally deleted es.js file

* Refactor client information to be consistant with project standard

* Complete Client information in ststem information window

* Remove console logs

* Add basic api functionality for getting server system information

* Structure return data from system server information endpoint | Add copyright to UIWindowSystemInfo

* Add function to format server system api data | Add loading element to server container while waiting for data | Complete System Information

* fix: disallow non admin for backend + move to extensions

---------

Co-authored-by: Daniel Salazar <daniel.salazar@puter.com>
2026-01-27 10:29:02 -08:00
ProgrammerIn-wonderland bbe1242eff Move webdav to dav.puter.com
Docker Image CI / build-and-push-image (push) Has been cancelled
Maintain Release Merge PR / update-release-pr (push) Has been cancelled
release-please / release-please (push) Has been cancelled
test / test-backend (24.x) (push) Has been cancelled
test / API tests (node env, api-test) (24.x) (push) Has been cancelled
test / puterjs (node env, vitest) (24.x) (push) Has been cancelled
2026-01-27 20:31:32 +05:30
KernelDeimos 404a5e9050 dev: fix issues with dns lookup, remove fallback
Docker Image CI / build-and-push-image (push) Has been cancelled
Maintain Release Merge PR / update-release-pr (push) Has been cancelled
release-please / release-please (push) Has been cancelled
test / test-backend (24.x) (push) Has been cancelled
test / API tests (node env, api-test) (24.x) (push) Has been cancelled
test / puterjs (node env, vitest) (24.x) (push) Has been cancelled
This is the effort remaining to bring back URL parameters to drivers
which support them. This fixes the implementation for DNS resolution
resulting in errors for undefined IP addresses when DNS resolution is
successful.
2026-01-26 15:01:22 -05:00
KernelDeimos 72078d3bc1 wip: try to resolve DNS with cloudflare DNS 2026-01-26 15:01:22 -05:00
KernelDeimos b935006ee7 Revert "fix: disable requests from server in two services"
This reverts commit de77b11954.
2026-01-26 15:01:22 -05:00
Daniel Salazar 66a3af69c9 fix: suggested apps breaking (#2343) 2026-01-26 10:17:48 -08:00
Daniel Salazar 8bb4dec231 perf: don't fetch b64 icon for apps always, and lru suggestedApps (#2336)
Docker Image CI / build-and-push-image (push) Has been cancelled
Maintain Release Merge PR / update-release-pr (push) Has been cancelled
release-please / release-please (push) Has been cancelled
test / test-backend (24.x) (push) Has been cancelled
test / API tests (node env, api-test) (24.x) (push) Has been cancelled
test / puterjs (node env, vitest) (24.x) (push) Has been cancelled
* perf: don't fetch b64 icon for apps always, and lru suggestedApps

* fix: fallback to default file icon if present
2026-01-23 20:57:12 -08:00
Reynaldi Chernando 143cbdce23 Add info about usage data scope for docs (#2334) 2026-01-24 10:18:54 +07:00
Daniel Salazar 2402e49cce fix: log format (#2333)
Docker Image CI / build-and-push-image (push) Has been cancelled
Maintain Release Merge PR / update-release-pr (push) Has been cancelled
release-please / release-please (push) Has been cancelled
test / test-backend (24.x) (push) Has been cancelled
test / API tests (node env, api-test) (24.x) (push) Has been cancelled
test / puterjs (node env, vitest) (24.x) (push) Has been cancelled
2026-01-23 13:47:02 -08:00
Daniel Salazar 2287704102 perf: batch readdir suggested apps into single big query (#2332)
* perf: batch readdir suggested apps into single big query

* fix: cleanup fucntions to go through single entry
2026-01-23 12:24:02 -08:00
KernelDeimos de77b11954 fix: disable requests from server in two services
Docker Image CI / build-and-push-image (push) Has been cancelled
Maintain Release Merge PR / update-release-pr (push) Has been cancelled
release-please / release-please (push) Has been cancelled
test / test-backend (24.x) (push) Has been cancelled
test / API tests (node env, api-test) (24.x) (push) Has been cancelled
test / puterjs (node env, vitest) (24.x) (push) Has been cancelled
2026-01-23 08:40:00 -05:00
ProgrammerIn-wonderland 5922f36358 fix gemini cost key 2026-01-23 18:45:10 +05:30
ProgrammerIn-wonderland 17e5edd643 Video model details 2026-01-23 16:01:50 +05:30
Nariman Jelveh 894bb939b1 Add aspect ratio resize options to window menu
Docker Image CI / build-and-push-image (push) Has been cancelled
Maintain Release Merge PR / update-release-pr (push) Has been cancelled
release-please / release-please (push) Has been cancelled
test / test-backend (24.x) (push) Has been cancelled
test / API tests (node env, api-test) (24.x) (push) Has been cancelled
test / puterjs (node env, vitest) (24.x) (push) Has been cancelled
Introduced a resize_window_to_aspect_ratio function and added 'Advanced' menu items to allow resizing the window to 16:9, 4:3, or 9:16 aspect ratios. This enhances user control over window dimensions for specific use cases.
2026-01-22 15:59:07 -08:00
Daniel Salazar d42f9b0e10 fix: disable bad token checks? (#2326) 2026-01-22 15:38:26 -08:00
Daniel Salazar d3a27be88e fix: dedup get_apps app requests (#2325)
Docker Image CI / build-and-push-image (push) Has been cancelled
Maintain Release Merge PR / update-release-pr (push) Has been cancelled
release-please / release-please (push) Has been cancelled
test / test-backend (24.x) (push) Has been cancelled
test / API tests (node env, api-test) (24.x) (push) Has been cancelled
test / puterjs (node env, vitest) (24.x) (push) Has been cancelled
* fix: dedup get_apps app requests

* fix: WSPushService errors

* fix: error messages
2026-01-22 11:07:42 -08:00
ProgrammerIn-wonderland 2a8ec97c09 add safety checks for worker updates
Docker Image CI / build-and-push-image (push) Has been cancelled
Maintain Release Merge PR / update-release-pr (push) Has been cancelled
release-please / release-please (push) Has been cancelled
test / test-backend (24.x) (push) Has been cancelled
test / API tests (node env, api-test) (24.x) (push) Has been cancelled
test / puterjs (node env, vitest) (24.x) (push) Has been cancelled
2026-01-22 18:53:59 +05:30
Daniel Salazar e9631b5a04 perf: dedup and cache get_apps in puter gui, also add more app batching in backend (#2319)
* perf: dedup and cache get_apps in puter gui

* feat: batch more apps
2026-01-21 23:31:49 -08:00
Daniel Salazar fbe87369f5 fix: add back test (#2317)
Docker Image CI / build-and-push-image (push) Has been cancelled
Maintain Release Merge PR / update-release-pr (push) Has been cancelled
release-please / release-please (push) Has been cancelled
test / test-backend (24.x) (push) Has been cancelled
test / API tests (node env, api-test) (24.x) (push) Has been cancelled
test / puterjs (node env, vitest) (24.x) (push) Has been cancelled
2026-01-21 21:37:36 -08:00
KernelDeimos b98f1be5fb Revert "feat(data-access): move puter.js read to app driver"
This reverts commit 2139551abf.

It looks like this breaks dev-center because the file associations
aren't properly sent. I will need to investigate this.
2026-01-22 00:35:56 -05:00
jelveh 70f58b08eb Update label from 'Publish Web Pages' to 'Hosting API' 2026-01-21 20:50:52 -08:00
KernelDeimos 20b5662704 dev(backend): make data-access an essential module 2026-01-21 23:00:45 -05:00
KernelDeimos 2139551abf feat(data-access): move puter.js read to app driver
This is the first functional migration from ths `es:app` driver to the
`app` driver. Any call to `puter.apps.get` will go through `es:app`
after this change.
2026-01-21 23:00:45 -05:00
jelveh 0b55d19f89 Add initial Puter.js documentation site 2026-01-21 19:39:01 -08:00
Daniel Salazar 6e9e5371c8 fix: batch fetch get apps for launch apps and recommended apps (#2315)
* wip: batch fetch get apps for launch apps and recommended apps

* fix: boot issues

* fix: bad refresh app cache

* tmp: remove test for now since can't mock db call
2026-01-21 18:17:15 -08:00
KernelDeimos 17b5ff4cb5 Revert "feat(data-access): move puter.js read to app driver"
Docker Image CI / build-and-push-image (push) Has been cancelled
Maintain Release Merge PR / update-release-pr (push) Has been cancelled
release-please / release-please (push) Has been cancelled
test / test-backend (24.x) (push) Has been cancelled
test / API tests (node env, api-test) (24.x) (push) Has been cancelled
test / puterjs (node env, vitest) (24.x) (push) Has been cancelled
This reverts commit f3100eca59.
2026-01-21 12:33:25 -05:00
KernelDeimos f3100eca59 feat(data-access): move puter.js read to app driver
This is the first functional migration from ths `es:app` driver to the
`app` driver. Any call to `puter.apps.get` will go through `es:app`
after this change.
2026-01-21 12:25:59 -05:00
Daniel Salazar 929fc6956e [PUT-456] fix: delete apps from marketplace when deleting anywhere else (#2310)
Docker Image CI / build-and-push-image (push) Has been cancelled
Maintain Release Merge PR / update-release-pr (push) Has been cancelled
release-please / release-please (push) Has been cancelled
test / test-backend (24.x) (push) Has been cancelled
test / API tests (node env, api-test) (24.x) (push) Has been cancelled
test / puterjs (node env, vitest) (24.x) (push) Has been cancelled
2026-01-20 23:42:24 -08:00
Daniel Salazar 4e6d9c9f33 perf: improve tel + decrease logs (#2309)
Docker Image CI / build-and-push-image (push) Has been cancelled
Maintain Release Merge PR / update-release-pr (push) Has been cancelled
release-please / release-please (push) Has been cancelled
test / test-backend (24.x) (push) Has been cancelled
test / API tests (node env, api-test) (24.x) (push) Has been cancelled
test / puterjs (node env, vitest) (24.x) (push) Has been cancelled
* perfmon: lower healthcheck status cache, add kv health signal

* perf: improve tel + decrease logs

* logs
2026-01-20 20:21:08 -08:00
KernelDeimos bf84ff4b10 config(perms): allow apps service to all users
Docker Image CI / build-and-push-image (push) Has been cancelled
Maintain Release Merge PR / update-release-pr (push) Has been cancelled
release-please / release-please (push) Has been cancelled
test / test-backend (24.x) (push) Has been cancelled
test / API tests (node env, api-test) (24.x) (push) Has been cancelled
test / puterjs (node env, vitest) (24.x) (push) Has been cancelled
2026-01-20 16:28:22 -05:00
KernelDeimos 3fe304ebac dev(data-access): re-add protected app support
Adds support for the "protected apps" feature to the new `apps` driver
that will replace the existing `es:apps` driver.
2026-01-20 16:28:22 -05:00
KernelDeimos d08a828226 test(data-access): avoid SQL error in app:es
It turned out this error was not coming from `app`, but it was coming
from `app:es` due to a pre-existing issue. Since these tests are meant
to compare the resulting behavior and `app` can handle this case while
`app:es` cannot, the best course of action is to avoid invoking the
issue and only test the intended behavior.
2026-01-20 16:28:22 -05:00
KernelDeimos 768a35e9b5 fix(data-access): read response regression
In `es:app`, attempting to read an app that doesn't exist results in an
error being thrown. This commit updates `app` to have the same behavior.
2026-01-20 16:28:22 -05:00
KernelDeimos 5b33beb6a1 test(data-access): check for error, not undefined
Check for error when an app doesn't exist, because this is the behavior
`es:app` already exhibits.
2026-01-20 16:28:22 -05:00
KernelDeimos 519ad336ba test: differences between es:app and app
Add tests for all the CRUD operations and related edge cases in `app` to
ensure the behavior is the same as `es:app`. These tests detect 3 issues
across 4 failing tests.
2026-01-20 16:28:22 -05:00
KernelDeimos bd416b0190 test: ensure kv global is always available
This is comitted separately from the commit for AppService.comp.test.js
that will follow because it interacts with all other test cases. It did
not cause any issue based on what I observed, but I'm still wrapping it
in a separate commit in case we need to revert or change it later.
2026-01-20 16:28:22 -05:00
KernelDeimos 503c1a4bb8 test: refactor AppService comparison test 2026-01-20 16:28:22 -05:00
KernelDeimos 1c438107aa test(data-access): verify and fix database state compare
An "anti-test" (test that should fail) was created to verify that a test
fails when apps are different. This revealed a problem in the original
logic of comparing the database state (UUIDs don't need to be, and will
not be, identical; they need to be excluded from comparison). This
commit contains the new test and fixes the existing test case, which was
passing because this problem caused a false-negative.
2026-01-20 16:28:22 -05:00
KernelDeimos b17486b1b4 fix(backend): fix context dual-instance problem
The file `context.js` causes problems in unit tests because vitest does
not play nice with CJS, especially when both CJS and ESM are in use such
as in our repository.

Given that it is not feasible to solve the underlying interoperability
issue, I have elected to make `context.js` a singleton in `Symbol.for`.
This worked very well with `helpers.js`.
2026-01-20 16:28:22 -05:00
KernelDeimos be8b5ef70a fix(backend): singleton in helpers for testability
The `helpers.js` file has two instances when testing with vitest.
Usually this can be solved by creating an "import bridge" file - another
CJS file that imports the desired CJS file and re-exports it so that the
`require` mechanism for caching modules is used instead of the `import`
mechanism for caching modules. Unfortunately in my most recent test
cases this does not work. I do not know why this does not work. However,
without doing a deep-dive into the internals of vitest I can at least
see that the only state in helpers is for providing `services` as a
pseudo-global, so a hack with `Symbol.for` solves everything.
2026-01-20 16:28:22 -05:00
KernelDeimos 7531a94687 clean(data-access): remove bad fixes and simplify 2026-01-20 16:28:22 -05:00
KernelDeimos 01b50b66f2 test(data-access): regression test for es:app vs app
This test was very difficult to get working because of issues
initializing the context under vitest. After a lot of effort and trying
to narrow down the issue in many ways that didn't work, I eventually
found that manually setting the storage and calling run on the
AsyncLocalStorage object got it working. I'm currently unsure if this is
specific to vitest or not. We don't seem to do this in Puter's kernel
but everything works fine in the typical runtime. Maybe this is
side-effect of otel's own use of AsyncLocalStorage.
2026-01-20 16:28:22 -05:00
KernelDeimos 3a268e6f16 test(data-access): add tests for delete method 2026-01-20 16:28:22 -05:00