question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Specify version of yaml spec to use

See original GitHub issue

Decision

Add version selection to schema. Schema version selection only uses major version, minor version is too granular. Current version is 1.0, work to complete spec will be under 2.0

Work required:

  • Add version selection to all schema versions of the config file
  • Work out a pattern to add multiple version parsing to the config file. How do we share config options that don’t change? How do we share config options that changed a little? Does class based schema validation work best?
  • Make an implied version 1.0 of the config file schema. I’m not sure if we also need schema tests for version 1.0, but it might also make sense to define the spec well.

Original Question

I didn’t find anything related to this on this repo and on the other, so I creating this issue here due https://github.com/rtfd/readthedocs-build/issues/46.

I think would be nice if we allowed to specify the version of the spec used, so this way we can introduce breaking changes to the spec without to worry about previous projects to fail.

We can use semver perhaps?

And something like this on the yaml

Use specific version

version: 2.1
python:
    ...

Use version with latest minor patch

version: 2
python:
    ...

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:10 (10 by maintainers)

github_iconTop GitHub Comments

1reaction
agjohnsoncommented, Jun 21, 2018

We can probably keep the build logic where it is, and just use conditional logic around the existing build code. The most important part is that we have a config object that knows what features it supports, and how to parse/validate those config values. Here’s a psuedo code example:

https://gist.github.com/agjohnson/70a2b5e839bc8e7fd722f8eaf63d6676

1reaction
agjohnsoncommented, Mar 29, 2018

+1 on major version, if only to reduce the number of specs we’re supporting. We will have a lot more backwards incompatible changes to support here though, so I think a lot of changes will be bumping major versions anyways. New feature additions to the spec shouldn’t break anyone’s config.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Specify version of yaml spec to use · Issue #3806 - GitHub
To get the DocBuilder object we need to parse the version key of the yaml (default to 1 if isn't present), pass the...
Read more >
YAML Configuration File
The version of the spec that the user wants to use will be specified on the YAML file. The spec only will have...
Read more >
YAML Ain't Markup Language (YAML™) Version 1.1
The “ YAML ” directive specifies the version of YAML the document adheres to. This specification defines version “ 1.1 ”. A version...
Read more >
How to specify version ranges in Conda environment.yml
I think/assume that the syntax specifying versions is the one documented at Package match specifications. So you would write - numpy >=1.2.3 ...
Read more >
Compose specification - Docker Documentation
The Compose file is a YAML file defining services, networks, and volumes for a ... A Compose implementation SHOULD NOT use this version...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found