支持/反对属性文件中重复键的参数
我在 QA 部门工作,作为工作的一部分,我经常查看开发人员准备的配置文件。有时,我看到随着配置文件的继续,特定的键被重新定义
A = 12
...
A = 34
对我来说,这看起来是一个非常糟糕的做法。归根结底,尚不清楚 A
等于什么,并且由于程序逻辑是隐藏的,因此不清楚应用程序是否正确处理了这种情况,或者,也许有一个非常好的方法事情这样做的原因。
另外,我有时会发现
A = 12
...
A = puppies
分配给该键的含义似乎非常模糊。开发人员是否正在构建 A
可能等于的变体?第一个 A
是拼写错误吗?许多问题仍然存在..
我想知道...开发人员是否有充分的理由配置他们的应用程序来重新定义键(包括重复的键),或者..我的质疑是否正确?
注意:该应用程序可以很好地处理重复的键,但是它是如何处理的,它似乎可以工作
I work in a QA department and, as part of my job, often times look at the configuration files prepared by our developers. On occasion, i see that particular keys are redefined as configuration file goes on
A = 12
...
A = 34
To me this looks like a very bad practice. At the end of the day, it is not clear what A
is equal to and since program logic is hidden, it is not clear whether application is handling this case properly, or, perhaps there is a very good reason why things are done this way.
Additionally, from time to time, i see
A = 12
...
A = puppies
The meaning assigned to the key seems to be very ambiguous. Is developer building variations of what A
may be equal to? Is first A
a typo? Many questions remain ..
I wonder ... Is there ever a good reason why developers would configure their apps to redefine Keys (include duplicate keys), or .. am i correct to question this?
NB: The application works fine with the duplicate keys, however it is handled, it appears to work
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
在与几位拥有数十年经验的开发人员交谈后,我的问题的答案是响亮的“不”。配置文件没有充分的理由包含重复的键。
After speaking with several developers with decades of experience, the answer to my question is a resounding "NO". There is no good reason for a configuration file to contain duplicate keys.