Skip to content
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

Resource types: Consistent naming #8

Open
jaller94 opened this issue Sep 30, 2022 · 3 comments
Open

Resource types: Consistent naming #8

jaller94 opened this issue Sep 30, 2022 · 3 comments

Comments

@jaller94
Copy link

I'd like to have common names for arguments of resource types on the hub.

The ones admin created all use single words (e.g. token) or abbreviations like dbname for "database name" and sslmode for "SSL mode".

The ones I created use camelCase and usually two words like baseUrl and accessToken.


  1. I think it's fairly important for the Hub (and Windmill in general) to suggest a consistent pattern.

e.g.

  • All authentication tokens should be called token.
  • Multiple words should be written in snake_case, e.g. base_url.

  1. We should have a consistent argument names for token and baseUrl (or base_url), as pretty much all services I'm thinking of have these two. I'm strongly considering to edit the current ones and re-submit all my scripts to make them consistent with the rest of the platform.
@rubenfiszel
Copy link
Contributor

The reason for dbname and sslmode is so we could unwrap the resource directly to psycopg2 connect

I would vote to use camel case everywhere like you did,

  1. I'm all for token and baseUrl being super consistent. Would you have to edit a lot ?

@jaller94
Copy link
Author

The following types need accessToken changed to token:

  • matrix
  • mastodon

And all my scripts for matrix need to be updated.
It's a fairly small change at this point.

@jaller94
Copy link
Author

jaller94 commented Oct 1, 2022

Updated the resource types.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants