Jest complains about non-existent obsolete snapshots which it fails to remove

🐛 Bug Report
We can't figure out why this is happening on this PR https://github.com/zowe/zowe-cli/pull/366.
Running the unit tests fails because it says there are 7 obsolete snapshot files. However, when you try to use the -u  flag on jest, we get failure messages complaining that jest could not delete some .snap files, which don't exist. I don't know how it is determining that there are obsolete snapshots. Confusingly, it also tried to delete more than seven files. This has happened on at least four different machines checking out the branch of the below repo
Sorry I don't have a more minimal example, but since I don't know what is causing it I can't make another example. Hopefully we are just missing something simple, but it doesn't seem jest is working as intended
Example output:
 FAIL  packages/zosfiles/__tests__/api/methods/download/Download.unit.test.ts
  ● Test suite failed to run

    ENOENT: no such file or directory, unlink 'C:\nodejs\zowe-cli\packages\zosfiles\__tests__\api\methods\download\__snapshots__\Download.unit.test.ts.snap'

      at SnapshotState.save (node_modules/jest-snapshot/build/State.js:114:21)

 FAIL  packages/zosfiles/__tests__/api/methods/delete/Delete.unit.test.ts
  ● Test suite failed to run

    ENOENT: no such file or directory, unlink 'C:\nodejs\zowe-cli\packages\zosfiles\__tests__\api\methods\delete\__snapshots__\Delete.unit.test.ts.snap'

      at SnapshotState.save (node_modules/jest-snapshot/build/State.js:114:21)

 FAIL  packages/zosfiles/__tests__/cli/upload/Upload.definition.unit.test.ts
  ● Test suite failed to run

    ENOENT: no such file or directory, unlink 'C:\nodejs\zowe-cli\packages\zosfiles\__tests__\cli\upload\__snapshots__\Upload.definition.unit.test.ts.snap'

      at SnapshotState.save (node_modules/jest-snapshot/build/State.js:114:21)

 FAIL  packages/zosconsole/__tests__/IssueCommand.unit.test.ts
  ● Test suite failed to run

    ENOENT: no such file or directory, unlink 'C:\nodejs\zowe-cli\packages\zosconsole\__tests__\__snapshots__\IssueCommand.unit.test.ts.snap'

      at SnapshotState.save (node_modules/jest-snapshot/build/State.js:114:21)

 FAIL  packages/workflows/__tests__/cli/archive/workflow/Archive.workflow.handler.unit.test.ts
  ● Test suite failed to run

    ENOENT: no such file or directory, unlink 'C:\nodejs\zowe-cli\packages\workflows\__tests__\cli\archive\workflow\__snapshots__\Archive.workflow.handler.unit.test.ts.snap'

      at SnapshotState.save (node_modules/jest-snapshot/build/State.js:114:21)

 FAIL  packages/zosconsole/__tests__/CollectCommand.unit.test.ts
  ● Test suite failed to run

    ENOENT: no such file or directory, unlink 'C:\nodejs\zowe-cli\packages\zosconsole\__tests__\__snapshots__\CollectCommand.unit.test.ts.snap'

      at SnapshotState.save (node_modules/jest-snapshot/build/State.js:114:21)

 FAIL  packages/zostso/__tests__/api/PingTso.unit.test.ts
  ● Test suite failed to run

    ENOENT: no such file or directory, unlink 'C:\nodejs\zowe-cli\packages\zostso\__tests__\api\__snapshots__\PingTso.unit.test.ts.snap'

      at SnapshotState.save (node_modules/jest-snapshot/build/State.js:114:21)

 FAIL  packages/zosfiles/__tests__/cli/delete/uss/Uss.handler.unit.test.ts
  ● Test suite failed to run

    ENOENT: no such file or directory, unlink 'C:\nodejs\zowe-cli\packages\zosfiles\__tests__\cli\delete\uss\__snapshots__\Uss.handler.unit.test.ts.snap'

      at SnapshotState.save (node_modules/jest-snapshot/build/State.js:114:21)

 FAIL  packages/utils/__tests__/CoreUtils.unit.test.ts
  ● Test suite failed to run

    ENOENT: no such file or directory, unlink 'C:\nodejs\zowe-cli\packages\utils\__tests__\__snapshots__\CoreUtils.unit.test.ts.snap'

      at SnapshotState.save (node_modules/jest-snapshot/build/State.js:114:21)

 FAIL  packages/workflows/__tests__/cli/delete/deleteArchivedWorkflow/Delete.archived.common.handler.unit.test.ts
  ● Test suite failed to run

    ENOENT: no such file or directory, unlink 'C:\nodejs\zowe-cli\packages\workflows\__tests__\cli\delete\deleteArchivedWorkflow\__snapshots__\Delete.archived.common.handler.unit.test.ts.snap'

      at SnapshotState.save (node_modules/jest-snapshot/build/State.js:114:21)

 FAIL  packages/zosconsole/__tests__/ConsoleResponseService.unit.test.ts
  ● Test suite failed to run

    ENOENT: no such file or directory, unlink 'C:\nodejs\zowe-cli\packages\zosconsole\__tests__\__snapshots__\ConsoleResponseService.unit.test.ts.snap'

      at SnapshotState.save (node_modules/jest-snapshot/build/State.js:114:21)

 FAIL  packages/zosfiles/__tests__/cli/invoke/Invoke.definition.unit.test.ts
  ● Test suite failed to run

    ENOENT: no such file or directory, unlink 'C:\nodejs\zowe-cli\packages\zosfiles\__tests__\cli\invoke\__snapshots__\Invoke.definition.unit.test.ts.snap'

      at SnapshotState.save (node_modules/jest-snapshot/build/State.js:114:21)

 FAIL  packages/zosfiles/__tests__/cli/delete/uss/Uss.definition.unit.test.ts
  ● Test suite failed to run

    ENOENT: no such file or directory, unlink 'C:\nodejs\zowe-cli\packages\zosfiles\__tests__\cli\delete\uss\__snapshots__\Uss.definition.unit.test.ts.snap'

      at SnapshotState.save (node_modules/jest-snapshot/build/State.js:114:21)

 FAIL  packages/provisioning/__tests__/api/ProvisionPublishedTemplate.unit.test.ts
  ● Test suite failed to run

    ENOENT: no such file or directory, unlink 'C:\nodejs\zowe-cli\packages\provisioning\__tests__\api\__snapshots__\ProvisionPublishedTemplate.unit.test.ts.snap'

      at SnapshotState.save (node_modules/jest-snapshot/build/State.js:114:21)

To Reproduce
clone https://github.com/matthewpwilson/zowe-cli
checkout branch upload-lts
npm i --@brightside:registry=https://api.bintray.com/npm/ca/brightside
npm run test:unit   or npm run test:unit -- -u
Expected behavior
Jest should not say there are obsolete snapshots, or else it should be able to delete them if they exist
Link to repl or repo (highly encouraged)
https://github.com/matthewpwilson/zowe-cli/tree/upload-lts
Run npx envinfo --preset jest
Paste the results here:
  System:
    OS: Windows 7
    CPU: (8) x64 Intel(R) Core(TM) i7-4810MQ CPU @ 2.80GHz
  Binaries:
    Node: 10.15.0 - C:\Program Files\nodejs\node.EXE
    npm: 6.4.1 - C:\nodejs\zowe-cli\node_modules\.bin\npm.CMD

This was happening to me because I was mocking fs.existsSync and forgot to call jest.resetAllMocks() after. Looks like you have the same problem

Thanks Nitive. That solved the problem for me

Had the same problem, can confirm it's because I was mocking fs and didn't call jest.resetAllMocks. Thanks guys for the tip!


static plotting for spatial data

IMPORTANT: Please search among the Pull requests before creating one.
Description
Static plotting for spatial data (extending scanpy.pl.spatial)
TODO

[x] add segmentation plotting capabilities #427
[ ] add some type of behaviour for alpha in continuous values. The reason for this is that if with umap you don't care to see points where the value is e.g. 0 (and you can just subset adata), in spatial you do cause you still want to see the full tissue (and this doesn't happen by proxy if you subset adata, cause it also crop the tissue). Not super sure how to handle it yet.
[x] saving
[ ] docs
[ ] tests

Ok here's a demo on what's currently doing:
import squidpy as sq

adata1 = sq.datasets.visium_hne_adata()
adata2 = adata1.copy() # copy adata
adata2.uns["spatial"] = {} # create fake new library_id
adata2.uns["spatial"]["V2_Adult_Mouse_Brain"] = adata1.uns["spatial"][
    "V1_Adult_Mouse_Brain"
]

# concat adatas putting library
adata_temp = ad.concat(
    {"V1_Adult_Mouse_Brain": adata1, "V2_Adult_Mouse_Brain": adata2},
    label="batch_key",
    uns_merge="only",
)

from squidpy.pl._spatial import spatial

spatial(
    adata_temp,
    batch_key="batch_key",
    cmap="inferno",
    shape="hex",
    size=[1.2, 1.0],
    color=["Sox17", "cluster"],
    add_outline=True,
    outline_width=(0.05, 0.05),
    crop_coord=[[1500, 2800, 1500, 2800], [1500, 2800, 1500, 2800]],
    scalebar_dx=2.0,
    scalebar_kwargs={"scale_loc": "bottom", "location": "lower right"},
)

I followed scanpy.pl.embedding module and adapted on the way. The main additions are:

it can now plot multiple library_ids (different visium slides) saved in the same adata. It essentially treats library_id the same way sc.pl.embedding treats components. This is very useful for storing everything in a single adata object.
it can plot with different shapes (added squares and hexagons), useful for e.g. dbitseq.
it can add the scale bar (important feature request).

code is messy and I'm still not super sure on the behaviour of the image-related arguments (e.g. spot size, scale factors, scalebars etc.). For now, they either have to be a single instance (e.g. a float, a str), so that that value is propagate to all slides, or a list that matches the library_id length. I think is sensible but it's also debatable. Would love to get feedback.
things that are still missing:

[ ] add segmentation plotting capabilities #427
[ ] add some type of behaviour for alpha in continuous values. The reason for this is that if with umap you don't care to see points where the value is e.g. 0 (and you can just subset adata), in spatial you do cause you still want to see the full tissue (and this doesn't happen by proxy if you subset adata, cause it also crop the tissue). Not super sure how to handle it yet.

plus ofc docs, tests etc. I'll take another look tomorrow and then request for first round of review.

Ok I think this a good stage to start testing out behaviour and overall structure. Things I'd like to get feedback on:

code structure: it follows sc.pl.embedding which can seem a bit messy (it's a big for loop) but intuitive to follow(?).
arguments: again, it follows sc.pl.embedding  but again I think it's intuitive cause people are used to arguments. They are many though and some could be grouped into kwargs, although then we'd have to find a way to explict some of them in docs in order to highlight.
anything else

Here's 2 code snippets to get started
Visium

Details
import squidpy as sq

adata1 = sq.datasets.visium_hne_adata()
adata2 = adata1.copy() # copy adata
adata2.uns["spatial"] = {} # create fake new library_id
adata2.uns["spatial"]["V2_Adult_Mouse_Brain"] = adata1.uns["spatial"][
    "V1_Adult_Mouse_Brain"
]

# concat adatas putting library
adata_temp = ad.concat(
    {"V1_Adult_Mouse_Brain": adata1, "V2_Adult_Mouse_Brain": adata2},
    label="batch_key",
    uns_merge="only",
	pairwise=True,
)

from squidpy.pl._spatial import spatial

spatial(
    adata_temp,
    batch_key="batch_key",
    cmap="inferno",
    shape="circle",
    size=[0.3, 0.5],
    color=["Sox17", "cluster"],
    edges=True,
    edges_width=5,
    add_outline=True,
    outline_width=(0.05, 0.05),
    crop_coord=[[1500, 2800, 1500, 2800], [1500, 2800, 1500, 2800]],
    scalebar_dx=2.0,
    scalebar_kwargs={"scale_loc": "bottom", "location": "lower right"},
)

Seqfish

Details
import squidpy as sq

adata_seqfish1 = sq.datasets.seqfish()
sq.gr.spatial_neighbors(adata_seqfish1)
adata_seqfish2 = adata_seqfish1.copy()

adata_seqfish = ad.concat(
    {"segfish1": adata_seqfish1, "seqfish2": adata_seqfish2},
    label="batch_key",
    uns_merge="only",
    pairwise=True,
)

from squidpy.pl._spatial import spatial

spatial(
    adata_seqfish,
    batch_key="batch_key",
    shape=None,
    cmap="inferno",
    edges=True,
    edges_width=2,
    #     shape="hex",
    size=[30, 50],
    color=["Wnt8a", "celltype_mapped_refined"],
    add_outline=True,
    outline_width=(0.2, 0.2),
    crop_coord=[[1, 2, 1, 2], [1, 2, 1, 2]],
    scalebar_dx=2.0,
    scalebar_kwargs={"scale_loc": "bottom", "location": "lower right"},
)

ok I think this is now in good shape.
TODO:

[ ] add alpha on cmap (see summary above)
[ ] check documentation
[ ] add tests (ideas how to proceed @michalk8 ? am thinking to test single functions with dummy data and then couple of instances for main spatial_ functions. Also, will need to cache couple of datasets).
[ ] make examples and tutorials

@AnnaChristina @hspitzer @ivirshup I'd really appreciate your help here. Would be great if you can try out API on couple of use cases and provide general feedback on usability+docs (can be improved I think a bit).
You can start with these couple of code snippets
Test points

Details
import squidpy as sq
from squidpy.pl._spatial import spatial_point, spatial_shape, spatial_segment

adata_seqfish1 = sq.datasets.seqfish()
sq.gr.spatial_neighbors(adata_seqfish1)
adata_seqfish2 = adata_seqfish1.copy()
adata_seqfish = ad.concat(
    {"seqfish1": adata_seqfish1, "seqfish2": adata_seqfish2},
    label="batch_key",
    uns_merge="unique",
    pairwise=True,
)

spatial_point(
    adata_seqfish,
    library_key="batch_key",
    cmap="inferno",
    edges=True,
    edges_width=2,
    size=[30, 50],
    color=["Wnt8a", "celltype_mapped_refined"],
    outline=True,
    outline_width=(0.2, 0.2),
    crop_coord=[[1, 2, 1, 2], [1, 2, 1, 2]],
    scalebar_dx=2.0,
    scalebar_kwargs={"scale_loc": "bottom", "location": "lower right"},
    #     vmin=4,
    vmax=5,
    dpi=100,
)

Test shapes

Details
import squidpy as sq
from squidpy.pl._spatial import spatial_point, spatial_shape, spatial_segment

adata1 = sq.datasets.visium_hne_adata()
sq.gr.spatial_neighbors(adata1)
adata2 = adata1.copy()
adata2.uns["spatial"] = {}
adata2.uns["spatial"]["V2_Adult_Mouse_Brain"] = adata1.uns["spatial"][
    "V1_Adult_Mouse_Brain"
]

adata_temp = ad.concat(
    {"V1_Adult_Mouse_Brain": adata1, "V2_Adult_Mouse_Brain": adata2},
    label="batch_key",
    uns_merge="unique",
    pairwise=True,
)

spatial_shape(
    adata_temp,
    cmap="inferno",
    shape="square",
    size=[1, 1.25],
    color=["Sox17", "cluster"],
    edges=True,
    edges_width=5,
    title=None,
    outline=True,
    outline_width=(0.05, 0.05),
    crop_coord=(1500, 2800, 1500, 2800),
    scalebar_dx=2.0,
    scalebar_kwargs={"scale_loc": "bottom", "location": "lower right"},
)

Test segment

Details
import squidpy as sq
from squidpy.pl._spatial import spatial_point, spatial_shape, spatial_segment

adata = sq.datasets.mibitof()
spatial_segment(
    adata,
    color=["Cluster", "cell_size"],
    groups=["Fibroblast", "Endothelial"],
    na_color=(0, 0, 0, 0),
    library_key="library_id",
    cell_id_key="cell_id",
    img=True,
    seg=True,
    seg_boundaries=True,
    seg_erosionpx=15,
    figsize=(5, 5),
    cmap="magma",
    vmin=500,
)

spatial_segment(
    adata,
    color="Cluster",
    #     groups=["Fibroblast", "Endothelial"],
    #     img_alpha=0.5,
    na_color=(0, 0, 0, 0),
    library_key="library_id",
    cell_id_key="cell_id",
    img=True,
    seg=True,
    seg_boundaries=True,
    seg_erosionpx=10,
    figsize=(5, 5),
)

We'd want to cut new release before easter and this is the biggest addition (together with spin off of napari) so would require some thorough beta testing. Thanks all 🙏

Thanks for this great work @giovp !
I played around with the plotting functions a bit and in general they work great!
I think I found one bug:
Plotting only one library_id with spatial_shape does not work.
The following code plots all library_ids, even though I specify 'point8'
adata_mibitof = sq.datasets.mibitof()
sq.pl.spatial_shape(
    adata_mibitof,
    library_key='library_id',
    library_id=['point8'],
    color=["Cluster", "cell_size"],
    ncols=2
    )

The equivalent spatial_segment call only plots one library_id as expected:
sq.pl.spatial_segment(
    adata_mibitof,
    library_key='library_id',
    library_id=['point8'],
    cell_id_key='cell_id',
    color=["Cluster", "cell_size"],
    ncols=2
    )

Btw, spatial_point on this example fails with a slightly cryptic error message:
# this fails
spatial_point(adata_mibitof, library_key='library_id')

File ~/projects/spatial_scanpy/squidpy/squidpy/pl/_spatial_utils.py:233, in <listcomp>(.0)
    ]()[231]()[ if scalefactors is not None:
    ]()[232]()[     if scale_factor is None:  # get intersection of scale_factor and match to img_res_key
--> ]()[233]()[         scale_factor_key = [i for i in scalefactors if img_res_key in i]
    ]()[234]()[         if not len(scale_factor_key):
    ]()[235]()[             raise ValueError(f"No `scale_factor` found that could match `img_res_key`: {img_res_key}.")

TypeError: 'in <string>' requires string as left operand, not NoneType]()

A couple of further remarks:

I was not too sure why you have three different interfaces to spatial_plot. For me, it was a bit confusing when to use spatial_point and when to use spatial_shape. The main difference between them seems to be that spatial_point does not plot the image, and shapes are restricted to circles. What is the argument for having two function here? Could you not set the default such that if no image is found no image is plotted?
I understand the need for a separate spatial_segment function though, that makes the interface a lot easier.
Would it be possible to have the library_id in the default title as well? When plotting multiple library ids, it can get confusing otherwise
What exactly do seg_boundaries and set_erosionpx do? I did not really understand the doctoring, and don't quite understand the potting behaviour with different values of seg_erosionpx
could you allow both lists + strings as input to library_id (or change name to library_ids, to indicate that list input is expected)
subfigures in spatial_segment plot above have slightly different sizes. Is this easily fixable?

slightly off topic, but I noticed that if we have an adata object combining multiple library_ids, the spatial graph does not take into account and is computed using all spatial coordinates. This is not always desirable, and its easy enough to iterate over each library id idenpendently, and concatenate the results again, but I was wondering if maybe sq.gr.spatial_neighbors should have an option to compute the graph for each library idependently

thanks for checking this out @hspitzer , I'll go through point by point

The following code plots all library_ids, even though I specify 'point8'

bug, fixed it, thanks!

Btw, spatial_point on this example fails with a slightly cryptic error message:

another bug, fixed it, thanks!

The main difference between them seems to be that spatial_point does not plot the image, and shapes are restricted to circles.

so spatial_points does not indeed plot the image, but simply a scatterplot. spatial_shape instead plots shapes, that can be circles, hexagons or squares.
The difference to have this plot separated is that the spatial_shape can control the size of the spots/observations (whether they are circles, squares or hexagons) via the scale_factor. Therefore, the shapes are correctly placed where the capture area is (for visium, dbit-seq and others). I thought to keep them separately because of this reason. I could also plot the image for the spatial_points but then we don't really have a way to infer from data what should be a good size for the scatterplot. Do you think this is an unnecessary concern? happy to hear thoughts on this

Would it be possible to have the library_id in the default title as well? When plotting multiple library ids, it can get confusing otherwise

this makes sense, to be added

What exactly do seg_boundaries and set_erosionpx do? I did not really understand the doctoring, and don't quite understand the potting behaviour with different values of seg_erosionpx

They can plot segmentation makss which have erosion outwards meaning that only the "boundaries" of the segmentation makss are plotted, I have an example above where to show this but also here https://github.com/theislab/squidpy/issues/427#issuecomment-1032990172 . The seg_boundaries instead plot a "boundary" in black on the segmentation masks, similar to the outline argument.

could you allow both lists + strings as input to library_id (or change name to library_ids, to indicate that list input is expected)

yes indeed, it was a bug, should be fixed

subfigures in spatial_segment plot above have slightly different sizes. Is this easily fixable?

do you think between continuos and categorical annotations? I noticed it as well but I must say I couldn't ifx it. I think scanpy has the same.

but I noticed that if we have an adata object combining multiple library_ids, the spatial graph does not take into account and is computed using all spatial coordinates. This is not always desirable, and its easy enough to iterate over each library id idenpendently, and concatenate the results again, but I was wondering if maybe sq.gr.spatial_neighbors should have an option to compute the graph for each library idependently

This is indeed a major problem and something the propagates on all the other functions in the library. The first step would be to allo spatial_neighbors to accept a batch_key or library_key argument so that it computes the neighbor graph per slide. After that, we'd have to do the same for the rest of the sq.gr functions and add tests. Not sure how much work it is but I think it'd be great to have it for next release cause it's really a bottleneck and makes it very unintuitive to users. Any help is very much appreciated.

The main difference between them seems to be that spatial_point does not plot the image, and shapes are restricted to circles.

so spatial_points does not indeed plot the image, but simply a scatterplot. spatial_shape instead plots shapes, that can be circles, hexagons or squares. The difference to have this plot separated is that the spatial_shape can control the size of the spots/observations (whether they are circles, squares or hexagons) via the scale_factor. Therefore, the shapes are correctly placed where the capture area is (for visium, dbit-seq and others). I thought to keep them separately because of this reason. I could also plot the image for the spatial_points but then we don't really have a way to infer from data what should be a good size for the scatterplot. Do you think this is an unnecessary concern? happy to hear thoughts on this

Just to clarify: Internally both functions use a scatterplot, right?
Ok, so the reason for separating them is that we don't always have scale information (in fact we only have scale information from the data when an image is stored in uns['spatial']. So you think the user might be confused about what the size of the dots/shapes means when we mix data that has a scale factor and data that does not.
I can see this point, but personally I'm not sure there needs to be a separation; if the data does not have intrinsic scale information, why should the user assume that you plot any?
Of course separating the image plotting from the simple scatter plot also makes the API easier, which might be a good argument in itself.
In any case, I would maybe rename spatial_point to spatial_scatter to match the scanpy API. And then either have spatial_scatter display the image if there is one + scale dots/shapes appropriately, or have another function spatial_image (or similar), for plotting shapes + images.
This way it would be a bit more intuitive (at least for me) which function does what.

What exactly do seg_boundaries and set_erosionpx do? I did not really understand the doctoring, and don't quite understand the potting behaviour with different values of seg_erosionpx

They can plot segmentation makss which have erosion outwards meaning that only the "boundaries" of the segmentation makss are plotted, I have an example above where to show this but also here #427 (comment) . The seg_boundaries instead plot a "boundary" in black on the segmentation masks, similar to the outline argument.

Ok, makes sense! I initially thought erosion would mean that the area you draw would shrink with larger seg_erosionpx. But its the other way around. Maybe renaming the arguments would make this clearer?

seg_boundaries -> seg_outline (to match the outline argument in  spatial_point
seg_erosionpx -> seg_contourpx
Also, for the seg_erosionpx docstring, maybe sth like: "Draw contour of specified width for each segment. If None, fills entire segment." makes it more clear.

subfigures in spatial_segment plot above have slightly different sizes. Is this easily fixable?

do you think between continuos and categorical annotations? I noticed it as well but I must say I couldn't ifx it. I think scanpy has the same.

yes exactly this slight change in size. Ok, if scanpy has the same, then lets just leave it.

but I noticed that if we have an adata object combining multiple library_ids, the spatial graph does not take into account and is computed using all spatial coordinates. This is not always desirable, and its easy enough to iterate over each library id idenpendently, and concatenate the results again, but I was wondering if maybe sq.gr.spatial_neighbors should have an option to compute the graph for each library idependently

This is indeed a major problem and something the propagates on all the other functions in the library. The first step would be to allo spatial_neighbors to accept a batch_key or library_key argument so that it computes the neighbor graph per slide. After that, we'd have to do the same for the rest of the sq.gr functions and add tests. Not sure how much work it is but I think it'd be great to have it for next release cause it's really a bottleneck and makes it very unintuitive to users. Any help is very much appreciated.

Ok! Yes, this would actually be great to have! Not sure if I will have lots of time to work on this, but I could try checking it out.

Just to clarify: Internally both functions use a scatterplot, right?

no they don't, spatial_point uses ax.scatter whereas the shape uses PatchCollection to build polygons.

Ok, so the reason for separating them is that we don't always have scale information (in fact we only have scale information from the data when an image is stored in uns['spatial']. So you think the user might be confused about what the size of the dots/shapes means when we mix data that has a scale factor and data that does not.
I can see this point, but personally I'm not sure there needs to be a separation; if the data does not have intrinsic scale information, why should the user assume that you plot any?

yeah we don't have both scale and img information sometime. basically if I were to add the spatial_scatter function that we discussed, then the spatial_point behaviour would be different and user would have to specify
spatial_scatter(adata, shape=None, img=False,...)

whereas iwth spatial_point they don't have to specify that but just use the function out of the box spatial_point(adata,...). This was motivation for separating spatial_scatter in spatial_point and spatial_shapes but maybe wrong, which API do you think is better?

Ok, makes sense! I initially thought erosion would mean that the area you draw would shrink with larger seg_erosionpx. But its the other way around. Maybe renaming the arguments would make this clearer?

seg_boundaries -> seg_outline (to match the outline argument in spatial_point
seg_erosionpx -> seg_contourpx
Also, for the seg_erosionpx docstring, maybe sth like: "Draw contour of specified width for each segment. If None, fills entire segment." makes it more clear.
sounds good, done.

ok, decided to go for spatial_scatter, thanks @hspitzer for discussion. Now to plot a scatterplot without image just need to dosq.pl.spatial_scatter(adata, shape=None) .

Ok, cool!
What will happen if there is no image data (eg seqfish)? Will the function still plot
Why are you using the name shape to control if an image is shown? Wasn't this parameter used to control the size of the dots?

What will happen if there is no image data (eg seqfish)? Will the function still plot
it will just plot the scatter plot

Why are you using the name shape to control if an image is shown? Wasn't this parameter used to control the size of the dots?

no this argument set whether a shape (circle, square, hex) will be used. If None, a scatterplot will be used (and no image is plotted)

pasting my comments here, please ignore them if this is intended behaviour:
1. mibitof data
sq.pl.spatial_scatter(
    adata_mibitof,
    color="Cluster",
    img=False
)

plots the same image three times without the underlying image, I would expect that it shows all present images side by side
sq.pl.spatial_scatter(
    adata_mibitof,
    color="Cluster",
    img=True
)

correctly changes the background image, but is not updating the scatter plot.
2. other data
I additionally tested the function on a second dataset where I collected all items needed for this function. General comment would be that we need a good tutorial that guides you through the steps of creating this structure. I think many people would like to use this function and its super nice.
one think I realized is the following:

if I plot the annotation for my example and the outline for plotting the continuous Area is correctly captured, but for the annotation, the outline disappears if two cells of the same type are super close.
I will explore further now and move my notebook for these kinds of plots towards the new function and will add my comments below if I come across more questions/hints/issues.
Overall this looks super cool imho! brings the whole plotting of spatial omics datasets to a whole new level and super excited that you were pushing for this.

if I plot the annotation for my example and the outline for plotting the continuous Area is correctly captured, but for the annotation, the outline disappears if two cells of the same type are super close.

@giovp, I think this is due to the boundaries being found after mapping cells -> categories, and could be solved by finding boundaries from the cell segmentation directly.

thanks a lot for testing it @AnnaChristina ! So for mibitof I've fixed the behaviour, should be consistent now.
for the boundaries, that's interesting cause it never happens with the mibitof data:

I think this is due to the boundaries being found after mapping cells -> categories, and could be solved by finding boundaries from the cell segmentation directly.

@ivirshup I think I get your point, I change the input of find_boundaries to original segmentation mask. @AnnaChristina could you try again on that dataset? If still doesn't work, I might have to allow to pass kwargs to find_boundaries https://scikit-image.org/docs/stable/api/skimage.segmentation.html#find-boundaries

tox -e check-docs runs successfully locally....


ZlibInputStream constructor naming

I'm not sure whether the ZlibInputStream has two constructors with the name "output" and one with the name "input" as the first parameter intentionally or whether this is a mistake, but it's very unclear when to use ZlibInputStream and when to use ZlibOutputStream, and when to use what constructor.
Some clarification in the documentation would be very helpful 😄

That's just a copy/paste.
Not really worth opening an issue for, perhaps it would have been better raised as a discussion


Move features without values to separate layers

the sort properties don't appear to work, so this could be one way to fix the overlapping lines. It also cleans up the code a bit, could perform better as those features won't need repainting, and allows us to make these features non-interactive.

I think we have resolved this by just ordering the GeoJSON so that England comes last


Fetch appropriate configlet binary.

I noticed that when I am working on my Mac the fetched configlet binary fails.
This pull request adds a limited but smarter configlet binary fetcher that
tries to determine the OS and architecture and fetch the appropriate
configlet binary.

@kytrinyx I wrote a script to propagate the pull request across all the tracks but I triggered some kind of abuse detection thing.  I need to wait to create pull requests for the remaining repos.

This is great. Anything to reduce the friction in getting a clean build!

@dkinzer A couple things:

Would you double-check the correct uname -m for 32 bit architectures?
I apparently had a configlet binary in there from before, from waaay back... so lots of new history here. Let me know if I should write up a quick how-to on cleaning this up against the new master.

@kytrinyx you're totally right, uname -m will return either i386 or i686 for 32 bit. (I need to stop making guesses).  I'll correct the patches.

I think it will be easier to close this and start a new one because of the merge conflicts.

OK, cool. Sorry about the mess!

No problem!


请问怎么安装你最新上传的基于0.5.6 oc的安装文件 没有发现pkg文件

Describe the bug
A clear and concise description of what the bug is. What is the installation destination (boot drive, USB installer drive, other drive)? What installation options are selected?
Expected behavior
A clear and concise description of what you expected to happen.
Environment:

Running OSX version:
Target drive OSX version:
HaC Mini installer version:

Additional context
Add any other context about the problem here.
Logs
Please attach /var/log/install.log

You can find it on page https://github.com/osy86/HaC-Mini/actions/runs/64139663.
你可以在上面那个链接里下载。。有个叫installer的artifacts。。。。（吐槽一下，你这个issue里面自动填写的东西。。hmmm。。。）

Updated release to 2.7


Initiating a Locale/Language with empty language code/script/region results in an unreasonable locale.

Here are some examples:
print(Locale(languageCode: "", script: "", languageRegion: "").identifier) // "-_"

let languageComponents = Locale.Language.Components(language: .init(identifier:""))
print(Locale(languageComponents: languageComponents).identifier) // "-Latn"

Fix this by handling empty identifiers passed in at initialization time correctly.
resolves 132353443

@swift-ci please test


Documentation: Deployment docs needed

Currently, we're deploying smart contracts only to Anvil or to Alchemy.
Docs could improve to explain how these deployments work, and what happens at each step.

[ ] Clean up README and scripts like deployment_build_op_goerli.sh (should this live under a new folder that contains deployment scripts?)
[x] Remove instructions for how to run scripts from those scripts, and update those instructions in documentation instead
[ ] Create an EXAMPLES section in documentation (considering this; tracking for visibility for myself)

Started in apalmer/deployment-scripts, branch checked out at #93

Partially resolve by #108


Bad7zFile Error

Hi,
I was trying to use this DLPacker on Google Colab, but after I run this code:
from dlpacker import DLPacker
dlp = DLPacker("/content/backbone.pdb")
dlp.reconstruct_protein(order="sequence", output_filename="structure_repacked.pdb")

I encounter this error:
Unzipping pretrained weight files...
---------------------------------------------------------------------------
Bad7zFile                                 Traceback (most recent call last)
[<ipython-input-34-b36edbf7401f>](https://localhost:8080/#) in <cell line: 1>()
----> 1 from dlpacker import DLPacker
      2 dlp = DLPacker("/content/backbone.pdb")
      3 dlp.reconstruct_protein(order="sequence", output_filename="structure_repacked.pdb")

5 frames
[/usr/local/lib/python3.10/dist-packages/dlpacker/__init__.py](https://localhost:8080/#) in <module>
----> 1 from dlpacker.dlpacker import DLPacker

[/usr/local/lib/python3.10/dist-packages/dlpacker/dlpacker.py](https://localhost:8080/#) in <module>
     55
     56     print('Unzipping pretrained weight files...')
---> 57     unzip_weights(
     58         archive_path=f'{DEFAULT_WEIGHTS}.7z',
     59         output_dir=os.path.dirname(DEFAULT_WEIGHTS),

[/usr/local/lib/python3.10/dist-packages/dlpacker/utils.py](https://localhost:8080/#) in unzip_weights(archive_path, output_dir)
     75         print("Created single archive file: ", archive_path)
     76
---> 77     with py7zr.SevenZipFile(archive_path, mode='r') as z:
     78             z.extractall(path=output_dir)
     79

[/usr/local/lib/python3.10/dist-packages/py7zr/py7zr.py](https://localhost:8080/#) in __init__(self, file, mode, filters, dereference, password, header_encryption, blocksize, mp)
    407         except Exception as e:
    408             self._fpclose()
--> 409             raise e
    410         self._dict: Dict[str, IO[Any]] = {}
    411         self.dereference = dereference

[/usr/local/lib/python3.10/dist-packages/py7zr/py7zr.py](https://localhost:8080/#) in __init__(self, file, mode, filters, dereference, password, header_encryption, blocksize, mp)
    395         try:
    396             if mode == "r":
--> 397                 self._real_get_contents(password)
    398                 self.fp.seek(self.afterheader)  # seek into start of payload and prepare worker to extract
    399                 self.worker = Worker(self.files, self.afterheader, self.header, self.mp)

[/usr/local/lib/python3.10/dist-packages/py7zr/py7zr.py](https://localhost:8080/#) in _real_get_contents(self, password)
    427     def _real_get_contents(self, password) -> None:
    428         if not self._check_7zfile(self.fp):
--> 429             raise Bad7zFile("not a 7z file")
    430         self.sig_header = SignatureHeader.retrieve(self.fp)
    431         self.afterheader: int = self.fp.tell()

Bad7zFile: not a 7z file

Can you help me?

Were you able to solve this problem? I just published an update, which might solve this problem.
Just run
!pip install dlpacker
before you run the cell above

Yeah, I able to reproduce, will work on the solution. For now the problem can be overcome by running the following line in the colab:
!7z e /usr/local/lib/python3.10/dist-packages/dlpacker/data/DLPacker_weights.7z.001

Solved in #11
Feel free to try again - the problem is gone, just make sure you install v1.0.1:
pip install dlpacker>=1.0.1


Add processing of NameError

Should fix #22 with optional TYPE_CHECKING import

So there are two options for fixing these: either set typing.TYPE_CHECKING=True or do this. This will let the process continue but the imported types won't be available. Can you think of a reason why setting the flag would be a problem?

@agronholm There is no way to avoid problem with circular imports like this when enable TYPE_CHECKING
Traceback (most recent call last):
  File "/home/siredvin/.pyenv/anji-orm/lib/python3.6/site-packages/sphinx/ext/autodoc.py", line 658, in import_object
    __import__(self.modname)
  File "/home/siredvin/Programming/AnjiProject/anji-orm/anji_orm/__init__.py", line 1, in <module>
    from .core import *
  File "/home/siredvin/Programming/AnjiProject/anji-orm/anji_orm/core/__init__.py", line 1, in <module>
    from .ast import *  # type: ignore
  File "/home/siredvin/Programming/AnjiProject/anji-orm/anji_orm/core/ast/__init__.py", line 1, in <module>
    from .base import *
  File "/home/siredvin/Programming/AnjiProject/anji-orm/anji_orm/core/ast/base.py", line 623, in <module>
    from ..model import Model  # pylint: disable=unused-import
  File "/home/siredvin/Programming/AnjiProject/anji-orm/anji_orm/core/model.py", line 6, in <module>
    from .fields import DatetimeField, AbstractField, JsonField, StringField
  File "/home/siredvin/Programming/AnjiProject/anji-orm/anji_orm/core/fields/__init__.py", line 1, in <module>
    from .base import *
  File "/home/siredvin/Programming/AnjiProject/anji-orm/anji_orm/core/fields/base.py", line 13, in <module>
    from ..register import orm_register
  File "/home/siredvin/Programming/AnjiProject/anji-orm/anji_orm/core/register.py", line 9, in <module>
    from .executor import AbstractSyncExecutor, AbstractAsyncExecutor
  File "/home/siredvin/Programming/AnjiProject/anji-orm/anji_orm/core/executor.py", line 99, in <module>
    from .model import Model
ImportError: cannot import name 'Model'

mypy imports only one module when sphinx try to load whole project and this cause problem. You can try on my project for example. And there is hard to avoid such references when using typing

I'll try to take one more look at this tomorrow and I'll probably merge this then.

Any progress on this? I'm encountering the issue that this would fix

Ah, damn. I had so many other things that made me forget all about this. I must add a reminder for myself to get this out of the way. Today or tomorrow.

@davidwneary what is your use case that you need this for? Is it something that can't be fixed simply by importing the target module and then adding forward references to module.classname?

Given 3f2605cd2b477be7a26df04094ca48ee634566e6 and 86d0834e7eea6beadfb29117cc0ffa25c0bfe1af, I feel there is no need for this. Comment if you disagree.

The problem here is that without evaluating the type checker the tool cannot be aware of types imported inside the block. In this case, the tool is behaving like a type checker and must evaluate the content.


Add automatic benchmark tests for both memory and performance

https://github.com/dotnet/BenchmarkDotNet
https://github.com/devhawk/xunit.benchmark
We want to break builds if we're outside of defined thresholds.
Would also be interesting to publish the results as telemetry data that can be observed over time.

See #1200


If I want to follow your research, what device and how many GPUs are needed to train this model？

If I want to follow your research, what device and how many GPUs are needed to train this model？

Hey @shonnon-zxs, thanks for your interest in our research! Most of our experiments only use 1 3090 GPU.
Let us know if there is anything we can help.

Hi, I am wondering how many parameters your LLMs (GPT-3 and Unified QA) have for getting reported results in Table 3. Also, what GPU machines do you need for zero-shot models? Thanks!!

Hi @tengfeixue-victor, for GPT-3, we simply used its API, while for Unified-QA we use huggingface to serve and evaluate the model and the experiments were done on a RTX 3090 GPU.

Thanks so much for your reply! I am wondering how you get answers when using GPT-3 or Unified-QA. These LLMs can output a sentence that includes the answer in it. How did you extract answers from the output sentences? The evaluation metric in the paper is still the accuracy, not language metrics.

https://github.com/SilongYong/SQA3D/issues/6#issuecomment-1670781074


result not same as REAME.md

python 3.5.6
pytorch 0.4.1
torchvision 0.2.1
Run
python search.py --name cifar10 --dataset cifar10
but my result graph is not same as README.md, such as epoch 24

Did you solve this problem?


Update Notice

Need to do this for recipes also.

We can also remove incubating from the SNAPSHOT version in the pom

@keith-turner I can do that for this PR if you would like

I think that makes sense to find them all in this PR

I ran the following
$ git clean -xfd
$ find . -type f  | fgrep -v .git | xargs grep -i incubat

Seeing poms and DISCLAIMER... Also seeing some URLs in other files, but we can not change those yet.

Its going to be so nice not having incubating in our versions.

I found one more incubating reference that should be removed:
./modules/core/pom.xml:  <name>Apache Fluo (incubating) Core</name>

Yea I noticed that a minutes ago. fixed ac0b1bc

Also have to update contrib/create-release-candidate.sh to not include incubating. I'll leave that for one of you guys to do so I don't mess it up.

Looks good to merge now


PS4 fpkg (*.pkg) support for HB-Store

Hi mate,
I just got a feedback that my HB-Store CDN Server tool would be great if it could supports RetroNAS as base path.
I will test the RetroNAS once I have time for it to figure out how to implement it though.
Currently there are a few endpoints and stuff to be made to get the pkgs working on the hb-store app on the ps4 side.
So therefore my Tool would only act as a proxy here and prepare the necessary data structure and provide the needen stuff.
As my tool just deep scans the given base path for all *.pkg files, I assume that it would be enough if users just put in the NAS address as base path and let it do it's job.  Which seems to be working fine by the user.  But apperently it scans all the NAS folders I guess which adds a bit delay.

Converting to discussion
Please let us know when this tool is ready to be added


[WIP] Propagate --color option to rustc

closes #2740
Will try to add a test for this soon (and fix failing tests if any, compiling/running tests locally is slow :( ).
I am not sure what is the right place to add --color option to the command line. I use build_base_args. process also looks like a good candidate, because it is more general, but if we look at the CommandType we see that only rustc command supports --color.

r? @wycats
(rust_highfive has picked a reviewer for you, use r? to override)

Ah yeah I think this location is fine, other places aren't necessarily invoking the compiler so it probably wants to avoid those directly. Thanks!
With a test r=me

Added the test.
And, OMG, someone has removed the test! macro, and I've just added support for context aware run configurations to IntelliJ Rust, so now I can run a single cargo test under cursor with one shortcut!

Hm, ironically the tests pass in the IDE and not on the CI, because
        // Use `TermInfo::from_env()` and `TerminfoTerminal::supports_color()`
        // to determine if creation of a TerminfoTerminal is possible regardless
        // of the tty status. --color options are parsed after Shell creation so
        // always try to create a terminal that supports color output. Fall back
        // to a no-color terminal regardless of whether or not a tty is present
        // and if color output is not possible.
```,

so no colors in the IDE without manually setting up the `TERM` env variable.

@bors: r+ 76a48a9b075342249d4080326c69f4638b55fe7d
Thanks!

:hourglass: Testing commit 76a48a9 with merge 13861b7...

:sunny: Test successful - cargo-cross-linux, cargo-linux-32, cargo-linux-64, cargo-mac-32, cargo-mac-64, cargo-win-gnu-32, cargo-win-gnu-64, cargo-win-msvc-32, cargo-win-msvc-64


Device disable

Here is implementation discussed in #3683
Disabled device excluded from reports of ordinary users and managers and from events notifications (via all transports).
Current device position is not updated via websocket for ordinary user, but device object is still updated.
Theoretically user can understand where device is placed now by device.geofenceIds[] but I do not think it is big leakage.
Only admin can enable device back.
There is switch database.storeDisabled to store or not store data from disabled device.
Also It is easy to add device expiration in future.
 I have some thoughts about permission optimizations, but it is need to be discussed.
fix #3683

I agree that it seems like a lot of extra complexity. That's why I suggested to basically exclude devices from user permissions if it's disabled. That would have been much simpler. Maybe we should still do it, but have some extra API to return disabled devices? To display it only in "devices" panel?

I'm not sure that it will be less complex, just in other places of code. We still need exclude devices from reports and positions.
My thoughts is about improve logic of checkDevice function. Basically we have next permissions:

read device object - all users who have access to device including device readonly users
edit/remove device object - not readonly  and device readonly users who have access to device
send command - all who can read ( if not disabled? )
reset total distance - admins only (?)
retrieve current position - all who can read if device not disabled
be notified about events related to device - same as previous
get reports - same as previous
...

What is complex is that in some cases we should rise exception, but in other we should skip device silently.

Even if we implement that, we would need to basically double that logic on the web side as well. I feel like my option is much much simpler.

I'll try, how do you see admin interface to enable/disable devices?

I guess just a checkbox on the device model.

But disabled devices are excluded from user lists, how to get to device model?

No, obviously they are not excluded from admin.

Implemented simple disable in other PR, want to leave this variant as is just in case.


Update form inputs to use the new focus state

What
Update the form inputs to use the new focus style as per the preview branch.
That includes:

Text input
Textarea
Select
File upload

Why
We're updating the focus style as part of making the Design System meet WCAG 2.1 – specifically with regard to WCAG 2.1 1.4.11 Non-Text Contrast (#1137).
Done when…

[x] Text input updated to use new focus state
[x] Textarea updated to use new focus state
[x] Select updated to use new focus state
[x] File upload updated to use new focus state
[x] Tested in all browsers that we support
[ ] Tested in legacy mode (using the deprecated libraries)
[ ] Tested with zoom up to 400%
[ ] Tested with ZoomText
[ ] Tested in Windows High Contrast mode
[ ] Tested with overridden colours in the browser

Closed by #1312


[Questions] There are plans to add support for async-std.?

Hi, I wanted to use the rust ngrok sdk but when I went to the documentation and then to the source code I noticed that it is linked to the Tokio ecosystem, I guess it makes sense because it is the largest within the rust ecosystem.
But my stack is completely based on async-std and that's why my question, I would love to be able to use this package without having to change my stack.

Thanks for the issue!
We don't have any plans to add support for alternative runtimes right now, though personally I'd love to. A good chunk of the muxado crate was written to be entirely runtime-agnostic (see: the StreamManager struct, which manages all of the subtasks via a FuturesUnordered), but got fatigued around some of the higher-level bits, like the Heartbeat wrapper :sweat_smile:
Some follow-up questions for you:

Is the tokio dependency a hard blocker for you, or is it something that can be worked around? If it can be worked around, how much effort does it take? Ideally, in lieu of full support for other runtimes, the fact that we're using tokio under the hood should be an implementation detail that shouldn't "infect" the rest of your codebase. If you're having to do weird things like carry around tokio Handles to enter its runtime context to prevent panics or something, we'd like to know about it and fix it.
In the ideal scenario, what does async-std support look like? Is it a set of features like in sqlx where you pick one at compile-time? Or is there a reasonable approach to being generic over executor implementations? I generally prefer the latter, but it doesn't seem like anyone has agreed on an executor/spawner trait to be generic over, and managing tasks internally quickly gets unwieldy :confused:
I just noticed the tokio1 feature in async-std. What does it do exactly?


Suggestions

Add suggestions here!

compression of modded ores like mekanism and thermal series

compression of modded ores like mekanism and thermal series

Will be added with the next update after the 5.0.1 release has been released.

compression of modded ores like mekanism and thermal series

Will be added with the next update after the 5.0.1 release has been released.

moved to v5.0.3 due recipe issues

compression of modded ores like mekanism and thermal series

Mekanism blocks have been added with #8209338

compression of the new blocks from the create mod like gabbro and scoria

logs

logs

In already working in logs, but it's different to generate their models using the data generator

logs

In already working in logs, but it's different to generate their models using the data generator

oh ok, cool

logs

In already working in logs, but it's different to generate their models using the data generator

oh ok, cool

Would you mind the texture issue? I mean all compression variants would look the same (implemented as Block that behaves same as minecraft log)
Or having it as an item with compression level texture (can't be placed in the world)

logs

In already working in logs, but it's different to generate their models using the data generator

oh ok, cool

Would you mind the texture issue? I mean all compression variants would look the same (implemented as Block that behaves same as minecraft log)
Or having it as an item with compression level texture (can't be placed in the world)
I'd prefer not to use a custom texture, because the mod has full texture pack support (excluding grass block)

i mean id be down to have like a working version that allows compression rn and then maybe someday figure out the texture issue but i dont see it as a big deal

the cosmetic blocks from the biomes o plenty mod

aswell as the new types of wood

the cosmetic blocks from the biomes o plenty mod
aswell as the new logs

all have been added (except the planned plugins)
also compressed logs are now fully functional :)

Can you make compacted blaze rods?
Also pumpkins and watermelons would be good
And maybe tier or two for ender pearls (81 is too small lol)

Can you make compacted blaze rods?
Also pumpkins and watermelons would be good
And maybe tier or two for ender pearls (81 is too small lol)

Theres a lot planned for 1.17, the sacks will be changed into crates containing all 10 levels of "compression"
including but not limited to sticks, apples, ender eyes + pearls, eggs, wheat, pumpkins, water melons, bone meal etc etc
Also tools are going to be removed in 1.17, but will remain in the 1.16 versions

Deepslate and the other 1.18 specific stones would be great!

Deepslate and the other 1.18 specific stones would be great!

Deepslate should be in there, but i forgot tuff etc i think, will be added soon!

Surprised me to find out that you didn't do it for netherwart, as all other farmables have

Looking at it again, I see that netherwart blocks are there, but could you also add something for the normal netherwart as you can't turn the blocks back to the normals

Support for Storage Drawers' Compacting Drawers? If support is meant to be included, it seems to be broken.

A way to disable certain recipes, especially if other compression mods are loaded. There currently isn't any CraftTweaker support for 1.19.
Another compression mod (AllTheCompressed) adds a 'check' that looks for other compression mods (more specifically Compressium iirc), then won't load those recipes, as they would conflict. Sadly hasn't been ported to 1.19 yet either.
Perhaps a config option? A check for other compression mods' presence?


Addressing Challenges in Complete Codebase Migration to React

The decision to transition the entire codebase to React represents a significant shift in a company's technology strategy. While React offers numerous advantages in terms of efficiency, scalability, and maintainability, such a migration also presents several challenges that need to be carefully considered and addressed to ensure a successful transition.

@Ramu-chiluveru
Thank you for highlighting the important considerations regarding the transition of the codebase to React. I completely agree that while React offers significant benefits in terms of efficiency, scalability, and maintainability, we must also address the challenges associated with such a migration to ensure its success.
I am eager to contribute to this transition and help navigate through these challenges to make the process as smooth and successful as possible.

@Asin-Junior-Honore I request you to assign this to me and please do label the issue. Then I will start working on it

@Ramu-chiluveru
I'm sorry for any misunderstanding. I'm not the owner or maintainer of the repo; I just want to be part of the  contributors to the transition of the repo to React. Thanks! 🙏


ORC-185: [C++] Simplify Statististics Implementation

@wgtmac   how does the second commit look?

Overall the PIMPL looks nicer than the current implementation. My main concern for using templates is that we need to compare & update values of different types, merge ColumnStatistics, and transform to protobuf version for implementing writers and using templates may not help in this case. It means we still need to do template specialization for different types like Date, Timestamp, Decimal, etc. if we want to let class ColumnStatistics to handle the update (e.g. use ColumnStatistics::update(T value) to update min/max for type T). Otherwise we may need to let specific ColumnWriters to be responsible for update (e.g. DecimalColumnWriter to compare min/max of decimal values and then use setMax/setMin of ColumnStatistics to update the values).

You have to specialize the code for non-primitive types. There is no other option. I would say specialization of methods like compare, update inside InternalStatisticsImpl  is the right and simple way to go forward. This class should be responsible for handling the statistics updates.
ColumnWriters will just have an instance of the InternalStatisticsImpl and call the corresponding methods to update on writing a new value.

Yeah, we should probably adopt some coding guidelines. I'm not wild about Google's trailing underscore names.

I will update this patch to remove the trailing underscores.


Update code to deal API-breaking changes in Spectron/Electron.

Older versions of Electron allowed one to IPC objects
that contained code (and other features) by silently converting
code -> undefined.  Newer versions reject these IPCs.  Adjusted
getMenuItem to return a generic object instead of a electron.MenuItem.
Newer versions of node/spectron also require webPreferences:true
to be set when creating an application.  Updated tests to reflect
this.
Next, I added the appropriate parameters to the menuItem.click()
method (menuItem,browserwindow,event).  I haven't yet figured
out how to pass a valid event, so don't trust that parameter yet,
but browserWindow is frequently needed so that an application knows
which window is being communicated with!
Lastly, I made the clickMenuItem an async function that uses
sendSync, so that tests could more easily wait until the click
was handled.
Bump version number.

hi,my electron version is 9.0.0,and my spectron version is12.0.0.I ran code menuAddon.clickMenu('XXX', 'XXXX'); It return the message  TypeError: Cannot read property 'electron' of undefined
at SpectronMenuAddon.clickMenu (node_modules\spectron-menu-addon\dist\index.js:24:18)
at Context. (spec.js:65:15)
at processTicksAndRejections (internal/process/task_queues.js:93:5)

Hey yoresu,
I think you need to match spectron/electron versions as listed here: https://github.com/electron-userland/spectron#version-map
If that doesn't @SALT-AND-PEPPER has not responded about this PR, so I've been maintaining this -v2 in jdhiser:master.  If you're having problems with that version and my comment above didn't help, please open an issue on that repo.
-j


Is there a way to extract the mask with an API call?

Not a bug, rather a question/feature request. Like the title says I have been trying to find a way to get the mask only via API call. Is there a way to do this?

Same, I'd like to use it as negative mask.

Yes, but you may need to write an api.py file and put it in the extension folder.


2.1 For 1.20.4

Please do not skip this version for 2.1, I cant use the mod because of the bugs that are only fixed in 2.1.

Im hoping that this will be a simple change to the version requirements, and if so there is no reason not to do so.

you know you can just install it anyways

actually you cant, it will force the game to crash because of the way its coded

uh huh ok, but i also don't see anything wrong with getting 1.21 either so

Why are you fighting me? You aren’t the dev, and I can’t just “get” 1.21 because I have other mods that have not updated. My request stands, I need this update for my version.

i'm not attempting to "fight" you, i'm just simply stating some alternative solutions for your problem.
i am not the developer either, yet i am still inclined to believe that he will not update the mod for an older minecraft version.
i am aware that my previous comments may have sounded a bit harsh, but i did have good intentions.

AutoTools will only be updated for 1.20.1 and 1.20.6 as these are the major and latest versions, but in the future the required versions won't be enforced as harshly and the release for 1.20.1 should probably work with 1.20.4 (apart from shears because of the changed id of grass)

Thanks, that’s all I needed really. As long as the version requirements are less strict, I can just use that


Support PHP 8.2

Do whatever changes to make sure library supports PHP 8.2

No release necessary:

No code/dependencies changes that affect projects using this library
PHP 8.2 compatibility (unfortunately) already declared by current constraint: ^7.3 || ^8.0


Russian Bank names provider

Hi, folks.
I've just implemented generator for Russian Bank names. Real bank names you can get from banki.ru  (see complete list: http://www.banki.ru/banks/)

Added description to readme.md

Hi.
Any comments?


Different queries between batch and interactive mode

I have a curious case of a query that succeeds relatively quickly in interactive mode but fails in batch mode. I used --log_queries to see if I could spot a substantial difference. The two SMT2 files are attached and I can reproduce the result by calling Z3 from the command-line with no arguments (Z3 version 4.5.1 - 64 bit - build hashcode 1f29cebd4df6).
The only non-syntactic difference I can see is that the interactive query does (push) a lot more than the batch query (222 vs. 3). I guess the extra (push) are there because in interactive mode the query is built incrementally and they would allow to (pop) complete segments.
Remove those extra (push) and the unsat result turns into unknown.
This behaviour is puzzling from a user point of view. I'd argue that for predictability, there shouldn't be any differences between the queries generated in interactive and batch mode.
~queries.zip~
queries-proper.zip
The query in question is (TLS.sendHandshake, 1) and comes from mitls-fstar/src/tls/TLS.fst with a few modifications.

Thanks for report! I'm currently investigating related parts of Z3 (not remembering quantifier instances after pops, etc). In general, (push)/pop are not "free"; they do incur overhead, and they can significantly change the search, so in that respect, this problem is not entirely unexpected. Note that there are also other differences between the queries, for instance the Fact-ids are numbered differently (possibly in a different order too).
On emacs.smt2, Z3 complains about the (pop) in the end, which doesn't have a corresponding (push):
(error "line 408440 column 4: invalid pop command, argument is greater than the current stack depth")

The general problem of what the "same" means for Z3 queries is rather tricky, e.g., renaming variables, reordering assertions, and push/popping can have a huge impact on the behavior of the solver, but users frequently think they didn't change "anything". This must be really frustrating to F* users, who possibly can't even observe the fact that there's a difference in the queries produced by F*. Suggestions and ideas in this area are very welcome though!
For the case of interactive queries we could try pre-filtering scopes, e.g. removing pushes that are never popped, and removing all assertions that are popped without checking. That would take some unpredictability out of it (and it's cheap to implement and may make queries physically smaller).
The really sad news is that the latest master of Z3 doesn't solve either of those queries :( Are they manually modified or are they exactly as produced by F*?

Sorry! I think I botched up emacs.smt2 by pruning all (push) before I attached it. That explains the unmatched (pop) and why Z3 couldn't solve either query.
Here are proper queries (they aren't manually modified in any way):
queries-proper.zip

;;;
;;; Started F* interactive: ("/Users/jkas/.fstar/bin/fstar.exe" "/Users/jkas/Documents/fstar/RSA.fst" "--ide" "--smt" "/Users/jkas/.fstar/bin/z3")
{"kind":"protocol-info","version":2,"features":["autocomplete","compute","describe-protocol","describe-repl","exit","lookup","lookup/documentation","lookup/definition","pop","peek","push","search"]}
;;; Complete message received: (status: nil; message: ((kind . "protocol-info") (version . 2) (features "autocomplete" "compute" "describe-protocol" "describe-repl" "exit" "lookup" "lookup/documentation" "lookup/definition" "pop" "peek" "push" "search")))
;;; [15.04ms] Feature list received
;;; Processing queue
>>> {"query-id":"1","query":"push","args":{"kind":"full","code":"module RSA\nopen FStar.Mul\n","line":1,"column":0}}
{"kind":"response","query-id":"1","status":"success","response":[]}
;;; Complete message received: (status: "success"; message: ((kind . "response") (query-id . "1") (status . "success") (response)))
;;; Processing queue
>>> {"query-id":"2","query":"push","args":{"kind":"full","code":"\n(*! 1. write a function that computes [g^e] naively *)\n\nval pow: g:nat -> e:nat -> nat\n","line":3,"column":0}}
{"kind":"response","query-id":"2","status":"success","response":[]}
;;; Complete message received: (status: "success"; message: ((kind . "response") (query-id . "2") (status . "success") (response)))
;;; Queue is empty (2 overlays)
;;; Processing queue
>>> {"query-id":"3","query":"push","args":{"kind":"full","code":"\n// Solution:\nlet rec pow g e =\n  if e = 0\n  then 1\n  else g * pow g (e-1)\n","line":7,"column":0}}
{"kind":"response","query-id":"3","status":"success","response":[]}
;;; Complete message received: (status: "success"; message: ((kind . "response") (query-id . "3") (status . "success") (response)))
;;; Queue is empty (3 overlays)
;;; Processing queue
>>> {"query-id":"4","query":"push","args":{"kind":"full","code":"\n// Test: evaluate pow 2 16\n\n// A convenient notation [but it breaks proofs?]\n// unfold let (^) = pow\n\n\n(*! 2. prove [g^(e1 + e2) = g^e1 * g^e2] *)\n\nval lemma_pow_add (g: nat) (e1 e2: nat): Lemma (pow g (e1 + e2) = pow g e1 * pow g e2)\n","line":13,"column":0}}
{"kind":"response","query-id":"4","status":"success","response":[]}
;;; Complete message received: (status: "success"; message: ((kind . "response") (query-id . "4") (status . "success") (response)))
;;; Queue is empty (4 overlays)
;;; Processing queue
>>> {"query-id":"5","query":"push","args":{"kind":"full","code":"\n#set-options \"--initial_fuel 1 --initial_ifuel 1\"\nlet rec lemma_pow_add g e1 e2 =\n  if e2 = 0 then ()\n  else lemma_pow_add g e1 (e2 - 1)\n","line":23,"column":0}}
{"kind":"response","query-id":"5","status":"failure","response":[{"level":"error","message":"Unknown assertion failed (SMT solver says: unknown because canceled (fuel=8; ifuel=2; ); SMT solver says: unknown because (resource limits reached) (fuel=4; ifuel=2; ); SMT solver says: unknown because (resource limits reached) (fuel=1; ifuel=2; ); SMT solver says: unknown because (resource limits reached) (fuel=1; ifuel=1; ))","ranges":[{"fname":"<input>","beg":[25,0],"end":[27,34]}]}]}
;;; Complete message received: (status: "failure"; message: ((kind . "response") (query-id . "5") (status . "failure") (response ((level . "error") (message . "Unknown assertion failed (SMT solver says: unknown because canceled (fuel=8; ifuel=2; ); SMT solver says: unknown because (resource limits reached) (fuel=4; ifuel=2; ); SMT solver says: unknown because (resource limits reached) (fuel=1; ifuel=2; ); SMT solver says: unknown because (resource limits reached) (fuel=1; ifuel=1; ))") (ranges ((fname . "<input>") (beg 25 0) (end 27 34)))))))
;;; Highlighting issues: ([cl-struct-fstar-issue error ([cl-struct-fstar-location /Users/jkas/Documents/fstar/RSA.fst 25 27 0 34]) Unknown assertion failed (SMT solver says: unknown because canceled (fuel=8; ifuel=2; ); SMT solver says: unknown because (resource limits reached) (fuel=4; ifuel=2; ); SMT solver says: unknown because (resource limits reached) (fuel=1; ifuel=2; ); SMT solver says: unknown because (resource limits reached) (fuel=1; ifuel=1; ))])
;;; Queue is empty (4 overlays)
;;; Processing queue
>>> {"query-id":"6","query":"push","args":{"kind":"full","code":"\n#set-options \"--initial_fuel 1 --initial_ifuel 1\"\nlet rec lemma_pow_add g e1 e2 =\n  if e2 = 0 then ()\n  else lemma_pow_add g e1 (e2 - 1)\n","line":23,"column":0}}
{"kind":"response","query-id":"6","status":"success","response":[]}
;;; Complete message received: (status: "success"; message: ((kind . "response") (query-id . "6") (status . "success") (response)))
;;; Queue is empty (5 overlays)
;;; Processing queue
>>> {"query-id":"7","query":"push","args":{"kind":"full","code":"\n(*! 3. prove [(g^e1)^ e2 = g^(e1 * e2)] *)\n\nval lemma_pow_mul (g:nat) (e1 e2:nat): Lemma (pow (pow g e1) e2 = pow g (e1 * e2))\n","line":28,"column":0}}
{"kind":"response","query-id":"7","status":"success","response":[]}
;;; Complete message received: (status: "success"; message: ((kind . "response") (query-id . "7") (status . "success") (response)))
;;; Queue is empty (6 overlays)
;;; Processing queue
>>> {"query-id":"8","query":"push","args":{"kind":"full","code":"\nlet rec lemma_pow_mul g e1 e2 =\n  if e2 = 0 then ()\n  else\n    let e2': nat = e2 - 1 in\n    lemma_pow_mul g e1 e2';\n    lemma_pow_add g e1 (e1 * e2')\n","line":32,"column":0}}
{"kind":"response","query-id":"8","status":"success","response":[]}
;;; Complete message received: (status: "success"; message: ((kind . "response") (query-id . "8") (status . "success") (response)))
;;; Queue is empty (7 overlays)
;;; Processing queue
>>> {"query-id":"9","query":"push","args":{"kind":"full","code":"\n\n(*! 4. Implement exponentiation by squaring using\n       [ g^e = g^(e/2)^2]       when [g % 2 = 0]\n       [ g^e = g*(x^(e-1)/2)^2] when [g % 2 = 1 ] *)\n\nval fast_pow: nat -> nat -> nat\n","line":39,"column":0}}
{"kind":"response","query-id":"9","status":"success","response":[]}
;;; Complete message received: (status: "success"; message: ((kind . "response") (query-id . "9") (status . "success") (response)))
;;; Queue is empty (8 overlays)
;;; Processing queue
>>> {"query-id":"10","query":"push","args":{"kind":"full","code":"\nlet rec fast_pow g e =\n  match e with\n  | 0 -> 1\n  | _ ->\n    let g' = pow g (e/2) in\n    g' * g' * (if e % 2 = 0 then 1 else g)\n","line":46,"column":0}}
{"kind":"response","query-id":"10","status":"success","response":[]}
;;; Complete message received: (status: "success"; message: ((kind . "response") (query-id . "10") (status . "success") (response)))
;;; Queue is empty (9 overlays)
;;; Processing queue
>>> {"query-id":"11","query":"push","args":{"kind":"full","code":"\n(*! 5. Prove that exponentiation by squaring is correct *)\n\nval lemma_fast_pow (g:nat) (e:nat): Lemma (fast_pow g e = pow g e)\n","line":53,"column":0}}
{"kind":"response","query-id":"11","status":"success","response":[]}
;;; Complete message received: (status: "success"; message: ((kind . "response") (query-id . "11") (status . "success") (response)))
;;; Queue is empty (10 overlays)
;;; Processing queue
>>> {"query-id":"12","query":"push","args":{"kind":"full","code":"\n// You will need the lemmas from exercises 2 and 3\n// Hint: think how to relate e to e/2 and e%2\n\nlet lemma_fast_pow g e =\n  if e = 0 then () else\n    let e' = e/2 in\n    let b = e%2 in\n//  assert(e = 2 * e' + b);\n    lemma_pow_add g (2 * e') b;\n//  assert(pow g e = pow g (2 * e') * pow g b);\n    let r = if b = 0 then 1 else g in\n//  assert(r = pow g b);\n//    let g' = pow g e' in\n//  assert(fast_pow g e = g' * g' * r);\n    lemma_pow_mul g e' 2\n//  assert(pow g e = pow g' 2 * r);\n//  assert_norm(pow g' 2 = g' * g')\n","line":57,"column":0}}
{"kind":"response","query-id":"12","status":"success","response":[]}
;;; Complete message received: (status: "success"; message: ((kind . "response") (query-id . "12") (status . "success") (response)))
;;; Queue is empty (11 overlays)
>>> {"query-id":"13","query":"pop","args":{"dummy":null}}
{"kind":"response","query-id":"13","status":"success","response":null}
;;; Complete message received: (status: "success"; message: ((kind . "response") (query-id . "13") (status . "success") (response . :json-null)))
;;; Queue is empty (10 overlays)
;;; Processing queue
>>> {"query-id":"14","query":"push","args":{"kind":"full","code":"\n// You will need the lemmas from exercises 2 and 3\n// Hint: think how to relate e to e/2 and e%2\n\nlet lemma_fast_pow g e =\n  if e = 0 then () else\n    let e' = e/2 in\n    let b = e%2 in\n//  assert(e = 2 * e' + b);\n    lemma_pow_add g (2 * e') b;\n//  assert(pow g e = pow g (2 * e') * pow g b);\n    let r = if b = 0 then 1 else g in\n//  assert(r = pow g b);\n//    let g' = pow g e' in\n//  assert(fast_pow g e = g' * g' * r);\n    lemma_pow_mul g e' 2\n//  assert(pow g e = pow g' 2 * r);\n//  assert_norm(pow g' 2 = g' * g')\n","line":57,"column":0}}
{"kind":"response","query-id":"14","status":"success","response":[]}
;;; Complete message received: (status: "success"; message: ((kind . "response") (query-id . "14") (status . "success") (response)))
;;; Queue is empty (11 overlays)
>>> {"query-id":"15","query":"pop","args":{"dummy":null}}
{"kind":"response","query-id":"15","status":"success","response":null}
;;; Complete message received: (status: "success"; message: ((kind . "response") (query-id . "15") (status . "success") (response . :json-null)))
;;; Queue is empty (10 overlays)
;;; Processing queue
>>> {"query-id":"16","query":"push","args":{"kind":"full","code":"\n// You will need the lemmas from exercises 2 and 3\n// Hint: think how to relate e to e/2 and e%2\n\nlet lemma_fast_pow g e =\n  if e = 0 then () else\n    let e' = e/2 in\n    let b = e%2 in\n//  assert(e = 2 * e' + b);\n    lemma_pow_add g (2 * e') b;\n//  assert(pow g e = pow g (2 * e') * pow g b);\n    let r = if b = 0 then 1 else g in\n//  assert(r = pow g b);\n//    let g' = pow g e' in\n//  assert(fast_pow g e = g' * g' * r);\n    lemma_pow_mul g e' 2\n//  assert(pow g e = pow g' 2 * r);\n//  assert_norm(pow g' 2 = g' * g')\n","line":57,"column":0}}
{"kind":"response","query-id":"16","status":"failure","response":[{"level":"error","message":"could not prove post-condition","ranges":[{"fname":"<input>","beg":[56,42],"end":[56,66]}]}]}
;;; Complete message received: (status: "failure"; message: ((kind . "response") (query-id . "16") (status . "failure") (response ((level . "error") (message . "could not prove post-condition") (ranges ((fname . "<input>") (beg 56 42) (end 56 66)))))))
;;; Highlighting issues: ([cl-struct-fstar-issue error ([cl-struct-fstar-location /Users/jkas/Documents/fstar/RSA.fst 56 56 42 66]) could not prove post-condition])
;;; Queue is empty (10 overlays)

I can reproduce (almost) this trace on my Linux machine using the <IP_ADDRESS> binary release (only small difference is that a success and a failure are flipped).
test3.out.zip
I cannot reproduce this using F* master (all queries succeed).
test2.out.zip

Thanks. Can you include the original file, too?

Note that Z3 can behave differently in incremental mode (which the IDE uses, whereas the command line doesn't). That could explain some of the differences.
I'm not sure why master would be better behaved. I did make fixes to the backtracking logic, but I wouldn't expect them to fix instances of flakiness. It'd be interesting to --log_queries and compare the outputs for the two files.


Add Workday Implementation

Ping me for assistance.

suggesting we don't add a Workday implementation. The Workday implemented sig suit is of type JcsEd25519Signature2020 https://identity.foundation/JcsEd25519Signature2020, its similar but not the same.
I think this may create confusion for an external implementer when looking at the submitted implementations.

Closing, workday declined to implement JsonWebSignature2020 or VC-JWT.


Nix package is missing meta.mainProgram attribute

Output of running lib.getExe against the package:
trace: warning: getExe: Package "python3.11-makejinja-2.5.0" does not have the meta.mainProgram attribute. We'll assume that the main program has the same name for now, but this behavior is deprecated, because it leads to surprising errors when the assumption does not hold. If the package has a main program, please set `meta.mainProgram` in its definition to make this warning go away. Otherwise, if the package does not have a main program, or if you don't control its definition, use getExe' to specify the name to the program, such as lib.getExe' foo "bar".

It seems that poetry2nix does not add meta.mainProgram by default. I fixed this by adding a custom meta attribute to the derivation, including a description and proper license information. Thanks for the report! The changes are available in https://github.com/mirkolenz/makejinja/releases/tag/v2.6.0 (the CI pipeline is still running and may take a few minutes to complete).

Thanks :)


When I open Scrcpy, it displays a black window, but I can still interact with and click on elements.

This issue is similar to #3229.
Environment:
OS: Windows 10
scrcpy version: 2.6.1
Installation method: Attempted manual installation by cloning the repository
Device model: Nothing A063
Android version: 13
I've followed the solutions suggested in issue #3229, but unfortunately, none of them resolved the problem. Restarting both the device and the PC didn't help either.
C:\\\\\scrcpy-win64-v2.6.1\scrcpy.exe
[server] INFO: Device: [Nothing] Nothing A063 (Android 13)
INFO: Renderer: direct3d
INFO: Texture: 1080x2400

If you record (scrcpy --record=file.mp4), is the recorded file "black"?
Does it happen with all apps opened on the device? Or only those with "flag secure" (#36 #2129)?

If you record (scrcpy --record=file.mp4), is the recorded file "black"?
Does it happen with all apps opened on the device? Or only those with "flag secure" (#36 #2129)?

Yes, it records perfectly.
2)No, the issue affects all apps, including the home screen, not just specific ones.

Oh No , Okay thanks. I'll dig into it a bit more


Adding '_' to allowed chars.

Adding "_" to chars.

👍

:+1:

Coverage remained the same at 8.635% when pulling c4af0ac6a6d67f29587c6849893c51851fb5eccd on database-name-fix into 48ec6b35b9876b05621402ffce038aba85ffa4be on master.

Coverage remained the same at 8.635% when pulling c4af0ac6a6d67f29587c6849893c51851fb5eccd on database-name-fix into 48ec6b35b9876b05621402ffce038aba85ffa4be on master.


B-17574 Add Column for Partial Payment Amount

B-17574 Add Column for Partial Payment Amount
Summary
Added column in database for partial payments - located in the payment_requests table - using migration file.
With the potential of having multiple payment requests, it was decided to store as an array of int4 that will represent the dollar amount of the payment request in cents (for example, $103.74 will be stored as 10,374).
Setup to Run the Code

Instructions for starting storybook
Instructions for starting the MilMove application
Instructions for running tests

Database
Any new migrations/schema changes:
Added migration file<PHONE_NUMBER>4545_add_column_for_partial_payments.up

Warnings

:warning:
Please add the JIRA issue key to the PR title (e.g. MB-123)

  Generated by :no_entry_sign: dangerJS against 8058e14f6d1e0d2e7da37affbd1d953f3edb15b0


Added arg to fetch usb speed and Myriad X serial number

XLinkConnect() in the wrapper takes an extra argument which will hold the serial number and the usb speed from the connection.
Previous added similar requests on Boot functions which I removed since it was not necessary.

I'd prefer not to change the interface of functions in Xlink because you have to propagate it through different layers, would be better saving the metadata in an internal structure in Xlink and accessing through a getter. @saching13

Please refactor this as @szabi-luxonis mentioned.
Consider exposing this data in a structured manner with added API instead of changed. Prefer structured data: XLinkPublicDefines.h: struct/enum Speed / UsbSpeed which holds the actual speed type, and similar for serial number.
Don't deserialize to a char* in a human readable form and send that around, prefer strong types.
Be aware that XLink is Win/Mac&Linux as well as USB & PCIe so try to make minimal changes, which remain platform independent.

Please refactor this as @szabi-luxonis mentioned.
Consider exposing this data in a structured manner with added API instead of changed. Prefer structured data: XLinkPublicDefines.h: struct/enum Speed / UsbSpeed which holds the actual speed type, and similar for serial number.
Don't deserialize to a char* in a human readable form and send that around, prefer strong types.
Be aware that XLink is Win/Mac&Linux as well as USB & PCIe so try to make minimal changes, which remain platform independent.

@themarpe @szabi-luxonis Used enum like you mentioend for the speed and created a static variable to store it and added a getter to acces it. And as of the Mx serial id I used a char array and created a getter for it too. I am not sure if char array is the right way to do it in 'C'. If there is a better way, open to suggestions.


Temp Humidity module resetting

Temp humidity 18-v1.0A  module keeps on resetting/disconnecting.
Temp Humidity malfunction.txt

will reprogram to see if it helps


Allow plotting categorical data

[x] Closes #4260
[ ] Tests added
[ ] Passes pre-commit run --all-files
[ ] User visible changes (including notable bug fixes) are documented in whats-new.rst
[ ] New functions/methods are listed in api.rst

a = xr.DataArray(
    [0, 1, 2],
    dims=("dim_1"),
    coords=dict(dim_1=(["dim_1"], ["u", "v", "w"])),
)
a.plot()

a = xr.DataArray(
    [[0, 1, 2], [3, 4, 5]],
    dims=("dim_0", "dim_1"),
    coords=dict(dim_0=(["dim_0"], [0, 1]), dim_1=(["dim_1"], ["u", "v", "w"])),
)
a.plot()

Are there any related tests for this that can be extended?

Turns out ax.imshow has some support for strings in the sense that it convert it to integers. So I had to some formatting to get the ticklabels back to strings.
a = xr.DataArray(
    [[0, 1, 2], [3, 4, 5]],
    dims=("dim_0", "dim_1"),
    coords=dict(dim_0=(["dim_0"], [0, 1]), dim_1=(["dim_1"], ["u", "v", "w"])),
)
a.plot.imshow()

Thanks @Illviljan this is great work!


Sync precommit config from main

Description
This PR syncs the pre-commit config from main branch. As of now forward merging of 4.18 to main is causing lint checks to fail for main.

Types of changes

[ ] Breaking change (fix or feature that would cause existing functionality to change)
[ ] New feature (non-breaking change which adds functionality)
[ ] Bug fix (non-breaking change which fixes an issue)
[ ] Enhancement (improves an existing feature and functionality)
[x] Cleanup (Code refactoring and cleanup, that may add test cases)

Feature/Enhancement Scale or Bug Severity
Feature/Enhancement Scale

[ ] Major
[ ] Minor

Bug Severity

[ ] BLOCKER
[ ] Critical
[ ] Major
[ ] Minor
[x] Trivial

Screenshots (if appropriate):
How Has This Been Tested?

List of files with conflicts while merging with main

@weizhouapache can you agree with this?

@weizhouapache can you agree with this?

@DaanHoogland
yes, looks good


Forgot password translations

Hi,
I am having issues with translations when using 'Forgot Password' functionality. The email sent to the user is in english and the dialogs for setting new password and the following dialog that confirms the correct operation are in english. The client behaves correctly with the language I have chosen for my site (italian).
What can I do to translate these messages and customize email content sent to the client in case of forgot password?
Regards,
Giuseppe

Try putting this somewhere on server, it should do the work. Both methods have user as param, and the method for body part also has url which represents password reset link.
Accounts.emailTemplates.resetPassword.subject = function (user) {
    return "SUBJECT";
};

Accounts.emailTemplates.resetPassword.text = function (user, url) {
    return "Reset password by clicking " + url;
};

Regarding form labels, I found out how to change message that appears when user successfully sets password, so I guess you can change other messages in similar manner:
AccountsTemplates.configure({
texts: {
        info: {
            pwdSet: T9n.get('passwordSet')
        }
    }
});

Thank you.
For what concerns email templates text it works as you suggested. Starting from your suggestion I have found this resource that explains it: https://gentlenode.com/journal/meteor-20-verify-an-email-with-meteor-accounts/42
For labels it doesn't work for forgot password. I am going to further investigate to better understand the issue.
Regards,
Giuseppe

Ciao Giuseppe,
some accounts-t9n keys are still to be translated and are currently missing.
Please see #123 and Define Translations for accounts-t9n.

@gicat let me know if you need further help!

Ciao Luca,
the issue seems not related to meteor-useraccounts, but to meteor/packages/accounts-ui-unstyled/login_buttons_dialogs.html. Here text are not managed by any framework, but in plain english. For example the confirmation dialog (
Thanks.
Giuseppe

oh, ok.
I though you were using useraccounts.
Ciao!

Yes, I am using useraccounts, I have configured AccountTemplates to display the showForgotPasswordLink. For what I understood, the form for managing the forgot password use case is from useraccount, while the part that manages the dialog for changing the password from the email link that arrives to the user, is contained in accounts-ui project of Meteor. I haven't found any code that contains this logic inside useraccounts. Is this correct?
Ciao,
Giuseppe

...oh, in this case: it's all about useraccounts!
make sure you get a link like this:
http://localhost:3000/reset-password/jEoy9dwo48kckijpH9wbU3g_TluR-XWJoxvp1h6Url7
...and remove accounts-ui ;-)

Thank you, now it works correctly. I hadn't removed accounts-ui.
Just another question: in the generated url that arrives in the email the url has the following format:
http://localhost:3000/#/reset-password/jEoy9dwo48kckijpH9wbU3g_TluR-XWJoxvp1h6Url7
I don't know where '#' came from. Did you experienced such issue? For the moment i will parse the url and remove the '#'.
Thanks a lot.
Ciao,
Giuseppe

make sure you configured all necessary routes

i have the same issue  with hash '#' in the link
how can i fix this problem


KAFKA-2607: Review Time interface and its usage

This change adds some documentation and changes some calls from using absolute time to relative time.
Since I am new to the Kafka codebase I will mark the locations where I made the change from absolute to relative times to make it easier for reviewers to find any bugs that I might have introduced.

In addition to nanotime being relative, it is also much slower (http://stackoverflow.com/questions/19052316/why-is-system-nanotime-way-slower-in-performance-than-system-currenttimemill) and more precise (but not necessarily more accurate.
Since it is much slower I suggest not having the millisecond-level relativeTime - there is no reason to pay additional performance cost for no extra precision. It is seriously misleading (and perhaps you even mislead yourself...)
Regarding whether the other names make sense, I'll defer to @ijuma who created the original JIRA.

One other advantage of System.nanoTime is that it is monotonically increasing. With regards to the performance cost, here's a thorough and reliable analysis on the cost of System.nanoTime:
http://shipilev.net/blog/2014/nanotrusting-nanotime/
I was unable to find an analysis of similar quality for System.currentTimeMilllis. We should definitely quantify the performance difference (particularly on Linux) before we choose one way or another.
Also, it would be good to do KAFKA-2247 before we do this.

Quantifying the performance differences will be great, but regardless - there is an important qualitative difference - on our target OS (Linux and Windows), currentTimeMillis does not require an interrupt and nanoTime does. Interrupts are a whole different story on systems that are already running at capacity (since they cause the process to lose its place on CPU queue, which on congested systems can be a huge time sink). For this reason I think its important to avoid nanoTime when at all possible.

@gwenshap Yes, the impact on machines running at capacity is very important indeed. Aleksey covered this in the blog post above and he called it the scalability challenge. It's a shame that the blog post from David Holmes (https://blogs.oracle.com/dholmes/entry/inside_the_hotspot_vm_clocks) is from 2006 and a bit Windows-centric. It would be quite handy to have updated blog post as many things have changed since then (at all levels, CPUs, OSes, JVMs).

For Mac OS X, some numbers are available here: https://bugs.openjdk.java.net/browse/JDK-8040140?focusedCommentId=13484433&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-13484433
System.nanoTime becomes more costly than System.currentTimeMillis as the number of threads increases.

http://pzemtsov.github.io/2017/07/23/the-slow-currenttimemillis.html indicates that nanoTime and currentTimeMillis perform similarly on Linux. Given that, it seems like this PR should be OK (after rebase).


bump Vue 3.4.19

I don't understand why you're doing the version bump manually instead of letting dependabot doing it automatically.

@murdos because the version is not updated since 3.4.13
that's why...

and sometimes it's interesting to watch the version bump (ex: #9004 ) ....

@murdos because the version is not updated since 3.4.13

Hmm... what would be interesting is to investigate why it's not updated automatically :/

at least I noticed it!
so this PR is not "interesting" ... you can close this PR if you want and find a better solution ...

Closing in favor of #9009: we'll then see if dependabot is able to update vuejs automatically.

@renanfranca : I did not succeed in founding the root cause of dependabot not doing the update. I've opened #9030 to track the issue for future vuejs releases, and I propose to manually update vuejs version with your PR :+1:

@murdos ok I update this PR

@qmonmert : Thanks!


Documentation Bug: Default is InheritableThreadLocal, but doc states ThreadLocal

Documentation for 3.3.x and 4.0.0 states in 4.8:
"By default it is stored in a ThreadLocal".
See Chapter 4.8
This is not correct. It is in fact InheritableThreadLocal by default.
See (3.3.x):
https://github.com/grails-plugins/grails-spring-security-core/blob/3.3.x/plugin/grails-app/conf/DefaultSecurityConfig.groovy#L346
and (master):
https://github.com/grails-plugins/grails-spring-security-core/blob/master/plugin/grails-app/conf/DefaultSecurityConfig.groovy#L346
I strongly recommend to change the default back to ThreadLocal, as InheritedThreadLocal can lead to strong - and hard to debug - security issues in multi-threaded applications. See #587

The docs are now correct as the default has been switched back to ThreadLocal.  Here is the commit that changed it back: https://github.com/grails-plugins/grails-spring-security-core/commit/59e13d8fa07a75d0f648c74b48ca3d3d38229b0f


Update enum of billing timegrain for budget API

Latest improvements:
MSFT employees can try out our new experience at OpenAPI Hub  - one location for using our validation tools and finding your workflow.

Contribution checklist:

[* ] I have reviewed the documentation for the workflow.
[* ] Validation tools were run on swagger spec(s) and have all been fixed in this PR.
[ *] The OpenAPI Hub was used for checking validation status and next steps.

ARM API Review Checklist

[ ] Service team MUST add the "WaitForARMFeedback" label if the management plane API changes fall into one of the below categories.
adding/removing APIs.
adding/removing properties.
adding/removing API-version.
adding a new service in Azure.

Failure to comply may result in delays for manifest application. Note this does not apply to data plane APIs.

[ ] If you are blocked on ARM review and want to get the PR merged urgently, please get the ARM oncall for reviews (RP Manifest Approvers team under Azure Resource Manager service) from IcM and reach out to them.
Please follow the link to find more details on API review process.

Automation for azure-sdk-for-js

Automation for azure-sdk-for-ruby

Automation for azure-sdk-for-net
A PR has been created for you:
https://github.com/azure/azure-sdk-for-net/pull/5735
.NET SDK Commits:
https://github.com/adxsdknet/azure-sdk-for-net/pull/5735/commits/cbdad95331cbde442cbd1f65843b387c768e1acf

Automation for azure-sdk-for-python

Can one of the admins verify this patch?

@azuresdkci @praries880 Would like to abandon this PR, as the changes will be updated with a new API version soon.

Automation for azure-sdk-for-go
Encountered an unknown error: (azure-sdk-for-go)
Traceback (most recent call last):
  File "/usr/local/lib/python3.6/dist-packages/azure_devtools/ci_tools/github_tools.py", line 33, in exception_to_github
    yield context
  File "/usr/local/lib/python3.6/dist-packages/swaggertosdk/restapi/github.py", line 168, in rest_handle_action
    return rest_pull_open(body, restapi_repo, sdk_pr_target_repo, sdkbase, sdk_tag)
  File "/usr/local/lib/python3.6/dist-packages/swaggertosdk/restapi/github.py", line 178, in rest_pull_open
    rest_pr_management(rest_pr, sdk_pr_target_repo, sdk_tag, sdk_default_base)
  File "/usr/local/lib/python3.6/dist-packages/swaggertosdk/restapi/github_handler.py", line 151, in rest_pr_management
    sdk_tag=sdk_tag
  File "/usr/local/lib/python3.6/dist-packages/swaggertosdk/SwaggerToSdkNewCLI.py", line 254, in generate_sdk_from_git_object
    with manage_git_folder(gh_token, Path(temp_dir) / Path("rest"), branched_rest_api_id, pr_number=pr_number) as restapi_git_folder, \
  File "/usr/lib/python3.6/contextlib.py", line 81, in __enter__
    return next(self.gen)
  File "/usr/local/lib/python3.6/dist-packages/azure_devtools/ci_tools/github_tools.py", line 272, in manage_git_folder
    clone_to_path(gh_token, temp_dir, split_git_id[0], branch_or_commit=branch, pr_number=pr_number)
  File "/usr/local/lib/python3.6/dist-packages/azure_devtools/ci_tools/github_tools.py", line 212, in clone_to_path
    repo.git.checkout(branch_or_commit)
  File "/usr/local/lib/python3.6/dist-packages/git/cmd.py", line 548, in <lambda>
    return lambda *args, **kwargs: self._call_process(name, *args, **kwargs)
  File "/usr/local/lib/python3.6/dist-packages/git/cmd.py", line 1014, in _call_process
    return self.execute(call, **exec_kwargs)
  File "/usr/local/lib/python3.6/dist-packages/git/cmd.py", line 825, in execute
    raise GitCommandError(command, status, stderr_value, stdout_value)
git.exc.GitCommandError: Cmd('git') failed due to: exit code(128)
  cmdline: git checkout abe5e9e4568210a3d13741162c8b2cff72836a2d
  stderr: 'fatal: reference is not a tree: abe5e9e4568210a3d13741162c8b2cff72836a2d'

Automation for azure-sdk-for-java


World Advancement Progression: Hildir quest

With the recent update, players on my server lost the ability to track the Hildir quest individually and cannot regain access to the ability to purchase items from her.

Hi @Mistermycelium,
The Hildir items unlock once the player turns in the chest. When using private keys each player would have to individually turn in a chest. Players can check if they have access to the keys by using the "listprivatekeys" console commands and there will be the keys Hildir1, Hildir2, Hildir3 for each of the chests turned in. I tested to make sure it was still working and it appears to function correctly. Can you check that your players are turning in the chests and have these keys in their private lists? If you send me your config file I can also make sure the settings are set up as you would expect them to work.
If you have discord that is the fastest way to receive help from me, just mention this post if you reach out to me there. Otherwise I will check back for a response here as fast as possible.

I'm sorry for the bug report. The server crashed last night and after restarting it seems like it's all functional again. It looks like I have some work to do tracking down why the server is having issues.