Commit Graph

3498 Commits

Author SHA1 Message Date
ProgrammerIn-wonderland f944d76261 change initialization order to make wisp socket on first use of networking 2025-05-16 17:18:28 -04:00
ProgrammerIn-wonderland 73e6830b1f Add reauthentication for unauthenticated web clients 2025-05-16 13:45:55 -04:00
KernelDeimos 880760c602 ux: use financial units instead of SI for credits
Instead of K, M, G, T, P it's K, M, B, T, Q.
2025-05-15 14:05:35 -04:00
KernelDeimos 3290440f4b dev: document auth and permissions 2025-05-15 14:05:35 -04:00
jelveh 0e0bfd6d7c Update PuterDialog.js
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 (18.x) (push) Has been cancelled
test / test (20.x) (push) Has been cancelled
test / test (22.x) (push) Has been cancelled
2025-05-13 17:34:11 -07:00
KernelDeimos 3dbe89f3dc dev: migrate "Create Shortcut" to DRY multi/single
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 (18.x) (push) Has been cancelled
test / test (20.x) (push) Has been cancelled
test / test (22.x) (push) Has been cancelled
2025-05-12 17:34:04 -04:00
KernelDeimos aa049b2c5a dev: factor out menu items functions in UIItem
The large if...else block for single-item vs multi-item selection
context menu items makes it difficult to extract common behaviors
between the two. For example, the "create shortcut" menu item could be
added by the same code snippet in both cases, and that snippet might
have conditional logic for the number of items (with 1 as a special
case).

The reason to move branching logic to the code snippets that handle
individual menu items is because the previous change to fix shortcuts in
shared directories revealed cross-cutting concerns in branching logic.
Since both single-item and multi-item "create shortcut" options both
have branching to handle the shared directory case, they are now more
similar than different.
2025-05-12 16:39:21 -04:00
KernelDeimos 73ab4baa60 dev: SI suffix for usage meter 2025-05-12 15:18:02 -04:00
KernelDeimos 72a45500d5 fix: cannot create shortcut for shared file
Closes #1263
2025-05-12 13:25:38 -04:00
KernelDeimos 518449cfdd fix: share issue
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 (18.x) (push) Has been cancelled
test / test (20.x) (push) Has been cancelled
test / test (22.x) (push) Has been cancelled
2025-05-09 17:04:00 -04:00
KernelDeimos 9bf48e7289 fix: fallback behavior related to fake-chat service
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 (18.x) (push) Has been cancelled
test / test (20.x) (push) Has been cancelled
test / test (22.x) (push) Has been cancelled
Fallbacks from or to the fake-chat service should not be allowed.
Fallbacks to the "costly" model from fake-chat could result in
unintended charges and fallbacks to real models from fake-chat could
result in service abuse.
2025-05-05 16:10:52 -04:00
KernelDeimos 34787bbb0c fix: gone
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 (18.x) (push) Has been cancelled
test / test (20.x) (push) Has been cancelled
test / test (22.x) (push) Has been cancelled
2025-05-03 21:27:21 -04:00
KernelDeimos 77f3bf2177 fix: ui bug in settings window
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 (18.x) (push) Has been cancelled
test / test (20.x) (push) Has been cancelled
test / test (22.x) (push) Has been cancelled
2025-05-02 16:01:26 -04:00
KernelDeimos 75aebd6d35 fix: sqlite syntax inconsistency
The SQL statement for creating a group uses syntax that only works under
sqlite. This was caused by introducing anomaly detection when a user
creates a large number of groups in quick succession.
2025-05-02 14:34:46 -04:00
KernelDeimos 4647e2d9c0 dev: add experimental firebase authentication
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 (18.x) (push) Has been cancelled
test / test (20.x) (push) Has been cancelled
test / test (22.x) (push) Has been cancelled
This adds an experimental custom token authentication endpoint to Puter.
This is disabled unless the firebase-auth service is explicitly
configured, and is not yet ready for production use.
2025-05-01 17:14:25 -04:00
Nivedita Rani 284b89a5fd fix: iframe overlap issue (PR 1250)
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 (18.x) (push) Has been cancelled
test / test (20.x) (push) Has been cancelled
test / test (22.x) (push) Has been cancelled
* Removed css property overflow: hidden at the parent container which was interfering with the layout calculations and was forcefully clipping child elements

* Replace css property overflow: hidden  with contain: paint to fix stacking without masking border-radius

Fixes #1233
2025-05-01 13:55:17 -04:00
KernelDeimos ea241540b9 dev: add WeatherService
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 (18.x) (push) Has been cancelled
test / test (20.x) (push) Has been cancelled
test / test (22.x) (push) Has been cancelled
- adds weather service
- updates IdentificationService to add ip_user property
2025-04-29 13:43:53 -04:00
KernelDeimos 29dbf3a517 dev: URLs to files in public directories
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 (18.x) (push) Has been cancelled
test / test (20.x) (push) Has been cancelled
test / test (22.x) (push) Has been cancelled
Already existing was the functionality to go to puter.local/@username to
access the Public folder belonging to "username". This commit adds the
ability for relative paths such as puter.local/@username/document.md to
access /username/Public/document.md in the suggested app for handling
".md" files.
2025-04-28 17:40:02 -04:00
KernelDeimos 3856ddcc8f dev: add default parameters for driver interfaces
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 (18.x) (push) Has been cancelled
test / test (20.x) (push) Has been cancelled
test / test (22.x) (push) Has been cancelled
2025-04-25 16:03:22 -04:00
KernelDeimos c5c17bae3a dev: add cost calculation for NewsDataService 2025-04-25 14:14:58 -04:00
KernelDeimos 78ae6f6bf2 dev: begin implementing driver for newsdata.io
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 (18.x) (push) Has been cancelled
test / test (20.x) (push) Has been cancelled
test / test (22.x) (push) Has been cancelled
2025-04-24 17:04:30 -04:00
KernelDeimos 89b8c8de1d fix: add missing null check 2025-04-24 16:09:32 -04:00
KernelDeimos b7efa6f894 fix: handle problematic null or undefined case
This is the product of a couple hours of debugging. We can now remove
the uuid entry from the cache for a deleted user without the strange
lockup behavior that was being observed previously. However, it is still
explained exactly how this happened; while this commit addresses the
cause it does not represent an actual understanding of the issue.

What is known is the following:
- /delete-own-user can trigger a complete lockup
- this happens when invalidate_cached_user is called
- kv.del('users:uuid:<uuid of user>') triggers the issue
- ... because get_user returns null and
- configurable_auth middleware accepts the null value
- configurable_auth middleware DOES call next()
- it is unknown why a lockup occurs after this
2025-04-24 14:41:05 -04:00
KernelDeimos 210ecaba8f tmp: comment out user uuid del
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 (18.x) (push) Has been cancelled
test / test (20.x) (push) Has been cancelled
test / test (22.x) (push) Has been cancelled
2025-04-23 22:33:25 -04:00
KernelDeimos 2b0c8fcaf0 dev: expose Context and ready event to extensions
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 (18.x) (push) Has been cancelled
test / test (20.x) (push) Has been cancelled
test / test (22.x) (push) Has been cancelled
2025-04-23 15:51:28 -04:00
KernelDeimos abf5852b93 dev: better log support for extensions 2025-04-23 15:28:15 -04:00
KernelDeimos a3ae60861c dev: add injected logger support
This allows a logger to be specified in the execution context. If
LogService sees this, it will perform its usual logging but also call
the injected logger.
2025-04-23 14:49:18 -04:00
KernelDeimos 017328420d dev: add support for an "any" interface
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 (18.x) (push) Has been cancelled
test / test (20.x) (push) Has been cancelled
test / test (22.x) (push) Has been cancelled
Driver interfaces don't require specifying the structure of the return
value when it's a JSON object, but parameters require specifying what
parameters can be provided. This commit adds a special wildcard
parameter for interface definitions. When the wildcard parameter is set,
the entire input object is considered as if it were the value of one
parameter.
2025-04-22 16:29:55 -04:00
KernelDeimos 790e3bdffc dev: puter.call
Instead of puter.drivers.call, make it puter.call. This is accomplished
by allowing puter.js modules to mutate the `puter` object on
initialization. Support for an optional `_init` method, similar to
backend services, is added to Puter modules to help with this.
2025-04-22 15:21:36 -04:00
KernelDeimos 9935f5a0be dev: simplify calling drivers with matching names
This commit modifies puter.js to allow calling an
interface+service+method with matching names without redundantly
specifying. The 'ip-geo' service is also renamed to ipgeo to match its
method name and allow a simple:

puter.drivers.call('ipgeo', { ip: '1.2.3.4' })
2025-04-22 14:01:01 -04:00
KernelDeimos 1764b99c22 dev: add log messages for cost records 2025-04-22 13:14:41 -04:00
KernelDeimos 7e7e2897b2 dev: improve actor logs
This commit adds the concept of a toLogFields method on objects which
will determine how they're turned into log fields in LogService. This
method is now implemented on actor to prevent errors when the object is
passed to log functions without being stringified first.
2025-04-22 12:52:09 -04:00
KernelDeimos b80052f177 dev: add cost service integration to IPGeoService 2025-04-22 12:07:13 -04:00
KernelDeimos 7945586050 dev: ip geolocation driver (initial development)
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 (18.x) (push) Has been cancelled
test / test (20.x) (push) Has been cancelled
test / test (22.x) (push) Has been cancelled
2025-04-21 17:53:39 -04:00
KernelDeimos 8ff2e93e66 tweak: add limit to deleteUser file select
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 (18.x) (push) Has been cancelled
test / test (20.x) (push) Has been cancelled
test / test (22.x) (push) Has been cancelled
I wasn't able to reprod any memory leak from a user having a large
number of files locally, but it's showing up in logs and maybe could add
up with lots of temp users getting auto-removed. It's worth a shot.
2025-04-19 15:45:33 -04:00
KernelDeimos f7b302b024 fix: potential log error 2025-04-19 14:27:14 -04:00
KernelDeimos c254b39afe fix: consistent email check in confirm-email 2025-04-19 11:07:13 -04:00
KernelDeimos c959ef3b83 dev: add actor to log context when available
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 (18.x) (push) Has been cancelled
test / test (20.x) (push) Has been cancelled
test / test (22.x) (push) Has been cancelled
2025-04-18 16:55:11 -04:00
KernelDeimos fdfa4cbc7c dev: log memory info periodically 2025-04-18 16:26:52 -04:00
KernelDeimos cc72508b75 dev: remove default system prompt
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 (18.x) (push) Has been cancelled
test / test (20.x) (push) Has been cancelled
test / test (22.x) (push) Has been cancelled
2025-04-17 15:35:35 -04:00
jelveh 2cdcc5ffcd Add o3 and o4-mini models
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 (18.x) (push) Has been cancelled
test / test (20.x) (push) Has been cancelled
test / test (22.x) (push) Has been cancelled
2025-04-16 11:06:57 -07:00
jelveh b17dc58ca6 remove unused imported modules
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 (18.x) (push) Has been cancelled
test / test (20.x) (push) Has been cancelled
test / test (22.x) (push) Has been cancelled
2025-04-15 23:44:11 -07:00
jelveh 19574e5bb1 Update OpenAICompletionService.js 2025-04-15 23:33:03 -07:00
jelveh c732263958 Update AI.js 2025-04-15 23:24:53 -07:00
jelveh cab933f1c2 Update AI.js
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 (18.x) (push) Has been cancelled
test / test (20.x) (push) Has been cancelled
test / test (22.x) (push) Has been cancelled
2025-04-14 12:56:32 -07:00
jelveh 68860d8876 Update AI.js 2025-04-14 12:52:54 -07:00
jelveh 42f0ac5785 Use OpenAI for `o1-mini1 2025-04-14 12:44:58 -07:00
jelveh 90d16c35e2 Add missing openai models 2025-04-14 12:36:07 -07:00
jelveh 16b8adc4ed add new GPT models 2025-04-14 12:26:04 -07:00
jelveh 2d7ca7f2e1 better error message for invalid emails
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 (18.x) (push) Has been cancelled
test / test (20.x) (push) Has been cancelled
test / test (22.x) (push) Has been cancelled
2025-04-13 18:24:06 -07:00