--
You received this message because you are subscribed to the Google Groups "infra-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to infra-dev+...@chromium.org.
To post to this group, send email to infr...@chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/infra-dev/CAEoffTCWtzu87MQoRJ5sYcPVX6P9iZArVLytu38pT1BDKJJnOA%40mail.gmail.com.
This was discussed before: https://groups.google.com/a/google.com/d/msg/chrome-infra/OJLcUVOSmUw/SHcSRLh3wiAJ (sorry, internal only). IIRC, last time we've decided to use proto3 text format, e.g. https://chromium.googlesource.com/chromium/src/+/master/infra/config/cq.cfg.
On Fri, Jan 13, 2017 at 3:26 AM Dirk Pranke <dpr...@chromium.org> wrote:
Hi all,Recently some people on the Blink team have wanted to move from .in config files to a more common, readable, and manageable config format. We discussed switching to JSON, PYthon Literal (.pyl) files, and YAML, but settled on JSON5.We use .pyl files in a few places in infra as well. I suggest we switch from PYL to JSON 5 as well.Advantages:- consistency w/ dev standards- IMO JSON5 is strictly more readable than PYL files- well-defined syntax- is at least something that people might've heard ofDisadvantages:- parser not built in to Python (there is a json5 library on PYPI -- that I wrote -- that we'd have to install or check in)- it's easy enough to define a subset of PYL as well (which I have also done)I don't think this is an urgent thing.I also don't want to confuse this with using protobufs. For situations where we need well-defined schemas, and where we can have generated parsing stubs, I tend to agree that we should use protobufs instead. But, I don't think we're at a point where we can justrequire protobufs for everything.What do others think? Is there a good argument for keeping .pyl files? Separately, there are a few places where we use .json files for configuration, which is terrible. If we can switch from PYL to JSON5, switching from .json to .json5 seems also easy enough, but that's a separate, follow-on discussion.-- Dirk
--
You received this message because you are subscribed to the Google Groups "infra-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to infra-dev+unsubscribe@chromium.org.
To post to this group, send email to infr...@chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/infra-dev/CAEoffTCWtzu87MQoRJ5sYcPVX6P9iZArVLytu38pT1BDKJJnOA%40mail.gmail.com.
To unsubscribe from this group and stop receiving emails from it, send an email to infra-dev+...@chromium.org.
To post to this group, send email to infr...@chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/infra-dev/CAEoffTCWtzu87MQoRJ5sYcPVX6P9iZArVLytu38pT1BDKJJnOA%40mail.gmail.com.
--Sergiy Byelozyorov | Software Engineer | ser...@google.comGoogle Germany GmbHErika-Mann-Strasse 3380636 MünchenAG Hamburg, HRB 86891 | Sitz der Gesellschaft: Hamburg | Geschäftsführer: Matthew Scott Sucherman, Paul Terence Manicle
--
You received this message because you are subscribed to the Google Groups "infra-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to infra-dev+...@chromium.org.
To post to this group, send email to infr...@chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/infra-dev/CAEoffTDZgdEA-W%3DPgFN4hV3MQYN3DseCkomDaadr1iiWisP9_w%40mail.gmail.com.
I think there were always two main arguments for .pyl files:1) They had better syntax than .json files (supported comments, trailing commas, etc)2) They had perfect language support in our main languageJSON5 does away with the first argument. The second, however, still stands. There are no standard, packaged, bug-free implementations of the JSON5 parser. Not to cast any disparagement on your implementation, but it's clearly not battle tested the way the python parser itself is, and it isn't deployed everywhere. To switch to JSON5, we'd need to make sure that the parser library is available everywhere, and while we've gotten a lot better at that, it's not non-trivial.
Basically, I agree with you on all points except one. JSON5 seems like the better solution for everything that we're currently using .pyl for. It's more standard, it's forwards-compatible, it satisfies our documentation and formatting needs. (I disagree that it is strictly more readable; the only real difference is that keys can be unquoted, unless they contain characters like '-', but that makes it less readable in my heavily-python-influenced opinion.)The point where I actually disagree is that switching would be worthwhile. I think we have a few parallel directions forward:1) New services that need configuration will be written in Go and configured with Protobufs2) Old services written in python and using .pyl should be rewritten in Go and configured with protobufs3) Old services written in python that won't be rewritten are probably not worth upgrading to JSON5 eitherI'd be totally fine with saying that any new configuration files should be .proto or .json5. I don't think there's a convincing argument for perpetuating our use of .pyl. I'm just not sure there's a convincing argument for expending effort on finding and changing current instances of .pyl either, since they have essentially 0 maintenance cost.
To unsubscribe from this group and stop receiving emails from it, send an email to infra-dev+unsubscribe@chromium.org.
To post to this group, send email to infr...@chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/infra-dev/CAEoffTCWtzu87MQoRJ5sYcPVX6P9iZArVLytu38pT1BDKJJnOA%40mail.gmail.com.
--Sergiy Byelozyorov | Software Engineer | ser...@google.comGoogle Germany GmbHErika-Mann-Strasse 3380636 MünchenAG Hamburg, HRB 86891 | Sitz der Gesellschaft: Hamburg | Geschäftsführer: Matthew Scott Sucherman, Paul Terence Manicle
--
You received this message because you are subscribed to the Google Groups "infra-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to infra-dev+unsubscribe@chromium.org.
-- Dirk
To unsubscribe from this group and stop receiving emails from it, send an email to infra-dev+...@chromium.org.
To post to this group, send email to infr...@chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/infra-dev/CAEoffTCWtzu87MQoRJ5sYcPVX6P9iZArVLytu38pT1BDKJJnOA%40mail.gmail.com.
--Sergiy Byelozyorov | Software Engineer | ser...@google.comGoogle Germany GmbHErika-Mann-Strasse 3380636 MünchenAG Hamburg, HRB 86891 | Sitz der Gesellschaft: Hamburg | Geschäftsführer: Matthew Scott Sucherman, Paul Terence Manicle
--
You received this message because you are subscribed to the Google Groups "infra-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to infra-dev+...@chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/infra-dev/CAEoffTDZgdEA-W%3DPgFN4hV3MQYN3DseCkomDaadr1iiWisP9_w%40mail.gmail.com.
--
You received this message because you are subscribed to the Google Groups "infra-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to infra-dev+...@chromium.org.
To post to this group, send email to infr...@chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/infra-dev/CAEoffTCQ6-0aZsMrEpjB0CbFgHyfAw-oohaa4ZOP%2BHNBynF8Ag%40mail.gmail.com.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/infra-dev/CAH58R2eGMj5KkyNHKGkjBGxxHiVuU-SB%3D7j%2BhAddR11AhS5sJg%40mail.gmail.com.