diff --git a/build-system/global-configs/canary-config.json b/build-system/global-configs/canary-config.json index bab436730446..9b0636a165e4 100644 --- a/build-system/global-configs/canary-config.json +++ b/build-system/global-configs/canary-config.json @@ -1,24 +1,16 @@ { "allow-doc-opt-in": ["amp-next-page"], "allow-url-opt-in": [], - "amp-accordion-display-locking": 1, "canary": 1, "a4aProfilingRate": 0.01, - "adsense-ad-size-optimization": 1, "doubleclickSraExp": 0.01, "doubleclickSraReportExcludedBlock": 0.1, "dfp-render-on-idle-cwv-exp": 1, - "expand-json-targeting": 1, "flexAdSlots": 0.05, "ios-fixed-no-transfer": 1, - "visibility-trigger-improvements": 1, "ads-initialIntersection": 1, - "amp-cid-backup": 1, "sticky-ad-transition": 0.1, "layout-aspect-ratio-css": 1, - "tcf-post-message-proxy-api": 1, - "amp-consent-granular-consent": 1, - "disable-a4a-non-sd": 1, "3p-vendor-split": 0.1, "story-ad-placements": 1 } diff --git a/build-system/global-configs/prod-config.json b/build-system/global-configs/prod-config.json index 296c0cfa0fee..d09839893692 100644 --- a/build-system/global-configs/prod-config.json +++ b/build-system/global-configs/prod-config.json @@ -3,20 +3,12 @@ "allow-url-opt-in": [], "canary": 0, "a4aProfilingRate": 0.01, - "adsense-ad-size-optimization": 1, - "amp-accordion-display-locking": 1, "doubleclickSraExp": 0.01, "doubleclickSraReportExcludedBlock": 0.1, - "expand-json-targeting": 1, "flexAdSlots": 0.05, "ios-fixed-no-transfer": 0, - "visibility-trigger-improvements": 1, "layout-aspect-ratio-css": 0, "sticky-ad-transition": 0.02, - "disable-a4a-non-sd": 1, - "tcf-post-message-proxy-api": 1, - "amp-consent-granular-consent": 1, - "amp-cid-backup": 1, "3p-vendor-split": 0.01, "story-ad-placements": 0.01 } diff --git a/extensions/amp-a4a/0.1/amp-a4a.js b/extensions/amp-a4a/0.1/amp-a4a.js index c44524c0bdac..70d7d478e28c 100644 --- a/extensions/amp-a4a/0.1/amp-a4a.js +++ b/extensions/amp-a4a/0.1/amp-a4a.js @@ -56,7 +56,7 @@ import { getConsentPolicyState, } from '../../../src/consent'; import {getContextMetadata} from '../../../src/iframe-attributes'; -import {getExperimentBranch, isExperimentOn} from '../../../src/experiments'; +import {getExperimentBranch} from '../../../src/experiments'; import {getExtensionsFromMetadata} from './amp-ad-utils'; import {getMode} from '../../../src/mode'; import {insertAnalyticsElement} from '../../../src/extension-analytics'; @@ -2586,7 +2586,8 @@ export function isPlatformSupported(win) { // Require Shadow DOM support for a4a. if ( !isNative(win.Element.prototype.attachShadow) && - isExperimentOn(win, 'disable-a4a-non-sd') + /* isExperimentOn(win, 'disable-a4a-non-sd') // launched: true */ + true ) { return false; } diff --git a/extensions/amp-a4a/0.1/test/test-amp-a4a.js b/extensions/amp-a4a/0.1/test/test-amp-a4a.js index 2426ec86ec2e..00eb59512694 100644 --- a/extensions/amp-a4a/0.1/test/test-amp-a4a.js +++ b/extensions/amp-a4a/0.1/test/test-amp-a4a.js @@ -61,7 +61,6 @@ import {layoutRectLtwh, layoutSizeFromRect} from '../../../../src/layout-rect'; import {macroTask} from '../../../../testing/yield'; import {resetScheduledElementForTesting} from '../../../../src/service/custom-element-registry'; import {data as testFragments} from './testdata/test_fragments'; -import {toggleExperiment} from '../../../../src/experiments'; import {data as validCSSAmp} from './testdata/valid_css_at_rules_amp.reserialized'; describes.realWin('amp-a4a: no signing', {amp: true}, (env) => { @@ -254,7 +253,6 @@ describes.realWin('amp-a4a: no signing', {amp: true}, (env) => { }); it('should fallback when shadow DOM is not supported', async () => { - toggleExperiment(env.win, 'disable-a4a-non-sd', true, true); attachShadowStub.value(undefined); const fallbackSpy = env.sandbox.spy(a4a, 'handleFallback_'); env.sandbox.stub(a4a, 'skipClientSideValidation').returns(false); @@ -265,7 +263,6 @@ describes.realWin('amp-a4a: no signing', {amp: true}, (env) => { }); it('should fallback when shadow DOM is polyfilled', async () => { - toggleExperiment(env.win, 'disable-a4a-non-sd', true, true); attachShadowStub.value(function () { // A non-native function. return null; @@ -279,7 +276,8 @@ describes.realWin('amp-a4a: no signing', {amp: true}, (env) => { }); it('should ignore shadow DOM requirement without an experiment', async () => { - toggleExperiment(env.win, 'disable-a4a-non-sd', false, true); + /* toggleExperiment(env.win, 'disable-a4a-non-sd', false, true) // launched: true */ + false; attachShadowStub.value(undefined); const fallbackSpy = env.sandbox.spy(a4a, 'handleFallback_'); env.sandbox.stub(a4a, 'skipClientSideValidation').returns(false); @@ -1587,7 +1585,6 @@ describes.realWin('amp-a4a', {amp: true}, (env) => { // Remove attachShadow. attachShadowStub.value(undefined); - toggleExperiment(fixture.win, 'disable-a4a-non-sd', true, true); fetchMock.getOnce( TEST_URL + '&__amp_source_origin=about%3Asrcdoc', @@ -1634,7 +1631,6 @@ describes.realWin('amp-a4a', {amp: true}, (env) => { attachShadowStub.value(function () { return null; }); - toggleExperiment(fixture.win, 'disable-a4a-non-sd', true, true); fetchMock.getOnce( TEST_URL + '&__amp_source_origin=about%3Asrcdoc', diff --git a/extensions/amp-accordion/0.1/amp-accordion.js b/extensions/amp-accordion/0.1/amp-accordion.js index 22a5667ee72f..fdf35bfbad4a 100644 --- a/extensions/amp-accordion/0.1/amp-accordion.js +++ b/extensions/amp-accordion/0.1/amp-accordion.js @@ -27,7 +27,6 @@ import {createCustomEvent} from '../../../src/event-helper'; import {dev, devAssert, user, userAssert} from '../../../src/log'; import {dict} from '../../../src/utils/object'; import {getStyle, setImportantStyles, setStyles} from '../../../src/style'; -import {isExperimentOn} from '../../../src/experiments'; import { numeric, px, @@ -43,8 +42,8 @@ const EXPAND_CURVE_ = bezierCurve(0.47, 0, 0.745, 0.715); const COLLAPSE_CURVE_ = bezierCurve(0.39, 0.575, 0.565, 1); const isDisplayLockingEnabledForAccordion = (win) => - isExperimentOn(win, 'amp-accordion-display-locking') && - win.document.body.onbeforematch !== undefined; + /* isExperimentOn(win, 'amp-accordion-display-locking') // launched: true */ + true && win.document.body.onbeforematch !== undefined; class AmpAccordion extends AMP.BaseElement { /** @override @nocollapse */ diff --git a/extensions/amp-accordion/0.1/test/test-amp-accordion.js b/extensions/amp-accordion/0.1/test/test-amp-accordion.js index 162f2e2c1aaf..b31aa744dbe4 100644 --- a/extensions/amp-accordion/0.1/test/test-amp-accordion.js +++ b/extensions/amp-accordion/0.1/test/test-amp-accordion.js @@ -26,7 +26,6 @@ import { whenUpgradedToCustomElement, } from '../../../../src/dom'; import {poll} from '../../../../testing/iframe'; -import {toggleExperiment} from '../../../../src/experiments'; describes.realWin( 'amp-accordion', @@ -202,8 +201,6 @@ describes.realWin( }); it('should expand when beforematch event is triggered on a collapsed section', async () => { - // Enable display locking feature. - toggleExperiment(win, 'amp-accordion-display-locking', true); doc.body.onbeforematch = null; await getAmpAccordion(); const section = doc.querySelector('section:not([expanded])'); @@ -216,7 +213,8 @@ describes.realWin( expect(header.getAttribute('aria-expanded')).to.equal('true'); // Reset display locking feature - toggleExperiment(win, 'amp-accordion-display-locking', false); + /* toggleExperiment(win, 'amp-accordion-display-locking', false) // launched: true */ + false; doc.body.onbeforematch = undefined; }); diff --git a/extensions/amp-accordion/1.0/amp-accordion.js b/extensions/amp-accordion/1.0/amp-accordion.js index 22faa401454a..3164806a973d 100644 --- a/extensions/amp-accordion/1.0/amp-accordion.js +++ b/extensions/amp-accordion/1.0/amp-accordion.js @@ -44,8 +44,8 @@ class AmpAccordion extends BaseElement { const {win} = this; const displayLockingExperimentEnabled = - isExperimentOn(win, 'amp-accordion-display-locking') && - win.document.body.onbeforematch !== undefined; + /* isExperimentOn(win, 'amp-accordion-display-locking') // launched: true */ + true && win.document.body.onbeforematch !== undefined; if (displayLockingExperimentEnabled) { this.element.classList.add('i-amphtml-display-locking'); diff --git a/extensions/amp-accordion/1.0/test/test-amp-accordion.js b/extensions/amp-accordion/1.0/test/test-amp-accordion.js index 564b565aa619..d0929ad63c4f 100644 --- a/extensions/amp-accordion/1.0/test/test-amp-accordion.js +++ b/extensions/amp-accordion/1.0/test/test-amp-accordion.js @@ -55,7 +55,6 @@ describes.realWin( win = env.win; html = htmlFor(win.document); toggleExperiment(win, 'bento-accordion', true, true); - toggleExperiment(win, 'amp-accordion-display-locking', true, true); element = html`
@@ -658,7 +657,6 @@ describes.realWin( let defaultBeforeMatch; beforeEach(async () => { - toggleExperiment(win, 'amp-accordion-display-locking', true); element = html`
@@ -682,7 +680,8 @@ describes.realWin( afterEach(() => { win.CSS.supports = defaultCssSupports; win.document.body.onbeforematch = defaultBeforeMatch; - toggleExperiment(win, 'amp-accordion-display-locking', false); + /* toggleExperiment(win, 'amp-accordion-display-locking', false) // launched: true */ + false; }); it('should expand collpased section with beforematch event', async () => { diff --git a/extensions/amp-analytics/0.1/analytics-root.js b/extensions/amp-analytics/0.1/analytics-root.js index 9a0e1d14f30f..9411537ce195 100644 --- a/extensions/amp-analytics/0.1/analytics-root.js +++ b/extensions/amp-analytics/0.1/analytics-root.js @@ -25,7 +25,6 @@ import { import {dev, user, userAssert} from '../../../src/log'; import {getMode} from '../../../src/mode'; import {isArray} from '../../../src/types'; -import {isExperimentOn} from '../../../src/experiments'; import {layoutRectLtwh} from '../../../src/layout-rect'; import {map} from '../../../src/utils/object'; import {provideVisibilityManager} from './visibility-manager'; @@ -342,7 +341,8 @@ export class AnalyticsRoot { */ getElements(context, selectors, selectionMethod) { if ( - isExperimentOn(this.ampdoc.win, 'visibility-trigger-improvements') && + /* isExperimentOn(this.ampdoc.win, 'visibility-trigger-improvements') // launched: true */ + true && isArray(selectors) ) { userAssert( diff --git a/extensions/amp-analytics/0.1/test/test-analytics-root.js b/extensions/amp-analytics/0.1/test/test-analytics-root.js index a00cae7953e3..82dc0dfefb63 100644 --- a/extensions/amp-analytics/0.1/test/test-analytics-root.js +++ b/extensions/amp-analytics/0.1/test/test-analytics-root.js @@ -23,7 +23,6 @@ import { VisibilityManagerForDoc, VisibilityManagerForEmbed, } from '../visibility-manager'; -import {toggleExperiment} from '../../../../src/experiments'; import {user} from '../../../../src/log'; describes.realWin('AmpdocAnalyticsRoot', {amp: 1}, (env) => { @@ -339,11 +338,11 @@ describes.realWin('AmpdocAnalyticsRoot', {amp: 1}, (env) => { child.setAttribute('data-vars-id', 'child1'); child2.setAttribute('data-vars-id', 'child2'); child3.setAttribute('data-vars-id', 'child3'); - toggleExperiment(win, 'visibility-trigger-improvements', true); }); afterEach(() => { - toggleExperiment(win, 'visibility-trigger-improvements', false); + /* toggleExperiment(win, 'visibility-trigger-improvements', false) // launched: true */ + false; }); it('should find element and elements by selector', async () => { @@ -355,7 +354,8 @@ describes.realWin('AmpdocAnalyticsRoot', {amp: 1}, (env) => { child2, ]); // Check that non-experiment works - toggleExperiment(win, 'visibility-trigger-improvements', false); + /* toggleExperiment(win, 'visibility-trigger-improvements', false) // launched: true */ + false; expect( await root.getElements(body, '.notMyClass', null) ).to.deep.equal([child3]); @@ -421,7 +421,8 @@ describes.realWin('AmpdocAnalyticsRoot', {amp: 1}, (env) => { }); it('should find non AMP element with single selector', async () => { - toggleExperiment(win, 'visibility-trigger-improvements', false); + /* toggleExperiment(win, 'visibility-trigger-improvements', false) // launched: true */ + false; child.classList.remove('i-amphtml-element'); child.removeAttribute('data-vars-id'); child.classList.add('myClass'); @@ -753,13 +754,12 @@ describes.realWin( child.setAttribute('data-vars-id', '123'); child2.setAttribute('data-vars-id', '456'); child3.setAttribute('data-vars-id', '789'); - - toggleExperiment(win, 'visibility-trigger-improvements', true); }); afterEach(() => { child.classList.add('i-amphtml-element'); - toggleExperiment(win, 'visibility-trigger-improvements', false); + /* toggleExperiment(win, 'visibility-trigger-improvements', false) // launched: true */ + false; }); it('should find all elements by selector', async () => { @@ -767,7 +767,8 @@ describes.realWin( expect(elements).to.deep.equals([child, child2]); // Check that non-experiment version works - toggleExperiment(win, 'visibility-trigger-improvements', false); + /* toggleExperiment(win, 'visibility-trigger-improvements', false) // launched: true */ + false; expect( await root.getElements(body, '.notMyClass', null) ).to.deep.equals([child3]); @@ -829,7 +830,8 @@ describes.realWin( }); it('should find non AMP element with single selector', async () => { - toggleExperiment(win, 'visibility-trigger-improvements', false); + /* toggleExperiment(win, 'visibility-trigger-improvements', false) // launched: true */ + false; child.classList.remove('i-amphtml-element'); expect(await root.getElements(body, '.myClass', null)).to.deep.equal([ child, diff --git a/extensions/amp-analytics/0.1/test/test-events.js b/extensions/amp-analytics/0.1/test/test-events.js index 1c7d87bf8063..d38d55ec0cde 100644 --- a/extensions/amp-analytics/0.1/test/test-events.js +++ b/extensions/amp-analytics/0.1/test/test-events.js @@ -32,7 +32,6 @@ import {AmpdocAnalyticsRoot} from '../analytics-root'; import {Deferred} from '../../../../src/utils/promise'; import {Signals} from '../../../../src/utils/signals'; import {macroTask} from '../../../../testing/yield'; -import {toggleExperiment} from '../../../../src/experiments'; describes.realWin('Events', {amp: 1}, (env) => { let win; @@ -2001,7 +2000,6 @@ describes.realWin('Events', {amp: 1}, (env) => { let target2; beforeEach(() => { - toggleExperiment(win, 'visibility-trigger-improvements', true); readyPromise = Promise.resolve(); unlisten = env.sandbox.spy(); unlisten2 = env.sandbox.spy(); @@ -2045,7 +2043,8 @@ describes.realWin('Events', {amp: 1}, (env) => { }); } - toggleExperiment(win, 'visibility-trigger-improvements', false); + /* toggleExperiment(win, 'visibility-trigger-improvements', false) // launched: true */ + false; }); it('should fire event per selector', async () => { diff --git a/extensions/amp-consent/0.1/amp-consent.js b/extensions/amp-consent/0.1/amp-consent.js index 20fd4a739b31..7a5d9e81b9ab 100644 --- a/extensions/amp-consent/0.1/amp-consent.js +++ b/extensions/amp-consent/0.1/amp-consent.js @@ -50,7 +50,6 @@ import {dict, hasOwn} from '../../../src/utils/object'; import {getData} from '../../../src/event-helper'; import {getServicePromiseForDoc} from '../../../src/service'; import {isArray, isEnumValue, isObject} from '../../../src/types'; -import {isExperimentOn} from '../../../src/experiments'; import {toggle} from '../../../src/style'; const CONSENT_STATE_MANAGER = 'consentStateManager'; @@ -122,16 +121,20 @@ export class AmpConsent extends AMP.BaseElement { this.matchedGeoGroup_ = null; /** @private {?boolean} */ - this.isTcfPostMessageProxyExperimentOn_ = isExperimentOn( + this.isTcfPostMessageProxyExperimentOn_ = + /* isExperimentOn( this.win, 'tcf-post-message-proxy-api' - ); + ) // launched: true */ + true; /** @private {?boolean} */ - this.isGranularConsentExperimentOn_ = isExperimentOn( + this.isGranularConsentExperimentOn_ = + /* isExperimentOn( this.win, 'amp-consent-granular-consent' - ); + ) // launched: true */ + true; /** @private {?Promise} */ this.purposeConsentRequired_ = this.isGranularConsentExperimentOn_ diff --git a/extensions/amp-consent/0.1/consent-ui.js b/extensions/amp-consent/0.1/consent-ui.js index 60fc7d7795b9..326e5d8c64c0 100644 --- a/extensions/amp-consent/0.1/consent-ui.js +++ b/extensions/amp-consent/0.1/consent-ui.js @@ -32,7 +32,6 @@ import {getConsentStateValue} from './consent-info'; import {getData} from '../../../src/event-helper'; import {getServicePromiseForDoc} from '../../../src/service'; import {htmlFor} from '../../../src/static-template'; -import {isExperimentOn} from '../../../src/experiments'; import {setImportantStyles, setStyles, toggle} from '../../../src/style'; const TAG = 'amp-consent-ui'; @@ -183,10 +182,12 @@ export class ConsentUI { /** @private {?Promise} */ this.promptUISrcPromise_ = null; - this.isGranularConsentExperimentOn_ = isExperimentOn( + this.isGranularConsentExperimentOn_ = + /* isExperimentOn( this.win_, 'amp-consent-granular-consent' - ); + ) // launched: true */ + true; this.init_(config, opt_postPromptUI); } diff --git a/extensions/amp-consent/0.1/test/test-amp-consent.js b/extensions/amp-consent/0.1/test/test-amp-consent.js index c15b817ee46d..e62daa3dc03c 100644 --- a/extensions/amp-consent/0.1/test/test-amp-consent.js +++ b/extensions/amp-consent/0.1/test/test-amp-consent.js @@ -35,7 +35,6 @@ import { resetServiceForTesting, } from '../../../../src/service'; import {removeSearch} from '../../../../src/url'; -import {toggleExperiment} from '../../../../src/experiments'; import {xhrServiceForTesting} from '../../../../src/service/xhr-impl'; describes.realWin( @@ -512,7 +511,6 @@ describes.realWin( }); it('updates local storage and uses those values (granular consent on)', async () => { - toggleExperiment(win, 'amp-consent-granular-consent', true); const inlineConfig = { 'consentInstanceId': 'abc', 'consentRequired': 'remote', @@ -544,7 +542,8 @@ describes.realWin( 'xyz': PURPOSE_CONSENT_STATE.REJECTED, }, }); - toggleExperiment(win, 'amp-consent-granular-consent', false); + /* toggleExperiment(win, 'amp-consent-granular-consent', false) // launched: true */ + false; }); it('accepts unknown as a response', async () => { @@ -651,7 +650,6 @@ describes.realWin( }); it('syncs purposeConsents from server', async () => { - toggleExperiment(win, 'amp-consent-granular-consent', true); const inlineConfig = { 'consentInstanceId': 'abc', 'consentRequired': true, @@ -686,7 +684,8 @@ describes.realWin( {'xyz': PURPOSE_CONSENT_STATE.REJECTED} ) ); - toggleExperiment(win, 'amp-consent-granular-consent', false); + /* toggleExperiment(win, 'amp-consent-granular-consent', false) // launched: true */ + false; }); it('syncs metadata from server', async () => { @@ -762,7 +761,6 @@ describes.realWin( }); it('should validate purpose consents before syncing', async () => { - toggleExperiment(win, 'amp-consent-granular-consent', true); const inlineConfig = { 'consentInstanceId': 'abc', 'consentRequired': true, @@ -777,7 +775,8 @@ describes.realWin( await macroTask(); expect(validationSpy).to.be.calledOnce; expect(validationSpy).to.be.calledWith({'xyz': false}); - toggleExperiment(win, 'amp-consent-granular-consent', false); + /* toggleExperiment(win, 'amp-consent-granular-consent', false) // launched: true */ + false; }); it('should not sync data if response is null', async () => { @@ -996,12 +995,11 @@ describes.realWin( let ampConsent; let consentElement; - beforeEach(() => { - toggleExperiment(win, 'tcf-post-message-proxy-api', true); - }); + beforeEach(() => {}); afterEach(() => { - toggleExperiment(win, 'tcf-post-message-proxy-api', false); + /* toggleExperiment(win, 'tcf-post-message-proxy-api', false) // launched: true */ + false; }); describe('config', () => { @@ -1222,11 +1220,11 @@ describes.realWin( 'purpose-bar': false, }, }; - toggleExperiment(win, 'amp-consent-granular-consent', true); }); afterEach(() => { - toggleExperiment(win, 'amp-consent-granular-consent', false); + /* toggleExperiment(win, 'amp-consent-granular-consent', false) // launched: true */ + false; }); it('handles purposeConsentMap w/ accept', () => { @@ -1569,7 +1567,6 @@ describes.realWin( let consentElement; beforeEach(() => { - toggleExperiment(win, 'amp-consent-granular-consent', true); jsonMockResponses = { 'https://server-test-1/': '{"consentRequired": true, "purposeConsentRequired": ["abc", "bcd"]}', @@ -1583,7 +1580,8 @@ describes.realWin( }); afterEach(() => { - toggleExperiment(win, 'amp-consent-granular-consent', false); + /* toggleExperiment(win, 'amp-consent-granular-consent', false) // launched: true */ + false; }); describe('purposeConsentRequired', () => { diff --git a/extensions/amp-consent/0.1/test/test-consent-ui.js b/extensions/amp-consent/0.1/test/test-consent-ui.js index bcb3ec2779ac..2143d7ddc699 100644 --- a/extensions/amp-consent/0.1/test/test-consent-ui.js +++ b/extensions/amp-consent/0.1/test/test-consent-ui.js @@ -31,7 +31,6 @@ import { registerServiceBuilder, resetServiceForTesting, } from '../../../../src/service'; -import {toggleExperiment} from '../../../../src/experiments'; import {user} from '../../../../src/log'; import {whenCalled} from '../../../../testing/test-helper.js'; @@ -377,7 +376,6 @@ describes.realWin( // TODO(micajuineho): consolidate w/ test above after exp done it('should pass purpose consents to the iframe', async () => { - toggleExperiment(win, 'amp-consent-granular-consent', true); const config = dict({ 'promptUISrc': 'https://promptUISrc', 'clientConfig': { @@ -405,7 +403,8 @@ describes.realWin( 'purposeConsents': {'abc': 1}, }) ); - toggleExperiment(win, 'amp-consent-granular-consent', false); + /* toggleExperiment(win, 'amp-consent-granular-consent', false) // launched: true */ + false; }); it('should pass the promptTrigger reason to the iframe', function* () { diff --git a/src/custom-element.js b/src/custom-element.js index 797376946daa..52cbdfa1d614 100644 --- a/src/custom-element.js +++ b/src/custom-element.js @@ -41,7 +41,6 @@ import {dev, devAssert, rethrowAsync, user, userAssert} from './log'; import {getIntersectionChangeEntry} from './utils/intersection-observer-3p-host'; import {getMode} from './mode'; import {getSchedulerForDoc} from './service/scheduler'; -import {isExperimentOn} from './experiments'; import {setStyle} from './style'; import {shouldBlockOnConsentByMeta} from './consent'; import {startupChunk} from './chunk'; @@ -499,10 +498,12 @@ function createBaseCustomElementClass(win, elementConnectedCallback) { // Wait for consent. const consentPromise = implPromise.then(() => { const policyId = this.getConsentPolicy_(); - const isGranularConsentExperimentOn = isExperimentOn( + const isGranularConsentExperimentOn = + /* isExperimentOn( win, 'amp-consent-granular-consent' - ); + ) // launched: true */ + true; const purposeConsents = isGranularConsentExperimentOn && !policyId ? this.getPurposesConsent_() diff --git a/src/service/cid-impl.js b/src/service/cid-impl.js index d349f4b65805..a57736c729c4 100644 --- a/src/service/cid-impl.js +++ b/src/service/cid-impl.js @@ -33,7 +33,6 @@ import {getCookie, setCookie} from '../cookies'; import {getCryptoRandomBytesArray} from '../utils/bytes'; import {getServiceForDoc, registerServiceBuilderForDoc} from '../service'; import {getSourceOrigin, isProxyOrigin, parseUrlDeprecated} from '../url'; -import {isExperimentOn} from '../../src/experiments'; import {isIframed} from '../dom'; import {parseJson, tryParseJson} from '../json'; import {tryResolve} from '../utils/promise'; @@ -181,7 +180,9 @@ class Cid { this.apiKeyMap_ = null; /** @const {boolean} */ - this.isBackupCidExpOn = isExperimentOn(this.ampdoc.win, 'amp-cid-backup'); + this.isBackupCidExpOn = + /* isExperimentOn(this.ampdoc.win, 'amp-cid-backup') // launched: true */ + true; } /** @override */ diff --git a/test/unit/test-custom-element.js b/test/unit/test-custom-element.js index 0de94fd31303..1a2040ae46d3 100644 --- a/test/unit/test-custom-element.js +++ b/test/unit/test-custom-element.js @@ -28,7 +28,6 @@ import { getImplSyncForTesting, } from '../../src/custom-element'; import {elementConnectedCallback} from '../../src/service/custom-element-registry'; -import {toggleExperiment} from '../../src/experiments'; describes.realWin('CustomElement', {amp: true}, (env) => { // TODO(dvoytenko, #11827): Make this test work on Safari. @@ -706,12 +705,11 @@ describes.realWin('CustomElement', {amp: true}, (env) => { }); describe('granular consent experiment', () => { - beforeEach(() => { - toggleExperiment(win, 'amp-consent-granular-consent', true); - }); + beforeEach(() => {}); afterEach(() => { - toggleExperiment(win, 'amp-consent-granular-consent', false); + /* toggleExperiment(win, 'amp-consent-granular-consent', false) // launched: true */ + false; }); it('should find the correct purposes', () => { diff --git a/tools/experiments/experiments-config.js b/tools/experiments/experiments-config.js index 3ae95cc6f1a0..79d29d75e7ae 100644 --- a/tools/experiments/experiments-config.js +++ b/tools/experiments/experiments-config.js @@ -153,67 +153,32 @@ export const EXPERIMENTS = [ spec: 'N/A', cleanupIssue: 'N/A', }, - { - id: 'adsense-ad-size-optimization', - name: - 'Per publisher server side settings for changing the ad size ' + - 'to responsive.', - spec: 'https://github.com/ampproject/amphtml/issues/23568', - cleanupIssue: 'https://github.com/ampproject/amphtml/issues/24165', - }, { id: 'amp-stream-gallery', name: 'Enables component', spec: 'https://github.com/ampproject/amphtml/issues/20595', cleanupIssue: 'https://github.com/ampproject/amphtml/issues/26709', }, - { - id: 'visibility-trigger-improvements', - name: 'AMP Analytics Visibility Trigger Improvements', - spec: 'https://github.com/ampproject/amphtml/issues/26823', - cleanupIssue: 'https://github.com/ampproject/amphtml/issues/26823', - }, { id: 'a4a-no-signing', name: 'Remove signing requirement for AMPHTML ads', spec: 'https://github.com/ampproject/amphtml/issues/27189', }, - { - id: 'expand-json-targeting', - name: 'Allow CLIENT_ID in doubleclick json targeting feature', - spec: 'https://github.com/ampproject/amphtml/issues/25190', - }, { id: 'auto-ads-layout-callback', name: 'Move ads placement into layoutCallback', spec: 'https://github.com/ampproject/amphtml/issues/27068', }, - { - id: 'amp-cid-backup', - name: 'Backup AMP-generated CIDs to Storage.', - spec: 'https://github.com/ampproject/amphtml/issues/29484', - cleanupIssue: 'https://github.com/ampproject/amphtml/issues/29484', - }, { id: 'layout-aspect-ratio-css', name: 'Responsive layouts implemented via aspect-ratio CSS', spec: 'https://github.com/ampproject/amphtml/issues/30291', }, - { - id: 'tcf-post-message-proxy-api', - name: 'Proxy for TCF PostMessageAPI to send TCData to 3p iframes', - spec: 'https://github.com/ampproject/amphtml/issues/30385', - }, { id: 'dfp-render-on-idle-cwv-exp', name: 'To measure the CWV impact of ads idle rendering', spec: 'https://github.com/ampproject/amphtml/issues/31436', }, - { - id: 'amp-consent-granular-consent', - name: 'Client-side granular consent', - spec: 'https://github.com/ampproject/amphtml/issues/31607', - }, { id: 'amp-story-page-attachment-ui-v2', name: 'New UI for all new page attachments in stories format',