Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Correct the version detection in erlang plugin #801

Merged
merged 1 commit into from
Apr 19, 2016
Merged

Correct the version detection in erlang plugin #801

merged 1 commit into from
Apr 19, 2016

Conversation

tas50
Copy link
Contributor

@tas50 tas50 commented Apr 15, 2016

We weren't correctly identifying the erlang version. Instead we were detecting the erts version.

Old result:

    "erlang": {
      "version": "7.3",
      "options": [
        "SMP",
        "ASYNC_THREADS",
        "HIPE"
      ],
      "emulator": "BEAM"
    },

New result

    "erlang": {
      "version": "18",
      "erts_version": "7.3",
      "nif_version": "2.10",
      "options": [
        "SMP",
        "ASYNC_THREADS",
        "HIPE"
      ],
      "emulator": "BEAM"
    },

We weren't correctly identifying the erlang version.  Instead we were detecting the erts version.

Old result:
```javascript
    "erlang": {
      "version": "7.3",
      "options": [
        "SMP",
        "ASYNC_THREADS",
        "HIPE"
      ],
      "emulator": "BEAM"
    },
```

New result
```javascript
    "erlang": {
      "version": "18",
      "erts_version": "7.3",
      "nif_version": "2.10",
      "options": [
        "SMP",
        "ASYNC_THREADS",
        "HIPE"
      ],
      "emulator": "BEAM"
    },
```
@tas50 tas50 changed the title Correct the version detection of erlang Correct the version detection in erlang plugin Apr 15, 2016
@tas50 tas50 added the Bug label Apr 15, 2016
@tas50
Copy link
Contributor Author

tas50 commented Apr 17, 2016

This is ready for review @chef/client-core @mcquin

@mcquin
Copy link
Contributor

mcquin commented Apr 18, 2016

Nice! 👍

@tas50 tas50 mentioned this pull request Apr 19, 2016
options = output[1]
options.gsub!(/(\(|\))/, "")
erlang[:options] = options.split(",")
erlang[:emulator] = output[2].gsub!(/(\(|\))/, "")
Copy link
Member

Choose a reason for hiding this comment

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

might consider using delete instead of gsub

@mwrock
Copy link
Member

mwrock commented Apr 19, 2016

I'm 👍 you can take my nit or leave it.

@tas50
Copy link
Contributor Author

tas50 commented Apr 19, 2016

I'll get that fixed up on my general plugin cleanup branch

@tas50 tas50 merged commit 508366c into master Apr 19, 2016
@tas50 tas50 deleted the erlang branch April 22, 2016 18:27
@thommay thommay added Type: Bug Does not work as expected. and removed Bug labels Jan 24, 2017
@chef chef locked and limited conversation to collaborators Nov 16, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Type: Bug Does not work as expected.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants