Question: How to change the width of a tab

Hello,
how do i change the Width of the Tab Character?
The Solution from Issue https://github.com/FXMisc/RichTextFX/issues/86 would be okay, but does not work anymore.
Is there a new way to do this?
Regards
Yann "Liz3" HN

Yes, the API was changed slightly in WellBehavedFX 0.3, you would now write something like:
InputMap<KeyEvent> im = InputMap.consume(
    EventPattern.keyTyped("\t"),
    e -> area.replaceSelection("    ")
);
Nodes.addInputMap(area, im);

Worked, Thanks!

Using the code above, a tab key yields both a tab and 4 spaces (in that order) being added to the code editor... is there something else I need to do to make sure the tab doesn't get inserted?

Do you also have something for area.setOnKeyTyped()? If so, then that handler will be run, too.
Which version of RTFX are you using?

I'm on 0.8.2.  My whole class is below (no setOnKeyTyped())
import java.util.Collection;
import java.util.Collections;
import java.util.regex.Matcher;
import java.util.regex.Pattern;

import org.fxmisc.richtext.CodeArea;
import org.fxmisc.richtext.LineNumberFactory;
import org.fxmisc.richtext.model.StyleSpans;
import org.fxmisc.richtext.model.StyleSpansBuilder;
import org.fxmisc.wellbehaved.event.EventPattern;
import org.fxmisc.wellbehaved.event.InputMap;
import org.fxmisc.wellbehaved.event.Nodes;

import javafx.scene.input.KeyEvent;

public class ScriptEditorSupport {

    private static final String[] KEYWORDS = new String[] {
        "abstract", "assert", "boolean", "break", "byte",
        "case", "catch", "char", "class", "const",
        "continue", "default", "do", "double", "else",
        "enum", "extends", "final", "finally", "float",
        "for", "goto", "if", "implements", "import",
        "instanceof", "int", "interface", "long", "native",
        "new", "package", "private", "protected", "public",
        "return", "short", "static", "strictfp", "super",
        "switch", "synchronized", "this", "throw", "throws",
        "transient", "try", "void", "volatile", "while"
    };

    private static final String KEYWORD_PATTERN = "\\b(" + String.join("|", KEYWORDS) + ")\\b";
    private static final String PAREN_PATTERN = "\\(|\\)";
    private static final String BRACE_PATTERN = "\\{|\\}";
    private static final String BRACKET_PATTERN = "\\[|\\]";
    private static final String SEMICOLON_PATTERN = "\\;";
    private static final String STRING_PATTERN = "\"([^\"\\\\]|\\\\.)*\"";
    private static final String COMMENT_PATTERN = "//[^\n]*" + "|" + "/\\*(.|\\R)*?\\*/";

    private static final Pattern PATTERN = Pattern.compile(
        "(?<KEYWORD>" + KEYWORD_PATTERN + ")"
            + "|(?<PAREN>" + PAREN_PATTERN + ")"
            + "|(?<BRACE>" + BRACE_PATTERN + ")"
            + "|(?<BRACKET>" + BRACKET_PATTERN + ")"
            + "|(?<SEMICOLON>" + SEMICOLON_PATTERN + ")"
            + "|(?<STRING>" + STRING_PATTERN + ")"
            + "|(?<COMMENT>" + COMMENT_PATTERN + ")");

    private CodeArea codeArea;

    public CodeArea getComponent() {
        if (codeArea != null) return codeArea;

        codeArea = new CodeArea();
        codeArea.setParagraphGraphicFactory(LineNumberFactory.get(codeArea));

        codeArea.richChanges()
            .filter(ch -> !ch.getInserted().equals(ch.getRemoved()))
            .subscribe(change -> {
                codeArea.setStyleSpans(0, computeHighlighting(codeArea.getText()));
            });

        InputMap<KeyEvent> im = InputMap.consume(
            EventPattern.keyTyped("\t"),
            e -> codeArea.replaceSelection("    "));
        Nodes.addInputMap(codeArea, im);

        return codeArea;
    }

    public void setText(String text) {
        getComponent().replaceText(0, getComponent().getText().length(), text);
    }

    public String getText() {
        return getComponent().getText();
    }

    private static StyleSpans<Collection<String>> computeHighlighting(String text) {
        Matcher matcher = PATTERN.matcher(text);
        int lastKwEnd = 0;
        StyleSpansBuilder<Collection<String>> spansBuilder = new StyleSpansBuilder<>();
        while (matcher.find()) {
            String styleClass =
                matcher.group("KEYWORD") != null ? "keyword" : matcher.group("PAREN") != null ? "paren" : matcher.group("BRACE") != null ? "brace" : matcher.group("BRACKET") != null ? "bracket" : matcher.group("SEMICOLON") != null ? "semicolon" : matcher.group("STRING") != null ? "string" : matcher.group("COMMENT") != null ? "comment" : null;
            // never happens
            assert styleClass != null;
            spansBuilder.add(Collections.emptyList(), matcher.start() - lastKwEnd);
            spansBuilder.add(Collections.singleton(styleClass), matcher.end() - matcher.start());
            lastKwEnd = matcher.end();
        }
        spansBuilder.add(Collections.emptyList(), text.length() - lastKwEnd);
        return spansBuilder.create();
    }
}

@cerebrosoft I tested out your above code and can reproduce the issue using the following TestFX test:
import javafx.scene.input.KeyCode;
import org.fxmisc.richtext.InlineCssTextAreaAppTest;
import org.fxmisc.wellbehaved.event.EventPattern;
import org.fxmisc.wellbehaved.event.InputMap;
import org.fxmisc.wellbehaved.event.Nodes;
import org.hamcrest.CoreMatchers;
import org.junit.Test;
import org.testfx.api.FxAssert;
import org.testfx.util.DebugUtils;

public class KeyboardOverrides extends InlineCssTextAreaAppTest {

    @Test
    public void testOverrideTabKeyBehavior() {
        String spaces = "    ";
        interact(() -> {
            Nodes.addInputMap(area,
                    InputMap.consume(
                            EventPattern.keyTyped()
                                // factor out possibility of shift/control/alt being pressed
                                .onlyIf(e -> e.getCharacter().equals("\t")),
                            e -> {
                                area.replaceSelection(spaces);
                                // insure event truly is consumed
                                e.consume();
                            }));
        });

        type(KeyCode.TAB);

        String tabCharReplacement = "#";
        String spaceCharReplacment = "!";

        String actual = area.getText()
                .replace("\t", tabCharReplacement)
                .replace(" ", spaceCharReplacment);
        String expected = spaces
                .replace(" ", spaceCharReplacment);

        FxAssert.verifyThat(expected, CoreMatchers.equalTo(actual),
                DebugUtils.informedErrorMessage("Context", false, true, this, true, true));
    }
}

This outputs the following error message:
java.lang.AssertionError:
Expected: "#!!!!"
     but: was "!!!!"

   Context
      Keys pressed at test failure:
      Mouse Buttons pressed at test failure:
      Fired events since test began:
         WindowEvent [source = javafx.stage.Stage@366e2eef, target = javafx.stage.Stage@366e2eef, eventType = WINDOW_SHOWING, consumed = false]
         WindowEvent [source = javafx.stage.Stage@366e2eef, target = javafx.stage.Stage@366e2eef, eventType = WINDOW_SHOWN, consumed = false]
         MouseEvent [source = javafx.stage.Stage@366e2eef, target = javafx.scene.Scene@6df97b55, eventType = MOUSE_ENTERED_TARGET, consumed = false, x = 318.0, y = 64.0, z = 0.0, button = NONE, pickResult = PickResult [node = InlineCssTextArea@7081a20e[styleClass=root styled-text-area], point = Point3D [x = 318.0, y = 64.0, z = 0.0], distance =<PHONE_NUMBER>137755]
         MouseEvent [source = javafx.stage.Stage@366e2eef, target = InlineCssTextArea@7081a20e[styleClass=root styled-text-area], eventType = MOUSE_ENTERED_TARGET, consumed = false, x = 318.0, y = 64.0, z = 0.0, button = NONE, pickResult = PickResult [node = InlineCssTextArea@7081a20e[styleClass=root styled-text-area], point = Point3D [x = 318.0, y = 64.0, z = 0.0], distance =<PHONE_NUMBER>137755]
         MouseEvent [source = javafx.stage.Stage@366e2eef, target = VirtualFlow@6ffe1684[styleClass=virtual-flow], eventType = MOUSE_ENTERED_TARGET, consumed = false, x = 318.0, y = 64.0, z = 0.0, button = NONE, pickResult = PickResult [node = Navigator@42e115e7, point = Point3D [x = 318.0, y = 64.0, z = 0.0], distance =<PHONE_NUMBER>137755]
         MouseEvent [source = javafx.stage.Stage@366e2eef, target = Navigator@42e115e7, eventType = MOUSE_ENTERED_TARGET, consumed = false, x = 318.0, y = 64.0, z = 0.0, button = NONE, pickResult = PickResult [node = Navigator@42e115e7, point = Point3D [x = 318.0, y = 64.0, z = 0.0], distance =<PHONE_NUMBER>137755]
         KeyEvent [source = javafx.stage.Stage@366e2eef, target = InlineCssTextArea@7081a20e[styleClass=root styled-text-area], eventType = KEY_PRESSED, consumed = false, character =  , text = 	, code = TAB]
         KeyEvent [source = javafx.stage.Stage@366e2eef, target = InlineCssTextArea@7081a20e[styleClass=root styled-text-area], eventType = KEY_TYPED, consumed = false, character = 	, text = , code = UNDEFINED]
         KeyEvent [source = javafx.stage.Stage@366e2eef, target = InlineCssTextArea@7081a20e[styleClass=root styled-text-area], eventType = KEY_RELEASED, consumed = false, character =  , text = 	, code = TAB] <Click to see difference>

	at org.testfx.api.FxAssert.verifyThatImpl(FxAssert.java:223)
	at org.testfx.api.FxAssert.verifyThat(FxAssert.java:68)
	at org.fxmisc.richtext.override.KeyboardOverrides.testOverrideTabKeyBehavior(KeyboardOverrides.java:39)

I'm honestly baffled why it doesn't work. I initially thought the issue was with WellBehavedFX not consuming the event for some reason. However, then I added the KeyEvent#consume() method in the overriding InputMap. The output showed that, whether the method is included or not, the event is never consumed. I'm guessing this is a JDK bug? I ran the tests using:
java version "1.8.0_161"
Java(TM) SE Runtime Environment (build 1.8.0_161-b12)
Java HotSpot(TM) 64-Bit Server VM (build 25.161-b12, mixed mode)

@liz3 Since you said my solution worked, which OS are you using?
I'm using Linux Mint 18.3. @cerebrosoft, what's your OS?

Thanks for looking into this- I'm on a Windows 10 box.

Thanks for your response. Let's continue the discussion in #707.

@cerebrosoft I finally figured out what was causing the issue :man_facepalming:
The default behavior uses
InputMapTemplate.consume(
   EventPattern.keyPressed(KeyCode.TAB),
   (behavior, keyevent) -> behavior.getView().replaceSelection("\t")
);

I mislead you and @liz3 by saying the EventPattern needed to be EventPattern.keyTyped("\t"). This actually doesn't override the default behavior (keyTyped vs keyPressed). I have since corrected my original answer to her question.


Add Odd Even Linked List Question of Leetcode

Is your feature request related to a problem? Please describe.
I would like to add Odd Even Linked List of Leetcode(Medium)
Describe the solution you'd like
I would like to code the solution of this question in cpp

/assign

@Saviour1001 May you please add other appropriate labels to this issue

Done, and BTW the labels on Issues don't matter, they are just there for the mentors and admin's reference. The labels on PRs matter.

Done, and BTW the labels on Issues don't matter, they are just there for the mentors and admin's reference. The labels on PRs matter.

Thank you @Saviour1001.
Is there any way this process of adding appropriate labels can also be automated by using checkbox type of thing in Issue template
It will then be convenient for project Admin and mentor also.

@Anupam-Panwar The current workflows give the tags of DCP21 and assigns you the issues. As the levels tags and language tags are given to PRs by the admins only, so we thought of having this system. Still will tinker on your thoughts and will upgrade.


Issues with Invoke-ScriptInNavContainer New-BCContainer

Setup:
Docker Desktop: <IP_ADDRESS>
Navcontainerhelper: <IP_ADDRESS>
OS: Windows 10 Pro
Creating a container using:
New-BCContainer -accept_eula -accept_outdated -containerName BC -imageName mcr.microsoft.com/businesscentral/sandbox:14.0.29537.0-w1 -licenseFile .\Licenses\MyLicense.flf -includeAL -includeCSide -updateHosts -auth UserPassword
Outcome:
`NavContainerHelper is version <IP_ADDRESS>
NavContainerHelper is running as administrator
Host is Microsoft Windows 10 Pro - ltsc2019
Docker Client Version is 19.03.5
Docker Server Version is 19.03.5
Using image mcr.microsoft.com/businesscentral/sandbox:14.0.29537.0-w1-ltsc2019
Creating Container BC
Version: 14.0.29537.0-W1
Style: sandbox
Platform: 14.0.29530.0
Generic Tag: <IP_ADDRESS>
Container OS Version: 10.0.17763.379 (ltsc2019)
Host OS Version: 10.0.17763.1039 (ltsc2019)
WARNING: The container operating system matches the host operating system, but the revision is different.
If you encounter issues, you might want to specify -isolation hyperv
Using locale en-US
Using process isolation
Disabling the standard eventlog dump to container log every 2 seconds (use -dumpEventLog to enable)
Using license file .\Licenses\MyLicense.flf
Files in C:\ProgramData\NavContainerHelper\Extensions\BC\my:

AdditionalOutput.ps1
AdditionalSetup.ps1
license.flf
MainLoop.ps1
SetupVariables.ps1
SetupWebClient.ps1
updatehosts.ps1
Creating container BC from image mcr.microsoft.com/businesscentral/sandbox:14.0.29537.0-w1-ltsc2019
18914ea02f1c0dc501689d8b0311dcc528c6988ec7dedfe56bfba01ee69845cc
Waiting for container BC to be ready
Initializing...
Setting host.containerhelper.internal to <IP_ADDRESS> in container hosts file (copy from host hosts file)
Setting host.docker.internal to <IP_ADDRESS> in container hosts file (copy from host hosts file)
Setting gateway.docker.internal to <IP_ADDRESS> in container hosts file (copy from host hosts file)
Setting kubernetes.docker.internal to <IP_ADDRESS> in container hosts file (copy from host hosts file)
Starting Container
Hostname is BC
PublicDnsName is BC
WARNING: DNS resolution not working from within the container.
Using NavUserPassword Authentication
Starting Local SQL Server
Starting Internet Information Server
Creating Self Signed Certificate
Self Signed Certificate Thumbprint 58E07A09F1BB936C7F1979A4FD6318B42B363E2F
Modifying Service Tier Config File with Instance Specific Settings
Starting Service Tier
Registering event sources
Creating DotNetCore Web Server Instance
Enabling Financials User Experience
Using license file 'c:\run\my\license.flf'
Import License
Creating http download site
Creating Windows user dev
Setting SA Password and enabling SA
Creating dev as SQL User and add to sysadmin
Creating SUPER user
Container IP Address: <IP_ADDRESS>
Container Hostname  : BC
Container Dns Name  : BC
Web Client          : http://BC/NAV/
Dev. Server         : http://BC
Dev. ServerInstance : NAV
Setting BC to <IP_ADDRESS> in host hosts file

Files:
http://BC:8080/al-3.0.106655.vsix
WARNING: You are running a container which is 335 days old.
Microsoft recommends that you always run the latest version of our containers.
Initialization took 136 seconds
Ready for connections!
Reading CustomSettings.config from BC
Creating Desktop Shortcuts for BC
**Export Objects with filter 'Id=1..1999999999' to C:\ProgramData\NavContainerHelper\Extensions\Original-14.0.29537.0-W1\objects.txt (container path)
!
at Export-NAVApplicationObject, C:\Program Files (x86)\Microsoft Dynamics NAV\140\RoleTailored Client\Microsoft.Dynamics.Nav.Ide.psm1: line 355
at , : line 51
!
At C:\Program Files\WindowsPowerShell\Modules\navcontainerhelper\<IP_ADDRESS>\ContainerHandling\Invoke-ScriptInNavContainer.ps1:37 char:13

        Invoke-Command -Session $session -ScriptBlock $scriptbloc ...

        ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

CategoryInfo          : NotSpecified: (:) [Write-Error], WriteErrorException
FullyQualifiedErrorId : Microsoft.PowerShell.Commands.WriteErrorException,Export-NAVApplicationObject
PSComputerName        : 18914ea02f1c0dc501689d8b0311dcc528c6988ec7dedfe56bfba01ee69845cc**`

Tried reinstalling navcontainerhelper, same issue. License is ok, did not expire or similar.
error
Any suggestions? (Sorry for bad formatting of output)

Rookie mistake - using -isolation hyperv solves the problem.
Though I'm still a bit confused since I never had to use it before. Anyhow, my mistake.

Had a similar issue, great work @mattiasboustedt.

This is due to the february update: https://freddysblog.com/2020/02/14/hyperv-isolation-to-the-rescue/
Note though that when you are using C/AL (export objects), this might cause issues with hyperv.
I am working on a more permanent solution to this problem, should be out later today.

More information here: http://freddysblog.com/2020/02/26/the-world-after-february-18th/

NavContainerHelper <IP_ADDRESS> has shipped.


[WIP] [#353] Adds a simple approach to normalize study_phase values

We opted to implement a solution based on a CSV file representing a two-way table(variation and its normalization). This file is accessed in order to match a phase variation
with its normalized forms.
Since a Trial may be in one or more Phases simutaneously and, as it was suggested,we decided that the return of the method should be an array of phases.
However, 'knex' does not support said type so we decided to alter the type of the 'study_phase' column to 'jsonb'.
With this solution, whenever a new variation arrives the CSV file needs to be updated.
Furthermore, a new schema file was generated, updating tests/dbs.
With these modifications, changes were needed on the Api repository. In which the migration and seeds were updated, generating another PR.

About using jsonb instead of text[], have you tried using table.specificType('study_phase', 'text[]')? If so, did you have any problems with it?

Yes, we did and it works fine.
Acctually, we have already made the changes and we're going to commit them soon.

@arthurSena thanks for the PR and congratulations on your first code merged :beers:
Looking forward for the next ones :smile:


HTTP Generic Connector supports URL parameter injection

Connected to #1290

modified 'renderHeader' function to allow rendering of multiple input fields of the same type

Moved the validation and saving of template strings to its own function to reduce code reuse

Added support for passing query parameters through a secretless configuration file, and appending them to the url in the http request

Added unit tests for parsing of query params

@BradleyBoutcher please use the PR template next time, it's really handy to make sure we're adding adequate tests, docs, and change log messages with each PR.


Support NTLM Authentication across the board

Both Domain and Local host authentication

What's the blocker on this?

fixed via #144


Add documentation about streaming response

Thanks, all fixed. 😉

@freevie Could you review this PR if you get a chance? 😆


Fixed Cookie::$sameSite description link and added Cookie::SAME_SITE_NONE

Q
A

Is bugfix?
❌

New feature?
✔(sort of)

Breaks BC?
❌

Tests pass?
✔

Fixed issues
-

The old OWASP link in the Cookie::$sameSite was no longer working.
Added missing constant Cookie::SAME_SITE_NONE

@samdark Does this require a line in the changelog?

Yes. Also it requires a @since tag for the new constant.

Thanks.


Finalize the application form fields and logic

The following information must be finalized for the application form to be completed.

What is the residence radius we are looking for? Eventually, we need the list of city IDs we allow the applicant to be able to apply from. Even if we are to use Google map APIs, we need the city IDs for data persistence of the applicant
We need the finalized content text. "By checking this box, I agree to the Terms of Use and Privacy Policy (unless I am under the age of 18, in which case, I represent that my parent or legal guardian also agrees to the Terms of Use on my behalf)"
Can we have 3 sets of logic questions and not just 2. The plan is to have the questions in the DB as sets and play to the students and auto-mark based on the responses. This is based on a DB model and a data service.
Can we move on to the essay section only if the student score more than 50% (or a similar %) for the logic section?
Can we move on to the video section only if the two essays are good enough?
What is the approach to auto-rate the essays?
Can we provision that students submit the video only when they are for at a later stage?
Can we assume that the email is the user ID for account creation? Email should be universally unique
What are the application LC and states we want to show the student applicant on the application portal?
What is the finalized list of education qualifications we need to capture?
What is the  evaluation data model we want to use?
What is the  qualification data model we want to use?
What is the process for informing and inviting for interviews? What are the features we need from the portal for that? (That is part of the application LC)

I think we were looking at 30mins distance (car on google maps) - but I guess you need the cities/towns mapped for this? We can discuss today
Yes, let's do that today.
Agree to 3 sets of logic qs
Yes, that's a good idea
I think that will help with filtering and volume of videos to assess
We can discuss this today
Yes, agree
Yes, we can add a note regarding that
9.-13 - we can discuss today and add a finalised doc here.

flowchart TD
    A((Start))

To answer some of the questions:
3. Yes
4. No, I think this fundamentally goes against our principle of holistically evaluating each student application.
5. No, same reason as #4
6. TBD; likely no for this round
7. No, we will need all information to make the interview/no interview decision

@samisa-abeysinghe I don't think that we should be arbitrarily cutting off on a "pass mark" at all. A holistic application means that we evaluate the entire packet, so we shouldn't have a policy-level cutoff as such. We can build in filtering and sorting to the evaluation UI to streamline the process on our (admissions team) end.

To answer some of the questions: 3. Yes 4. No, I think this fundamentally goes against our principle of holistically evaluating each student application. 5. No, same reason as #4 6. TBD; likely no for this round 7. No, we will need all information to make the interview/no interview decision

Noted and updated the flowchart

@samisa-abeysinghe I don't think that we should be arbitrarily cutting off on a "pass mark" at all. A holistic application means that we evaluate the entire packet, so we shouldn't have a policy-level cutoff as such. We can build in filtering and sorting to the evaluation UI to streamline the process on our (admissions team) end.

Fixed in flowchart


Setting up Constrained Notification Handler example for Simple Injector.

I edited the example Simple Injector registrations to get a Y for Constrained Notification Handler.
This should be a recommended way to automatically register generic types in RegisterCollection as the same approach is mentioned in Simple Injector documentation  (see last code snippet in the section).

Thanks! Feel free to change the wiki, too.

Cool, wiki's now updated as well:
https://github.com/jbogard/MediatR/wiki/Container-Feature-Support/_compare/adaaabce0028ee589908b89767ac77c739acb63d...934c27f3aeb8619d6b1c52adfc198ff724734c62?diff=split&short_path=40f20bb


Add AlphaMask2d phase

Objective

Bevy now supports an opaque phase for mesh2d, but it's very common for 2d textures to have a transparent alpha channel.

Solution

Add an alpha mask phase identical to the one in 3d. It will do the alpha masking in the shader before drawing the mesh.
Uses the BinnedRenderPhase
Since it's an opaque draw it also correctly writes to depth

Testing

Tested the mes2d_alpha_mode example and the bevymark example with alpha mask mode enabled

Showcase

The white logo on the right is rendered with alpha mask enabled.
Running the bevymark example I can get 65fps for 120k mesh2d all using alpha mask.
Notes
This is one more step for mesh2d improvements https://github.com/bevyengine/bevy/issues/13265

I added the blocked label because I need to implement the MAY_DISCARD shader def


Optionally Hide the Key Icon

In some circumstances you may want to hide the key icon despite it's excellent value to users.
Eg when showing a bundle of small icons for one field (eg the products that the Account has purchased over the lifetime). It may be overkill to show the Bundle Icon, Bundle Title and Text, so the key may not be necessary also.
The Key uses the standard SLDS Card Actions Slot for the location, and that takes up the same vertical space as the Title.
If there are any other options to keep The Key and display a Card with no Title or Icon then it would be great to pursue it.

During the Oct-2023 Sprint, we discussed the alternative of being able to configure where the help icon appeared; either top right or bottom center.
We need to mock up what bottom center would look like to decide if that's best.

Note this would not be needed anymore if #172 is approved.


refactor(streaming): unify rate limiter and related components design

Signed-off-by: MrCroxx<EMAIL_ADDRESS>hereby agree to the terms of the RisingWave Labs, Inc. Contributor License Agreement.
What's changed and what's your intention?
Changes:

Introduce unified RateLimit, RateLimiter, and MonitoredRateLimiter.
RateLimiter follows interior mutability design, and supports online rate limit policy updates.

Remains:

*.proto files are still using the old design, I'll update it in another PR to keep changes easy for reviews.

Related:
#19857

Checklist

[ ] I have written necessary rustdoc comments.
[ ]  I have added necessary unit tests and integration tests.
[ ]  I have added test labels as necessary.
[ ]  I have added fuzzing tests or opened an issue to track them.
[ ]  My PR contains breaking changes.
[ ]  My PR changes performance-critical code, so I will run (micro) benchmarks and present the results.
[ ]  My PR contains critical fixes that are necessary to be merged into the latest release.

Documentation

[ ]  My PR needs documentation updates.

Release note

Sometimes rate limit basic slt failed because of timeout.
https://github.com/risingwavelabs/risingwave/blob/794afcb784405385e0c283c6f8ead90b559cd728/e2e_test/streaming/rate_limit/basic.slt#L40-L41
This line may backfill the tombstones?


Plasmic can't create PR after moving to organization

It looks like the step in the Github action generates this error
https://github.com/repo-sync/pull-request/issues/76
So there's no PR in created. We'll have to work around this.

This was resolved by using a custom webhook instead of the GitHub app integration.


Windows 20240414.1.0 regression over 20240322.1.0: permission denied

Description
Installing Haskell build-tools (alex, happy) during a Stack build process on Windows is suddenly failing with "permission denied": 20240414.1.0 regression over 20240322.1.0.
Did the filesystem access rights change?
Extra info: The location is under C:\sr as created by https://github.com/haskell-actions/setup.
See https://github.com/agda/agda/actions/runs/8733365593/job/23961919676#step:1:37:

Download action repository 'haskell-actions/setup@v2' (SHA:ca7ecf7b0c7a4300227b1ab05cda52bf019c174b)

(The version of haskell-action/setup did not change, see https://github.com/agda/agda/actions/runs/8509770751/job/23306000462#step:1:36.)
Platforms affected

[ ] Azure DevOps
[ ] GitHub Actions - Standard Runners
[ ] GitHub Actions - Larger Runners

Runner images affected

[ ] Ubuntu 20.04
[ ] Ubuntu 22.04
[ ] macOS 11
[ ] macOS 12
[ ] macOS 13
[ ] macOS 13 Arm64
[ ] macOS 14
[ ] macOS 14 Arm64
[ ] Windows Server 2019
[X] Windows Server 2022

Image version and build link
20240414.1.0
https://github.com/agda/agda/actions/runs/8733365593/job/23961919676#step:10:1402
Is it regression?
Yes, worked with 20240322.1.0, see https://github.com/agda/agda/actions/runs/8509770751/job/23306000462#step:10:1384
Expected behavior
Stack copying bins to C:\sr\snapshots\dd11c2a9\bin should succeed.
Actual behavior
Stack copying bins to C:\sr\snapshots\dd11c2a9\bin fails with "permission denied".
Repro steps
Well, I reproduced this in the public agda/agda repo (see links).
Let me know if you need a stand-alone reproducer.
Downstream issue:

https://github.com/agda/agda/issues/7232

Let me investigate this further for a bit.  Closing for now, might reopen.


Bug: Markdown exportTextFormat treats literal string as regex

Steps To Reproduce

On https://playground.lexical.dev/, clear the text area and enter the string $$.
Click Markdown export button.

The current behavior
$$ is exported as $
The expected behavior
$$ is exported as $$
The bug is here:
https://github.com/facebook/lexical/blob/716d409085e44fb7ab47a35d517e39623b4a5fc0/packages/lexical-markdown/src/MarkdownExport.ts#L168
String.prototype.replace is used for literal string replacement. In that context, "$$" in the replacement string inserts a single "$", as described here
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/replace#specifying_a_string_as_the_replacement
It can be fixed with this diff:
-  return textContent.replace(frozenString, output);
+  return textContent.split(frozenString).join(output);

Can't reproduce


fix: Don't register spiffe token provider service

go-mod-bootstrap only allows registration of HTTP healtchecks with consul, which will not work for this service, as it requires clients have a client TLS certificate.  In any case, registration is not required for proper functioning of the service
Closes #4531
PR Checklist
Please check if your PR fulfills the following requirements:

[X] I am not introducing a breaking change (if you are, flag in conventional commit message with BREAKING CHANGE: describing the break)
[X] I am not introducing a new dependency (add notes below if you are)
[ ] I have added unit tests for the new feature or bug fix (if not, why?)
[X] I have fully tested (add details below) this the new feature or bug fix (if not, why?)
[ ] I have opened a PR for the related docs change (if not, why?)

Testing Instructions
This service never runs in secure mode and thus embedded CMD is never exercised.
Actually fixed by edgex-compose#375, but this corresponding change is made for conistency.
New Dependency Instructions (If applicable)

Codecov Report

Merging #4536 (d3551e8) into main (824c097) will not change coverage.
The diff coverage is n/a.

:mega: This organization is not using Codecov’s GitHub App Integration. We recommend you install it so Codecov can continue to function properly for your repositories. Learn more
@@           Coverage Diff           @@
##             main    #4536   +/-   ##
=======================================
  Coverage   41.53%   41.53%
=======================================
  Files         106      106
  Lines        9766     9766
=======================================
  Hits         4056     4056
  Misses       5364     5364
  Partials      346      346


systemd: Restore access to TTYs for reboot delay

When sessions are active, locksmith write a message to the TTYs of the sessions and then delays the reboot for 5 minutes to give the user time to stop the reboot or finish the work.
The commit for cgroup memory and CPU limits also brought in a change to disallow /dev/tty* access which broke the delay for console users except SSH sessions which are under /dev/pts/*.
Allow device access to have a delay of 5 minutes when sessions are active. This includes the autologin session even if no interaction was done there recently. Still, the reboot delay doesn't hurt and since update-engine has a random delay for pulling updates, there is no big difference in the end.
How to use
Update ref in ebuild
Testing done
In the demo @tormath1 prepared, locksmith didn't wait. We looked at the possible issue and found this.
I just tried echo A >> /dev/tty1 with sudo systemd-run -S -P --property=PrivateDevices=true -G and it failed while it works with PrivateDevices=false, so I think this will fix the issue. @tormath1 did a test with PrivateDevices=true removed and the delay worked.

[ ] Changelog entries added in the respective changelog/ directory (user-facing change, bug fix, security fix, update)
[ ] Inspected CI output for image differences: /boot and /usr size, packages, list files for any missing binaries, kernel modules, config files, kernel modules, etc.

I thought about keeping the block devices unavailable but the commit introducing it wasn't really aimed at providing a security benefit and if we want to go this route we should also not leave the whole root partition writable.

DeviceAllow=/dev/tty*

The suggestion doesn't work  yet, /dev/tty1: Operation not permitted


Logitech Options+ available

Logitech released Logitech Options+ software for newer devices with Logitech Bolt adapter.
https://download01.logi.com/web/ftp/pub/techsupport/optionsplus/logioptionsplus_installer.zip
See website for more infos:
https://www.logitech.com/de-de/software/logi-options-plus.html

Download has a installer embedded

--quiet for silent install
/logioptionsplus_installer.app/Contents/MacOS/logioptionsplus_installer --quiet

Also has a keystroke warning that users need to accept.
I'll look into seeing if Installomator supports installing from a binary and passing arguments


Dotless outputting garbage when formatString missing arguments

If formatString specifies one or more {n} arguments and those arguments are not provided following the format string, the compiler outputs garbage (i.e. a whole lot of unreadable unicode characters). While the fix is to actually specify the arguments, figuring out that this is the problem is painful when the compiler spits out unreadable text instead of an error message.
The following should reproduce the problem:
.icon(@name) { background-image: formatString("url({0}images/icons/brand/32/{1}.png"); }
.myclass { .icon("facebook"); }

This should be fixed on main / 1.2.2 - or at least better. Please re-open if this is still causing an issue.


Unset Device Tokens

I have a use case for "unsetting" device tokens via the iOS sdk. We have log-in and log-out functionality in our app. It's possible for a user to log-in with account X, log-out of that account, and then log in with account Y (all on the same device).
I would like to be able to unregister the deviceToken for account X when they log-out.

Is there a status update to this?

This can be easily accomplished by calling unset: and passing @"$ios_devices" however, I can see how this would be really useful for people so I added removePushDeviceToken to the public API. This will be usable in next release, 2.9.2.
#419

I Sam, thanks for the addition. The code seems to be removing all the tokens. If my user is logged in on 2 devices, and logs out from device A, he is still logged in on a device B so he should still receive the notification, so Mixpanel's should only remove the current device token from the array of device token.

@alpennec Currently there is no API to remove a a specific value from a List property. See @samgreen 's comment here: https://github.com/mixpanel/mixpanel-iphone/pull/419#issuecomment-174096297


Archived acquisitions don't affect session template compliance

Fixes #885
Review Checklist

Tests were added to cover all code changes
Documentation was added / updated
Code and tests follow standards in CONTRIBUTING.md

LGTM!


[WIP] - initial version of Salvador spider

For older gazettes, they have the interesting habit to put the file from a different date.
It is also not possible to discover if it is an extra edition without parsing the gazette content. It will require a custom pipeline (specific to this city) to process the file content after it passes through PdfParsingPipeline .

The date is not wrong. I discovered that some gazettes are related to more than one day (for example http://www.dom.salvador.ba.gov.br/index.php?option=com_content&view=article&id=5815:dom-7118&catid=1:dom). Updated the spider to handle this situation (unfortunately it will require an extra request for each gazette).

To identify extra editions we need to parse the content of the PDF. Unfortunately, when converted, the information is not well structured, so I included a regex that for the gazettes that I saw is enough to make the classification. However it is not 100% guaranteed.

Remember to update the cities.md


Updating library build tools and flash match

This PR has a large amount of modified files.

in LibraryBuildTools: this folder was really outdated. Fhicl files for generating libraries were returning empty trees, for instance. All fhicls were moved to a new folder (legacy) for historical reasons. The submit file was also updated and a new fhicl was included for generating a test library (protodunehd).
in the FlashMatch algorithm: some modifications were made in order to get the energy deposition by the particle of interest in the presence of backgrounds. New fhicl parameters were included to handle different primary particles and also NDK events when they are generated with the @local::standard_ndk module (since they are labelled as unknown type). Also, another fhicl parameter was included to allow the analyzer to record flashes from events with vertex located between the field cage and cryostat wall in FD2-VD (currently used in SNB analysis). The FlashMatch fhicl file was updated and VD specific names and parameters were included. The fhicl files in dunesw will be updated to use the new definitions (and removing additional parameters put by hand in them) once this PR is merged not to cause any disruption. HD fhicls will not have to be modified.

trigger build

trigger build

:heavy_check_mark: CI build for LArSoft Succeeded on slf7 for c7:prof -- details available through the CI dashboard

:heavy_check_mark: CI build for LArSoft Succeeded on slf7 for e20:prof -- details available through the CI dashboard

:warning: CI build for DUNE Warning at phase ci_tests DUNE on slf7 for c7:prof -- details available through the CI dashboard
:rotating_light: For more details about the warning phase, check the ci_tests DUNE phase logs
parent CI build details are available through the CI dashboard

:heavy_check_mark: CI build for DUNE Succeeded on slf7 for e20:prof -- details available through the CI dashboard
parent CI build details are available through the CI dashboard

@lpaulucc Hi Laura, is this ready to be merged in?

Hi Jake, yes, it can be merged. Thanks!


PRM acquisition mode

Good afternoon everyone,
Not sure if I am at the good place to ask this question.
I have lc data that were acquired on orbitrape in prm mode.
I canot find anything on this mode.
Thanks!

Please find some details about the PRM mode (for targeted analysis) on the Qexactive (Thermo). Here the link if you can't access the shared pdf : https://assets.thermofisher.com/TFS-Assets/CMD/Reference-Materials/wp-65147-ms-q-exactive-orbitrap-scan-modes-wp65147-en.pdf
I was looking to have access to the data of my targeted lists. When I import a .raw in full ms msd2 it opens on the usual page but when  do it with my .raw in PRM the page is blank. Like this mode is not taken in account. But if I am correct DIA is.
Thanks.
Envoyé à partir de Outlook pour iOShttps://aka.ms/o0ukef

De : Steffen Heuckeroth @.>
Envoyé : Wednesday, February 7, 2024 4:03:22 AM
À : mzmine/mzmine3 @.>
Cc : Nicolle, Pamela @.>; Author @.>
Objet : Re: [mzmine/mzmine3] PRM acquisition mode (Issue #1636)
Vous ne recevez pas souvent de courriers de la part de @.*** Découvrez pourquoi cela est importanthttps://aka.ms/LearnAboutSenderIdentification
Attention
L’émetteur de ce courriel est externe à l’Université du Québec en Outaouais.
Hi Pamou,
we'll need a bit more information than that.
what do you want to do with the data?
I don't know how the prm mode works on the orbitrap. What is actually acquired?
—
Reply to this email directly, view it on GitHubhttps://github.com/mzmine/mzmine3/issues/1636#issuecomment-1931480693, or unsubscribehttps://github.com/notifications/unsubscribe-auth/BF6PV5GTTX4TRTGNUI2ESMDYSMYMVAVCNFSM6AAAAABC4RI662VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTSMZRGQ4DANRZGM.
You are receiving this because you authored the thread.Message ID: @.***>

Hi,
if i read it correctly the prm mode does not inlcule MS1 scans?
Then i think you can use one of the the MSn feature detection modules. regular processing is not possible then.


Allow ignoring properties that are not mapped directly

I have a SavedPost class generated by my ORM client that represents a row in the database, and a couple of model classes that represent API responses and are nearly identical to these generated classes. Trying to map between them is proving to be a challenge due to the plugin seemingly requiring that every property in the source class has a mapping in the destination. Here's what I'm trying to do:
// "Source" class being generated by the ORM

public data class SavedPost(
  public val shortId: String,
  public val title: String,
  public val url: String,
  public val createdAt: String,
  public val commentCount: Int?,
  public val commentsUrl: String,
  public val submitterName: String,
  public val submitterAvatarUrl: String,
  public val tags: List<String>,
  public val description: String,
)

// "Target" class hand-written by me, used to model the API response
class LobstersPost(
  val shortId: String,
  val createdAt: String,
  val title: String,
  val url: String,
  val description: String,
  val commentCount: Int,
  val commentsUrl: String,
  @SerialName("submitter_user") val submitter: User,
  val tags: List<String>,
) {

  // How I'm trying to use Konvert
  @KonvertFrom(
    value = SavedPost::class,
    mappings =
      [
        Mapping(source = "submitterName", target = "submitter.username"),
        Mapping(source = "submitterAvatarUrl", target = "submitter.avatarUrl"),
      ],
  )
  companion object
}

As you can see, to simplify database storage I flattened out some nested fields which can be filled back in easily from the object received in the API response, but since the submitter object itself does not get mapped into a property in the SavedPost class I get an error like this from the processor:
e: [ksp] io.mcarle.konvert.processor.exceptions.PropertyMappingNotExistingException: No property for valueParameter=submitter existing in [PropertyMappingInfo(mappingParamName=savedPost, sourceName=submitterName, targetName=submitter.username, constant=null, expression=null, ignore=false, enableConverters=[], declaration=submitterName, isBasedOnAnnotation=true), PropertyMappingInfo(mappingParamName=savedPost, sourceName=submitterAvatarUrl, targetName=submitter.avatarUrl, constant=null, expression=null, ignore=false, enableConverters=[], declaration=submitterAvatarUrl, isBasedOnAnnotation=true), PropertyMappingInfo(mappingParamName=savedPost, sourceName=commentCount, targetName=commentCount, constant=null, expression=null, ignore=false, enableConverters=[], declaration=commentCount, isBasedOnAnnotation=false), PropertyMappingInfo(mappingParamName=savedPost, sourceName=commentsUrl, targetName=commentsUrl, constant=null, expression=null, ignore=false, enableConverters=[], declaration=commentsUrl, isBasedOnAnnotation=false), PropertyMappingInfo(mappingParamName=savedPost, sourceName=createdAt, targetName=createdAt, constant=null, expression=null, ignore=false, enableConverters=[], declaration=createdAt, isBasedOnAnnotation=false), PropertyMappingInfo(mappingParamName=savedPost, sourceName=description, targetName=description, constant=null, expression=null, ignore=false, enableConverters=[], declaration=description, isBasedOnAnnotation=false), PropertyMappingInfo(mappingParamName=savedPost, sourceName=shortId, targetName=shortId, constant=null, expression=null, ignore=false, enableConverters=[], declaration=shortId, isBasedOnAnnotation=false), PropertyMappingInfo(mappingParamName=savedPost, sourceName=submitterAvatarUrl, targetName=submitterAvatarUrl, constant=null, expression=null, ignore=false, enableConverters=[], declaration=submitterAvatarUrl, isBasedOnAnnotation=false), PropertyMappingInfo(mappingParamName=savedPost, sourceName=submitterName, targetName=submitterName, constant=null, expression=null, ignore=false, enableConverters=[], declaration=submitterName, isBasedOnAnnotation=false), PropertyMappingInfo(mappingParamName=savedPost, sourceName=tags, targetName=tags, constant=null, expression=null, ignore=false, enableConverters=[], declaration=tags, isBasedOnAnnotation=false), PropertyMappingInfo(mappingParamName=savedPost, sourceName=title, targetName=title, constant=null, expression=null, ignore=false, enableConverters=[], declaration=title, isBasedOnAnnotation=false), PropertyMappingInfo(mappingParamName=savedPost, sourceName=url, targetName=url, constant=null, expression=null, ignore=false, enableConverters=[], declaration=url, isBasedOnAnnotation=false)]

At the moment Konvert does not offer this "dot syntax" in source and target.
Instead you can use a custom expression for now:
@KonvertFrom(
  value = SavedPost::class,
  mappings = [
    Mapping(
      target = "submitter",
      expression = "package.of.User(username = it.submitterName, avatarUrl = it.submitterAvatarUrl)"
    )
  ]
)
companion object

This will generate the following:
fun LobstersPost.Companion.fromSavedPost(savedPost: SavedPost): LobstersPost = LobstersPost(
  // other mappings,
  submitter = savedPost.let {
    package.of.User(username = it.submitterName, avatarUrl = it.submitterAvatarUrl)
  },
  // other mappings
)

You can also create a function which does the "complex" mapping stuff:
package package.of

fun userFromSavedPost(savedPost: SavedPost) = User(
   username = it.submitterName,
   avatarUrl = it.submitterAvatarUrl
)

and then call that function instead inside the expression:
@KonvertFrom(
  value = SavedPost::class,
  mappings = [
    Mapping(
      target = "submitter",
      expression = "package.of.userFromSavedPost(it)"
    )
  ]
)
companion object

This way, refactoring etc. will work more reliably. Only if you rename or move the function, you will have to change it in the expression as well, otherwise you will get an error after Konvert generated the mapping sources and during their compile-time.
Hope this helps for now?

Okay reading back the OP it looks like I was trying to misuse Konvert and ended up confusing myself. What I wanted to do is to convert instances of LobstersPost and LobstersPostDetails to SavedPost, but KonvertFrom is actually meant for mapping in the opposite direction. I tried doing the same using KonvertTo but I get a different failure:
class LobstersPost(
  val shortId: String,
  val createdAt: String,
  val title: String,
  val url: String,
  val description: String,
  val commentCount: Int,
  val commentsUrl: String,
  @SerialName("submitter_user") val submitter: User,
  val tags: List<String>,
) {
  @KonvertTo(
    value = SavedPost::class,
    mappings =
      [
        Mapping(
          target = "submitter",
          expression = "dev.msfjarvis.claw.serialization.userFromSavedPost(it)"
        )
      ],
  )
  companion object
}

e: [ksp] java.lang.IllegalStateException: Mapping can only target classes and companion objects

The error message is a bit off, I will fix this... But the annotation @KonvertTo can only be applied to classes:
@KonvertTo(
    value = SavedPost::class,
    mappings =
      [
        Mapping(
          target = "submitter",
          expression = "dev.msfjarvis.claw.serialization.userFromSavedPost(it)"
        )
      ],
  )
class LobstersPost(
 // ...
)

Thanks for the help! I was able to make everything work and delete my manual mapping functions https://msfjarvis.dev/g/compose-lobsters/25382acf0eaa


lapce panics on start

Lapce Version
I've tried both, one compiled from git repo ( lapce-9999-r4 on my Gentoo) and the binary that I downloaded from your site.
Both panic at the same spot
System information
Gentoo, profile default/linux/amd64/23.0/hardened/selinux
Using sway+wayland on radeon graphics (amdgpu)
Describe the bug
lapce silently panics on start.
I compiled it in debug mode and left binaries unstripped, so that I can get the stack.
So "lapce -w" gets me:

2024-05-01T19:28:07.545881Z ERROR lapce_app::panic_hook: thread main panicked at  | file://.//var/tmp/portage/app-editors/lapce-9999-r4/work/cargo_home/gentoo/floem-cosmic-text/src/buffer_line.rs:192:41
0: lapce_app::app::panic_hook::{{closure}}
1: std::panicking::rust_panic_with_hook
2: std::panicking::begin_panic_handler::{{closure}}
3: std::sys_common::backtrace::__rust_end_short_backtrace
4: rust_begin_unwind
5: core::panicking::panic_fmt
6: core::option::expect_failed
7: floem_cosmic_text::buffer_line::TextLayoutLine::shape
8: floem_cosmic_text::buffer_line::TextLayoutLine::layout
9: floem_cosmic_text::buffer::TextLayout::shape_until
10: floem_cosmic_text::buffer::TextLayout::set_text
11: floem_cosmic_text::buffer::TextLayout::new
12: floem_reactive::signal::ReadSignal::with_untracked
13: <floem_reactive::effect::Effect<T,F> as floem_reactive::effect::EffectTrait>::run
14: floem_reactive::scope::with_scope
15: floem_reactive::effect::run_initial_effect
16: floem_reactive::effect::create_effect
17: floem_reactive::scope::with_scope
18: lapce_app::window_tab::WindowTabData::new
19: lapce_app::window::WindowData::new
20: lapce_app::app::AppData::app_view
21: core::ops::function::FnOnce::call_once{{vtable.shim}}
22: floem_reactive::scope::with_scope
23: floem::window_handle::WindowHandle::new
24: floem::app_handle::ApplicationHandle::new_window
25: lapce_app::app::launch
26: std::sys_common::backtrace::__rust_begin_short_backtrace
27: std::rt::lang_start::{{closure}}
28: std::rt::lang_start_internal
29: main
30:
31: __libc_start_main
32: _start

Additional information
It looks like floem_cosmic_text fails to set the default font shape. Do I need to have some specific font package installed ? 🙄

I just managed to make it work by emerging media-fonts/freefont
(homepage:   https://savannah.nongnu.org/projects/freefont/ )


Panic when use Omit(clause.Associations) before Table(name)

Explain your user case and expected results
Run without panic.

Fix https://github.com/go-gorm/gorm/commit/e77156980cd74639fefdaf0576785018464a3ca1


Error: Invalid Credentials during upload

About an hour or so into upload, even now, I get this error: upload failed: - Error: Invalid Credentials

@Divide-By-0, after investigation, it seems that we have encountered this bug in next-auth:
https://github.com/nextauthjs/next-auth/discussions/6642
there is a solution described in the thread, but unfortunately not a simple one
i'll look at it again in a while, and also try to think of a workaround

@Divide-By-0 I have deployed an update with a workaround.
I have tested it for 90 minutes and the access token is now updated and the process continues.
You can try it you want on https://registry.prove.email/upload as usual. Just sign out and sign in again, and then start an Gmail upload and verify that it runs for more than 60 minutes.

No reports of this problem since the workaround, closing


Is it necessary that ModelField.default is set to static value from default_factory at import time?

Question
Output of python -c "import pydantic.utils; print(pydantic.utils.version_info())":
             pydantic version: 1.5.1
            pydantic compiled: False
                 install path: /virtualenvs/QajdTuIM-py3.7/lib/python3.7/site-packages/pydantic
               python version: 3.7.7 (default, Jun 24 2020, 15:45:42)  [Clang 10.0.1 (clang-1<IP_ADDRESS>)]
                     platform: Darwin-18.7.0-x86_64-i386-64bit
     optional deps. installed: ['email-validator']

I'm trying to do some stuff with dynamically created models, one of which has a field with Field(default_value=my_factory)
I was expecting that my_factory would only be called at runtime. Instead there is code in ModelField.infer, which is called by ModelMetaclass.__new__ at import time, which calls the default factory and gets a value (which presumably is never used) and sets it as the default on the newly created ModelField.
This value doesn't influence the type inference (annotation attr) and default_factory is called as expected when instantiating the model at runtime. I haven't looked any deeper in the code, but it seems like this default value must be unnecessary?
from datetime import datetime
from pydantic import BaseModel, field

class Model(BaseModel):
    dt = Field(default_factory=datetime.now)

mf = Model.__fields__['dt']
# this value should never be used for anything in practice?
mf.default
Out[15]: datetime.datetime(2020, 6, 29, 17, 33, 20, 799276)

# default_factory is called fresh for each instantiation as expected
m = Model()
m.dt
Out[7]: datetime.datetime(2020, 6, 29, 17, 33, 26, 230211)

m = Model()
m.dt
Out[9]: datetime.datetime(2020, 6, 29, 17, 33, 31, 790472)

If nothing else it is a small piece of extra work that could be avoided.
I'm sure I will find a workaround for what I am trying to do, which is an awkward thing where the default_factory returns an instance of a dynamically created model which initially doesn't exist. But that's how I noticed this quirk, maybe it can be cleaned up (or maybe has some useful purpose I haven't perceived).

Hello @anentropic
This should have been fixed by https://github.com/samuelcolvin/pydantic/pull/1504, which will be in pydantic 1.6.
Could you try with the master branch and make sure it works as expected ?

i'l release v1.6 tomorrow.


deisctl: Add 'backup' and 'restore' commands

We have the backup/restore docs, but deisctl itself should have a backup/restore command to ease this process. We could also back up and restore etcd keys, which is not something we currently do - we just repopulate them from the database.

Ref #1408
The suggested CLI from there is:
$ deisctl backup > deis.tar
$ deisctl restore < deis.tar
$ deisctl backup database > deis-database.tar
$ deisctl restore database < deis-database.tar

This is probably easier since etcd2 provides native backup/restore functionality in etcdctl, so we could probably vendor that code quite easily.

deisctl is going away in Deis v2 and I don't think we will be able to get to this for the LTS release so I'm going to go ahead and close this. Thank you for the report though!


Not working with mobile app

Dear
do you have any estimate for your new release to include voice message on mobile app ?

We also only can use this plugin when it's working with the mobile app. Would be very nice when there will be a supporting version released soon. Thanks for your work!

Correct, as explained in https://github.com/streamer45/mattermost-plugin-voice/issues/3#issuecomment-521544719 there's currently no support for mobile plugins.


About pyocd updating.

May I ask is there anybody else handling the pull requests? And which branch should the PR merged into, main or develop?

The branch depends on the content of the PR. See https://github.com/pyocd/pyOCD/blob/main/docs/developers_guide.md#branch-configuration-policy

Thanks @mathias-arm
There's one more question, how to solve this problem on branch 'develop'?

Without the link to the PR or GitHub Actions run, it's impossible to help.

Here is my PR link.
https://github.com/pyocd/pyOCD/pull/1747
Thanks.

I think develop is missing this change https://github.com/pyocd/pyOCD/commit/5166025ae5da5e093d6cfe2b26cae5e1334476e4

Thank you so much@mathias-arm. The problem seems to have been solved.


Removed duplicate Links rsc in myOnlineMeeting_ref.

Removed duplicate Links rsc in myOnlineMeeting_ref. as said in the issue #160
Herve-M

Hi @Herve-M, I'm your friendly neighborhood Microsoft Pull Request Bot (You can call me MSBOT). Thanks for your contribution!

This seems like a small (but important) contribution, so no Contribution License Agreement is required at this point. Real humans will now evaluate your PR.

TTYL, MSBOT;

:warning: Validation status: warnings

File
Status
Preview URL
Details

Skype/UCWA/myOnlineMeeting_ref.md
:warning:Warning

Details

Skype/UCWA/myOnlineMeeting_ref.md

Line 368: [Warning] Invalid file link:(~/UCWA/OnlineMeetingResource_ref.md).

For more details, please refer to the build report.
Note: If you changed an existing file name or deleted a file, broken links in other files to the deleted or renamed file are listed only in the full build report.

@Herve-M This is an old PR, so closing. If you still think these changes need to be made, please file a new PR. Thanks.


add support for classrooms.list and orders.list

@JCotton1123 Any chance you can test this, and if all good, merge?

They work.


fix: #733 Disable grant access button when there is no application selected

Adding the JSON data control ability from the sideNav component to the parent component;
Checking if the Grant Access option should be enabled or disabled according to the value of isApplicationSelected state by adding a variable watcher.

Let's merge the main branch into this branch

Is this still a draft pr? Also update from main branch is needed.

Is this still a draft pr? Also update from main branch is needed.

Yes, Ian. I have put it in draft because I am working to solve a Sonar Cloud error reported.


Crash on emailAddressList is required

I get the below error on converting quite a few of my legacy emails. Unfortunately I cannot share the emails due to PII issues. Would it be possible to force the conversion despite errors like this?
Start converting Prisoner_numbers.msg to Prisoner_numbers.pdf
The email could not be converted. Error: java.lang.IllegalArgumentException: emailAddressList is required
at org.simplejavamail.internal.util.Preconditions.verifyNonnull(Preconditions.java:41)
at org.simplejavamail.internal.util.Preconditions.checkNonEmptyArgument(Preconditions.java:30)
at org.simplejavamail.internal.util.MiscUtil.extractEmailAddresses(MiscUtil.java:165)
at org.simplejavamail.email.internal.EmailPopulatingBuilderImpl.withRecipients(EmailPopulatingBuilderImpl.java:1422)
at org.simplejavamail.email.internal.EmailPopulatingBuilderImpl.to(EmailPopulatingBuilderImpl.java:835)
at org.simplejavamail.internal.outlooksupport.converter.OutlookEmailConverter.copyReceiversFromOutlookMessage(OutlookEmailConverter.java:132)
at org.simplejavamail.internal.outlooksupport.converter.OutlookEmailConverter.buildEmailFromOutlookMessage(OutlookEmailConverter.java:97)
at org.simplejavamail.internal.outlooksupport.converter.OutlookEmailConverter.outlookMsgToEmailBuilder(OutlookEmailConverter.java:78)
at org.simplejavamail.converter.EmailConverter.outlookMsgToEmailBuilder(EmailConverter.java:229)
at org.simplejavamail.converter.EmailConverter.outlookMsgToEmail(EmailConverter.java:211)
at org.simplejavamail.converter.EmailConverter.outlookMsgToEML(EmailConverter.java:595)
at org.simplejavamail.converter.EmailConverter.outlookMsgToEML(EmailConverter.java:586)
at mimeparser.MimeMessageConverter.convertToPdf(MimeMessageConverter.java:123)
at cli.Main.main(Main.java:123)

Seems to be the type of email version as I just run some tests as had the same problem.
Saved the emails again in the new Outlook .msg format and still the same.
Might be a permissions type on the email as its "emailAddressList is required" is causing this.

Can you check if this problem still exists in the newest version?

I assume this is also fixed, since the same error was reported here and tested to be fixed:
https://github.com/nickrussler/email-to-pdf-converter/issues/36

Unfortunately I no longer have access to the emails that were causing the issues. I will test again when I get another set of MSG files to convert.


Use lazy_static in rusoto_credential profile provider

TODO note here: https://github.com/rusoto/rusoto/blob/master/rusoto/credential/src/profile.rs#L259 .
Whenever we parse the credential file we create a parsing regex which is relatively expensive. We could instantiate it once so it's not recreated every time we parse the credentials file. This is important when we support https://github.com/rusoto/rusoto/issues/1303 .
See https://docs.rs/regex/1.3.1/regex/#example-avoid-compiling-the-same-regex-in-a-loop for more details on why we'd want to compile it just once.

i'll take this one.


require to generate frquency of 1Mhz or above by using clkout

i have got the code .c file for generating clkout on gpio pins using internal system frequency with a divider. please if can share any document or code regarding this topic in thonny

This is a question you'll need to ask at https://github.com/orgs/micropython/discussions

Discussion link https://github.com/micropython/micropython/discussions/9269


NuGet curation fixes

How about splitting you all pure formatting commits out to a separate PR until those version 2.1.7 path issues are sorted out for all affected packages?

I went through all curations and found 2 more "version 2.1.17 like" issue which I fixed. I believe the curations are fine now.


WRONG_INDENTATION: false positives for parentheses-surrounded infix expressions

The following code fragment triggers no errors, provided that expectedIndentAfterOperators is off:
val value = 1 to
    2

Now, let's surround the expression (which is an infix function call) with parentheses, preserving the indent:
val value = (1 to
    2)

DiKTat will report the following errors:
[WRONG_INDENTATION] only spaces are allowed for indentation and each indentation should equal to 4 spaces (tabs are not allowed): expected 8 but was 4
[WRONG_INDENTATION] only spaces are allowed for indentation and each indentation should equal to 4 spaces (tabs are not allowed): expected 8 but was 4

Strangely, if we move the expression onto the next line (and increment the indent), the errors immediately go away:
val value =
    (1 to
        2)

The issue is caused by the incomplete implementation of ExpressionIndentationChecker as a part of #75 (see 7d913ed0).
Environment information

diktat version: 1.2.0
build tool (maven/gradle): Maven
how is diktat run (CLI, plugin, etc.): Maven plug-in
kotlin version: 1.7.0
operating system: Windows

If we take a test for ExpressionIndentationChecker (IndentationRuleWarnTest.closing parenthesis bug()) and reformat the original code:
fun foo() {
    return x +
        (y +
            foo(x)
        )
}

— and reformat it:
fun foo() {
    return x + (y +
        foo(x)
    )
}

— the test will still pass. If, however, we convert the return statement to an expression body, it will immediately start to fail:
fun foo() = x + (y +
    foo(x)
)


How to adjust the width of the sidebar?

Hi. I want to make the sidebar wider, so I change some values in the _sidebar.scss but it didn't work.
Maybe I got some wrong operations. So How should I do and which value should I change?
Thank you!

I have searched similar issues. Thank you for your wonderful theme!


Timout configuration is not available.

Your description here
Timout configuration is not available.
Expected outcome
What should happen?
For requests with lengthy duration, timeout occurs.
Actual outcome
What happened?
For requests with lengthy duration, timeout occurs.
Versions
App: <IP_ADDRESS>-stable
Chrome: 49.0.2623.112
Platform: Windows (7)
Steps to reproduce

Try accessing a delayed restful service
Timeout occurs on the same

Hi,
Thank you for issue report.
It is duplicate of #613 #605 and #601
As per this I'm closing it as a duplicate.


Fix incorrect package name in pkg/api/cluster/formatter.go

Problem:
execute make and I got error
pkg/api/cluster/formatter.go:14:2: cannot find module providing package github.com/rancher/wrangler/pkg/generated/controllers/core/v1: import lookup disabled by -mod=vendor
	(Go version in go.mod is at least 1.14 and vendor directory exists.)
FATA[0011] exit status 1
make: *** [Makefile:11: default] Error 1

Solution:
Fix incorrect package in pkg/api/cluster/formatter.go, the root cause is we change the rancher wrangler version in https://github.com/harvester/harvester/pull/6173
Related Issue:
N/A
Test plan:
Compile should pass.

@ibrokethecloud, could you cherry-pick the fix to https://github.com/harvester/harvester/pull/6238? Or do we prefer to merge https://github.com/harvester/harvester/pull/6238 first and then backport this again to v1.4? Thanks.

@FrankYang0529 i am ok with either option. I can rebase the backport PR once this is merged.


chore: fixup release instructions for pushing tags

Description
Current instructions are incorrect.
Type of change

[x] Documentation (updates to documentation or READMEs)

What's wrong with that bash shorthand notation? It means "last argument of prior command"

I don't know. It doesn't work for me.
gregs-mbp:aspect-cli greg$ git tag 6.6.6
gregs-mbp:aspect-cli greg$ echo $!
76802

Maybe it is linux specific?

Last arg is either !$ or $_... Updating to $_ since !$ is too easy to mixup with $! at a glance.


Doc are hard to read and use

Hi.
I can't fid out how to:

disable tooltips in the donut chart?
how to manage border width or to turn it off?
how to manage width of the overall chart (width and height values in the canvas tag are not working)?
how to make a rounded corners in the donut charts?

I'm using Version: 2.2.1 and yep, i read the doc, but i cant' deal with those things.
To be onest, the previous version was a lot easier to understand.
Thanks.

+1 for docs are hard to read

Can you please add some specific examples of what you find hard to read and understand? We will try to update the docs so that they are easier to read.

Well I think that you can find almost anything, using the find bar of chrome.
But if could exists an integrated, "improved" search mechanism inside the docs page, it will be perfect.

@zerazobz that would be something that @nnnick would have to implement into the site, but I feel that the normal browser search accomplishes the same thing. Were you thinking a search such as the one in slate?

I don't think i've ever had a problem finding anything in the docs, but that might be because i've been semi-reading them for the last few months. Generally if it's something all charts would have (like tooltips) then i'll look under 'Chart Configuration', otherwise i'll look under that specific chart's section. If I still haven't found it then i'll do a search.

Having some fully featured examples of working charts would be a great help. When I first started using chart.js, I often found it difficult to understand where things were supposed to go and what they were supposed to look like. For example, there are no examples containing callbacks, however, if I wanted some callbacks to alter the text on my tooltips, it would look something like:
...
options = {
tooltips: {
callbacks: {
label: function (item, data) {
// do a thing with item or data
return string_for_tooltip;
},
beforeLabel: function (item, data) {
// Do a thing with item or data
return string_to_display_before_label;
}
}
},
scales: {...}
}
...
While it's possible to work this out for yourself (since I have), it would be nice to have an example of things like this in the docs given that, while the information is available, it's not always clear, especially if you've never used it before.
Basically, some complex charts demonstrating features would make the docs more usable.

Please add examples for docs.
Like it
http://gionkunz.github.io/chartist-js/examples.html

I personally like the format of Read the Docs.
An example of a well-structured project would be Simple Injector.
Just my two cents.

Closing since docs have been rewritten since this issue was opened


Remove Microsoft's copyright notice from type definition file

Bug Report
Problem
The start of your TypeScript type definitions file contains a copyright notice claiming that it belongs to Microsoft:
// Type definitions for Apache Cordova File System plugin
// Project: https://github.com/apache/cordova-plugin-file
// Definitions by: Microsoft Open Technologies Inc <http://msopentech.com>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
//
// Copyright (c) Microsoft Open Technologies, Inc.
// Licensed under the MIT license.

I suspect this is a copy-and-paste-mistake. You should correct it. You may also want to remove the outdated link to the DefinitelyTyped repo.

What's the problem here? License is in tact, and the code is licensed under MIT. Removing the copyright notice would be violating the license.

I’ll search the commits later, but indeed Microsoft originally authored those files. They were split from DefinetlyTyped to the actual software projects.

@purplecabbage Are you able to provide insight on this issue regarding code licensed/owned by a third-party?


Publish endpoint for each receive endpoint

The publish endpoint should include the source address of the receiving endpoint, not the temporary bus.

Resolved in  f6425a0]


Upgrade the data-explorer、manager-explorer versions to 1.1.1.RELEASE

This issue has been resolved by an unmerged pr


isJson assertion returns the error "Invalid Chai property"

Description
isJson assertion returns the error Invalid Chai property: json. Did you mean "to"?
Test collection
Test collection:  https://github.com/dcoomber/exploring-bruno/tree/dpc_session_1/exploration/02-create/EE Bookings
Test request:  "Retrieve a booking"
Screenshot

Thanks for catching this @dcoomber !
Would you be able to work on fixing this?
The code is here

I have ended up proposing the use of https://github.com/chaijs/chai-http, but am uncertain if this is what you're looking for.
chai-http .to.be.json is merely a check that the response headers includes Content-Type: application/json.  In this form, the assertion would only ever be valid when comparing against res and would not be usable for comparisons of subsets of the response structure.
Please let me know if you had a different solution in mind.

After reviewing https://www.chaijs.com/api/plugins/ along with stepping through some of the other assertions, I realised that we're looking to addProperty and not addMethod.
PR updated.


Fails to detect search query on Kagi

Describe the bug
问题描述
Kagi input detection does not work
To Reproduce
如何复现
Steps to reproduce the behavior:

Go to 'https://kagi.com/search?q=testing'
"No input found"

Expected behavior
期望行为

Go to 'https://kagi.com/search?q=testing'
ChatGPTBox detects the search query

Screenshots
截图说明
If applicable, add screenshots to help explain your problem.
Please complete the following information):
请补全以下内容

OS: [e.g. Windows]
Browser: [e.g. chrome, safari]
Extension Version: [e.g. v2.0.2]

Additional context
其他
Kagi is no longer using an input for the search query, it's a text area so input[name='q'] fails but textarea[name='q'] works

Can confirm this is fixed now


Trying to put a different bf death scene

Describe your bug here.
function onCreate()
-- CHARACTER
setPropertyFromClass('substates.GameOverSubstate', 'characterName', 'shapey_bf-dead');
-- SOUNDS/MUSICS
setPropertyFromClass('substates.GameOverSubstate', 'deathSoundName', 'fnf_loss_sfx'); --file goes inside sounds/ folder
setPropertyFromClass('substates.GameOverSubstate', 'loopSoundName', 'gameOver'); --file goes inside music/ folder
setPropertyFromClass('substates.GameOverSubstate', 'endSoundName', 'gameOverEnd'); --file goes inside music/ folder

end
but it didn't work on data or script TOT
Command Prompt/Terminal logs (if existing)
No response
Are you modding a build from source or with Lua?
Lua
What is your build target?
Windows
Did you edit anything in this build? If so, mention or summarize your changes.
no
If you use 1.12.0 or earlier, did you have Optimized Chart Loading turned on?
None

are you using android? if not, does the character exist?

https://github.com/JordanSantiagoYT/FNF-PsychEngine-NoBotplayLag/assets/109116149/4da6631b-599d-450c-b225-0396082103d8

what do you mean by the script not working? it seems to be working for me

I used a the death script https://github.com/ShadowMario/FNF-PsychEngine/wiki/Lua-Script-API

never mind i had to change it to GameOverSubstate


Performance regression in #33473

The extra work done in #33473 is valuable, but maybe it doesn't need to be so expensive.  In this particular case, there don't seem to be any errors (though there is one @ts-ignore).
Setup:

Clone https://github.com/amcasey/material-ui.git
Check out Benchmark
yarn to restore packages
yarn typescript to prebuild and run some TS tests

Repro

tsc -p docs

On a random Mac Mini:

10-run avg on https://github.com/microsoft/TypeScript/commit/6c2ae12559508b594f7038f8d6165b92ec89c58c: 33,010ms
10-run avg on https://github.com/microsoft/TypeScript/commit/26caa3793e310e271ddee8adc1804486e5b0749f: 33,494ms (1% slower)

Note: to build old TS commits, you probably need to change const { default: chalk } to const chalk in scripts/build/utils.js.

FYI @weswigham


Add Purview platform DNS zone and fix typo

Adds the Purview platform DNS Zone config.
fix typo with superscript tag.

@AbdullahBell
Can you review the proposed changes?
IMPORTANT: When the changes are ready for publication, adding a #sign-off comment is the best way to signal that the PR is ready for the review team to merge.
#label:"aq-pr-triaged"
@MicrosoftDocs/public-repo-pr-review-team

#sign-off


[GLUTEN-3559][VL] Fix UTs failing in spark 3.4 which have assertions for SMJ node

What changes were proposed in this pull request?
This PR fixes the following suites:

GlutenJoinSuite
GlutenKeyGroupedPartitioningSuite
GlutenWriteDistributionAndOrderingSuite

(Partially Fixes: #3559)
How was this patch tested?
Ran UTs locally

cc: @JkSelf

@JkSelf @ulysses-you @zhli1142015 Could you please help in reviewing this PR?

Thank you @JkSelf @ulysses-you @zhli1142015


Okay, @gf712 I'm so sick of this error, I rebased and everything but still getting some checks were not successful, help :'(

Which error?

"Some checks were not successful"

oh don't worry about that, that is not because of your PR

oh don't worry about that, that is not because of your PR
Really :'( okay then,
how can I merge when it's not passing the checks?

Well, you can’t merge.. only a shogun member can merge

Well, you can’t merge.. only a shogun member can merge

okay

I created a NOTEBOOKS.md as mentioned in issue #3519 perhaps you could help me get started
@gf712

this PR contains parts of other PRs you have sent before (opencv readme). It is fine if you want to group things, but it would be good if you closed the other PR (or better, not open it in the first place).
Went through the suggested changes here and don't think they are improving things. See my other comment on the docstrings as a suggestion what to get involved with.


Delete Global Content

Add delete functionality in Global Queries, Connection & Themes.
(Need discussion on related content)

The connection id is attached to Query. What will happen when we delete the connection?


Hide form fields based on value of other form fields?

Using _fbKey.currentState.fields['dependent_field'].currentState.value does not work, throws the error that customState was called on null

You could use Visibility() widget and set visible to either true or false depending on the value of the other field.

@Dennis-Mwea Do you mean I'll declare a separate bool value on init then set that with onChanged of the form field that is responsible for the visibility value? Because my current setup throws an error "NoSuchMethodError: The method '[]' was called on null" as the state has not been initialised:
 Visibility(
                            visible: this._fbKey.currentState?.fields['dependent_field']?.currentState.value,
                            maintainState: true,
                            child: Text('Hello'),
                          ),

@joshuakoh1 Yeah you have to declare separate bool value on init then set that with onChanged of the form field that is responsible for the visibility value.

Hi @joshuakoh1!
This still an issue?

Due to lack of response and an old error, I will close this issue.
If the bug still exists, feel free to open a new issue


Add Ignore annotation to failing tests

Fixes #3834

A lot of the test failures are due to timeouts. Some of the tests that failed initially due to a timeout succeeded on a retry.


Build fails with no real error message

I have a feeling this is a configuration issue, but I have tried just about everything I can think of and am getting nowhere. I am trying to build the docs I have at the svn repository in this location:
https://hpxml.nrel.gov/pubsvn/branches/hpxmlguide/guide/
Right now my settings are as follows.
Repo: https://hpxml.nrel.gov/pubsvn/
Repository Type: Subversion
Python config file: guide/source/conf.py
Default branch: branches/hpxmlguide

When I do a build it fails, but doesn't give me anything really useful.
Built: Sept. 3, 2014. 11:26 a.m.
State: Finished
Outcome: Failed (Status Code: 0)
Version: latest
Type: html
Build Standard Output

Believe this was fixed.


Use $global:lastexitcode instead of $lastexitcode in Exec

Description
Use $global:lastexitcode as described in https://github.com/psake/psake/issues/203.
Related Issue
https://github.com/psake/psake/issues/203
Motivation and Context
Check https://github.com/psake/psake/issues/203

@gpetrou Yep. 4.7.4 is now on PSGallery, nuget.org, and chocolatey. Thanks for catching the older versions. They're on nuget.org now as well.


Scheduling Replicator

Introduce Scheduling CouchDB Replicator
Jira: https://issues.apache.org/jira/browse/COUCHDB-3324
The core of the new replicator is a scheduler. It which allows running a large number of replication jobs by switching between them, stopping some and starting others periodically. Jobs which fail are backed off exponentially. There is also an improved inspection and querying API: _scheduler/jobs and _scheduler/docs.
Replication protocol hasn't change so it is possible to replicate between CouchDB 1.x, 2.x, PouchDB, and other implementations of CouchDB replication protocol.
Scheduler
Scheduler allows running a large number of replication jobs. Tested with up to 100k replication jobs in 3 node cluster. Replication jobs are run in a fair, round-robin fashion. Scheduler behavior can be configured by these configuration options in [replicator] sections:

max_jobs : Number of actively running replications. Making this too high
could cause performance issues. Making it too low could mean replications jobs
might not have enough time to make progress before getting unscheduled again.
This parameter can be adjusted at runtime and will take effect during next
rescheduling cycle.

interval : Scheduling interval in milliseconds. During each reschedule
cycle scheduler might start or stop up to "max_churn" number of jobs.

max_churn : Maximum number of replications to start and stop during
rescheduling. This parameter along with "interval" defines the rate of job
replacement. During startup, however a much larger number of jobs could be
started (up to max_jobs) in a short period of time.

_scheduler/{jobs,docs} API
There is an improved replication state querying API, with a focus on ease of use and performance. The new API avoids having to update the replication document with transient state updates. In production that can lead to conflicts and performance issues. The two new APIs are:

_scheduler/jobs : This endpoint shows active replication jobs. These are jobs managed by the scheduler. Some of them might be running, some might be waiting to run, or backed off (penalized) because they crashed too many times. Semantically this is somewhat equivalent to _active_tasks but focuses only on replications. Jobs which have completed or which were never created because of malformed replication document will not be shown here as they are not managed by the scheduler. _replicate replications, started form _replicate endpoint not from a document in a _replicator db, will also show up here.

_scheduler/docs :  This endpoint is an improvement on having to go back and re-read replication document to query their state. It represents the state of all the replications started from documents in _replicator dbs. Unlike _scheduler/jobs it will also show jobs which have failed or completed (that is, which are not managed by the scheduler anymore).

Compatibility Mode
Understandably some customers are using the document-based API to query replication states (triggered, error, completed etc). To ease the upgrade path, there is a compatibility configuration setting:
[replicator]
update_docs = false | true

It defaults to false but when set to true it will continue updating replication document with the state of the replication jobs.
Other Improvements

Network resource usage and performance was improved by implementing a common connection pool. This should help in cases of a large number of connections to the same sources or target. Previously connection pools were shared only withing a single replication job.

Improved rate limiting handling. Replicator requests will auto-discover rate limit capacity on targets and sources based on a proven Additive Increase / Multiplicative Decrease feedback control algorithm.

Improved performance by avoiding repeatedly retrying failing replication jobs. Instead use exponential backoff. In a large multi-user cluster, quite a few replication jobs are invalid, are crashing or failing (for various reasons such as inability to checkpoint to source, mismatched credentials, missing databases). Penalizing failing replication will free up system resources for more useful work.

Improved recovery from long but temporary network failure. Currently if replications jobs fail to start 10 times in a row, they will not be retried anymore. This is sometimes desirable, but in some scenarios (for example, after a sustained DNS failure which eventually recovers), replications reach their retry limit and cease to work. Previously it required operator intervention to continue. Scheduling replicator will never give up retrying a valid scheduled replication job. So it should recover automatically.

Better handling of filtered replications: Failing to fetch filters could block couch replicator manager, lead to message queue backups and memory exhaustion. Also, when replication filter code changes update replication accordingly (replication job ID should change in that case). This PR fixes both of those issues. Filters and replication ID calculation are managed in separate worker threads (in couch replicator doc processor). Also, when filter code changes on the source, replication jobs will restart and re-calculate their new ID automatically.

Related PR:
Documentation PR:  https://github.com/apache/couchdb-documentation/pull/123
Tests

EUnit test coverage. Some modules such as multidb_changes, have close to 100% coverage. Some have less. All previous replication tests have been updated to work with the new scheduling replicator.

Except for one modification, existing Javascript tests pass.

Additional integration tests. To validate, test and benchmark some edge cases, an additional toolkit was created: https://github.com/cloudant-labs/couchdyno/blob/master/README_tests.md which allows testing scenarios where nodes fail, creation of large number of replication jobs, manipulation of cluster configurations, and setting up long running (soak) tests.

Some additional information from testing how new scheduling replicator handles a large amount of jobs.
This is a graph of adding 1M replication jobs to a cluster of 3 nodes (testy011). Replication jobs were added using dyno/rep tool : https://github.com/cloudant/dyno/blob/master/README_rep.md
rep.replicate_all_and_compare(n=1000, num=1, normal=False)

That creates a connected cluster of replications for for n=1000, it would create 1000*1000=1M replication jobs.

couch_replicator.docs.db_changes tracks the total number of changes seen by the replicator. In this case the replicator has seen the 1M replication documents created above.

couch_replicator.jobs.total tracks the number of replication jobs managed by the scheduler. Out of the 1M jobs, each node in the cluster picked up about 330K each.

couch_replicator.jobs.starts counts the number of jobs which have been started by the scheduler. In this case a time derivative was applied. So it shows how the scheduler interval works. Every time it runs it start another 20 jobs (this is specified by the max_churn parameter).

Hooray scheduling replicator! This looks pretty awesome. Its quite big so I'm gonna split my review into roughly three parts: concerns, things that look like bugs, and then style issues. Commencing in 3, 2, 1, now!

Seems like couch_replicator_rate_limiter could use some tests and if we could pass our own now_msecs() value it'd be pretty simple to calculate some test data to assert we're generating the correct intervals.

Got rate limiter tests in : https://github.com/apache/couchdb/blob/63012-scheduler/src/couch_replicator/test/couch_replicator_rate_limiter_tests.erl

Yeah, sorry to go back and note that. I found them after. I generally prefer tests separate from a module but in this case it might be nice to eventually move those to the module in case we ever move the module somewhere and make it more general to be re-used in other places cause it looks rather useful.

Alright. Done for the day. I'm pretty sure I've got all the major bits paged into my brain. Everything seems pretty good. There are only two bits that we should think about a bit harder.
The HTTP handlers are a bit futzy. They currently aren't using fabirc/rexi style RPC and instead just use builtin Erlang RPC which is a bit of an odd departure from our standard approach to clustered HTTP requests. Also for the doc listing API its odd that we kind of just shove the lists out separately into a weirdly combined single view like output. Also any sort of skip is going to be rather non-performant so paging through our thousands of active replications concern is going to be ungood. I'd like to see this as a module using our standard fabric/rexi approach that is smart about paging and streaming results.
The doc processor architecture is a bit Rube Goldberg-ian. I can see why its that way given how all of the odd replication features kind of collide. User filter functions being the obvious complicating factor there.  I don't immediately see a better approach though given that the scheduler expects to have a replication_id before we tell it to do anything and that seems fairly legit. I'l stew on this overnight in case anything occurs to me.
Tomorrow I'm gonna write up a description/overview of the couch_replicator app as a check that my understanding matches everyone elses. And if so we can add that as a README in the application folder. Once I'm done there I'll actually pull and compile and run the test suite though I'm assuming that's already happened quite a lot but I'll also look at coverage and consider any tests that should be added for anything that's lacking significant coverage and is non-trivial.
Awesome work on this everyone!

Many thanks @davisp for taking a look at this.
With your help found some sneaky bugs and a added number of great improvements.
Now on the idea of how to simplify the doc processor (as in remove the complicated bit). I remember I was wondering at some point what if scheduler operated on documents instead of replication jobs. So the {DbName, DocId} becomes the Job ID and we use the scheduler to track and manage the lifecycle of "when scheduled get replication ID (or check if changed), then start a replication job, and so on" But that scheme got kind of complicated as well. It might have been less code overall but it would have been even harder to decipher.

Awesome work on this only had a couple notes after the README stuff. The new fabric stuff looks awesome.
+1 once the README bits and the few other notes are addressed.

foundings -> findings

Tests pass locally
======================== EUnit ========================
module 'json_stream_parse'
module 'couch_replicator_worker'
module 'couch_replicator_utils'
module 'couch_replicator_test_helper'
module 'couch_replicator_sup'
module 'couch_replicator_stats'
module 'couch_replicator_small_max_request_size_target'
module 'couch_replicator_scheduler_sup'
module 'couch_replicator_scheduler_job'
module 'couch_replicator_scheduler'
module 'couch_replicator_rate_limiter_tables'
module 'couch_replicator_rate_limiter'
module 'couch_replicator_rate_limiter_tests'
module 'couch_replicator_notifier'
module 'couch_replicator_manager'
module 'couch_replicator_job_sup'
module 'couch_replicator_ids'
module 'couch_replicator_httpd_util'
module 'couch_replicator_httpd'
module 'couch_replicator_httpc_pool'
module 'couch_replicator_httpc_pool_tests'
module 'couch_replicator_httpc'
module 'couch_replicator_filters'
module 'couch_replicator_fabric_rpc'
module 'couch_replicator_fabric'
module 'couch_replicator_docs'
module 'couch_replicator_doc_processor_worker'
module 'couch_replicator_doc_processor'
module 'couch_replicator_db_changes'
module 'couch_replicator_connection'
module 'couch_replicator_connection_tests'
module 'couch_replicator_clustering'
module 'couch_replicator_changes_reader'
module 'couch_replicator_app'
module 'couch_replicator'
module 'couch_replicator_use_checkpoints_tests'
module 'couch_replicator_selector_tests'
module 'couch_replicator_proxy_tests'
module 'couch_replicator_modules_load_tests'
module 'couch_replicator_missing_stubs_tests'
module 'couch_replicator_many_leaves_tests'
module 'couch_replicator_large_atts_tests'
module 'couch_replicator_id_too_long_tests'
module 'couch_replicator_filtered_tests'
module 'couch_replicator_compact_tests'
=======================================================
  All 300 tests passed.

@davisp @iilyak @sagelywizard @tonysun83  Thanks again for taking a look. Really appreciate your time. This was no small PR.  There were a lot of good suggestions from you all and we improved the code quite a bit as a result.

I ran the dyno tests against a cluster that rate limits and was able to get replication completed with ten concurrent replications for 50K docs. I really like the history for _scheduler/jobs:
"history": [
                {
                    "timestamp": "2017-04-25T06:20:30Z",
                    "type": "started"
                },
                {
                    "timestamp": "2017-04-25T06:20:30Z",
                    "type": "crashed",
                    "reason": "max_backoff"
                },
                {
                    "timestamp": "2017-04-25T05:12:12Z",
                    "type": "started"
                },
                {
                    "timestamp": "2017-04-25T05:12:12Z",
                    "type": "crashed",
                    "reason": "max_backoff"
                },
                {
                    "timestamp": "2017-04-25T05:03:15Z",
                    "type": "started"
                },
                {
                    "timestamp": "2017-04-25T05:03:15Z",
                    "type": "added"
                }

Background: https://issues.apache.org/jira/browse/COUCHDB-3391
Summary: I tested the max_jobs config and it doesn't appear to be working as I would expect. Sorry, if I missed a detail.
Steps to reproduce:

Pull and build https://github.com/apache/couchdb/pull/470
Clone https://github.com/redgeoff/couchdb2-replicator-not-scalable-vagrant. I used vagrant to set up my test, but you should be able to run the tests outside a VM as well.
Modify couchdb2-replicator-not-scalable-vagrant/index.js and replace localhost with the correct dev DB host
Set the config replicator.max_jobs=10
Run npm run demo (this just runs index.js)

=> this results in Unhandled rejection Error: internal_server_error errors. If you were to modify https://github.com/redgeoff/couchdb2-replicator-not-scalable-vagrant/blob/master/index.js#L10 and use a smaller number, e.g. 10 then there would be no issue as you would not exhaust the file descriptors and db connections. My assumption is that the max_jobs config should throttle the replications and prevent the DB from throwing errors.

@redgeoff
Thanks for taking a look!
max_jobs parameter would limit the number of running replication jobs at one time. File descriptors can be exhausted by other things not just replication tasks. In this case it is probably the databases opened. Also note each db by default is split into 8 shards (the q value). So that starts to add up.
I gave your setup a try and got it to work with these settings:
(I didn't try to minimize them, you can probably tweak them to find minimal values)
ulimit  -n 8192
config settings:
couchdb.max_dbs_open = 3000
cluster.q=1
cluster.n=1
replicator.max_jobs = 10
worker_processes = 1
I put q=1, n=1 based on your use case in https://issues.apache.org/jira/browse/COUCHDB-3391
With all that set up. Started couch (I build a local scheduling replicator in Vagrant)
couchdb@ubuntu-xenial:~/couchdb$ ./bin/couchdb
[info] 2017-04-26T19:22:44.457066Z couchdb@localhost <0.7.0> -------- Application couch_log started on node couchdb@localhost
...

Created _users and _replicator dbs. I am not sure if your test does this. Here is how it looks:
couchdb@ubuntu-xenial:/vagrant$ http put http://localhost:5984/_users
HTTP/1.1 201 Created
...

{
    "ok": true
}

couchdb@ubuntu-xenial:/vagrant$ http put http://localhost:5984/_replicator
HTTP/1.1 201 Created
...

{
    "ok": true
}

Ran your demo:
npm run demo

><EMAIL_ADDRESS>demo /vagrant
> ./index.js

without any errors.
And finally showing off the states-based filtering:
$ http http://localhost:5984/_scheduler/docs?states=running
HTTP/1.1 200 OK
...

{
    "docs": [
        {
            "database": "_replicator",
            "doc_id": "7e801385699c0723d64ce2b684000378",
            "error_count": 0,
            "id": "2f691a8a3e337142691e7679e2c146a1+continuous",
            "info": null,
            "last_updated": "2017-04-26T19:14:07Z",
            "node": "couchdb@localhost",
            "proxy": null,
            "source": "http://localhost:5984/test_1493234045679_2_a/",
            "start_time": "2017-04-26T19:14:07Z",
            "state": "running",
            "target": "http://localhost:5984/test_1493234045679_2_b/"
        },
        {
            "database": "_replicator",
            "doc_id": "7e801385699c0723d64ce2b684001144",
            "error_count": 0,
            "id": "2f42b5ccbfb20e82d319054af8cb7828+continuous",
            "info": null,
            "last_updated": "2017-04-26T19:14:08Z",
            "node": "couchdb@localhost",
            "proxy": null,
            "source": "http://localhost:5984/test_1493234045679_6_a/",
            "start_time": "2017-04-26T19:14:08Z",
            "state": "running",
            "target": "http://localhost:5984/test_1493234045679_6_b/"
        },
        {
            "database": "_replicator",
            "doc_id": "7e801385699c0723d64ce2b684001d86",
            "error_count": 0,
            "id": "a7361651a4c5fbb64ae9dd601005dc11+continuous",
            "info": null,
            "last_updated": "2017-04-26T19:14:08Z",
            "node": "couchdb@localhost",
            "proxy": null,
            "source": "http://localhost:5984/test_1493234045679_4_a/",
            "start_time": "2017-04-26T19:14:08Z",
            "state": "running",
            "target": "http://localhost:5984/test_1493234045679_4_b/"
        },
    ...
    ],
    "offset": 0,
    "total_rows": 1000
}

Without any crashes
http http://localhost:5984/_scheduler/docs?states=crashing
HTTP/1.1 200 OK
Cache-Control: must-revalidate
Content-Type: application/json
Date: Wed, 26 Apr 2017 19:26:03 GMT
Server: CouchDB/2.0.0-49786f7 (Erlang OTP/18)
Transfer-Encoding: chunked
X-Couch-Request-ID: 465148b54d
X-CouchDB-Body-Time: 0

{
    "docs": [],
    "offset": 0,
    "total_rows": 1000
}

@redgeoff As far as I'm aware, CouchDB doesn't make any attempt to check system/process ulimit on max fds. If I recall correctly, you'll start getting {error, system_limit} when you hit this limit. (Don't forget that the erl process itself by default limits Erlang to 65536 max simultaneous ports open or 8196 on Windows, which can be adjusted with +Q in vm.args or on the command line.) If the test passes as @nickva shows with a sufficiently high ulimit, I don't see any need to block this PR.

\o/ congrats! so exciting.

Sorry, I haven't had time to follow up. I'll try to test this soon, but
please don't hold this up. In general though, I was hoping that these
changes would make it so that you could more efficiently implement
replication with less connections/handles so that you could support more
databases/users (with replications) on a single box. I'm not sure if these
enhancements target this detail.
On Fri, Apr 28, 2017, 15:50 Joan Touzet<EMAIL_ADDRESS>wrote:

\o/ congrats! so exciting.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/apache/couchdb/pull/470#issuecomment-298124062, or mute
the thread
https://github.com/notifications/unsubscribe-auth/ADOPKn3BpC-XvvbHv5OG-FvtNziBAhpgks5r0m0rgaJpZM4Mzi0E
.

The good news is that yes, this commit DOES more efficiently handle replication with less connections, but only for multiple replications between the same hosts. So it's great for clusters and data center backups and so on, but doesn't really help the database-and-replication-per-user model very much.

Was this actually finished and released? Struggling to understand the git history, seems to have been reverted. Also struggling to find in release notes or related documentation regarding settings. Possible in just not doing a good job of looking.

@badbod99 Yes, the scheduling replicator was merged and released in 2.1.0.
http://docs.couchdb.org/en/latest/whatsnew/2.1.html#version-2-1-0