-
-
Notifications
You must be signed in to change notification settings - Fork 114
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Redesign Aura #217
Comments
There needs to discussion about The ProblemAura's current behaviour is this, assuming
With AUR 3.0, dependency information is going to be available via the AUR API, meaning the PKGBUILD will never have to be downloaded in first place. Fewer HTTP calls mean a faster Aura. The process becomes:
As dep checks happen before the PKGBUILD is downloaded, editing the dep fields in the PKGBUILD is pointless. If the user were given the opportunity to alter the deps given by the API, they would also have to alter the PKGBUILD in the same way, or else makepkg would crash. The Case for
|
I would still like a |
@bb010g Which would allow the user to edit all files in the downloaded tarball? They would have to understand that editing the deps fields wouldn't do anything. |
Just have it edit the metadata from the AUR. (That could go well with something like |
I'll have to see what the shape of the metadata is before I can make a call on that. |
For the ABS, wouldn't you still need to read the Also, for the current (pre-AUR3) workflow, what's the point of doing steps 1 and 5 separately? It seems like it might be more efficient to do the following, but if this approach is missing something crucial:
EDIT: Start list at 0 to match ones above |
Question: How much dependency information is stored in the database? Are {make,check}depends excluded? As for the current flow, you're probably right that doing those things separately is silly. There are redundant http requests, and the size difference between downloading a
And every folder for every package would look like this. Navigating from folder to folder would take some regexing on package names to find out where to navigate to. Right now, it just does it one at a time. The pre-downloaded PKGBUILD is held internally, dep checks are done, packages are sorted into a nice build order, and then one-by-one their tars are downloaded and built. Regardless, we don't have to worry about any of this in Aura 2 because of the new API coming, and the libalpm bindings to rely on. I agree with you that the current method is inefficient, but until Aura 2 it probably won't be changed. |
I assume the question at the top of your comment was about libalpm, because AUR 3.0 handles all four types of dependencies and even allows separate dependencies in split packages (which I don't think Aura correctly handles now). I believe ALPM only records regular and optdepends (which makes sense, given that it's designed for binary packages and therefore doesn't need to know about the others). The ALPM doxygen documentation only gives functions to retrieve these two dependencies (or it puts the makedepends and checkdepends functions somewhere other than where it puts the depends and optdepends ones. Thus, unless it's hiding somewhere I (and Google) haven't seen it, it's undocumented, or you want to drop ABS support entirely, you'll need to get these fields from Because of the ABS, the updated workflow you posted might not always be usable and some variant of the existing one might be necessary, at least sometimes, so I have another question about it. Would there be a problem with having a single temp directory with all the packages under it, like below:
|
Just a few remarks, since I had also time to think about these issues for another project:
I fully agree with the above. There shouldn't be any reason to modify dependencies in the PKGBUILDs in the first place. And if there is one, an additional PKGBUILD should probably be uploaded in the AUR instead of doing "magic" locally (that's the very reason I believe the idea behind customizepkg is silly in the first place). An --edit flag should be kept for special cases like xmobar-git, although any modification to the deps fields would be ignored.
The .AURINFO metadata is only useful to make the complete info available in the RPC interface in a secure way (and adding split package support in the AUR too), so "editing the metadata" would be the equivalent of editing the Json response. Then, it's possible to edit the json info on the fly, if you keep one info call per package or dependency. But Aura should use the multiinfo RPC call instead, because it is way faster as it requires only one call per level of dependencies, no matter what is the total number of dependencies in the transaction. Of course it would also theoretically be possible to edit the returned multiinfo answer, but that's would probably a nightmare for the user in practice. Better forget the customizationpkg thing entirely, it's not worth it (and silly in the first place imho).
I know some core pacman developers are interested in integrating ABS closely with pacman itself (read it some time ago on the ML). I haven't seen any patch for it yet, but I know this will eventually happen. Maybe in two weeks, maybe in two years, I don't know. So it's up to the aura dev to decide if it is worth it integrating it now, or if the extra work and time would be better invested in some other area of aura. |
Premise: If you know enough about package building to know you want different dependencies, you're smart enough to build them manually while hand-editing the PKGBUILD. An And yes, one |
Since you've decided to keep hotediting, is there a reason not to also keep I'll agree that changing dependencies isn't that useful, but there is a case where "contact the maintainer" or "release a clone package" aren't better options: adding optional dependencies to the |
What prevents you from uploading your own version in the AUR? I don't see in which way that wouldn't be a better option than patching again and again a package locally. |
In general: when somebody wants to make a change to an package and they believe their change would only benefit a small number of people (with others neutral or disliking the change), it is generally not worth uploading the package to the AUR. It's a minor hassle for the maintainer (and doesn't get rid of the problem of "patching again and again a package locally"), and if only a small number of people would prefer their version to a version already in the AUR or the official repositories, it doesn't give much benefit. Often, this change may only be useful to that one person (one example might be somebody who wants to configure dwm but still have it managed by a package manager, but I'm not sure if this example works because I don't personally use dwm or any of the other several tiling window managers that require recompilation for a configuration change ). The specific package that prompted my earlier comment: There's a package in the community repo called |
Could you not just keep a local PKGBUILD that you bump the version of every once and a while? You mention avoiding confusing AUR users with multiple versions on the AUR. I agree with this. We've arrived at one of the fundamental problems of the AUR: it's filled with garbage. Vast expanses of 0-vote, out-of-date, orphaned packages. Is there any system in place to have these removed? In the mean time, |
If the modified version is useful for someone, chances are that it is useful for another one at least. If the pkgbuild is kept up-to-date and has a logical name (software-mydiff), I don't really see why it shouldn't be uploaded in the AUR. The fact that it is popular or not is just a side effect.
Unmaintained or obsolete packages are indeed a big issue. There have been some discussion in the forums and on the aur-dev mailing list, but nothing is set on stone yet. When I read the following, I really hope the entire AUR content get wiped and starts again on a clean basis:
Seriously, the aurpocalypse is going to be fun. |
I would support that. |
Am I to understand that you don't want to implement Also, what about a more generic hooks mechanism? ALPM will probably get hooks at some point, but it might be useful to have AUR, ABS, or building specific hooks. They could be used in general to implement |
I think it's a very good idea (thinking for future version of Aura as well, moved to other distros) to implement some sort of plugin/hooks system so that the build process can be highly customized. |
@dhouck I've made three proposals on how the plugin system could be implemented. What do you think? |
Option 3 gives the most flexibility though the CON (many deps) could really cause havoc with the build system. Option 2 I think is good middle ground and works somewhat like PKGBUILDs now (different areas you can write and such. Option 1 Too complexed really and honestly Option 2 can give just as much flexibility as 1. |
How exactly? One other thing I thought of was that non-Haskell plugins wouldn't be forced to compute things via the Aura Monad (in particular, via the
Unfortunately I've never coded with Haskell actors before and I believe for me personally this would be the hardest to implement. Another pro that hasn't been added yet is the opposite of the above: Operations could be guaranteed to run through the Aura Monad.
I don't know if I agree, but the whole "pre-built version users can't configure" thing is a big con, I think. |
We could just do something like |
That applies to any of the options. |
I'm considering going ahead with Option 1 for the following reasons:
hooks :: AuraHooks
hooks = defaultHooks becomes: import Aura.Hooks.Customizepkg
hooks :: AuraHooks
hooks = defaultHooks { pkgbuildHooks = customizepkgHook : defaultPkgbuildHooks }
|
Let me elaborate: As pkgCache :: Text
pkgCache = "/var/cache/pkgs/" but it would probably be more "hands off" for the average user to have: import Linux.Aura.Hooks.Arch (archPkgCache, ...)
pkgCache :: Text
pkgCache = archPkgCache The user can, of course, change this at will by setting a different string. They know their conf file is valid if it typechecks. Saving their change, they run Within Aura, all it ever checks is Q: How will the user know what the actual contents of the conf file (paths, etc.) are if they're mostly aliases to things defined in Hooks? A: An option like |
Just for a sane check, might want to add a aura --confi-check (or something) so people could make sure the config check before running aura and having it fail out for some reason due to conf checks. If a user does not run the config-check manually before running aura and a failure happens, then a forced check should be run which could also out put the |
Dyre might support that (if we decide to use it).
|
It was a runtime error, so I'm not sure what kind of checking could have prevented it. If it helps make things clearer, I can try to reproduce the scenario this weekend. Another alternative might be the plugin package, ghc's api, or hint. I'll update this post with links within the hour (heading out the door at the moment). |
Shiny. Now we just need a better TOC. I'd say some reformating is also in
|
I'll be going through and updating some things pretty soon. |
I would be ok without hotedit as long as we get makepkg functionality in aura. I sometimes use hotedit to completely change what package I'm installing just so that aura can install aur dependancies and make/install the package. |
How’s it going? Did you address #153 in the redesign already? |
@flying-sheep Luckily that will be hook dependent and not part of the Aura core itself. |
Suggestion: option to pass arguments directly to |
@joca-bt This is often requested, and would be handled by the Arch-specific hooks of Aura 2. |
|
Cool, thanks! |
@atondwal I didn't know there were non-Linux versions of Arch. Provided they have |
Maybe we could have names like |
Or take an |
I'd be for just |
Where a hook library would be: |
+1 |
#332 brought up an interesting point. Currently, |
My propositions for renaming top-level ops is covered in the Doc. I like the idea of relegating the other ones to subops of the top-level ones. |
The main issue with something like a global |
I have been flirting with the idea of multiple Hook sets on one machine (which you seem to be implying here). As Then they make calls like:
Some general
|
@fosskers that would probably make the day of people who use all these different package manager and would be very useful. |
Is it easier for someone to do Output like
So that you can see what packages, from any manager, are installed on your system. |
Design then may be informed by a proper port of libalpm. |
Create a design document in
.md
format for easy viewing on github. This also allows for code snippets to be added. The main section needed isFunctional Requirements
, as many of Aura's features were tacked on later because the use cases they involve were not known about at first. As many use cases as possible should be considered before recoding begins.Related issues:
customizepkg: customizepkg failure & output #93 customizepkg is unsafe #143 Handling of customizepkg #198The text was updated successfully, but these errors were encountered: