Foundation-emails: SetProcessDpiAwareness failed: "COM error 0x80070005

Created on 11 Feb 2017  路  17Comments  路  Source: foundation/foundation-emails

npm run build or gulp --production produces this error:

[13:01:06] Starting 'sass'...
SetProcessDpiAwareness failed: "COM error 0x80070005  (Unknown error 0x0ffffffff80070005)"
[13:01:07] 'sass' errored after 1.09 s
[13:01:07] Error in plugin 'gulp-uncss'
Message:
    SetProcessDpiAwareness failed: "COM error 0x80070005  (Unknown error 0x0ffffffff80070005)"

Details:
    domainEmitter: [object Object]
    domain: [object Object]
    domainThrown: false
[13:01:07] 'build' errored after 1.81 s

Here is the inky code:


---
subject: redacted
---

<container class="header">
  <container class="body-border">
    <row>
      <columns style="width:100%;" small="12" large="12">
        <div class="hr"></div>
        <div class="hr"></div>
      </columns>
    </row>
    <row>
      <columns small="9" large="9">
        <row>
          <columns small="12" large="12">
            <h1 class="title-text main_title" style="margin-top:5px;">redacted</h1>
          </columns>
        </row>
        <row>
          <columns small="12" large="12">
            <h2 class="title-text sub_heading" style="margin-bottom:15px;">Graphic Designer</h2>
          </columns>
        </row>
      </columns>
      <columns class="logo" align="right" small="3" large="3">
        <img src="redacted" alt="" title="" width="33" height="50" border="0" style="float:right;text-align:right;max-width:100%;outline:none;text-decoration:none;-ms-interpolation-mode:bicubic;image-rendering:optimizeQuality;">
      </columns>
    </row>
    <row style="max-width:410px;margin-bottom:10px;margin-top:5px;">
      <columns small="12" large="4">
        <menu class="menu-items">
          <item class="image_item" href="tel:redacted" style="float:left!important;margin:0!important;text-align:left!important;"><img src="redacted" alt="" title="" width="14" height="14" border="0" style="max-width:100%;outline:none;text-decoration:none;-ms-interpolation-mode:bicubic;image-rendering:optimizeQuality;"></item>
          <item href="redacted" style="float:left !important;">redacted</item>
        </menu>
      </columns>
      <columns small="12" large="4">
        <menu class="menu-items">
          <item class="image_item" href="redacted" style="float:left!important;margin:0!important;text-align:left!important;"><img src="redacted" alt="" title="" width="14" height="14" border="0" style="max-width:100%;outline:none;text-decoration:none;-ms-interpolation-mode:bicubic;image-rendering:optimizeQuality;"></item>
          <item href="redacted" style="float:left!important;margin:0!important;text-align:left!important;">jredacted</item>
        </menu>
      </columns>
      <columns small="12" large="4">
        <menu class="menu-items">
          <item class="image_item" href="redacted" style="float:left!important;margin:0!important;text-align:left!important;"><img src="redacted" alt="" title="" width="14" height="14" border="0" style="max-width:100%;outline:none;text-decoration:none;-ms-interpolation-mode:bicubic;image-rendering:optimizeQuality;"></item>
          <item href="redacted" style="float:left!important;margin:0!important;text-align:left!important;">redacted</item>
        </menu>
      </columns>
    </row>
    <row>
      <columns small="12" large="12">
        <p class="small_print" style="max-width:410px">This message, including any attachments, may contain privileged and confidential information intended only for the person(s) named. Any use, distribution, copying or disclosure by any other person is strictly prohibited. I do not accept any liability or responsibility for viruses and it is the recipient's responsibility to scan any attachments.</p>
      </columns>
    </row>
  </container>
</container>

bug

Most helpful comment

Ok another update.

in gulpfile.babel.js comment out this from the sass task:

// Compile Sass into CSS
function sass() {
  return gulp.src('src/assets/scss/app.scss')
    .pipe($.if(!PRODUCTION, $.sourcemaps.init()))
    .pipe($.sass({
      includePaths: ['node_modules/foundation-emails/scss']
    }).on('error', $.sass.logError))
    //.pipe($.if(PRODUCTION, $.uncss( ,    <--- this
    //  {
    //    html: ['dist/**/*.html']
    //  }))) <--- to this
    .pipe($.if(!PRODUCTION, $.sourcemaps.write()))
    .pipe(gulp.dest('dist/css'));
}

This will stop the un-css plugin from running, which is causing the problem.

This isn't an issue as you can read here: https://www.npmjs.com/package/gulp-uncss , all this plugin does is remove un-used CSS, so it's not critical.

This is a half 'fix'

All 17 comments

I got the same error((

How to solve it?

I am still trying to find a solution. Perhaps we can both try and provide more information for others to help.

My utility versioning information

$ gulp -v
[20:00:32] Requiring external module babel-register
[20:00:32] CLI version 1.2.2
[20:00:32] Local version 4.0.0-alpha.2
$ npm -v
2.15.9

I didnt realise I was using an alpha version of gulp perhaps it's worth rolling back to a stable release and testing.

[03:11:11] Requiring external module babel-register
[03:11:11] CLI version 1.2.2
[03:11:11] Local version 4.0.0-alpha.2

npm -v
4.2.0

3 days ago evrything was working absolutly correctly

How can i build project without this operation? I need to send project under 5 hours..

You could try rolling back your version of gulp, we both have an alpha version I suspect that's the issue.

Alternativley you can use the CSS version of Foundation, but you lose the convenience of having Inky.

http://foundation.zurb.com/emails/docs/css-guide.html

Did you try? How to roll it back?

evrything been working - how it possible? Gulp was updating automatically on alpha?

I tried rolling back to gulp 4.0 and gulp 3.9.1 but it's still broken.

3.9.1 is in-compatible as the series method is missing.

4.0 has the same SetProcessDpiAwareness failed error.

I'm stumped for now. I will try looking more later, I have to work on another project now.

Specifically the error is being thrown

Error in plugin 'gulp-uncss'

Yes, but it starting in sass process

`SetProcessDpiAwareness failed: "COM error 0x80070005 (Unknown error 0x0ffffffff80070005)"
[03:44:41] 'sass' errored after 1.39 s
[03:44:41] Error in plugin 'gulp-uncss'
Message:
SetProcessDpiAwareness failed: "COM error 0x80070005 (Unknown error 0x0ffffffff80070005)"

Details:
domainEmitter: [object Object]
domain: [object Object]
domainThrown: false
[03:44:41] 'build' errored after 1.78 s
[03:44:41] 'default' errored after 1.78 s`

I "solved" this broblem that way: http://foundation.zurb.com/emails/inliner.html

But, i want to know how to make "build" process correct again.

Have you managed to find a solution for this problem yet?

Using the manual in-liner is all well and good but it's a serious pain in the rear for the development process.

I have started an entirely new project and have the very same issue..

Ok another update.

in gulpfile.babel.js comment out this from the sass task:

// Compile Sass into CSS
function sass() {
  return gulp.src('src/assets/scss/app.scss')
    .pipe($.if(!PRODUCTION, $.sourcemaps.init()))
    .pipe($.sass({
      includePaths: ['node_modules/foundation-emails/scss']
    }).on('error', $.sass.logError))
    //.pipe($.if(PRODUCTION, $.uncss( ,    <--- this
    //  {
    //    html: ['dist/**/*.html']
    //  }))) <--- to this
    .pipe($.if(!PRODUCTION, $.sourcemaps.write()))
    .pipe(gulp.dest('dist/css'));
}

This will stop the un-css plugin from running, which is causing the problem.

This isn't an issue as you can read here: https://www.npmjs.com/package/gulp-uncss , all this plugin does is remove un-used CSS, so it's not critical.

This is a half 'fix'

Try npm rebuild node-sass.

This issue is quite old. I think this should be already resolved by newer dependencies.

Was this page helpful?
0 / 5 - 0 ratings