javascript - MongoDB Stitch 引发非用户错误

标签 javascript mongodb mongodb-stitch

我正在使用 mongodb 的缝合后端来运行应用程序,当我尝试以匿名用户身份登录时,它会抛出此错误:

failed to log in anonymously: { StitchError: authentication via 'anon-user' is unsupported
at /*****/*****/*****/****/node_modules/mongodb-stitch/dist/node/common.js:29:19
at
at process._tickCallback (internal/process/next_tick.js:160:7)
name: 'StitchError',
response:
Body {
url: '*****',
status: 401,
statusText: 'Unauthorized',
headers: Headers { _headers: [Object] },
ok: false,
body:
Gunzip {
_readableState: [ReadableState],
readable: false,
domain: null,
_events: [Object],
_eventsCount: 4,
_maxListeners: undefined,
_writableState: [WritableState],
writable: false,
allowHalfOpen: true,
_transformState: [Object],
bytesRead: 81,
_handle: null,
_hadError: false,
_writeState: [Uint32Array],
_outBuffer: ,
_outOffset: 57,
_level: -1,
_strategy: 0,
_chunkSize: 16384,
_flushFlag: 0,
_scheduledFlushFlag: 0,
_origFlushFlag: 0,
_finishFlushFlag: 4,
_info: undefined },
bodyUsed: true,
size: 0,
timeout: 0,
_raw:
[ ],
_abort: false,
_bytes: 57 },
json: { error: 'authentication via \'anon-user\' is unsupported' } }



标有 ***** 的项目因隐私原因被删除。

我在 Stitch 管理控制台中启用了匿名身份验证,但它仍然会引发此错误。在这种情况发生之前,我的应用程序甚至无法对数据库执行任何操作,所以我知道这与我的应用程序的 Rules 无关。 .

关于匿名身份验证有什么我不知道的吗?

如果您知道 mongodb 错误引用在哪里,那也会有所帮助。

谢谢

最佳答案



https://github.com/Spaceface16518/Converse/issues/22

"I think you have to deploy it in the deploy session"

关于javascript - MongoDB Stitch 引发非用户错误,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/49143526/

相关文章:

Javascript - 操纵硬币翻转(正面朝上)

java - 我们应该在 Java 中为 Mongodb 使用 OGM/ORM,就像 hibernate 一样吗?

javascript - 如何在html页面中显示php错误信息?

javascript - 小语法问题

javascript - 在 Angular 中使用 $http POST 时获取 mongo ObjectID

node.js - 如何修改 Mongoose 查询的输出?

javascript - mongodb stitch 返回所有字段

mongodb - StitchServiceError  "aws: "aws_service“是必需的字符串”,errorCodeName : InvalidParameter

javascript - MongoDB Stitch SDK 返回 "aggregation stage "$lookup“不支持”

javascript - 在每次 href 出现之前放置文本?