From f97c344e3c2ab9adeaad1956f874c82d4582924a Mon Sep 17 00:00:00 2001 From: Alexander Marks Date: Fri, 18 Sep 2020 11:34:10 -0700 Subject: [PATCH] Add all browser config parameters to signature --- CHANGELOG.md | 6 +++++- src/browser.ts | 7 ++++++- 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 019d0788..840c3dae 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,7 +5,11 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](http://keepachangelog.com/) and this project adheres to [Semantic Versioning](http://semver.org/). - +## Unreleased + +- Fix bug where a unique browser would not be launched if the only difference + between browser configurations was `binary`, `addArguments`, + `removeArguments`, `cpuThrottlingRate` or `preferences`. ## [0.5.3] 2020-09-11 diff --git a/src/browser.ts b/src/browser.ts index ce2f559c..ff71cc3c 100644 --- a/src/browser.ts +++ b/src/browser.ts @@ -85,9 +85,14 @@ export function browserSignature(config: BrowserConfig): string { return JSON.stringify([ config.name, config.headless, - config.remoteUrl || '', + config.remoteUrl ?? '', config.windowSize.width, config.windowSize.height, + config.binary ?? '', + config.addArguments ?? [], + config.removeArguments ?? [], + config.cpuThrottlingRate ?? 1, + config.preferences ?? {}, ]); }