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

Added Conflicted Claims Feature #357

Merged

Conversation

prathambatra
Copy link
Contributor

Signed-off-by: prathambatra batrapratham999@gmail.com
fixes #260
Created new PR(previous was by master branch) after merging bootstrap changes. UI changes are remaining. will commit soon.

Signed-off-by: prathambatra <batrapratham999@gmail.com>
@prathambatra
Copy link
Contributor Author

@hereisnaman please confirm . Do you need the same way conflicted claims below claim card and form on the right side.
Screenshot from 2020-05-22 20-19-22
something like this only positioning . this is from my previous PR.

@thenamankumar
Copy link
Contributor

@hereisnaman please confirm . Do you need the same way conflicted claims below claim card and form on the right side.
Screenshot from 2020-05-22 20-19-22
something like this only positioning . this is from my previous PR.

Please refer to the new design and reflect the changes

@prathambatra
Copy link
Contributor Author

@hereisnaman cool. I will complete this today.

Signed-off-by: prathambatra <batrapratham999@gmail.com>
Signed-off-by: prathambatra <batrapratham999@gmail.com>
@prathambatra
Copy link
Contributor Author

Screenshot from 2020-05-28 14-55-32
Screenshot from 2020-05-28 14-55-48

@prathambatra
Copy link
Contributor Author

@hereisnaman

routes/root.js Outdated
res.send('Error getting conflicting claims')
})
}
else {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There can be conflicts in the case when the pull url points to an issue as well. Handle that here.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it means same person claimed issue more than once or someone else is claiming issue created by someone. right?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

will fix it.

Signed-off-by: prathambatra <batrapratham999@gmail.com>
@prathambatra
Copy link
Contributor Author

Screenshot from 2020-05-30 15-12-43
Screenshot from 2020-05-30 15-13-12
ezgif com-video-to-gif (1)

@thenamankumar
Copy link
Contributor

Can you debug why this is not working:
Screenshot 2020-05-31 at 3 41 40 PM
Screenshot 2020-05-31 at 3 41 37 PM

@prathambatra
Copy link
Contributor Author

@hereisnaman yeah sure wait.

@prathambatra
Copy link
Contributor Author

Screenshot from 2020-05-31 15-52-13
its working fine on my side.

Signed-off-by: prathambatra <batrapratham999@gmail.com>
@prathambatra
Copy link
Contributor Author

@hereisnaman does it show no conflicted claims?

@prathambatra
Copy link
Contributor Author

@hereisnaman have you rechecked, as it was working fine for me.

Signed-off-by: prathambatra <batrapratham999@gmail.com>
@thenamankumar thenamankumar merged commit 67bbf2d into coding-blocks:master Jun 5, 2020
@boss-contributions-bot
Copy link

Congratualtions @prathambatra, your pull request is merged! 🎉

Thanks for your contributions and participating in BOSS 2020. 🙌

You can claim your bounty points here. 💰

Copy link
Contributor

@prabalsingh24 prabalsingh24 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@hereisnaman @prathambatra I see the testing-required label. I tested this feature

Comment on lines +2 to +16
let urlDetails = {
project : "",
type : "",
id : ""
}

url = url.split('/')
position = url.indexOf('github.com')

urlDetails.project = url[position+2]
urlDetails.type = url[position+3]
urlDetails.id = url[position+4]

return urlDetails;
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

upperCase lowerCase in the url is not handled properly here.

if github.com is in upperCase then this would fail. (Although you can't really enter https://GITHUB.com/coding-blocks/boss/issues/29923232. this throws duplicate issue error (a bug maybe?). But still it's better to make sure it doesn't break in the future)

Also project, type should be converted to lowerCase.

https://github.com/coding-blocks/BOSS/issues/29923232
https://github.com/coding-blocks/boss/issues/29923232 This fails when these two are the issueUrl. Op.like is case-sensitive I guess

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@prabalsingh24 'GITHUB.com' and 'github.com' should be fixed at add claim level. thanks for pointing the project, and type. yes, they should be converted to lower case.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@prabalsingh24 @hereisnaman I think we just need to convert both issue URL and pull URL to lowercase before adding. Everything will work fine, no need to do any change anywhere else. just convert url to lowercase on adding.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah that would work but if there is already a pull url with uppercase, then it might fail in that case. I know chances of that happening is pretty low. But better to be on the safer side and fix it from the both side?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we will add convert code to add claims and also write a migration to convert existing ones.

@deprov447
Copy link

@prabalsingh24 Can I work on this issue?

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

Successfully merging this pull request may close these issues.

Add conflicting claims section on accept claims page
4 participants