Uncaught TypeError: Cannot use 'in' operator to search for 'Dropdown' in null

I get the below error.
Uncaught TypeError: Cannot use 'in' operator to search for 'Dropdown' in null on bootstrap-native.min.js:2
I'm using AngularJS to conditionally render the dropdown html and associated button. After opening the "More..." dropdown, I'm hitting on the "Edit" button (which changes the route and hides the button grouping
...
).
https://i.imgur.com/klPIOqZ.png
After the edit button, the dropdown goes away (which  is good), but I get the following error:
https://i.imgur.com/AkSNDH1.png
Which takes me to this line when I click on it:
https://i.imgur.com/YfdlSTS.png
I'm simply reporting this to get this fixed on the repo. I already have a solution to this. Unfortunately, I'm unable to easily replicate this bug on jsFiddle without using AngularJS, which is what I suspect is causing this, because my example without AngularJS on jsFiddle works fine.
I was able to fix this by updating this code:
("Dropdown"in i||"Dropdown"in i[d]) into ("Dropdown"in i||i[d] && "Dropdown"in i[d])
Note that I'm  adding i[d] && which is simply checking that i[d] exists before evaluating "Dropdown"in i[d]. Thanks for reading and your time.

BSN version?

Whoops. It's v2.0.26.

We need to know how you invoke the component, perhaps you expect it to do something it was never meant to do.

For me this happened, when I called the constructor manually without there being an element.
// i.e.
var bsn = require("bootstrap.native");
var btn = new bsn.Dropdown('.dropdown');
// throws error, if no element with '.dropdown' is found

This might happen in frontend frameworks when the above code is registered globally but the '.dropdown' element is only later added when a specific template renders.
@ezerr correct me, if it is different for you.
so it's basically a result of not initialising bootstrap.native correctly, not a problem of the library. But it might be alleviated with a fix for #102

For me this happened, when I called the constructor manually without there being an element.
Why attempting such a thing?

It was not on purpose. The frameworks async init process just was not yet finished, when the bootstrap code was called.

https://github.com/thednp/bootstrap.native/wiki/FAQs


Install nasm for windows workflow builds

What does this Pull Request accomplish?
Install nasm for windows workflow builds.
Why should this Pull Request be merged?
Installing nasm is part of the Windows build setup steps for grpc. However, there's a special case for the Visual Studio generator that will disable asm in boringssl when nasm is unavailable. This puts us on an obscure Windows-specific suboptimal codepath that we can fix by installing nasm.
What testing has been done?
Ran workflow in my fork with an extra cmake check to ensure that ASM_NASM is available. Ensured that it failed without this change and passed with it.

Thanks @smooresni for pointing this out!


On mobile unable to scroll when touch event starts from over the video

I can't scroll my page when I start scrolling from the ad playing on my video. It seems it is due to preventDefault on touchstart and touchend event. I get the following warning when trying to scroll:

Unable to preventDefault inside passive event listener due to target being treated as passive. See https://www.chromestatus.com/features/5093566007214080.

I know I could add an overlay, but I'll prefer no too.

I believe this is an issue with the IMA SDK, not just this plugin, but will have to investigate further. Thanks for the report!

Unable to scroll seems odd due to this intervention. Is there a URI that reproduces this? (I'm not familiar with videojs-ima at all but am looking at it from Chrome's touch handling perspective as I'm a chromium author)

You can repro with vanilla IMA SDK (no video.js pluign) here: http://googleads.github.io/googleads-ima-html5. If you zoom in a bit you can scroll vertically - it works when you tap outside the ad, but not when you start your tap inside the ad.

Testing with 1.0, this appears to be resolved. If you're still seeing the issue with the updated plugin let me know.


Mix indexed and non-indexed properties

How can I specify that I accept any object, whose property values are T?
Here is my experience so far (Playground):
function foo(param: {[k: string]: number}) {
}

// This is not an error, correct:
foo({ a: 2 })

// This should not be an error either, but it is:
foo({ a: 2 } as { a: number })

// In real life code there is no explicit cast, but an interface:
interface MyFoo {
  a: number
}
foo(getMyFoo())

if you are casting, you are not using the contextual type from the function declaration, and thus did not inherit the index signature so you will need to explicitly add it:
foo({ a: 2 } as { a: number; [k:string]:number })

in the case of your interface, add the constraint on it to ensure the two are compatible:
interface MyFoo {
  a: number;
  [k:string]: number;
}


Example images broken

Hello, the example image links in the README.md are no longer valid.

Curious, I'll change it, thank you!

Changed!

Push on typst universe


Made env variables easily extendable and added debugging mode

Added debugging mode, enable with "--debug" parameter
Added manual name parameter, in case our script can't pick it up automatically from the API for games. use "-n" (or "--name") to set it manually.
Made environment variables in a list instead of separate, numbered variables.
Improved logging and added more debugging logs.
Refactored some parts of the code, converting the configuration to a dictionary instead of using global variables all around.

Minor note, all variables were converted to English instead of spanish :)


FBX Importer: Support Limb class tag

ref #47184

I need an example file with the "Limb" data in it, to test this, and make sure the relationships are correct.
I will convert it to ASCII to be sure this is the correct fix, the data could be unrelated in some ways, or it could be legacy exporters dumping old formats of the file which in that case this fix is correct but right now we don't know for certain.
So let's put a test plan together for any changes for the FBX Importer in future because we merge something it could knock 10 other files out.

I need an example file with the "Limb" data in it, to test this, and to make sure the relationships are correct.

Example provided by author of #47184.

So let's put a test plan together for any changes for the FBX Importer in future because we merge something it could knock 10 other files out.

A form of test suit would certainly be helpful.

I need an example file with the "Limb" data in it, to test this, and to make sure the relationships are correct.

Example provided by author of #47184.

So let's put a test plan together for any changes for the FBX Importer in future because we merge something it could knock 10 other files out.

A form of test suit would certainly be helpful.

Cool I will gist/pastebin the file he posted and grab a file without it, so we can compare, see if it's a version thing. I think maybe at some point would be good to write some script to convert them to debug things without having to grab Maya.
I'd honestly like to rewrite a lot of the FBX Parser soon, there are so many problems we inherited with the poor memory management which has also been a burden, I think next week this can be started too.

Doesn't Assimp provide such functionality out of the box. I seem to recall it ships with a command-line utility and a viewer.

Doesn't Assimp provide such functionality out of the box? I seem to recall it ships with a command-line utility and a viewer.

its not really giving you a JSON dump of an fbx it's a dump of what it believes is in the fbx so it means a parser bug will drop data or crash and still give you nothing, with maya you can just dump the content of the fbx to ascii to make this 10x easier basically

Following a stackoverflow post, I found this, which seems helpful: https://help.autodesk.com/view/FBX/2020/ENU/?guid=FBX_Developer_Help_cpp_ref_import_scene_2main_8cxx_example_html.

Superseded by #59691 and #59653.


Is there a way to parse table_factor only?

I want to parse some table_factor with args like
"Table(3)"

but without parsing full sentense (SELECT * FROM Table(3))
I found there is fn parse_table_factor but it seem like it can not be used stand-alone

@devgony
    #[test]
    fn parse_table_factor() {
        let dialect = GenericDialect {};
        let mut parser = Parser::new(
            Tokenizer::new(&dialect, "Table(3)").tokenize().unwrap(),
            &dialect,
        );

        let table_factor = parser.parse_table_factor().unwrap();
        println!("{:#?}", table_factor)
    }

This prints:
TableFunction {
    expr: Value(
        Number(
            "3",
            false,
        ),
    ),
    alias: None,
}

I'm pretty sure you can do it externally from the crate, as everything I used is public.

@devgony, can you please close this issue? I think it is solved, right...?


noise: implement 2d perlin noise (#42)

saw there was an open issue, here you go

i will do so tomorrow


Custom fields

Description
Added a customSocials field which allows users to create their own fields with their parameters including icons, name and url
Resolves #16
Basic Checklist

[x] ✨ Ran dartdoc
[x] 🛠 Added proper documentation
[x] ❌ No warnings or errors in the code
[x] ✅ If added a new parameter, added in Readme and example too

Type of Change

[x] ✨ New feature (non-breaking change which adds functionality)
[ ] 🛠 Bug fix (non-breaking change which fixes an issue)
[ ] ❌ Breaking change (fix or feature that would cause existing functionality to change)
[ ] 🧹 Code refactor
[ ] ✅ Build configuration change
[ ] 📝 Documentation
[ ] 🗑 Chore

In the example I have added my socials since I didn't have a good example, you might want to change that so I haven't updated the screenshot yet on README

Also, looks like your repository has been marked as excluded, you might want to enquire about that


Using Minio with fog

We should test & write a cookbook on using fog with Minio.
http://fog.io/

can be closed via https://github.com/minio/cookbook/pull/120


[sozo] add trace logs

Added trace logs for Sozo.
Closes #1409
Closes DOJ-160

@lambda-0x Thank you for your suggestions.

I've take Katana logging as reference, if LOG_TARGET in Katana if for any specific reason then I'll remove it from Sozo.
If  we print signer and world_address on single line, there'll be no trace message for that log, as it doesn't make sense to copy same message. If that's fine I can do that as well.

Are any changes required or can we merge this one?

@btirth can you please take a look at CI failures, try running the command they run locally.

@lambda-0x: I've fixed CI failures.


routerWillLeave is not confirmable

this is my component
import React from 'react';

import {Link, Lifecycle } from 'react-router';

const secret = 'supersecretpassword';

const Admin = React.createClass({
	mixins: [ Lifecycle ],
	getInitialState: function() {
		return {
			password: ''
		};
	},

	routerWillLeave(nextLocation) {
		if (nextLocation.pathname === '/wifi' && this.state.password !== secret ) {
			return false;
		}
	},

	render() {
		return (
			<div className="container adminContainer">
				<Link className="confirmButton" to="/wifi"/>
			</div>
		);
	}
});

export default Admin;

if I try to open /wifi with the wrong state I'm correctly blocked otherwise I can see the location update in the browser but not the view.
if I remove the mixin i can navigate but obviously i have no pass check
Am I doing something wrong ?

Routing table
export default (
	<Route path="/" component={App} >
		<IndexRoute component={Home}/>
		<Route path="pin" component={Pin}/>
		<Route path="print" component={Print}/>
		<Route path="admin" component={Admin}/>
		<Route path="wifi" component={Wifi}/>
	</Route>
);

I am experiencing the same situation.

mind sending PR with minimal failing test?

You should be using the onEnter hook for auth. routerWillLeave is for preventing navigation away from a page. onEnter can prevent unauthorized navigation to a page.

Update to master resolved it.

Ignoring the security issue in the OPs question, I am also unable to navigate to a new page if routerWillLeave method exits in a component. Even a blank method blocks navigation. Returning true has no effect. On 1.0.0-rc1. What should the routerWillLeave function return to allow moving along?


IndexError when printing dataset from an Argo file

Working with a netcdf Argo data file, I encountered the following error:
# Sample data file here: https://storage.googleapis.com/myargo/sample/4902076_prof.nc
argofile = '4902076_prof.nc'
ds = xr.open_dataset(argofile)
print ds

[...full trace below...]
Out[]:
IndexError: The indexing operation you are attempting to perform is not valid on netCDF4.Variable object. Try loading your data into memory first by calling .load().
Original traceback:
Traceback (most recent call last):
  File "/Users/gmaze/anaconda/envs/obidam/lib/python2.7/site-packages/xarray/backends/netCDF4_.py", line 62, in __getitem__
    data = getitem(self.get_array(), key)
  File "netCDF4/_netCDF4.pyx", line 3961, in netCDF4._netCDF4.Variable.__getitem__
  File "netCDF4/_netCDF4.pyx", line 4796, in netCDF4._netCDF4.Variable._get
IndexError

The error remains the same even if I try to load the data as suggested in the error message.
However, I can keep working with the dataset and access variable.
This only affects the printing of the ds object.
I can't get to determine where in my package updating workflow this really pop out. It used to work very fined up to xarray version 0.9.5. Here I'm using 0.10.0rc1 (see full version details below).
It is worth noting that using the 'scipy' engine solves the issue !
ds = xr.open_dataset(argofile, engine='scipy')
print ds
Out[48]:
<xarray.Dataset>
Dimensions:                       (N_CALIB: 1, N_HISTORY: 0, N_LEVELS: 1007, N_PARAM: 3, N_PROF: 33)
Dimensions without coordinates: N_CALIB, N_HISTORY, N_LEVELS, N_PARAM, N_PROF
Data variables:
    PROFILE_PRES_QC               (N_PROF) object ...
    DATA_TYPE                     object ...
    JULD                          (N_PROF) datetime64[ns] .
[...]

I suspect a compatibility issue somewhere with netCDF4
Any ideas ?
thanks
Exact trace:
print ds
Traceback (most recent call last):
  File "/Users/gmaze/anaconda/envs/obidam/lib/python2.7/site-packages/IPython/core/interactiveshell.py", line 2881, in run_code
    exec(code_obj, self.user_global_ns, self.user_ns)
  File "<ipython-input-31-63698f3c943a>", line 1, in <module>
    print ds
  File "/Users/gmaze/anaconda/envs/obidam/lib/python2.7/site-packages/xarray/core/formatting.py", line 64, in __repr__
    return ensure_valid_repr(self.__unicode__())
  File "/Users/gmaze/anaconda/envs/obidam/lib/python2.7/site-packages/xarray/core/dataset.py", line 1050, in __unicode__
    return formatting.dataset_repr(self)
  File "/Users/gmaze/anaconda/envs/obidam/lib/python2.7/site-packages/xarray/core/formatting.py", line 426, in dataset_repr
    summary.append(data_vars_repr(ds.data_vars, col_width=col_width))
  File "/Users/gmaze/anaconda/envs/obidam/lib/python2.7/site-packages/xarray/core/formatting.py", line 297, in _mapping_repr
    summary += [summarizer(k, v, col_width) for k, v in mapping.items()]
  File "/Users/gmaze/anaconda/envs/obidam/lib/python2.7/site-packages/xarray/core/formatting.py", line 236, in summarize_datavar
    return summarize_variable(name, var.variable, col_width, show_values)
  File "/Users/gmaze/anaconda/envs/obidam/lib/python2.7/site-packages/xarray/core/formatting.py", line 212, in summarize_variable
    elif isinstance(var.data, dask_array_type):
  File "/Users/gmaze/anaconda/envs/obidam/lib/python2.7/site-packages/xarray/core/variable.py", line 308, in data
    return self.values
  File "/Users/gmaze/anaconda/envs/obidam/lib/python2.7/site-packages/xarray/core/variable.py", line 369, in values
    return _as_array_or_item(self._data)
  File "/Users/gmaze/anaconda/envs/obidam/lib/python2.7/site-packages/xarray/core/variable.py", line 225, in _as_array_or_item
    data = np.asarray(data)
  File "/Users/gmaze/anaconda/envs/obidam/lib/python2.7/site-packages/numpy/core/numeric.py", line 482, in asarray
    return array(a, dtype, copy=False, order=order)
  File "/Users/gmaze/anaconda/envs/obidam/lib/python2.7/site-packages/xarray/core/indexing.py", line 412, in __array__
    self._ensure_cached()
  File "/Users/gmaze/anaconda/envs/obidam/lib/python2.7/site-packages/xarray/core/indexing.py", line 409, in _ensure_cached
    self.array = np.asarray(self.array)
  File "/Users/gmaze/anaconda/envs/obidam/lib/python2.7/site-packages/numpy/core/numeric.py", line 482, in asarray
    return array(a, dtype, copy=False, order=order)
  File "/Users/gmaze/anaconda/envs/obidam/lib/python2.7/site-packages/xarray/core/indexing.py", line 393, in __array__
    return np.asarray(self.array, dtype=dtype)
  File "/Users/gmaze/anaconda/envs/obidam/lib/python2.7/site-packages/numpy/core/numeric.py", line 482, in asarray
    return array(a, dtype, copy=False, order=order)
  File "/Users/gmaze/anaconda/envs/obidam/lib/python2.7/site-packages/xarray/core/indexing.py", line 360, in __array__
    return np.asarray(array[self.key], dtype=None)
  File "/Users/gmaze/anaconda/envs/obidam/lib/python2.7/site-packages/xarray/conventions.py", line 384, in __getitem__
    return mask_and_scale(self.array[key], self.fill_value,
  File "/Users/gmaze/anaconda/envs/obidam/lib/python2.7/site-packages/xarray/conventions.py", line 493, in __getitem__
    return char_to_bytes(self.array[key])
  File "/Users/gmaze/anaconda/envs/obidam/lib/python2.7/site-packages/xarray/conventions.py", line 635, in char_to_bytes
    arr = np.array(arr, copy=False, order='C')
  File "/Users/gmaze/anaconda/envs/obidam/lib/python2.7/site-packages/xarray/core/indexing.py", line 360, in __array__
    return np.asarray(array[self.key], dtype=None)
  File "/Users/gmaze/anaconda/envs/obidam/lib/python2.7/site-packages/xarray/backends/netCDF4_.py", line 73, in __getitem__
    raise IndexError(msg)
IndexError: The indexing operation you are attempting to perform is not valid on netCDF4.Variable object. Try loading your data into memory first by calling .load().
Original traceback:
Traceback (most recent call last):
  File "/Users/gmaze/anaconda/envs/obidam/lib/python2.7/site-packages/xarray/backends/netCDF4_.py", line 62, in __getitem__
    data = getitem(self.get_array(), key)
  File "netCDF4/_netCDF4.pyx", line 3961, in netCDF4._netCDF4.Variable.__getitem__
  File "netCDF4/_netCDF4.pyx", line 4796, in netCDF4._netCDF4.Variable._get
IndexError

Expected Output:
In [26]: print ds
<xarray.Dataset>
Dimensions:                       (N_CALIB: 1, N_HISTORY: 0, N_LEVELS: 1007, N_PARAM: 3, N_PROF: 33)
Dimensions without coordinates: N_CALIB, N_HISTORY, N_LEVELS, N_PARAM, N_PROF
Data variables:
    DATA_TYPE                     object 'Argo profile    '
    FORMAT_VERSION                object '3.1 '
    HANDBOOK_VERSION              object '1.2 '
    REFERENCE_DATE_TIME           object '19500101000000'
    DATE_CREATION                 object '20150402105716'
    DATE_UPDATE                   object '20160127150022'
    PLATFORM_NUMBER               (N_PROF) object '4902076 ' '4902076 ' ...
    PROJECT_NAME                  (N_PROF) object 'US ARGO PROJECT                                                 ' ...
    PI_NAME                       (N_PROF) object 'GREGORY C. JOHNSON                                              ' ...
    STATION_PARAMETERS            (N_PROF, N_PARAM) object 'PRES            ' ...
    CYCLE_NUMBER                  (N_PROF) float64 1.0 2.0 4.0 5.0 6.0 7.0 ...
    DIRECTION                     (N_PROF) object 'A' 'A' 'A' 'A' 'A' 'A' ...
    DATA_CENTRE                   (N_PROF) object 'AO' 'AO' 'AO' 'AO' 'AO' ...
    DC_REFERENCE                  (N_PROF) object '5448_0469_001                   ' ...
    DATA_STATE_INDICATOR          (N_PROF) object '2B  ' '2B  ' '2B  ' ...
    DATA_MODE                     (N_PROF) object 'A' 'A' 'A' 'A' 'A' 'A' ...
    PLATFORM_TYPE                 (N_PROF) object 'NAVISIR                         ' ...
    FLOAT_SERIAL_NO               (N_PROF) object '0469                            ' ...
    FIRMWARE_VERSION              (N_PROF) object '011514                          ' ...
    WMO_INST_TYPE                 (N_PROF) object '863 ' '863 ' '863 ' ...
    JULD                          (N_PROF) datetime64[ns] 2015-03-03T08:56:39.984000 ...
    JULD_QC                       (N_PROF) object '1' '1' '1' '1' '1' '1' ...
    JULD_LOCATION                 (N_PROF) datetime64[ns] 2015-03-03T09:12:09.993600 ...
    LATITUDE                      (N_PROF) float64 20.26 20.11 21.53 22.0 ...
    LONGITUDE                     (N_PROF) float64 -121.5 -121.5 -121.1 ...
    POSITION_QC                   (N_PROF) object '1' '1' '1' '1' '1' '1' ...
    POSITIONING_SYSTEM            (N_PROF) object 'GPS     ' 'GPS     ' ...
    PROFILE_PRES_QC               (N_PROF) object 'A' 'A' 'A' 'A' 'A' 'A' ...
    PROFILE_TEMP_QC               (N_PROF) object 'A' 'A' 'A' 'A' 'A' 'A' ...
    PROFILE_PSAL_QC               (N_PROF) object 'A' 'A' 'A' 'A' 'A' 'A' ...
    VERTICAL_SAMPLING_SCHEME      (N_PROF) object 'Primary sampling: averaged []                                                                                ' ...
    CONFIG_MISSION_NUMBER         (N_PROF) float64 1.0 2.0 4.0 5.0 6.0 7.0 ...
    PRES                          (N_PROF, N_LEVELS) float64 4.0 6.0 8.0 ...
    PRES_QC                       (N_PROF, N_LEVELS) object '1' '1' '1' '1' ...
    PRES_ADJUSTED                 (N_PROF, N_LEVELS) float64 3.73 5.73 7.73 ...
    PRES_ADJUSTED_QC              (N_PROF, N_LEVELS) object '1' '1' '1' '1' ...
    PRES_ADJUSTED_ERROR           (N_PROF, N_LEVELS) float64 nan nan nan nan ...
    TEMP                          (N_PROF, N_LEVELS) float64 22.24 22.24 ...
    TEMP_QC                       (N_PROF, N_LEVELS) object '1' '1' '1' '1' ...
    TEMP_ADJUSTED                 (N_PROF, N_LEVELS) float64 22.24 22.24 ...
    TEMP_ADJUSTED_QC              (N_PROF, N_LEVELS) object '1' '1' '1' '1' ...
    TEMP_ADJUSTED_ERROR           (N_PROF, N_LEVELS) float64 nan nan nan nan ...
    PSAL                          (N_PROF, N_LEVELS) float64 34.45 34.45 ...
    PSAL_QC                       (N_PROF, N_LEVELS) object '1' '1' '1' '1' ...
    PSAL_ADJUSTED                 (N_PROF, N_LEVELS) float64 34.45 34.45 ...
    PSAL_ADJUSTED_QC              (N_PROF, N_LEVELS) object '1' '1' '1' '1' ...
    PSAL_ADJUSTED_ERROR           (N_PROF, N_LEVELS) float64 nan nan nan nan ...
    PARAMETER                     (N_PROF, N_CALIB, N_PARAM) object 'PRES            ' ...
    SCIENTIFIC_CALIB_EQUATION     (N_PROF, N_CALIB, N_PARAM) object 'PRES_ADJUSTED = PRES - surface_pressure                                                                                ' ...
    SCIENTIFIC_CALIB_COEFFICIENT  (N_PROF, N_CALIB, N_PARAM) object 'surface_pressure=0.27 dbar                                                                                ' ...
    SCIENTIFIC_CALIB_COMMENT      (N_PROF, N_CALIB, N_PARAM) object 'Pressure adjusted at real time based on most recent valid surface pressure                                                                                ' ...
    SCIENTIFIC_CALIB_DATE         (N_PROF, N_CALIB, N_PARAM) object '20150514141619' ...
     I use xarray frequently on ARGO netCDF files. It would be a shame if we broken something related to reading them. It sounds like this could be related to the indexing changes in #1676.
Since rc1, xarray 0.10.0 has gone through another release candidate (rc2) and is now in full release. Can you try upgrading to the just-released 0.10.0 and verify whether the problem is still present?

Yes, please upgrade to 0.10.0 and report back. I cannot reproduce your issue with this release version.

Ok, upgrading to 0.10.0 solve the issue ! Thanks
Should have tried this in the 1st place

It's good to see that the release-candidate process actually works! 😉

~It's good to see that the release-candidate process actually works!~ 😭

Reproduced also in my environment.
Selected repr of your dataset is
<xarray.Dataset>
Dimensions:                       (N_CALIB: 1, N_HISTORY: 0, N_LEVELS: 1007, N_PARAM: 3, N_PROF: 33)
Dimensions without coordinates: N_CALIB, N_HISTORY, N_LEVELS, N_PARAM, N_PROF
Data variables:
   ...
    SCIENTIFIC_CALIB_DATE         (N_PROF, N_CALIB, N_PARAM) object b'20150514141619' ...
    HISTORY_INSTITUTION           (N_HISTORY, N_PROF) object ...

It seems the data variable in concern, such as ds['HISTORY_STEP'], is 2-dimensional but one of the dimensions N_HISTORY is size 0.
Currently, xarray does not handle such zero-length n-dimensional arrays.
Maybe we need to drop such variables when reading?
@shoyer, @fmaussion, any idea?

Currently, xarray does not handle such zero-length n-dimensional arrays.
Maybe we need to drop such variables when reading?

Rather than drop a variable the user could read with no problem under xarray 0.9.6, I propose we examine our new indexing wrappers and figure out how to fix this bug.

But is this really the issue? Because this works:

import numpy as np
import xarray as xr

a = np.zeros((0, 2))
da = xr.DataArray(a)
da.to_netcdf('test.nc')

xr.open_dataarray('test.nc')
Out[16]:
<xarray.DataArray (dim_0: 0, dim_1: 2)>
array([], shape=(0, 2), dtype=float64)
Dimensions without coordinates: dim_0, dim_1

I tried with xarray v0.9.6 but it raises the same error.
Maybe also related to #1719 .

This might be specific to string variables (character arrays) and netCDF4. My guess is that netCDF4 may not handle indexing on zero-dimensional arrays properly.

This is pretty clearly a netCDF4-Python bug, which I have reported upstream: https://github.com/Unidata/netcdf4-python/issues/743
If desired, we probably could pretty easily add a work around for this behavior (e.g., to create an empty numpy array of the appropriate shape) to our netCDF4-python wrapper:
https://github.com/pydata/xarray/blob/9d09c1659741dafb1fadeed49c81f9e90a548b07/xarray/backends/netCDF4_.py#L50

Marking this as closed since the issue will be fixed in the next netcdf4-python release. Feel free to submit a PR with a work around for xarray if using the scipy backend is not a good alternative for you.

The scipy backend has shown to be a good alternative as of now, if not I'll write a work around though.
Thanks for your help !


Uncaught TypeError: Error processing argument -1.

[Enter steps to reproduce below:]

Clicked the "Report Issue" button on a deprecation call item.

Atom Version: 1.5.0-beta2
System: Microsoft Windows 7 Home Premium
Thrown From: deprecation-cop package, v0.54.0
Stack Trace
Uncaught TypeError: Error processing argument -1.
At C:\Users\jerone\AppData\Local\atom\app-1.5.0-beta2\resources\app.asar\node_modules\deprecation-cop\lib\deprecation-cop-view.js:189

TypeError: Error processing argument -1.
    at TypeError (native)
    at openExternally (C:\Users\jerone\AppData\Local\atom\app-1.5.0-beta2\resources\app.asar\node_modules\deprecation-cop\lib\deprecation-cop-view.js:189:33)
    at Object.$.ajax.success (C:\Users\jerone\AppData\Local\atom\app-1.5.0-beta2\resources\app.asar\node_modules\deprecation-cop\lib\deprecation-cop-view.js:203:22)
    at fire (C:\Users\jerone\AppData\Local\atom\app-1.5.0-beta2\resources\app.asar\node_modules\jquery\dist\jquery.js:3099:30)
    at Object.self.fireWith [as resolveWith] (C:\Users\jerone\AppData\Local\atom\app-1.5.0-beta2\resources\app.asar\node_modules\jquery\dist\jquery.js:3211:7)
    at done (C:\Users\jerone\AppData\Local\atom\app-1.5.0-beta2\resources\app.asar\node_modules\jquery\dist\jquery.js:8264:14)
    at XMLHttpRequest.<anonymous> (C:\Users\jerone\AppData\Local\atom\app-1.5.0-beta2\resources\app.asar\node_modules\jquery\dist\jquery.js:8605:9)

Commands
     -0:29.7.0 deprecation-cop:view (atom-workspace.workspace.scrollbars-visible-always.use-animations.theme-atom-material-syntax.theme-atom-material-ui.panel-contrast.tinted-tab-bar.blend-tree-view.compact-tree-view.compact-tab-bar)

Config
{
  "core": {
    "disabledPackages": [
      "atom-jade",
      "json-schema"
    ],
    "themes": [
      "atom-material-ui",
      "atom-material-syntax"
    ]
  }
}

Installed Packages
# User
atom-json-editor, v0.4.1
atom-less, v0.1.10
atom-material-syntax, v0.3.2
atom-material-ui, v0.8.1
atom-minify, v0.7.1
bottom-dock, v0.3.7
coffee-refactor, v0.7.0
color-picker, v2.1.1
editorconfig, v1.2.4
file-icons, v1.6.14
flex-tool-bar, v0.7.3
foldername-tabs, v0.1.10
gutter-shadow, v0.6.0
imdone-atom, v1.3.25
indentation-indicator, v0.6.0
jade-autocompile, v0.8.3
language-actionscript3, v0.3.0
language-jade, v0.6.3
less-postcss-autocompile, v1.2.3
less-than-slash, v0.12.3
linter, v1.11.3
linter-coffeelint, v1.1.2
linter-csslint, v1.2.0
linter-htmlhint, v1.0.2
linter-jade, v0.3.2
linter-jshint, v1.3.0
linter-just-say-no, v0.6.1
linter-less, v2.3.3
linter-manager, v0.2.8
linter-markdown, v1.3.0
linter-sass-lint, v1.0.3
linter-scspell, v2.0.1
markdown-scroll-sync, v2.0.3
menu-manager, v0.4.4
minimap, v4.19.0
minimap-bookmarks, v0.2.0
minimap-find-and-replace, v4.4.0
minimap-git-diff, v4.1.8
minimap-highlight-selected, v4.3.1
minimap-linter, v1.1.1
minimap-pigments, v0.1.7
minimap-selection, v4.3.1
new-tab, v0.5.0
open-recent, v5.0.0
pigments, v0.23.0
pinned-tabs, v0.1.12
project-view, v0.5.0
refactor, v0.6.0
sass-autocompile, v0.12.2
soft-wrap-indicator, v0.7.0
sync-settings, v0.6.0
tool-bar, v0.2.0

# Dev
atom-material-ui, v1.0.5

This issue still happens when I press the "Report Issue" button on a deprecation in the deprecation's cop pane.
The following message appeared in the console:
Failed to load resource: the server responded with a status of 422 (Unprocessable Entity)
https://api.github.com/search/issues?q=Object.TextEditor%20is%20deprecated.%20repo:git+mark-hahn/markdown-scroll-sync&sort=created

When opening above url it will print the following message:
{
    "message": "Validation Failed",
    "errors": [
        {
            "message": "The listed users and repositories cannot be searched either because the resources do not exist or you do not have permission to view them.",
            "resource": "Search",
            "field": "q",
            "code": "invalid"
        }
    ],
    "documentation_url": "https://developer.github.com/v3/search/"
}

Hope that helps a little bit.

I had the same issue as @jerone. The issue seems to be from the regular expression on deprecation-cop-view.coffee:84:
repo = repoUrl.replace /http(s)?:\/\/(\d+\.)?github.com\//gi, ''

works on some packages, but not for others with a ^git+ prefix...
{"type": "git", "url": "git+https://github.com/ben/autoflow-diffable.git"}
{"type": "git", "url": "https://github.com/atom/atom-dark-syntax.git"}

which results in malformed URLs that are visible in the JSON response above.

with a ^git+ prefix

I can confirm this. When removing git+ from the url I get a valid response back from the server:
-https://api.github.com/search/issues?q=Object.TextEditor%20is%20deprecated.%20repo:git+mark-hahn/markdown-scroll-sync&sort=created
+https://api.github.com/search/issues?q=Object.TextEditor%20is%20deprecated.%20repo:mark-hahn/markdown-scroll-sync&sort=created

Thanks for the report. This is now fixed on master via a fix to package repository URL normalization in the package manager.


Added angular sample for xlsx-import package

Description
Resolves "Angular sample" from #6

Thank you for adding next sample :) I am going to review and test it on the evening or tomorrow.
I see also, that xlsx-renderer checks falls - but shouldn't. I have to check it.

@Metastasis could I ask you to change GH button url  : https://github.com/Siemienik/XToolset#the-xlsx-import ?

I've just tested again Squash merge, and will it doesn't take authorship


tvOS Support

It seems to be possible since AFNetworking 3.1.0 supports tvOS

Waiting on Ono project: https://github.com/mattt/Ono/issues/61

Here's a branch if you're still interested.


Grouping by multiple columns with dropna=False gives unexpected results

What happened:
I am attempting to do a groupby on multiple columns with dropna=False, and I find that this still drops null values:
import dask.dataframe as dd
import pandas as pd

df = pd.DataFrame(
    {
        "a": [1, 2, 3, 4, None, None, 7, 8],
        "b": [1, None, 1, 3, None, 3, 1, 3],
        "c": [4, 5, 6, 3, 2, 1, 0, 0],
    }
)

ddf = dd.from_pandas(df, npartitions=2)

res = ddf.groupby(["a", "b"], dropna=False).sum()

res.compute()

         c
a   b
1.0 1.0  4
3.0 1.0  6
4.0 3.0  3
7.0 1.0  0
8.0 3.0  0

When attempting this same operation with a series groupby, we get an error during computation:
res = ddf.groupby(["a", "b"], dropna=False).c.sum()

res.compute()

Trackback
TypeError                                 Traceback (most recent call last)
Input In [16], in <cell line: 16>()
     12 ddf = dd.from_pandas(df, npartitions=2)
     14 res = ddf.groupby(["a", "b"], dropna=False).c.sum()
---> 16 res.compute()

File ~/dask/dask/base.py:292, in DaskMethodsMixin.compute(self, **kwargs)
    268 def compute(self, **kwargs):
    269     """Compute this dask collection
    270
    271     This turns a lazy Dask collection into its in-memory equivalent.
   (...)
    290     dask.base.compute
    291     """
--> 292     (result,) = compute(self, traverse=False, **kwargs)
    293     return result

File ~/dask/dask/base.py:575, in compute(traverse, optimize_graph, scheduler, get, *args, **kwargs)
    572     keys.append(x.__dask_keys__())
    573     postcomputes.append(x.__dask_postcompute__())
--> 575 results = schedule(dsk, keys, **kwargs)
    576 return repack([f(r, *a) for r, (f, a) in zip(results, postcomputes)])

File ~/dask/dask/threaded.py:81, in get(dsk, result, cache, num_workers, pool, **kwargs)
     78     elif isinstance(pool, multiprocessing.pool.Pool):
     79         pool = MultiprocessingPoolExecutor(pool)
---> 81 results = get_async(
     82     pool.submit,
     83     pool._max_workers,
     84     dsk,
     85     result,
     86     cache=cache,
     87     get_id=_thread_get_id,
     88     pack_exception=pack_exception,
     89     **kwargs,
     90 )
     92 # Cleanup pools associated to dead threads
     93 with pools_lock:

File ~/dask/dask/local.py:508, in get_async(submit, num_workers, dsk, result, cache, get_id, rerun_exceptions_locally, pack_exception, raise_exception, callbacks, dumps, loads, chunksize, **kwargs)
    506         _execute_task(task, data)  # Re-execute locally
    507     else:
--> 508         raise_exception(exc, tb)
    509 res, worker_id = loads(res_info)
    510 state["cache"][key] = res

File ~/dask/dask/local.py:316, in reraise(exc, tb)
    314 if exc.__traceback__ is not tb:
    315     raise exc.with_traceback(tb)
--> 316 raise exc

File ~/dask/dask/local.py:221, in execute_task(key, task_info, dumps, loads, get_id, pack_exception)
    219 try:
    220     task, data = loads(task_info)
--> 221     result = _execute_task(task, data)
    222     id = get_id()
    223     result = dumps((result, id))

File ~/dask/dask/core.py:119, in _execute_task(arg, cache, dsk)
    115     func, args = arg[0], arg[1:]
    116     # Note: Don't assign the subtask results to a variable. numpy detects
    117     # temporaries by their reference count and can execute certain
    118     # operations in-place.
--> 119     return func(*(_execute_task(a, cache) for a in args))
    120 elif not ishashable(arg):
    121     return arg

File ~/compose/etc/conda/cuda_11.5/envs/rapids/lib/python3.9/site-packages/toolz/functoolz.py:630, in pipe(data, *funcs)
    610 """ Pipe a value through a sequence of functions
    611
    612 I.e. ``pipe(data, f, g, h)`` is equivalent to ``h(g(f(data)))``
   (...)
    627     thread_last
    628 """
    629 for func in funcs:
--> 630     data = func(data)
    631 return data

File ~/dask/dask/dataframe/groupby.py:295, in _groupby_aggregate(df, aggfunc, levels, dropna, sort, observed, **kwargs)
    292 dropna = {"dropna": dropna} if dropna is not None else {}
    293 observed = {"observed": observed} if observed is not None else {}
--> 295 grouped = df.groupby(level=levels, sort=sort, **observed, **dropna)
    296 return aggfunc(grouped, **kwargs)

File ~/compose/etc/conda/cuda_11.5/envs/rapids/lib/python3.9/site-packages/pandas/core/series.py:1884, in Series.groupby(self, by, axis, level, as_index, sort, group_keys, squeeze, observed, dropna)
   1880 axis = self._get_axis_number(axis)
   1882 # error: Argument "squeeze" to "SeriesGroupBy" has incompatible type
   1883 # "Union[bool, NoDefault]"; expected "bool"
-> 1884 return SeriesGroupBy(
   1885     obj=self,
   1886     keys=by,
   1887     axis=axis,
   1888     level=level,
   1889     as_index=as_index,
   1890     sort=sort,
   1891     group_keys=group_keys,
   1892     squeeze=squeeze,  # type: ignore[arg-type]
   1893     observed=observed,
   1894     dropna=dropna,
   1895 )

File ~/compose/etc/conda/cuda_11.5/envs/rapids/lib/python3.9/site-packages/pandas/core/groupby/groupby.py:889, in GroupBy.__init__(self, obj, keys, axis, level, grouper, exclusions, selection, as_index, sort, group_keys, squeeze, observed, mutated, dropna)
    886 if grouper is None:
    887     from pandas.core.groupby.grouper import get_grouper
--> 889     grouper, exclusions, obj = get_grouper(
    890         obj,
    891         keys,
    892         axis=axis,
    893         level=level,
    894         sort=sort,
    895         observed=observed,
    896         mutated=self.mutated,
    897         dropna=self.dropna,
    898     )
    900 self.obj = obj
    901 self.axis = obj._get_axis_number(axis)

File ~/compose/etc/conda/cuda_11.5/envs/rapids/lib/python3.9/site-packages/pandas/core/groupby/grouper.py:879, in get_grouper(obj, key, axis, level, sort, observed, mutated, validate, dropna)
    871         raise ValueError(
    872             f"Length of grouper ({len(gpr)}) and axis ({obj.shape[axis]}) "
    873             "must be same length"
    874         )
    876     # create the Grouping
    877     # allow us to passing the actual Grouping as the gpr
    878     ping = (
--> 879         Grouping(
    880             group_axis,
    881             gpr,
    882             obj=obj,
    883             level=level,
    884             sort=sort,
    885             observed=observed,
    886             in_axis=in_axis,
    887             dropna=dropna,
    888         )
    889         if not isinstance(gpr, Grouping)
    890         else gpr
    891     )
    893     groupings.append(ping)
    895 if len(groupings) == 0 and len(obj):

File ~/compose/etc/conda/cuda_11.5/envs/rapids/lib/python3.9/site-packages/pandas/core/groupby/grouper.py:493, in Grouping.__init__(self, index, grouper, obj, level, sort, observed, in_axis, dropna)
    485     mapper = self.grouping_vector
    486     # In extant tests, the new self.grouping_vector matches
    487     #  `index.get_level_values(ilevel)` whenever
    488     #  mapper is None and isinstance(index, MultiIndex)
    489     (
    490         self.grouping_vector,  # Index
    491         self._codes,
    492         self._group_index,
--> 493     ) = index._get_grouper_for_level(mapper, ilevel)
    495 # a passed Grouper like, directly get the grouper in the same way
    496 # as single grouper groupby, use the group_info to get codes
    497 elif isinstance(self.grouping_vector, Grouper):
    498     # get the new grouper; we already have disambiguated
    499     # what key/level refer to exactly, don't need to
    500     # check again as we have by this point converted these
    501     # to an actual value (rather than a pd.Grouper)

File ~/compose/etc/conda/cuda_11.5/envs/rapids/lib/python3.9/site-packages/pandas/core/indexes/multi.py:1483, in MultiIndex._get_grouper_for_level(self, mapper, level)
   1480 if mapper is not None:
   1481     # Handle group mapping function and return
   1482     level_values = self.levels[level].take(indexer)
-> 1483     grouper = level_values.map(mapper)
   1484     return grouper, None, None
   1486 codes, uniques = algos.factorize(indexer, sort=True)

File ~/compose/etc/conda/cuda_11.5/envs/rapids/lib/python3.9/site-packages/pandas/core/indexes/base.py:5506, in Index.map(self, mapper, na_action)
   5486 """
   5487 Map values using input correspondence (a dict, Series, or function).
   5488
   (...)
   5502     a MultiIndex will be returned.
   5503 """
   5504 from pandas.core.indexes.multi import MultiIndex
-> 5506 new_values = self._map_values(mapper, na_action=na_action)
   5508 attributes = self._get_attributes_dict()
   5510 # we can return a MultiIndex

File ~/compose/etc/conda/cuda_11.5/envs/rapids/lib/python3.9/site-packages/pandas/core/base.py:870, in IndexOpsMixin._map_values(self, mapper, na_action)
    867         raise ValueError(msg)
    869 # mapper is a function
--> 870 new_values = map_f(values, mapper)
    872 return new_values

File ~/compose/etc/conda/cuda_11.5/envs/rapids/lib/python3.9/site-packages/pandas/_libs/lib.pyx:2859, in pandas._libs.lib.map_infer()

TypeError: 'numpy.ndarray' object is not callable

What you expected to happen:
Pandas gives the following outputs:
df.groupby(["a", "b"], dropna=False).sum()

         c
a   b
1.0 1.0  4
2.0 NaN  5
3.0 1.0  6
4.0 3.0  3
7.0 1.0  0
8.0 3.0  0
NaN 3.0  1
    NaN  2

df.groupby(["a", "b"], dropna=False).c.sum()

a    b
1.0  1.0    4
2.0  NaN    5
3.0  1.0    6
4.0  3.0    3
7.0  1.0    0
8.0  3.0    0
NaN  3.0    1
     NaN    2
Name: c, dtype: int64

Environment:

Dask version: latest main
Python version: 3.9
Operating System: ubuntu 18.04
Install method (conda, pip, source): source

Opened an issue tracking this - https://github.com/pandas-dev/pandas/issues/46783

A fix was submitted and merged for this in https://github.com/pandas-dev/pandas/pull/47186, and should be included in the 1.5 release - I will go ahead and verify that things are working here with the latest source of Pandas.
Assuming things work now, how would we like to handle the required Pandas dependency? Is it okay to bump the Pandas min version for dask.dataframe to 1.5, or do we want to leave that more flexible and have a check on Pandas version for this specific groupby functionality?

Can verify that https://github.com/pandas-dev/pandas/pull/47186 has resolved the issue for dataframe groupbys - I am still getting the same traceback for series groupbys though.

Think I've isolated the series groupby failures to Pandas; as part of _groupby_aggregate, we are attempting to do a groupby on a series with a multi-index that has nulls in all levels, which seems to fail regardless of dropna:
import pandas as pd

arr = [list(range(4)) * 4, list(range(2)) * 8]

# inserting nulls into all levels of multi-index
arr[0][2] = None
arr[1][4] = None

ser = pd.Series(
    list(range(16)),
    index=pd.MultiIndex.from_arrays(arr, names=("a", "b"))
)

ser.groupby(level=[0, 1])

Will open up another issue to track this in Pandas.

Thanks for keeping on top of this Charles!

With the above pandas issues resolved, I can confirm these issues no longer occur with pandas 1.5.0rc0.
Knowing this, is there anything we want to change on Dask's end w.r.t. pandas constraints? I imagine we don't want to bump the pandas minimum dependency, not sure if it makes sense to introduce some compatibility code here to block certain groupbys if an older pandas version is detected.

Yeah we definitely don't want to bump the minimum. If it's easy to bring in some compatibility code that seems like a good approach.

Opened #9468 to add warnings around the groupby behavior in pandas < 1.5.0

Closing this since there do not seem to be any errors with pandas>=1.5. Feel free to re-open if I'm missing something.


Learn about choo

[x] choo
[x] sheetify

Examples

Pers choo project
Choo examples

Adding "-P" option to the budo CLI startup will render Index page instead of error page. This will enable choo's routing to be initialized and render the respective (Error) Page.

If you want to use location hash based routing you can start choo using the {hash: true}-option. That way you get routing based on /#/... strings. It lacks an automatic update mechanism for the URL though.

👍

🚀

🚀


Update should be in a transaction

The update method does a find and then an update, there will be an issue if the resource is changed between those methods so it should be done in a transaction.

That's valid, but too rare and specific an issue for the general purpose of this controller.


OS3 little template improvements

I'll collect minor things that annoy me using OS3. If someone will do this, I would appreciate this.

[ ] Clicking on the main OpenSlides logo should navigate to the start page
[ ] The menu does not close if clicking on the grayed site.
[ ] The menu does not have a burger menu, if using a mobile approch, so one cannot close it
[ ] All views should have the possibility to go back. In every place a top located "go back" is missing. Navigating is terrible if one has always to use the menu.

To be continued..

Thanks to all implementing points from this!


how to reuse a cancelled channel

Expected behavior
I use spliceTo to upload file.  but I don't know the file size util another request tell me .
So i will cancel the spliceTo channel when I got another request.
And i want my client reuse the  spliceTo channel when next transport.
Actual behavior
when my client reuse the channel . i got
java.lang.IllegalStateException: complete already
Netty version
4.1.89.Final

Can you please show the full stack trace ?

I think splice are still in task when I cancel splice channel .
Cause I got  ERRNO_EBADF_NEGATIVE indicate that the native splice is still running?

I chose that wait server ready spliceTo then client send stream. even it may use a RTT, but it worth.


Perp Gamma mode + update fill listener

Add a perp gamma mode that does not delta hedge. Useful as a quasi market maker and for testing illiquid markets where taking delta hedges are costly.
This mode uncovered a change to the websocket fill listener which originally had 2 trade events per fill one for the take and one for the maker.
Small fix to round gamma to min step size so that order placement isn't rejected.
The full set of changes was tested locally on BTC for ~3 days. Test trading pnl positive and funding rate pnl positive, although with current liquidity we seem to skew to sell

Pull request description and title need to be more descriptive on a quick glance. They need to state what is going on for someone checking commit logs. Ideally these things are split up and would be like
Title:
New perp gamma mode
Description:
Adds new gamma scalping mode for perp where we ...
Title:
Update to latest spec for fills from mango
Description:

Pull request description and title need to be more descriptive on a quick glance. They need to state what is going on for someone checking commit logs. Ideally these things are split up and would be like
Title: New perp gamma mode Description: Adds new gamma scalping mode for perp where we ...
Title: Update to latest spec for fills from mango Description:

Will make the descriptions more detailed. The issue with splitting the PRs is that I don't test them individually. Perp gamma mode was added and uncovered the issue around the new websocket objects. This has been running locally for a couple days so breaking them up just adds room for errors imo
For now this is just an added tool to the RM as we don't have active risk to manage using it

FillFeed change
https://github.com/blockworks-foundation/mango-feeds/blob/ec80a1980d79221df617cdf100b9896049e34778/lib/src/fill_event_filter.rs#L74


HDDS-4631. Fix client set quota with 0.

What changes were proposed in this pull request?
Currently setting Quota is invalid if set to 0. It's actually going to be set to -1.
store.getVolume(volumeName).getBucket(bucketName).setQuota(
       OzoneQuota.parseQuota("0GB", 0));
  Assert.assertEquals(-1, bucket.getQuotaInBytes());
  Assert.assertEquals(-1, bucket.getQuotaInNamespace());
This behavior is actually incorrect, and In general setting quota to 0 isn't a valid entry even in HDFS.  we can be consistent with HDFS on this part.
java.lang.IllegalArgumentException: Invalid values for quota : 0
Because the original client quota type is long. If the user does not specify quota, the default value for this field is 0.
We cannot verify that the user did not specify quota or set quoat to 0, since both actions are passed to the backend to be 0.
So it would be more appropriate to change the long to a string. If the user does not specify quota, it is null. It's easier to judge.
What is the link to the Apache JIRA
https://issues.apache.org/jira/browse/HDDS-4631
How was this patch tested?
ut added

In general setting quota to 0 isn't a valid entry even in HDFS.
It throws an exception

@ayushtkn Thanks for the tip. I think we can be consistent with HDFS on this part. Later I will commit a new commit to fix it

Fixed review issues. cc @ayushtkn

@captainzmc , If setting quota to 0 is not allowed now, can we rollback unrelated change in this PR?

@captainzmc , If setting quota to 0 is not allowed now, can we rollback unrelated change in this PR?

@linyiqun Thanks for the tip.
I think currently all changes to this PR are required。
First we need to be able to distinguish whether the user sets quota to 0 (users may not specify Quoat when creating volumes and buckets, long is undefined as 0 by default and should be successful), and then judge the validity based on this.
Therefore, we need to change quotaInNamespace from long to String. In addition, it is also possible for users to specify either quotaInBytes or quotaInNamespace separately. In addition, many cases of original UT are not covered, so I made a supplement separately.

{quote}
First we need to be able to distinguish whether the user sets quota to 0 (users may not specify Quoat when creating volumes and buckets, long is undefined as 0 by default and should be successful), and then judge the validity based on this.
{quote}
I don't fully get why we need to distinguish whether the user sets quota to 0. If the long undefined value is 0, we could return a Quota.RESET value instead of while get the quota value for this case. I don't think this is a problem here. And for other cases, we don't allow 0 could be set by cli command after above change.

{quote}
First we need to be able to distinguish whether the user sets quota to 0 (users may not specify Quoat when creating volumes and buckets, long is undefined as 0 by default and should be successful), and then judge the validity based on this.
{quote}
I don't fully get why we need to distinguish whether the user sets quota to 0. If the long undefined value is 0, we could return a Quota.RESET value instead of while get the quota value for this case. I don't think this is a problem here. And for other cases, we don't allow 0 could be set by cli command after above change.

I am even not sure about converting to string type. If the user hasn't specified, Can't we send specific constant like QUOTA_DONT_SET(Something like this is there in HdfsConstants) to distinguish. We can even just validate at client side and leave the server side as is, Like don't bother with 0. Might help for compatibility reasons.
The present aim is like we don't support 0, it is not taking affect also. We just need to tell the client it won't work and save an RPC, if he tends to shoot 0.

I am even not sure about converting to string type. If the user hasn't specified, Can't we send specific constant like QUOTA_DONT_SET(Something like this is there in HdfsConstants) to distinguish. We can even just validate at client side and leave the server side as is, Like don't bother with 0. Might help for compatibility reasons.
The present aim is like we don't support 0, it is not taking affect also. We just need to tell the client it won't work and save an RPC, if he tends to shoot 0.

Hi @linyiqun @ayushtkn Sorry for the late reply, we can continue to discuss this problem.
Maybe I didn't make it clear before, let's do an example：
ozone sh bucket create vol1 （This should be success）
ozone sh bucket create vol1 --space-quota 0TB --namespace-quota 0 （This should be unsuccessful）
These are two different cases. But in both cases in CreateVolumeHandler quotaOptions.getQuotaInNamespace() is 0.

Different cases  receives the same parameters. Because the long variable is also 0 by default when it is not declared.
Let's look at another example，this also has the same problem：
ozone sh volume setquota vol1 --space-quota 10TB （This should be success）
ozone sh volume setquota vol1 --space-quota 10TB --namespace-quota 0 （This should be unsuccessful）
Because of this, I changed long to a string.

Hi @linyiqun @ayushtkn Sorry for the late reply, we can continue to discuss this problem.
Maybe I didn't make it clear before, let's do an example：
ozone sh bucket create vol1 （This should be success）
ozone sh bucket create vol1 --space-quota 0TB --namespace-quota 0 （This should be unsuccessful）
These are two different cases. But in both cases in CreateVolumeHandler quotaOptions.getQuotaInNamespace() is 0.

Different cases  receives the same parameters. Because the long variable is also 0 by default when it is not declared.
Let's look at another example，this also has the same problem：
ozone sh volume setquota vol1 --space-quota 10TB （This should be success）
ozone sh volume setquota vol1 --space-quota 10TB --namespace-quota 0 （This should be unsuccessful）
Because of this, I changed long to a string.

I am even not sure about converting to string type. If the user hasn't specified, Can't we send specific constant like QUOTA_DONT_SET(Something like this is there in HdfsConstants) to distinguish.

Suppose current logic already implement this logic(see below assert), if user hasn't specified quota. 0 means it comes from the long type default value as user.
    store.getVolume(volumeName).setQuota(OzoneQuota.parseQuota(
        "0GB", 0L));
    volume = store.getVolume(volumeName);
    Assert.assertEquals(OzoneConsts.QUOTA_RESET, volume.getQuotaInBytes());
    Assert.assertEquals(OzoneConsts.QUOTA_RESET, volume.getQuotaInNamespace());

Let's look at another example，this also has the same problem：
ozone sh volume setquota vol1 --space-quota 10TB （This should be success）
ozone sh volume setquota vol1 --space-quota 10TB --namespace-quota 0 （This should be unsuccessful）

@captainzmc , this will be not a problem. For first case that don't specified namespace quota, now the real meaning is the quota unset not means namepsace quota was 0.
So I prefer only to make the adjustment that don't allow 0 can be set in this PR change.

I am even not sure about converting to string type. If the user hasn't specified, Can't we send specific constant like QUOTA_DONT_SET(Something like this is there in HdfsConstants) to distinguish.

Suppose current logic already implement this logic(see below assert), if user hasn't specified quota. 0 means it comes from the long type default value as user.
    store.getVolume(volumeName).setQuota(OzoneQuota.parseQuota(
        "0GB", 0L));
    volume = store.getVolume(volumeName);
    Assert.assertEquals(OzoneConsts.QUOTA_RESET, volume.getQuotaInBytes());
    Assert.assertEquals(OzoneConsts.QUOTA_RESET, volume.getQuotaInNamespace());

Let's look at another example，this also has the same problem：
ozone sh volume setquota vol1 --space-quota 10TB （This should be success）
ozone sh volume setquota vol1 --space-quota 10TB --namespace-quota 0 （This should be unsuccessful）

@captainzmc , this will be not a problem. For first case that don't specified namespace quota, now the real meaning is the quota unset not means namepsace quota was 0.
So I prefer only to make the adjustment that don't allow 0 can be set in this PR change.

Let's look at another example，this also has the same problem：
ozone sh volume setquota vol1 --space-quota 10TB （This should be success）
ozone sh volume setquota vol1 --space-quota 10TB --namespace-quota 0 （This should be unsuccessful）

@captainzmc , this will be not a problem.

We can reproduce the case I mentioned above using UT in the current master code. Add the following test code in UT：

Set the breakpoint in SetQuotaHandler. Execute the test. We can see that although namespace quota was not specified, 0 was passed in anyway. Because when this field is not defined get the default value (0) of long.

The first case can also reproduce with the testShQuota UT, adding a breakpoint at CreateVolumeHandler. Execute the test.

For first case that don't specified namespace quota, now the real meaning is the quota unset not means namepsace quota was 0.
So I prefer only to make the adjustment that don't allow 0 can be set in this PR change.

I agree that we need to distinguish between these two different behaviors of the user. ”Don't allow 0 can be set“ It's our purpose，I also agree this. The point is, how do we do that?
We need to distinguish whether this '0' was set by the user actively or user didn't set it so that the code uses the default value of long.
At the moment, I can't think of anything better than replacing a long with a string (which is easier to judge because the default value of a String is null not 0). Is any advice here?

Let's look at another example，this also has the same problem：
ozone sh volume setquota vol1 --space-quota 10TB （This should be success）
ozone sh volume setquota vol1 --space-quota 10TB --namespace-quota 0 （This should be unsuccessful）

@captainzmc , this will be not a problem.

We can reproduce the case I mentioned above using UT in the current master code. Add the following test code in UT：

Set the breakpoint in SetQuotaHandler. Execute the test. We can see that although namespace quota was not specified, 0 was passed in anyway. Because when this field is not defined get the default value (0) of long.

The first case can also reproduce with the testShQuota UT, adding a breakpoint at CreateVolumeHandler. Execute the test.

For first case that don't specified namespace quota, now the real meaning is the quota unset not means namepsace quota was 0.
So I prefer only to make the adjustment that don't allow 0 can be set in this PR change.

I agree that we need to distinguish between these two different behaviors of the user. ”Don't allow 0 can be set“ It's our purpose，I also agree this. The point is, how do we do that?
We need to distinguish whether this '0' was set by the user actively or user didn't set it so that the code uses the default value of long.
At the moment, I can't think of anything better than replacing a long with a string (which is easier to judge because the default value of a String is null not 0). Is any advice here?

I agree that we need to distinguish between these two different behaviors of the user. ”Don't allow 0 can be set“ It's our purpose，also agree this. The point is, how do we do that?

@captainzmc , here I mean don't allow 0 can be set in quota from the client side. So we can just add check in OzoneQuota#parseQuota and RpcClient#verifyCountsQuota/verifySpaceQuota. Does this make sense to you?

I agree that we need to distinguish between these two different behaviors of the user. ”Don't allow 0 can be set“ It's our purpose，also agree this. The point is, how do we do that?

@captainzmc , here I mean don't allow 0 can be set in quota from the client side. So we can just add check in OzoneQuota#parseQuota and RpcClient#verifyCountsQuota/verifySpaceQuota. Does this make sense to you?

I see OmVolumeArgs resets the quotaInBytes/quotaInNamespace to OzoneConsts.QUOTA_RESET in its builder function. We can also make this change in OmBucketArgs# builder constructor. In addition, we should also reset quota when 0 was passed in constructor method.

Good advice. I found there are some bugs with creating volumes and buckets when quota is specified to 0 or not. This proposal can fix these problems. I will fix it in the new Commit.
The previous Commit had add check in OzoneQuota#parseQuota and RpcClient#verifyCountsQuota/verifySpaceQuota.

I see OmVolumeArgs resets the quotaInBytes/quotaInNamespace to OzoneConsts.QUOTA_RESET in its builder function. We can also make this change in OmBucketArgs# builder constructor. In addition, we should also reset quota when 0 was passed in constructor method.

Good advice. I found there are some bugs with creating volumes and buckets when quota is specified to 0 or not. This proposal can fix these problems. I will fix it in the new Commit.
The previous Commit had add check in OzoneQuota#parseQuota and RpcClient#verifyCountsQuota/verifySpaceQuota.

Is any review update here？ @linyiqun @amaliujia @ChenSammi

Is any review update here？ @linyiqun @amaliujia @ChenSammi

Fixed review issues.  cc @ChenSammi
CI runs normally on my personal branch. Failed UT is irrelevant.

Fixed review issues.  cc @ChenSammi
CI runs normally on my personal branch. Failed UT is irrelevant.


FDroid Store?

Can this please be added to the F-Droid store?

See https://github.com/Tommy-Geenexus/exif-eraser/issues/40.
TL;DR due to time constraints i won't be publishing on FDroid, if you require the FOSS-Version feel free to download via Accrescent or GitHub releases.


Is this project deprecated?

@auvipy Hey, questions about this project...  is this completely replaced by django-celery-beat and django-celery-results at this point?  The docs seem to suggest this, but don't outright say it.

It looks like there is a monitoring capability of it, which someone forked and made celery4 compatible here:  https://github.com/jezdez/django-celery-monitor
I suppose that functionality is also covered by flower though?  https://github.com/mher/flower
I'd like to know more about the the decisions made around this and what the plans are for the future.  I think it would be nice to have monitoring capabilities built-in, but maybe there were reasons why that was not done like it was for beat and results?

It is deprecated for celery 4. and yes monitor is forked by another guy. Though the flower is the suggested one. The goal is two make the two new package as complete and futuristic as possible. And docs might need some good amount of edits as well

@auvipy so this is not compatible with eg Django 2.2 ? I´ve seen a ticket for bumping the version up. In case I want to use celery with Django I still can use the official guide for "manual" connecting right?
https://docs.celeryproject.org/en/stable/django/first-steps-with-django.html

with  celery 4.x series django-celery-beat, and django-celery-result should be used.


Make nREPL server persist over resets

fixes https://github.com/kit-clj/kit/issues/91
Mostly inspired by how this is done in other components, tested it in the REPL with integrant.repl/reset with something like this:
 (require '[integrant.repl :as igr])
 (igr/set-prep! #(ig/prep {:nrepl/server {:port 4004}}))
 (igr/reset)

I also added another commit (happy to open a separate PR or remove it) but just wanted to check in about the idea: I usually start my development system via something like bb dev this will launch an nREPL server that I then connect to. I think with kit it could make sense to do something similar and only inject that component in development?

I find nREPL can be useful in a deployed app as well. I often keep nREPL open when I deploy the app to dev environment in a jar for example, and then use ssh reverse tunnel to forward it locally.

I find nREPL can be useful in a deployed app as well. I often keep nREPL open when I deploy the app to dev environment in a jar for example, and then use ssh reverse tunnel to forward it locally.

Absolutely, I didn't mean to limit this to development usage but thinking of kit as a wholistic framework it could be nice if it just started an nREPL server during development — which would be easy with this module and the .nrepl-port addition.

Ah ok, yeah that makes sense. I think keeping it consistent is reasonable. From what I've seen, people tend to be split between running the app and then starting the REPL from it for the editor to connect to, and running the REPL from editor and then starting up the system in the REPL. I think controlling whether nREPL component starts up based on a flag would such as :enabled? might be the way to go here?

I was wondering a similar thing recently: how to conditionally load components? That said I think this should be handled in the realm of system.edn rather than adding no-op flags to individual components.
I think with aero #merge, #include or similar switching on the profile.

I agree, handling it in system.edn would be a reasonable way to go.


Bug fix for contacts page

Bug Fix for Contacts Page

This PR:
1.    Fixes the bug where the website fails to render after login due to undefined variable client by changing it to contact and modifying the area which are causing the issue
2.   Also removes the unused link element from index.html for the original css file

The files this PR effects:
Components/Pages

src/pages/Profile.jsx

Other Files

index.html

Screenshots (if applicable):
Screenshot of fix:
https://github.com/codeforpdx/PASS/assets/14917816/1de0d2d0-ed42-4b28-9064-07f69719033d
Screenshot of signup link rendering for signups page:
https://github.com/codeforpdx/PASS/assets/14917816/1c51add1-2782-4773-94ea-bdc8d7cc2a20

Good quick fix
Only question is whether client should also be changed to contact on lines 45 and 111

Yeah, I think I could do that before merging.l the fixes. I'll check any of the test files, too, in case it fails one of them.

Hey @xscottxbrownx and @timbot1789, I've just updated PR based on the new comments. Let me know if there's still anything else that would need to be corrected. Would like to merge this in as soon as possible to fix the existing rendering bug.


When is 2.3.4 released?

Search before asking

[X] I had searched in the feature and found no similar feature requirement.

Description
When is 2.3.4 released?
Usage Scenario
No response
Related issues
No response
Are you willing to submit a PR?

[ ] Yes I am willing to submit a PR!

Code of Conduct

[X] I agree to follow this project's Code of Conduct

Did you get answer from community?


Test that the jj2 are valid syntax

It would be good to have some tests to confirm that the jj2 templates are valid, run by Travis CI.
Probably worth using (improving?) moban to perform that check, so that the same check can be easily run on the templates in each project.

Agreed. It is a good idea.


Add a deviation to accept when dequeue deletes are not counted as drops

Pull Request Test Coverage Report for Build<PHONE_NUMBER>

0 of 0   changed or added relevant lines in 0 files are covered.
No unchanged relevant lines lost coverage.
Overall coverage remained the same at 55.385%

Totals

Change from base Build<PHONE_NUMBER>:
0.0%

Covered Lines:
1188

Relevant Lines:
2145

💛  - Coveralls

Please update test code in OTG folder as well.
feature/qos/otg_tests/mixed_sp_wrr_traffic_test/mixed_sp_wrr_traffic_test.go

/gcbrun

/gcbrun


Temporary issue: installing @emotion/core breaks things

For now I decided to use Chakra UI to build the interface, and it might even stay that way because Chakra is awesome. However there's one tiny issue: if you add @emotion/core to your deps, things will break, and I can't even wrap my head around exactly how. See this issue: https://github.com/chakra-ui/chakra-ui/issues/2414.
There are two paths out of this: either I find a way for r3e's deps to stop leaking, or I replace the UI with a different solution. This will all happen before 1.0.0. If you happen to know how all of this works and how exactly things are breaking, and what bandaid I can apply, if any until Chakra fixes this, please let me know. 🙏
For now, however, I will keep using Chakra simply because it allows me to move extremely fast.

Update
It doesn't look like there is a good way to depend on emotion in a way that we can guarantee that it won't burden r3e's users.
To have a design system that is completely isolated from the outside, and maintainable at the same time, I think the best solution would be to use Reakit with tailwind. Tailwind provides a system UI-like theming API with design tokens, while being entirely static CSS, and Reakit provides low level primitives for functionality and accessibility.

Sounds good. I couldn't use this precisely because of that issue.

@MioQuispe this should be done in a day or two, I'm already working on it. Please keep an eye on the pre-releases.

@MioQuispe this should be fixed in the 0.7.2 prerelease.


recorded video is corrupted

Checked FAQ
Checked  open Issues
Environment
OS: Windows 11
Scrcpy version: 2.5
Installation method: Windows release/ through choco
Device model: infix and mia2
Android version: Android 11
Describe the bug
I'm using this scrcpy to record the device screen in mp4 format, but without the floating window(--no-window),   and terminating the scrcpy.exe by their PID(taskkill /PID ).  if i do this, the recorded video is corrupted. instead if i close by clicking the close button or by killing the process by removing the --no-window flag then i can play the video.
This issue happens only in MS Windows and works fine in Linux.
But i want to record the video without the the window showing and if possible please provide gracefully closing option from cli
here is a code snippet how i used:
issue causing snippet=>  exec(scrcpy  --record=video.mp4 --max-fps 15 --max-size 480  --no-window, (error, _stdout) => {
console.log("recording....")
}
working snippet =>
issue causing snippet=>  exec(scrcpy  --record=video.mp4 --max-fps 15 --max-size 480 , (error, _stdout) => {
console.log("recording....")
}
and here is the code how i find PIDs and killing them =>
    function stopScrcpy() {
        const findPIDs = spawn('tasklist', ['/FI', 'IMAGENAME eq scrcpy.exe']);
        let output = '';
        let errorOutput = '';
        findPIDs.stdout.on('data', (data) => {
            output += data.toString();
        });
        findPIDs.stderr.on('data', (data) => {
            errorOutput += data.toString();
        });
        findPIDs.on('close', (code) => {
            if (code !== 0) {
                console.error(`Error finding PIDs: ${errorOutput}`);
                return;
            }
            const pids = output.match(/(\d+)\s+Console\s+\d+\s+[\d,]+ K/g)
                .map(match => match.split(/\s+/)[0]);
            if (pids.length === 0) {
                console.log('No scrcpy.exe processes found');
                return;
            }
            pids.forEach(pid => {
                const killProcess = spawn('taskkill', ['/PID', pid]);
                killProcess.stdout.on('data', (data) => {
                    console.log(`stdout for PID ${pid}: ${data}`);
                });
                killProcess.stderr.on('data', (data) => {
                    console.error(`stderr for PID ${pid}: ${data}`);
                });
                killProcess.on('close', (code) => {
                    if (code === 0) {
                        console.log(`PID ${pid} terminated successfully`);
                    } else {
                        console.log(`taskkill process for PID ${pid} exited with code ${code}`);
                    }
                });
                killProcess.on('error', (error) => {
                    console.error(`Error stopping PID ${pid}: ${error.message}`);
                });
            });
        });
        findPIDs.on('error', (error) => {
            console.error(`Error finding PIDs: ${error.message}`);
        });
  }

i find PIDs and killing them

If you kill the process abruptly, the muxer will never have a chance to write the footer, so your mp4 will be corrupted. Although it would still be incorrect for Matroska files (mkv), the resulting files should still be playable).
You must send Ctrl+C on Windows instead to interrupt (and never close the cmd console by clicking the X, it would kill abruptly).

Can we save the currently recorded video when an exception occurs, such as exiting? That should solve the problem

The problem lies in saving the video correctly. Currently, I can obtain a playable video only by manually closing the scrcpy application using the X button. However, if I hide the scrcpy window using the --no-window option, I have to terminate the scrcpy processes either by their PID or by using Ctrl+C, both of which result in a corrupted video.

Can we save the currently recorded video when an exception occurs, such as exiting? That should solve the problem

The problem lies in saving the video correctly. Currently, I can obtain a playable video only by manually closing the scrcpy application using the X button. However, if I hide the scrcpy window using the --no-window option, I have to terminate the scrcpy processes either by their PID or by using Ctrl+C, both of which result in a corrupted video.

I hide the scrcpy window using the --no-window option, I have to terminate the scrcpy processes either by their PID or by using Ctrl+C, both of which result in a corrupted video.

Using Ctrl+C from the terminal should work correctly, without corrupting video.
If it does not (I cannot test currently), this is a bug. If so, please test v2.4 (before --no-window was added) to confirm.

I hide the scrcpy window using the --no-window option, I have to terminate the scrcpy processes either by their PID or by using Ctrl+C, both of which result in a corrupted video.

Using Ctrl+C from the terminal should work correctly, without corrupting video.
If it does not (I cannot test currently), this is a bug. If so, please test v2.4 (before --no-window was added) to confirm.

it seems there is issue with <cntrl+c> itself,  here are the reference videos that could help analyze.
tested with version 2.5 : v2.5.webm
tested with version 2.4: v2.4.webm

Could you please test with scrcpy v2.0, which uses an older SDL version?

Could you please test with scrcpy v2.0, which uses an older SDL version?

i tried with version 2.0. but the results are same.
here are the logs, you can see first time i terminated with <cntrl+c> and second one i terminated with close button.
C:\Users\sanji\poc\Videos>scrcpy --record=video1_v2.mp4
scrcpy 2.0 <https://github.com/Genymobile/scrcpy>

daemon not running; starting now at tcp:5037
daemon started successfully
C:\ProgramData\chocolatey\lib\scrcpy\tools\scrcpy-win64-v2...1 file pushed, 0 skipped. 7.9 MB/s (52867 bytes in 0.006s)
[server] INFO: Device: INFINIX MOBILITY LIMITED Infinix X682B (Android 10)
[server] WARN: Audio disabled: it is not supported before Android 11
INFO: Recording started to mp4 file: video1_v2.mp4
INFO: Renderer: direct3d
WARN: Demuxer 'audio': stream explicitly disabled by the device
WARN: Audio stream recording disabled
INFO: Initial texture: 720x1640

C:\Users\sanji\poc\Videos>scrcpy --record=video2_v2.mp4
scrcpy 2.0 <https://github.com/Genymobile/scrcpy>
C:\ProgramData\chocolatey\lib\scrcpy\tools\scrcpy-win64-v2... file pushed, 0 skipped. 99.5 MB/s (52867 bytes in 0.001s)
[server] INFO: Device: INFINIX MOBILITY LIMITED Infinix X682B (Android 10)
[server] WARN: Audio disabled: it is not supported before Android 11
INFO: Recording started to mp4 file: video2_v2.mp4
INFO: Renderer: direct3d
WARN: Demuxer 'audio': stream explicitly disabled by the device
WARN: Audio stream recording disabled
INFO: Initial texture: 720x1640
INFO: Recording complete to mp4 file: video2_v2.mp4
WARN: Killing the server...
you can observer,   if i do <cntrl+c>  i'm not getting these "INFO: Recording complete to mp4 file: video2_v2.mp4
WARN: Killing the server..." s
o it leads to corrupted videos.

OK, I can't explain why Ctrl+c does not work as expected on your machine. Scrcpy explicitly catches Ctrl+c on Windows):
https://github.com/Genymobile/scrcpy/blob/bbfac9ae1fba08a045557abe9612703ace8a3890/app/src/scrcpy.c#L149
Maybe a cmd.exe configuration or something?

OK, I can't explain why Ctrl+c does not work as expected on your machine. Scrcpy explicitly catches Ctrl+c on Windows:
https://github.com/Genymobile/scrcpy/blob/bbfac9ae1fba08a045557abe9612703ace8a3890/app/src/scrcpy.c#L149
Maybe a cmd.exe configuration or something?

Thank you  @rom1v  for your help and quick responses to my comments. I appreciate your time and support. I'll try to  figure out the issue.

好吧，我无法解释为什么 Ctrl+c 在你的机器上不能按预期工作。Scrcpy 在 Windows 上明确捕获了 Ctrl+c：
https://github.com/Genymobile/scrcpy/blob/bbfac9ae1fba08a045557abe9612703ace8a3890/app/src/scrcpy.c#L149
也许是 cmd.exe 配置或者别的什么？

谢谢 @rom1v 感谢您的帮助和对我评论的快速回复。感谢您的时间和支持。我会尽力解决问题。

Hello, have you solved your problem? I have this problem now

Interesting. I don't know why. I re-tested, for me it works as expected, I have Recording complete to mp4 file: file.mp4 at the end when I Ctrl+c.

It you run
scrcpy -Vverbose --no-window --record=file.mp4

then Ctrl+c, what's the full output?

C:\Users\I5343\Pictures>scrcpy -Vverbose --no-window --record=file.mp4
scrcpy 2.5 <https://github.com/Genymobile/scrcpy>

daemon not running; starting now at tcp:5037
daemon started successfully
INFO: ADB device found:
INFO:     -->   (usb)<PHONE_NUMBER>021085                device  Infinix_X682B
DEBUG: Device serial:<PHONE_NUMBER>021085
DEBUG: Using server (portable): C:\ProgramData\chocolatey\lib\scrcpy\tools\scrcpy-server
C:\ProgramData\chocolatey\lib\scrcpy\tools\scrcpy-server: 1 file pushed, 0 skipped. 39.6 MB/s (69624 bytes in 0.002s)
[server] INFO: Device: [INFINIX MOBILITY LIMITED] Infinix Infinix X682B (Android 10)
[server] WARN: Audio disabled: it is not supported before Android 11
[server] DEBUG: Audio encoder stopped
DEBUG: Server connected
DEBUG: Demuxer 'video': starting thread
DEBUG: Demuxer 'audio': starting thread
WARN: Demuxer 'audio': stream explicitly disabled by the device
WARN: Audio stream recording disabled
INFO: Recording started to mp4 file: file.mp4
[server] DEBUG: Using video encoder: 'OMX.MTK.VIDEO.ENCODER.AVC'
[server] DEBUG: Display: using SurfaceControl API
DEBUG: Us

i have attached reference video also, with and without --no-window command
vid2.webm
vid1.webm

Thank you. I guess this is the same with the Windows release (instead of the chocolatey package)?
Something probably intercepts Ctrl+c at the system level and kills the process. Any antivirus/firewall/something enabled?

好吧，我无法解释为什么 Ctrl+c 在你的机器上不能按预期工作。Scrcpy 在 Windows 上明确捕获了 Ctrl+c：
https://github.com/Genymobile/scrcpy/blob/bbfac9ae1fba08a045557abe9612703ace8a3890/app/src/scrcpy.c#L149
也许是 cmd.exe 配置或者别的什么？

谢谢 @rom1v 感谢您的帮助和对我评论的快速回复。感谢您的时间和支持。我会尽力解决问题。

Hello, have you solved your problem? I have this problem now

hello, i have a temporary solution for this, i tried killing process gracefully, it worked. I'm dropping the code below, this might be helpful.
code: "@echo off
setlocal
set SCRCPY_BINARY=scrcpy.exe
set OUTPUT_FILE=output.mp4
set PID_FILE=%TEMP%\scrcpy_record_%RANDOM%.pid
set LOG_FILE=%TEMP%\scrcpy_record_%RANDOM%.log
:CHECK_EXISTING_PROCESSES
rem Kill any existing scrcpy processes before starting
for /f "skip=1 tokens=2" %%a in ('tasklist /fi "imagename eq scrcpy.exe" /fo csv /nh') do (
echo %%a > %PID_FILE%
set PID=%%a
echo Killing process with PID: %%a
taskkill /PID %%a /F >nul 2>&1
timeout /T 2 /NOBREAK >nul
)
:START
if "%1"=="start" (
echo Starting recording...
start "" /B "%SCRCPY_BINARY%" --no-control --max-size 480 --record %OUTPUT_FILE% > %LOG_FILE% 2>&1
timeout /T 2 /NOBREAK >nul
for /f "skip=1 tokens=2" %%a in ('tasklist /fi "imagename eq scrcpy.exe" /fo csv /nh') do (
echo %%a > %PID_FILE%
set PID=%%a
)
if defined PID (
echo Recording started. PID: %PID%
) else (
echo Failed to start recording or capture PID.
)
exit /b 0
)
:STOP
if exist %PID_FILE% (
@echo off
setlocal enabledelayedexpansion
:: Initialize a counter
set count=0
:: Loop through the tasklist output
for /f "tokens=2 delims=," %%i in ('tasklist /FI "IMAGENAME eq scrcpy.exe" /FO CSV /NH') do (
set /a count+=1
if !count! equ 2 (
:: Print the PID of the second process
echo Terminating process with PID: %%i
:: Kill the process
taskkill /PID %%i
:: Exit the script
exit /b
)
)
:: Inform if no second process was found
echo No second scrcpy.exe process found.
if exist %OUTPUT_FILE% (
echo Recording stopped. Check %OUTPUT_FILE% for the recording.
) else (
echo No output file found. Check %LOG_FILE% for errors.
)
) else (
echo No recording process found.
)
endlocal
exit /b 0"
1: save the file with .bat extension.
2: in cmd,  cd C:\path\to\your\script.bat
3:if required, do this    chmod +x script.bat
4: script.bat start/stop
reference video:
scriptvideo.webm

Is it powershell or cmd?

cmd

Thank you. I guess this is the same with the Windows release (instead of the chocolatey package)?
Something probably intercepts Ctrl+c at the system level and kills the process. Any antivirus/firewall/something enabled?

yes, in both the ways i tried installing scrcpy, same results.

cmd

What's your terminal?
When I run cmd.exe, it does not look like this at all.

cmd

What's your terminal?
When I run cmd.exe, it does not look like this at all.

strange!, i use normal command prompt only (cmd)

It looks like this: https://upload.wikimedia.org/wikipedia/commons/b/b3/Command_Prompt_on_Windows_10_RTM.png

cmd

What's your terminal?
When I run cmd.exe, it does not look like this at all.

strange!, i use normal command prompt only (cmd)

i tried in  all these, 1: Win+r  : cmd.exe. but there was no betterment.

It looks like this:

its only a UI difference(might be difference in OS version or laptop vendor),but in windows there will be only one command prompt and it work same for everyone right.

Non only, this terminal is also "limited" (it cannot be resized for example), but above all it probably correctly sends Ctrl+c to the running process.

Non only, this terminal is also "limited" (it cannot be resized for example), but above all it probably correctly sends Ctrl+c to the running process.

vid.webm

OK, I don't know Windows very well, but IMO the behavior of Ctrl+c is definitely handled differently in your "terminal" app (whichever it is).

OK, I don't know Windows very well, but IMO the behavior of Ctrl+c is definitely handled differently in your "terminal" app (whichever it is).
EDIT: I guess your app is Windows Terminal: https://apps.microsoft.com/detail/9n0dx20hk701

yes, but you can see in the above video, i tried opening a new cmd tab from windows terminal and ran the given command.

If you manage to start the "old" cmd terminal in some way and confirm that Ctrl+c works, it might be interesting to report the issue to https://github.com/microsoft/terminal

As Windows 11 is now widely used, it would be helpful if you could provide a way to start and stop 'scrcpy.exe' directly from the command line interface (CLI) without requiring additional steps. This would ease the process for users.
Thanks again for your time and assistance @rom1v.

Could please test scrcpy 2.7, and execute:
scrcpy --record=file.mp4

Then interrupt with Ctrl+c.
Confirm that the process terminates abruptly without Recording complete to mp4 file: file.mp4, and that the file is corrupted.
Then, replace scrcpy.exe by this version:
diff
diff --git a/app/src/scrcpy.c b/app/src/scrcpy.c
index 854657fbd..1ad0d1f0d 100644
--- a/app/src/scrcpy.c
+++ b/app/src/scrcpy.c
@@ -150,6 +150,16 @@ sdl_configure(bool video_playback, bool disable_screensaver) {
     if (!ok) {
         LOGW("Could not set Ctrl+C handler");
     }
+    HANDLE hStdin = GetStdHandle(STD_INPUT_HANDLE);
+    DWORD mode;
+    if (GetConsoleMode(hStdin, &mode)) {
+        mode |= ENABLE_PROCESSED_INPUT;
+        if (!SetConsoleMode(hStdin, mode)) {
+            LOGW("Could not set console mode");
+        }
+    } else {
+        LOGW("Could not get console mode");
+    }
 #endif // _WIN32

     if (!video_playback) {

scrcpy.exe SHA-256: 0c39c87f9ee71c85600983911aaae82b48db5776b2c80cf7a8f4a518c1a15af

And confirm that it works correctly.

@vinayhatyal Could you please test?


feat(toDash): Add option to include thumbnails in the manifest

The DASH spec allows manifests to provide thumbnails, the most common use case for them is showing a preview when seeking with the seekbar. Players like shaka and DASH.js don't have a built-in UI for them, but they do parse them and provide APIs to get the thumbnail for a given timestamp, Player#getThumbnails and MediaPlayer#provideThumbnail respectively.
I decided to make this feature opt-in with a setting for the toDash function, as it requires making a few HEAD requests to get the content length, to approximate the bandwidth for the storyboards and it's not supported by all players/they don't provide a built-in UI for them. Sticking it behind an option allows people that can and want to use it, to use it without slowing the manifest generation down for everyone else.
I will create a separate pull request after this is merged (to avoid merge conflicts), to add captions/subtitles to the manifests, those require making requests too and it doesn't make sense to include both WebVTT and TTML captions, if you know your player only supports one of them.

Haven't reviewed this completely yet but the toDash fn implementation should be go in MediaInfo so we can avoid all that duplicate code (plus the burden of having to modify all of them if say, we add another parameter).
https://github.com/LuanRT/YouTube.js/blob/7e5c3648c1f7bd0876ad38039d283c948f23d52c/src/core/mixins/MediaInfo.ts#L42-L44

Unfortunately YouTube Kids doesn't provide any storyboads, so the storyboards properties are on the YouTube Music TrackInfo and YouTube VideoInfo classes, so we can't really move that up into MediaInfo as the properties it needs to read don't exist there. (well we could probably do it in pure javascript, as the properties would exist at runtime, but typescript doesn't like that kind of stuff).

We'll have the same issue with captions, as both YouTube and YouTube Kids provide them but YouTube music doesn't, at least not on the TrackInfo object.

Yes I am aware, but can't we just throw an error if someone tries using MediaInfo#toDash with that option set to true but the required data doesn't exist? At least we'd get to keep the function signature the same across all VideoInfo-like classes.
I really doubt anybody is going to use that option by accident, unless they're mixing youtube+youtube music+youtube kids.

Also, you do have access to the MediaInfo#page, which contains the parsed response. Both /player and /next responses.

Move the toDash implementation to just be in the MediaInfo class again, thanks for the suggestion!

Perfect. Awesome work as always! Thank you.


[SPARK-6511] [docs] Fix example command in hadoop-provided docs.

@pwendell

Merged build triggered.

Merged build started.

Test build #34709 has started for   PR 6766 at commit 49f0f67.

LGTM thanks @vanzin!

Test build #34709 has finished for   PR 6766 at commit 49f0f67.

This patch passes all tests.
This patch merges cleanly.
This patch adds no public classes.

Merged build finished. Test PASSed.

Merged!


Created database and comment section with API's on portolio

Added images to portfolio website
Added database on website for comments
Added Javascript/HTML to show comments
Added Javascript for Map API
Added HTML elements for MAp API
PERSISTENT ISSUES:
None of the API's show up (Might be project issue)

Did you mean to assign a reviewer to this PR? It looks like this PR has a lot of the same commits as the other PR.

The last 3 commits are in this branch and #4 — you should revert these commits from this branch.


Bug: Disconnected network drives aren't displayed

Description
Disconnected network mapped drives disappear from the app making it impossible to reconnect the mapped drive from the Files app. Only way to reconnect is by doing it through Windows Explorer.
Steps To Reproduce

Have a mapped drive disconnect from your system. (Typically for me it gets disconnected if I put my laptop to sleep or bring it from one network to another).
In windows explorer it will show that it's now disconnected and will allow you to reconnect, while in the Files app it disappears completely.

Steps to fix
Open the default Windows Explorer and then you will be able to see the disconnected mapped drive there and reconnect. Upon reconnection the mapped drive will show up in Files app.
Files Version
Version: <IP_ADDRESS> OS Version: 10.0.25267.1000
Windows Version
Windows 11 22H2
Relevant Assets/Logs
Windows Explorer Disconnected Map Drive

Files App Disconnected Map Drive

@ArtexJay do you have the network drive section enabled?

@ArtexJay do you have the network drive section enabled?

There is a network drive section, its not hidden in the files app.

The issue is resolved, i haven't encountered any problems now.

@ArtexJay what did you do to resolve it?


How to reset to frame 0 after gif is played with AnimatedGif

Hello there,
What is the best way to  reset the gif to zero frame after completing playing it? here is the code I have so far:
AnimatedImage(url: URL(string: selectedArticle.imageName), placeholderImage: .init(systemName: "Pic 7"))
.customLoopCount(1)
.runLoopMode(.common)
.transition(.fade)

Emmm.
Can you try using the "pausable" modifier ? I think if the gif play ended with last frame is normal behavior
Actually, this internal UIKit view(SDAnimatedImageView) has API to seek to any frame index if you want.
You can grab the native UIKit view via "onViewUpdate" API and call the API


Improving k8s 1.25 compatibility for rancher/chart

Issue:
#41455
Problem
The current default for global.cattle.psp.enabled is not compatible with k8s 1.25. This requires users to manually set this value to false when installing on this version of k8s. As 1.25+ is becoming more widely adapted, this pain point will become more apparent for our users.
Solution

There is no default for global.cattle.psp.enabled (i.e. the default value is "").

If this value is "" and the cluster does not support PSPs (i.e. is k8s version 1.25 or higher), then PSPs will not be used.
If this value is "" and the cluster does support PSPs (i.e. is k8s version 1.24 or lower), then PSPs will be used.

If the value is set to true, no capabilities check will be used, and the chart will attempt to use PSPs. This will cause the above error message for k8s 1.25 clusters.
If the value is set to false, no capabilities check will be used, and the chart will not attempt to use PSPs.

The changes to the chart caused our charts tests to fail, since it used the lookup function (to determine if there is an active k8s cluster this is running against), which our old fork doesn't appear to support. To resolve this, I refactored our tests and our CI to use the upstream unittest plugin
Testing
Repro steps are valid.
Engineering Testing
Manual Testing
Basic helm template and helm install cases were done, but more will need to be re-tested here.
Automated Testing
I added tests for the chart when global.cattle.psp.enabled is set to:

True
False
Unset
Set to an invalid value

These tests do not cover the "live cluster cases" since the helm-unittest framework does not appear to offer the ability to mock out the lookup functionality.

I believe we should move to helm_v3 for this so we use the latest and supported version of Helm instead of Helm 2


Dep ZSH plugin

I've created a ZSH plugin for Dep.

Thanks so much, this is great!

I suppose we should add a community contributions section, or something...

Might be worth showing them that there's a demand for it.


Refactor Wifi Config & Backup

see #4384

tested good on my machines

Tested the wifi file worked well when recovering an RPi5 node


Multiple modern search extension in the tenant but I see the wrong search layout with the correct data until I refresh

We have more than one extension created, one for forms and one for FAQs. When I go to the FAQs page, I can see the FAQs pnp search extension/layout but when I go to the forms page, I can see the FAQs extension I need to do a hard refresh and then I see the Forms pnp search extension.
https://github.com/PDSB-sps/FAQ-PnP-Search-Ext - the FAQ extension
https://github.com/PDSB-sps/DeptFormsPnPSearch - the forms extension
I don't know why this is being cached, how can I stop this from happening? It caches that search layout to the next page, and you need to do a hard reset on the page, and it displays the correct layout.  Why is this caching of the layout happening?  Also, the very weird thing is it displays the correct data but the wrong layout.
Step 1 - FAQ page

Step 2 - forms page

Step 3 -refresh on the forms page

I cannot expect that the user would refresh the page to see the correct data.

Issue will be closed unless the issue layout is used.


Add Environment Variables

The Environment variables will be available from the pipeline in Tekton and they should be available to be used.
export APP_NAME='checkout'
export BRANCH_NAME='master'
export BUILD_NUMBER='26'
export DOMAIN='devx.io'
export GIT_BRANCH='master'
export PIPELINE_KIND='release'
export REPO_NAME='checkout'
export REPO_OWNER='XXX-XXX'
export VERSION='0.6.19'

Hey, @bradmccoydev can I work on this issue?


Radial Menu Icon "Reset Fog of War" shares same definition as "Set always Invisible"

There is no entry in the .xml and no button to be found in the graphics folders of core rpg.

It looks like that menu is hardcoded into Fantasy Grounds; I can't find any reference to those icons in CoreRPG. We'll likely have to request that these icons be separated.

Hardcoded for now.


ntfy: restructure to be a Python package

Description of changes

This allows us to access ntfy built with a specific Python interpreter more easily (and thus swapping the Python interpreter uses).
This also splits out the things which are ntfy optional dependencies so that they can be disabled - in particular, sleekxmpp is broken on Darwin and because of the way the package is designed at the moment it isn't possible to turn it off.
e.g. this allows you to use ntfy with python3.10 as long as you disable XMPP support.
This also fixes things on Darwin which don't work, like Slack support. And XMPP support.
Things done

Built on platform(s)

[x] x86_64-linux
[ ] aarch64-linux
[ ] x86_64-darwin
[x] aarch64-darwin

[ ] For non-Linux: Is sandbox = true set in nix.conf? (See Nix manual)
[ ] Tested, as applicable:

NixOS test(s) (look inside nixos/tests)
and/or package tests
or, for functions and "core" functionality, tests in lib/tests or pkgs/test
made sure NixOS tests are linked to the relevant packages

[ ] Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage
[x] Tested basic functionality of all binary files (usually in ./result/bin/)
22.11 Release Notes (or backporting 22.05 Release notes)

[ ] (Package updates) Added a release notes entry if the change is major or breaking
[ ] (Module updates) Added a release notes entry if the change is significant
[ ] (Module addition) Added a release notes entry if adding a new NixOS module
[ ] (Release notes changes) Ran nixos/doc/manual/md-to-db.sh to update generated release notes

[x] Fits CONTRIBUTING.md.

This does not at all fit with the contributing guidelines for Python packages. Please read that section in the Nixpkgs manual as well as the header of the python-packages.nix file.

Oh, you're right. The suggested packaging is awful but I guess it's what the documentation says, so I'll leave this broken as-is.


Use java-shared-dependencies/third-party-dependencies where possible

We should add an import-scoped java-shared-dependencies/third-party-dependencies entry in the dependency-management section of java-core's pom.xml, remove the associated version declarations in java-core, and consider offloading any remaining third-party dependency versions to third-party-dependencies.

In google-cloud-java, java-core uses the shared dependencies BOM, which imports third-party-dependencies.


Caching issue when using deferred load on the web

Is there an existing issue for this?

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

Steps to reproduce
When using deferred load the compiler breaks js code into chunks such as main.dart.js_XX.part.js; this naming remains the same after deploying a new version, hence causing browser to keep reusing cached version. In case of main.dart.js and flutter_service_worker.js  it's possible to add version string manually, such as "/main.dart.js?v=" + serviceWorkerVersion, but not for dynamically loaded scripts. In particular the issue concerns dictionaries; for instance this code generates fixed names:
import 'messages_AA.dart' deferred as messages_AA;
...
import 'messages_ZZ.dart' deferred as messages_ZZ;

We need a mechanism that would trigger re-caching of changed chunks - ideally based on file hash so that only really changed content would re-cache.
Expected results
After code or dictionary change corresponding content should be re-cached by browsers.
Actual results
Browsers keep using obsolete cached version unless the page is explicitly refreshed.
Code sample
Code sample
import 'messages_AA.dart' deferred as messages_AA;
...
import 'messages_ZZ.dart' deferred as messages_ZZ;

Screenshots or Video

Screenshots / Video demonstration
[Upload media here]

Logs
Logs
[Paste your logs here]

Flutter Doctor output
Doctor output
[Paste your output here]

I also encountered this problem

Thanks for the report @dmitry-fbm
Can you take a look at this issue and underlying comments to check if it resembles your case or not ?

Can you take a look at this issue and underlying comments to check if it resembles your case or not ?

@darshankawar yes thank you. Sorry for duplicate, missed that one. Same thing, also had DeferredLoadException in logs.

Thanks for confirming. Closing as duplicate.


Interpolate Consul service health checks.

Similar to the request in #58, this patch adds the interpolation of
service IPs and ports for Consul's SERVICE_CHECK_SCRIPT using the
placeholders, SERVICE_PORT and SERVICE_IP:
SERVICE_CHECK_SCRIPT=nc $SERVICE_IP $SERVICE_PORT | grep OK
To keep things simple, each check is specific only to the service in
question; specifically, the check does not have a full view of the
container and all of its ports.

Great!


⚠ Bofrost.com has degraded performance

In dd99f9e, Bofrost.com (https://www.bofrost.com) experienced degraded performance:

HTTP code: 200
Response time: 5416 ms

Resolved: Bofrost.com performance has improved in 636c4c6 after 10 minutes.