best way to execute shell commands and preserve color

I want to execute a shell command in windows using cmd.
var spawn = require('child_process').spawn,
	cmd    = spawn('cmd', ['/s', '/c', 'C:\\Windows\\Microsoft.NET\\Framework\\v4.0.30319\\MSBuild c:\\test.sln']);

cmd.stdout.on('data', function(data){
	process.stdout.write(data);
});

cmd.stderr.on('data', function(data){
	process.stderr.write(data);
});

cmd.on('exit', function(code){
	console.log(code);
});

The problem is the color is not preserved. Rather it uses default color.
Any idea how to redirect the stdout and preserve the color.
Here is the original question I posted in stackoverflow. http://stackoverflow.com/questions/7725809/preserve-color-when-executing-child-process-spawn

the solution was posted here.
http://facebook.stackoverflow.com/a/8671997/157260
currently exec method (https://github.com/mde/jake/blob/23221e2d361f3224a1ebdf1f2b8febe1749eaa25/lib/utils.js) uses var exec = require('child_process').exec but it doesn't preserve the color.
it should rather use the following code so color can be preserved.
var spawn = require('child_process').spawn
  , command = 'C:\\Windows\\Microsoft.NET\\Framework\\v4.0.30319\\MSBuild c:\\test.sln'
  , cmd    = spawn('cmd', ['/s', '/c', command], { customFds: [0,1,2] });

cmd.on('exit', function(code){
    console.log(code);
});

when executing msbuild using rake (ruby) we get color output but currently with jake there is no color output in console. the above method would enable color console output in jake.
Here is also the discussion in nodejs forum incase you are interested. https://groups.google.com/forum/#!topic/nodejs/t8dPnfqVl6U
"When msbuild writes its output to a console it will also make api
calls (SetConsoleTextAttribute) to change the text color. When you
redirect its output, it doesn't do that. And even it if did, node
wouldn't be able to intercept those calls. "

I think the idea of a project for doing MS builds is great. That doesn't really solve the problem of getting color output in your terminal though, does it? Maybe some of the basics like getDotNetVersionPath should be built directly into Jake. Or maybe Jake can test to see if the msbuild package is installed, and use that, and fall back to a reasonable default if it's not. What are your thoughts?

the stackoverflow solution does get the color output in the terminal for msbuild. (http://facebook.stackoverflow.com/questions/7725809/preserve-color-when-executing-child-process-spawn/8671997#8671997)
Certain tasks like PackageTask/File/Directory is great to be part of the core jake itself. not sure if it is good to have msbuild bundled in jake or as a separate package. Because there will  be lots of custom tasks besides msbuild so you might find it a maintenance problem later on when the number of custom tasks increases. It might be better to have a jake (github) organization containing all the custom tasks and depending on the user needs pull each task as a npm package (npm install jake-msbuild) Or create a wiki page showing links to all different custom tasks such as msbuild.
It is also important to standardize how custom tasks are created and consumed (documentation and sample needed for this).  we also need options for global defaults. for example by default msbuild should be using the x86 version, this way it will work in most of the machines but if the dev wants to ovveride it to use x he should be allowed to do it globally once so that he will not need to override it in every task.
For example instead of adding the following line in every PackgeTask, dev should be allowed to set that globally once.
this.needTarGz = true;
this.needTarBz2 = true;

Here is the working sample on how I'm executing executable files and also preserve colors.
https://github.com/prabirshrestha/CombinationStream/blob/23af2ead47be15a4481b9b3b108ce35168b2b8e2/Jakefile#L61-67
On second thought I'm wondering if this code getWinDir and getDotNetVersionPath can actually be a part of the core Jake. https://github.com/prabirshrestha/CombinationStream/blob/23af2ead47be15a4481b9b3b108ce35168b2b8e2/Jakefile#L69-107

linux shell is missing color too~ 。 i'm using jake to run my mocha test case。
mocha output the test result with colorful display ,but when i exec in jake and pipe the child_process's stdout|stderr to jake's process, the colorful report has gone~

Any fix on this?

Pushed to NPM in f1d655515d54788183fbf89617a8fea351e2313f


The onchange doesnt work?

When I click the last page or first page or previous page or next page li's, the onChange is passing a pageNumber which is wrong. Is there a handler for first page, last page, previous page and next page?

i am facing the same issue, when i redirect user from create or update to list (in the middle pages of pagination). it does not go from middle pages to first page but allows us to navigate to the last.

Yeah, I think the handler should return something different instead of pageNumber. I ended up writing my own pagination component, but I think this is a small fix in this library if author wants. Or maybe there is a way to handle it in this library which we are not aware of.


Show/hide token feature (Issue #285)

This PR updates the Show/Hide token feature (Issue #285) by creating a new panel called Denylist under Settings where the hidden tokens are displayed, with the option to make them visible again under the Account tab.
Why:

At the moment the tokens could only be hidden but there was no option to view and display them again.

How:

Added new components to create the Denylist panel, display the tokens, and enable the option to show them back under the Account tab.
gui/src/components/Settings/Denylist.tsx
gui/src/components/ERC20ViewDenylist.tsx
gui/src/components/Settings/Settings.tsx
gui/src/store/balances.ts
crates/http/src/routes/db.rs

Added new queries and commands to interact/update the database.
bin/src/app.rs
crates/db/src/queries/erc20.rs
crates/db/src/commands.rs

Preview:

Other considerations:

Native chain token should not have the option to be hidden.
With this update the Send button is disabled under the Denylist tab, to transfer the tokens they have to be visible under the Account tab.

Overall love the update, but there's one change I'd like to make
it seems very weird to me to have the concept of a "denylist balance". they're only meant to show up in settings, so refering to balances there seems way off.
The fact that you're reusing the same ERC20View in that settings page also feels off. you're creating some tight coupling between the Balances list and the Denylist. Meaning whenever we change functionality for balances, we now have to worry how that'll affect the denylist (and most likely, we'll forget about it and cause weird behaviour)
What I'd do instead:

just have a simple db_get_erc20_denylist call that lists out all the token addresses that have been hidden
in the settings page, just show a simpler list element with all those (token name, address, but no balance), and a button to restore it

Overall love the update, but there's one change I'd like to make
it seems very weird to me to have the concept of a "denylist balance". they're only meant to show up in settings, so refering to balances there seems way off. The fact that you're reusing the same ERC20View in that settings page also feels off. you're creating some tight coupling between the Balances list and the Denylist. Meaning whenever we change functionality for balances, we now have to worry how that'll affect the denylist (and most likely, we'll forget about it and cause weird behaviour)
What I'd do instead:

just have a simple db_get_erc20_denylist call that lists out all the token addresses that have been hidden

in the settings page, just show a simpler list element with all those (token name, address, but no balance), and a button to restore it

Thanks for the feedback! I will update accordingly 👍🏻

Update:

Removed balance, simplified the list element and added a single button to restore the token (we could use the opposite button on the Account tab to hide the token, unless we are willing to have more options available)
Fixed Denylist to be independent from the Balances definition

Preview:

Note: whenever you add/change SQL queries in the codebase, you'll need to run mise run sqlx to update the sqlx cache files


Can export to Wii U

This is not legally possible, Nintendo SDKs are secret and you have to sign a license to use them. We can't provide a port here for their platform without breaking the law.

Then how can Scirra supports Wii U export with Construct 2?

@Plasmmer Scirra made a deal with Nintendo, probably, and you still need to be a registered Wii U developer, with access to the official Wii U dev forum.

What about porting Godot Engine using WUT? It's GPL-2 Licensed, and even thought it doesn't provide a pathway for developers to port to the Nintendo Wii U eShop, it would provide hobbyists a pathway for Homebrew Games developed for the platform.

What about porting Godot Engine using WUT? It's GPL-2 Licensed, and even thought it doesn't provide a pathway for developers to port to the Nintendo Wii U eShop, it would provide hobbyists a pathway for Homebrew Games developed for the platform.

I want to add on to this, I recently was searching if anyone had thought that it would be possible to do that and I wanted to create a Luigi's Mansion fan port for Wii U because it never happened, I thought that Godot would be the perfect engine for it, however seeing that they're not even interested in Homebrew is sad, especially considering that here in the future, the eShop is even discontinued.


[tensorflow/compiler/mlir/xla/experimental/conv_emitter/conv_emitter.cc] Add calls to reserve() before populating vector

https://github.com/tensorflow/tensorflow/pull/51739#issuecomment-940389562 told me to split the larger PR into one PR per file; thus this (thanks bash, git and gh!)

@SamuelMarks Any update on this PR? Please. Thanks!

@gbaned Done

It seems like you didn't test your code:
third_party/tensorflow/compiler/mlir/xla/experimental/conv_emitter/conv_emitter.cc:146:58: error: invalid operands to binary expression ('mlir::Operation' and 'mlir::Operation *')
                        return for_op.getBody()->front() == &*begin_op;
                               ~~~~~~~~~~~~~~~~~~~~~~~~~ ^  ~~~~~~~~~~
third_party/llvm/llvm-project/llvm/include/llvm/ADT/StringRef.h:918:15: note: candidate function not viable: no known conversion from 'mlir::Operation' to 'llvm::StringRef' for 1st argument
  inline bool operator==(StringRef LHS, StringRef RHS) {
              ^
third_party/llvm/llvm-project/llvm/include/llvm/Support/Alignment.h:248:13: note: candidate function not viable: no known conversion from 'mlir::Operation' to 'llvm::Align' for 1st argument
inline bool operator==(Align Lhs, uint64_t Rhs) {
            ^
third_party/llvm/llvm-project/llvm/include/llvm/Support/Alignment.h:274:13: note: candidate function not viable: no known conversion from 'mlir::Operation' to 'llvm::MaybeAlign' for 1st argument
inline bool operator==(MaybeAlign Lhs, uint64_t Rhs) {
            ^
third_party/llvm/llvm-project/llvm/include/llvm/Support/Alignment.h:282:13: note: candidate function not viable: no known conversion from 'mlir::Operation' to 'llvm::Align' for 1st argument
inline bool operator==(Align Lhs, Align Rhs) {
            ^
third_party/tensorflow/compiler/mlir/xla/experimental/conv_emitter/conv_emitter.cc:146:58: note: remaining 16 candidates omitted; pass -fshow-overloads=all to show them
                        return for_op.getBody()->front() == &*begin_op;
                                                         ^
third_party/tensorflow/compiler/mlir/xla/experimental/conv_emitter/conv_emitter.cc:220:66: error: expected ')'
    for (auto ancestor_and_new : llvm::zip(ancestors, new_loops) {
                                                                 ^
third_party/tensorflow/compiler/mlir/xla/experimental/conv_emitter/conv_emitter.cc:220:9: note: to match this '('
    for (auto ancestor_and_new : llvm::zip(ancestors, new_loops) {

Ahhh I just used your code https://github.com/tensorflow/tensorflow/pull/52472#discussion_r762388923

Please re-open when the build failures are fixed

@joker-eph I fixed the second error but the first one with your solution https://github.com/tensorflow/tensorflow/pull/52472#discussion_r762388923 is still ambiguous for ==

I'm not sure what you mean by "ambiguous"?
There is just a & missing I think:     return &for_op.getBody()->front() == &*begin_op;

It can also be written: return &*for_op.getBody()->begin() == &*begin_op;

Ok I've made that change also (see my fork's branch)


Error with wildcard in Include ssh directive

When reading the ssh config, the wildcards  in the Include ssh directive are not treated.
  Multiple
pathnames may be specified and each pathname may contain
glob(7) wildcards and, for user configurations, shell-
like ‘~’ references to user home directories.
[...]

I'm closing the issue because of the multiple workarounds available: use the --ssh-config option or switch to the ssh backend.


Share your blog

hlo pls assign me to this issue

pls assign me to this issue

Hello Sir, can you assign me this issue?


seal[hexl]:  cannot find -leasyloggingpp: No such file or directory

Description:
I installed Microsoft SEAL using vcpkg on WSL2 with the following command:
vcpkg install seal[hexl]

Then, I got an error /usr/bin/ld: cannot find -leasyloggingpp: No such file or directory in the Debug (CMAKE_BUILD_TYPE=Debug) while the same error did not appear in Release. I use the following CMake Commands:
cmake .. -DCMAKE_BUILD_TYPE=Debug -DCMAKE_TOOLCHAIN_FILE=/home/konjak/vcpkg/scripts/buildsystems/vcpkg.cmake
cmake --build .

Failure log
konjak@lab:~/Sealtest/build$ cmake .. -DCMAKE_BUILD_TYPE=Debug -DCMAKE_TOOLCHAIN_FILE=/home/konjak/vcpkg/scripts/buildsystems/vcpkg.cmake
-- The C compiler identification is GNU 11.4.0
-- The CXX compiler identification is GNU 11.4.0
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: /usr/bin/cc - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++ - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Found ZLIB: optimized;/home/konjak/vcpkg/installed/x64-linux/lib/libz.a;debug;/home/konjak/vcpkg/installed/x64-linux/debug/lib/libz.a (found version "1.3.0")
-- Intel HEXL found
-- Looking for pthread.h
-- Looking for pthread.h - found
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD - Success
-- Found Threads: TRUE
-- Microsoft SEAL -> Version 4.1.1 detected
-- Microsoft SEAL -> Targets available: SEAL::seal
-- Found PkgConfig: /usr/bin/pkg-config (found version "1.8.0")
-- Checking for module 'easyloggingpp'
--   Found easyloggingpp, version 9.96.7
-- Configuring done
-- Generating done
-- Build files have been written to: /home/konjak/Sealtest/build
konjak@lab:~/Sealtest/build$ cmake --build .
[ 50%] Building CXX object CMakeFiles/main.dir/main.cpp.o
[100%] Linking CXX executable main
/usr/bin/ld: cannot find -leasyloggingpp: No such file or directory
collect2: error: ld returned 1 exit status
gmake[2]: *** [CMakeFiles/main.dir/build.make:102: main] Error 1
gmake[1]: *** [CMakeFiles/Makefile2:83: CMakeFiles/main.dir/all] Error 2
gmake: *** [Makefile:91: all] Error 2

CMake Files Version 1
cmake_minimum_required(VERSION 3.11)

project(CMAKE_TEST)

set(CMAKE_CXX_STANDARD 11)

add_executable(main main.cpp)

find_package(SEAL CONFIG REQUIRED)

target_link_libraries(main PRIVATE SEAL::seal)

CMake Files Version 2
cmake_minimum_required(VERSION 3.11)

project(CMAKE_TEST)

set(CMAKE_CXX_STANDARD 11)

add_executable(main main.cpp)

find_package(SEAL CONFIG REQUIRED)
find_package(PkgConfig REQUIRED)
pkg_check_modules(easyloggingpp easyloggingpp REQUIRED IMPORTED_TARGET)

target_link_libraries(main PRIVATE SEAL::seal PkgConfig::easyloggingpp)

Of course, this error can be fixed by installed easyloggingpp globally. But I think this solution is contrary to the original purpose of using VCPKG.


Protect against broken JSON packets

Port: https://github.com/HowProgrammingWorks/NodejsStarterKit/pull/167

Landed in https://github.com/metarhia/impress/commit/565a2e8afe65794b57518545c2e9ad370625782a


Setup GitHub Actions

We may want to do this.
https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-nodejs-or-python?langId=py

I am doing this and will push the changes.

Hii @AlvinKuruvilla . I have generated the PR . yOU CAN REVIEW AND MERGE IT.

Solved by #6

It looks like there is an issue with no module named venv on the python 2.7 build


Masked array performance

Given https://github.com/SciTools/iris/pull/3301 and https://github.com/SciTools-incubator/iris-agg-regrid/pull/37 we should consider whether masked arrays with no masked points should be automatically converted to ordinary ndarrays for obvious performance benefits.
Note that python-netcdf4 now automatically always returns masked arrays.
This could be considered as a breaking change in iris behaviour, and so puts it plum in 3.0.0 territory.

As a user of iris, I want comparable regridding performance when using masked array data where no points are masked (i.e. mask=False) and non-masked arrays.  I would also like to have the ability to apply this functionality to other areas of my code if I deem it necessary.
I would like the capacility to be avilable to users to apply else where in their code.
Acceptance Criteria

[ ] Create a function/decorator that can be applied to my iris function to give equivalent performance if my cube data is masked, but the mask is False.
[ ] The output cube data should remain masked if it was originally masked.  Remain unmasked if originally unmasked.
[ ] The function/decorator is applied to appropriate iris regridding methods.
[ ] Have an ASV benchmark to prove the benefits of the solution.
[ ] The new functionality should be in the what's new.
[ ] The new functionality is documented in the user guide.

masked array data where no points are masked (i.e. mask=False)

That "i.e." isn't quite an equation : You can still have a mask array, but with no True values.
For operations where masks are costly, like regridding, it will still be worth the cost of a test + convert.
But it probably needs to be on a case-by-case basis.
We should have some common code for it, though.

... meanwhile, could we not routinely convert the mask=False cases on loading, if that is generally useful ??

This week I learned that a whole new implementation of masked arrays is afoot:
https://github.com/ahaldane/ndarray_ducktypes/blob/master/doc/MaskedArray.md
Note that the owner of that repo is a numpy "member" and another member indicated a consensus for replacing numpy masked arrays "at some point" with something developed outside numpy: https://github.com/numpy/numpy/pull/16022#issuecomment-618616577

First steps of investigation
The netcdf4 package represents unmasked data using a masked array with a full array of masks - [False] with a shape matching the underlying data array. Some performance can be gained by setting the mask to a single False value, thanks to optimisations within NumPy itself for 'non-masked masked arrays' (thanks to @rcomer for this example).
There is however a larger amount of performance to be gained if we can operate on pure NumPy arrays. This may be because implementations in numpy.ma are sometimes piecemeal, so the non-masked optimisation might not be fully implemented. I unfortunately don't have the available resource to investigate within NumPy itself, so I will further pursue the idea of converting to NumPy arrays while operations are being performed.

How I investigated
SciTools/iris-agg-regrid#37 seemed like a good lead, so I used necromancy to get iris-agg-regrid working again and ran the below script.
Expand for the script
from time import time

import iris
from iris.cube import Cube
import numpy as np
from numpy.random import random
from numpy import ma

from agg_regrid import AreaWeighted

def main():
    global_air_temp = iris.load_cube(iris.sample_data_path('air_temp.pp'))
    rotated_psl = iris.load_cube(iris.sample_data_path('rotated_pole.nc'))

    def upsample_cube(cube_in: Cube):
        upsample_factor = 10

        new_dim_coords = []
        for coord_in in cube_in.dim_coords:
            points = coord_in.points
            new_points = np.linspace(points.min(), points.max(), len(points) * upsample_factor)
            new_dim_coords.append(coord_in.copy(points=new_points))

        new_shape = [len(c.points) for c in new_dim_coords]
        new_data = random(new_shape)

        return Cube(
            data=new_data,
            dim_coords_and_dims=[(c, ix) for ix, c in enumerate(new_dim_coords)]
        )

    global_air_temp = upsample_cube(global_air_temp)
    rotated_psl = upsample_cube(rotated_psl)

    for coord_name in ("longitude", "latitude"):
        src_coord = global_air_temp.coord(coord_name)
        tgt_coord = rotated_psl.coord(f"grid_{coord_name}")
        for coord in (src_coord, tgt_coord):
            coord.guess_bounds()

    area_weighted = AreaWeighted()

    def time_regridding(src_cube: Cube):
        regridder = area_weighted.regridder(src_cube, rotated_psl)
        time_start = time()
        _ = regridder(src_cube)
        time_elapsed = time() - time_start
        print(f"Elapsed seconds: {time_elapsed}")

    print("Basic NumPy ...")
    global_air_temp.data = np.asarray(global_air_temp.data)
    time_regridding(global_air_temp)

    print("Simple masked ...")
    global_air_temp.data = ma.asarray(global_air_temp.data)
    time_regridding(global_air_temp)

    print("Full masked ...")
    full_mask = np.broadcast_to(np.array(False), global_air_temp.data.shape)
    global_air_temp.data = ma.array(global_air_temp.data.data, mask=full_mask)
    time_regridding(global_air_temp)

if __name__ == "__main__":
    main()

Results:
Basic NumPy ...
Elapsed seconds: 1.890709638595581
Simple masked ...
Elapsed seconds: 1.89862060546875
Full masked ...
Elapsed seconds: 1.6773123741149902

Then I disabled the conversion introduced in SciTools/iris-agg-regrid#37, which produced the below results:
Basic NumPy ...
Elapsed seconds: 1.7257087230682373
Simple masked ...
Elapsed seconds: 4.838908910751343
Full masked ...
Elapsed seconds: 5.676675796508789

Possible approaches
Convert all inputs of a function, re-convert on output
Pros

Clear to the developer applying the decorator

Cons

Non-masked masked arrays can either be masked with an array of False, or with a single np.ma.nomask value. Difficult/impossible to know which masking strategy to apply when re-converting. Could skip conversion if presented with a mixture?

Array sub-classes
Pros

Obvious signal that they should be converted back
Can store the appropriate masking strategy to re-apply

Cons

How to re-convert? Ideally check every return value, but what if function includes object modification too?
More complex development pattern

A 'register' of objects to re-convert
Don't know how to implement this. A register of Cubes would work - can run my_cube.data =  - but this concept is most useful if it can also work on straight arrays, and these are not contained by another object so assignment isn't possible.

(peloton test comment)

(peloton test comment)

I believe #5178 proves that, while there is a case for optimisation in specific cases, there isn't much benefit in a generic way of temporarily un-masking. Happy to open if others think differently.


Enumerating dev boxes takes 30 seconds after app first launches.

Dev Home version
0.1401.500.0
Windows build number
10.0.22631.3296
Other software
OS Build Version: 10.0.22631.3296.amd64fre.ni_release.220506-1250
.NET Version: .NET 8.0.4
Steps to reproduce the bug
Enumerating dev boxes takes 30 seconds after app first launches. Then it is down to 10 seconds. Several repeated restarts show the same behavior.
Expected result
<10 seconds.
Actual result
30 seconds
Included System Information
CPU: Intel(R) N200
Physical Memory: 7.83GB (2.71GB free)
Processor Architecture: x64
Included Extensions Information
Extensions:
Microsoft.Windows.DevHome.Canary_0.1401.500.0_x64__8wekyb3d8bbwe (Core Widget Extension)
Microsoft.Windows.DevHome.Canary_0.1401.500.0_x64__8wekyb3d8bbwe (Hyper-V Extension)
Microsoft.Windows.DevHomeAzureExtension.Canary_0.900.500.0_x64__8wekyb3d8bbwe (Dev Home Azure Extension (Canary))
Widget Service:
MicrosoftWindows.Client.WebExperience_424.1301.450.0_x64__cw5n1h2txyewy

This was fixed in https://github.com/microsoft/DevHomeAzureExtension/pull/168


SSO and saving users in Camunda DB.

Hello! Related to Spring Security Camunda
I have a question about SSO. In regards for the case when SSO is working, but for this case, users don't save into Camunda database. After authentication logs show us warning about it.
It's good to save the data into the User database.
How do you think, how can it be implemented?

With SSO you can either use the LDAP plugin to load the groups of an authenticated user or provide them as part of the SSO.

Duplicating user data into Camunda's database is not recommended if another system is managing them.

I got it. Thanks for an answer.


Enable productionMode by default for the StaticContentVaadinServlet

Closes #108

Hi,
This commit might have had unwanted side-effects as Vaadin will not compile .scss if it's in production mode.
I don't understand the rationale behind this - it's like JSP being compiled on first access, but you have to explicitly set vaadin.servlet.params.productionMode to false or take care of the compilation in the build.

You are right, but it does not really matter, since there will be no StaticContentVaadinServlet as of version 0.0.6. I'll be migrating the project to the official Vaadin Spring add-on then.


Add new fields for diversity in contacts CSV

Is your feature request related to a problem? Please describe.
As an admin I need to be able to see more information relating to diversity in the contacts CSV download. I need this so I can send a complete set of data to the diversity officer to get clearance to my next stage of an exercise.
Describe the solution you'd like
The following fields need to be added to the contacts CSV:

'Professional background"
'Attended UK state school'
'First generation to attend University'

Describe alternatives you've considered
The full diversity report but this is a complex piece of work and this is needed more urgently. The teams can calculate the numbers and percentages for now.
Additional context
Nothing further.

@warrensearle if there is any possibility of this being done by Monday evening that would be great. Thanks.

Sure thing


Upgrade doesn't work for machines where --virtualbox-boot2docker-url was used in create

To recreate:
$ docker-machine create -d virtualbox --virtualbox-boot2docker-url=https://github.com/boot2docker/boot2docker/releases/download/v1.8.3/boot2docker.iso 183

$ docker-machine upgrade 183
Stopping machine to do the upgrade...
Upgrading machine 183...
Downloading boot2docker.iso from https://github.com/boot2docker/boot2docker/releases/download/v1.8.3/boot2docker.iso...
Starting machine back up...

$ docker-machine ssh 183 docker -v
Docker version 1.8.3, build f4bf5c7

I'd expect that machine to be upgraded to the latest version of Docker

/cc @tiborvass per https://github.com/docker/machine/issues/2098#issuecomment-154126476

cc @nathanleclaire

It's difficult to say what the right behavior should be, since there are certainly users who would expect a custom-used ISO to never be overwritten.

I would recommend two distinct behaviours
docker-machine update

Gets the latest version of the ISO at the provided URL
This is useful for folks using custom ISOs

docker-machine upgrade

Get the latest boot2docker ISO and upgrades the machine
Perhaps we allow for a version to be specified, if present, upgrade to that one
Also, we could allow pre-release versions, and if enabled, upgrade to the latest release candidate

I don't like having both update and upgrade.
Tibor Vass
On Thu, Nov 5, 2015 at 8:22 PM, Dave Tucker<EMAIL_ADDRESS>wrote:

I would recommend two distinct behaviours
docker-machine update

Gets the latest version of the ISO at the provided URL
This is useful for folks using custom ISOs

docker-machine upgrade

Get the latest boot2docker ISO and upgrades the machine
Perhaps we allow for a version to be specified, if present, upgrade
to that one
Also, we could allow pre-release versions, and if enabled, upgrade
to the latest release candidate

—
Reply to this email directly or view it on GitHub
https://github.com/docker/machine/issues/2195#issuecomment-154255163.

I guess I was trying to say, instead of having one command doing 2 things for 2 different users, it might make sense to split the command in two.
update could be renamed recreate or create --recreate or similar if that makes it more palletable
Without splitting the behaviours, the other approach I can think of would be as follows:

add some logic that looks at the b2d iso and see's if it's from the b2d repo
if yes, then get the latest release and upgrade
if no, just fetch the latest version of the ISO

I get bad vibes from just thinking about baking assumptions like that (only upgrade ISOs from b2d repo) in to code.
Especially as the "upgrade" logic could be useful if users were able to change the GitHub repo via a flag. For example, If I'm developing a boot2docker style ISO (e.g https://github.com/docker/boot2docker), it would be useful to me to have users specify that they want this at create time and to re-use the upgrade checking logic.
docker-machine create -d virtualbox --virtualbox-boot2docker-repo docker/boot2docker debian
# When a new release is pushed
docker-machine upgrade debian

Unfortunately, this will hit hard in the near future, as the b2d for Docker 1.9.1 is broken and many people had to use a 1.9.0 issue or custom images...
WDYT of a -f flag to force upgrading to the latest official Boot2Docker image ?
Which would basically boil down to overwrite the "Boot2DockerURL" and reset it to an empty string, as it is when no custom URL is provided.

I encountered this problem while trying to update to docker 1.10.
I understand that defining a new behavior (wether it's a -f flag or new commands) is hard, but in the meantime maybe docker-machine could just display a simple message indicating no upgrade have been performed because of the --virtualbox-boot2docker-url usage ? At least people will not wonder why nothing happened even if the command successfully ran.

I understand that defining a new behavior (wether it's a -f flag or new commands) is hard, but in the meantime maybe docker-machine could just display a simple message indicating no upgrade have been performed because of the --virtualbox-boot2docker-url usage ? At least people will not wonder why nothing happened even if the command successfully ran.

Sounds good, a new issue / PR for this would help us to track the feature request if you're willing.

@nathanleclaire provided a PR for this @ #3019


Update kobackupdec.py

This patch allow to run the script as normal user (ie without sudo) by setting -rx permission (ie 0o755) to directories. Indeed, Linux need -rx permissions to allow read directories contents, not only -r.
Until now chmod 0o444 at the end of the script prevent read output directories and crashes the script if ran as standard user (ie without sudo).
Also tested with Windows 10 with Python 3.8.1.

Thanks @lp4n6 !


install error

Which version of PhantomJS are you using? Tip: run phantomjs --2.1.7.

What steps will reproduce the problem?

PhantomJS not found on PATH
Downloading https://github.com/Medium/phantomjs/releases/download/v2.1.1//phantomjs-2.1.1-macosx.zip
Saving to /var/folders/26/fk34yzmj2nqfmbwr3_0y90kr0000gn/T/phantomjs/phantomjs-2.1.1-macosx.zip
Receiving...

Error making request.
Error: connect ETIMEDOUT <IP_ADDRESS>:443
    at Object.exports._errnoException (util.js:860:11)
    at exports._exceptionWithHostPort (util.js:883:20)
    at TCPConnectWrap.afterConnect [as oncomplete] (net.js:1063:14)

Which operating system are you using?
macOS

Did you use binary PhantomJS or did you compile it from source?

Please provide any additional information below.

npm ERR<EMAIL_ADDRESS>install: `node install.js`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the<EMAIL_ADDRESS>install script 'node install.js'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the phantomjs-prebuilt package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     node install.js
npm ERR! You can get information on how to open an issue for this project with:
npm ERR!     npm bugs phantomjs-prebuilt
npm ERR! Or if that isn't available, you can get their info via:
npm ERR!     npm owner ls phantomjs-prebuilt
npm ERR! There is likely additional logging output above.

Thank you for submitting the ticket. But we don't maintain the NPM package. Please file your issue under the corresponding repository. Thank you!


"malformed zng record" created in Zed lake journal

Repro is with zed commit a5bdb86.
I have a demo setup that's calling zed lake load on Zeek logs as they rotate every 60 seconds. After letting it run for a few minutes, it got into a state where I'm unable to fully read the journal because of a malformed entry.
$ zed lake log -p default
commit 1rX6vtBPruI8QW1soh6HIyqRXLK
Author<EMAIL_ADDRESS>Date:   2021-04-22T16:52:00Z

    load dns.2021-04-22-09-51-32.log

    Add 1rX6vphLSLV447qSsiWFi49RXue 967B data 726B file 6 records
       from 2021-04-22T16:51:32Z to 2021-04-22T16:51:31Z

commit 1rX6vtZhBvgsw8BEVUwD9cWWDo6
Author<EMAIL_ADDRESS>Date:   2021-04-22T16:52:00Z

    load known_hosts.2021-04-22-09-51-33.log

    Add 1rX6vpYwNfO2W2HQc0MznffNJWd 26B data 48B file 1 records
       from 2021-04-22T16:51:32Z to 2021-04-22T16:51:32Z

commit 1rX6vuDQoUZ4lMPut5BqlxPeqJy
Author<EMAIL_ADDRESS>Date:   2021-04-22T16:52:00Z

    load stats.2021-04-22-09-51-30.log

    Add 1rX6vofrTxaOZmnKayI5zyqCC7L 59B data 417B file 1 records
       from 2021-04-22T16:51:30Z to 2021-04-22T16:51:30Z

commit 1rX6vsp4X7e6TgpU6Ey6DLmg2Qs
Author<EMAIL_ADDRESS>Date:   2021-04-22T16:52:00Z

    load ssl.2021-04-22-09-51-33.log

    Add 1rX6vod7F9ztcziwa35zyh5h1So 110B data 374B file 1 records
       from 2021-04-22T16:51:32Z to 2021-04-22T16:51:32Z

commit 1rX6w0PbaOIicKWdk6VWetFuNAj
Author<EMAIL_ADDRESS>Date:   2021-04-22T16:52:01Z

    load conn.2021-04-22-09-51-38.log

    Add 1rX6vwauuR03aVG1a0baa2r4pMD 788B data 834B file 9 records
       from 2021-04-22T16:51:48Z to 2021-04-22T16:51:31Z

commit 1rX73SYlExHFIioqVWjuPlvgQtH
Author<EMAIL_ADDRESS>Date:   2021-04-22T16:53:00Z

    load dns.2021-04-22-09-52-00.log

    Add 1rX73OLtAl031vMdhNE9R8f5i1D 13.68KB data 3KiB906B file 95 records
       from 2021-04-22T16:52:52Z to 2021-04-22T16:51:43Z

malformed zng record

I then narrowed the problem down to the attached 6.zng.gz.
~/Library/Application Support/Brim/data/spaces/sp_1rX6pGXhUMIdeXfE1Pm2V2HGzQq/1rX6pI0pT900dWoLCUF2ILnvELk/L/J$ for file in *.zng; do   zq -z $file > /dev/null; done
6.zng: malformed zng record

~/Library/Application Support/Brim/data/spaces/sp_1rX6pGXhUMIdeXfE1Pm2V2HGzQq/1rX6pI0pT900dWoLCUF2ILnvELk/L/J$ zq -z 6.zng
{commit:0x0d0f5becfd275b16ee40df063288020904a1d56b (=KSUID),segment:{id:0x0d0f5bec72e79f25f9799ea96ffd8d4456ad93a3 (KSUID),meta:{first:2021-04-22T16:52:52.688975Z,last:2021-04-22T16:51:43.468973Z,count:95 (uint64),size:13681,row_size:3978} (=Metadata)} (=Reference)} (=Add)
{commit:0x0d0f5becfd275b16ee40df063288020904a1d56b (KSUID),author:"root@PhilMac.local",date:2021-04-22T16:53:00.557311Z,message:"load dns.2021-04-22-09-52-00.log"} (=CommitMessage)
6.zng: malformed zng record

This is a bit mysterious right now.  The zng stream ends in 67 ff then these last two byte are repeated causing the "corruption".  The journal files are written with ioutil.WriteFile so anything left behind by accident would be truncated.  The zng marshaler does a builder.Reset then a Bytes, so that shouldn't be creating extra bytes.  The zngio.Writer is properly closed by commit.Transaction.Serialize starting from an empty bytes.Buffer.  Given that the repeated data includes EOS, it seems like a problem in the write path after the marshaling but zngio.Writer is very old and stable.  Feels like mutex but the writer should be single threaded.  Hmm.

I've come up with a recipe that reproduces this pretty well. It's quite abusive of course. I'm currently repro'ing with zed commit e8f6d09.
If you've got the Zeek TSV zed-sample-data cloned locally, execute these commands while in the zed-sample-data/zeek-default/ directory. It'll initialize an empty lake+pool and start populating it with repeated concurrent loads of the full set.
export ZED_LAKE_ROOT=$HOME/logs
rm -rf $ZED_LAKE_ROOT
zed lake init
zed lake create -p default -k ts -order desc
while true; do for file in *; do   zed lake load -p default $file & done; wait; done

I'm not sure if it's related, but in the output I see some other signs of unhealthiness, including this message occasionally:
strconv.ParseUint: parsing "": invalid syntax

Also this one:
file:///Users/phil/logs/1rXXBFSkoTKLXF0WgsVU0N7ohBE/L/J: no such journal

As for the malformed zng record, sometimes it comes right away and sometimes it takes a few minutes, but I find that if I keep executing zed lake log -p default from another window eventually it happens.

Ah okay.  You're backgrounding the zed commands so they are running concurrently and stomping on each other's journal.  Adding transactional consistency here is part of the design but not yet implemented.  I will put in the hook for the local file system, which will solve your problem for now, but we'll also need to implement S3.

171
820
103
364

Indeed, the concurrency seems to be key. I checked with @JustinAzoff from the Zeek team and he confirmed that the way I was doing it via zeekctl, the archive-log scripts (and hence the postprocessor scripts like one I had doing the zed lake load) are effectively all started in parallel for all the rotated logs. My while loop above is just a more abusive way to get the same kind of concurrency quicker.
To log a baseline before I test a fix, I just did repeated runs of the while loop and logged how many successful commits accumulated in the log before I saw the malformed zng record error. The counts across five runs were 171, 820, 103, 364, and 117. Then I started a run that doesn't background them and hence does each zed lake load serially, and it's accumulated 6400+ successful commits and is still going without a problem, so that further validates that it's all about concurrency. I see there's a test branch up, so will try that next.

Verified in zed commit 3fb771c.
Using this fixed version of zed, I repeated the abusive while loop shown above and left it running for several minutes. Thus far I've accumulated 9000+ successful commits without a repro of the malformed zng record, and it's still chugging along. This is far in excess of the <1000 commits it would make it through before triggering the problem pre-fix.
$ zed lake log -p default | grep commit | wc -l
    9089

That said, similar to what I described during the branch tests in linked PR #2616, I can see there's still some odd items appearing in the output during the abusive/concurrent loop that don't show up when I do each zed lake load "serially". Specifically these show up as occasional:
strconv.ParseUint: parsing "": invalid syntax

and:
file:///Users/phil/logs/1ragtZ8VeRNbaQaSjSUK81hOhlA/L/J: no such journal

I've not yet connected these to any user-visible problems with the actual data, so they may turn out to be benign. However since they're unexpected and only show up during heavy concurrency, I'll make a note-to-self in #2615 to re-run these tests after those changes land, since it looks like that will significantly overhaul how we handle concurrency and increase our testing in that area.
Thanks @mccanne!


MSID: 95842 Version: 1 DOI: 10.1101/2<IP_ADDRESS>6925

MSID: 95842
Version: 1
Preprint DOI: https://doi.org/10.1101/2<IP_ADDRESS>6925
Step 1. Awaiting reviews
Editorial to post reviews via hypothesis
Useful links:

DocMap: https://data-hub-api.elifesciences.org/enhanced-preprints/docmaps/v2/by-publisher/elife/get-by-manuscript-id?manuscript_id=95842
New model tracking: https://docs.google.com/spreadsheets/d/1_fHaoOy7hjyocptKtVJRijeNpUY4hBS7Ck_aVmx6ZJk/
Reviews on sciety: https://sciety.org/articles/activity/10.1101/2<IP_ADDRESS>6925

For trouble shooting (e.g. no Docmaps available):

DocMap issue addressing: https://miro.com/app/board/uXjVNCwK6EI=/
Explore DataHub DocMaps API: https://lookerstudio.google.com/reporting/4c2f0368-babb-4beb-b5b3-497e7e7b0f08/page/ejphD
Unmatched submissions and preprints: https://lookerstudio.google.com/u/0/reporting/9f86204f-3bf7-477c-9b18-5c5ef141bf69/page/p_gxi57ha93c
Unmatched manuscripts spreadsheet: https://docs.google.com/spreadsheets/d/15QcK8w-ssB7109RQEDtFpJPZ0J5HTGxoHa_2TtpMBbg/edit#gid=1336081641

Step 2. Preview reviewed preprint
Production QC content ahead of publication
Instructions:

QC preview: https://prod--epp.elifesciences.org/previews/95842v1
Update ticket with any problems (add blocked label)
When QC OK, add QC OK label to ticket and add publication date and time to https://docs.google.com/spreadsheets/d/1amAlKvdLcaDp5W8Z8g77NmkwbMF5n_u89ArSqPMO8jg
Move card to next column
(At end of the day post link in #enhanced-preprint and ask for PDF to be generated)

Useful links:

Preprint DOI :  https://doi.org/10.1101/2<IP_ADDRESS>6925
Confirm reviews returned by EPP: https://prod--epp.elifesciences.org/api/reviewed-preprints/95842/v1/reviews
To update the MECA path in the docmap: https://docs.google.com/spreadsheets/d/1mctCQuNFBjSn97Lihy7_vBO6z7-N-oqyLv4clyi6zHg

Step 3: Awaiting search reindex
This step adds the reviewed preprint to the homepage: https://elifesciences.org
The search reindex is triggered once an hour. We need the reviewed preprint to be indexed as the search application serves the journal homepage.
Useful links:

Jenkins pipeline to reindex search can be triggered sooner or monitored here: https://alfred.elifesciences.org/job/process/job/process-reindex-reviewed-preprints/

Step 4: Published! PDF requested
Waiting for PDF to be generated
Useful links:

PDF tracking: https://docs.google.com/spreadsheets/d/106_XeDjmuBae7gexOTNzg60lapeqjl2aRn9DzupGyS8/

Step 5: Introduce PDF to data folder and git repo
Upload PDF to relevent folder in git repo https://github.com/elifesciences/enhanced-preprints-data/
Step 6: Done!

[ ] Kettle is on!

This has been posted to the v2, but the revision summary for v3 is:

I am uploading 3 tables (as Excel files, hopefully) that are called from within the manuscript but which I forgot to upload during the last revision. Apologies for this oversight.

So I think we should be using the v3.
Going to move the reviews across. Also there's a structural issue which needs fixing.


Question: May I ask how it works?

I dug a little and noticed that calling Binary.build() requires downloading a file from https://nbin.cdr.sh/1.2.7/node-12.14.0-linux-x86_64, which is then concatenated with other buffers to create the binary. Could you please elaborate a little on the origin of this file? I just want to know what's going on running the binary... Thank you very much!

Oh, just figured it out, it's all within the repository...
Never mind :)


Update to diesel 2.0

I propose to publish this to crates.io after my holiday.

enjoy your holiday :)


[FLINK-22171][sql-client][docs] Update the SQL Client doc

What is the purpose of the change
Update the SQL Client doc.
Documentation

Does this pull request introduce a new feature? (yes / no)
If yes, how is the feature documented? (not applicable / docs / JavaDocs / not documented)

@flinkbot run azure


feat: support the process dashboard and create the time range text widget

Support the process dashboard and create the time range text widget.
Video
https://user-images.githubusercontent.com/20871783/184570573-55ba9e5b-e960-4e91-a75f-7c3021034360.mov
Signed-off-by: Qiuxia Fan<EMAIL_ADDRESS>

Could you add a text field as additional description?

Could you add a text field as additional description?

What do you think of this?
https://user-images.githubusercontent.com/20871783/184588565-9b55029c-0307-44f3-bc00-3d4edb1af7ce.mov

Let us put the text before the time range.

Screenshot


Redirect URL mismatch

What is the problem you are having with rclone?
When using the auto config for a Dropbox remote, rclone says my redirect URL should be http://<IP_ADDRESS>:<port>. But the redirect URL actually used by auto config is http://localhost:<port>! This results in an error since <IP_ADDRESS> != localhost for Dropbox.
What is your rclone version (eg output from rclone -V)
rclone v1.41

os/arch: linux/amd64
go version: go1.10.1

Which OS you are using and how many bits (eg Windows 7, 64 bit)
Arch Linux, 64 bit
Which cloud storage system are you using? (eg Google Drive)
Dropbox
The command you were trying to run (eg rclone copy /tmp remote:tmp)
rclone config

Both rclone and the dropbox developer app console agree that the redirect URL should be http://localhost:53682/

What exactly do you mean by this - can you paste some messages maybe?

When using the auto config for a Dropbox remote, rclone says my redirect URL should be http://<IP_ADDRESS>:.

Have you made your own app credentials?
How does the error manifest itself?

Hi! Well, this is a bit confusing since I just now noticed that the message is only displayed when using a Dropbox app (fill out client_id and client_secret). This is my rclone output
[...]

Storage> 7
Dropbox App Client Id - leave blank normally.
client_id> xxxxxxxxxx
Dropbox App Client Secret - leave blank normally.
client_secret> xxxxxxxxxxxx
Remote config
Make sure your Redirect URL is set to "http://<IP_ADDRESS>:53682/" in your custom config.
Use auto config?
 * Say Y if not sure
 * Say N if you are working on a remote or headless machine
y) Yes
n) No
y/n>

As you can see, it is telling me to use http://<IP_ADDRESS>:53682/. If I use it as redirect url it fails. If I use http://localhost:53682/ it works. Therefore, I think, rclone should suggest using http://localhost:53682/ instead of http://<IP_ADDRESS>:53682/
BTW: Thanks for this great tool! ;)

I see!
I've fixed this now
https://beta.rclone.org/v1.41-058-ge62d2fd3/ (uploaded in 15-30 mins)
This will be in the latest beta from now on and 1.42
Thanks for explaining the problem :-)

Thanks for fixing!


Clicking textfield does not trigger true click

See Gif below. In order to get the placeholder(?) to animate, you must click it? It should trigger when you click the textfield area too.

Dangit, wrong library sorry


get_iostat_sys in linux_sigar.c causes memory corruption

Hello,
I'd like to report get_iostat_sys bug which was founded when I was investigating the ElasticSearch issue https://github.com/elastic/elasticsearch/issues/9582.
The function has a following code
    if (!(*iodev = sigar_iodev_get(sigar, dirname))) {
        return ENXIO;
    }

    name = fsdev = (*iodev)->name;

    if (SIGAR_NAME_IS_DEV(name)) {
        name += SSTRLEN(SIGAR_DEV_PREFIX); /* strip "/dev/" */
    }

    while (!sigar_isdigit(*fsdev)) {
        fsdev++;
    }

    partition = strtoul(fsdev, NULL, 0);
    *fsdev = '\0';

For example, if (*iodev)->name is /dev/ploop50957 (it's a real case value), *fsdev = '\0' line replaces the first 5 in the path by NULL. It doesn't cause an issue first time but the value is cached one so it's used repeatedly. Second time, the (*iodev)->name is /dev/ploop\00957 and sigar_isdigit returns false at the NULL character so 0 is replaced by NULL. Third time, the value is /dev/ploop\0\0957...
In this way, the function replaces the value referred by (*iodev)->name with NULL repeatedly and causes a segmentation fault.
To resolve it, I suggest a fix like following
diff --git a/src/os/linux/linux_sigar.c b/src/os/linux/linux_sigar.c
index a3fd230..1a5068b 100644
--- a/src/os/linux/linux_sigar.c
+++ b/src/os/linux/linux_sigar.c
@@ -1182,7 +1182,7 @@ static int get_iostat_sys(sigar_t *sigar,
                           sigar_disk_usage_t *disk,
                           sigar_iodev_t **iodev)
 {
-    char stat[1025], dev[1025];
+    char dev_name[256], stat[1025], dev[1025];
     char *name, *ptr, *fsdev;
     int partition, status;

@@ -1190,7 +1190,8 @@ static int get_iostat_sys(sigar_t *sigar,
         return ENXIO;
     }

-    name = fsdev = (*iodev)->name;
+    SIGAR_SSTRCPY(dev_name, (*iodev)->name);
+    name = fsdev = dev_name;

     if (SIGAR_NAME_IS_DEV(name)) {
         name += SSTRLEN(SIGAR_DEV_PREFIX); /* strip "/dev/" */

It's just a quick hack so other ideas welcome.

Looks like you may have to report this here if no one responds on github - https://jira.hyperic.com/browse/SIGAR

@prabhu, thanks for the comment. No one of the project hasn't responded for 5 days so I'll send the report to Developers forum too. It annoys me a little that it requires filling out many forms for account registration to just send a bug...

Done. The post is https://communities.vmware.com/message/2498829#2498829


Allow GIL to be released with threads=1

Currently the GIL is never released during executions if the FFTW object is single threaded. In a Python multithreaded environment, it may be helpful to execute FFTW objects in parallel in different Python threads so there should be a way for the user to turn off the GIL even when the number of threads used by the FFTW object is 1.

Hi,
is this an issue for the following use, many instances of the same FFT being called on each of a
large number of identical arrays. The routine uses the multiprocessing module . Abbreviated code is below.
In this use, I have two questions that seem to be related to this issue ,

Does this suffer from not ulocking the GIL as mentioned, thus it should be faster than it is? It seems faster than using one single thread already.

Is it threadsafe against multiple threads modifying the array being processed in fft_object? I thought that fftw used the exact array that was designated at "planning" time ? Or is it always using an array of identical type but in a different memory location?

Thanks
Robert

import pyfftw
import multiprocessing.
**** In main routine ***
fft_object = pyfftw.FFTW(a, b, axes=(0,1))
ifft_object = pyfftw.FFTW(c, d, axes=(0,1), direction='FFTW_BACKWARD')
for i in range(n):
p = multiprocessing.Process(target=ravenfilter,args=((..blah..blah.., fft_object,ifft_object)))
jobs.append(p)
p.start()
**** In a function****
def ravenfilter( ... several args... , fft_object,ifft_object):
... get the array 'sinogram' somehow ...
sino2=ft_object(sinogram)
... more operations ..

Lots of calls to identical arrays should not really be affected by the GIL issue unless you're running stuff in multiple threads yourself. Multiprocessing uses different processes anyway so shouldn't really be affected either way.

It's perfectly plausible that many small transforms are faster in a single thread in which the threading overhead is greater than any speed up. As always, try it and see :)

If multiple threads hit the same array, you should expect things to break. The idea is that other threads might be doing other things (or running other FFTW instances or whatever) and so the GIL can be released whilst FFTW is working.

Does that answer the qs?

Thanks for the speedy reply.
I am afraid it may answer the question by referring to things I am not familiar enough with, in Python.
If you can clarify a couple of things about your answer it would be very helpful.
'unless you're running stuff in multiple threads yourself' -- I am not sure , technically speaking, what constitutes 'running it yourself' . In this case the function launched by Process simplly filters in Fourier space i.e. does  a forward transform, some arithmetic, then a reverse transform. At present it also inputs and outputs from/to the disk. It is only accessed through multiprocessing. Process and no other threading library or operations are used in this Python script. Is that what you mean, if I used other threading outside multiprocessing.Process module? Is the 'multiprocessing' module not actually using threads?
I think your answer means that there is not a problem in this case?
My worry is about whether fft_object contains pointers to the original array used in planning (a and/or b) and whether this array is used during the call to the object. The object fft_object is passed to the thread function, but, technically, I don't really understand  whether that's a copy or a reference, nor whether the object does use this original array or not. In C-fftw, i was under the impression that it did and that one must 'plan' with the exact array that one performs the transform, but perhaps for more advanced users  it is sufficient to use an identically type and layout array in a different location in memory, and this is what pyFFTW does?
Thanks again
Robert

No, multiprocessing is not using threads at all, but separate processes (this is how it can sidestep the GIL issue). I suspect in you case there is no problem; if you're not explicitly using threads, I doubt there are any being used.
I don't quite follow your last paragraph. Everything in python is by reference unless a copy is made explicitly - really "variables" are just references to some object or other. Do you mean in the context of multiprocessing? I'm actually not sure what happens here. You may be avoiding any problem by updating the memory when you call it (by passing a new input array). I honestly don't know... I think it must be copying, but I don't know how this interacts with FFTW. Does it work?

Fixed with 0fed0706aaa6898913d4e8716d7eb3f9a4a1351d.


Roll engine aa8fcbb65283..73dd5a33d9d1 (4 commits)

git@github.com:flutter/engine.git/compare/aa8fcbb65283...73dd5a33d9d1
git log aa8fcbb65283..73dd5a33d9d1 --no-merges --oneline
2019-10-02<EMAIL_ADDRESS>Roll fuchsia/sdk/core/linux-amd64 from LSKbP... to EeMsz... (flutter/engine#12751)
2019-10-02<EMAIL_ADDRESS>Roll src/third_party/skia a1ea0a96f490..ce240cc6fd8e (13 commits) (flutter/engine#12750)
2019-10-02<EMAIL_ADDRESS>Roll src/third_party/dart 98b286de21..eaf1c308ab (5 commits)
2019-10-02<EMAIL_ADDRESS>Add web implementation for channel_buffers.dart (flutter/engine#12747)
If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/flutter-engine-flutter-autoroll
Please CC<EMAIL_ADDRESS>on the revert to ensure that a human
is aware of the problem.
To report a problem with the AutoRoller itself, please file a bug:
https://bugs.chromium.org/p/skia/issues/entry?template=Autoroller+Bug
Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+/master/autoroll/README.md

Auto-roller completed checks. About to merge.


Introduce AttributeHydratorInterface

As suggested in https://github.com/woohoolabs/yang/issues/28#issuecomment-602545847

@holtkamp Sorry for this taking a long time. I like your solution, so merged the PR. :)


Update init.py

Sorry, but I'm persistent about using the one provided by trackerslist.com but you are free to use as u wish. Thank You, though.


Create a pull request in the main folder

Putting the title “First release to production” means metadata (assignees, labels, milestones, projects). Then merge the pull request.

The labels are not visible after the pull request has been accepted.


Save uploaded image to some log file for future backup

I think we can save all uploaded images to a file, such as json or xml. In this way, we can back up the pictures or import saved pictures to a database such as MySQL.
Any plan to add this feature? Thanks!

@upupming  Great idea! This may be the resolution to #8. BUT, these days, I may not have time to do this. THIS WILL BE IN THE PLAN. At the same time, a pull request is always  WELCOME!

Cool, I will try to open a PR 😜
On Sun, Mar 31, 2019, 11:02 PM Spades<EMAIL_ADDRESS>wrote:

@upupming https://github.com/upupming Great idea! This may be the
resolution to #8 https://github.com/Spades-S/vs-picgo/issues/8. BUT,
these days, I may not have time to do this. THIS WILL BE IN THE PLAN. At
the same time, a pull request is always WELCOME!
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/Spades-S/vs-picgo/issues/13#issuecomment-478349457,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AXmHhB4ksCwMhagbdFdNJZGBnCFp28Huks5vcM4agaJpZM4cUV2L
.


fix: fixture path to support commonjs and esm

Added a support for the commonjs and ESM to fixturepath.
Description

Motivation and Context

Screenshots (if appropriate):
Checklist:

[ ] I have updated/added documentation affected by my changes.
[ ] I have added tests to cover my changes.

Hey, thanks for the PR!
I'm happy to support this, however as it stands, this PR changes when require is called (it's now immediately rather than upon usage).
If you wouldn't mind addressing that, I'll merge this once the change is made.

A bit more context:
This desire for lazy evaluation is why fixture is a getter and the require call is inside the render function.  Since this library is intended to be used by tests, this means that a fixture with an error will cause a specific test to fail rather than blow up the whole suite.  In some cases, you may even want to test that a certain fixture throws.  Or if you grep/it.only to run a specific test, the suite is slowed down by unnecessarily loading all the fixtures.

@mlrawlings Thanks, addressed the comments.


Update README.md

Minutes posted to mailing list --> Minutes posted to wiki; Clarified that this includes all past calls.

Can we post to both the mailing list and wiki?

On Sun, Aug 30, 2015 at 03:28:27PM -0700, Rob Dolin wrote:

Minutes posted to mailing list --> Minutes posted to wiki;

I floated something like this in my initial version of #116
(61930a2a), but @vbatts suggested we hold off until we've been posting
to the wiki for longer 1.

I agree with @philips that we should BOTH post to mailing list and wiki.  PR updated.

LGTM

I really want to like the wiki. and it is more discoverable than the google docs folder. but the wiki syntax is awful. Markdown is fine. But, for instance, most wiki's have nested pages, like meeting-notes/2015-07-22 and when you go to the page meeting-notes you can see its children, but github wiki is a flat structure (no directories). And there is no "automatic lists of pages", so as the number of pages increases, then to keep track of them, there would have to be a separately edited page linking to each new page.

On Thu, Sep 03, 2015 at 12:18:29PM -0700, Vincent Batts wrote:

But, for instance, most wiki's have nested pages, like
meeting-notes/2015-07-22 and when you go to the page
meeting-notes you can see its children, but github wiki is a flat
structure (no directories).

I haven't used GitHub's wiki engine enough to know how this gets done
(maybe it's coded by hand) but the docs show a nested TOC 1.

TOC is different. It points to anchors on a same page, not nested pages...
On Thu, Sep 3, 2015 at 3:36 PM, W. Trevor King<EMAIL_ADDRESS>wrote:

On Thu, Sep 03, 2015 at 12:18:29PM -0700, Vincent Batts wrote:

But, for instance, most wiki's have nested pages, like
meeting-notes/2015-07-22 and when you go to the page
meeting-notes you can see its children, but github wiki is a flat
structure (no directories).

I haven't used GitHub's wiki engine enough to know how this gets done
(maybe it's coded by hand) but the docs show a nested TOC 1.
—
Reply to this email directly or view it on GitHub
https://github.com/opencontainers/specs/pull/127#issuecomment-137552605.

On Thu, Sep 03, 2015 at 12:40:10PM -0700, Vincent Batts wrote:

TOC is different. It points to anchors on a same page, not nested
pages...

Ah, bummer.

@vbatts maybe we can just agree on some naming standard for posting to the mailing list and then just have a search URL here for people to hunt them down like: https://groups.google.com/a/opencontainers.org/forum/#!searchin/dev/minutes

fair. I mean, the google docs folder is viewable to the world and can have
comments. I'm down for whatever, really. Convenience is nice. :-)
On Thu, Sep 3, 2015 at 4:41 PM, Brandon Philips<EMAIL_ADDRESS>wrote:

@vbatts https://github.com/vbatts maybe we can just agree on some
naming standard for posting to the mailing list and then just have a search
URL here for people to hunt them down like:
https://groups.google.com/a/opencontainers.org/forum/#!searchin/dev/minutes
—
Reply to this email directly or view it on GitHub
https://github.com/opencontainers/specs/pull/127#issuecomment-137568578.

Just did a bit of cleanup and layout. No magic. This is tedious.
https://github.com/opencontainers/specs/wiki
Thoughts?

@vbatts I mean honestly I would just say "search the mailing list" and leave it at that until someone complains. Seems like a lot of work for not much gain.

LGTM for now. Though the wiki ... meh.

The update doesn't contain 3 different update intentions, using 3 commit for it is bad.
The pr should be squashed into one commit.

@RobDolinMS squash your commits for merge

LGTM


Chrome Store beta version flagged as Malware

Vue devtools version
6.0.0 beta 21
Link to minimal reproduction
na
Steps to reproduce & screenshots
https://chrome.google.com/webstore/detail/vuejs-devtools/ljjemllljcmogpfapbkkighbhhppjdbg
What is expected?
Can install from chrome store
What is actually happening?
Chrome store page 404s, shows flagged as malware

System Info
NA

Any additional comments?
No response

I also got the same alert and have had to uninstall the extension.


Why use grid_cell_regularizer function over GridCellLoss class for grid cell regularization?

Hi,
I noticed that in the implementation, the grid_cell_regularizer function is used to compute the grid cell regularizer, but I was exploring using a GridCellLoss class instead. This class includes the weight function described in the paper and offers flexibility for modifications. I want to understand if there’s a specific reason for the choice of the clipping function over a class-based implementation with w(y) = max(y + 1, 24).
In the paper the significance of it is worded as:

The grid cell regularize ensures that the mean prediction remains close to the ground truth, and is averaged across all grid cells along the height 𝐻, width 𝑊, and lead-time 𝑁 axes. It is weighted towards higher rainfall targets using the function w(y) = max(y + 1, 24), which operate element-wise for input vectors, and is clipped at 24 for robustness to spuriously large values in the radar.

Here's the weight function implementation:
import torch

def weight_fn(y, precip_weight_cap=24.0):
    """
    Weight function for the grid cell loss.
    w(y) = max(y + 1, ceil)

    Args:
        y: Tensor of rainfall intensities.
        ceil: Custom ceiling for the weight function.

    Returns:
        Weights for each grid cell.
    """
    return torch.max(y + 1, torch.tensor(precip_weight_cap, device=y.device))

My adjusted implementation of the GridCellLoss class:
class GridCellLoss(nn.Module):
    """
    Grid Cell Regularizer loss from Skillful Nowcasting, see https://arxiv.org/pdf/2104.00954.pdf

    """

    # def __init__(self, weight_fn=None):
    #     super().__init__()
    #     self.weight_fn = weight_fn  # In Paper, weight_fn is max(y+1,24)

    def __init__(self, weight_fn=None, precip_weight_cap=24.0):
        """
        Initialize GridCellLoss.

        Args:
            weight_fn: A function to compute weights for the loss.
            ceil: Custom ceiling value for the weight function.
        """
        super().__init__()
        self.weight_fn = lambda y: weight_fn(y, precip_weight_cap) if weight_fn else None

    def forward(self, generated_images, targets):
        """
        Calculates the grid cell regularizer value, assumes generated images are the mean predictions from
        6 calls to the generater (Monte Carlo estimation of the expectations for the latent variable)

        Args:
            generated_images: Mean generated images from the generator
            targets: Ground truth future frames

        Returns:
            Grid Cell Regularizer term
        """
        difference = generated_images - targets
        if self.weight_fn is not None:
            weights = self.weight_fn(targets)
            difference = difference * weights
        difference = difference.norm(p=1)
        # difference = difference.mean()
        difference = difference / targets.size(1) * targets.size(3) * targets.size(4)  # 1/HWN
        return difference

Here's an example of how I integrated the class inside of training_step:
        # Compute Grid Cell Loss using GridCellLoss
        print("Computing Grid Cell Loss")
        gen_mean = torch.stack(predictions, dim=0).mean(dim=0)  # Mean over samples
        grid_cell_reg = self.grid_regularizer(gen_mean, future_images)
        # Original function commented out
        # grid_cell_reg = grid_cell_regularizer(torch.stack(predictions, dim=0), future_images)

For comparison, here’s the original grid_cell_regularizer function:
def grid_cell_regularizer(generated_samples, batch_targets):
    """Grid cell regularizer.

    Args:
      generated_samples: Tensor of size [n_samples, batch_size, 18, 256, 256, 1].
      batch_targets: Tensor of size [batch_size, 18, 256, 256, 1].

    Returns:
      loss: A tensor of shape [batch_size].
    """
    gen_mean = torch.mean(generated_samples, dim=0)
    weights = torch.clip(batch_targets, 0.0, 24.0)
    loss = torch.mean(torch.abs(gen_mean - batch_targets) * weights)
    return loss

@jacobbieker Hi! Please let me know what you think when you have a moment.

I can create a pull request that uses the formula from the paper.
If so, do you want the weight function (from above) to be inside of the losses.py or dgmr.py?
I can also make it be just w(y) = max(y + 1, 24) since my implementation is customizable.


[build] Add missing prim_xilinx_ultrascale to bazel deps

With the sandbox now enabled for fusesoc runs, the CW340 build was failing. It was missing the Ultrascale prim library in the bazel deps.

Merging. The kokoro failures appear to be service issues--There were partial results on the first run (no errors for those jobs that had results), and the second run gave no results at all.


Error converting valid curl command to py

curl -X POST "http://localhost:5000/forms/v1.0/dataset/1/score" -H  "accept: application/json" -H  "Content-Type: application/json-patch+json" -d "{  "modelId": 1}"

`import requests
headers = {
'accept': 'application/json',
'Content-Type': 'application/json-patch+json',
}
data = '{ modelId: 1}'
response = requests.post('http://localhost:5000/forms/v1.0/dataset/1/score', headers=headers, data=data)
`

I used this:  looks like you just need " " around the modelid.
curl -X POST "http://localhost:5000/forms/v1.0/dataset/1/score" -H
"accept: application/json" -H "Content-Type: application/json-patch+json"
-d "{ "modelId": 1}"
hearders = {
'accept': 'application/json',
'Content-Type': 'application/json-patch+json'
}
data = '{"modelId": "1"}'
model = requests.post('http://localhost:5000/forms/v1.0/dataset/1/score',
headers=headers, data=data).json()
*Fei Guo *
+1<PHONE_NUMBER>
http://about.me/rosefeiguo
On Fri, Apr 12, 2019 at 8:47 AM Katzen Katze<EMAIL_ADDRESS>wrote:

`import requests
headers = {
'accept': 'application/json',
'Content-Type': 'application/json-patch+json',
}
data = '{ modelId: 1}'
response = requests.post('http://localhost:5000/forms/v1.0/dataset/1/score',
headers=headers, data=data)
`
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/NickCarneiro/curlconverter/issues/126#issuecomment-482624608,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AKcYbvVF1UdTIpNAm-NswmADx5pQpOjgks5vgKqLgaJpZM4crJSj
.

It works as expected, I don't see any problem here.


Display problem in K0178.xml

code: kantrum<unclear>·</unclear><g type="circleMed">.</g> niya<choice><sic>n</sic><corr>m</corr></choice>a
display:

Can you sort this out @ajaniak ?

Dear @chloechollet,
I am not sure what you want me to sort. Is it the fact that the <g type="circleMed">.</g> is displayed as |?

Dear @chloechollet,
I am not sure what you want me to sort. Is it the fact that the <g type="circleMed">.</g> is displayed as |?

we are seeing not (·)| but (·| in the display on our side — generated with XLST in Oxygen.
[cid:6F1A560A-0F26-40C4-8BAA-0C94C87210C4@home]
display on your side is different!
Le 19 janv. 2021 à 16:12, ajaniak <notifications<EMAIL_ADDRESS>a écrit :
Dear @chloechollethttps://github.com/chloechollet,
I am not sure what you want me to sort. Is it the fact that the . is displayed as |?
[Capture d’écran 2021-01-19 à 16 10 40]https://user-images.githubusercontent.com/33328906/105053136-e9c87e80-5a70-11eb-93ff-360ec29ae1c3.png
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHubhttps://github.com/erc-dharma/tfc-khmer-epigraphy/issues/20#issuecomment-762905608, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AAGMAE5O7VHJRBITXL7H5KDS2WOPRANCNFSM4WI43Y7A.

we are seeing not (·)| but (·| in the display on our side — generated with XLST in Oxygen.
[cid:6F1A560A-0F26-40C4-8BAA-0C94C87210C4@home]
display on your side is different!
Le 19 janv. 2021 à 16:12, ajaniak <notifications<EMAIL_ADDRESS>a écrit :
Dear @chloechollethttps://github.com/chloechollet,
I am not sure what you want me to sort. Is it the fact that the . is displayed as |?
[Capture d’écran 2021-01-19 à 16 10 40]https://user-images.githubusercontent.com/33328906/105053136-e9c87e80-5a70-11eb-93ff-360ec29ae1c3.png
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHubhttps://github.com/erc-dharma/tfc-khmer-epigraphy/issues/20#issuecomment-762905608, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AAGMAE5O7VHJRBITXL7H5KDS2WOPRANCNFSM4WI43Y7A.

Do you have the last version of the XSLT on your computer?
My version of the output as well as the automated html are both with (·)|  and checking the codes history, this issue should have been resolved with the commit made the 4/11/2020.

Do you have the last version of the XSLT on your computer?
My version of the output as well as the automated html are both with (·)|  and checking the codes history, this issue should have been resolved with the commit made the 4/11/2020.

My bad. I’ve just done a git pull on project-documentation and the problem seems to have been resolved on the new html version.

My bad. I’ve just done a git pull on project-documentation and the problem seems to have been resolved on the new html version.


Fix the repository URL for the taskrun

${subject}

Duplicates https://github.com/redhat-scholars/tekton-tutorial/pull/52/files, closing


Create Mobile Nav 7

One need to make this component using HTML and Tailwind CSS. I would suggest to use Tailwind Playgrounds to make things faster and quicker.
Here is a reference to the component.

After building the component please raise a PR with a screenshot of the component and add the component in Navbar/nav-mobile/nav-7.html.
If you need to use any icon please use it from Hero Icons
Good luck.

I would like to work on this

@Rajdip019 please assign this to me

Sure. @Anuran12


Correct the document wrong about default rgw port number

The default port number of rgw has been changed after PR #201.

Thanks!


Project License

Dear Thomas,
Please add project license type(MIT, BSD, LGPL, GPL), thank for sharing...

@a4business when can you help?

@a4business when can you help?

License added

License added


examples/mailbox memory consumption

I have a question about memory consumption in Pony.
Launching examples/mailbox 20 1000000 on 2 cores machine consume >2GB memory.
Why so?
actor Mailer
  be ping(receiver: Main, pass: U32) =>
    for i in Range[U32](0, pass) do
      receiver.pong()                     /* Does this start work on another actor? */
    end

Shouldn't  receiver.pong() immediately start Main.pong() ? Or Mailer.ping collect all calls to another actors, and then fires?
 Is this because of message queue?
Because from my point of view, if you call pong, and someone consume that call, then queue shouldn't grow....

@tower120 - there was a recently fixed garbage collection / cycle detection issue that sounds related to this one.  It was fixed on master, but (as far as I know) hasn't been released yet.  If you're using the most recent stable release of ponyc, can you try building from latest source and see if the problem is reproducible on the master branch?

Just tried from git source - no, not fixed.
Maybe it should eat memory? Because if I reduce numbers - it seems ok.

A lot has changed with the garbage collector since this issue was opened. Is it still a problem?

$ ../build/release/ponyc -v
0.2.1-549-gab62f55
time ./mailbox1 20 1000000 finishes in 1s, and couldn't observe a spike.
However, ./mailbox1 20 100000000 triggers something.
It eats memory like crazy, up to 17G resident, >150G virtual and finishes in 1m51s.

Whatever is going on starts somewhere between 10000000 and 2000000.
I'm calling this a bug at this point.

Closing this.

mailbox is a stress test it should use lots of memory: note has been added re: this to the code.
there is however extra memory usage that is related to a different issue.

Thanks for bringing this up. It did help find a hidden issue.


How can I run this project?

The same error
https://github.com/javaterminal/TerminalFX/issues/34

Error occurred during initialization of boot layer java.lang.module.FindException: Module javafx.controls not found Command execution failed.

I am using netbeans IDE


baseline calculation in Camera.h assumes axis-aligned camera

Description:
The calculation of baseline in Camera.h assumes an axis-aligned stereo camera setup. Specifically, it assumes the two cameras are on the x-axis. Using the norm to calculate baseline will be better.
https://github.com/MIT-SPARK/Kimera-VIO/blob/42ad9ca557656ef3463b8cc3b841fe5a4a36398c/include/kimera-vio/frontend/Camera.h#L262

Checking the norm is not enough, but I'll add a warning if the baseline is not along x axis after rectification.


New branch request

Hello!
Can you create branch for 0.0.x versions? In our project we have rails 4.1 and so we can't use evil-client 2.0, that depends on rack 2.0.
But we need one more feature from sms aero api - HLR request. I've add this and want to open PR to your repo, but of course not to master.

Hi!
I've created this one. Please, let me now whether it is what you need.
And yes, feel free to open a PR )
(not sure, whether I could look it through before weekend, though)

Yes, it what I'm need :)
Opened a PR


Publish helm charts on ArtifactHub.io?

Can repo admins publish the helm charts for occm, cinder-csi and manila-csi to ArtifactHub.io too? For organizations that use Harbor as image and charts registry this would make it very easy to create replication rules.

/remove-lifecycle stale


Remote URL usage

Hi.
It appears instructions to use markdown differ from README and Website:

<markdown [path]="/path/to/code.cpp"></markdown>
<markdown [path]="/path/to/code.java"></markdown>

versus
<markdown [path]="'/assets/files/demo.md'"> </markdown>

Either way my files are parsed but dont show translation from markdown language to HTML (i.e. # to
). I followed tutorial at https://github.com/dimpu/angular2-markdown/blob/master/docs/getting-started/ng-cli.md carefully and there are no errors. Someone got a clue what am i missing?
Cheers,
midzer

Could you create a plunkr

Thanks for your answer, @dimpu.
In my minimal example <markdown [path]="'assets/markdown/index.md'"></markdown> loads file without error but formatting is not applied.
On the contrary

 gives following error message in chromium console:

Unhandled Promise rejection: Template parse errors:
Parser Error: Unexpected token 'Lexer Error: Unterminated quote at column 25 in expression [assets/markdown/index.md']' at column 26 in [assets/markdown/index.md'] in ng:///AppModule/ScreenComponent.html@6:16 ("

It's clearly syntax error
it should be

Yes, you're right. Now Markdown -> HTML conversion is functional, too. I copied content from a wiki and thought it is proper markdown.
Thanks for helping out, @dimpu.


Support for box transients?

For instance, when modifying a struct wrapped with immer::box, it may be simpler to obtain a mutable instance of the struct rather than wrapping all mutations inside an immer::box::update. Is this possible to do without sacrificing performance?

Since there is only one element in the box, it does not really make sense to provide a transient type for it. However, it could make sense, in the case where one is using reference counting, to overload .get() such that the value is moved out of the box when the refcount is 1. You could then do:
// given a `box<T> x`
auto v = std::move(x).get()
v.foo = ...;
v.bar = ...;
x = std::move(v);

Would that satisfy your use-case?

I think that makes sense. I'd just like to leverage copy-on-write, but I don't care about the contents of the box once I start modifying them, so a "copy and overwrite" strategy works here.
I assume that this usage is as efficient as the following?
x = x.update([&](auto v) {
  v.foo = ...;
  v.bar = ...;

  return v;
});

it should be as efficient as this (note the std::move):
x = std::move(x).update([&](auto v) {
  v.foo = ...;
  v.bar = ...;

  return v;
});

[Note that this optimization is not done yet, so this might also involve a superfluous copy. It is easy to do though... I might do it over the weekend if I remember.]

I'd just like to leverage copy-on-write, but I don't care about the contents of the box once I start modifying them, so a "copy and overwrite" strategy works here.

Yese, these two proposed syntaxes leverage copy-on-write and would avoid a copy of the contents when the box is unique. Did you have some other syntax or API in mind?

No, I think the API you've proposed makes sense. Thanks :)

Since there is only one element in the box, it does not really make sense to provide a transient type for it. However, it could make sense, in the case where one is using reference counting, to overload .get() such that the value is moved out of the box when the refcount is 1. You could then do:
// given a `box<T> x`
auto v = std::move(x).get()
v.foo = ...;
v.bar = ...;
x = std::move(v);

Would that satisfy your use-case?

I would very much like this. It allows you to do something like returning something else while modifying the boxed value more conveniently.
std::optional<R> res;
x = std::move(x).update([&](auto v) {
    res = func(v);
    return v;
});
return res.value();

could be rewritten as:
auto v = std::move(x).get();
auto res = func(v);
x = std::move(v);
return res;

See also https://lily-is.land/kazv/libkazv/-/merge_requests/61/diffs#b21da8173c8b3638b5e9e2cbd8c4044182270781_112_121

Happy to accept a PR for this one!


DrawIO and Log4j Vulnerability (CVE-2021-44228)

Not really a bug, but might be good to investigate.
Was curious about how much DrawIO is susceptible for the Log4j Vulnerability, where this module is used in the Java code.
Thanks!
PS;  want to say that we are very happy with this project, really nice project! 👏

None of our deployments are vulnerable is the conclusion of our analysis.
The only place log4j is a dependency is in the Confluence and Jira on-prem integrations. There we use the provided 1.2.16 version. Yes, if you have JMS enabled that can cause a problem, but we went through all of the log calls that we make to ensure there were no cases where anything could be injected and deserialised or forced to contain the JNDI string required for the attack. There were no such cases.


PD Advanced Step Settings: Flow Rate

As a protocol designer,  I would like to control the aspirate and dispense speed, so that I can fine-tune pipetting for various liquids.
Acceptance criteria

User able to open 'pipetting speed' modal from step editor advanced settings
Pipetting speed has a default, min, and max
Pipetting speed is specific to aspirate vs. dispense

Implementation Notes

Note we need to persist pipette min, max and default speeds somewhere
-- These are currently stored in pipette mem, but we believe we need a source of truth outside the robot (much like we use shared data for labware)
-- PD will read from this source of truth and ship protocols with pipette speeds
--- This implies that new and improved defaults will not be automatically applied (users who did not change speed from the default will be left with whatever was the default when they created their protocol)

Design
https://zpl.io/agNNKYN
Pipette defaults from Laura
{
"p10_single_v1": {
"displayName": "P10 Single-Channel",
"nominalMaxVolumeUl": 10,
"plungerPositions": {
"top": 18,
"bottom": 3,
"blowOut": 1,
"dropTip": -5
},
"pickUpCurrent": 0.1,
"aspirateFlowRate": 5,
"dispenseFlowRate": 10,
"ulPerMm": 0.617,
"channels": 1,
"modelOffset": [0.0, 0.0, -13],
"tipLength": 40
},
"p10_multi_v1": {
"displayName": "P10 8-Channel",
"nominalMaxVolumeUl": 10,
"plungerPositions": {
"top": 18,
"bottom": 3,
"blowOut": 1,
"dropTip": -5
},
"pickUpCurrent": 0.2,
"aspirateFlowRate": 5,
"dispenseFlowRate": 10,
"ulPerMm": 0.617,
"channels": 8,
"modelOffset": [0.0, 28.0, -25.8],
"tipLength": 40
},
"p50_single_v1": {
"displayName": "P50 Single-Channel",
"nominalMaxVolumeUl": 50,
"plungerPositions": {
"top": 18,
"bottom": 4,
"blowOut": 2,
"dropTip": -2.5
},
"pickUpCurrent": 0.1,
"aspirateFlowRate": 25,
"dispenseFlowRate": 50,
"ulPerMm": 3.08,
"channels": 1,
"modelOffset": [0.0, 0.0, 0.0],
"tipLength": 60
},
"p50_multi_v1": {
"displayName": "P50 8-Channel",
"nominalMaxVolumeUl": 50,
"plungerPositions": {
"top": 18,
"bottom": 4,
"blowOut": 2,
"dropTip": -4
},
"pickUpCurrent": 0.3,
"aspirateFlowRate": 25,
"dispenseFlowRate": 50,
"ulPerMm": 3.08,
"channels": 8,
"modelOffset": [0.0, 28.0, -25.8],
"tipLength": 60
},
"p300_single_v1": {
"displayName": "P300 Single-Channel",
"nominalMaxVolumeUl": 300,
"plungerPositions": {
"top": 18,
"bottom": 3,
"blowOut": 1,
"dropTip": -2.5
},
"pickUpCurrent": 0.1,
"aspirateFlowRate": 150,
"dispenseFlowRate": 300,
"ulPerMm": 18.51,
"channels": 1,
"modelOffset": [0.0, 0.0, 0.0],
"tipLength": 60
},
"p300_multi_v1": {
"displayName": "P300 8-Channel",
"nominalMaxVolumeUl": 300,
"plungerPositions": {
"top": 18,
"bottom": 3,
"blowOut": 1,
"dropTip": -4
},
"pickUpCurrent": 0.3,
"aspirateFlowRate": 150,
"dispenseFlowRate": 300,
"ulPerMm": 18.51,
"channels": 8,
"modelOffset": [0.0, 28.0, -25.8],
"tipLength": 60
},
"p1000_single_v1": {
"displayName": "P1000 Single-channel",
"nominalMaxVolumeUl": 1000,
"plungerPositions": {
"top": 18,
"bottom": 3,
"blowOut": 1,
"dropTip": -2.5
},
"pickUpCurrent": 0.1,
"aspirateFlowRate": 500,
"dispenseFlowRate": 1000,
"ulPerMm": 61.69,
"channels": 1,
"modelOffset": [0.0, 0.0, 20.0],
"tipLength": 60
}
}
Background

This design will evolve as we include defaults for liquid classes
-Decided against slider because it's hard to make meaningful in this use case.

Min and max recommended flow rates will not go into the protocol. Flow rate protocol default and per-step asp/disp flow rates will!

Closed by #2123


Missing gcc prevents some package installs through requirements.txt

#174 is kind of annoying since it prevents us from installing packages like pymssql, hvac and anything that requires gcc build tools to install.
Can we have it back?   :)

Missing gcc is bad. PIP requires it to build some packages like ujson.
@puckel can we revert #174 ?


Allow ongoing checks

Main change
add allow_ongoing_checks option to update PRs that have ongoing checks when the action is triggered.  close #33
Setting require_passed_checks to true alone may prevent updates to PRs with ongoing checks. It is advisable to set both require_passed_checks and allow_ongoing_checks to true.

Pull Request Test Coverage Report for Build<PHONE_NUMBER>0
Details

13 of 13 (100.0%)  changed or added relevant lines in 1 file are covered.
No unchanged relevant lines lost coverage.
Overall coverage decreased (-0.7%) to 99.315%

Totals

Change from base Build<PHONE_NUMBER>:
-0.7%

Covered Lines:
104

Relevant Lines:
104

💛  - Coveralls


Write navigator

Write a functioning navigator which mirrors zooming and drag movement on an image.

PR Overview

This PR adds a Navigator component to the Classifier page.
The Navigator component is a miniature "preview" of the Subject image, and mirrors what the Subject Viewer component shows.
The full feature/functionality list of the Navigator component is as follows:

It shows the same Subject image as the Subject Viewer (but way tinier)
It shows the "viewport" / "viewing window" of the Subject Viewer as a red rectangle; i.e. when a user is zoomed in on the Subject Viewer, the Navigator gives a general context of which part of the Subject image the user is looking at.
By clicking on a specific part of the Subject image on the Navigator, the Subject Viewer should 'jump' its view to that position. NOT in this PR - this is an intended future feature.

The Navigator component is to the top-right of the Classifier page. Not how the position and size of red rectangle matches what's being shown on the primary Subject Viewer.

PR Review

Currently, there is an issue with matching the position of the red rectangle in the Navigator with the actual view of the Subject Viewer, but only at really really high zoom levels.
This is very likely just an issue with the mathematics, e.g. the order of translation first or scaling first. I'll try to take a look into this today, but if not, I'm quite happy to pass this first and then open a separate issue to fix the high-zoom-synchronisation issue.

Note that the Subject Viewer shows the left-most edge of the Subject image, but the Navigator's red rectangle goes beyond the left-most edge. This indicate an excessively large translation() along the x-axis (and a minor drift along the y-axis).

Let's open an issue about this since we have the basis of the navigator down, then we can tweak the navigator in a future PR.


Windows Support

This PR will add basic Windows support for Macchina.

Work in progress, do not merge yet.

neofetch on Windows has some serious performance issues lol. Running it outside the benchmark confirms the slowness.

Stuck at uni right now, I'll try and debug with you as soon as I get home :smile:

This ended up being merged when accepting the macos support PR. Oops!

This ended up being merged when accepting the macos support PR, because windows branch was merged to macos branch.

Yea, I accidentally pulled the changes into my macos branch today, but it’s not a big deal.

Alrighty then, before I forget, I'd like for you to add macOS benchmarks in the "Benchmarks" section of both README files.


Add a test invalid entry for a repeated word at the end of a sentence.

Fixes #321

Why should we accept repetition in general?

I don't think the RedHat style should accept repetition. I think it should catch it as an error, or at least as a warning. This update is intended to fix the false negative that @alexpdp7 discovered and raised in https://github.com/redhat-documentation/vale-at-red-hat/issues/321

I'd appreciate your reviews, @alexpdp7, @rohennes, and @themr0c. Thanks!


Adds parquet and discards protobuf generated classes (#193)

@Avasil using your advice to correct parquet api docs :)
The old filter has been removed since it was copied from monix and not needed here.

Nice!
It shouldn't cause anything wrong because generated classes probably do not belong in API docs


CSS is loaded every time when CKEditor is created

Every time when I load ckeditor in my application, contents.css is downloaded. For example, I have 100 comments, that I want to display in CKEditor (one by one), then contents.css will be downloaded 100 times. Can we stop this?

<div *ngFor="let comment of comments">
<ckeditor class="editor-suggestion"
        [(ngModel)]="comment.text"
	[config]="Helpers.getCkEditorConfig()"
	(change)="onTextChange($event)"
	debounce="500">
</div>

Any update on this question?

It's the default behavior of CKEditor, see this : http://jsfiddle.net/xykk4nss/


screen

hello
i don't have a e-paper "screen" but i have a 7 inch raspberry pi touchscreen. Is there any way i can use that to see iss position?

You most certainly can! But that would mean rewriting the iss.py to create a GUI that you can display on your touch screen or TV, instead of the ePaper. There are many packages and options for you to choose from. Raspberry Pi Projects page has a tutorial that uses guizero Python package - this would be a good place to get started.
https://projects.raspberrypi.org/en/projects/getting-started-with-guis
Cheers,
Sridhar
PS - I'm going to close this issue, but feel free to open another one for other questions you may have!


Fitbit Component not working with Multiple trackers.

Home Assistant release (hass --version):
0.62
Component/platform:
Fitbit
Description of problem:
Looks like Fitbit is hardcoded to write it's configuration to fitbit.conf.  Multiple trackers break this.  Need to have an option for multiple conf files like light.
Expected:
have multiple fitbits and different configuration files.
Additional info:
https://community.home-assistant.io/t/fitbit-more-than-one-tracker/9666

Hey @robbiet480, Do I have to buy you a second Fitbit tracker? :)

@CCOSTAN - I've submitted a PR on your personal repo - have a look and let me know - if it works everyone else can test - cheers.

I have this on my plate to extend this sensor too.

@tchellomello - This is the PR @mf-social referred to..
https://github.com/CCOSTAN/Home-AssistantConfig/pull/328
Maybe it can help with the development.
I'm available to test anything if that helps as well.

@CCOSTAN @mf-social it seems you guys already figured it out. Is there any reason why this PR has not yet been sent to the official repo?

@tchellomello - Not fully working.
https://github.com/CCOSTAN/Home-AssistantConfig/issues/329 - Testing notes.

@CCOSTAN  gotcha I'll take a look

Still hoping for multiple user support on this.

Closing since not every component/platform supports multiple instances, so this is more of a feature request than a bug. Please post a thread in the feature requests section of the community forums.


Base64 encoding should not have linefeed characters

I was trying to use the #b64_data method to encode an image into base64 for insertion directly into an HTML IMG element attribute. I noticed it was failing because the data contains linefeed ("\n") characters to wrap the text.
I think the fix is to modify the Content#b64_data method to use Base64.strict_encode64 as the Ruby docs say that doesn't add linefeeds. I hope to submit a PR for this but wanted to create an issue in case others have the same problem.

Which browser are you using out of interest? I tested in Safari and Chrome (but not IE) and they seemed to work ok for me with "\n" characters

Ah sorry, I oversimplified! I'm actually passing the data to Javascript code (Polymer's iron-image web component to be exact). It doesn't display and it also confuses the Chrome Development Console, which identifies it as B64 encoded image but gives up after the newline. I imagine browser attribute parsing is more tolerant to this.
I also checked the data URL scheme RFC, which is silent on the issue (not really in the remit), however the (Base-N encodings RFC)[https://www.ietf.org/rfc/rfc4648.txt] specifically prohibits the insertion of newlines in this context:

Implementations MUST NOT add line feeds to base-encoded data unless
the specification referring to this document explicitly directs base
encoders to add line feeds after a specific number of characters.

That section in the standard basically appears to be a complaint about MIME-style encoding being overly prevalent. As evidenced by Ruby's own Base64 encoding being wrong by default!

Ok - it seems almost as though it isn't well specified whether newlines are ok are not (the statement from RFC 4648 seems to me to delegate responsibility to the "other" spec referring to it), but taking them out with strict encode can't hurt.

so it definitely works with Polymer with strict encode?
out of interest how does it confuse the Chrome Dev console? (seemed fine when I tested)

Sorry for taking so long to get back to you.
So I think Polymer's iron-image component breaks because it sets the image by doing el.style.backgroundImage = "url('" + src + "')". Which fails when the base64 has newlines. So yes it does work with strict base64.
The error I referred to in Chrome also appears to be due to URL detection and how the dev console handles strings. Creating a new image element and assigning it to src normalises the string for example, so reading it back out means the Console's URL detection works. This is a very minor problem.


[DRAFT] UniFFI exploration

Exploring what it'd look like if we used uniffi to generate our FFI bindings. Some challenges getting things set up with macro errors, but this is building and generating. Another challenge is to continue supporting C ABI/FFI as a baseline, and a separate object-oriented interface for dynamic languages via uniffi. We could approach this continuing our current pattern of FFI C functions interfacing with a uniffi-object (e.g. NsNoosphere), though this is just a very different way of designing APIs compared to e.g. ns_error_code_get
Scaffolding

All types used in the interface (and scaffolding macro) must be placed in src/lib.rs
Even with build.rs pointing to udl file at src/ffi/noosphere.udl, bindgen still looks for udl at src/noosphere.udl.
Ran into error during bindgen: "cargo metadata returned 0 packages" -- needed to change rlib crate type to lib https://github.com/mozilla/uniffi-rs/issues/1563

Bindgen

In lieu of using nightly, we have a bin to create bindings.

cargo run --features=uniffi/cli --bin uniffi-bindgen generate --library ./target/debug/libnoosphere.so --language swift --out-dir ./target/ffi
--library mode requires running in workspace root

Generated examples:
Generates a noosphere.h (for uniffi internals, unrelated to our safer ffi bindings), swift bindings (and .modulemap) and kotlin:
Kotlin
class NsNoosphere(
    pointer: Pointer
) : FFIObject(pointer), NsNoosphereInterface {
    constructor(`globalStoragePath`: String, `sphereStoragePath`: String, `gatewayApi`: Url?) :
        this(
    rustCallWithError(NoosphereException) { _status ->
    _UniFFILib.INSTANCE.uniffi_noosphere_fn_constructor_nsnoosphere_new(FfiConverterString.lower(`globalStoragePath`),FfiConverterString.lower(`sphereStoragePath`),FfiConverterOptionalTypeUrl.lower(`gatewayApi`),_status)
})

    /**
     * Disconnect the object from the underlying Rust object.
     *
     * It can be called more than once, but once called, interacting with the object
     * causes an `IllegalStateException`.
     *
     * Clients **must** call this method once done with the object, or cause a memory leak.
     */
    override protected fun freeRustArcPtr() {
        rustCall() { status ->
            _UniFFILib.INSTANCE.uniffi_noosphere_fn_free_nsnoosphere(this.pointer, status)
        }
    }
}

Swift
public class NsNoosphere: NsNoosphereProtocol {
    fileprivate let pointer: UnsafeMutableRawPointer

    // TODO: We'd like this to be `private` but for Swifty reasons,
    // we can't implement `FfiConverter` without making this `required` and we can't
    // make it `required` without making it `public`.
    required init(unsafeFromRawPointer pointer: UnsafeMutableRawPointer) {
        self.pointer = pointer
    }
    public convenience init(`globalStoragePath`: String, `sphereStoragePath`: String, `gatewayApi`: Url?) throws {
        self.init(unsafeFromRawPointer: try rustCallWithError(FfiConverterTypeNoosphereError.lift) {
    uniffi_noosphere_fn_constructor_nsnoosphere_new(
        FfiConverterString.lower(`globalStoragePath`),
        FfiConverterString.lower(`sphereStoragePath`),
        FfiConverterOptionTypeUrl.lower(`gatewayApi`),$0)
})
    }

    deinit {
        try! rustCall { uniffi_noosphere_fn_free_nsnoosphere(pointer, $0) }
    }
}

uniffi generated bindings for JS in firefox


Cosmos DB - database and collection resources

Currently, Pulumi only supports creating Cosmos DB accounts - not databases or collections.
Terraform just merged this support, so I'm creating this issue to make sure we transfer this capability to Pulumi.
In addition, we need to add/update an example and enable serverless trigger on the collection resource level.

Ok, the databases are supported now, but not SQL Collections yet.

@mikhailshilkov can you give me a quick TL;DR of what is still required for this issue? Is this a limitation upstream?

Yes, they added a database and some collection types, but not the "SQL Collection" - a native Cosmos DB collection, see https://github.com/terraform-providers/terraform-provider-azurerm/issues/3506

Yes, they added a database and some collection types, but not the "SQL Collection" - a native Cosmos DB collection, see https://github.com/terraform-providers/terraform-provider-azurerm/issues/3506

@mikhailshilkov, as this is a missing resource upstream, I am going to close this out. When the work to add support for SQL Collections is added, we will get a warning in the code generation that we need to add it
I am going to link https://github.com/terraform-providers/terraform-provider-azurerm/issues/3506 as the correct place for the questions on this


Missing CSS file in npm package

Current release (2.2.2) does not include the src/xterm.css file.

I am happy to submit a PR with a script that copies the file over before publishing:  cf https://github.com/jupyterlab/jupyterlab/blob/bda6c803494a0e6ddf5df673749be5a9590bf719/scripts/copyfiles.js

The copy is meant to be done here https://github.com/sourcelair/xterm.js/blob/master/bin/build#L29, maybe it's not being published due to files in package.json?

It must only include JS files by default: https://github.com/jupyterlab/jupyterlab/blob/bda6c803494a0e6ddf5df673749be5a9590bf719/package.json#L97

On it.

@Tyriar and @blink1073 feel free to take a look at #416. I will merge ASAP.

Should be fine with 2.2.3

The copy script still didn't do the trick, because the release has the CSS in the src/ folder but not the lib/ folder.