-
Notifications
You must be signed in to change notification settings - Fork 43
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
Onboarding updates #135
Comments
/start |
Tips:
|
@rndquu After looking into it, I think there would be different approaches that we should consider, all having their pros and cons. Generating script for the configurationIt would work similarly to the script that currently pulls the configuration from the repo, e.g. downloading the file from the Ubiquity Bot directly.
Cons
Git SubmodulePros
Cons
Git SubtreePros
Cons
It seems to me that having a submodule would be the best choice. Now I could try to do a partial clone to avoid having the whole other project in it. Please share your thoughts if any other approach sounds better! |
Follow up question, there are inside the
Should they be added in the bot config, or are specific for the onboarding? |
@FernandVEYRIER
Using git submodule is fine |
I'm not deeply aware of the latest bot's architecture. @wannacfuture @whilefoo Do we still need to set |
We migrated from kebab case to camel case. Kebab case properties should be deprecated.
|
Thank you for the info @pavlovcik. Then, I will change |
In our config the 3rd naming us used: |
Yes sorry I was not on my computer much of today but my mistake was not clarifying that the development branch on this repository is extremely outdated. As mentioned in our other thread @FernandVEYRIER the latest is here: https://github.com/pavlovcik/ubiquibot/tree/refactor/move-to-delegated-compute And again, this will be deprecated when we get the kernel stable. However we will port over the event handlers so it's not a wasted effort to continue working on this repository, as the "core" is quite stable. Just as long as you're doing work in the GitHub webhook event handlers instead of "core" logic which will be replaced by the new kernel. |
@pavlovcik from the repo you sent, it seems that the default configuration is pulled from another repo according to a given context. It also depends on a lot of 3rd party libraries to generate the config itself. This complicates things a lot when it comes to integrate it in another repo. At that point I believe that having an endpoint serving the configuration would make more sense. I refer to the file https://github.com/pavlovcik/ubiquibot/blob/refactor/move-to-delegated-compute/src/utils/generate-configuration.ts since I need a default config. Edit: |
Some other remarks is that I'm curious to see some type of caching approach because on Cloudflare Workers in our current state of research, it must fetch both the organization and repository configurations within the GitHub webhook event handler function. This means that before it can respond to the user invoked event, the Worker needs to make a couple of fetches to those repositories and merge the configuration before it can respond. The configuration is needed to modify the behavior of the Worker response for most situations I can think of so it seems like an optimization that will affect most use cases. We also made a handler for pushes that validates the |
Another approach could be to locally generate the configuration during a build and store it as a file, thus not needing to poke the network at runtime anymore. It comes with drawbacks as well, such as the conf not being updated without a rebuild, and the need to embed it somewhere. The cache would speed things up but still depend on a network request I believe. |
Unfortunately the vision is to run a single kernel instance from a Cloudflare Worker that we control across all of our future partner organizations/repositories. I didn't deeply do research here but I imagine that caching on |
I've been thinking about it for a while, but why not making it an npm package? That would solve the distribution issue, very easy to include in any project, with all the type and dependencies, we also get versioning so we don't break everything whenever we update? |
I'm not against distributing npm packages, but I guess it's not clear to me if you are implying that our partners can make other repositories and then run their own instances of the bot. But our business model mandates that our partners go to the GitHub marketplace and add our UbiquiBot to their organization/repositories as a GitHub App. From here we can support Fiat payments (monthly fees or transaction fees) directly via GitHub and then middle-man/provide the liquidity between crypto or fiat (bank transfer or top up of our UbiquiCards) for the payouts to the contributors (this is our strong moat to establish a profit margin/service for charging transaction fees) |
I meant that the configuration could be it's own repository that we distribute as an npm package. This way any project that needs the configuration can just add something like "@ubiquibot/configuration" in the npm packages of the project, this way you get access to the configuration easily, with the parsing / generation methods as well. |
That's a great idea. I do envision a developer SDK for our plugins which absolutely should make configuration imports simple (as they seem to need to be handled by the plugin itself.) |
+ Evaluating results. Please wait... |
Depends on ubiquity/ubiquibot#725
There is the onboarding page where partners can generate a default bot's config (example) for their organizations.
It requires a few fixes:
json
tots
ubiquibot#725 is implemented we should refactor the onboarding code to work with the bot's.ts
default config instead of.json
any
type declarations in the onboarding pageThe text was updated successfully, but these errors were encountered: