Mattermost-plugin-github: Labels with spaces don't work when saving a subscription

Created on 26 May 2020  路  7Comments  路  Source: mattermost/mattermost-plugin-github

When trying to set a subscription dependent on a label that contains a space, creating the subscription will fail. The user will receive a response that only 1 feature can be included.
The same subscription command works if the GitHub label does not contain white space.
This is not a regression from the previous release.

Creating a subscription as follows works as expected
/github subscribe DHaussermann/hello-world issues,label:"Help"

Creating a subscription as follows will return an error about the number of features.
/github subscribe DHaussermann/hello-world issues,label:"Help Wanted"

Hard Help Wanted TecGo TypBug

Most helpful comment

@utkuufuk In order to test, you can use ngrok to create a tunnel to your localhost. If you need any help with the configuration, do not hesitate to ask.

@larkox Thanks for the tip, tunneling makes sense :+1:
I'll try to make it work and get back to you if I face any issues.

All 7 comments

Good catch. Please note that this is not a regression. With the current parser fixing this issue is quite hard. Let's open this as a tricky help wanted.

I'll work on this.

Awesome, thanks @utkuufuk :+1:

@hanzei @larkox I have a question about configuring the plugin for the development environment.

There are detailed configuration steps in the repository readme, but I'm not sure how I'm supposed to set the "Authorization callback URL" and the "Webhook Payload URL" during development, since localhost obviously won't work.

This issue is just about parsing the command, so a workaround could be to programmatically skip the auth steps while working on this, that is unless there's a better way.

@hanzei @larkox I'm having another issue about deploying the plugin as admin.

I can successfully deploy without setting any environment variables using make dist && make deploy.

However, when I set the environment variables below as specified in readme;

export MM_SERVICESETTINGS_SITEURL=http://localhost:8065
export MM_ADMIN_USERNAME=admin
export MM_ADMIN_PASSWORD=password

then I run make dist && make deploy, I get the following error:

Authenticating as admin against http://localhost:8065.
Failed to deploy: failed to login as admin: : Enter a valid email or username and/or password.

@utkuufuk In order to test, you can use ngrok to create a tunnel to your localhost. If you need any help with the configuration, do not hesitate to ask.

Regarding your second question, just as a sanity check, you are setting the proper admin user name and admin passwords instead of admin and password, right?
Also, have you tried https instead of http?

@utkuufuk In order to test, you can use ngrok to create a tunnel to your localhost. If you need any help with the configuration, do not hesitate to ask.

@larkox Thanks for the tip, tunneling makes sense :+1:
I'll try to make it work and get back to you if I face any issues.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

jfrerich picture jfrerich  路  5Comments

hanzei picture hanzei  路  3Comments

crudolf picture crudolf  路  3Comments

iomodo picture iomodo  路  5Comments

mattermod picture mattermod  路  6Comments