Skip to content

[draft] Add experimental build#270

Closed
anyoung-tableau wants to merge 4 commits intomainfrom
anyoung/experimental
Closed

[draft] Add experimental build#270
anyoung-tableau wants to merge 4 commits intomainfrom
anyoung/experimental

Conversation

@anyoung-tableau
Copy link
Collaborator

@anyoung-tableau anyoung-tableau commented Mar 18, 2026

The build now emits TWO files.

The original index.js (with import.meta.env.BUILD_CONFIGURATION replaced with "default")
A new index-experimental.js file (with import.meta.env.BUILD_CONFIGURATION replaced with "experimental")

withTrace,
} from '@openai/agents';
import { OpenAI } from 'openai/client.js';
import OpenAI from 'openai';
Copy link
Collaborator Author

@anyoung-tableau anyoung-tableau Mar 18, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The TypeScript compiler was complaining about this line with the module resolution changes.

@@ -0,0 +1,13 @@
import { BuildConfiguration, isBuildConfiguration } from './scripts/buildConfigurations';

class MetaEnv {
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This abstraction isn't really necessary, but I prefer the type-safety it provides, rather than just cluttering the code and referencing import.meta.env.BUILD_CONFIGURATION everywhere.

Comment on lines +4 to +6
"module": "ESNext",
"moduleResolution": "bundler",
"noEmit": true,
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These changes are to get tsc to stop complaining about the use of import.meta.env. We're only using tsc for type-checking anyway so threw in noEmit for good measure.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant