Issue with Dynamically Changing Giscus Theme Based on Website Theme

Hello Giscus Team,
Firstly, I'd like to apologize as I'm not well-versed in coding. This issue and the attempted solutions were generated and formulated with the assistance of ChatGPT, based on my experiences and the problems I've encountered on my website: greendolphindance.com.
Problem Description:

My website has a dark mode toggle, and I want giscus to automatically switch its theme to match the website's current theme.
The giscus comments section is dynamically loaded when the user scrolls down to it.

Attempted Solutions:

Using MutationObserver: Tried to observe changes in the body class to detect theme changes and send a message to the giscus iframe to change its theme. The message is being sent successfully (verified using console.log), but the theme in the giscus iframe is not updating.

Using setTimeout/setInterval: Tried to delay the message sending or repeatedly send the message to ensure it is received after giscus has fully loaded. This method was not reliable and did not consistently apply the theme.

Directly Observing Giscus Iframe: Attempted to observe the giscus iframe for changes and send the theme update message upon detecting changes. This also did not result in the theme being updated.

Code Snippets:
Here are some snippets from the attempted solutions:
// Example code for changing giscus theme
function changeGiscusTheme() {
    const theme = document.body.classList.contains('dark-theme') ? 'dark' : 'light';
    const iframe = document.querySelector('iframe.giscus-frame');
    if (!iframe) return;
    iframe.contentWindow.postMessage({ giscus: { setConfig: { theme: theme === 'dark' ? 'noborder_dark' : 'noborder_light' } } }, 'https://giscus.app');
}

// Example code for observing body class changes
const observer = new MutationObserver(changeGiscusTheme);
observer.observe(document.body, { attributes: true });

I appreciate any assistance or guidance you can provide on this issue. Thank you in advance!

Load two iframes on top each other, switch between them🤫

Apologies, I've resolved my issue independently with assistance from ChatGPT, and will consequently close the issue. The primary challenge encountered is detailed below, along with the methodology employed for its resolution.
Issue Summary:
Problem:
When the webpage was in dark mode and a user navigated to an article page, the Giscus comment section remained in light mode. Using the toggle to switch to light mode and then back to dark mode would then switch the comment section to dark mode. The desired behavior was to have the comment section match the theme of the rest of the webpage immediately upon loading, without requiring additional toggling by the user.
Initial Attempt:
A solution was attempted using the code provided in this GitHub comment. However, this introduced a new issue: while directly entering the post page had the comment section displaying the correct color mode, utilizing the toggle to switch themes did not affect the comment section, rendering it static and unresponsive to theme changes.
Solution Path:
The code from the aforementioned GitHub comment was provided to ChatGPT for analysis and adaptation. After several rounds of adjustments and testing, ChatGPT generated a code snippet that resolved the issue, ensuring that the Giscus comment section not only adhered to the initial theme of the webpage but also accurately responded to theme changes via the toggle.
Final Solution Code:
<script>
function setGiscusTheme() {
    const theme = document.body.classList.contains('dark-theme') ? 'dark' : 'light';
    function sendMessage(message) {
        const iframe = document.querySelector('iframe.giscus-frame');
        if (!iframe) return;
        iframe.contentWindow.postMessage({ giscus: message }, 'https://giscus.app');
    }
    sendMessage({
        setConfig: {
            theme: theme === 'dark' ? 'transparent_dark' : 'transparent_light'
        }
    });
}

document.addEventListener('DOMContentLoaded', function () {
    const giscus = document.createElement('script');
    giscus.src = 'https://giscus.app/client.js';
    giscus.crossOrigin = 'anonymous';
    giscus.async = true;
    giscus.setAttribute('data-repo', 'greendolphindance/greendolphindance.github.io');
    giscus.setAttribute('data-repo-id', 'R_kgDOKc-MwA');
    giscus.setAttribute('data-category', 'General');
    giscus.setAttribute('data-category-id', 'DIC_kwDOKc-MwM4CZ8oe');
    giscus.setAttribute('data-mapping', 'url');
    giscus.setAttribute('data-reactions-enabled', '1');
    giscus.setAttribute('data-theme', 'transparent_light');
    giscus.setAttribute('data-lang', 'zh-CN');
    document.body.appendChild(giscus);

    document.getElementById('theme-switch').addEventListener('click', () => {
        setTimeout(() => {
            setGiscusTheme();
        }, 100);
    });
});
</script>

Sorry, still something wrong…the display on my Mac is all good but the same problem appears when I use a cell phone. I have no idea why.

Issue Overview
When utilizing a dark mode toggle to switch the color scheme of the website, the embedded Giscus comment section also switches its color scheme accordingly on desktop. However, on mobile, despite the website's color scheme switching, the comment section remains in its original color mode.
Attempted (Unsuccessful) Solutions

Using JavaScript to Listen for Mode Switch and Refresh Comment Section
An attempt was made to use JavaScript to listen for a switch in color mode and refresh the Giscus comment section upon switch. This worked on desktop but not on mobile.

Using Double iframe Switching
A method was considered where two iframes of the Giscus comment section (one for dark mode, one for light mode) would be placed on the page and switched between upon color mode switching. This method was deemed too complex and potentially impactful on page performance, so it was not pursued further.

Attempting to Modify Giscus Source Code
There was consideration to directly modify the source code of Giscus to resolve the issue. However, as Giscus is a third-party service, its source code cannot be directly modified.

Successful Solution

Identifying the Correct Mobile Toggle Selector
Through inspecting the HTML, it was found that the mobile color mode toggle button used an id (mobile-toggle-theme) instead of a class. Therefore, the correct selector needed to be used to select this element.

Using JavaScript to Refresh the Page
Upon color mode switching, JavaScript is used to refresh the entire page, not just the comment section. This way, the comment section reloads under the new color mode.

Final Code Implementation
Add the following code to your HTML or JavaScript file:
document.addEventListener('DOMContentLoaded', function () {
    // Select the desktop color mode toggle button
    const toggleDesktop = document.querySelector('label[for="switch_default"]');
    // Select the mobile color mode toggle button
    const toggleMobile = document.querySelector('#mobile-toggle-theme'); // Using ID selector

    // Define a function to handle color mode switching and page refresh
    function handleToggle() {
        location.reload();
    }

    // If the desktop button is found, add a click event listener
    if (toggleDesktop) {
        toggleDesktop.addEventListener('click', handleToggle);
    }

    // If the mobile button is found, add a click event listener
    if (toggleMobile) {
        toggleMobile.addEventListener('click', handleToggle);
    }
});

This code first attempts to select the desktop and mobile color mode toggle buttons. Once the button is clicked, the handleToggle function is called, refreshing the entire page. This way, the comment section reloads under the new color mode on both desktop and mobile.
Note
While this solution works, it is admittedly a bit of a hack and not the most elegant or user-friendly solution due to the entire page reloading upon a color mode switch. It's a somewhat "ugly" implementation and I am still in search of a better, smoother method to achieve the desired outcome without needing to refresh the entire page. Any further suggestions or solutions are most welcome!
I hope this summary clearly reflects the entire process of resolving the issue! If you have any further questions or concerns, feel free to let me know!

Hey @greendolphindance
I hope I can help a bit, as I managed to sync the theme switching between the site and the theme.
There are two important parts:

The JS for the theme switcher
The JS for loading Giscus

I communicate events between them (theme switcher -> giscus) with a custom event listener, like this:
        window.addEventListener('themeChanged', (event) => {
            const selectedTheme = event.detail.theme === 'dark' ? darkTheme : lightTheme;
            setGiscusTheme(selectedTheme);
        });

And I set the proper theme initially with:
        const currentTheme = document.documentElement.getAttribute('data-theme') || 'light';
        const selectedTheme = currentTheme === 'dark' ? darkTheme : lightTheme;
        script.setAttribute('data-theme', selectedTheme);

You can see this in the context of the script here.
As for the theme switcher, it needs to send this custom event. I did it like this:
    const event = new CustomEvent("themeChanged", {
        detail: { theme: theme }
    });
    window.dispatchEvent(event);

See it in context in this file.
Let me know if that helps!
P.S: If you want to understand my entire theme switching setup, there's a third piece: the theme initialiser. As the name implies, it sets up the proper theme before the page is even rendered. This avoids flashing the wrong theme. The code is here.

I would like to implement this on my website, but it is well beyond my understanding on Hugo, HTML, CSS, JS, etc. to implement. So I'm following along and would definitely appreciate this to be laid out for a layman like myself.

I recently added giscuss to my blog and I was having the same issue. To solve that I had to:

Adjust the template where I add the giscuss script

<script>
  var theme = localStorage.getItem('theme') == null ? 'light' : 'dark_dimmed';
</script>

<div class="container">
  ... giscus script here ...
</div>

<script>
  document.querySelector('script[src="https://giscus.app/client.js"]').setAttribute('data-theme', theme);
</script>

Adjust the script that is triggered when the user clicks the theme switch button

// Theme Switcher
  function darkMode() {
    if (html.classList.contains('dark-mode')) {
      html.classList.remove('dark-mode');
      localStorage.removeItem("theme");
      document.documentElement.removeAttribute("dark");
      setGiscusTheme('light');
    } else {
      html.classList.add('dark-mode');
      localStorage.setItem("theme", "dark");
      document.documentElement.setAttribute("dark", "");
      setGiscusTheme('dark_dimmed');
    }
  }

  // Set Theme giscus theme
  function setGiscusTheme(theme) {
    var iframe = document.querySelector('.giscus-frame');

    if (iframe) {
      var url = new URL(iframe.src);
      url.searchParams.set('theme', theme);
      iframe.src = url.toString();
    }
  }

I documented the process on my blog as well https://thiagoalves.ai/adding-comments-to-jekyll-using-giscus

Thank you @avsthiago! That worked for me.
I was actually able to implement this without adjusting the javascript run when the button is pressed because (for the Hugo theme I use, at least), pressing the theme switcher button set the value for 'appearance' to either "light" or "dark", so I just made the following minor change to your code for the Giscus script:
    var theme = localStorage.getItem('appearance') == 'light' ? 'light' : 'dark_dimmed';

help me on vitepress

@avsthiago Thanks for taking the time to write this down. 🙇
For me the example didn't work put pointed me in the right direction and eventually this is that worked: https://github.com/pmalek/KeepIt/commit/f9055bd1992c58daca1f8930b3bf778c5c5b612b


Use FireNet player by default

Released in https://github.com/afrostalin/FireNET/commit/776401224cdb4a2190f30c5ed85ab19106c06291


Ubuntu red squiggles headers even when cpp_properties has been updated. And its supposed to find recursivley anyway.

Issue Type: Bug
Place header in sub folder "public/mysdk/header.h".
Ensure cpp_properties are set.
Include the header in a cpp file with angle brackets <mysdk/header.h> as you would with an sdk header.
VS Code version: Code 1.21.1 (79b44aa704ce542d8ca4a3cc44cfca566e7720f1, 2018-03-14T14:46:30.761Z)
OS version: Linux x64 4.13.0-37-generic

System Info

Item
Value

CPUs
Intel(R) Core(TM) i7-7700HQ CPU @ 2.80GHz (8 x 2800)

Load (avg)
0, 0, 0

Memory (System)
15.55GB (9.18GB free)

Process Argv
/usr/share/code/code .

Screen Reader
no

VM
0%

Extensions (10)

Extension
Author (truncated)
Version

vscode-markdownlint
Dav
0.14.1

vscode-m3u
af4
1.0.0

code-gnu-global
aus
0.2.2

githistory
don
0.4.0

Go
luk
0.6.77

vscode-clang
mit
0.2.2

python
ms-
2018.2.1

azure-account
ms-
0.3.3

cpptools
ms-
0.15.0

vscode-arduino
vsc
0.2.11

Reproduces without extensions

Reproduces without extensions

We don't ship any C++ support out of the box, there should not be any squiggles in these files unless you have extensions.

You can report against the cpp extension here https://github.com/Microsoft/vscode-cpptools/issues


PureJavaSnappy causes BufferUnderflowException when reading w/ hadoop-common's SnappyCodec

I'm using hadoop-common to uncompress the hadoop snappy format since this library doesn't appear to support reading Hadoop-compatible data.
That library uses snappy-java in the SnappyCodec.
This works for me when the native snappy is available (I reuse the codec object, but I put it in the method to keep the sample shorter):
public byte[] decompressSnappy(byte[] in) throws IOException {
  SnappyCodec codec = new SnappyCodec();
  codec.setConf(new Configuration());
  try (InputStream stream = codec.createInputStream(new ByteArrayInputStream(in));) {
      return stream.readAllBytes();
  }
}

SnappyNative works perfectly, but when PureJavaSnappy is used I get a BufferUnderflowException.
After a painful debugging session I found that it seemed to be caused by the hadoop-common's SnappyDecompressor.decompressDirectBuf calling Snappy.uncompress, which calls PureJavaSnappy.rawUncompress, which left the uncompressed buffer in an inconsistent state.
With SnappyNative I saw "uncompressed position=14454, remaining=0, limit=14454"
With PureJavaSnappy I saw "uncompressed pos=14454, remaining=14454, limit=14454"
The next call to uncompressedDirectBuf.get triggered the BufferUnderflowException, with
uncompressed.get(0, 8192) called while the buffer had position=14454, remaining=0, limit=14454.

Dropped the pure-java support in https://github.com/xerial/snappy-java/releases/tag/v<IP_ADDRESS>


daemon: improve debugging line

When setting DEBUG=verbose, this only activates bash tracing with set
-x. This patch adds more info during the debug like the name of the
script and the line being executed. See:
$ ./a.sh
+./a.sh:6: echo a
a
Signed-off-by: Sébastien Han<EMAIL_ADDRESS>

anythin you pass on the command line (e.g., CEPH_ARGS="--debug-ms 1 --debug-osd 10")

@liewegas alright thanks, will rework this then.


Make CSS more consistent and simplify linting code.

Automated message from Dropbox CLA bot
@showell, it looks like you've already signed the Dropbox CLA. Thanks!


Wheel build for 8.0.0 on macos x86_64 is failing tests

See: https://github.com/GraphBLAS/python-suitesparse-graphblas/actions/runs/5035542365/jobs/9031130433
Raw log attached for posterity: macos_x86_64_log.txt
Looks like something bad is happening in test_matrix_binfile_read_write.

I'm not sure if there is anything useful here, but I dumped the JIT config for the failing wheel build: https://github.com/GraphBLAS/python-suitesparse-graphblas/actions/runs/5161271671/jobs/929812306
===================================
  Printing default JIT configurations
  -----------------------------------
  JIT_C_CONTROL on
  JIT_USE_CMAKE False
  JIT_C_COMPILER_NAME /Applications/Xcode_14.2.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/cc
  JIT_C_COMPILER_FLAGS -arch x86_64 -O3 -DNDEBUG -Xclang -fopenmp -I/usr/local/opt/libomp/include  -fPIC  -arch x86_64  -isysroot /Applications/Xcode_14.2.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX13.1.sdk
  JIT_C_LINKER_FLAGS -L/usr/local/opt/libomp/lib -dynamiclib
  JIT_C_LIBRARIES  -lm -ldl -lomp
  JIT_C_CMAKE_LIBS m;dl;omp
  JIT_C_PREFACE
  JIT_ERROR_LOG
  JIT_CACHE_PATH /Users/runner/.SuiteSparse/GrB8.0.1
  ===================================

Anecdotally I noticed that, at least for C++, builds on macOS seem to be a lot less tolerant of things like out-of-bounds memory accesses. Even reads. Usually on Linux and Windows you have to write to an entirely different page to trigger a segfault, it seems like surprisingly often a single byte out of range is enough to crash on macOS.
So maybe this is an upstream bug in eWiseMult that is just being caught on this platform. The JIT is new code, after all.


Release Should Accept Strings

In the read-me it states that release takes a strings but when I tried this it only takes numerics.
It should use strings to allow for pre-release versions etc. I'll create a PR for this now hopefully.

Haha and as I sit to try this - I see that actually it is an rpm-rs issue. Will file this with them as well.

Hi,
I've released a new version of rpm-rs which allows you to use strings for release.


chore: release 1.1.1

:robot: I have created a release *beep* *boop*
1.1.1 (2022-11-24)
Feature Improvements

fix bug (c0410ab)

This PR was generated with Release Please. See documentation.

:robot: Release is at https://github.com/Galaxy-Wish-Star/E-commerce/releases/tag/v1.1.1 :sunflower:


chore(ContentBlockCards): update styles and storybook layout

Related Ticket(s)
#5533
Description
Fixes card styles in content-block-* components, as well as Storybook layout for ContentBlockCards.
Changelog
Changed

add max-width for Card CTA in content block components
update Storybook layout for web components content-block-cards

Thank you, @kennylam! I tested the Web Components, the Web Comp - React wrapper doesn’t have this card, the HTML Test application doesn’t have it, and the Codesandbox examples have that 100% height cards issue.
So this is the small issue that needs to be addressed:

On smaller viewports than xlg for the desktop, still the card needs to be 4 cols plus the overhangs. Now it applies the 320 as min-width also.

1. React
1.A. Content block cards
1.A.1. Mobile sm - card should be overhang left and right, full width, with a max-width of 320px (for big mobile)

1.A.2 Big Mobile sm - 671 - should have max-width and overhang

1.A.3 Big Medium md - 1055 - the max-width is not applied

1.A.4 Desktop lg 1056 is not quite 4 columns.

1.B. Content block media
1.B.1. Breakpoint lg 1056, apply here the 4 columns with overhangs rule, too. 320px is max-width, but it is lower on lg.

1.B.2. Big Mobie sm - 671 - should have max-width of 320

1.C. Content block mixed, Content block segmented, Content block simple:
Same issues signaled in the following images:

2. Web Components
2.A. Content block cards
Here, page is not aligned to grid as it should be, but this is another issue. On mobile, it should overhang, and on lg 1056 it should occupy 4 columns, as 320 is max-width.

Moving it to the next release so we can address it for all content-block-* comps.


⚠ Bofrost.at has degraded performance

In 4b40381, Bofrost.at (https://www.bofrost.at) experienced degraded performance:

HTTP code: 200
Response time: 1013 ms

Resolved: Bofrost.at performance has improved in dc8bab1.


Configure Azure Pipelines

This pipeline configuration builds the application and produces a build for the Release configuration.

 Thank you for your submission, we really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.:x: akhverma1997 sign nowYou have signed the CLA already but the status is still pending? Let us recheck it.


Please create a new repo 'sensu-plugins-gpg-keys-check'

Hi Sensu Community Plugins team,
I developed check-gpg-expiry.rb script which checks all public or secret GPG keys' expiry dates and sends appropriate alerts to Sensu client. I also developed check-gpg-expiry-spec.rb script which ensures that the check-gpg-expiry.rb script works properly.
I would like to contribute them to a new repo 'sensu-plugins-gpg-keys-check' in Sensu Community Plugins GitHub.
Could you please help to create a new repo in Sensu Community Plugins so that I can upload all my files to the repo.
Kind regards,
Aditya

There is already one. https://github.com/sensu-plugins/sensu-plugins-gpg

closing per: https://github.com/sensu-plugins/sensu-plugins-feature-requests/issues/15#issuecomment-279741165


Adds components to render resource template value constraint properties

Fixes #123

adds carrier property to static resource template json in Editor.jsx
adds a new <ValueConstraints /> component with sub-components:

<ValueTemplateRefs />
<UseValuesFrom />
<ValueDataTypes />
<Defaults />

function to check whether a hash has a key/value pair, used for conditional display
test that uses enzyme full rendering with mount and a way to test a component's properties directly.

Coverage remained the same at 0.976% when pulling a64720dfe4b40f87433f5f56cd4e4371ccceb6eb on value-constraints into 199a3dd0f88dc59fa79f0ba867c91347a0f64b5c on master.

I'm now wondering to what extent we want to abstract the parsing of profiles so that we are not dependent on the specific "profile editor" schema? Right now we are setting the props to be the specific profile name/values. Should we just loop through all of the name/values and display them? FWIW, the BFW does not actually do this either. It also looks for specific name/values from the expected profile.


Can't get the project to run locally.

Node version: v18.18.1
NPM: 9.8.1
Steps followed:

Forked the repository
Ran npm install in the root directory
Ran npm start -w docs

Error: Cannot find package 'C:\Users\Kevin\Documents\stylex\node_modules\@stylexjs\babel-plugin\' imported from C:\Users\Kevin\Documents\stylex\apps\docs\babel-virtual-resolve-base.js
Am I missing a step? It seems every command I try (build) results in some sort of error.
https://github.com/facebook/stylex/blob/main/.github/CONTRIBUTING.md

Did you already run npm i at root of the repo?
Otherwise, this feels like a Windows incompatibility. I will find my PC and try to reproduce this issue.

Yeah first thing I di. I will also try to get it working on my macbook. Will get back to you with my results as soon I get the chance

I had the same issue on macOS Ventura 13.3.1. Was able to start the development server after I manually built @stylexjs/babel-plugin, @stylexjs/eslint-plugin, @stylexjs/shared and @stylexjs/stylexjs.

UPDATE: yeah, I seem to be getting similar issues on Mac OS.

@nedjulius
Maybe a silly question, but how exactly do I manually build these?

@nedjulius
Maybe a silly question, but how exactly do I manually build these?

According to the root README, you can either build all packages at once or specify the package name with -w flag. I tried building them all, but it failed (I assume because some of the packages don't have a specified build command) so I just manually built the dependencies in the docs app. I did that by running the npm run build -w <package-name> from the root of the monorepo, where <package-name> stands for those packages that I listed.

Did you build the babel plugin before running the doc?

Hi everyone, I tried the above commands but I'm getting errors. @kevintyj  Can you please help?

Hi everyone, I tried the above commands but I'm getting errors. @kevintyj Can you please help?

I don't see a node_modules folder, did you run npm install?

I haven't run that command. According to the doc that commands on the top so i thaught we need run that first. I will do npm install now.

I'm still having the same issues after running  npm run build -w @stylexjs/stylex -w @stylexjs/shared -w @stylexjs/eslint-plugin -w @stylexjs/babel-plugin
as suggested by @kevintyj

Cannot able to do npm install on windows machine. My node version is 18 and npm version is 9.8

Using the latest version of Node.js won't fix the issue.

We're updating the instructions, but when you first clone the repo the very next steps are:
$ npm install
$ npm run build

You can't build and run the docs website without first running npm run build at the root directory. npm run build will build everything and then you can work on specific parts as needed.

@nmn Yes, using a WSL works. But it would be great to find the issue so we don't have to start a WSL every time.

@weti09 Yes, working on getting this problem solved, but it's good to know that there is a workaround available in the meantime.

Quick Update: I have reproduced the problem and identified the various causes for breakages.
I'm going to describe a workaround here, but I will work to fix at least some of these problems in the repo itself, so you need to handle fewer workarounds manually.
Step 0: Git clone & delete the postinstall script from the root package.json
We need to make some tweaks to the build scripts so we need to ensure that we can install node_modules without triggering a build.
Step 1: Disable every prebuild script in packages.
There is a prebuild script in most of the packages. Rename it to something like pre:build, so it doesn't run automatically before the build script. All the packages except bundler and framework plugins have this script.
Step 2: Install cross-env at root directory
Just run npm i -D cross-env at root of the project
Step 3: Use windows friendly commands withing apps/docs
In the apps/docs/package.json file, replace rm -rf with rimraf and replace NODE_ENV=... with cross-env NODE_ENV=...

Now, hopefully, running npm run build from the root of the project should run successfully.
Don't include any of the package.json file changes in your commits or PRs.
Please don't include any changes to the package.json (or package-lock) files in your commits as these are all workarounds and not meant to be merged into the repo haphazardly.
Ramifications
The primary loss of functionality will be the lack of the generation of type definition files for Flow and Typescript. In practice, Flow has been configured to read the types from
the source files directly so there is no need to generate Flow type definition files to get
type-checking while contributing code. gen-types is only really necessary for publishing
to NPM.
The one piece of lost functionality is typescript types that are made available to the NextJS example app. This is unavoidable until we find a solution to making gen-types work on Windows.
Next steps
I will add fixes with rimraf and cross-env by tomorrow.
I will think about the best approach for dealing with gen-types.

Maybe add a link to the workaround in the Contribution Guide (if not already done)? This would help avoid more questions about this until more fixes are available.

I hope to fix everything such that no workarounds are needed.


feat: add s3 resource client

Signed-off-by: Jim Ma<EMAIL_ADDRESS>
Description

Related Issue
#1514
Motivation and Context

Screenshots (if appropriate)
Types of changes

[ ] Bug fix (non-breaking change which fixes an issue)
[ ] New feature (non-breaking change which adds functionality)
[ ] Breaking change (fix or feature that would cause existing functionality to change)
[ ] Documentation Update (if none of the other choices apply)

Checklist

[ ] My change requires a change to the documentation.
[ ] I have updated the documentation accordingly.
[ ] I have read the CONTRIBUTING document.
[ ] I have added tests to cover my changes.

Codecov Report

Merging #1826 (240e1c6) into main (3ea1dea) will decrease coverage by 0.04%.
The diff coverage is n/a.

:exclamation: Current head 240e1c6 differs from pull request most recent head 13a2b24. Consider uploading reports for the commit 13a2b24 to get more accurate results

@@            Coverage Diff             @@
##             main    #1826      +/-   ##
==========================================
- Coverage   43.61%   43.56%   -0.05%
==========================================
  Files         128      128
  Lines       16050    16050
==========================================
- Hits         7000     6992       -8
- Misses       8517     8523       +6
- Partials      533      535       +2

Flag
Coverage Δ

Object-compatibility-e2etests
?

e2etests
?

unittests
43.56% <ø> (-0.05%)
:arrow_down:

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files
Coverage Δ

...ent/daemon/peer/peertask_piecetask_synchronizer.go
49.54% <0.00%> (-0.92%)
:arrow_down:

client/daemon/peer/piece_manager.go
52.99% <0.00%> (-0.41%)
:arrow_down:

client/daemon/peer/peertask_conductor.go
56.67% <0.00%> (-0.15%)
:arrow_down:


[Suggestion] Make it more clear when a command succeded

It's hard to tell when a command was entered correctly and actually started the timer.
Maybe add a green flash by the background of the command line? Maybe clear the console when you press enter?
Thanks so much, love the app <3

+++

Yeah sorry about that. I wasn't aware of the console not clearing upon command entry. On Linux (what I use), it works alright. I don't have a way to test on Windows or macOS, unfortunately.

If I get some time, I cant take a look at it if you're accepting PR's <3

PR's are welcome :)

I use the app on Windows and Linux and my console clears up effectively. Although I would really like some kind of indicator about the timer being started. Top-border slide-in notification on the gray/green background saying:
"Task timer <name> has started!"
or something close to that.

I'm still working on that. I used to have this feature where the whole screen shows a timer and what activity is being logged. It was removed because I couldn't decide on the design haha. I'm thinking of bringing it back.
https://twitter.com/joshavanier/status/926092656983252992

Notifications now appear when entries are started and ended


Add a new page to display all contributors done ! #61 ✨

Hello, PR
Add new Contributors page - #61
Add Contributors page done - It display all Contributors

Page link in footer..

@Akshat111111 done, please merge my PR with level 3,
you can check my code...


Facilitate asynchronous realtime ingestion on decoding & transformation

ingestion enhancement feature request
Resolving issues mentioned in https://github.com/apache/pinot/issues/13319.
Pinot ingestion is currently using a strictly serial processing. It fetches a batch of messages from Kafka and then for messages in the batch, it would process one by one with the order of offsets to:

Decode
Transform
Index

It provides benefits to reuse the objects created in between to achieve better memory efficiency but not able to utilize all system resources. There are multiple solutions with their pros and cons:

Async processing for each step as this patch introduced.

It could still preserve the same order of messages and retain same offset control logics.
It still could not fully utilize the system resources.
It brings overhead on memory and GC as not able to reuse objects as before. (There could be TODOs to make size of each batch configurable)

Batch (multiple executors) processing on decoding and transformation.

Hard to ensure the order of messages, it might only do at least once consumption instead of current (almost) exact once.

Full batch process on all 3 steps.

Current indexing logics and data structures do not really support parallel processing.

Comparing the CPU usage and consumption speed on same server before and after (at 10:00) enabling "ASYNCHRONOUS":

The more CPU usage contributes a ~10% ingestion speed increase.
Notes:
The new mode is better performed on computation heavy ingestion but cannot really help on light weight use cases. In light computation use cases, the extra memory and GC overhead would compensate the async process gain.

Codecov Report
Attention: Patch coverage is 0% with 177 lines in your changes missing coverage. Please review.

Project coverage is 0.00%. Comparing base (59551e4) to head (c3ca31a).
Report is 804 commits behind head on master.

Files
Patch %
Lines

...a/manager/realtime/RealtimeSegmentDataManager.java
0.00%
168 Missing :warning:

...ot/spi/config/table/ingestion/IngestionConfig.java
0.00%
6 Missing :warning:

...able/ingestion/DecodeTransformIndexModeConfig.java
0.00%
3 Missing :warning:

:exclamation:  There is a different number of reports uploaded between BASE (59551e4) and HEAD (c3ca31a). Click for more details.
HEAD has 48 uploads less than BASE

Flag
BASE (59551e4)
HEAD (c3ca31a)

integration
7
2

integration2
3
2

temurin
12
2

java-21
7
2

skip-bytebuffers-true
3
1

skip-bytebuffers-false
7
1

unittests
5
0

unittests1
2
0

java-11
5
0

unittests2
3
0

integration1
2
0

custom-integration1
2
0

Additional details and impacted files
@@              Coverage Diff              @@
##             master   #13695       +/-   ##
=============================================
- Coverage     61.75%    0.00%   -61.76%
=============================================
  Files          2436     2480       +44
  Lines        133233   137074     +3841
  Branches      20636    21335      +699
=============================================
- Hits          82274        0    -82274
- Misses        44911   137074    +92163
+ Partials       6048        0     -6048

Flag
Coverage Δ

custom-integration1
?

integration
0.00% <0.00%> (-0.01%)
:arrow_down:

integration1
?

integration2
0.00% <0.00%> (ø)

java-11
?

java-21
0.00% <0.00%> (-61.63%)
:arrow_down:

skip-bytebuffers-false
0.00% <0.00%> (-61.75%)
:arrow_down:

skip-bytebuffers-true
0.00% <0.00%> (-27.73%)
:arrow_down:

temurin
0.00% <0.00%> (-61.76%)
:arrow_down:

unittests
?

unittests1
?

unittests2
?

Flags with carried forward coverage won't be shown. Click here to find out more.

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

cc: @sajjad-moradi

Is is useful to create a sub-class of RealtimeSegmentDataManager that consumes asynchronously?

To ensure the ingestion order, we might be able to use a producer-consumer pattern, where consumer thread creates MessageBatchs and put them into a queue; another ingestion thread pull MessageBatchs from the queue, transform the records and index them into segment. This way we can use 2 threads per partition.

To ensure the ingestion order, we might be able to use a producer-consumer pattern, where consumer thread creates MessageBatchs and put them into a queue; another ingestion thread pull MessageBatchs from the queue, transform the records and index them into segment. This way we can use 2 threads per partition.

Thanks for the review. Right now, it is only using 1 thread to guarantee the order. For multiple threads, I am thinking about adapting the way mentioned in Multi-topic ingestion support if it goes through the review.


"return: can only `return' from a function or sourced script" from  update_dart_sdk.sh

~/git$ flutter doctor -v
Downloading Linux x64 Dart SDK from Flutter engine d98926c32ee7f5efb1de322163a5315e7ab74297...
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
 33  240M   33 81.0M    0     0  2583k      0  0:01:35  0:00:32  0:01:03 4080k
curl: (56) OpenSSL SSL_read: Connection reset by peer, errno 104
/usr/local/google/home/fujino/git/flutter/bin/internal/update_dart_sdk.sh: line 156: return: can only `return' from a function or sourced script

... (more)

The offending line is https://github.com/flutter/flutter/blob/master/bin/internal/update_dart_sdk.sh#L156

same here. I used 3.13.8 with fvm.

I have fixed my issue. My issue was my mistake. I mistakenly used the Chinese version of Flutter in my environment variables. I have removed it, setting the default source, which solved my issue.


[17.09] irssi 1.0.7

Motivation for this change
fixes CVE-2018-7050, CVE-2018-7051, CVE-2018-7052, CVE-2018-7053, CVE-2018-7054
Things done

[X] Tested using sandboxing (nix.useSandbox on NixOS, or option build-use-sandbox in nix.conf on non-NixOS)
Built on platform(s)

[X] NixOS
[ ] macOS
[ ] other Linux distributions

[ ] Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
[ ] Tested compilation of all pkgs that depend on this change using nix-shell -p nox --run "nox-review wip"
[X] Tested execution of all binary files (usually in ./result/bin/)
[X] Fits CONTRIBUTING.md.

@GrahamcOfBorg build irssi irssi_fish irssi_otr

Failure on aarch64-linux (full log)
Partial log (click to expand)
Package ‘fish-irssi-20130413-e98156bebd’ in /var/lib/gc-of-borg/nix-test-rs-1/repo/38dca4e3aa6bca43ea96d2fcc04e8229/builder/grahamc-aarch64-community-1/pkgs/applications/networking/irc/irssi/fish/default.nix:4 has an unfree license (‘unfree’), refusing to evaluate.

a) For `nixos-rebuild` you can set
  { nixpkgs.config.allowUnfree = true; }
in configuration.nix to override this.

b) For `nix-env`, `nix-build`, `nix-shell` or any other Nix command you can add
  { allowUnfree = true; }
to ~/.config/nixpkgs/config.nix.

Failure on x86_64-darwin (full log)
Partial log (click to expand)
Package ‘fish-irssi-20130413-e98156bebd’ in /Users/graham/nix-borg/repo/38dca4e3aa6bca43ea96d2fcc04e8229/builder/grahamc-ndnd/pkgs/applications/networking/irc/irssi/fish/default.nix:4 has an unfree license (‘unfree’), refusing to evaluate.

a) For `nixos-rebuild` you can set
  { nixpkgs.config.allowUnfree = true; }
in configuration.nix to override this.

b) For `nix-env`, `nix-build`, `nix-shell` or any other Nix command you can add
  { allowUnfree = true; }
to ~/.config/nixpkgs/config.nix.

@GrahamcOfBorg build irssi irssi_otr

Failure on x86_64-darwin (full log)
Partial log (click to expand)
Package ‘irssi-otr-1.0.2’ in /private/var/lib/ofborg/checkout/repo/38dca4e3aa6bca43ea96d2fcc04e8229/builder/lnl7-mac/pkgs/applications/networking/irc/irssi/otr/default.nix:5 is not supported on ‘x86_64-darwin’, refusing to evaluate.

a) For `nixos-rebuild` you can set
  { nixpkgs.config.allowBroken = true; }
in configuration.nix to override this.

b) For `nix-env`, `nix-build`, `nix-shell` or any other Nix command you can add
  { allowBroken = true; }
to ~/.config/nixpkgs/config.nix.

Failure on x86_64-linux (full log)
Partial log (click to expand)
Package ‘fish-irssi-20130413-e98156bebd’ in /var/lib/gc-of-borg/.nix-test-rs/repo/38dca4e3aa6bca43ea96d2fcc04e8229/builder/rbvermaa-spot/pkgs/applications/networking/irc/irssi/fish/default.nix:4 has an unfree license (‘unfree’), refusing to evaluate.

a) For `nixos-rebuild` you can set
  { nixpkgs.config.allowUnfree = true; }
in configuration.nix to override this.

b) For `nix-env`, `nix-build`, `nix-shell` or any other Nix command you can add
  { allowUnfree = true; }
to ~/.config/nixpkgs/config.nix.

Success on x86_64-darwin (full log)
Partial log (click to expand)
 /nix/store/g5h8sqappi0vbznhrply6cll5gbwk2yq-coreutils-8.28/bin/install -c -m 644 default.theme colorless.theme '/nix/store/jqxkq049gi0rpncgdms9pdp52d127mff-irssi-1.0.7/share/irssi/themes'
make[3]: Leaving directory '/private/tmp/nix-build-irssi-1.0.7.drv-0/irssi-1.0.7'
make[2]: Leaving directory '/private/tmp/nix-build-irssi-1.0.7.drv-0/irssi-1.0.7'
make[1]: Leaving directory '/private/tmp/nix-build-irssi-1.0.7.drv-0/irssi-1.0.7'
glibPreFixupPhase
post-installation fixup
gzipping man pages under /nix/store/jqxkq049gi0rpncgdms9pdp52d127mff-irssi-1.0.7/share/man/
stripping (with flags -S) in /nix/store/jqxkq049gi0rpncgdms9pdp52d127mff-irssi-1.0.7/lib  /nix/store/jqxkq049gi0rpncgdms9pdp52d127mff-irssi-1.0.7/bin
patching script interpreter paths in /nix/store/jqxkq049gi0rpncgdms9pdp52d127mff-irssi-1.0.7
/nix/store/jqxkq049gi0rpncgdms9pdp52d127mff-irssi-1.0.7

Success on x86_64-linux (full log)
Partial log (click to expand)
make[1]: Leaving directory '/tmp/nix-build-irssi-otr-1.0.2.drv-0/irssi-otr-v1.0.2-src'
glibPreFixupPhase
post-installation fixup
shrinking RPATHs of ELF executables and libraries in /nix/store/59x6fprkbkkrgb058mdsfgylnm2xmbhl-irssi-otr-1.0.2
shrinking /nix/store/59x6fprkbkkrgb058mdsfgylnm2xmbhl-irssi-otr-1.0.2/lib/irssi/modules/libotr.so
stripping (with flags -S) in /nix/store/59x6fprkbkkrgb058mdsfgylnm2xmbhl-irssi-otr-1.0.2/lib
patching script interpreter paths in /nix/store/59x6fprkbkkrgb058mdsfgylnm2xmbhl-irssi-otr-1.0.2
checking for references to /tmp/nix-build-irssi-otr-1.0.2.drv-0 in /nix/store/59x6fprkbkkrgb058mdsfgylnm2xmbhl-irssi-otr-1.0.2...
/nix/store/gl2czd8xzkj91fca18n4cc9ihni570m7-irssi-1.0.7
/nix/store/59x6fprkbkkrgb058mdsfgylnm2xmbhl-irssi-otr-1.0.2

Success on x86_64-linux (full log)
Partial log (click to expand)
/nix/store/gl2czd8xzkj91fca18n4cc9ihni570m7-irssi-1.0.7

Success on aarch64-linux (full log)
Partial log (click to expand)
these derivations will be built:
  /nix/store/cawcp4n1y6hbiadavzb9mrscssp2dh0w-irssi-1.0.7.drv
waiting for locks or build slots...
/nix/store/nzkwhns1g2fpqhvzm68qy7bczlh0zvld-irssi-1.0.7

Success on aarch64-linux (full log)
Partial log (click to expand)
make[1]: Leaving directory '/build/irssi-otr-v1.0.2-src'
glibPreFixupPhase
post-installation fixup
shrinking RPATHs of ELF executables and libraries in /nix/store/6i085f78wpzwrkwgsp6y0gvwcgyy7zz8-irssi-otr-1.0.2
shrinking /nix/store/6i085f78wpzwrkwgsp6y0gvwcgyy7zz8-irssi-otr-1.0.2/lib/irssi/modules/libotr.so
stripping (with flags -S) in /nix/store/6i085f78wpzwrkwgsp6y0gvwcgyy7zz8-irssi-otr-1.0.2/lib
patching script interpreter paths in /nix/store/6i085f78wpzwrkwgsp6y0gvwcgyy7zz8-irssi-otr-1.0.2
checking for references to /build in /nix/store/6i085f78wpzwrkwgsp6y0gvwcgyy7zz8-irssi-otr-1.0.2...
/nix/store/nzkwhns1g2fpqhvzm68qy7bczlh0zvld-irssi-1.0.7
/nix/store/6i085f78wpzwrkwgsp6y0gvwcgyy7zz8-irssi-otr-1.0.2


Release Google.Cloud.Filestore.V1 version 2.3.0

Changes in this release:
New features

Added REGIONAL tier support in the v1 API (commit e6cd7ec)

Created release for Google.Cloud.Filestore.V1-2.3.0


BUG: SVD-LOBPCG benchmarks sparse_linalg_svds.py

Reference issue
Closes gh-18945
What does this implement/fix?
Originally attempted in https://github.com/scipy/scipy/pull/19292 to add a separate unit test checking the accuracy of the iterative solvers. However, one cannot open a file with test matrices from benchmarking in a unit test, since the benchmark directory outside of the scipy main tree. So this PR adds a rudimentary accuracy check directly to benchmarking, just like in  https://github.com/scipy/scipy/pull/18954

@tylerjereddy from the PR description:
"Originally attempted in https://github.com/scipy/scipy/pull/19292 to add a separate unit test checking the accuracy of the iterative solvers. However, one cannot open a file with test matrices from benchmarking in a unit test, since the benchmark directory outside of the scipy main tree."

I'm not sure why you'd try that in the first place, I just mean that you could effectively use code duplication (or abstraction, but in the other direction SciPy lib-> benchmarks) to test what you benchmark without any cross-talk between the suites. I'm not saying that's what you should do, but it did cross my mind if it could be done concisely.

@lobpcg We agreed about adding asserts and stuff here on the premise that it was about keeping the benchmark in working order. If you are changing your mind and using it as a replacement for a proper unit test, we don't agree. If you need this tested, make a unit test. If you need data files in the unit test suite, put them there.

@rkern - this benchmarking is NOT in working order, although the trouble is now hidden alter turning off globally all warnings in benchmarking. The benchmark needs to be fixed and the asserts will be used to make sure that the fix is valid, as described in https://github.com/scipy/scipy/issues/18945
@tylerjereddy At the same time, I see additional value in running these examples with various parameters in a unit test, but that I now feel would be better for a separate issue/PR, also requiring access to somehow read the file with matrices, which currently is located in benchmarks/benchmarks/svds_benchmark_files/svds_benchmark_files.npz and thus is not readable from scipy/sparse/linalg/_eigen/tests/test_svds.py

Move the file into the tests/ directory. This PR is not a replacement for #19292.

This pull request is still a work in progress. Please wait till it is marked as ready for review.

@j-bowhay CircleCI config appears to still be broken?

@j-bowhay great, thanks for your help!

Done, ready for the final review.

This PR is completed 3 months ago now. Could someone review it and consider merging?

Could someone review it and consider merging?

I did review, and not everything is done yet.

Also, we're getting the following in the benchmark job:
[33.33%] ··· sparse_linalg_svds.BenchSVDS.time_svds                20/30 failed
[33.33%] ··· ==== ========== ======== ======== ==========
             --                         solver
             --------------- ----------------------------
              k    problem    arpack   lobpcg     svd
             ==== ========== ======== ======== ==========
              20    abb313    failed   failed   6.61±0ms
              20   illc1033   failed   failed   46.1±0ms
              20   illc1850   failed   failed   345±0ms
              20    qh1484    failed   failed   1.39±0s
              20   rbs480a    failed   failed   85.4±0ms
              20   tols4000   failed   failed     n/a
              20   well1033   failed   failed   65.6±0ms
              20   well1850   failed   failed   366±0ms
              20   west0479   failed   failed   59.4±0ms
              20   west2021   failed   failed   3.94±0s
             ==== ========== ======== ======== ==========
             For parameters: 20, 'abb313', 'arpack'
             asv: benchmark timed out (timeout 60.0s)

             For parameters: 20, 'abb313', 'lobpcg'
             asv: benchmark timed out (timeout 60.0s)

             [...]

which is presumably also what's causing the whole job to fail.

@h-vetinari could you please close those discussions where you are satisfied with my response to minimize the clutter?
It is your suggestion to use the 'if' that makes all tests to fail and I guess stops the benchmark. The benchmark runs with my original 'assert' in the latest commit, but maybe the error message gets indeed eaten as you conjecture?
Ideally, I would like to see something like n/a in the table where the test cannot reach the tolerance. I don't know how to do it.
I am still unable to install asv locally in a proper way, so have to rely on circleci here to run the benchmark...

Here is the present output:
[```
33.33%] ··· sparse_linalg_svds.BenchSVDS.time_svds                          ok
[33.33%] ··· ==== ========== ========== ========== ========== ==========
--                                 solver
--------------- -------------------------------------------
k    problem    propack     arpack     lobpcg      svd
==== ========== ========== ========== ========== ==========
20    abb313    6.62±0ms   7.66±0ms   62.5±0ms   6.92±0ms
20   illc1033   13.3±0ms   12.7±0ms   236±0ms    45.0±0ms
20   illc1850   37.1±0ms   24.0±0ms   239±0ms    342±0ms
20    qh1484    9.87±0ms   9.53±0ms   29.4±0ms   1.31±0s
20   rbs480a    15.3±0ms   18.8±0ms   480±0ms    65.9±0ms
20   well1033   9.92±0ms   11.5±0ms   197±0ms    43.0±0ms
20   well1850   23.7±0ms   20.5±0ms   334±0ms    339±0ms
20   west0479   4.74±0ms   6.47±0ms   20.5±0ms   64.8±0ms
==== ========== ========== ========== ========== ==========
LGTM. If any of the solvers would not converge for a problem, the table entry would be "failed", but the `maxiter`, `tol` and timing are collectively tuned for that not to happen with the present revisions of the solvers.


Accept new type of certificates

Current Implementation

Corona test stations enter their certificates. User can lookup and present qr-code of result.
Suggested Enhancement

CWA should accept prescriptions from doctors for their patients.
Expected Benefits
Replacing obligate E-Rezept solution by a free one.
Looking forward for discussion.
Now is the right time and here is the right place and CWA team is the right admin.
Urgent.

Thanks for your suggestion @gitbrueck. We have created an internal ticket for it and will raise this topic internally.
Internal Tracking ID: EXPOSUREAPP-11343

Corona-Warn-App Open Source Team


Python script from ModSecurity

Hi All,
I have to configure a rule that it calls a python script and it has to elaborate the return of this script. At the moment I write this:
SecRule REQUEST_HEADERS:Content-Type "application/json" "id:'1000003',phase:4,log,setenv:richiesta=%{STREAM_INPUT_BODY},exec:/etc/modsecurity/includes/pythons/test.py"
It works correctly (it has been execute by apache and it logs some phrases on my trace) but I don't know how give the output and use it.
Can you help me please?
Thanks
Andrea

ModSecurity does not support receiving the stdout of scripts like this. You may consider dealing with LUA to get direct access to variables.

Whats is Python branch?

https://github.com/SpiderLabs/ModSecurity/tree/experimental_python_support

Can you explain me better please?

it is an experimental branch without documentation/support that provides support for using python in similar ways you can use LUA now giving you access to modsecurity variables. You can use similar logic within libmodsecurity.

Ok, I understand this.
I can execute yet a Python script, but how can I link this to modsecurity rules?

huh?

I wrote a Python script that it works fine with modsecurity, I wrote rule with exec action that it sends a buffer to this script. The script elaborates this buffer and logs in my trace. My problem is the comunication from script to modsecurity. Are there any metodology to return anything?

The script you execute must write something (anything) to stdout; if it doesn’t, ModSecurity will assume that the script failed, and will record the failure.

My script print a string in stdout, and it works fine. My problem is: how have I to do to deny a request from modsecurity from my script?

giving no output will be treated as false whereas output to stdout will be treated as success.


JAVA-2402

@olim7t My thinking was to merge this via a squash merge, so in that case I can add the ticket number + description as part of the squashed commit.  That should address your concern about the title of this PR... unless you guys don't use squash merges in general, in which case I'll need to come up with another plan. :)

As long as this ends up as a single commit on 4.x with the subject JAVA-2402: Add setTracing(boolean) to StatementBuilder, any method works for me :)

Nit: next time, please put the ticket description in the first line of the commit message, so that it shows in github default view / git log --pretty=oneline, etc.


Need a public API to measure the layout

In GUI frameworks an important concept is called preferred size, which is the best size that an GUI element can fit all its content. However it is quite tricky to implement when using Yoga as layout engine, since it lacks a way to merely measure the layout without actually change the layout.
This is what I have been doing for now:
float Container::GetPreferredHeightForWidth(float width) const {
  float float_max = std::numeric_limits<float>::max();
  YGLayoutNodeInternal(node(), width, float_max, YGDirectionLTR,
                       YGMeasureModeExactly, YGMeasureModeAtMost, float_max,
                       float_max, false, "GetPreferredHeightForWidth");
  return node()->layout.measuredDimensions[YGDimensionHeight];
}

Is it possible to make YGLayoutNodeInternal a public API, and provide APIs to read layout.measuredDimensions? Or is there a better way to do this?
Thanks.

What I use for this is decoupling the calculation from the applying of the layout. I use something like:

float width = preferedWidth > 0 ? preferedWidth : NaN;
float height = preferedHeight > 0 ? preferedHeight: NaN;

YGNodeCalculateLayout(YGNodeRef node,
                           width,
                           height,
                           YGDirectionLTR);

return Size {
 .height = YGNodeLayoutGetHeight(node),
 .width = YGNodeLayoutGetWidth(node)
};

And if you really want to apply this to your ui, I recursivly go done any node and put those values actually on the ui elements.
Besides some (negligible) unnessesary work inside the libary, this works quite well in my projects.
What would be your concerns doing it this way?

One main benefit of doing it this way is that only if you perform a layout all the dirty nodes are marked as non dirty. Which means you can mostly avoid unnessesary recalculations of elements inside your tree which aren't affected by your size constraints.

I didn't know I can pass NaN to YGLayoutNodeInternal, thanks for helping out!


Too much TIME_WAIT connection

Hello!
I try to use your benchmark script with boom. Unfortunatelly my result verry different as yours, So I try to detect the problem and I found many TIME_WAIT tcp connection to the etcd server. I can't modify your script just what I have to (leader and server). I think the boom can reuse the connection but etcd can be able to reuse tcp connections?
https://github.com/coreos/etcd/tree/master/hack/benchmark
Example:
...
tcp        0      0 <IP_ADDRESS>:47340       <IP_ADDRESS>:2379         TIME_WAIT
tcp        0      0 <IP_ADDRESS>:54238       <IP_ADDRESS>:2379         TIME_WAIT
tcp        0      0 <IP_ADDRESS>:60169       <IP_ADDRESS>:2379         TIME_WAIT
....

what benchmark command are you using?

Just run your bech.sh (link in description).

@aga20 What are the versions of boom and etcd you used?

I think boom fixed it last November. https://github.com/rakyll/boom/commit/5d051b61ca6c098f77137c4f6224fa263da365b2
I tried the benchmark script with the latest boom, but don't see any TIME_WAITs anymore.

@xiang90 sorry I forget this.
boom: last I found on github: https://github.com/rakyll/boom (run installation command)
etcd: I try it with a docker container https://quay.io/repository/coreos/etcd?tab=tags from this and without docker 2.1.1 (latest redhat rpm what we found).
@gyuho Then I try to build boom manually and I will try it on Monday because I'm on holiday now. Thanks for your link!

@gyuho @aga20 The default behavior of boom will still cause the TCP connection not able to be reused. You need to pass in the flag readall=true

I am verifying that right now if the newer boom resolves this issue. I will
keep you updated.
On Fri, Jan 8, 2016 at 9:57 AM, Sandor Szombat<EMAIL_ADDRESS>wrote:

@xiang90 https://github.com/xiang90 sorry I forget this.
boom: last I found on github: https://github.com/rakyll/boom (run
installation command)
etcd: I try it with a docker container
https://quay.io/repository/coreos/etcd?tab=tags from this and without
docker 2.1.1 (latest redhat rpm what we found).
@gyuho https://github.com/gyuho Then I try to build boom manually and I
will try it on Monday because I'm on holiday now. Thanks for your link!
—
Reply to this email directly or view it on GitHub
https://github.com/coreos/etcd/issues/4172#issuecomment-170074479.

--
Sincerely,
Gyu-Ho Lee

WIth newer version, I still see lots of TIME-WAITs.
@aga20 Could you also try the newest boom with -readall=true and
check if you still see those TIME-WAITs? I will investigate more.
Thanks!

You can do something like:
#!/bin/bash -e

leader=http://<IP_ADDRESS>:12379
# assume three servers
servers=( http://<IP_ADDRESS>:12379 http://<IP_ADDRESS>:22379 http://<IP_ADDRESS>:32379 )

keyarray=( 64 256 )

for keysize in ${keyarray[@]}; do

  echo write, 1 client, $keysize key size, to leader
  ./boom_new -readall=true -m PUT -n 10 -d value=`head -c $keysize < /dev/zero | tr '\0' '\141'` -c 1 -T application/x-www-form-urlencoded $leader/v2/keys/foo | grep -e "Requests/sec" -e "Latency" -e "90%" | tr "\n" "\t" | xargs echo

  echo write, 64 client, $keysize key size, to leader
  ./boom_new -readall=true -m PUT -n 640 -d value=`head -c $keysize < /dev/zero | tr '\0' '\141'` -c 64 -T application/x-www-form-urlencoded $leader/v2/keys/foo | grep -e "Requests/sec" -e "Latency" -e "90%" | tr "\n" "\t" | xargs echo

  echo write, 256 client, $keysize key size, to leader
  ./boom_new -readall=true -m PUT -n 2560 -d value=`head -c $keysize < /dev/zero | tr '\0' '\141'` -c 256 -T application/x-www-form-urlencoded $leader/v2/keys/foo | grep -e "Requests/sec" -e "Latency" -e "90%" | tr "\n" "\t" | xargs echo

  echo write, 64 client, $keysize key size, to all servers
  for i in ${servers[@]}; do
    ./boom_new -readall=true -m PUT -n 210 -d value=`head -c $keysize < /dev/zero | tr '\0' '\141'` -c 21 -T application/x-www-form-urlencoded $i/v2/keys/foo | grep -e "Requests/sec" -e "Latency" -e "90%" | tr "\n" "\t" | xargs echo &
  done
  # wait for all booms to start running
  sleep 3
  # wait for all booms to finish
  for pid in $(pgrep 'boom'); do
    while kill -0 "$pid" 2> /dev/null; do
      sleep 3
    done
  done

  echo write, 256 client, $keysize key size, to all servers
  for i in ${servers[@]}; do
    ./boom_new -readall=true -m PUT -n 850 -d value=`head -c $keysize < /dev/zero | tr '\0' '\141'` -c 85 -T application/x-www-form-urlencoded $i/v2/keys/foo | grep -e "Requests/sec" -e "Latency" -e "90%" | tr "\n" "\t" | xargs echo &
  done
  sleep 3
  for pid in $(pgrep 'boom'); do
    while kill -0 "$pid" 2> /dev/null; do
      sleep 3
    done
  done

  echo read, 1 client, $keysize key size, to leader
  ./boom_new -readall=true -n 100 -c 1 $leader/v2/keys/foo | grep -e "Requests/sec" -e "Latency" -e "90%" | tr "\n" "\t" | xargs echo

  echo read, 64 client, $keysize key size, to leader
  ./boom_new -readall=true -n 6400 -c 64 $leader/v2/keys/foo | grep -e "Requests/sec" -e "Latency" -e "90%" | tr "\n" "\t" | xargs echo

  echo read, 256 client, $keysize key size, to leader
  ./boom_new -readall=true -n 25600 -c 256 $leader/v2/keys/foo | grep -e "Requests/sec" -e "Latency" -e "90%" | tr "\n" "\t" | xargs echo

  echo read, 64 client, $keysize key size, to all servers
  # bench servers one by one, so it doesn't overload this benchmark machine
  # It doesn't impact correctness because read request doesn't involve peer interaction.
  for i in ${servers[@]}; do
    ./boom_new -readall=true -n 21000 -c 21 $i/v2/keys/foo | grep -e "Requests/sec" -e "Latency" -e "90%" | tr "\n" "\t" | xargs echo
  done

  echo read, 256 client, $keysize key size, to all servers
  for i in ${servers[@]}; do
    ./boom_new -readall=true -n 85000 -c 85 $i/v2/keys/foo | grep -e "Requests/sec" -e "Latency" -e "90%" | tr "\n" "\t" | xargs echo
  done

done

Mine's went up to 2248 time-waits from 400. You can check with:
ss -tan state time-wait | wc -l
2248

With old boom, it's worse:
ss -tan state time-wait | wc -l
30500

@gyuho I tried -readall=true with old bloom and I've got higher qps. But what this parameter exactly mean?

@aga20 It means it reads out the previous response body so that the TCP connection can be reused and can be properly closed at client side. So it reduces timewait and improves qps.

@aga20 Can you try with the new boom, not the old one. readall flag lets you consume the entire request body so that TCP conn can be reused as Xiang explains. So we should expect lower time-waits.

@xiang90 Hm I see thanks. But this isn't modify the real qps? Just because you measured without this parameter.  Thanks :)

But this isn't modify the real qps?

It does affect qps since you do not have to create a new TCP connection each time, which reduce the e2e latency and thus increases qps.

I got breakdown per node:
With readall=true flag:
server_1_client_wait_time_count: 2218
server_1_server_wait_time_count: 852

server_2_client_wait_time_count: 803
server_2_server_wait_time_count: 400

server_3_client_wait_time_count: 353
server_3_server_wait_time_count: 35

Without readall flag and with old boom:
server_1_client_wait_time_count: 64286
server_1_server_wait_time_count: 42169

server_2_client_wait_time_count: 42104
server_2_server_wait_time_count: 21104

server_3_client_wait_time_count: 21045
server_3_server_wait_time_count: 45

And this causes a bunch of I/O timeout on server side.
server_1_client_wait_time_count=$(ss -tan state time-wait dport ge :12379 | wc -l)
server_1_server_wait_time_count=$(ss -tan state time-wait dport ge :12380 | wc -l)

server_2_client_wait_time_count=$(ss -tan state time-wait dport ge :22379 | wc -l)
server_2_server_wait_time_count=$(ss -tan state time-wait dport ge :22380 | wc -l)

server_3_client_wait_time_count=$(ss -tan state time-wait dport ge :32379 | wc -l)
server_3_server_wait_time_count=$(ss -tan state time-wait dport ge :32380 | wc -l)

echo "
server_1_client_wait_time_count: $server_1_client_wait_time_count
server_1_server_wait_time_count: $server_1_server_wait_time_count

server_2_client_wait_time_count: $server_2_client_wait_time_count
server_2_server_wait_time_count: $server_2_server_wait_time_count

server_3_client_wait_time_count: $server_3_client_wait_time_count
server_3_server_wait_time_count: $server_3_server_wait_time_count
"

@aga20 Please try this https://github.com/coreos/etcd/pull/4182/files.
And this has been addressed in the past as well https://github.com/coreos/etcd/issues?q=is%3Aissue+time_wait+is%3Aclosed.
With readall flag, I don't see many time waits anymore.
But we might not merge the script because it is non-etcd issue, and
that benchmark script is not the best to measure the performance right now.
Please re-open this when you still see many time waits.


[Feature Requests] Filter Extensions By Language

A PR has already been made thanfully, you can use that if you want
https://github.com/inorichi/tachiyomi/pull/2275

Thanks for the PR link, I've incorporated it into 0.9.3


Create PerSegmentBaseModel, PerSegmentPredictionIntervalModel, PerSegmentModel

🚀 Feature Request
Instead of one PerSegmentModel create three models
Motivation
It will make abstractions easier to comprehend.
Proposal
Create PerSegmentBaseModel

it should inherit from FitAbstractModel
It should implement method fit (actually it is already implemented in current PerSegmentModel)
It should implement method init (already implemented in current PerSegmentModel)
it should implement method _build_models (already implemented in current PerSegmentModel)
it should implement method get_models that returns dict of all segment-models pairs
it should implement method _forecast_segment (already implemented in current Model), except it should expect additional parameters: def _forecast_segment(model, segment: Union[str, List[str]], ts: TSDataset, *args, **kwargs) -> pd.DataFrame and pass them to https://github.com/tinkoff-ai/etna/blob/1a10b256956352dd576ae8972771534c9ad47ed8/etna/models/base.py#L79

Create PerSegmentPredictionIntervalModel

it should inherit from PerSegmentBaseModel and ForecastPredictIntervalAbstractModel
It should implement method forecast, that passes prediction_interval, quantiles to model's predict method

Create PerSegmentModel

it should inherit from PerSegmentBaseModel and ForecastAbstractModel
It should implement method forecast (actually it is already implemented in current PerSegmentModel)

Create FitPredictProtocol as all these classes expect base_model to implement it.

fit def fit(self, df: pd.DataFrame, *args, **kwargs)
predict def predict(self, df: pd.DataFrame, *args, **kwargs) -> pd.DataFrame

Use FitPredictProtocol for typing in PerSegmentBaseModel: model: FitPredictProtocol
DO NOT use FitPredictProtocol for inheritance, FitPredictProtocol should be used only for type checks.
Also change the line
https://github.com/tinkoff-ai/etna/blob/1a10b256956352dd576ae8972771534c9ad47ed8/etna/pipeline/pipeline.py#L156
As it should check isinstance, not signature.
Test cases
No response
Alternatives
No response
Additional context
Blocked by #505
Also future developers should note that FitPredictProtocol is for inner library use only.
User guaranteed only fit-forecast interface stated by #505 and one should not worry about inner implementation of PerSegmentBaseModel, PerSegmentPredictionIntervalModel, PerSegmentModel and model adapters.
Checklist

[x] I discussed this issue with ETNA Team

We refused to implement FitPredictProtocol because the type checking fails with args/kwargs in the signature.
Changes in Pipeline moved to #507


Parametrized types

Types like list tell if we can apply list operations to the value,
but the result of (nth INDEX LIST) operation is remains unknown.
This can be solved with parametrized types like list<T>.
Functions that return parametrized types do exist, some of them
always return a type of same T.
number-sequence returns list<number> in the general case,
or list<integer>/list<float> if INC argument type is known (default - integer, but user may specify floating point INC).
These parametrized types should be somehow compatible with list type.

The simplest solution is switching to type=(cons T info) type representation,
where (car typ) will always give unparametrized type (like list)
and (cdr (cons T info)) returns additional type information, if available.


Subscription for Gotham Fonts

Is this still open?

Sanger doesn't want to purchase, we'll use Montserrat.


Chord with one augmentation dot missing

How should a chord missing one augmentation dot be encoded?  This question related to this example:

The B-flat octaves in the first measure only have an augmentation dot on the upper B-flat and not the lower (either it was forgotten by the typesetter, or the typesetter removed it on purpose since there is the text a Tempo. which is in the way).

It depends on what you want to capture.
If you just want to capture the editorial intervention on the digital edition, you can use the <supplied> tag to record the dot.
If you want to record more information about it, you could use the <sic> and <corr> elements to record that it's a correction from the original.

You may encode in this way:
  <chord xml:id="chord_8208"  dur="4" dots="1" tstamp="3">            <note xml:id="note_8214" pname="b" oct="5" accid.ges="f" dur="4"dots="1"/>            <note xml:id="note_8220"  pname="c" oct="5" accid="n" dur="4" **dots="0"**/>              <note xml:id="note_8226"  pname="e" oct="4" dur="4" dots="0"/> </chord>

To capture an editorial intervention or a mistake is on my opinion rather difficult here. You cannot wrap @dots in an <supplied> or <sic> and there is no <dots>. And if you ecode it like this:
<supplied>
<note xml:id="note_8220"  pname="c" oct="5" accid="n" dur="4" dots="0"/>
</supplied>
it would mean that the whole note is supplied.
The same problem is with some other attributes. For instance, @num, where the number over the tuplet was added by an editor.

There is a <dot> element:
http://music-encoding.org/guidelines/v3/elements/dot.html
<note>
    <dot />
</note>

<chord dur="4" dots="1" >
><note pname="b" oct="5" accid.ges="f" dur="4" dots="1"/>
><note pname="c" oct="5" accid="n" dur="4" dots="0"/>
><note pname="e" oct="4" dur="4" dots="0"/>
>
></chord>

@dots and @dur on the first note is not necessary in my opinion. Also, if you want to be explicit about the editorial aspect you can do:
<chord dur="4" dots="1" >
    <note pname="b" oct="5" accid.ges="f" />
    <choice>
        <sic>
            <note pname="c" oct="5" accid="n" dots="0" dots.ges="1" />
            <note pname="e" oct="4" dots="0" dots.ges="1"/>
        </sic>
        <corr>
            <note pname="c" oct="5" accid="n" />
            <note pname="e" oct="4" />
        </corr>
    </choice>
</chord>

Regarding the duplication of values, they cannot be fully avoided as long as attributes are used. When you encoded the correction of the pitch of a note, the duration @dur is duplicated, for example. It is a question of granularity and again, the only way to avoid any duplications is to remove attributes completely, but I am not you we want to go that path.

@jacekiwaszko1:

And this solution:

wouldn't mean that one note goes on longer than the others?

yes, in my example I encoded notes with different durations (violin).

This support request has been answered, so I'm closing the issue.


nested functions in coroutines referencing a variable from coroutine

Since variable names within coroutines are renamed to unique names and are hoisted to the top, functions defined within coroutines that uses those closure variables will get variable not found error.
This should be easily fixed in pass_var by going through functions as well.

TypedExpr solves this.


in make phase (C++) : third_party/cares/cares/ares_init.c error . all warnings being treated as errors

Hi,
I 'm my Ubuntu 18.04.1 LTS I'm just trying to install and build gRPC, but in the "make" step there, as you can see, there is an error:
third_party/cares/cares/ares_init.c: In function ‘ares_dup’:
third_party/cares/cares/ares_init.c:301:17: error: argument to ‘sizeof’ in ‘strncpy’ call is the same
expression as the source; did you mean to use the size of the destination? [-Werror=sizeof-pointer-
memaccess]
           sizeof(src->local_dev_name));

These are the steps followed:
marco@PC:~$ git clone -b $(curl -L https://grpc.io/release) https://github.com/grpc/grpc
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100     8  100     8    0     0     31      0 --:--:-- --:--:-- --:--:--    31
Cloning into 'grpc'...
remote: Counting objects: 398293, done.
remote: Compressing objects: 100% (31/31), done.
remote: Total 398293 (delta 22), reused 21 (delta 21), pack-reused 398241
Receiving objects: 100% (398293/398293), 179.33 MiB | 9.12 MiB/s, done.
Resolving deltas: 100% (307519/307519), done.
Note: checking out 'd2c7d4dea492b9a86a53555aabdbfa90c2b01730'.

You are in 'detached HEAD' state. You can look around, make experimental
changes and commit them, and you can discard any commits you make in this
state without impacting any branches by performing another checkout.

If you want to create a new branch to retain commits you create, you may
do so (now or later) by using -b with the checkout command again. Example:

  git checkout -b <new-branch-name>

marco@PC:~$ cd grpc
marco@PC:~/grpc$ git submodule update --init
Submodule 'third_party/abseil-cpp' (https://github.com/abseil/abseil-cpp) registered for path
'third_party/abseil-cpp'
Submodule 'third_party/benchmark' (https://github.com/google/benchmark) registered for path
'third_party/benchmark'
Submodule 'third_party/bloaty' (https://github.com/google/bloaty.git) registered for path
'third_party/bloaty'
Submodule 'third_party/boringssl' (https://github.com/google/boringssl.git) registered for path
'third_party/boringssl'
Submodule 'third_party/boringssl-with-bazel' (https://github.com/google/boringssl.git) registered for
path 'third_party/boringssl-with-bazel'
Submodule 'third_party/cares/cares' (https://github.com/c-ares/c-ares.git) registered for path
'third_party/cares/cares'
Submodule 'third_party/gflags' (https://github.com/gflags/gflags.git) registered for path
'third_party/gflags'
Submodule 'third_party/googletest' (https://github.com/google/googletest.git) registered for path
'third_party/googletest'
Submodule 'third_party/libcxx' (https://github.com/llvm-mirror/libcxx.git) registered for path
'third_party/libcxx'
Submodule 'third_party/libcxxabi' (https://github.com/llvm-mirror/libcxxabi.git) registered for path
'third_party/libcxxabi'
Submodule 'third_party/protobuf' (https://github.com/google/protobuf.git) registered for path
'third_party/protobuf'
Submodule 'third_party/zlib' (https://github.com/madler/zlib) registered for path 'third_party/zlib'
Cloning into '/home/marco/grpc/third_party/abseil-cpp'...
Cloning into '/home/marco/grpc/third_party/benchmark'...
Cloning into '/home/marco/grpc/third_party/bloaty'...
Cloning into '/home/marco/grpc/third_party/boringssl'...
Cloning into '/home/marco/grpc/third_party/boringssl-with-bazel'...
Cloning into '/home/marco/grpc/third_party/cares/cares'...
Cloning into '/home/marco/grpc/third_party/gflags'...
Cloning into '/home/marco/grpc/third_party/googletest'...
Cloning into '/home/marco/grpc/third_party/libcxx'...
Cloning into '/home/marco/grpc/third_party/libcxxabi'...
Cloning into '/home/marco/grpc/third_party/protobuf'...
Cloning into '/home/marco/grpc/third_party/zlib'...
Submodule path 'third_party/abseil-cpp': checked out 'cc4bed2d74f7c8717e31f9579214ab52a9c9c610'
Submodule path 'third_party/benchmark': checked out '5b7683f49e1e9223cf9927b24f6fd3d6bd82e3f8'
Submodule path 'third_party/bloaty': checked out '73594cde8c9a52a102c4341c244c833aa61b9c06'
Submodule path 'third_party/boringssl': checked out 'b29b21a81b32ec273f118f589f46d56ad3332420'
Submodule path 'third_party/boringssl-with-bazel': checked out
'8149b351bf797bd80e063787886b7618f508e451'
Submodule path 'third_party/cares/cares': checked out
'3be1924221e1326df520f8498d704a5c4c8d0cce'
 Submodule path 'third_party/gflags': checked out '30dbc81fb5ffdc98ea9b14b1918bfe4e8779b26e'
Submodule path 'third_party/googletest': checked out 'ec44c6c1675c25b9827aacd08c02433cccde7780'
Submodule path 'third_party/libcxx': checked out '6599cac0965be8e5a835ab7a5684bbef033d5ad0'
Submodule path 'third_party/libcxxabi': checked out '9245d481eb3e890f708ff2d7dadf2a10c04748ba'
Submodule path 'third_party/protobuf': checked out '48cb18e5c419ddd23d9badcfe4e9df7bde1979b2'
Submodule path 'third_party/zlib': checked out 'cacf7f1d4e3d44d871b605da3b647f07d718623f'

 marco@PC:~/grpc$ make
marco@PC:~/grpc$ make
[MAKE]    Generating /home/marco/grpc/libs/opt/pkgconfig/grpc.pc
[MAKE]    Generating /home/marco/grpc/libs/opt/pkgconfig/gpr.pc
[MAKE]    Generating /home/marco/grpc/libs/opt/pkgconfig/grpc_unsecure.pc
[MAKE]    Generating cache.mk
 [C]       Compiling third_party/address_sorting/address_sorting.c
[C]       Compiling third_party/address_sorting/address_sorting_posix.c
[C]       Compiling third_party/address_sorting/address_sorting_windows.c
[AR]      Creating /home/marco/grpc/libs/opt/libaddress_sorting.a
[C]       Compiling third_party/cares/cares/ares__close_sockets.c
[C]       Compiling third_party/cares/cares/ares__get_hostent.c
[C]       Compiling third_party/cares/cares/ares__read_line.c
[C]       Compiling third_party/cares/cares/ares__timeval.c
[C]       Compiling third_party/cares/cares/ares_cancel.c
[C]       Compiling third_party/cares/cares/ares_create_query.c
[C]       Compiling third_party/cares/cares/ares_data.c
[C]       Compiling third_party/cares/cares/ares_destroy.c
[C]       Compiling third_party/cares/cares/ares_expand_name.c
[C]       Compiling third_party/cares/cares/ares_expand_string.c
[C]       Compiling third_party/cares/cares/ares_fds.c
[C]       Compiling third_party/cares/cares/ares_free_hostent.c
[C]       Compiling third_party/cares/cares/ares_free_string.c
[C]       Compiling third_party/cares/cares/ares_getenv.c
[C]       Compiling third_party/cares/cares/ares_gethostbyaddr.c
[C]       Compiling third_party/cares/cares/ares_gethostbyname.c
[C]       Compiling third_party/cares/cares/ares_getnameinfo.c
[C]       Compiling third_party/cares/cares/ares_getopt.c
[C]       Compiling third_party/cares/cares/ares_getsock.c
[C]       Compiling third_party/cares/cares/ares_init.c
third_party/cares/cares/ares_init.c: In function ‘ares_dup’:
third_party/cares/cares/ares_init.c:301:17: error: argument to ‘sizeof’ in ‘strncpy’ call is the same
expression as the source; did you mean to use the size of the destination? [-Werror=sizeof-pointer-
memaccess]
           sizeof(src->local_dev_name));
                 ^
third_party/cares/cares/ares_init.c: At top level:
cc1: error: unrecognized command line option ‘-Wno-invalid-source-encoding’ [-Werror]
cc1: all warnings being treated as errors
Makefile:2896: recipe for target '/home/marco/grpc/objs/opt/third_party/cares/cares/ares_init.o' failed
make: *** [/home/marco/grpc/objs/opt/third_party/cares/cares/ares_init.o] Error 1
marco@PC:~/grpc$

What do I have to do to solve the problem? Looking forward to your kind hints and help.
Marco

The fix is part of the 1.15.0 c-ares release (https://github.com/c-ares/c-ares/releases/tag/cares-1_15_0). It was released on the 23.10.18.

The issue was fixed with PR https://github.com/grpc/grpc/pull/18519


Use Sphinx for docs

http://www.sphinx-doc.org/en/stable/

http://www.sphinx-doc.org/en/stable/tutorial.html
https://docs.readthedocs.io/en/latest/getting_started.html

Complete as of commit 747940931f7c542f082fe691a44ed895dec45d23
Additionally, the docs are automatically built and hosted by readthedocs.


Place all ungrouped dependencies into a single pull request

Is there an existing issue for this?

[X] I have searched the existing issues

Feature description
I would like updates to all dependencies that don't match any group definitions to go into a single pull request. Currently, to achieve this requires creating an "other" group and explicitly listing each of these dependencies in it. This creates a maintenance burden when dependencies change.
One way of achieving this is to (optionally) constrain each dependency to belong to a single group. Groups should be defined in priority order, so if a dependency matches multiple groups, it will belong to the one highest in the list. One could then define an other group at the end with a pattern of "*" to group up any unmatched dependencies.
There is another benefit to mutually exclusive groups: If group 1 is *prettier* and group 2 is *eslint*, you don't need to use exclude-patterns to prevent eslint-plugin-prettier appearing in both groups.
The above is just a suggestion. There may be other ways to solve this problem.

Is this not the way it currently works? I was also looking for this and then found this in the docs?

Dependabot creates groups in the order they appear in your dependabot.yml file. If a dependency update could belong to more than one group, it is only assigned to the first group it matches with.

From here
Happy to be told I'm misunderstanding!


Ability to make ContextMenu follow trigger when scrolling

Feature request
Overview

Examples in other libraries
https://ant.design/components/dropdown-cn/#components-dropdown-demo-context-menu

Hi @leadream,
Are you referring to when using the context menu in "non-modal" mode?
If so I guess as scrolling is enabled, it would be fair to expect it to follow the point it was triggered at.
I'll file this as an enhancement.

@benoitgrelard yeah, I tested dropdown in non-modal mode and it will follow the trigger element when scrolling, but context menu doesn't.


Error after preparing for iOS: TypeError: v1.indexOf is not a function

I'm getting an error after preparing the project for iOS.
Error: TypeError: v1.indexOf is not a function     at compare (/CordovaProject/plugins/cordova-universal-links-plugin/node_modules/node-version-compare/index.js:3:20)     at activateAssociativeDomains (/CordovaProject/plugins/cordova-universal-links-plugin/hooks/lib/ios/xcodePreferences.js:69:13)     at Object.enableAssociativeDomainsCapability (/CordovaProject/plugins/cordova-universal-links-plugin/hooks/lib/ios/xcodePreferences.js:36:5)     at activateUniversalLinksInIos (/CordovaProject/plugins/cordova-universal-links-plugin/hooks/afterPrepareHook.js:79:25)     at /CordovaProject/plugins/cordova-universal-links-plugin/hooks/afterPrepareHook.js:50:11     at Array.forEach (native)     at run (/CordovaProject
It looks like everything gets moved to the iOS project properly but I've found that I need to manually enable the "Associated Domain" toggle in my projects capabilities.
My setup:
<EMAIL_ADDRESS><EMAIL_ADDRESS>

Weird... Try the following:

Remove plugin and iOS platform:

cordova plugin remove cordova-universal-links-plugin
cordova platform remove ios

Add iOS platform and plugin:

cordova platform add ios
cordova plugin add cordova-universal-links-plugin

Go to YOUR_PROJECT_ROOT/plugins/cordova-universal-links-plugin/hooks/lib/ios/ and open xcodePreferences.js. In it comment out lines 67-81.

Build again:

cordova build ios

Worked. I got rid of lines 67-76.

I ran into this as well, added a pull request to fix this:
https://github.com/nordnet/cordova-universal-links-plugin/pull/154


Mac Support

I hate having to switch to my old slow computer to use UABEA, please consider making a Mac OS version

I built one https://github.com/MaxNiftyNine/UABEA-Mac/

I built one https://github.com/MaxNiftyNine/UABEA-Mac/

That won't work for the texture plugin. It uses native libraries that need to be compiled for mac.
Since I don't have a mac, it's hard for me to compile and test for it.


Installation docs

The README doesn't mention how to install. I'm guessing the easiest is to download a release and put it on PATH?
For manually building and installing, I expected to use cargo install, but that fails:
❯ cargo install --path .
error: found a virtual manifest at `/Users/josh.nichols/workspace/scope/Cargo.toml` instead of a package manifest

Looks like this works:
$ cargo install --path scope
$ cargo install --path scope-intercept

Updated Readme with docs


Incorrect auth state listener message

Android device: any
Android OS version: any
Google Play Services version: latest
Firebase/Play Services SDK version: 10.2.0

The following log message reports 0 listeners notified, but the last line is a log message from my listener. Happens on sign-in too.
D/FirebaseAuth: Notifying listeners about a sign-out event.
D/FirebaseApp: Notifying auth state listeners.
D/FirebaseApp: Notified 0 auth state listeners.
D/MyApp SignInActivity: onAuthStateChanged:signed_out

Not a big deal, but something for the TODO list.

It's been a long time since the last update here so I am going to close this issue.  Thank you for reporting it and feel free to re-open if it you'd like to discuss further.
Additionally we now have two different listener types (AuthStateListener and IdTokenListener) which may help for your use case.


Language — Rewrite SQL -> AR/Arel

Quite a bit of fancy footwork in this rewrite.

Coverage increased (+0.005%) to 93.038% when pulling bd2833b26e39db44244b7da9fd568a56b0fdac91 on nimmo-SQL-in-models-language into eb867d5cb837f6056aeffcea875f7a9dcd50d1bd on master.


Use node 18

Motivation
Resolve #4768
Description
Minimal diff to test/build/recommend using node 18

not sure why computeProposerBoostScoreFromBalances benchmark test is 3x slower than NodeJS 16

not sure why computeProposerBoostScoreFromBalances benchmark test is 3x slower than NodeJS 16

Can you retry multiple times and double check in local to make sure it's not a false positive?

not sure why computeProposerBoostScoreFromBalances benchmark test is 3x slower than NodeJS 16

Can you retry multiple times and double check in local to make sure it's not a false positive?

confirmed locally and also in CI multiple times.

also e2e tests consistently timing out in a few places :eyes:

tests fixed, ready for re-review

Mesh peers and gossip peer scores are great (while rpc count is the same)

EventLoop lag is better than Nodejs 16

That's confirmed by attestation produce/publish delay

However:

Heap memory (and gc) is not stable so we need to monitor it for a long time

And some benchmark tests failed, especially Buffer.concat() is >2000x slower is a concern

Where are all the places we use Buffer.concat in Lodestar's regular runtime?

Probably the most run:
https://github.com/ChainSafe/lodestar/blob/798ec16d301e9db20f94cd818205277678d6f213/packages/beacon-node/src/network/gossip/encoding.ts#L62
Others:
https://github.com/ChainSafe/lodestar/blob/e5dabac124933bcadc650d19d6b128dcbfcb6c43/packages/beacon-node/src/util/graffiti.ts#L7
A few in these files:
https://github.com/ChainSafe/lodestar/blob/eccde2f3d71448ad5b5026f87e4699c29b5b04f7/packages/state-transition/src/util/seed.ts#L34
https://github.com/ChainSafe/lodestar/blob/2883368c84efc23a679cafc4c98d430f45444e51/packages/utils/src/verifyMerkleBranch.ts#L4

opened issue upstream in node repo:

https://github.com/nodejs/node/issues/45802

Ok to me to defer issue for latter and unblock v18


[FLINK-2170] [connectors] Add OrcRowInputFormat and OrcTableSource.

What is the purpose of the change

Adds OrcRowInputFormat to read ORC files as DataSet<Row>. The input format supports projection and filter push-down.
Adds OrcTableSource to read ORC files as a Table in a batch Table API or SQL query. The table source supports projection and filter push-down.

This is an extension of PR #4670.
Brief change log

Creates a new module flink-connectors/flink-orc
Add OrcRowInputFormat
Add OrcTableSource
Add tests for input format and table source
Adjust cost model of batch table scans to favor table sources with pushed-down filters over those without pushed-down filters.
Add static method to RowTypeInfo to project on fields.
Improve translation of literals in RexProgramExtractor

Verifying this change

OrcRowInputFormatTest verifies

Correct configuration of ORC readers.
Results when reading ORC files
Schema evolution support
Computation of split boundaries

OrcTableSourceTest verifies

Correct implementation of TableSource interface methods
Correct configuration of OrcRowInputFormat for test queries (predicate and filter push-down)

OrcTableSourceITCase runs end-to-end tests with SQL queries.

Does this pull request potentially affect one of the following parts:

Dependencies (does it add or upgrade a dependency): yes, adds a new Maven module flink-orc with a dependency on org.apache.orc/orc-core
The public API, i.e., is any changed class annotated with @Public(Evolving): no
The serializers: no
The runtime per-record code paths (performance sensitive): no
Anything that affects deployment or recovery: JobManager (and its components), Checkpointing, Yarn/Mesos, ZooKeeper: no
The S3 file system connector: no

Documentation

Does this pull request introduce a new feature? yes
If yes, how is the feature documented? yes, documentation for RowTableSource was added.

Thanks for the review @twalthr!
I'll address your comments and will merge this PR.


[Feature]: Add the github action workflow for greeting contributors

#Describe your improvement idea or feature request
The current project lacks an automated action to greet contributors. GitHub Actions can significantly enhance project automation. I propose adding a GitHub Action workflow to greet new pull request (PR) and issue creators, fostering a welcoming environment.
#How would you like to see it implemented?
Implement a GitHub Action workflow that triggers on new PRs and issues. The workflow should include a greeting message to acknowledge and appreciate the contributors for their efforts.

Please assign me here @Kritika30032002 , will greet the first contributors on your repo.

included in #214


[feature request] Add countdown in top bar of Mac

Hi there! I am very excited to find this project! I am wondering is it possible to add a countdown in the top bar? I think this is a useful feature that allows user to know how many time has elapsed.
For example, another pomodoro timer "Focus To-Do" add a countdown like:

Thanks!

Second this


Multiple text fonts and styles within same label

I want to make a label (or text area) at the bottom of my app that says "This app is created using Monomer. Visit https://github.com/fjvallarino/monomer for more details." How do I underline and italicize just the link part of the text?

I think you could do something like that:
hstack
    [ label "This app is created using Monomer. Visit "
    , externalLink "https://github.com/fjvallarino/monomer" "https://github.com/fjvallarino/monomer"
    , label " for more details."
    ]

Hi! Thanks for suggesting externalLink. I was going to add a dedicated OpenLink Text constructor to my AppEvent data type, but externalLink is definitely nicer to work with. There’s still an issue though.
I tried using an hstack like you suggested, and it worked well in a wide window.

However, when I narrowed the window, the link got clipped as expected.

How do I achieve something like this?

(Also, side question, how do you limit the number of visible rows in a selectList container?)

There is label_ "Text" [multiline] which would wrap the text. However we have here three widgets in hstack, so I think it's not possible to configure wrapping in one line.
Probably build different versions for different sizes of the window like that:
if wenv ^. L.windowSize . L.w > 1000 then hstack [] else vstack []

And also you need to supply resizeEvent to startApp config, where you would return [Request RenderOnce], otherwise text will wrap only when app model changes.
As for your question about selectList, I think you need `styleBasic` [sizeReqH $ fixedSize 100]

Thanks for suggesting adding an appResizeEvent to the list of AppConfigs. I must be doing something wrong, though, because after I made different versions of the widget based on window size, and added
appResizeEvent (const AppRender)

to my AppConfig list and
handleEvent wenv ui model AppRender = [Request RenderOnce]

to my event handler, the widget never changed upon resizing the window.
I had to include window size in my app model, which worked but was less than ideal.
I might open a new issue, though, because what I hope to do is to have the widget adapt to its allocated widget size and not to the size of the whole window.

Hi @izuzu-izuzu!
Sorry for the delay. At the time, there is no support for rich labels, although it's something I plan to pursue in the next few months.
The solution you provided using hstacks will work as long as each label does not need to wrap to a different line. There is support for multi-line labels, but each of its lines will be in the same viewport (so a label that starts at x = 500 will not be able to have its second line at x = 200).


Provide ability to override NavigationBar indicator ink response overlay

Is there an existing issue for this?

[X] I have searched the existing issues
[X] I have read the guide to filing a bug

Use case
Currently, there is no overlayColor property in the NavigationBar which should allow overriding ink response overlay.
This is typically found in other material widgets
For cases when you want ovrerride ink focus, hover and highlight effects, a Material State overlay can be used.
Take this example where we can indicator color to be transparent but cannot override ink response overlay.
Code sample

expand to view the code sample
import 'package:flutter/material.dart';

void main() => runApp(const MyApp());

class MyApp extends StatelessWidget {
  const MyApp({super.key});

  @override
  Widget build(BuildContext context) {
    return const MaterialApp(
      debugShowCheckedModeBanner: false,
      home: Scaffold(
        bottomNavigationBar: NavigationBarExample(),
      ),
    );
  }
}

class NavigationBarExample extends StatefulWidget {
  const NavigationBarExample({super.key});

  @override
  State<NavigationBarExample> createState() => _NavigationBarExampleState();
}

class _NavigationBarExampleState extends State<NavigationBarExample> {
  int index = 0;

  @override
  Widget build(BuildContext context) {
    return NavigationBar(
      elevation: 0,
      indicatorColor: Colors.transparent,
      selectedIndex: index,
      onDestinationSelected: (int index) {
        setState(() {
          this.index = index;
        });
      },
      destinations: const <Widget>[
        NavigationDestination(
          selectedIcon: Icon(Icons.home_filled),
          icon: Icon(Icons.home_outlined), label: 'Home'),
        NavigationDestination(
          selectedIcon: Icon(Icons.favorite),
          icon: Icon(Icons.favorite_outline), label: 'Favorites'),
      ],
    );
  }
}

https://github.com/flutter/flutter/assets/48603081/10333bbd-cd1a-4ff4-bee4-14a104172385
Proposal
Provide an overlay color property for the indicator ink response
overlayColor: MaterialStatePropertyAll(Colors.transparent), should be able to override the default ink response overlay.
https://github.com/flutter/flutter/assets/48603081/98d5b962-f8dc-4758-94dc-f4859ba4703b

cc: @leighajarett

Awesome! I think this makes sense as a cherry pick as well.

@leighajarett
https://github.com/flutter/flutter/pull/138901 should allow to customize M3 style indicator overlay.


System.IO.FileFormatException: File contains corrupted data - Excel file(.xlsx)

Describe the bug
Getting "System.IO.FileFormatException: File contains corrupted data" error in SpreadsheetDocument.Open(filename, false); method for excel(.xlsx) file
Error Detail :
System.Exception: OpenXML failed to open Pricing file | ‘System.IO.FileFormatException: File contains corrupted data.
at MS.Internal.IO.2ip.ZipIOEndOfCentralDirectoryBlock.FindPosition(Stream archiveStream)
at MS.Internal.IO.Zip.ZiplOEndOfCentralDirectoryBlock.SeekableLoad(ZipIOBlockManager blockManager)
at MS.Internal.IO.Zip.ZipArchive..ctor(Stream archiveStream, FileMode mode, FileAccess access, Boolean streaming, Boolean ownStream)at
MS.Internal.IO.2ip.ZipArchive.OpenOnFile(String path, FileMode mode, FileAccess access, FileShare share, Boolean streaming)
at System.IO.Packaging.ZipPackage..ctor(String path, FileMode mode, Fileccess access, FileShare share, Boolean streaming)
at System.IO.Packaging.Package.Open(String path, FileMode packageMode, FileAccess packageAccess, FileShare packageShare, Boolean streaming)
at DocunentFormat.OpenXnl.Packaging.OpenknlPackage-OpenCore(String path, Boolean readiiniteMode)
at DocumentFormat.Openxnl.Packaging.SpreadsheetDocument.Open(String path, Boolean isEditable, OpenSettings openSettings)
How to fix this issue?

@shailesh1984, we need more information to help (e.g., as indicated by the template you were asked to fill in when creating this issue). Most importantly, we'd need to be able to reproduce the issue. Also, we need the version (e.g., 2.18.0, 2.19.0) of the Open XML SDK (DocumentFormat.OpenXml package) you are using.
As the exception message says, the "file contains corrupted data." So the file itself may be corrupt, which would not be a bug in the Open XML SDK (or any other library). Looking at the stack trace, the exception is thrown by the FindPosition(Stream) method of the ZipIOEndOfCentralDirectoryBlock class, which is part of the WindowsBase framework assembly.
Based on your information, this does not look like a bug in the Open XML SDK (this project).

Is there any way to avoid temporary file opening in OpenXml?
or
We need to handle it in the code itself.
ex :
if(fileName.StartsWith("~")){ }

Your code is responsible for passing the right file names, streams, or packages to the Open XML SDK. If the data contained in a file, stream, or package is corrupt, the bug or issue is on your side and you'll have to deal with that. The Open XML SDK or other framework libraries can only handle cases where you provide invalid or corrupt data by throwing exceptions, for example.

Thank you


Error when estimating eta

Thanks for developing this great package!
I'm trying to analyze some phylogenetic data using Pesto (attached below -- it is not from evolutionary data but it is also present in the tree form), following the tutorial (https://kopperud.github.io/Pesto.jl/dev/analysis/extended/). I get the following error when estimating eta, the rate of shift:
η = optimize_eta(λ, µ, pdac)
ERROR: KeyError: key 10247 not found
Stacktrace:
  [1] getindex(h::Dict{Int64, Int64}, key::Int64)
    @ Base ./dict.jl:484
  [2] partition_postorder_indices(data::SSEdata)
    @ Pesto ~/.julia/packages/Pesto/yDVQr/src/utils.jl:217
  [3] postorder_nosave(model::SSEconstant, data::SSEdata, ....

Do you have any idea why this error occurs and how to fix it? Thanks very much for your help!
M1_1_v3.txt

Hi Yusha,
How did you install the package? It might be that you need to install the development version like so
import Pkg
Pkg.add(url="https://github.com/kopperud/Pesto.jl")

We haven't finished the manuscript yet, and we're still ironing out some of the bugs. I think it should run if you install the development version.
Otherwise, we are assuming the following for the tree:

The tree is bifurcating (i.e. that there are no polytomies)
The branch lengths are in units of time
The tree is ultrametric (i.e. each tip has the same time from the root to the tip)

I quickly plotted your tree and saw that these conditions are not met -- so the model results will not make sense, sorry. I'll try to add some checks and print errors if this is not the case, thank you for the example. If you somehow can resolve the polytomies, and transform the units of your branches to time, and make the tree ultrametric, then you can re-run the model.
Sorry if it's not the response you hoped for, but thanks for your interest.
Bjørn

Thanks very much! I'm able to run the model after I make the tree ultrametric and bifurcating. Regarding the condition that the branch lengths are units of time, does it matter if the branch lengths in my tree are different in scale (magnitude) from those in typical evolution data? Will the validity of your method be affected, or it shouldn't matter as long as the branch lengths are positive values? And another minor question -- is zero branch length allowed?

In the examples that we have tested, we have been using trees with branch lengths in units of million years, something between a few myr and up to 400-500 myr. In these cases the rates (speciation, extinction, shift rate) are on the order of 0.001-1.0, in units of events per lineage per myr, something like that. If you use a different scale, like years instead of million years, then the branch lengths will be longer, but the rates smaller. Mathematically speaking the method should be invariant to the choice of time units, but there can potentially be some problems with numerical stability if you choose numbers that are very extreme, either very large or very small. Also we set some initial values, and upper/lower limits when estimating the rates, i.e. these steps
λml, μml = estimate_constant_bdp(primates)

and
η = optimize_eta(λ, µ, primates)

Those are not in the vignette but the limits and initial values can be controlled with keyword arguments, you can see from the source
https://github.com/kopperud/Pesto.jl/blob/3ffd98f70e148a53d594958e4a11e593f217050b/src/bd_shift/optimize.jl#L26-L39
https://github.com/kopperud/Pesto.jl/blob/3ffd98f70e148a53d594958e4a11e593f217050b/src/bd_constant/constantBDP.jl#L110-L112
However if your branch lengths are not in units of time, and instead something like number of nucleotide substitutions, then I'm not sure the model makes sense at all

And I'm not sure if zero-length branch lengths work. Theoretically it should but I'm not sure if we coded it correctly in that edge-case