# Newbie problems with wdm errors

**URL:** <https://talk.jekyllrb.com/t/newbie-problems-with-wdm-errors/9233>\
**Category:** Help\
**Created:** [June 6, 2024, 2:47am UTC](https://talk.jekyllrb.com/t/newbie-problems-with-wdm-errors/9233 "2024-06-06T02:47:00Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![axfreeman](https://avatars.discourse-cdn.com/v4/letter/a/8797f3/32.png) [@axfreeman](https://talk.jekyllrb.com/u/axfreeman)\
**Post date:** [June 6, 2024, 2:47am UTC](https://talk.jekyllrb.com/t/newbie-problems-with-wdm-errors/9233/1 "2024-06-06T02:47:00Z")

</div>

Hi folks.

I am new to Ruby and Jekyll but generally tech savvy.  
Im running Windows 11.

Trying to create a new Jekyll site. I followed all the steps in the docs (some problems accessing Jekyll, resolved by editing Windows path and rebooting)

In VSCODE, I ran

```
gem install jekyll bundler

```

which ran with no faults.

I then tried to create a new jekyll site with

```
jekyll new mysite

```

(In VSCODE also but see below)

This reported the error `error occurred while installing wdm (0.1.1), and Bundler cannot continue`  
I’ve looked at various solutions to this - since I am new to Ruby I haven’t gone into any of its internals.

I then ran

```
 bundle install

```

This reported `Gem::Ext::BuildError: ERROR: Failed to build gem native extension.` with quite extensive diagnostics

I then ran

```
gem install wdm

```

This gave the same diagnostics. At the end it states

```
Gem files will remain installed in C:/Users/afree/.local/share/gem/ruby/3.3.0/gems/wdm-0.1.1 for inspection.  
Results logged to C:/Users/afree/.local/share/gem/ruby/3.3.0/extensions/x64-mingw-ucrt/3.3.0/wdm-0.1.1/gem_make.out

```

I’ve gone through most of these steps also outside VScode, in both cmd and powershell

This must be a common problem, though I haven’t yet found previous answers to it. Probably something trivial but I’m stuck, and if I am, others must be also.

All suggestions welcome.

---

<div class="post-metadata">

**Author:** ![rdyar](https://yyz2.discourse-cdn.com/flex030/user_avatar/talk.jekyllrb.com/rdyar/32/710_2.png) [@rdyar](https://talk.jekyllrb.com/u/rdyar)\
**Post date:** [June 6, 2024, 4:06am UTC](https://talk.jekyllrb.com/t/newbie-problems-with-wdm-errors/9233/2 "2024-06-06T04:06:39Z")

</div>

> [@axfreeman](#):
>
> ERROR: Failed to build gem native extension

usually this is cause you don’t have the ruby dev tools installed - when you installed ruby you probably did the one without the dev kit. Try uninstalling it and re-installing it with the devkit.

---

<div class="post-metadata">

**Author:** ![axfreeman](https://avatars.discourse-cdn.com/v4/letter/a/8797f3/32.png) [@axfreeman](https://talk.jekyllrb.com/u/axfreeman)\
**Post date:** [June 6, 2024, 10:36am UTC](https://talk.jekyllrb.com/t/newbie-problems-with-wdm-errors/9233/3 "2024-06-06T10:36:43Z")

</div>

@rydar: yes, I saw that this could be a problem. I went through a number of attempts to fix the installation but I’ll try again. If I remember right, I didn’t do an uninstall first, just re-installed. But I answered the install questions differently. I will try a complete uninstall, reinstall, reboot and take note of the options I used…

---

<div class="post-metadata">

**Author:** ![axfreeman](https://avatars.discourse-cdn.com/v4/letter/a/8797f3/32.png) [@axfreeman](https://talk.jekyllrb.com/u/axfreeman)\
**Post date:** [June 6, 2024, 11:29am UTC](https://talk.jekyllrb.com/t/newbie-problems-with-wdm-errors/9233/4 "2024-06-06T11:29:28Z")

</div>

Here is the solution, discovered by trial and error.

In the file called ‘gemfile’ in the jekyll directory, there is the following line:

```
gem "wdm", "~> 0.1.1", :platforms => [:mingw, :x64_mingw, :mswin]

```

Removing this line removes the problem

So it’s to do with the WDM ‘watch’ service. But this is inessential, so it functions without it.

The docs suggest substituting a slightly different line which I think is intended to do the same thing. It doesn’t work either.

Should I perhaps raise a query about the fact that WDM doesn’t function?

---

<div class="post-metadata">

**Author:** ![turbolego](https://yyz2.discourse-cdn.com/flex030/user_avatar/talk.jekyllrb.com/turbolego/32/6004_2.png) [@turbolego](https://talk.jekyllrb.com/u/turbolego)\
**Post date:** [July 13, 2024, 6:09am UTC](https://talk.jekyllrb.com/t/newbie-problems-with-wdm-errors/9233/5 "2024-07-13T06:09:09Z")

</div>

Thanks! I had the same problem, and removing the line in the gemfile worked for me too.  
I used the guide on GitHub [(Creating a GitHub Pages site with Jekyll)](https://docs.github.com/en/pages/setting-up-a-github-pages-site-with-jekyll/creating-a-github-pages-site-with-jekyll) and i have never used Ruby before so everything was installed for the first time.

---

<div class="post-metadata">

**Author:** ![chezhian0599](https://yyz2.discourse-cdn.com/flex030/user_avatar/talk.jekyllrb.com/chezhian0599/32/6047_2.png) [@chezhian0599](https://talk.jekyllrb.com/u/chezhian0599)\
**Post date:** [August 12, 2024, 3:08pm UTC](https://talk.jekyllrb.com/t/newbie-problems-with-wdm-errors/9233/6 "2024-08-12T15:08:42Z")

</div>

Thank you for your solution. After struggling for a week, we finally made it.

---

<div class="post-metadata">

**Author:** ![a1fbg](https://yyz2.discourse-cdn.com/flex030/user_avatar/talk.jekyllrb.com/a1fbg/32/6064_2.png) [@a1fbg](https://talk.jekyllrb.com/u/a1fbg)\
**Post date:** [August 29, 2024, 5:40am UTC](https://talk.jekyllrb.com/t/newbie-problems-with-wdm-errors/9233/7 "2024-08-29T05:40:08Z")

</div>

Thank you for ending my 2 hour agony.

---

<div class="post-metadata">

**Author:** ![contsili](https://yyz2.discourse-cdn.com/flex030/user_avatar/talk.jekyllrb.com/contsili/32/6086_2.png) [@contsili](https://talk.jekyllrb.com/u/contsili)\
**Post date:** [September 24, 2024, 11:36am UTC](https://talk.jekyllrb.com/t/newbie-problems-with-wdm-errors/9233/8 "2024-09-24T11:36:09Z")

</div>

For me changing this line to: `gem "wdm", "~> 0.1", :platforms => [:mingw, :x64_mingw, :mswin]` worked.

---

<div class="post-metadata">

**Author:** ![alekszakharov](https://avatars.discourse-cdn.com/v4/letter/a/6bbea6/32.png) [@alekszakharov](https://talk.jekyllrb.com/u/alekszakharov)\
**Post date:** [October 1, 2024, 1:48pm UTC](https://talk.jekyllrb.com/t/newbie-problems-with-wdm-errors/9233/9 "2024-10-01T13:48:26Z")

</div>

try to replace the initial line with wdm dependency with

gem ‘wdm’, ‘\>= 0.1.0’ if Gem.win\_platform?

this worked for me 😉
