Chronograf: Can't delete role - Chronograf

Created on 18 Aug 2017  路  8Comments  路  Source: influxdata/chronograf

Hi, this is an error I get in the Influx Cloud Chronograf when I try to remove a role or modify it's permisisons:

From dev tools:

index.js:933 Uncaught (in promise) TypeError: Cannot read property 'message' of undefined
    at _callee16$ (webpack:///./src/admin/actions/index.js?:933:111)
    at tryCatch (webpack:///./~/regenerator-runtime/runtime.js?:64:40)
    at Generator.invoke [as _invoke] (webpack:///./~/regenerator-runtime/runtime.js?:355:22)
    at Generator.prototype.(anonymous function) [as next] (webpack:///./~/regenerator-runtime/runtime.js?:116:21)
    at step (webpack:///./~/babel-runtime/helpers/asyncToGenerator.js?:17:30)
    at eval (webpack:///./~/babel-runtime/helpers/asyncToGenerator.js?:28:13)
    at <anonymous>

image

Which means I can't delete some roles, or modify permissions on some other ones.

Any hints?

Thanks :)

kinbug penterprise readiness

All 8 comments

Roles also can't be assigned to users (through the admin->users tab), after selecting them and clicking "apply" and refreshing the page after that - user roles are not listed/assigned.

Thanks for this detailed report, @pootzko!

This is currently not reproducible. I suspect this might be related to #1948 @pootzko can you try again after it is fixed

Hi,

sorry for the late reply, just came back from holidays. I just tested this and I still can't remove the role. I'm not getting and console or api request errors, everything goes smooth but when I refresh the page, the roles I "deleted" are still there.

I've been sniffing out chronograf to influx-meta communications with a proxy. I also noticed this behavior.
2018/03/13 14:12:23 Chronograf 1.2.0~n201803070832 (git: ca9713ed1f8b5e179d457f02ad8c991ecd06bc8c)

I'm unable to remove users from roles in chronograf, however it works with curl.

curl -v -d '{"action":"remove-users","role":{"name":"test-role","users":["tucnak"]}}' http://admin:[email protected]:8091/role

To reproduce in the UI

  1. Open InfluxDBAdmin
  2. Click on Users tab
  3. Highlight a user
  4. In the roles drop down Uncheck an existing role
  5. Click Apply in the drop down control

A notification appears "Failed to update user: No fields to Update"
The Roles field holds the value 'none' for a couple of seconds and then the old role is returned.

Note that when removing a user from role in the role tab, the removal works. However, the InfluxDBAdmin page has to be reloaded manually in order for the change to appear in the UI.

Also - The post body from this control is.

{"action":"remove-permissions","role":{"name":"test-role","permissions":{"":null}}}

I was expecting something like the following to the /role endpoint.

{"action":"remove-users","role":{"name":"test-role","users":["tucnak"]}}

In any event it works. But the message is inconsistent. Is this by design?

thanks for the update @karel-rehor and @pootzko . I am able to reproduce this bug in the latest build so we will add this to the next sprint.

  • [ ] when removing a role from a user, chronograf should not error and the role should be removed

kapture 2018-03-14 at 10 54 18

love it!

Was this page helpful?
0 / 5 - 0 ratings

Related issues

mkarlesky picture mkarlesky  路  3Comments

benschweizer picture benschweizer  路  5Comments

krysjoseoctanio picture krysjoseoctanio  路  4Comments

coreprocess picture coreprocess  路  6Comments

dhasenan picture dhasenan  路  5Comments