Hacktoberfest 2026:维护者为十月标记出来的 issue,仍然开放、适合新手。 浏览 Hacktoberfest issue

Filter.or over a missing field breaks the whole query silently

未关闭
#2,952 2 条评论 0 个 reaction 已指派 1 人 在 GitHub 查看

维护者通常 1 天内回复

@dconeybe 已经在做这个了。

开始于 2025年11月4日。

评估

这个 Issue 还没有评估数据。

描述

api: firestore
[REQUIRED] Step 2: Describe your environment

Live.
It works in the emulator.

[REQUIRED] Step 3: Describe the problem
Steps to reproduce:

If one or more of the filters inside a Filter.or queries a non-existent property, then the whole Filter.or returns false, returning no results, even if the other filters (e.g. Age in the example below) do match.
No errors or warnings are raised, the query "fails" silently.

Relevant Code:
	let snap = await firestore.collection('MyThing').where(
		Filter.or(
			Filter.where('age', '>=', 18),
			Filter.where('nonExistentProperty', '>=', 123),
		)
	).get()

I get the limitations on querying non-existent fields, but the whole thing shouldn't fail silently.

Either the other filters should still work, or there should be an error raised.

This doesn't occurr on the emulator, so was only a prod issue that it just took me several hours to track down.

At least make the emulator mirror live!

主要语言
TypeScript
星标
1.7k
派生
419
平均合并
4 天 20 小时
30 天内合并 PR
16

环境准备

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

firebase/firebase-admin-node 的其他 Issue

查看 firebase/firebase-admin-node 的全部 Issue

相似的 Issue

更多 TypeScript Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。