Skip to content

Use basic parsing to avoid IE dependency - #58

Merged
Derek (derekfreed) merged 1 commit into
microsoft:developfrom
jwittner:fix/parsingIEDependency
Feb 27, 2018
Merged

Use basic parsing to avoid IE dependency#58
Derek (derekfreed) merged 1 commit into
microsoft:developfrom
jwittner:fix/parsingIEDependency

Conversation

@jwittner

Copy link
Copy Markdown
Member

I was running into this error:

The response content cannot be parsed because the Internet Explorer engine is not available, or Internet Explorer’s first-launch configuration is not complete.

when running under the context of a DSC resource I'm developing that leverages this module. Using the basic parsing resolves that error by avoiding the dependency on IE entirely.

$webResult = Invoke-WebRequest $page
$prototypeLink = $webResult.Links | Select-Object -ExpandProperty href | Where-Object {
$webResult = Invoke-WebRequest $page -UseBasicParsing
$prototypeLink = $webResult.Links | Select-Object -ExpandProperty href -ErrorAction SilentlyContinue | Where-Object {

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

This is required because the new output doesn't always contain an href property, luckily those are links we want to ignore anyways.

@derekfreed
Derek (derekfreed) merged commit 256e22c into microsoft:develop Feb 27, 2018
@jwittner Josh Wittner (jwittner) mentioned this pull request Apr 2, 2018
26 tasks
@jwittner
Josh Wittner (jwittner) deleted the fix/parsingIEDependency branch September 25, 2019 17:00
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.

2 participants