On Wed, 8 Apr 2020 13:52:44 +0200 Ancor Gonzalez Sosa <ancor@suse.de> wrote:
On 2020-04-08 13:33, josef Reidinger wrote:
On Wed, 8 Apr 2020 10:46:17 +0200 Martin Vidner <mvidner@suse.cz> wrote:
On Fri, Apr 03, 2020 at 05:21:21PM +0200, josef Reidinger wrote:
On Fri, 3 Apr 2020 16:05:04 +0200 Martin Vidner <mvidner@suse.cz> wrote:
- It uses a namespace, xmlns="http://www.suse.com/1.0/yast2ns"
Can we set namespace if it is not defined in XML? What puzzle me the most about that format (not parser) now is not that xml is badly readable, but that it is very hard and error prone to write/modify it. And mandatory namespace is unnecessary from my POV. Can we simple assume this namespace if none is defined?
The quick answer is no. Just like with other programming languages, for throwaway scripts working without namespaces is fine but as soon as you start building anything bigger or longer lasting, namespaces are needed to resolve conflicts and organize things.
For me it looks like overengineering. Do we plan to have multiple namespaces
Just a warning note from someone who doesn't know the topic so well. The sentence "that is overengineering, we are never going to do X" always triggers my spider-sense.[*]
As much as we abuse of the term, it's in fact really hard to overengineer something. Having a piece of software that is not prepared for the future/present (because someone decided that X would never happen) is a WAY more common problem. And we usually cause by trying to avoid the almost-mythological overengineering.
Well, my goal is to use reasonable default as currently we have only one namespace. So if it is not defined, then our parser will use our namespace. And if we need in future more namespaces, then it should not be a problem as we use default one without namespaces and respect others. From UX ( and here user is user of XML so also autoyast users ) is better for me to allow to avoid namespace if there is just one and just use it. So I agree with you about closing for extension, I just think that this is not the case ( if I do not overlook something ). Josef
Cheers.
[*] Spider-sense: see experience.
-- To unsubscribe, e-mail: yast-devel+unsubscribe@opensuse.org To contact the owner, e-mail: yast-devel+owner@opensuse.org