Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

chore: remove ai tasks from experiment#18511

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
hugodutka merged 2 commits intomainfromhugodutka/ai-tasks-remove-experiment
Jun 24, 2025
Merged
Show file tree
Hide file tree
Changes fromall commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 2 additions & 5 deletionscoderd/apidoc/docs.go
View file
Open in desktop

Some generated files are not rendered by default. Learn more abouthow customized files appear on GitHub.

7 changes: 2 additions & 5 deletionscoderd/apidoc/swagger.json
View file
Open in desktop

Some generated files are not rendered by default. Learn more abouthow customized files appear on GitHub.

1 change: 0 additions & 1 deletioncoderd/coderd.go
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -1536,7 +1536,6 @@ func New(options *Options) *API {
// Add CSP headers to all static assets and pages. CSP headers only affect
// browsers, so these don't make sense on api routes.
cspMW:=httpmw.CSPHeaders(
api.Experiments,
options.Telemetry.Enabled(),func() []*proxyhealth.ProxyHost {
ifapi.DeploymentValues.Dangerous.AllowAllCors {
// In this mode, allow all external requests.
Expand Down
7 changes: 2 additions & 5 deletionscoderd/httpmw/csp.go
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -6,7 +6,6 @@ import (
"strings"

"github.com/coder/coder/v2/coderd/proxyhealth"
"github.com/coder/coder/v2/codersdk"
)

// cspDirectives is a map of all csp fetch directives to their values.
Expand DownExpand Up@@ -59,7 +58,7 @@ const (
// Example: https://github.com/coder/coder/issues/15118
//
//nolint:revive
func CSPHeaders(experiments codersdk.Experiments,telemetry bool, proxyHosts func() []*proxyhealth.ProxyHost, staticAdditions map[CSPFetchDirective][]string) func(next http.Handler) http.Handler {
func CSPHeaders(telemetry bool, proxyHosts func() []*proxyhealth.ProxyHost, staticAdditions map[CSPFetchDirective][]string) func(next http.Handler) http.Handler {
return func(next http.Handler) http.Handler {
return http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
// Content-Security-Policy disables loading certain content types and can prevent XSS injections.
Expand DownExpand Up@@ -124,9 +123,7 @@ func CSPHeaders(experiments codersdk.Experiments, telemetry bool, proxyHosts fun
if len(extraConnect) > 0 {
for _, extraHost := range extraConnect {
// Allow embedding the app host.
if experiments.Enabled(codersdk.ExperimentAITasks) {
cspSrcs.Append(CSPDirectiveFrameSrc, extraHost.AppHost)
}
cspSrcs.Append(CSPDirectiveFrameSrc, extraHost.AppHost)
if extraHost.Host == "*" {
// '*' means all
cspSrcs.Append(CSPDirectiveConnectSrc, "*")
Expand Down
5 changes: 1 addition & 4 deletionscoderd/httpmw/csp_test.go
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -10,7 +10,6 @@ import (

"github.com/coder/coder/v2/coderd/httpmw"
"github.com/coder/coder/v2/coderd/proxyhealth"
"github.com/coder/coder/v2/codersdk"
)

func TestCSP(t *testing.T) {
Expand DownExpand Up@@ -50,9 +49,7 @@ func TestCSP(t *testing.T) {
r := httptest.NewRequest(http.MethodGet, "/", nil)
rw := httptest.NewRecorder()

httpmw.CSPHeaders(codersdk.Experiments{
codersdk.ExperimentAITasks,
}, false, func() []*proxyhealth.ProxyHost {
httpmw.CSPHeaders(false, func() []*proxyhealth.ProxyHost {
return proxyHosts
}, map[httpmw.CSPFetchDirective][]string{
httpmw.CSPDirectiveMediaSrc: expectedMedia,
Expand Down
1 change: 0 additions & 1 deletioncodersdk/deployment.go
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -3369,7 +3369,6 @@ const (
ExperimentWebPushExperiment="web-push"// Enables web push notifications through the browser.
ExperimentWorkspacePrebuildsExperiment="workspace-prebuilds"// Enables the new workspace prebuilds feature.
ExperimentAgenticChatExperiment="agentic-chat"// Enables the new agentic AI chat feature.
ExperimentAITasksExperiment="ai-tasks"// Enables the new AI tasks feature.
)

// ExperimentsSafe should include all experiments that are safe for
Expand Down
1 change: 0 additions & 1 deletiondocs/reference/api/schemas.md
View file
Open in desktop

Some generated files are not rendered by default. Learn more abouthow customized files appear on GitHub.

1 change: 0 additions & 1 deletionsite/src/api/typesGenerated.ts
View file
Open in desktop

Some generated files are not rendered by default. Learn more abouthow customized files appear on GitHub.

5 changes: 1 addition & 4 deletionssite/src/modules/dashboard/Navbar/NavbarView.tsx
View file
Open in desktop
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
import{API}from"api/api";
import{experiments}from"api/queries/experiments";
importtype*asTypesGenfrom"api/typesGenerated";
import{Button}from"components/Button/Button";
import{ExternalImage}from"components/ExternalImage/ExternalImage";
Expand All@@ -10,7 +9,6 @@ import { useWebpushNotifications } from "contexts/useWebpushNotifications";
import{useEmbeddedMetadata}from"hooks/useEmbeddedMetadata";
import{NotificationsInbox}from"modules/notifications/NotificationsInbox/NotificationsInbox";
importtype{FC}from"react";
import{useQuery}from"react-query";
import{NavLink,useLocation}from"react-router-dom";
import{cn}from"utils/cn";
import{DeploymentDropdown}from"./DeploymentDropdown";
Expand DownExpand Up@@ -145,7 +143,6 @@ const NavItems: FC<NavItemsProps> = ({ className }) => {
constlocation=useLocation();
constagenticChat=useAgenticChat();
const{ metadata}=useEmbeddedMetadata();
constexperimentsQuery=useQuery(experiments(metadata.experiments));

return(
<navclassName={cn("flex items-center gap-4 h-full",className)}>
Expand DownExpand Up@@ -178,7 +175,7 @@ const NavItems: FC<NavItemsProps> = ({ className }) => {
Chat
</NavLink>
)}
{experimentsQuery.data?.includes("ai-tasks")&&(
{metadata.tasksTabVisible.value&&(
<NavLink
className={({ isActive})=>{
returncn(linkStyles.default,isActive ?linkStyles.active :"");
Expand Down
Loading

[8]ページ先頭

©2009-2025 Movatter.jp