rethinkdb / horizon

Horizon is a realtime, open-source backend for JavaScript apps.
MIT License
6.78k stars 349 forks source link

Error: Operation not permitted. #876

Closed bodekbeska closed 7 years ago

bodekbeska commented 7 years ago

Server version: 2.0 Client version: running angular 2

import { Injectable } from '@angular/core'; const Horizon = require('@horizon/client'); @Injectable() export class HorizonService { table = Horizon({host: 'ip_address_here:8181'}); constructor() { } }

This is what show in the debug scren

? Horizon ready for connections debug: Client connection established. debug: Received handshake: {"request_id":0,"method":"unauthenticated"} debug: Sending response: {"token":"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzUxMiJ9.eyJpZCI6 bnVsbCwicHJvdmlkZXIiOiJ1bmF1dGhlbnRpY2F0ZWQiLCJpYXQiOjE0OTA3MjI1NzQsImV4cCI6MTQ5 MDgwODk3NH0.DXxD-juAEojfvAyi8dONVn74dpvWD6SAmM_BmpJ7JxE_d3AhKc6mESGDB6Uhn7LBZ87l nc_qvtuNx-iKtLW5bA","id":null,"provider":"unauthenticated","request_id":0} debug: Received request from client: {"request_id":1,"type":"subscribe","options ":{"collection":"surveys"}} debug: Error on request 1: Error: Operation not permitted. at Request.run (C:\Users\z383205a\AppData\Roaming\npm\node_modules\horizon\n ode_modules\@horizon\server\src\request.js:40:15) at Client.handle_request (C:\Users\z383205a\AppData\Roaming\npm\node_modules \horizon\node_modules\@horizon\server\src\client.js:161:13) at error_wrap_socket (C:\Users\z383205a\AppData\Roaming\npm\node_modules\hor izon\node_modules\@horizon\server\src\client.js:107:47) at Client.error_wrap_socket (C:\Users\z383205a\AppData\Roaming\npm\node_modu les\horizon\node_modules\@horizon\server\src\client.js:50:7) at WebSocket._socket.on (C:\Users\z383205a\AppData\Roaming\npm\node_modules\ horizon\node_modules\@horizon\server\src\client.js:107:18) at emitTwo (events.js:106:13) at WebSocket.emit (events.js:191:7) at Receiver.ontext (C:\Users\z383205a\AppData\Roaming\npm\node_modules\horiz on\node_modules\ws\lib\WebSocket.js:841:10) at C:\Users\z383205a\AppData\Roaming\npm\node_modules\horizon\node_modules\w s\lib\Receiver.js:536:18 at C:\Users\z383205a\AppData\Roaming\npm\node_modules\horizon\node_modules\w s\lib\Receiver.js:368:7 at C:\Users\z383205a\AppData\Roaming\npm\node_modules\horizon\node_modules\w s\lib\PerMessageDeflate.js:249:5 at afterWrite (_stream_writable.js:388:3) at onwrite (_stream_writable.js:379:7) at WritableState.onwrite (_stream_writable.js:90:5) at afterTransform (_stream_transform.js:79:3) at TransformState.afterTransform (_stream_transform.js:54:12) at Zlib.callback (zlib.js:639:5) debug: Handling error: Operation not permitted. debug: Sending error result for request 1: Error: Operation not permitted. at Request.run (C:\Users\z383205a\AppData\Roaming\npm\node_modules\horizon\n ode_modules\@horizon\server\src\request.js:40:15) at Client.handle_request (C:\Users\z383205a\AppData\Roaming\npm\node_modules \horizon\node_modules\@horizon\server\src\client.js:161:13) at error_wrap_socket (C:\Users\z383205a\AppData\Roaming\npm\node_modules\hor izon\node_modules\@horizon\server\src\client.js:107:47) at Client.error_wrap_socket (C:\Users\z383205a\AppData\Roaming\npm\node_modu les\horizon\node_modules\@horizon\server\src\client.js:50:7) at WebSocket._socket.on (C:\Users\z383205a\AppData\Roaming\npm\node_modules\ horizon\node_modules\@horizon\server\src\client.js:107:18) at emitTwo (events.js:106:13) at WebSocket.emit (events.js:191:7) at Receiver.ontext (C:\Users\z383205a\AppData\Roaming\npm\node_modules\horiz on\node_modules\ws\lib\WebSocket.js:841:10) at C:\Users\z383205a\AppData\Roaming\npm\node_modules\horizon\node_modules\w s\lib\Receiver.js:536:18 at C:\Users\z383205a\AppData\Roaming\npm\node_modules\horizon\node_modules\w s\lib\Receiver.js:368:7 at C:\Users\z383205a\AppData\Roaming\npm\node_modules\horizon\node_modules\w s\lib\PerMessageDeflate.js:249:5 at afterWrite (_stream_writable.js:388:3) at onwrite (_stream_writable.js:379:7) at WritableState.onwrite (_stream_writable.js:90:5) at afterTransform (_stream_transform.js:79:3) at TransformState.afterTransform (_stream_transform.js:54:12) at Zlib.callback (zlib.js:639:5) debug: Sending response: {"error":"Operation not permitted.","error_code":-1,"re quest_id":1} debug: Received request from client: {"request_id":1,"type":"end_subscription"}

Not sure if it's bug or I am doing something wrong in my set up? It works fine when i run --dev

bodekbeska commented 7 years ago

I did some more googling. Found out new property that was not in the original conf.toml document. addedd permission=false and it worked. apologies.

ForsakenHarmony commented 7 years ago

close this?

bodekbeska commented 7 years ago

Yes pls

On Mar 29, 2017 6:15 PM, "Ashley" notifications@github.com wrote:

close this?

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/rethinkdb/horizon/issues/876#issuecomment-290273157, or mute the thread https://github.com/notifications/unsubscribe-auth/AGJIXh2rHzrxy-oZk4o_uEj_td87mcxEks5rqwJDgaJpZM4Mr-MY .

ForsakenHarmony commented 7 years ago

you can close it, not me