It should be possible to hide diff of some of the files by default

When reviewing PR it's offen problematic if the PR contains big autogenerated changes. Especially in files like `yarn.lock` or `package-lock.json`. Those files are totally not interesting for me and I'd prefer them to be collapsed by default.

All of the files are expanded by default and with many lines to show (around few thousands) it starts to be really troublesome to navigate (page is lagging)

Can you guys make it collapsed by default and save the reviewers pain of looking at massive and not interesting diffs?

yarnlocks.PNG

Example above

4 comments

I disagree, the linked feature request is not really the same. Especially since bitbucket doesn't auto-load some files once a diff has reached a certain size. So if I have a project with files

```

package.json

package-lock.json

sourcefile1

sourcefile2

````

 

`sourcefile1` and `sourcefile2` always get stuck with the annoying `Oops! You've got a lot of code in this diff and it couldn't load with the page. Click here to give it another chance.` message.

 

It seems like bitbucket should be smart enough to recognize common files like `package-lock.json` use extremely common and almost always have a very log signal:noise ratio, and collapse them accordingly. Or at least move them to the end of the diff, which presumably would make them more likely to get the `Oops!` message than the actual source code.

Like 2 people like this

I agree that this issue is distinct from 7086. I'd really like to see files above a certain size either collapsed by default, or pushed to the end of the list. It would make it much easier to skim a PR and quickly identify areas that will require closer review.

+1, almost all our PRs fail to load anything because the first file is often a large `package-lock.json` file that fails, and all subsequent files fail. The linked issue is not the same, it was quite easy to create a Tampermonkey script that adds collapse/expand of individual file diffs, but the failure to load file diffs at all is quite annoying.

Same here, can't believe, we're in 2019, and I'm not able to see the diff of my javascript project.

If this doesn't get fixed soon, this would be a real reason for me to move back to Github.

Like 2 people like this

The new PR experience "lab" is amazing and just what I was hoping to see! I acknowledge that it's in beta but looks like it will significantly improve my workflow.

For anyone else coming here, here's how to enable:

  • Click your profile image in the bottom-left
  • Choose “Bitbucket settings”
  • Choose “Apps and features > Labs” from left-hand menu
  • Enable “New pull request experience”

Right off the bat I can see that it hides my package-lock.json which was causing the most trouble, but correctly displays all other files. I'm seeing a 404 when I click "Configure excluded files" but I'm assuming that this will be fixed soon.

Well done Atlassian 👏

Like 3 people like this

I am sorry but using a new PR experience is no way to be fix for that. 

First of all there are multiple functionalities missing there. This one alone does make it unusable in our company. Tasks for example

But there's more: big PRs are totally not usable, whereas in the "old experience"  it was slow but eventually page would load (WTF)

Oh, for sure. I'm definitely going to be flipping back and forth between the two implementations, since I frequently need to add tasks and create comment permalinks. This is annoying but fortunately these features seem to be on their roadmap.

I haven't seen it barf yet for big PRs but will keep that in mind.

Tom Kane Atlassian Team Jan 24, 2019

We’ve released a new feature called Excluded files. You can now exclude files in large diffs on pull requests for which you are the admin, so the review process is easier for everyone involved. To enable the new feature, go to the repository containing the pull request and click Settings > Excluded files in the Pull Requests section. Learn more.

The Excluded files filter is only available in the new pull request experience.

Like 1 person likes this

Any chance for this to be included in commit diffs as well?

Tom Kane Atlassian Team Feb 04, 2019

That's a great idea. We are gathering feedback and usage metrics on excluded files in the new pull request experience. We also have some improvements we want to add to the feature. After that we may consider supporting excluded files in other diff contexts.

Tom Kane Atlassian Team Feb 04, 2019

You can read about this feature on the Bitbucket blog.

Comment

Log in or Sign up to comment
Community showcase
Published Thursday in Bitbucket Pipelines

Building a Bitbucket Pipe as a casual coder

...ipe.sh :  #!/bin/bash source "$(dirname "$0")/common.sh" enable_debug extra_args="" if [[ "${DEBUG}" == "true" ]]; then extra_args="--verbose" fi # mandatory variables R...

220 views 0 12
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you