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

Error parsing event details cpu_percentage #78

Closed
ghost opened this issue Apr 27, 2020 · 1 comment · Fixed by #92
Closed

Error parsing event details cpu_percentage #78

ghost opened this issue Apr 27, 2020 · 1 comment · Fixed by #92
Labels
bug Something isn't working

Comments

@ghost
Copy link

ghost commented Apr 27, 2020

The cpu_percentage field inside the entity_map looks like a float32
instead of an int32, the error shown on some events is:

ERROR unable to get event details: json: cannot unmarshal number 0.02 into Go struct field eventProcessEntity.data.entity_map.process.cpu_percentage of type int32
@ghost ghost added the bug Something isn't working label Apr 27, 2020
@ghost ghost self-assigned this May 4, 2020
ghost pushed a commit that referenced this issue May 4, 2020
The `cpu_percentage` field inside the `entity_map` is a `float32`
not `int32`, this commit is fixing the following error:
```
ERROR unable to get event details: json: cannot unmarshal number 0.02 into Go struct field eventProcessEntity.data.entity_map.process.cpu_percentage of type int32
```

Closes #78

Signed-off-by: Salim Afiune Maya <afiune@lacework.net>
ghost pushed a commit that referenced this issue May 4, 2020
The `cpu_percentage` field inside the `entity_map` is a `float32`
not `int32`, this commit is fixing the following error:
```
ERROR unable to get event details: json: cannot unmarshal number 0.02 into Go struct field eventProcessEntity.data.entity_map.process.cpu_percentage of type int32
```

Closes #78

Signed-off-by: Salim Afiune Maya <afiune@lacework.net>
@scottford-lw
Copy link
Contributor

@afiunelw I am testing this branch out with the event Brian mentioned and I am still getting an error...

~/src/go-sdk(master*) » git fetch origin                                                                                                                                                                                                            scottford@scott-fords-mbp
git checkout afiune/bug-fix/78
git merge --ff-only @{upstream}

Branch 'afiune/bug-fix/78' set up to track remote branch 'afiune/bug-fix/78' from 'origin'.
Switched to a new branch 'afiune/bug-fix/78'
Already up to date.
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
~/src/go-sdk(afiune/bug-fix/78*) » lacework event show 33723 -p customerdemo                                                                                                                                                                        scottford@scott-fords-mbp
Usage:
  lacework event show <event_id> [flags]

Flags:
  -h, --help   help for show

Global Flags:
  -a, --account string      account subdomain of URL (i.e. <ACCOUNT>.lacework.net)
  -k, --api_key string      access key id
  -s, --api_secret string   secret access key
      --debug               turn on debug logging
      --json                switch commands output from human-readable to json format
      --nocolor             turn off colors
      --noninteractive      disable interactive progress bars (i.e. 'spinners')
  -p, --profile string      switch between profiles configured at ~/.lacework.toml

ERROR unable to get event details: json: cannot unmarshal number 0.01 into Go struct field eventProcessEntity.data.entity_map.process.cpu_percentage of type int32

@ghost ghost closed this as completed in #92 May 4, 2020
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant