XSS Filter

Here comes the new XSS Filter. It is activated for all Endpoints now. I have no clue if we should remove stuff from the ESAPI.properties file... I always only found these huge examples but as far as I understood we only really need lines 105, 109 and 114.

 Mitigate XSS Attacks


Loses positions of nodes

For the graph below with the layout option "preset" initial positions of the nodes are lost
<?xml version="1.0" encoding="UTF-8"?>
<graphml xmlns="http://graphml.graphdrawing.org/xmlns"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://graphml.graphdrawing.org/xmlns
     http://graphml.graphdrawing.org/xmlns/1.0/graphml.xsd">
  <graph id="G" edgedefault="undirected">
    <node id="n0"/>
	    <data key="x">122.50374073928583</data>
		<data key="y">367.98329788349827</data>
    <node id="n1"/>
	    <data key="x">100</data>
		<data key="y">300</data>
    <node id="n2"/>
	    <data key="x">150</data>
		<data key="y">300</data>
    <node id="n3"/>
    <node id="n4"/>
    <node id="n5"/>
    <node id="n6"/>
    <node id="n7"/>
    <node id="n8"/>
    <node id="n9"/>
    <node id="n10"/>
    <edge source="n0" target="n2"/>
    <edge source="n1" target="n2"/>
    <edge source="n2" target="n3"/>
    <edge source="n3" target="n5"/>
    <edge source="n3" target="n4"/>
    <edge source="n4" target="n6"/>
    <edge source="n6" target="n5"/>
    <edge source="n5" target="n7"/>
    <edge source="n6" target="n8"/>
    <edge source="n8" target="n7"/>
    <edge source="n8" target="n9"/>
    <edge source="n8" target="n10"/>
  </graph>
</graphml>

AFAIK, graphml format doesn't include a separate structure or keyword for the position information. It is also given as a data element, so extension stores that information in node's data field. Position information can be reached from node's data field after import.
In my opinion, estimating position information from a data element and assigning it directly to the node's position field is not so convenient. Because, user may define position information with different names. (In the above file, it is x and y, but in another file it can be xPos and yPos.)

@hasanbalci Does this extension recognize any of these ways to specify location? Can we perhaps make it recognize some commonly accepted location and dimension specification keywords?

No, it doesn't recognize. But maybe we can specify 'x' and 'y' for position and 'width' and 'height' for the dimension.

@JustDoIt1999 Could you please work on this and modify this extension to recognize 'x', 'y', 'width', and 'height'?

Yeah, of course

A node in my graphml looks like this
<node id="n0">
      <data key="d0">
        <y:ImageNode>
          <y:Geometry height="48.0" width="48.0" x="-24.0" y="694.0"/>
          <y:Fill color="#CCCCFF" transparent="false"/>
          <y:BorderStyle color="#000000" type="line" width="1.0"/>
          <y:NodeLabel alignment="center" autoSizePolicy="content" backgroundColor="#FFFFFF" fontFamily="Dialog" fontSize="12" fontStyle="plain" hasLineColor="false" height="18.701171875" modelName="sides" modelPosition="e" textColor="#000000" visible="true" width="39.34375" x="52.0" y="14.6494140625">Server</y:NodeLabel>
          <y:Image refid="1"/>
        </y:ImageNode>
      </data>
      <data key="d1"/>
</node>

I am interested in the nodes position x and y. Since position cannot be recognized by the library, Can you guide me how can I access that manually? @PermanAtayev

You can access it as follows:
let obj = {}; obj["position"] = { x: parseInt(ele.data('x')), y: parseInt(ele.data('y')) };
where ele is a node in cytoscape.js
@zeeshanullah

I already tried this but it returns NaN for both values.
$graph.children("node").each(function () {
      var $node = $(this);

      var settings = {
        data: {id: $node.attr("id")},
        css: {},
        position: { x: parseInt($node.data('x')), y: parseInt($node.data('y')) }
      };

@PermanAtayev

This type of graphml is not supported by the extension, please use the format I provided for this issue.


Improve error messages for when operation errors due to missing target (e.g. deleted app/space/org)

Currently, when using the CloudExplorer to stop/start/delete an app which has been deleted outside the IDE (i.e. the tree view is not in sync with the real CF foundation), an error window is raised with the message "Unable to stop/start/delete {app name}."
This message could be made more explanatory; it could describe that the reason for the error is that the app didn't exist at the time the start/stop command was issued. In the case of an app deletion, we could improve the UX even further and not raise any error when trying to delete an already-deleted app.

Need to validate the error handling now that we changed to use CFAPI calls.

Current error from trying to start a "stale" (i.e. shown in tree view but actually non-existent) app:
Title: Encountered an error while starting app 'app-1-1-1'
Message: Something went wrong while trying to start app 'app-1-1-1': Response from POST /v3/apps/2bbeb572-ace9-41c7-983d-74955e8bd2ed/actions/start was NotFound.

get rid of "something went wrong"
add in "see logs for more details"


Rethink the credential we used in Python test source code and recording files

Current Status
We already setup the cred scan steps in aggregate-report, and we can check the error report here: link
However, team keeps checked in new files containing new keys which failed the pipeline.
Open Issues to address
We have the suppression file to suppress some of the existing issues.
It is a huge effort if we suppress all newly detected keys in suppression file, since most reported cases are false positive. However, blindly suppress the key probably hide the real issues. Therefore, we have to rethink how we generate those keys and reuse them as many as possible.
Facts
Currently, we basically have 3 types of errors:

Placeholder key/secret in test src code. E.g password = "123".
We'd better to reuse the fake key inside of the suppression file instead of generating new ones for new tests.
Files only which contain the key, mostly appears in keyvault and identity. E.g client.jks, pemCert.pem
If any new service needs to reuse the same key, it is better to move the key files into some common space, so we do not need to suppress them one by one for each service.
(Important) SAS, share key, web hook token, hashkey etc
For this category, we saw a lot of random generalized key/secret/token. Team is better to review how each service generates those keys, and whether we can share the same type of key for all services, so that we can reuse and suppress certain amount of keys only. Can we reuse redact string instead of real ones?

Update 2/26: Storage is in the process of adding self.scrubber.register(key, <scrubbed_value>) which will remove ~40% of these issues.

Update 3/2: Added several fake_mgmt_settings.py files to be ignored.

We now have a strategy for handling these scenarios that should satisfy this issue. There's a central, shared fake_credentials.py file where multiple packages can share sanitization strings, and this is being publicized by a CredScan process guide that describes best practices for resolving warnings. There's an ongoing effort to make fake_credentials.py use more widespread, but the process is in place.


require javascript files from the embedded js block

Is your feature request related to a problem? Please describe.
I would like to define some common javascript functions that could be used in the whole .http file, or locally for a single request. I would like to allow require statement in this case.
Describe the solution you'd like
< {%
    const mylib = require('scripts/common.js');
    mylib.prepareEnvs();
%}

It would be nice if there is a single block at the beginning of the .http file that is run for every request.
Describe alternatives you've considered
Other things I have considered is syntax like:
< scripts/common.js
< {% prepareEnvs(); %}
Here I'm not sure whether we just import all functions in the module globally.
Additional context
Add any other context or screenshots about the feature request here.

require should be available in the javascript runtime that rq uses (goja) but I haven't tested it. I'm curious so I will set up some tests with it.
I'm not sure about the best syntax to use for embedding file-scoped scripts in an .http file, if a file starts with a script block then we can treat it as a file-scoped script is one possibility, as you suggested.
For implementation, there are a few considerations. rq is creating a goja instance usually for each request, unless the caller decides to embed a single runtime in the go Context using WithRuntime. It may be OK to use this pattern so we simply run the file-scoped scripts once into a runtime and then share that runtime across all requests in the file. However, this removes runtime isolation between request executions so global variables or functions defined in the request scope may bleed into other requests. Another approach would be to add a context value for additional Pre-Request scripts and we can extract and execute these before applying the request-scoped pre-request scripts.
ex.,
requests, _ := ParseRequests(`
### Get Foo
GET {{host}}/foo/{{fooId}}
`)
ctx := WithSetupScripts(`const fooId = 'bar'`)
for _, req := requests {
 req.Do(ctx) // creates a new Runtime and runs the scripts setup scripts
}

alternatively,
ctx := context.Background()
requests, _ := ParseRequests(`
< {% const fooId = 'bar' %}

### Get Foo
GET {{host}}/foo/{{fooId}}
`)

for _, req := requests {
 req.Do(ctx) // creates a new Runtime and runs the scripts setup scripts
}

Where const fooId = 'bar' is added to a Request property that is executed before the Pre-Request scripts is also possible.
Do you have a better proposal for a solution?


Not found error when using container

When using this action with this configuration:
name: Comment translation list
on: push

jobs:
  translations:
    runs-on: ubuntu-latest
    container:
      image: leviy/build-image
    steps:
      - name: Find comment with added translation keys
        uses: peter-evans/find-comment@v1
        id: findComment
        with:
          issue-number: ${{ github.event.pull_request.number }}
          comment-author: 'github-actions[bot]'
          body-includes: New added translation keys

We are using this docker image: https://hub.docker.com/r/leviy/build-image
It fails with this error:
Run peter-evans/find-comment@v1
/usr/bin/docker exec  b2e6705e275dc30ba9e27b1ee7700ff5c555983034fb2f2dd3fbfdad957083ac sh -c "cat /etc/*release | grep ^ID"
Error: Not Found

We don't have this with other actions, for example this one: necojackarc/auto-request-review

Hi @tlsvda
You are running the workflow on a push event, but trying to get the issue number from a pull_request event context.
My guess is that github.event.pull_request.number is blank, and that leads to issue-number becoming 0. It tries to find an issue with number 0, and raises a 404 Not Found.

Issue has been resolved, thanks for the help @peter-evans !


Experiment: Add MSVC 32bit workflows

MSVC 32bit workflows came up in #473 and may help catch 64bit-isms early.

Closing this experimental PR for now.


[INFO]: Wrong "Aktualisiert: ..." / "Updated: ..." - Information on CWA start screen

Android 10 with Android Sicherheitsupdate / Security-Update: 1. Juli 2020
Nokia 7.1, Build: 00WW_4_15C_SP02
Internet: WLAN (only)
CWA-Version: 1.2.1
Hello,
to see the little problem, do...

Start CWA.
If CWA starts with "Prüfung läuft ..." (CWA-Start-Screen) then look at the message "Aktualisiert: ..." ("Updated: ...").
You will see: "Aktualisiert: Gestern ..." ("Updated: Yesterday ..."). / In my case: "Low risk".
Touch the "->" to go to the "Ihr Risikostatus" / "Your Riskstatus" screen.
Here you will see the correct: "Aktualisiert: Heute ..." / "Updated: Today ...".
Tapp on "X" to go back to the start screen again and NOW the correct message "Aktualisiert: Heute ..." / "Updated: Today ..." was displayed.

Instead of executing point 3, it is sufficient, for example, to switch off the smartphone / restart the CWA app.
The indication of the wrong information is repeatable.
Best regards.

Internal Tracking ID: EXPOSUREAPP-2216

Same here. CWA1.2.1, ENF<PHONE_NUMBER>0

Hi @vaubaehn,

Not able to reproduce behaviour after switching off phone and restarting CWA, like suggested above.

Follow steps 1 and 2.
3a. Then, instead to open then ‘Screenshot-Menu’ press the button too short, so the phone goes to ‘stand-by’.
3b. Restart it (e.g. per fingerprint-scanner) and the last CWA-Start-Screen is displayed.
After this, yesterday I saw the correct "Aktualisiert: Heute ..." / "Updated: Today ..." – instead of the wrong 'Gestern ...' / Yesterday ...' display under 2.
But today: after restarting the phone (3b.) the “Prüfung läuft …” is running and then: "URSACHE: 9002, Etwas ist schiefgelaufen. Timeout #998"!
After some tapps to repeat and make screenshots, I see a 'time-out 60000 seconds' and after this the correct “Aktualisiert: Heute ..." / "Updated: Today ...".
So I have actually no additional information.
I'm adding an informal cross-reference in the thread: "URSACHE: 9002, Etwas ist schiefgelaufen. Timeout #998"".

Brief impression of today ...

CWA-Version: 1.2.1
1. Start CWA.

2. If CWA starts with "Prüfung läuft ..." (CWA-Start-Screen) then look at the message "Aktualisiert: ..." ("Updated: ...").
   You will see: "Aktualisiert: **Gestern** ..." ("Updated: **Yesterday** ..."). / In my case: "Low risk".

3. Touch the "->" to go to the "Ihr Risikostatus" / "Your Riskstatus" screen.

4. Here you will see the correct: "Aktualisiert: **Heute** ..." / "Updated: **Today** ...".

5. Tapp on "X" to go back to the start screen again and NOW the correct message "Aktualisiert: **Heute** ..." / "Updated: **Today** ..." was displayed.

Is it possible that the incorrect previous update information ("Aktualisiert: Gestern ..." / "Updated: Yesterday ...") is still displayed in step 4?
And, in this case, only with next step 5 then both on the 'CWA-Start-Screen' and then (after "->" again) on the "Ihr Risikostatus" / "Your risk status" screen the correct update time ("Aktualisiert: Heute ..." / "Updated: Today" ... ") is shown?
Best regards.

Yes, it is possible - CWA 1.3.0.

Related to: https://github.com/corona-warn-app/cwa-app-android/issues/1081

The OPs description sounds like there is an issue with the updated data being passed around via LiveData classes. They are not optimal for this approach and we've addressed quite a few of those issues for upcoming updates
Especially pausing+resuming the UI and the recreation of some UI parts would fit that behavior. I think this behavior could already improve as a side-effect of other changes in 1.6, as we moved a lot of non-UI code from LiveData (suitable for the UI layer) to a more reactive approach using Kotlin Flow (suitable for internal layers), removing the need for UI elements to "manually call refresh" and using patterns where the UI is "notified".
We're checking if this can still be reproduced on newer builds to evaluate whether extra changes are needed, or this will be fixed as a side effected from refactoring for upcoming features.

Android 10 with Android Security Update: September 1st, 2020
Nokia 7.1, Build: 00WW_4_16B
CWA version: 1.6.0
ENF version:<PHONE_NUMBER>0
The problem described in my first post today is under CWA 1.6.0. also occurred.

Android 10 with Android Security Update: September 1st, 2020
Nokia 7.1, Build: 00WW_4_16B
CWA version: 1.6.0
ENF version:<PHONE_NUMBER>0
Hello, here some screenshots from described problem (after the start of CWA and the 'Update...' triggered in this way)...
After CWA-start and 'Update...' (Mainscreen):

After tap to [->]:

Back to Mainscreen (tapped to [X]):

"Covid-19" - Info...

Best regards.

Dear @Jo-Achim, can you reproduce this issue with CWA 1.9.1. Feedback very much appreciated. Best regards, DS.

Corona-Warn-App Open Source Team

No, not at the moment - but I will pay attention again.

@Jo-Achim, thanks for the feedback. We monitor this some more days before, hopefully, we can close this issue as fixed. Bes, DS

Corona-Warn-App Open Source Team

@dsarkar: Hello, I think that after the update, which also led to this change...

the problem of the 'different update dates / times' has been resolved. So I think this issue can be closed.
Many thanks.
Best regards, Joachim.

@Jo-Achim, and community, thanks for the feedback and contributions. We close this issue now. Best, DS

Corona-Warn-App Open Source Team


highlight newlines decorationOptions

VSCode Version: 1.11.2
OS Version: Arch Linux

It seems that when you set decorations, the decoration isn't applied to newlines. In this case, the decoration is being applied across three lines, but as you can see, the newline is not decorated.
Would be nice for this issue: https://github.com/VSCodeVim/Vim/issues/1575

Shares the same root cause as https://github.com/Microsoft/vscode/issues/24711, let's track it in https://github.com/Microsoft/vscode/issues/1688


Add mkdocs-video and termynal plugins.

This PR adds two plugins:

mkdocs-video, allows embedding videos from various sources. See https://pypi.org/project/mkdocs-video/ for more info.
termynal, adds terminal animations, helping to document steps requiring terminal interaction.

Not sure what's happening there in the docker build. It complains about
#24 287.2       Building lxml version 4.9.3.
#24 287.2       Building without Cython.
#24 287.2       Error: Please make sure the libxml2 and libxslt development packages are installed.
#24 287.2       [end of output]

My local image build works, but I'm using build and not buildx.


Explain how recurring works

I haven't found any information about how recurring jobs works.
When is exactly a recurring job scheduled?
If I have an executing window trigger of 10 minutes one hour in future, can I expect to be rescheduled also at a 10 minutes window one hour later than first execution finished?

Are there any updates in docs?

In April 2019 we announced that Firebase Job Dispatcher would be deprecated today, April 7th 2020.  For this reason we are going to close all open issues and archive the repository.  We will also stop supporting FJD for new app installations (such as those targeting sdk versions greater than Android Q).  Existing apps that rely on FJD should continue to function as usual.
While we will no longer work on FJD, we encourage you to migrate to Work Manager which is a superior tool and fully supported by the Android team.
Thank you for taking the time to try the library and provide this feedback.  We sincerely appreciate your effort and we apologize for not addressing it in time.


Fix #331: Correct a few typos

Correct a few typos
Interchange the terms page and offset in "137. Use Conventional Query Strings"

Thank you! :smile:

Please, check that the small corrections make sense and let me know if PR needs to be updated. Would be nice to have a couple of reviewers looking over the corrections 😄

Thanks for reviewing, reverted the hint for "Use Conventional Query Strings [137]" back to the original.

👍

:+1:

👍


Add SequentialPlanner support to Copilot ChatApp

Motivation and Context

See issue/feature request #1137
Description

Add SequentialPlanner support in Copilot ChatApp
Contribution Checklist

[X] The code builds clean without any errors or warnings
[X] The PR follows SK Contribution Guidelines (https://github.com/microsoft/semantic-kernel/blob/main/CONTRIBUTING.md)
[X] The code follows the .NET coding conventions (https://learn.microsoft.com/dotnet/csharp/fundamentals/coding-style/coding-conventions) verified with dotnet format
[X] All unit tests pass, and I have added new tests where possible
[X] I didn't break anyone :smile:

@thomasgobin how have you tested this? Can you share some steps and screenshots?

Hey @thomasgobin, I've been testing the SequentialPlanner with Copilot Chat and results we're seeing aren't deterministic, so we're going to hold off on merging these changes until we can get the SequentialPlanner into a more stable state. I'll keep you posted, but these changes should be enough to get it working in your local environment for your personal use


Create SAS token without user delegation key

Package Name: azure-storage-blob
Package Version: 12.1.0
Operating System: Ubuntu 18.04
Python Version: 3.6.8

Describe the bug
To generate a blob SAS token I need to get a user delegation key since I'm authenticating to the storage service with client id/secret. User delegation keys expire, and this means I have to keep requesting new ones, adding overhead to my application. Is it possible to sign SAS tokens directly with client id/secret credentials?

@rakshith91 to the rescue

Hi @Korijn
Thanks for reaching out!
I don't think you can use the application id/secret to sign the user delegation SAS.
Here is some info about user delegation SAS
Every SAS is signed with a key. To create a user delegation SAS, you must first request a user delegation key, which is then used to sign the SAS. The user delegation key is analogous to the account key used to sign a service SAS or an account SAS, except that it relies on your Azure AD credentials. To request the user delegation key, call the Get User Delegation Key operation. You can then use the user delegation key to create the SAS.
Here is the link of user delegation SAS doc https://docs.microsoft.com/en-us/rest/api/storageservices/create-user-delegation-sas
Let me know if you need any help!

OK, thanks for the info. I will learn to live with it! :)

You can generate a SAS token using the Storage Account Key.

Put the Storage Account Key in Key Vault as a secret
Then use the python sdk to create a KeyVault Client
Get the secret
Create a BlobService client with the key
Generate SAS token from key + BlobServiceClient


Fix IDEFICS dtype

What does this PR do?

This forces the use of bfloat16 for IDEFICS. The issue is that with float16 the 80b model gives garbage output. Let me know if this solution is not appropriate and I'll adjust accordingly. For the details see below.
The current behaviour:
$ curl <IP_ADDRESS>:8080/generate -X POST -d '{"inputs":"What is Deep Learning?","parameters":{"max_new_tokens":20}}' -H 'Content-Type: application/json'
{"generated_text":""}

On closer inspection with:
import requests

headers = { "Content-Type": "application/json"}

query = "What is Deep Learning?"
data = {
    "inputs": query,
    "parameters": {
        "max_new_tokens": 10,
        "return_full_text": True,
        "decoder_input_details": True,
        "do_sample": False,
    },
}

api_url = "http://<IP_ADDRESS>:8080"
response = requests.post(api_url + "/generate", headers=headers, json=data).json()

for i in ['prefill', 'tokens']:
    print(f'### {i}')
    print(repr(''.join([t['text'] for t in response['details'][i]])))

Prints:
### prefill
'<s>WhatisDeepLearning?'
### tokens
'<unk><unk><unk><unk><unk><unk><unk><unk><unk><unk>'
########

With the change in this PR it prints:
### prefill
'<s>WhatisDeepLearning?'
### tokens
'\n\nDeep Learning is a subset of machine'

Note, using the Transformers implementation (with IdeficsForVisionText2Text.from_pretrained) produces the latter (correct) output as well.
This only happens with the 80b model, the 9b model is not as sensitive to the dtype (as also mentioned in the code).
The reason for "forcing" this in the IDEFICS init method, is because if quantization is used, then the dtype cannot be set explicitly. And since it's left as None, it's set to float16 by default here. I.e. there's no other way to manually change the dtype if someone is using quantization:
$ docker run .... ghcr.io/huggingface/text-generation-inference:latest --model-id HuggingFaceM4/idefics-80b-instruct --dtype bfloat16 --quantize bitsandbytes-nf4
.....
2023-10-31T12:42:26.710401Z  INFO shard-manager: text_generation_launcher: Starting shard rank=0
2023-10-31T12:42:30.315734Z ERROR shard-manager: text_generation_launcher: Shard complete standard error output:

Traceback (most recent call last):

  File "/opt/conda/bin/text-generation-server", line 8, in <module>
    sys.exit(app())

  File "/opt/conda/lib/python3.9/site-packages/text_generation_server/cli.py", line 80, in serve
    raise RuntimeError(

RuntimeError: Only 1 can be set between `dtype` and `quantize`, as they both decide how goes the final model.
 rank=0
Error: ShardCannotStart
2023-10-31T12:42:30.414010Z ERROR text_generation_launcher: Shard 0 failed to start
2023-10-31T12:42:30.414044Z  INFO text_generation_launcher: Shutting down shards

Before submitting

[ ] This PR fixes a typo or improves the docs (you can dismiss the other checks if that's the case).
[x] Did you read the contributor guideline,
Pull Request section?
[ ] Was this discussed/approved via a Github issue or the forum? Please add a link
to it if that's the case.
[ ] Did you make sure to update the documentation with your changes? Here are the
documentation guidelines, and
here are tips on formatting docstrings.
[ ] Did you write any new necessary tests?

Who can review?
Anyone in the community is free to review the PR once the tests have passed. Feel free to tag
members/contributors who may be interested in your PR.
@Narsil what do you think?

Hey I checked it out.
Idefics works perfectly fine in both f16 and bf16.
The issue only seems to arise with bitsandbytes-nf4 so I'm guessing the issue is upstream, don't you think ? I mean users shouldn't have to guess if it's float16 or bfloat16 that they should use (and some models are better in float16 for stability, probably idefics too).

@Narsil thanks for looking into it. Could you provide the exact steps that you used to check?
I tested it without the quantization using:
docker run --gpus all --shm-size 1g -p 9080:80 -v /home/user/.cache/huggingface/hub:/data ghcr.io/huggingface/text-generation-inference:latest --model-id HuggingFaceM4/idefics-80b-instruct --sharded true --num-shard 8

That gave the same result that I provided in the description: {"generated_text":""}.
To compare, I also tried with bfloat16, like:
docker run --gpus all --shm-size 1g -p 9080:80 -v /home/user/.cache/huggingface/hub:/data ghcr.io/huggingface/text-generation-inference:latest --model-id HuggingFaceM4/idefics-80b-instruct --sharded true --num-shard 8 --dtype bfloat16

That gave the same result that I provided in the description: {"generated_text":"\nDeep Learning is a subset of Machine Learning"}.
Also, to check other quantization, I tried eetq with:
docker run --gpus all --shm-size 1g -p 9080:80 -v /home/user/.cache/huggingface/hub:/data ghcr.io/huggingface/text-generation-inference:latest --model-id HuggingFaceM4/idefics-80b-instruct --sharded true --num-shard 4 --quantize eetq

That gave the same result that I provided in the description: {"generated_text":""}.
I also made sure that it's the latest Docker image (sha256:298404d862962d6d497a1d1aebb433a37d4e6fae96f2356c2f38b64ee844f15c) and the latest model revision (a14d258b1be2a74a3604483de552c33121a98391).
Regarding the "I mean users shouldn't have to guess if it's float16 or bfloat16 that they should use (and some models are better in float16 for stability, probably idefics too).", I agree, it's quite inconvenient, but I'm not sure that's true. The current implementation explicitly states the opposite (see here):

9b seems to work correctly enough in float16, but 80b seems to be really saturating for f16.

I have also seen cases where bfloat16 certainly worked better than float16.
So, please let me know your testing procedure, in case I missed anything important.

@Narsil do you need more information to narrow down the issue?

Sorry, very busy elsewhere this last few weeks.
I indeed was able to reproduce today, although last time I'm sure I also tested it and couldn't find any issue. Could be some cuda version or something.
In any case 80B does seem to suffer in float16 in inference at least in some circumstances, happy to change the default.
I modified your PR so we still allow users to choose which dtype they want, but we changed the default to bfloat16 so at least it shouldn't required any configuration to get correct behavior.

@Narsil thanks for looking into it and verifying the issue.
As I mentioned in the original post:

The reason for "forcing" this in the IDEFICS init method, is because if quantization is used, then the dtype cannot be set explicitly. And since it's left as None, it's set to float16 by default here.

I.e. the way how you changed it back will still not work if any of the quantization options are used, so this issue is still not resolved.
You can use the same reproduction commands that I included before to verify this.

Indeed, the default is overridden earlier: https://github.com/huggingface/text-generation-inference/pull/1287

Problem is worse than I thought.
9B gives garbage with bfloat16 and works fine with float16
80B is the other way around.
Quantization only work with float16 (definitely the case for all quantization methods aside of potentially bnb, bnb is slow though). Seems like the previous version of the code was the best.
I'll run a few more experiments to try a good default that would fit both cases without having explicit model name if possible.

9B gives garbage with bfloat16 and works fine with float16

Could you provide the exact steps that you used to test that? I cannot reproduce that, for me 9B works the same way with bfloat16 as expected.
For me I used:
docker run --gpus all --shm-size 1g -p 9080:80 -v /home/user/.cache/huggingface/hub:/data ghcr.io/huggingface/text-generation-inference:latest --model-id HuggingFaceM4/idefics-9b-instruct --dtype bfloat16

Then
curl localhost:9080/generate -X POST -d '{"inputs":"What is Deep Learning?","parameters":{"max_new_tokens":10}}' -H 'Content-Type: application/json'

Which returned:
{"generated_text":"\n\nDeep learning is a subset of machine"}

The #1287 PR helps, at least the default dtype is not forced in cli.py.


Wakelock crash on launch

wakelock: 0.5.4 has an issue where it crashes on launch on Flutter 2.5 and thus having chewie as a dependency cashes the app on launch on 2.5. See: https://github.com/creativecreatorormaybenot/wakelock/issues/140
Proposed solution: bump wakelock to 0.5.6 as that contains the fix to get it to work.
Temporary workaround:
dependency_overrides:
  wakelock: 0.5.6

Is this also coming on ios ? I saw this yesterday on Android device only.


Features for new Login App

Describe the issue
We want the login app to duplicate the functionality of the original login app except for the sort order of the displayed accounts.
Additional context
Ideas for future design discussions with technical team:

Bonus points if it uses a widget for the user to change sort order.
Navigation Bar could have things like:
Projects, reporting, monitoring, documentation etc.
top-right will be user configuration,
In the project page, teams can self-serve their user access (automated reporting to the POs of who has access on a monthly basis)
In the project page, it will contain accounts accessible in the project set and this is like a old login accordion.

Definition of done

In the new login app, the sort order defaults to alphanumeric by project name, environment.
We are going to additionally display the billing code, PO name as metadata.
Architected so that if page expires, the next thing you click on it redirects you to the keycloak login page

No longer relevant


Need help with evaluation using structs

Hi,
Apologies if this is a duplicate issue / request. I have the below requirement:
Expression - "foo.a + foo.b"
foo is a struct -
type foo struct {
a int
b int
}
I'm getting runtime errorn when i do the following:
func method6(){
obj := &foo{1, 2}
expression, _ := govaluate.NewEvaluableExpression("foo.a + foo.b")
parameters := make(map[string]interface{}, 8)
parameters["foo"] = *obj
result, err := expression.Evaluate(parameters)
if err != nil{
	fmt.Println(err)
} else {
	fmt.Println(result)
}

}
Kindly help.
Regards,
Asim.

hi, you should keep the field be exported.
Like this:
`
type foo struct {
A int
B int
}
...
expression, _ := govaluate.NewEvaluableExpression("foo.A + foo.B")
`

Thanks a lot. It worked.
Regards,
Asim.
On Sat, Jun 16, 2018 at 3:45 PM hate13<EMAIL_ADDRESS>wrote:

hi, you should keep the field be exported.
Like this:
`
type foo struct {
A int
B int
}
...
expression, _ := govaluate.NewEvaluableExpression("foo.A + foo.B")
`
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/Knetic/govaluate/issues/99#issuecomment-397802807,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AgpQ0DF7-CmSzFEAb0mM4UAYruS1wC7Uks5t9NrHgaJpZM4UlBQP
.


error: unable to find library -lunwind

Cloned didkit and ssi in the same level in a folder
Ran cargo build in the didkit root folder
Ran cd ./lib
Ran make ../target/test/android.stamp

Got this error:
error: linking with `i686-linux-android19-clang` failed: exit status: 1
  |
  = note: LC_ALL="C" PATH="... "-o" "~/Desktop/didkit/target/i686-linux-android/release/deps/libdidkit.so" "-Wl,--gc-sections" "-shared" "-Wl,-z,relro,-z,now" "-Wl,-O1" "-nodefaultlibs"
  = note: ld: error: unable to find library -lunwind
          clang: error: linker command failed with exit code 1 (use -v to see invocation)

error: could not compile `didkit` (lib) due to previous error
make: *** [../target/i686-linux-android/release/libdidkit.so] Error 101"

I ran brew install lunwind:
➜  lib git:(main) ✗ brew install lunwind
Warning: No available formula with the name "lunwind". Did you mean luabind or libunwind?
==> Searching for similarly named formulae and casks...
==> Formulae
luabind

To install luabind, run:
  brew install luabind

I ran brew install luabind:
➜  lib git:(main) ✗ brew install luabind
Error: luabind has been disabled because it is not maintained upstream!

I ran brew install libunwind:
➜  lib git:(main) ✗ brew install libunwind
libunwind: Linux is required for this software.
Error: libunwind: An unsatisfied requirement failed this build.

Use forked repository https://github.com/alan-turing-institute/trustchain-mobile.git
and follow the instructions from install_trustchain_mobile.md file to setup the project.
This is updated latest repo.
Android and iOS running successfully without any issues.


Catch getJWT promise errors

Malformed tokens (undefined, random string) can make payload validation code to throw an Error, that will not be caught and the function that have called getJWT will hang. It would be nicer to catch such error.

It should indeed, thank you! Released as v0.3.2


Job Offer $$$

Come and support the TumblThree project.
You don't need a bachelor, master or PhD to work in our team. English language skills are sufficient.
What you will be working on:

Reading the existing open and closed issues
Categorizing them and moving some to the new Discussions section
Moving issues with questions & answers, or ideas
Leaving discussions about code or implemented features
No text editing or rephrasing necessary, mostly selecting and clicking
Marking unclear issues with a new label for later review
You'll need a couple of hours going through all existing issues

Benefits:

Work remotely
Free time management
The chance to contribute something good to the TumblThree project

Compensation:

No money, but lots of gratitude
An entry in our contributors list
The good feeling of having contributed something to the TumblThree project

This work is limited. Further employment with other duties is possible.
Are you interested? Leave us a short comment.

“There are three kinds of people: Those who make things happen,
those who watch things happen, and those who ask, ‘what happened?’”
— Casey Stengel

Hello @thomas694 , I'd love to take this up.

Hello Emmanuel,
thanks for your support.
Although I believe you have understood the task and know how to organize yourself, I would like to give you some input. And feel free to ask any questions you have.
I have enabled the new discussions section, added you to the repository and given you the required permission to convert the issues.
All issues, currently 267 ones, need to be revised. If an issue, e.g. #248, qualifies for one of the 3 categories "General", "Ideas" (or feature requests) or "Q&A", it can be converted to a discussion entry by clicking on "Convert to discussion", choosing the appropriate category (here Q&A) and confirming the conversion.

Okay,thanks for the clarifications. If I have any questions. I'll do well to reach out to you. Let's get to work :rocket:

All issues, currently 267 ones,. I don't understand this..do you mean there are 267 issues?
Also, I've moved a few open issues to discussions, based on their categories..that's what I'm expected to do right?

There should be up to 267 issue entries, either still open or closed, maybe one or two really aren't accessible any more.
Yes, please go also through the closed issues. If they contain information or answers to a question which a user had, they might be helpful to others in the future too.

Okay, thanks

Thanks a lot @Mannuel25 for helping us.
The new discussions section got enabled and with the converted issues it doesn't look empty any more.

Thanks a lot @Mannuel25 for helping us. The new discussions section got enabled and with the converted issues it doesn't look empty any more.

Thanks for granting me the opportunity as well.


Add basic docker deployment

@zackgalbreath This would be good again. I had to adjust for the client code move.


Sluuuurp

This should be merged sooner than later.

Codacy can go pound sand. The labeler doesn't work with external repositories.

Oh, another nit. The design document should be moved to the repository wiki.

Hello, your friendly libage maintainer :wave:
I might pull some of the utility classes/objects into the former sooner than later; you don't have to use them in this PR, but I figure now might be a good time to prepare :)


"Amazon-Demo-Test" failed with "Error Code: 403"

Steps:

Start "Amazon-Demo-Test" via Jenkins
Test is failed with error message:

"com.amazonaws.services.s3.model.AmazonS3Exception: Forbidden (Service: Amazon S3; Status Code: 403; Error Code: 403 Forbidden; Request ID: TG9FXYFJSXVSEQFW; S3 Extended Request ID: fmYLeFOLarn3uZFB4DLevogRLwyPmh3AFmYrxalzt3uDa9fE1Ts9MuoSnBVtOHkefHkKuqnuo7"

wontfix


Can't remove the existing Cookie

Since i could get the value by using
cookie.get('example);
unfortunately after running the following code
cookie.remove('example', { path: '/' });
i could still get the value.
is there anything wrong about my code, or the remove function not working properly?

Sorry there was a mistake on my working environment.


Clang build issue: Undefined symbols for architecture x86_64 _IOPSGetTimeRemainingEstimate

Sorry for spamming issues, but after solving the first two issues and adding openssl include dir to INTERFACE_INCLUDE_DIRECTORIES I get the following:
[ 84%] Linking CXX executable monero-lws-admin
Undefined symbols for architecture x86_64:
  "_IOPSGetTimeRemainingEstimate", referenced from:
      cryptonote::miner::background_worker_thread() in libcryptonote_basic.a(miner.cpp.o)
      cryptonote::miner::on_battery_power() in libcryptonote_basic.a(miner.cpp.o)
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make[2]: *** [src/monero-lws-admin] Error 1
make[1]: *** [src/CMakeFiles/monero-lws-admin.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....

Adding
list(APPEND IMPORTED_MONERO_LIBRARIES "-framework IOKit")

to the CMakeLists file solved this for me.

This worked for me too.


[SPARK-11582][MLLib] specifying pmml version attribute =4.2 in the root node of pmml model

The current pmml models generated do not specify the pmml version in its root node. This is a problem when using this pmml model in other tools because they expect the version attribute to be set explicitly. This fix adds the pmml version attribute to the generated pmml models and specifies its value as 4.2.

Can one of the admins verify this patch?

@fazlan-nazeem Thanks for finding & fixing this. In general we try and put the name of the JIRA and the component in the title of our PRs (makes it easier to tracking on the pull request dashboard). So you might want to update the title to something like "[SPARK-11582][MLLib] specifying pmml version attribute =4.2 in the root node of pmml models", this will help the correct reviewers find your PR faster :)

@holdenk Thanks for the advice. I have done the changes as you requested.  Please let me know if anything else has to be updated.

Test build #2018 has started for PR 9558 at commit d79c657.

LGTM. 4.2.1 supersedes 4.2 but I don't know that this matters.

LGTM pending tests

Test build #2018 has finished for PR 9558 at commit d79c657.

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

Merged into master and branch-1.6. Thanks!

Thanks for the merge! :)


Request for theming OneTab extension

Name: OneTab
AMO Link: https://addons.mozilla.org/en-US/firefox/addon/onetab/
What needs to be styled: HTML page with saved tabs)

It looks like theming for OneTab has been added to another dark theme by @Izheil.  It would be nice if @overdodactyl could work with him to integrate the color variables so we can mix and match parts of the themes together.  Until then just copy the portion related to OneTab of the css below and paste it into the userContent_customization.css file and run the updater.
https://github.com/Izheil/Firefox-57-full-dark-theme-with-scrollbars/blob/master/Full%20theme%20(except%20scrollbars)/addons.css

@Devo7v Perfect! As a temporary solution this looks good

@Devo7v Sure, I will try

Something like this, it`s not ideal, but at least its dark right now)
/*------ ONETAB ADDON ------*/
@-moz-document url-prefix(moz-extension://4a9c7a19-0d52-4612-bebf-aeef0e6d956b/),
url-prefix(https://www.one-tab.com/page/) {
  html, body {
    background: var(--tone-6) !important
  }

  #settingsDiv {
    background: var(--tone-6) !important;
    border: 1px solid var(--tone-8) !important
  }

  div {
    color: var(--tone-2) !important
  }

  #contentAreaDiv > div {
    border-color: var(--tone-8) !important
  }

  a:link, a, a:visited, .clickable {
    color: #09f !important
  }
  a:hover, .clickable:hover {
    color: #0ff !important
  }
  a:active, .clickable:active {
    color: #0050aa !important
  }

  img[src="images/cross.png"] {
    filter: brightness(200%)
  }

  textarea {
    -moz-appearance: none !important;
    background-color: var(--tone-8) !important;
    color: var(--tone-2) !important;
    border: 1px solid var(--tone-5) !important
  }

  label::before {
    filter: invert(81%) hue-rotate(170deg)
  }
}

Sorry for the slow response here - feel free to reopen or open a new issue if you find any problems or have suggestions!


all are equal in face of the law (no)

Sure we can make an exception for one exceptional guy?

Sorry @C-Pro the princess is in another castle


Xcode10

Issue Link 🔗
Gets SwiftEntryKit compiling with Xcode 10. Arguably fixes https://github.com/huri000/SwiftEntryKit/issues/108
Goals 🥅
Allow an Xcode 10 user to build the SwiftEntryKit demo.
Implementation Details ✏

Update test Cocoapods to compatible versions.
Specify usage of older Xcode build system.

Testing Details 🔍
Run tests, they passed. Launch example, it works.
Screenshot Links 📷
N/A

Hi,
The CI has been failed during the last build.
I cannot approve this pull request until the CI passes again. Have you checked it?
Thanks!

@huri000 The test failures appear to have been spurious issues with Travis. I added a third commit to fix a couple typos I noticed in the doc comments and the tests now pass fine.


GSSOC'2023: Predicting Credit card approvals

💥 Proposal
(A clear and concise description of what the proposal is.)
We will build an automatic credit card approval predictor using machine learning techniques, just like the real banks do. Assign me an issue.

@sadhana70 Can you please provide the link for the dataset you will use? And also please tell us more specifically which ml models you will be using.

https://github.com/sadhana70/Datacamp-Projects/blob/main/Predicting Credit Card Approvals/datasets/cc_approvals.data
I'll be using LogisticRegression and perform grid search using GridSearchCV and also preprocess using MinMaxScaler.

@sadhana70 if there is a kaggle link, please provide it. I will be assigning you the issue.

@sadhana70 - you can go ahead! We are assigning you 21 days for this project, after which it will be assigned to someone else if not completed. All the best!  Name the file as: algorithm_dataset.ipynb and link it in the readme of the labeled directory as algorithm - dataset.

Is this completed? or can i continue with this one?


Workflow name length tests

👍

That invalid_wdl error message starts out ok... and then just goes off the rails. Anywho 👍

@kshakir I think the newlines should make it look much nicer (it's pointing an arrow to the place in your WDL code that it didn't like). But yeah, SEP


#63: Add Configuration.BaseUrl

Add BaseUrl property to Configuration
Add tests for BaseUrl

Looks promising! Will look into this (review PR) probably during next weeks, at most - till the end of first week of Sept

Looks promising! Will look into this (review PR) probably during next weeks, at most - till the end of first week of Sept

Just noticed there are a lot of unnecessary formatting into my commit on existing code(auto alignment by IDE) - tell me if it's needed to be undone, I'll fix it.

@davespoon, yes, please fix it with another commit on this PR

@davespoon, yes, please fix it with another commit on this PR
@yashaka done =)


Namespace plugin: issue with preudo selectors

Hey folks!
It seems that there is something wrong in namespace plugin as output emitted with it looks completely incorrect 😿
And ideas why it happens?
Stylis version: 4.0.6
Input
.foo:before {
  color: red;
}
.foo {
  :before {
    color: red;
  }
}

Output with namespace plugin
before.foo.foo {
  color: red;
}
:before.foo {
  color: red;
}

Output without plugin
.foo:before{color:red;}
.foo :before{color:red;}

The output with the namespace plugin looks wrong. I would classify this as a bug - I won't have time to fix this myself as this plugin lies outside of my interests. I'm encouraging you to play with the codebase to provide a fixing PR.
Note that the actual output without the plugin is this:
.foo:before{color:red;}
.foo :before{color:red;}"

Note that the actual output without the plugin is this:

Yup, updated.

I would classify this as a bug - I won't have time to fix this myself as this plugin lies outside of my interests.

That's fair, if we will take v4 as a dependency I will fix it 👍


SAK-29259 regression: site creation forces site to be added to public index

https://jira.sakaiproject.org/browse/SAK-29259
regression from SAK-27508

Thank you @bjones86 !!

No problem! Thanks for pinging me on this one @ottenhoff :)


Fix #1928 Improve Zephir constant get

Hello!

Type: bug fix
Link to issue: https://github.com/phalcon/zephir/issues/1928

In raising this pull request, I confirm the following:

[x] I have checked that another pull request for this purpose does not exist
[x] I wrote some tests for this PR
[ ] I updated the CHANGELOG

Thanks

@sergeyklay I also think it's reasonable.

Thank you!


give local .bin higher priority

There are other binaries available called sha3sum (e.g. as part of busybox).
As a result, those will be executed, and while they throw an error, that error will be swallowed because of the sha3sum || true call.
As a result, you get a completely wrong hash in the end end well, dig for the reason for quite a while.
This PR will prioritize the downloaded binary over any system binary.
Tbh., I would also recommend removing that || true - it's bound to bring more problems than it solves.

Nice, thanks! Agree with removing || true.


Migrate to new Warrior image, other enhancements

This change detects the old Warrior image (from Docker Hub) by checking for the existence of the /root/docker_container_id.txt file. If it detects the old image, it backs up the user config.json, deletes the container, prunes everything from Docker, and then deletes the /root/docker_container_id.txt file. If the new image or the Watchtower image aren't found, they are installed and configured. Watchtower is configured to run every hour, and to clean up old images. The user configuration is now stored on the host VM and bind mounted into the Docker image so it will survive container updates as well as the complete deletion of the container. Additionally, container names are used instead of container IDs when referring to containers since Watchtower doesn't preserve container IDs after automatic updates. This change also fixes the network statistics indicator.
I have tested this change on versions 3.0 and 3.1 of the Warrior VM image. In particular, I have tested the migration of the user configuration, the persistence of the user configuration, the pruning of old Docker data, and the creation of new containers. I have also tested the creation of new containers when none exist. Watchtower automatic updates should work but hasn’t received a lot of testing.
Some remaining considerations:

Shutting down the VM when the warrior container is stopped will take a few seconds longer because the startup.sh now checks a second time that the container is stopped before shutting down the system. This change was made because Watchtower briefly stops containers before updating them, and I didn't want a warrior container stopped for updates to cause the VM to shut down. Related, the change appears to cause some Docker-related errors to be briefly printed on screen before shut down.
During setup of the Docker container, after running the command needed to enable non-root users to access network stats, the container is restarted. The container is given the default grace period of 10 seconds before the restart is forced. I don't believe restarting the container shortly after its first startup causes problems, but I still thought I would mention it.
Since this change applies to the startup.sh script, the Warrior VMs would need to be rebooted to receive this update. I'm not aware of any regular restart interval for the VM, so users would need to be instructed to restart their VMs, and a restart-VM pseudo-project could briefly be made the default project. This project would need to check if it is running in the current Docker image (perhaps by looking for startup.py), and if it is not, it would need to create the /tmp/warrior_reboot_required file. This reboot project would not affect anyone running the old Warrior Docker image without a VM, and among those running the VM, it would only apply the update for users who have their Warrior set to run the default project. (Currently, statistics indicate that there are about 34 Warrior instances running the default project out of a total of about 48 instances overall, though some of them are likely running the old Docker image without a VM, or are already running the new Docker image.) Additionally, it may make sense to release a new Warrior VM image with these updates already applied.
It seems that many projects still fail inside the new container stating No usable Wget+At found. I do not believe this error is related to my changes.

I haven't tested it yet, but I looked at the changes and I'm not noticing any issues.
The seesaw process in the container schedules a reboot every 7 days so a coordinated effort to get people to reboot isn't strictly necessary.
Also if I understand correctly when making the OVA file, it's no longer desirable to prebake a ready-to-use warrior container into the OVA because the dockerfile changes frequently. Is that correct? If so, when I release version 3.2, the OVA file would be smaller but I will update the readmes saying it will download additional data to install the Docker container before it can fully work.

Yeah it wouldn't be necessary to include a Docker image in the OVA file; if containers named warrior and watchtower aren't found, they are created.

RE chfoo with this. It could be an idea to host a small API endpoint on warriorhq with a link to the docker image in case it ever needs to change again without having everyone redeploy the warrior VMs, but yes as we change the dockerfile with updates/upgrades its handier being able to do this remotely and have watchtower update the code rather than redeploying the VM again.

If so, when I release version 3.2, the OVA file would be smaller but I will update the readmes saying it will download additional data to install the Docker container before it can fully work.

Correct yep it'll pull warrior docker image and watchtower


zapier_app: Add support for private/huddle messages.

@timabbott: I'd really appreciate a review on this one, I had to write a separate helper, but I'm not sure if it necessary for our purposes here (we've never had to send a group PM in webhooks). Maybe just internal_send_huddle_message would suffice? Although that doesn't take request.client into account, from what I can tell! :)

This looks reasonable, but I think it should be called check_send_private_messages_from_emails or something like that.  We reserve the term huddle to refer to a multi-person group PM.

@timabbott: Addressed your comment, merging now! :) Thanks!


python38Packages.pytelegrambotapi: 3.8.3 -> 4.0.0

Automatic update generated by nixpkgs-update tools. This update was made based on information from passthru.updateScript.
meta.description for python38Packages.pytelegrambotapi is: "A simple, but extensible Python implementation for the Telegram Bot API"
meta.homepage for python38Packages.pytelegrambotapi is: "https://github.com/eternnoir/pyTelegramBotAPI"
meta.changelog for python38Packages.pytelegrambotapi is: ""
Updates performed

Ran passthru.UpdateScript

To inspect upstream changes
Impact

Checks done (click to expand)

built on NixOS

Warning: a test defined in passthru.tests did not pass

0 of 0 passed binary check by having a zero exit code.

0 of 0 passed binary check by having the new version present in output.

found 4.0.0 with grep in /nix/store/6cvc0iwqz5yjprkbdcnbapa8dkzppjky-python3.8-pyTelegramBotAPI-4.0.0

found 4.0.0 in filename of file in /nix/store/6cvc0iwqz5yjprkbdcnbapa8dkzppjky-python3.8-pyTelegramBotAPI-4.0.0

directory tree listing: https://gist.github.com/cc720d76e389c1a81ea944d03c008e08

du listing: https://gist.github.com/a71887c8e5da21b40593912944e9206f

Rebuild report (if merged into master) (click to expand)

8 total rebuild path(s)

2 package rebuild(s)

2 x86_64-linux rebuild(s)
2 i686-linux rebuild(s)
2 x86_64-darwin rebuild(s)
2 aarch64-linux rebuild(s)

First fifty rebuilds by attrpath
python38Packages.pytelegrambotapi
python39Packages.pytelegrambotapi

Instructions to test this update (click to expand)

Either download from Cachix:
nix-store -r /nix/store/6cvc0iwqz5yjprkbdcnbapa8dkzppjky-python3.8-pyTelegramBotAPI-4.0.0 \
  --option binary-caches 'https://cache.nixos.org/ https://nix-community.cachix.org/' \
  --option trusted-public-keys '
  nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs=
  cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY=
  '

(The Cachix cache is only trusted for this store-path realization.)
For the Cachix download to work, your user must be in the trusted-users list or you can use sudo since root is effectively trusted.
Or, build yourself:
nix-build -A python38Packages.pytelegrambotapi https://github.com/r-ryantm/nixpkgs/archive/f4584e71fe02bf2a271d8e645abc73f6dcbe4d7d.tar.gz

After you've downloaded or built it, look at the files and if there are any, run the binaries:
ls -la /nix/store/6cvc0iwqz5yjprkbdcnbapa8dkzppjky-python3.8-pyTelegramBotAPI-4.0.0
ls -la /nix/store/6cvc0iwqz5yjprkbdcnbapa8dkzppjky-python3.8-pyTelegramBotAPI-4.0.0/bin

Pre-merge build results
We have automatically built all packages that will get rebuilt due to
this change.
This gives evidence on whether the upgrade will break dependent packages.
Note sometimes packages show up as failed to build independent of the
change, simply because they are already broken on the target branch.
Result of nixpkgs-review run on x86_64-linux 1

2 packages built:

python38Packages.pytelegrambotapi
python39Packages.pytelegrambotapi

Maintainer pings
cc @dasJ for testing.

Result of nixpkgs-review pr 136262 at f4584e71 run on aarch64-linux 1

2 packages built successfully:

python38Packages.pytelegrambotapi
python39Packages.pytelegrambotapi

2 suggestions:

warning: unclear-gpl
gpl2 is a deprecated license, please check if project uses gpl2Plus or gpl2Only and change meta.license accordingly.
Near pkgs/development/python-modules/pyTelegramBotAPI/default.nix:17:5:
   |
17 |     license = licenses.gpl2;
   |     ^

warning: no-python-tests
Test runner could not discover any test cases: ‘Ran 0 tests in 0.000s’
Near pkgs/development/python-modules/pyTelegramBotAPI/default.nix:16:0:
   |
16 |     description = "A simple, but extensible Python implementation for the Telegram Bot API";
   | ^

4.1.0 already in master, see https://github.com/NixOS/nixpkgs/commits/master/pkgs/development/python-modules/pyTelegramBotAPI/default.nix


Concord2

Signed-off-by: shr264<EMAIL_ADDRESS>

Syed,
I think that this request makes the previous request obsolete and it should be dropped.  Is that correct?
 I am not an R programmer, but I was expecting to see the Concord_R function return an array of double precision floats.

Yes, that is true. When I run it in linux on my mac book pro, I am getting a set of reals of length p^2.

From: johnholt<EMAIL_ADDRESS>Sent: Monday, June 29, 2015 2:29 PM
To: hpcc-systems/ecl-ml
Cc: Rahman,Syed
Subject: Re: [ecl-ml] Concord2 (#225)
Syed,
I think that this request makes the previous request obsolete and it should be dropped. Is that correct?
I am not an R programmer, but I was expecting to see the Concord_R function return an array of double precision floats.

Reply to this email directly or view it on GitHubhttps://github.com/hpcc-systems/ecl-ml/pull/225#issuecomment-116786357.

I have been looking at some other Embedded R and see that there is not an explicit return.  I did notice that your Concord_R function has no return type.  I changed my copy to return a set of reals (SET OF REAL8), and this fixed my compile error.
I am getting a link error that the R library is not found on the ML cluster.  Once you fix the export, you may see that error.  I know R support used to be installed on the ML cluster, so I am looking at that.

Syed, we have concluded that we don't want the R implementation visible in the general library.  Please just remove it from the PopulationEstimate module and your test code.  In this case, I would just create an in-line dataset of the correct results for the compare.

Sounds good.
Syed Rahman
Sent from my iPhone
On Jun 30, 2015, at 12:52 PM, johnholt <notifications<EMAIL_ADDRESS>wrote:
Syed, we have concluded that we don't want the R implementation visible in the general library. Please just remove it from the PopulationEstimate module and your test code. In this case, I would just create an in-line dataset of the correct results for the compare.

Reply to this email directly or view it on GitHubhttps://github.com/hpcc-systems/ecl-ml/pull/225#issuecomment-117238972.

You MUST replace the tab characters in the indentation whitespace with blanks, and amend the commit.  You should turn on the commit check as noted in https://github.com/hpcc-systems/HPCC-Platform/wiki/Git-step-by-step as this prevents you from making a commit with whitespace problems.

@johnholt are you happy with the math level review? should I do the code review?

Yes please.

@dabayliss @johnholt Are we planning to merge this?

I believe it has open review comments

We need to resolve them then... Are any of your comments of the "must fix" variety?

All performance nits; but I believe the algorithm was under active review and testing. @shr264 are you and your professor happy with this submission now?

I think it is working correctly. I've been quite busy for the past few months and haven't looked at it since then. As a result, I never got around to making the changes that were suggested. If needed, I can make those changes over the next couple of weeks (I have a short break coming up during the first week of March) but I would need access to the training clusters.
Thanks,
Syed Rahman
Sent from my iPhone
On Feb 5, 2016, at 9:20 AM, David Bayliss <notifications<EMAIL_ADDRESS>wrote:
All performance nits; but I believe the algorithm was under active review and testing. @shr264https://github.com/shr264 are you and your professor happy with this submission now?

Reply to this email directly or view it on GitHubhttps://github.com/hpcc-systems/ecl-ml/pull/225#issuecomment-180376290.

Performance issues raised above are covered by a separate Jira.


feat: structured logging

Overview
Note: this is still a work in progress.
This implements structured logging.
Example
> aws-nuke - 3.0.0-dev - dirty
Do you really want to nuke the account with the ID<PHONE_NUMBER>83 and the alias 'no-alias-637423565883'?
Waiting 3s before continuing.
{"level":"info","msg":"filtered: cannot delete AWS managed key","owner":"us-east-1","prop:ID":"4960b196-e3e1-4f46-b82e-764ae098bada","prop:Manager":"AWS","prop:State":"Enabled","prop:_tagPrefix":"tag","resource":"4960b196-e3e1-4f46-b82e-764ae098bada","state":7,"time":"2024-10-05T23:45:00-06:00","type":"KMSKey"}
{"level":"info","msg":"filtered: cannot delete AWS managed key","owner":"us-east-1","prop:ID":"49faf6ef-ae89-4203-bb29-1bc32be20228","prop:Manager":"AWS","prop:State":"Enabled","prop:_tagPrefix":"tag","resource":"49faf6ef-ae89-4203-bb29-1bc32be20228","state":7,"time":"2024-10-05T23:45:00-06:00","type":"KMSKey"}
{"level":"info","msg":"filtered: cannot delete AWS managed key","owner":"us-east-1","prop:ID":"bfec52f0-a84c-4c78-a305-368918386251","prop:Manager":"AWS","prop:State":"Enabled","prop:_tagPrefix":"tag","resource":"bfec52f0-a84c-4c78-a305-368918386251","state":7,"time":"2024-10-05T23:45:00-06:00","type":"KMSKey"}
Scan complete: 3 total, 0 nukeable, 3 filtered.

No resource to delete.

Running It
Note: this omits standard required options like configs.
aws-nuke --log-format=json

Questions

Should everything be handled by the logging (i.e. version and wait for 3 seconds, etc)
Should properties be prefixed by prop: or should it be stripped

Builds
You can clone and run the following command:
goreleaser build --snapshot --clean --single-target

Resolves #154

Thanks a bunch for working on this! 👊

@kieran-lowe my pleasure. feedback would be appreciated.

Thanks for working on this @ekristen .
Question on the logging format:
How would it look after nuke has run and some resources have been removed, others failed or filtered etc? Will there be a 'Status' with possible values 'removed' | 'filtered' | 'failed' etc that one can then filter on when they process the json output? A useful outcome is a logfile that will enable users of the logfile to put together a summary almost like your https://ekristen.github.io/aws-nuke/cli-usage/#aws-nuke-explain-config summary but more reporting on that the nuke module has managed to do.
To tweak your example a bit, I am picturing something like this:
{"level":"info",nuke-status:"removed","msg":"remove successfully","owner":"us-east-1","prop:ID":"4960b196-e3e1-4f46-b82e-764ae098bada","prop:Manager":"AWS","prop:State":"Enabled","prop:_tagPrefix":"tag","resource":"4960b196-e3e1-4f46-b82e-764ae098bada","state":7,"time":"2024-10-05T23:45:00-06:00","type":"KMSKey"}
{"level":"info",nuke-status:"filtered","msg":"filtered: cannot delete AWS managed key","owner":"us-east-1","prop:ID":"49faf6ef-ae89-4203-bb29-1bc32be20228","prop:Manager":"AWS","prop:State":"Enabled","prop:_tagPrefix":"tag","resource":"49faf6ef-ae89-4203-bb29-1bc32be20228","state":7,"time":"2024-10-05T23:45:00-06:00","type":"KMSKey"}
{"level":"info",nuke-status:"failed","msg":"Failed: Cannot delete the directory because it still has authorized applications","owner":"us-east-1","prop:ID":"bfec52f0-a84c-4c78-a305-368918386251","prop:Manager":"AWS","prop:State":"Enabled","prop:_tagPrefix":"tag","resource":"bfec52f0-a84c-4c78-a305-368918386251","state":7,"time":"2024-10-05T23:45:00-06:00","type":"DirectoryServiceDirectory"}
{"level":"info","nuke-summary":{"total":3,"filtered":1,"removed":1,"failed":1}}

Apologies if this is already the case and I have missed it somehow but that's just my thoughts.

Getting close to being mergeable -- new build available once this action finishes up https://github.com/ekristen/aws-nuke/actions/runs/12476251043
state - string of the state of the resource
state_code - internal integer of the state (might be removed)
prop:PROPERT_NAME - all properties on a resource are prefixed with prop:
name - this is the STRING representation or in the future the primary/default property (once I put that in place)
{"level":"info","msg":"filtered: unable to delete, fargate managed","name":"arn:aws:ecs:us-east-2:637423565883:capacity-provider/FARGATE_SPOT","owner":"us-east-2","prop:ARN":"arn:aws:ecs:us-east-2:637423565883:capacity-provider/FARGATE_SPOT","prop:Name":"FARGATE_SPOT","prop:Status":"ACTIVE","state":"filtered","state_code":7,"time":"2024-12-23T19:55:16-07:00","type":"ECSCapacityProvider"}
{"level":"info","msg":"filtered: cannot delete group 'default'","name":"sg-0ad5cc8941267ed4f","owner":"us-east-2","prop:Name":"default","prop:OwnerID":"637423565883","state":"filtered","state_code":7,"time":"2024-12-23T19:55:16-07:00","type":"EC2SecurityGroup"}
{"component":"libnuke","filtered":408,"level":"info","msg":"Scan complete: 408 total, 0 nukeable, 408 filtered.\n","nukeable":0,"time":"2024-12-23T19:55:16-07:00","total":408}
{"component":"libnuke","level":"info","msg":"No resource to delete.","time":"2024-12-23T19:55:16-07:00"}

@kieran-lowe @cland new builds, please test.

:tada: This PR is included in version 3.39.0 :tada:
The release is available on GitHub release
Your semantic-release bot :package::rocket:


Add modifier to ActiveGate StatefulSet mounting EEC token volume

Description
K8S-10131
Now, when Prometheus extension is enabled, we mount the EEC token value from the extensions secret to the ActiveGate StatefulSet.
How can this be tested?

Apply a dynakube with Prometheus enabled
Check volume is mounted in ActiveGate pod and that the file with its content exist (via shell, path /var/lib/dynatrace/secrets/eec/token/eec.token)
Apply a dynakube with Prometheus disabled and there shouldn't be any mounts

:warning: Please install the  to ensure uploads and comments are reliably processed by Codecov.
Codecov Report
All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 58.13%. Comparing base (e4a2a0f) to head (c2516b2).

:exclamation: Your organization needs to install the Codecov GitHub app to enable full functionality.
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #3497      +/-   ##
==========================================
+ Coverage   58.05%   58.13%   +0.08%
==========================================
  Files         365      366       +1
  Lines       20316    20356      +40
==========================================
+ Hits        11794    11834      +40
  Misses       7269     7269
  Partials     1253     1253

Flag
Coverage Δ

unittests
58.13% <100.00%> (+0.08%)
:arrow_up:

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

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


Using external service causes the application to restart when going back from Google Maps

Hi there.
I am developing an Android App. I am using cordova version 6.1.1.
When using the external service in the plugin, when I go back from the opened Google Maps, the application did not stay on the last view, and basically restarts.
I already tried to use the latest version on git by removing the plugin from the projecto and doing cordova plugin add https://github.com/phonegap-googlemaps-plugin/cordova-plugin-googlemaps
Any ideas to solve this?
Thank you.

I could not reproduce your issue.
https://youtu.be/4WUlpeSrgfc
In the above video, there is "full screen button" in the app, but it launches the external GoogleMaps.
(I reused some other code)

Hi there. You have a different scenario. Basically I have an html with various divs that correspond to various pages. I have navigate from page A to page B and in page B I trigger the external service. When I press back from the Google Maps it returns to the app but to the Page A.

Please make an example project.

@clviper If you don't provide an example project, we close this issue since we don't have enough information.
Thank you for your cooperation.

Hi there. Sorry for not giving feedback. In a hour or two I will leave here an example project.

I'm sorry. I found out the problem while trying to create a new sample project to send you. Nothing related to the plugin itself.
Thanks for the patience.
Congrats on the plugin. Really awesome. Good work.

Thank you for following up, and thank you for using this plugin.


Add Authentication Dialog

Add authentication dialog for http basic auth request in iframe (like Blue Iris, Kodi, IDE Cloud 9...)

Fixes: https://github.com/home-assistant/home-assistant-android/issues/259


docs: Update sidebar

https://github.com/jdx/mise/discussions/2440#discussioncomment-11126188
Proposal to update the documentation sidebar

@jdx let me know if I there is still something I need to address here.
Follow-up MRs could be created to make sure plugins is replaced with tools whenever needed also

I am getting some new errors
fatal: unable to access 'https://github.com/hverlin/mise/': The requested URL returned error: 403
Error: Invalid status code: 128
    at ChildProcess.<anonymous> (/Users/runner/work/_actions/stefanzweifel/git-auto-commit-action/v5/index.js:17:19)


chore: correct esbuild peer dependency version

Correct esbuild peerDep requirement so latest version is supported (0.23.1).
From PR template:

Code changes have been tested and working fine, or there are no code changes
This PR only includes non-code changes, like changes to documentation, README, etc.

See: https://jubianchi.github.io/semver-check/#/>%3D0.14.0 ^0.23.0/0.23.1 vs https://jubianchi.github.io/semver-check/#/>%3D0.14.0 <%3D0.23.0/0.23.1

I don't think this is correct. >=0.14.0 ^0.23.0 only matches 0.23.x (it means >=0.14.0 AND ^0.23.0, so the >=0.14.0 is redundant). I think the intent is to do >= 0.14.0 <=0.23.x.
You can check that at https://semver.npmjs.com


Havens

Made changes to scene_play.js, scene_end.js, and game_manager.js
Added code for timers with reference to the ones in ABoF.
Had to delete some code because it was popping errors.
Let me know what changes I can do

So far, everything is working as intended. The only piece remaining is to add the div element for the timer to the play scene and apply the timer to the end scene.


[nfc] use _bazel.yml from the release.yml

I wonder if there's a way to trigger release build on PR to test it?

I wonder if there's a way to trigger release build on PR to test it?

Temporarily enabling it with on: pull_request might work, worth trying for sure. Release is not an action that can be started manually (unlike the npm jobs that are marked as workflow_dispatch). This kind of change inherently comes with some risk of breakage, I'm happy to review any fixups following this if needed. Merging the release bazel configuration will make CI a lot easier to maintain in the long term.
LGTM otherwise BTW.


Keyboard-accessible "open in web" action

Is your feature request related to a problem? Please describe.
Many of the feeds I follow only show a summary in the feed, but opening the full item (in e.g. another tab) requires fiddly mouse motions which are an accessibility issue for me.
Describe the solution you'd like
Having a keyboard shortcut to open the currently-highlighted item with target=_new or whatever; ideally something like enter

It's kind of already in there with the v button (from google reader I think)
But the shortcuts are kind of fiddly. They don't work on the timeline view - because trying to determine which post you are trying to control was a big performance hit.
They do work in the other views, on the classic view you have to lor → to focus the post. I should enable that sort of stuff on the classic view list as well.
You can also hit ? at any time to show the shortcuts

Ah, thanks. Done visibility into the fact I can press ? to get the shortcuts lost would be helpful then.


Architecture Reference » CouchDB as the State Database

https://hyperledger-fabric.readthedocs.io/en/release-2.2/couchdb_as_state_database.html
https://github.com/hyperledger/fabric-docs-i18n/blob/release-2.2/docs/locale/ja_JP/source/couchdb_as_state_database.rst

I will do this


Feat(cb2 8167): Archive technical record

Archive Tech Record v3 endpoint
Generic post endpoint that calls the test number service in order to generate system numbers.
ArchiveTech Records endpoint can update a single non-archived Technical Record using the provided system number and created timestamp.
Related issue: CB2-8167
Type of change

[ ] Bug fix (non-breaking change which fixes an issue)
[ ] Feature (non-breaking change which adds functionality)
[ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)

Checklist:

[ ] I have performed a self-review of my own code
[ ] I have added tests that prove my fix is effective or that my feature works

There's lots of listing issues, can they be looked into?


Upgrade tmp

This finally resolves #882
I've checked the changelog and none of the breaking changes affect us. tmp is also still compatbile with node v8, it just bumped its minimum requirement to the latest version of v8 to satifsfy its linter.

Would be great with a new release with this so new users don’t run into that issue. The symptoms are really subtle.
Will also allow me to get off my fork based on exceljs 1.7.0(!)

@guyonroche, could you make a new release, please? This tmp upgrade fixes a very long standing bug that has prevented me from using exceljs 1.8.0 - 3.3.0.


corrplor

If there is no negative values, nothing is plotted. quick fix for now is so set one of the
df value to a small negative value.....

fixed in a previous bug fix.


2 Types are not being found when building the app

Rules

To report a bug and help us to provide the solution as fast as possible, please follow the instructions below:
1 - Describe the bug
A clear and concise description of what the bug is.
When i build my app, the build fails due to three files producing Error: Type '{TypeName}' not found
OBS: avoid to use the expression "its not working" or "is working" or any other variation. These expressions can mean anything and at same time doesn´t bring any useful information. As soon you rewrite these expressions, you naturally going to be more precise and clear.
2 - Provide us as much information as possible
To help us to understand your issue, provide with your bug report all the relevant informations, such as:

Your plugins list inside the file pubspec.yaml (at least all notification plugins)
none other than Awesome_Notifications
What platform did you found the issue
MacOs to Build which was going to be built to an Android device
What devices did you found the issue
Macbook Pro
How are you initializing the plugin

'Future<void> createNotification() async {
    String localTimeZone =
        await AwesomeNotifications().getLocalTimeZoneIdentifier();
    String utcTimeZone =
        await AwesomeNotifications().getLocalTimeZoneIdentifier();
  }';

As well as the initialization steps as per the instructions in the documentation

How are you creating the notification
I have not created it yet
The output of flutter doctor command
`Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel stable, 3.0.5, on macOS 12.6 21G115 darwin-x64, locale en-ZA)
[✓] Android toolchain - develop for Android devices (Android SDK version 31.0.0)
[✓] Xcode - develop for iOS and macOS (Xcode 14.1)
[✓] Chrome - develop for the web
[✓] Android Studio (version 2021.3)
[✓] Connected device (3 available)
[✓] HTTP Host Availability

• No issues found!
`
OBS: To post a source code in your issue, please use the markdown below:
print('Your source code goes here');

3 - How To Reproduce the Error
I dont know what to put here since the only steps i took to get the error was the instructions in the documentation for the plugin
Steps to reproduce the behavior:

Go to '...'
Click on '....'
Scroll down to '....'
See error

...or if you prefer, you can provide us a simple example app on GitHub with the issue already reproduced instead of the steps 2 and 3.
4 - Expected behavior
A clear and concise description of what you expected to happen.
For the app to build
5 - Screenshots
If applicable, add screenshots to help explain your problem.

6 - Additional context
Add any other context about the problem here.

You need to update your flutter and dart versions. Use the command flutter upgrade to do it.


How Can I return the unmasked value?

Is there a way to return the unmasked value to the v-model?

you can access unmasked value from change event
e.target.inputmask.unmaskedvalue()

Also, if you just want the raw value in the v-model, you can specify: autoUnmask: true.
It is not clear in these docs but this wrapper seems to support many/most/all the features in the Robin Herbots component it is based on. The link is on the main page.


Updates for updated CI containers

Description

Updates to CI by Travis
A non-intelligent reference update that I needed for the soca tests to pass on orion with gnu with spack-stack/1.5.0. Not sure why updates are needed, but all changes are small as far as I can tell.

my untested code change worked on the first try, huzzah!

FYI @shlyaeva the actual reference changes required might have been fewer than you think. I suspect that some answers changed at some point but were still within tolerance so they never got updated.

Great @travissluka, thank you for confirming!


When the cmp completion menu is open pressing enter adds a new line which cannot be removed

While Using Native Menu:
https://user-images.githubusercontent.com/51816057/138512787-6d8c21a4-1541-4bd8-a5bc-e6274a3731f1.mp4
While Using CMP Menu:
https://user-images.githubusercontent.com/51816057/138512878-5f663885-b8c8-48cd-be65-a683427c4c6e.mp4

duplicated #328


image missing, code error

The image used is out of date
Dockerfile required massive enhancement
 error in task code

expired > update follows


Question about model performance

Hi @juney-nvidia ，I have a question here https://github.com/NVIDIA/TensorRT-LLM/blob/release/0.5.0/docs/source/performance.md#:~:text=2%2C980-,LLaMA 7B,-64，the model ”LLaMA“ in this page means Llama2 or just Lalma1? Becausu in this page https://github.com/NVIDIA/TensorRT-LLM/blob/a21e2f85178111fed9812bb88c2cc7411b25f0ba/docs/source/blogs/H200launch.md, the title says llama2-13B, but the content is about llama-13B.
Looking forward to your reply, thanks!

@RussellRao
Hi , thanks for bringing this question.
From model inference perspective, my understanding is that the LLaMA-13B in V1 and V2 share the exact same model architecture:

hidden dimension: 5120
hidden activation: silu
num of layers: 40
num of attention heads: 40 (LLaMA2-70B does uses GQA which is different from 13B)

So sometimes for inference scenarios, they are used interchangeably.
Hope this can answer your question.
Thanks
June

Hi @juney-nvidia ，
Thanks for your reply, I understood.


Need support for search params.

Need something like useSearchParams in React Router to handle queries.

I was also facing the issue of extracting search params. But I have built a custom hook for that. I can raise a pull request for it.

Hi! Sorry, this isn't well documented (yet! PRs are welcome). You can subscribe to search string updates via:
import { useSearch, useLocationProperty, navigate } from 'wouter/use-location';

// get all search params:
const search = useSearch();

Note that you will have to parse these using URLSearchParams or a 3rd party library. We might add this in the future releases.

I see, this isn't provided out-of-the-box right now. But I'll try to hack a simple implementation for that.

I've written the useSearchParams function based on react-router's implementation for wouter. The API is similar if not identical to react-router's useSearchParams version.
So far it has been working great for me, hope it helps :)
lib/wouter.ts
import { useCallback, useMemo, useRef } from 'react';
import { navigate, useSearch } from 'wouter/use-location';

// Based on react-router: https://github.com/remix-run/react-router/blob/main/packages/react-router-dom/index.tsx

type ParamKeyValuePair = [string, string];

type URLSearchParamsInit =
  | string
  | ParamKeyValuePair[]
  | Record<string, string | string[]>
  | URLSearchParams;

export function createSearchParams(
  init: URLSearchParamsInit = '',
): URLSearchParams {
  return new URLSearchParams(
    typeof init === 'string' ||
    Array.isArray(init) ||
    init instanceof URLSearchParams
      ? init
      : Object.keys(init).reduce((memo, key) => {
          const value = init[key];
          return memo.concat(
            Array.isArray(value) ? value.map((v) => [key, v]) : [[key, value]],
          );
        }, [] as ParamKeyValuePair[]),
  );
}

export function getSearchParamsForLocation(
  locationSearch: string,
  defaultSearchParams: URLSearchParams | null,
) {
  const searchParams = createSearchParams(locationSearch);

  if (defaultSearchParams) {
    // Use `defaultSearchParams.forEach(...)` here instead of iterating of
    // `defaultSearchParams.keys()` to work-around a bug in Firefox related to
    // web extensions. Relevant Bugzilla tickets:
    // https://bugzilla.mozilla.org/show_bug.cgi?id=1414602
    // https://bugzilla.mozilla.org/show_bug.cgi?id=1023984
    defaultSearchParams.forEach((_, key) => {
      if (!searchParams.has(key)) {
        defaultSearchParams.getAll(key).forEach((value) => {
          searchParams.append(key, value);
        });
      }
    });
  }

  return searchParams;
}

export function useSearchParams(defaultInit?: URLSearchParamsInit) {
  if (typeof URLSearchParams !== 'undefined') {
    console.warn(
      `You cannot use the \`useSearchParams\` hook in a browser that does not ` +
        `support the URLSearchParams API. If you need to support Internet ` +
        `Explorer 11, we recommend you load a polyfill such as ` +
        `https://github.com/ungap/url-search-params\n\n` +
        `If you're unsure how to load polyfills, we recommend you check out ` +
        `https://polyfill.io/v3/ which provides some recommendations about how ` +
        `to load polyfills only for users that need them, instead of for every ` +
        `user.`,
    );
  }

  const defaultSearchParamsRef = useRef(createSearchParams(defaultInit));
  const hasSetSearchParamsRef = useRef(false);

  const search = useSearch();
  const searchParams = useMemo(
    () =>
      // Only merge in the defaults if we haven't yet called setSearchParams.
      // Once we call that we want those to take precedence, otherwise you can't
      // remove a param with setSearchParams({}) if it has an initial value
      getSearchParamsForLocation(
        search,
        hasSetSearchParamsRef.current ? null : defaultSearchParamsRef.current,
      ),
    [search],
  );

  const setSearchParams = useCallback(
    (
      nextInit:
        | URLSearchParamsInit
        | ((prev: URLSearchParams) => URLSearchParamsInit),
      navigateOpts?: Parameters<typeof navigate>['1'],
    ) => {
      const newSearchParams = createSearchParams(
        typeof nextInit === 'function' ? nextInit(searchParams) : nextInit,
      );
      hasSetSearchParamsRef.current = true;
      navigate('?' + newSearchParams, navigateOpts);
    },
    [searchParams],
  );

  return [searchParams, setSearchParams] as const;
}

app.tsx
export function App() {
  const [searchParams, setSearchParams] = useSearchParams();

  return (
    <main>
      <p>{searchParams.get('key')}</p>

      <button onClick={() => setSearchParams({ key: 'value' })}>
        Set Param
      </button>
      <button
        onClick={() =>
          setSearchParams((prevSearchParams) => ({
            ...Object.fromEntries(prevSearchParams),
            array: ['value_1', 'value_2'], // Array is supported just like react-router.
          }))
        }
      >
        Merge Params
      </button>
    </main>
  );
}

If interested, I could open up a PR to add this as an official helper util :)

Cool, that could be a nice feature to have in v3. We're preparing the first release candidate right now, I will let you know once it is ready, so you can start working on a PR.

The RC is out now. There is no useSearchParams yet, but we added it to the roadmap for v3.1

i find it quite often that you might want to replace searchParam but you don't really want to trigger a re-render in same component!
useSearch will trigger re-render everytime; infact current implementaion trigger re-render even if params/href didnot change at all. (it re-render on any navigation event)
a nice js helper to manipulate searchParams is more than enough more most cases imo
export function replaceSearchParam(qs: Record<string,string|number|boolean|null>, replace=false){
  const params = new URLSearchParams(location.search);
  for (const [key, value] of Object.entries(qs)) {
    if(value === null){
      params.delete(key);
    } else {
      params.set(key, `${value}`);
    }
  }
  if(replace){
    history.replaceState(null, "", `${location.pathname}?${params}`);
  } else {
    history.pushState(null, "", `${location.pathname}?${params}`);
  }
}

i find it quite often that you might want to replace searchParam but you don't really want to trigger a re-render in same component!
useSearch will trigger re-render everytime; infact current implementaion trigger re-render even if params/href didnot change at all. (it re-render on any navigation event)
a nice js helper to manipulate searchParams is more than enough more most cases imo
export function replaceSearchParam(qs: Record<string,string|number|boolean|null>, replace=false){
  const params = new URLSearchParams(location.search);
  for (const [key, value] of Object.entries(qs)) {
    if(value === null){
      params.delete(key);
    } else {
      params.set(key, `${value}`);
    }
  }
  if(replace){
    history.replaceState(null, "", `${location.pathname}?${params}`);
  } else {
    history.pushState(null, "", `${location.pathname}?${params}`);
  }
}

I believe triggering a re-render upon search changes is the desired behaviour. E.g, updating query ?status=failed will trigger an update on the UI and refetch API with status = "failed".
May I know on what occasion that you would want to update the search params without re-rendering? This also mean that when you hit back on the browser, nothing happens because UI does not re-render.


Cargo links libcore twice when compiling with -Zbuild-std and panic=abort

Problem
its seems like libcore is being linked twice one from built std and one from prebuilt one Error
error[E0152]: duplicate lang item in crate `core`: `sized`
  |
  = note: the lang item is first defined in crate `core` (which `std` depends on)
  = note: first definition in `core` loaded from <project-dir>\target\x86_64-pc-windows-msvc\release\deps\libcore-9934970537b87ae5.rlib, <project-dir>\target\x86_64-pc-windows-msvc\release\deps\libcore-9934970537b87ae5.rmeta
  = note: second definition in `core` loaded from <rustup-dir>\toolchains\nightly-x86_64-pc-windows-msvc\lib\rustlib\x86_64-pc-windows-msvc\lib\libcore-0a7d9524c210bd3d.rlib

For more information about this error, try `rustc --explain E0152`

Steps

create a binary project using cargo new
add panic="abort" in release profile
add rust flag "-Crelocation-model=pic"
compile using "cargo b -Zbuild-std --target x86_64-pc-windows-msvc --release"

Possible Solution(s)
No response
Notes
I'm trying to create PIE using rust yet no success
Version
cargo 1.81.0-nightly (bc89bffa5 2024-06-22)
release: 1.81.0-nightly
commit-hash: bc89bffa5987d4af8f71011c7557119b39e44a65
commit-date: 2024-06-22
host: x86_64-pc-windows-msvc
libgit2: 1.8.1 (sys:0.19.0 vendored)
libcurl: 8.6.0-DEV (sys:0.4.72+curl-8.6.0 vendored ssl:Schannel)
os: Windows 10.0.20348 [64-bit]

Thanks for the report! I'm going to close as a duplicate of https://github.com/rust-lang/wg-cargo-std-aware/issues/29. Support for abort hasn't ever really worked very well. In the meantime, I think you can do -Zbuild-std=std,panic_abort as a workaround.


Add P-space property

Addresses issue #220

Hayden and I worked together on this just now - @prabau let us know if you have any suggestions for improvement.

Cool.  I'll take a look.

I don't think the alias "pseudo-discrete" is justified.  In his introduction Misra mentions that P-space was an abbreviation for "pseudo-discrete space" in Gillman and Henriksen, but as Misra mentions, their notion of P-space was slightly different than the notion taken as definition by Misra.

For the definition of P147, I think it would be good to add equivalent formulations that seem useful for verifying the property.  Something like the following for example:

Equivalently, a space in which every countable union of closed sets is closed.
Equivalently, a space in which every point is a P-point, where a point $x$ is called a P-point if every countable intersection of neighborhoods of $x$ is a neighborhood of $x$.

For T351, instead of Corollary 3.3, it should refer to the proof of Proposition 3.2.  But that proof does not use the T2 or T1 property anywhere, so the more generally valid result is [regular + P-space ==> zero-dim]

For T351, instead of Corollary 3.3, it should refer to the proof of Proposition 3.2. But that proof does not use the T2 or T1 property anywhere, so the more generally valid result is [regular + P-space ==> zero-dim]

I suspected that might be an easy improvement, but did not take the time during our call earlier to look closely. Now that I have, I agree that T1 is clearly unnecessary and citing the rpoof of Proposition 3.2 is a better reference.

The name "Misra subspace" for S178 does not seem very good.  Can we come up with something better?
Also, the README should have a link to S177 that it is a subspace of.
"Misra space" for S177 is not too descriptive either.  "Misra's $E_0$ P-space" or something else?  Not sure.  (The article also has example $E_\omega$ in 5.1 if one would ever care to add it in the future, mentioned in https://math.stackexchange.com/questions/3765829).
@StevenClontz What's your take on the following? I'll tell you my opinion, but it's up for discussion.
When providing the definition of an example space, I think it's worth spelling it out in full if the description is relatively simple, or if it's necessary to refer to specific element when justifying the properties.  On the other hand if the construction is very involved, just a reference would be enough.  It's a judgement call.  But at least we can also provide more context about the main purpose of the example.
So in the README for S177 we could mention that Misra's 3.1 provides an example of P-space that is T2, semiregular, but not T2.5.  And similarly for S178.

Not sure if you want to defer this to a later PR, but S17 (cocountable topology on the reals) is a simple example of P-space.

@prabau lest this get too stale, would you like to make your suggested improvements? Then I'll do the final review and (presumably) approve and merge.

@hpecora1 I have added changes based on the review.  Please see if that makes sense.

I'll approve if @hpecora1 is happy with the changes.


How to fix the issue: init_fs_encoding: failed to get the Python codec of the filesystem encoding

Hello:
I want to play a MP4 format video in Windows 10 PC with Pythonnet.
I have installed Python 3.9.7, but I didn't set up PYTHONPATH and PYTHONHOME, as many people said that they are not necessary.
I installed Pythonnet nuget package:
PM> Install-Package pythonnet -Version 3.0.0-preview2022-03-03
The following is my code:
using Python.Runtime;
namespace PyReturnTransit1Result
{
class Program
{
public const string MP4_File1 = "D:/Videos/1.mp4";
public static void Python_Play_Video()
{
using (Py.GIL())
{
dynamic np = Py.Import("numpy");
dynamic cv2 = Py.Import("cv2");
dynamic cap = cv2.VideoCapture(MP4_File1);
while (cap.isOpened())
{
var video_frame = cap.read();
cv2.imshow("frame", video_frame);
}
cap.release();
cv2.destroyAllWindows();
}
}
    static void Main()
    {
        Python_Play_Video();
    }
}

}
But when I run the above code, I got errors:
Python path configuration:
PYTHONHOME = (not set)
PYTHONPATH = (not set)
program name = 'python'
isolated = 0
environment = 1
user site = 1
import site = 1
sys._base_executable = 'C:\SoccerVideos\PythonNet\PyReturnTransit1Result\PyReturnTransit1Result\bin\x64\Debug\net5.0\PyReturnTransit1Result.exe'
sys.base_prefix = 'C:\Program Files\Python39'
sys.base_exec_prefix = 'C:\Program Files\Python39'
sys.platlibdir = 'lib'
sys.executable = 'C:\SoccerVideos\PythonNet\PyReturnTransit1Result\PyReturnTransit1Result\bin\x64\Debug\net5.0\PyReturnTransit1Result.exe'
sys.prefix = 'C:\Program Files\Python39'
sys.exec_prefix = 'C:\Program Files\Python39'
sys.path = [
'C:\Program Files\Python39\python39.zip',
'.\DLLs',
'.\lib',
'C:\SoccerVideos\PythonNet\PyReturnTransit1Result\PyReturnTransit1Result\bin\x64\Debug\net5.0',
]
Fatal Python error: init_fs_encoding: failed to get the Python codec of the filesystem encoding
Python runtime state: core initialized
ModuleNotFoundError: No module named 'encodings'
Current thread 0x00009094 (most recent call first):

C:\SoccerVideos\PythonNet\PyReturnTransit1Result\PyReturnTransit1Result\bin\x64\Debug\net5.0\PyReturnTransit1Result.exe (process 34764) exited with code 1.
To automatically close the console when debugging stops, enable Tools->Options->Debugging->Automatically close the console when debugging stops.
Press any key to close this window . . .
The similar code in Python works in my PC.
Any suggestion on how I can fix this issue?
Thanks,

Hello:
As I am confused, could you please indicate what exactly is the environment configuration issue?
thanks,

This is a bug tracker, not a support forum.


Adding version

Adding versioning for packagist

@lireincore Hello, I wanted to add versioning to this project. I added the change to the composer file, and then I'll add a tag for the change, and it will hopefully work automatically for packagist. If not, it is easy to setup, and I can provide info if needed.

That is a good way forward. I'll close this PR out.


[bug] Conflicting peer dependency<EMAIL_ADDRESS>

Link to minimal reproducible example
https://stackblitz.com/
Summary
Hi there,
I'm facing a warning message when I install the web3-modal and Wagmi packages.  Please use @babel/plugin-transform-optional-catch-binding instead.
npm WARN deprecated<EMAIL_ADDRESS>This proposal has been merged to the ECMAScript standard and thus this plugin is no longer maintained. Please use @babel/plugin-transform-numeric-separator instead.
npm WARN deprecated<EMAIL_ADDRESS>This proposal has been merged to the ECMAScript standard and thus this plugin is no longer maintained. Please use @babel/plugin-transform-nullish-coalescing-operator instead.
npm WARN deprecated<EMAIL_ADDRESS>This proposal has been merged to the ECMAScript standard and thus this plugin is no longer maintained. Please use @babel/plugin-transform-class-properties instead.
npm WARN deprecated<EMAIL_ADDRESS>This proposal has been merged to the ECMAScript standard and thus this plugin is no longer maintained. Please use @babel/plugin-transform-logical-assignment-operators instead.
npm WARN deprecated<EMAIL_ADDRESS>This proposal has been merged to the ECMAScript standard and thus this plugin is no longer maintained. Please use @babel/plugin-transform-optional-chaining instead.
npm WARN deprecated<EMAIL_ADDRESS>This proposal has been merged to the ECMAScript standard and thus this plugin is no longer maintained. Please use @babel/plugin-transform-async-generator-functions instead.
npm WARN deprecated<EMAIL_ADDRESS>This proposal has been merged to the ECMAScript standard and thus this plugin is no longer maintained. Please use @babel/plugin-transform-object-rest-spread instead.
npm WARN deprecated<EMAIL_ADDRESS>The querystring API is considered Legacy. new code should use the URLSearchParams API instead.
npm WARN deprecated<EMAIL_ADDRESS>Motion One for Vue is deprecated. Use Oku Motion instead https://oku-ui.com/motion
List of related npm package versions
@web3modal/wagmi@alpha @wagmi/core @wagmi/connectors viem

This is a Wagmi issue that downstreams from the MetaMask SDK, I'd try to contact them instead since we don't have control over that SDK