Re: Can the Slack integration be configured to omit or truncate the Description?
Hi Christian -- thanks for the detailed reply. So to explain the request in more detail: We have no concern about the Summary field, nor the repo name or branch. It's really only the Description field we care about because it contains potentially unbounded amounts of text, and maybe sensitive source code that we wouldn't necessarily want unexpected Slack users seeing. Slack channel membership is not as tightly controlled as Git repo access is for developers -- it's pretty easy to invite someone to a Slack channel, so the person posting doesn't always know the exact readership. Interesting that you mentioned screenshots -- I tested a review with a screenshot and that didn't show up in Slack in fact, so I assumed it was deliberate. I think if possible we would want to skip attachments in principle. It's less clear cut than the Description and probably wouldn't be a killer as long as they were just URLs, though if they displayed as full images in Slack it would bulk out the notification a lot. We'd prefer the Slack notification to be a basic "something changed" type of thing and people who care can follow the link back to the review. Apart from code confidentiality issues, our Slack admins are very nervous about any automated process making posts without some kind of size sanity checks. I think if the Description field had a maximum length (we'd probably choose 100 or 200 chars) that would be a big help to get it approved. Thanks for the subclassing suggestion. I might take a look at that. -- Ben -- Supercharge your Review Board with Power Pack: https://www.reviewboard.org/powerpack/ Want us to host Review Board for you? Check out RBCommons: https://rbcommons.com/ Happy user? Let us know! https://www.reviewboard.org/users/ --- You received this message because you are subscribed to the Google Groups "Review Board Community" group. To unsubscribe from this group and stop receiving emails from it, send an email to reviewboard+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/reviewboard/f7355248-ebf2-43f0-9fd0-fda2b7468f03%40googlegroups.com.
Re: Can the Slack integration be configured to omit or truncate the Description?
Hi Christian -- thanks for the detailed reply. So to explain the request in more detail: We have no concern about the Summary field, nor the repo name or branch. It's really only the Description field we care about because it contains potentially unbounded amounts of text, and maybe sensitive source code that we wouldn't necessarily want unexpected Slack users seeing. Slack channel membership is not as tightly controlled as Git repo access is for developers -- it's pretty easy to invite someone to a Slack channel, so the person posting doesn't always know the exact readership. Interesting that you mentioned screenshots -- I tested a review with a screenshot and that didn't show up in Slack in fact, so I assumed it was deliberate. I think if possible we would want to skip attachments in principle. It's less clear cut than the Description and probably wouldn't be a killer as long as they were just URLs, though if they displayed as full images in Slack it would bulk out the notification a lot. We'd prefer the Slack notification to be a basic "something changed" type of thing and people who care can follow the link back to the review. Apart from code confidentiality issues, our Slack admins are very nervous about any automated process making posts without some kind of size sanity checks. I think if the Description field had a maximum length (we'd probably choose 100 or 200 chars) that would be a big help to get it approved. Thanks for the subclassing suggestion. I might take a look at that. -- Ben. On Wednesday, 23 October 2019 06:58:56 UTC+1, Christian Hammond wrote: > > Hi Ben, > > We don't have any way of doing this built-in, I'm afraid. I want to > understand this in more detail. > > So the main concern is that you're looking to limit what information Slack > receives, and the main source of this information in your case would be in > the description, correct? Are there any concerns about the summary or any > fields (branch, repository, etc.) being sent as well? If a review request > has an attached screenshot, it will be shown as well, so would that also > need to be filtered out? > > One approach, which admittedly is more involved but gives you more control > over what gets sent, is to write your own extension that registers a > subclass of our own SlackIntegration ( > https://github.com/reviewboard/rbintegrations/blob/master/rbintegrations/slack/integration.py#L155 > ). > > That subclass would override notify(), altering some of the fields and > stripping away the description, screenshots, or whatever else you need to > remove, and then call the parent with the new method. > > Your Extension subclass would be simple, just something like: > > > from reviewboard.extensions.base import Extension > from reviewboard.extensions.hooks import IntegrationHook > > class MySlackExtension(Extension): > def initialize(self): > IntegrationHook(self, MySlackIntegration) > > > Christian > > On Tue, Oct 22, 2019 at 8:03 AM Ben ST > > wrote: > >> Hi >> >> I am experimenting with the Slack integration (RB 3.0.15). Currently all >> of the RB Description body is sent to Slack. Is there a way to limit the >> post just to the Summary? >> >> For confidentiality/security reasons our system admins don't want code >> posted into Slack channels, at least not by an automated system. So I can't >> use the Slack integration as it is. Or if there was a way to limit the >> Description to a max length like 250 chars, that would be good enough. >> >> Thanks. >> >> -- >> Supercharge your Review Board with Power Pack: >> https://www.reviewboard.org/powerpack/ >> Want us to host Review Board for you? Check out RBCommons: >> https://rbcommons.com/ >> Happy user? Let us know! https://www.reviewboard.org/users/ >> --- >> You received this message because you are subscribed to the Google Groups >> "Review Board Community" group. >> To unsubscribe from this group and stop receiving emails from it, send an >> email to revie...@googlegroups.com . >> To view this discussion on the web visit >> https://groups.google.com/d/msgid/reviewboard/511c5ed2-6d32-471a-b7de-38d22479abca%40googlegroups.com >> >> <https://groups.google.com/d/msgid/reviewboard/511c5ed2-6d32-471a-b7de-38d22479abca%40googlegroups.com?utm_medium=email_source=footer> >> . >> > > > -- > Christian Hammond > President/CEO of Beanbag <https://www.beanbaginc.com/> > Makers of Review Board <https://www.reviewboard.org/> > -- Supercharge your Review Board with Power Pack: https://www.reviewboard.org/powerpack/ Want us to host Review Board
Can the Slack integration be configured to omit or truncate the Description?
Hi I am experimenting with the Slack integration (RB 3.0.15). Currently all of the RB Description body is sent to Slack. Is there a way to limit the post just to the Summary? For confidentiality/security reasons our system admins don't want code posted into Slack channels, at least not by an automated system. So I can't use the Slack integration as it is. Or if there was a way to limit the Description to a max length like 250 chars, that would be good enough. Thanks. -- Supercharge your Review Board with Power Pack: https://www.reviewboard.org/powerpack/ Want us to host Review Board for you? Check out RBCommons: https://rbcommons.com/ Happy user? Let us know! https://www.reviewboard.org/users/ --- You received this message because you are subscribed to the Google Groups "Review Board Community" group. To unsubscribe from this group and stop receiving emails from it, send an email to reviewboard+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/reviewboard/511c5ed2-6d32-471a-b7de-38d22479abca%40googlegroups.com.
Do you need a mirror path if using local Git repositories?
If Review Board is set up to only use local Git repositories, would it ever contact the remote Git server? Do I need to specify the remote URL in the mirror path? I'm just trying to simplify my configuration to eliminate scope for network and/or authentication issues. In the Repository admin page I have removed the Mirror path, and also the SSH key, and all still seems to work. Thanks. -- Supercharge your Review Board with Power Pack: https://www.reviewboard.org/powerpack/ Want us to host Review Board for you? Check out RBCommons: https://rbcommons.com/ Happy user? Let us know! https://www.reviewboard.org/users/ --- You received this message because you are subscribed to the Google Groups "Review Board Community" group. To unsubscribe from this group and stop receiving emails from it, send an email to reviewboard+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/reviewboard/b4f35bbb-3a38-470b-afeb-38aa0ba8362b%40googlegroups.com.
Re: HTTP 0 error with larger reviews (Docker image)
Thanks very much for the reply, Christian. You're absolutely right and it is the email send that is hanging. It works fine configured the same way outside of a Docker container. The odd thing is that after the hang and timeout the email does actually get delivered, so it's not a complete network failure. I'll have to figure out what Docker is doing. Can you tell me anything about how RB sends the emails -- does it use some particular subsystem? I tried setting uwsgi to use multiple processes but it didn't make a difference. -- Ben. On Tuesday, 1 October 2019 19:51:48 UTC+1, Christian Hammond wrote: > > Hi Ben, > > If this is happening at Publish time, then my first guess would be that > something is going wrong with sending an e-mail. That, or custom WebHooks, > are the only blocking operations that exist in the publish process (we do > want to make these non-blocking in the future, fwiw). > > Try disabling e-mails entirely and see if that fixes the problem. WebHooks > as well, if they're configured. > > What concerns me a bit is the Connection Refused errors. I looked at the > Docker image and I suspect part of what's happening is that uwsgi (set up > in the image) is running multi-threaded but only with a single process. > This can lead to blocking issues. You're really going to want to update > that to use multiple processes, for things like this. Maybe start with 10, > go up from there. You'll have to determine what numbers are best for your > scale (and how many Docker instances you plan to run). It doesn't look like > the image natively supports customizing this, so you'll probably have to > fork the image. > > Christian > > On Thu, Sep 26, 2019 at 8:39 AM Ben ST > > wrote: > >> I have installed ReviewBoard using Docker and the ikatson/reviewboard >> image. I thought it was all working and some small test diffs I posted >> worked fine. Then when we tried to use some real diffs that were a bit >> larger, ReviewBoard shows "Saving" for a long time (~60 seconds) and gives >> a "HTTP 0" error. See attached screen shot. >> >> This is not a stupidly large diff. It's around 50 files, and an attached >> 6MB movie. The diff upload itself, and attaching the movie, work fine. The >> error happens when you try to publish. I am using HTTP on port 8000. >> >> Does anyone know what is causing this? Thanks. >> >> ReviewBoard log: >> >> 2019-09-26 11:23:59,273 - INFO - - root - Reloading logging settings >> 2019-09-26 11:24:02,977 - DEBUG - None - bestave - >> /reviews/r/1/_fragments/diff-comments/1/ - root - Begin: Generating diff >> file info for diffset id 1, filediff 2 >> 2019-09-26 11:24:03,632 - DEBUG - None - bestave - >> /reviews/r/1/_fragments/diff-comments/1/ - root - End: Generating diff file >> info for diffset id 1, filediff 2 >> 2019-09-26 11:24:03,633 - DEBUG - None - bestave - >> /reviews/r/1/_fragments/diff-comments/1/ - root - Generating diff file info >> for diffset id 1, filediff 2 took 0.655330 seconds >> 2019-09-26 11:25:17,069 - DEBUG - - root - Calculated issue counts for >> review request ID 1 across 1 review(s): Resulting counts = {u'A': 0, u'B': >> 0, u'R': 0, u'D': 0, u'O': 1}; DB values = >> [{u'screenshot_comments__issue_status': None, >> u'general_comments__issue_opened': True, u'file_attachment_comments__pk': >> None, u'screenshot_comments__issue_opened': None, u'comments__pk': None, >> u'general_comments__pk': 1, u'comments__issue_opened': None, >> u'general_comments__issue_status': u'O', >> u'file_attachment_comments__issue_opened': None, >> u'screenshot_comments__pk': None, u'comments__issue_status': None, >> u'file_attachment_comments__issue_status': None}]; Field IDs = >> {u'screenshot_comments': set([]), u'general_comments': set([1]), >> u'comments': set([]), u'file_attachment_comments': set([])} >> >> >> Chrome console (also in a screen shot): >> base.min.af574b99af97.js:3 [Deprecation] The Notification API may no >> longer be used from insecure origins. You should consider switching your >> application to a secure origin, such as HTTPS. See https://goo.gl/rStTGz >> for more details. >> setup @ base.min.af574b99af97.js:3 >> :8000/reviews/api/review-requests/1/reviews/draft/?1569497084270_format=json=html=raw%2Cmarkdown:1 >> >> Failed to load resource: the server responded with a status of 404 (NOT >> FOUND) >> reviews.min.62c9e1499e46.js:5 Failed to save review Arguments(2)0: r >> {cid: "c20", attributes: {…}, _changing: false, _previousAttributes: {…}, >> changed: {…}, …}attributes: {parentObject: r,