Commit Graph

330 Commits

Author SHA1 Message Date
4c15e16f59 Merge remote-tracking branch 'upstream/main' into feat/rbac
# Conflicts:
#	.github/workflows/cli-tests.yml
#	api/clients/agent_backend/__init__.py
#	api/clients/agent_backend/request_builder.py
#	api/controllers/console/app/app.py
#	api/controllers/console/app/mcp_server.py
#	api/controllers/console/workspace/members.py
#	api/controllers/openapi/__init__.py
#	api/controllers/openapi/_models.py
#	api/controllers/openapi/account.py
#	api/controllers/openapi/app_run.py
#	api/controllers/openapi/apps.py
#	api/controllers/openapi/apps_permitted_external.py
#	api/controllers/openapi/auth/__init__.py
#	api/controllers/openapi/auth/composition.py
#	api/controllers/openapi/auth/pipeline.py
#	api/controllers/openapi/files.py
#	api/controllers/openapi/human_input_form.py
#	api/controllers/openapi/workflow_events.py
#	api/controllers/openapi/workspaces.py
#	api/core/workflow/node_factory.py
#	api/core/workflow/nodes/agent_v2/agent_node.py
#	api/core/workflow/nodes/agent_v2/runtime_request_builder.py
#	api/libs/oauth_bearer.py
#	api/models/agent_config_entities.py
#	api/openapi/markdown/openapi-swagger.md
#	api/services/account_service.py
#	api/tests/unit_tests/clients/agent_backend/test_request_builder.py
#	api/tests/unit_tests/controllers/console/test_workspace_members.py
#	api/tests/unit_tests/controllers/console/workspace/test_members.py
#	api/tests/unit_tests/controllers/openapi/auth/test_composition.py
#	api/tests/unit_tests/controllers/openapi/auth/test_pipeline.py
#	api/tests/unit_tests/controllers/openapi/conftest.py
#	api/tests/unit_tests/controllers/openapi/test_account.py
#	api/tests/unit_tests/controllers/openapi/test_app_run_streaming.py
#	api/tests/unit_tests/controllers/openapi/test_human_input_form.py
#	api/tests/unit_tests/controllers/openapi/test_workflow_events_openapi.py
#	api/tests/unit_tests/core/workflow/nodes/agent_v2/test_agent_node.py
#	api/tests/unit_tests/core/workflow/nodes/agent_v2/test_runtime_request_builder.py
#	api/tests/unit_tests/libs/test_oauth_bearer_rate_limit_ordering.py
#	api/tests/unit_tests/libs/test_oauth_bearer_require_scope.py
#	api/tests/unit_tests/libs/test_workspace_member_helper.py
#	api/tests/unit_tests/services/test_oauth_device_flow.py
#	cli/AGENTS.md
#	cli/ARD.md
#	cli/package.json
#	cli/src/api/account-sessions.ts
#	cli/src/api/app-meta.test.ts
#	cli/src/api/workspaces.ts
#	cli/src/auth/file-backend.test.ts
#	cli/src/auth/file-backend.ts
#	cli/src/auth/hosts.test.ts
#	cli/src/auth/hosts.ts
#	cli/src/cache/app-info.test.ts
#	cli/src/cache/app-info.ts
#	cli/src/cache/nudge-store.test.ts
#	cli/src/cache/nudge-store.ts
#	cli/src/commands/_shared/authed-command.ts
#	cli/src/commands/auth/devices/_shared/devices.test.ts
#	cli/src/commands/auth/devices/_shared/devices.ts
#	cli/src/commands/auth/devices/list/index.ts
#	cli/src/commands/auth/login/index.ts
#	cli/src/commands/auth/login/login.test.ts
#	cli/src/commands/auth/login/login.ts
#	cli/src/commands/auth/logout/index.ts
#	cli/src/commands/auth/logout/logout.test.ts
#	cli/src/commands/auth/logout/logout.ts
#	cli/src/commands/auth/status/index.ts
#	cli/src/commands/auth/status/status.test.ts
#	cli/src/commands/auth/status/status.ts
#	cli/src/commands/auth/whoami/index.ts
#	cli/src/commands/auth/whoami/whoami.test.ts
#	cli/src/commands/auth/whoami/whoami.ts
#	cli/src/commands/config/get/index.ts
#	cli/src/commands/config/get/run.test.ts
#	cli/src/commands/config/get/run.ts
#	cli/src/commands/config/path/index.ts
#	cli/src/commands/config/set/index.ts
#	cli/src/commands/config/set/run.test.ts
#	cli/src/commands/config/set/run.ts
#	cli/src/commands/config/unset/index.ts
#	cli/src/commands/config/unset/run.test.ts
#	cli/src/commands/config/unset/run.ts
#	cli/src/commands/config/view/index.ts
#	cli/src/commands/config/view/run.test.ts
#	cli/src/commands/config/view/run.ts
#	cli/src/commands/describe/app/run.test.ts
#	cli/src/commands/describe/app/run.ts
#	cli/src/commands/env/list/run-list.ts
#	cli/src/commands/get/app/run.ts
#	cli/src/commands/get/workspace/run.ts
#	cli/src/commands/resume/app/run.ts
#	cli/src/commands/run/app/_strategies/streaming-structured.ts
#	cli/src/commands/run/app/_strategies/streaming-text.ts
#	cli/src/commands/run/app/handlers.ts
#	cli/src/commands/run/app/hitl-render.ts
#	cli/src/commands/run/app/run.test.ts
#	cli/src/commands/run/app/run.ts
#	cli/src/commands/run/app/stream-handlers.ts
#	cli/src/commands/tree.generated.ts
#	cli/src/commands/version/index.ts
#	cli/src/env/registry.ts
#	cli/src/errors/format.ts
#	cli/src/util/browser.ts
#	cli/src/version/info.ts
#	cli/src/version/nudge.test.ts
#	cli/src/version/nudge.ts
#	cli/src/version/probe.test.ts
#	cli/src/version/probe.ts
#	cli/src/version/render.ts
#	cli/src/workspace/resolver.ts
#	cli/tsconfig.json
#	eslint-suppressions.json
#	packages/contracts/generated/api/console/apps/types.gen.ts
#	packages/contracts/generated/api/console/apps/zod.gen.ts
#	packages/contracts/generated/api/openapi/orpc.gen.ts
#	packages/contracts/generated/api/openapi/types.gen.ts
#	packages/contracts/generated/api/openapi/zod.gen.ts
#	packages/dify-ui/README.md
#	pnpm-lock.yaml
#	web/app/components/app/app-publisher/index.tsx
#	web/app/components/app/app-publisher/sections.tsx
#	web/app/components/app/create-app-modal/__tests__/index.spec.tsx
#	web/app/components/app/create-app-modal/index.tsx
#	web/app/components/app/duplicate-modal/__tests__/index.spec.tsx
#	web/app/components/base/chip/index.tsx
#	web/app/components/datasets/list/dataset-card/index.tsx
#	web/app/components/datasets/list/datasets.tsx
#	web/app/components/datasets/settings/form/components/basic-info-section.tsx
#	web/app/components/rag-pipeline/components/rag-pipeline-header/run-mode.tsx
#	web/app/components/tools/edit-custom-collection-modal/index.tsx
#	web/app/components/tools/mcp/__tests__/index.spec.tsx
#	web/app/components/tools/mcp/index.tsx
#	web/app/components/tools/provider-list.tsx
#	web/app/components/tools/workflow-tool/__tests__/configure-button.spec.tsx
2026-05-28 14:01:01 +08:00
6464255d33 fix: fix DocumentSegment.keywords can not a valid json (#36715) 2026-05-27 08:42:48 +00:00
b034449a0c refactor(api): migrate console/service_api.dataset.hit_testing to BaseModel (#36533) 2026-05-27 06:51:42 +00:00
31a454abf7 fix: remove unused datasource_parameters from Notion pre-import query (#36627) 2026-05-27 10:15:22 +08:00
2cf03f3576 chore: example of current user id dep injection (#36588)
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2026-05-27 10:15:21 +08:00
6813875f31 fix: fix dataset miss permission keys 2026-05-26 13:47:30 +08:00
7d464d014c fix: remove unused datasource_parameters from Notion pre-import query (#36627) 2026-05-26 01:05:30 +00:00
135e01930b chore: example of current user id dep injection (#36588)
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2026-05-25 11:31:40 +00:00
78c25159c6 Merge branch 'main' into feat/rbac 2026-05-25 15:50:35 +08:00
345ba80942 fix: type mismatches (route says uuid: but handler says str) (#36612) 2026-05-25 07:33:32 +00:00
7f06534f07 Merge branch 'main' into feat/rbac 2026-05-24 18:24:32 +08:00
603532863d chore: add UUID/str type annotations to api endpoints for files in api/controllers/console/datasets (#36560) 2026-05-24 07:59:16 +00:00
6b1b1f3790 fix(api): use plain Session in RAG pipeline controllers to prevent closed-transaction error (#36392) 2026-05-24 03:50:59 +00:00
790ca72627 refactor(api): migrate console/service_api.dataset to BaseModel (#36480) 2026-05-22 17:39:07 +00:00
7aac3ba564 Merge branch 'main' into feat/rbac 2026-05-22 18:26:35 +08:00
ea5e487d3c fix(api): stop returning 204 with response body and add CI check (#36489) 2026-05-21 16:20:34 +00:00
092c8bca81 refactor(api): migrate console.datasets.metadata to BaseModel (#36450)
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2026-05-21 15:04:42 +00:00
ba0751bc3c Merge branch 'main' into feat/rbac 2026-05-19 15:02:56 +08:00
b04b4449db chore(api): annotate simple contract responses (#36331)
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Asuka Minato <i@asukaminato.eu.org>
2026-05-19 06:13:20 +00:00
f753e76f64 Merge branch 'main' into feat/rbac 2026-05-19 11:55:21 +08:00
2eb37caf2e refactor(api): migrate console.app.workflow to BaseModel (#36216)
Co-authored-by: WH-2099 <wh2099@pm.me>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2026-05-18 07:31:37 +00:00
658b8d038b Merge branch 'main' into feat/rbac 2026-05-15 21:26:33 +08:00
a35b28dbef refactor: cleanup duplicate code (#36173) 2026-05-14 10:34:31 +00:00
b30219c897 Merge branch 'main' into feat/rbac 2026-05-14 16:33:39 +08:00
2afa39cdcb fix: knowledge hit-testing render failed. (#36106)
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
2026-05-13 07:31:38 +00:00
57da82c7a2 Merge remote-tracking branch 'origin/main' into feat/rbac 2026-05-12 05:31:09 +00:00
e44252c242 feat: list app and dataset permission keys 2026-05-11 16:25:25 +08:00
d625ac0bf1 refactor: port some if else to match (#31841)
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2026-05-11 06:39:59 +00:00
c67ce6f66d chore: unify api && clean some type ignore (#35984)
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2026-05-10 04:16:29 +00:00
4a56763d2f refactor(api): migrate console.app.workflow etc. to BaseModel (#35967) 2026-05-09 08:34:15 +00:00
bce61ff7ce fix: hit-testing response failed because of Pydantic check. (#35640)
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
2026-04-29 10:43:38 +08:00
38eb04dc98 fix: hit-testing response failed because of Pydantic check. (#35640)
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
2026-04-28 08:37:13 +00:00
97bb338e7d fix: prevent double /v1 in MCP server URL causing 404 authorization failure (#34596)
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2026-04-20 02:42:59 +00:00
af21dc7df8 refactor(api): migrate dataset document response schemas to BaseModel (#35298)
Co-authored-by: ai-hpc <ai-hpc@users.noreply.github.com>
Co-authored-by: Asuka Minato <i@asukaminato.eu.org>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2026-04-17 05:02:04 +00:00
3193e8a712 chore: reorg imports (#35308)
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2026-04-16 08:50:02 +00:00
7e7b27fdec refactor: replace bare dict with dict[str, Any] in response converter… (#35212)
Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-14 19:45:04 +00:00
e78558bc06 refactor(api): migrate dataset hit-testing response model to BaseModel (#35192)
Co-authored-by: ai-hpc <ai-hpc@users.noreply.github.com>
2026-04-14 18:12:40 +00:00
5a446f8200 refactor(api): deduplicate dataset controller schemas into controller_schemas.py (#34756) 2026-04-13 05:33:20 +00:00
e37aaa482d refactor: migrate apikey from marshal_with/api.model to Pydantic BaseModel (#34932)
Co-authored-by: ai-hpc <ai-hpc@users.noreply.github.com>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2026-04-13 05:18:42 +00:00
33bc58c9c2 refactor(api): migrate controllers to SQLAlchemy 2.0 select() API (#34960)
Co-authored-by: Asuka Minato <i@asukaminato.eu.org>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2026-04-11 15:30:19 +00:00
b90fe73c96 fix(api): prevent cross-tenant external API use-check disclosure (#34744) 2026-04-10 03:23:32 +00:00
b8858708be chore: remove commented-out reqparse code from rag_pipeline_workflow (#34860)
Co-authored-by: ai-hpc <ai-hpc@users.noreply.github.com>
2026-04-09 15:37:39 +00:00
4c05316a7b refactor(api): deduplicate DSL shared entities into dsl_entities.py (#34762)
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2026-04-09 06:04:18 +00:00
1c7cf44af4 refactor: convert SegmentType controllers if/elif to match/case (#30001) (#34784) 2026-04-09 01:11:47 +00:00
a8fa552b3a refactor: convert importStatus if/elif to match/case (#30001) (#34780) 2026-04-09 00:04:47 +00:00
bd257777a0 refactor(api): deduplicate workflow controller schemas into controller_schemas.py (#34755) 2026-04-08 23:49:04 +00:00
396b39dff9 refactor: migrate session.query to select API in console controllers (#34607) 2026-04-07 04:19:30 +00:00
985b41c40b fix(security): add tenant_id validation to prevent IDOR in data source binding (#34456)
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-02 13:17:02 +00:00
99
318a3d0308 refactor(api): tighten login and wrapper typing (#34447) 2026-04-02 09:36:58 +00:00
43c48ba4d7 fix: add tenant/dataset ownership checks to prevent IDOR vulnerabilities (#34436)
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2026-04-02 05:45:20 +00:00