The Funtoo Linux project has transitioned to "Hobby Mode" and this wiki is now read-only.
Difference between revisions of "Funtoo:Metatools/Releases/1.0.5"
(Created page with "{{SoftwareRelease |release_date=2022-05-28 |name=metatools |version=1.0.5 |type=regular }} == ChangeLog == The 1.0.5 release of metatools has a number of significant functiona...") |
|||
(5 intermediate revisions by the same user not shown) | |||
Line 3: | Line 3: | ||
|name=metatools | |name=metatools | ||
|version=1.0.5 | |version=1.0.5 | ||
|type= | |type=major | ||
}} | }} | ||
== ChangeLog == | == ChangeLog == | ||
The 1.0.5 release of metatools has a number of significant functionality improvements and bug fixes. | The 1.0.5 release of metatools has a number of significant functionality improvements and bug fixes. | ||
{{Important|Please note that metatools requires a version earlier than 0.23.0 of {{c|httpx}}. 0.23.0 introduced breaking changes to the httpx | |||
API. Please see {{Bug|FL-9887}} and {{Bug|FL-9888}}.}} | |||
=== New Features === | === New Features === | ||
Line 14: | Line 17: | ||
This is an implementation of the feature request described in {{Bug|FL-9827}}. | This is an implementation of the feature request described in {{Bug|FL-9827}}. | ||
{{c|doit}} now allows the use of official generators such as github-1 to be used outside of kit-fixups. The way this works is that doit will now detect if it is being run inside kit-fixups or not. If it is | {{c|doit}} now allows the use of official generators such as github-1 to be used outside of kit-fixups. The way this works is that doit will now detect if it is being run inside kit-fixups or not. If it is '''not''', then it will clone/update a kit-fixups repository to {{f|~/repo_tmp/source-trees/kit-fixups}} to have access to the official generators. | ||
New options have been added to | New options have been added to {{c|doit}}: | ||
;{{c|--fixups_url}} and {{c|--fixups_branch}}: Can be used to point to a kit-fixups to clone if you want to use a non-standard kit-fixups for access to custom generators. | ;{{c|--fixups_url}} and {{c|--fixups_branch}}: Can be used to point to a kit-fixups to clone if you want to use a non-standard kit-fixups for access to custom generators. | ||
;{{c|--fast}}: If you are using | ;{{c|--fast}}: If you are using {{c|doit}} outside of kit-fixups, doing a git pull on ~/repo_tmp/source-trees/kit-fixups can take a bit of time. This option tells {{c|doit}} to use the already-cloned kit-fixups as-is without trying to update it by hand first. | ||
To use: | To use: | ||
Simply run | Simply run {{c|doit}} in an arbitrary overlay -- it will "just work". The extra options are there if needed but are not normally required. | ||
==== Allow {{c|github-1}} Generator to Lock Version ==== | |||
This implements functionality described in {{Bug|FL-9855}}. | |||
Add a mechanism for github.py and github-1 generator to autogen a specific tag version. This allows us to lock down certain autogens and leverage the github-1 generator even for static ebuilds (I am using this for the containerd ebuild). Before this, it was tricky/impossible to use the generator with tags to generate anything but the latest version. | |||
This commit is being made to both kit-fixups (github-1.py) and metatools. | |||
{{Note|To use this feature, simply specify a literal version in {{c|version}} pkginfo. It will be used instead of grabbing the latest version.}} | |||
==== Add GitHub Tag Transforms ==== | |||
This implements functionality described in {{Bug|FL-9440}}: | |||
Add a {{c|1=transform=}} keyword argument to github.py tag methods to allow tags to be arbitrarily modified before they are searched for version strings. The keyword argument should be a single-argument function/lambda. Note that this functionality can only be used directly from Python, not | |||
YAML, as you must specify a function as an argument. | |||
=== Bug Fixes === | |||
* Fix {{c|1=refresh_interval=}} in {{c|get_page}} ({{Bug|FL-9881}}) | |||
* Adding missing {{c|psutil}} dep to {{c|setup.py}} and {{c|RDEPEND}}. ({{Bug|FL-9702}}) | |||
=== Improvements === | |||
==== Improved Logging ==== | |||
Various logging improvements (thanks: [[User:s4uliu5]] | |||
==== Improve JSON Decode ==== | |||
With httpx, sometimes escaping was broken (related to backslashes in strings.) It turns out that with httpx, the most reliable way to get proper json back is to use the json() method on the response object directly rather than rolling your own JSON decoding. | |||
==== Improve Fetch Cache Consistency ==== | |||
Refactor of the fetch cache, so that {{c|encoding}} and {{c|is_json}} settings are stored in the fetch cache data, and are also used to construct the hash key for the fetch cache, to ensure we always get back JSON when we stored JSON, etc. This completes the work related to robustifying JSON by using httpx's response.json() method, which now ensures we get back the format we originally requested from the fetch cache. Before we were relying on good behavior (no changes between JSON vs no) for a URL, whereas now we can handle this kind of change without returning incorrect format data in some rare cases. | |||
==== Steamline Mirroring ==== | |||
In {{c|--prod}} mode, have any locally-cloned destination tree create local branches for any remote branches. This should allow mirroring of the tree to work properly (so the remote won't be asked to delete branches) |
Latest revision as of 22:18, May 28, 2022
Metatools 1.0.5 is a major release which was released on 28 May 2022.
ChangeLog
The 1.0.5 release of metatools has a number of significant functionality improvements and bug fixes.
New Features
Allow Generators To Be Used in Overlays
This is an implementation of the feature request described in FL-9827.
doit
now allows the use of official generators such as github-1 to be used outside of kit-fixups. The way this works is that doit will now detect if it is being run inside kit-fixups or not. If it is not, then it will clone/update a kit-fixups repository to ~/repo_tmp/source-trees/kit-fixups
to have access to the official generators.
New options have been added to doit
:
--fixups_url
and--fixups_branch
- Can be used to point to a kit-fixups to clone if you want to use a non-standard kit-fixups for access to custom generators.
--fast
- If you are using
doit
outside of kit-fixups, doing a git pull on ~/repo_tmp/source-trees/kit-fixups can take a bit of time. This option tellsdoit
to use the already-cloned kit-fixups as-is without trying to update it by hand first.
To use:
Simply run doit
in an arbitrary overlay -- it will "just work". The extra options are there if needed but are not normally required.
Allow github-1
Generator to Lock Version
This implements functionality described in FL-9855. Add a mechanism for github.py and github-1 generator to autogen a specific tag version. This allows us to lock down certain autogens and leverage the github-1 generator even for static ebuilds (I am using this for the containerd ebuild). Before this, it was tricky/impossible to use the generator with tags to generate anything but the latest version.
This commit is being made to both kit-fixups (github-1.py) and metatools.
To use this feature, simply specify a literal version in version
pkginfo. It will be used instead of grabbing the latest version.
Add GitHub Tag Transforms
This implements functionality described in FL-9440:
Add a transform=
keyword argument to github.py tag methods to allow tags to be arbitrarily modified before they are searched for version strings. The keyword argument should be a single-argument function/lambda. Note that this functionality can only be used directly from Python, not
YAML, as you must specify a function as an argument.
Bug Fixes
- Fix
refresh_interval=
inget_page
(FL-9881) - Adding missing
psutil
dep tosetup.py
andRDEPEND
. (FL-9702)
Improvements
Improved Logging
Various logging improvements (thanks: User:s4uliu5
Improve JSON Decode
With httpx, sometimes escaping was broken (related to backslashes in strings.) It turns out that with httpx, the most reliable way to get proper json back is to use the json() method on the response object directly rather than rolling your own JSON decoding.
Improve Fetch Cache Consistency
Refactor of the fetch cache, so that encoding
and is_json
settings are stored in the fetch cache data, and are also used to construct the hash key for the fetch cache, to ensure we always get back JSON when we stored JSON, etc. This completes the work related to robustifying JSON by using httpx's response.json() method, which now ensures we get back the format we originally requested from the fetch cache. Before we were relying on good behavior (no changes between JSON vs no) for a URL, whereas now we can handle this kind of change without returning incorrect format data in some rare cases.
Steamline Mirroring
In --prod
mode, have any locally-cloned destination tree create local branches for any remote branches. This should allow mirroring of the tree to work properly (so the remote won't be asked to delete branches)