Existing wireguard configuration is not fetched on first start

When running wireguard-ui for the first time any existing configuration in wg0.conf is not fetched.
That is clients, server settings and global settings.
Status shows the currently active clients though

I'm also having the same problem, and I'm a bit stuck right now.

Skimming through the code I didn't find any function that imports the current conf. It seems to only generate a new conf each time from the records in its own db.
As I was in a bit of a hurry and only had ~10 clients, I just created "dummy" entries and copy-pasted the keys from the previous conf.

@diggy128
May I ask where is the program you found? I may be able to assist in fixing this.

I didn't use any extra program. I just edited the information that was stored in the database.

AFAIK you cannot import any existing configuration into wireguard-ui

@yodaphone OK, maybe it could be in the documentation or github page to save other people some time trying to find out why it doesn't work with existing configurations.

Yup, I'm affected as well. Saving the server configuration nukes the original config...
This would mean that it doesn't allow users to make manual changes to the wireguard server config, and it always overwrites that config with whatever it has in its database. Might cause issues down the road...

It's especially an issue when using something like the LinuxServer prebuilt container unless the intent is that you leave that blank and make the wireguard LS container depend on the wireguard-ui container to ensure that wg0.conf is autogenerated.
As it stands now though, I am not seeing the private key etc in wireguard-ui being pushed into an existing wg0.conf generated by LS which might be permissions or something else, I don't know. Clearer docs would be awesome, as would an import function.

I have the same problem. It took me a lot of time to make a working vpn configuration manually, usage of this ui tool overwrites my (backupped) configs. Creating a new client also does not build a working config file for me.

Well, this is odd. I thought of giving this project a second chance on a new wireguard setup. I used the UI from start to finish to set up the wireguard configuration. I did change the suggested tunnel address, and proceeded with the configuration. When i was done, I applied, checked that the config files were ok (I used wg0 as interface), and stopped the wireguard-ui application. Next, I moved the binary to /usr/local/bin, created a systemd startup script for it and started it via systemd. Well - surprise - it started, but it didn't load the configuration. It behaved as if wg0 was not configured by it and didn't import anything.
I suspect it's keeping a cache of settings somewhere and can't find it when started through systemd...

Update: Figured it out with a bit of strace trickery: The application creates and maintains its database in a db directory relative to the current working directory from where it was started. I moved the db directory into /etc/wireguard, and instructed the systemd service to load it from there:
[Unit]
Description=Starts wireguard-ui
After=network.service

[Service]
Type=simple
User=root
WorkingDirectory=/etc/wireguard
ExecStart=/usr/local/bin/wireguard-ui
Restart=always
RestartSec=5

[Install]
WantedBy=multi-user.target


Detection Issues

Dear authors of MegaDetector,
I would be very grateful, if you could help me and my colleagues with a very persistent issue:
We applied MegaDetector (run_tf_detector_batch.py) for a large amount of camera trap imagery. Yet we noticed that for many cases, the locations of the individual bounding boxes, stored in the resulting JSON-file, do not represent the animals’ actual position within the image. Thus, we ran the test version (run_tf_detector.py) for a collection of images. Yet the bounding boxes in the resulting “..._detections”-images just matched perfectly with the animal’s location. Consequently, we performed the batch-version on folders only containing one of these test images and the resulting JSON-files contained the exact same values as after the first run while still not matching the animals position.
We performed these steps on several different PCs (computers and laptops) as well as with different operating systems (Ubuntu and Windows). However, the issue persists.
We would be extremely grateful for your advice and help.
Best regards,
Tobias Pelchen (e-mail<EMAIL_ADDRESS>detection issue.pdf

Very odd... we had one other user report exactly the same behavior recently (incorrect results in the batch script, correct results in the non-batch script), and when they sent us some sample images, we were unable to reproduce the issue.
First, are you using the "use_image_queue" option in run_tf_detector_batch.py?  We haven't directly observed any issues with this option, but the most recent set of changes added this option so there could be a regression hiding here, and it is a threading-related change, so regressions can be sneaky.
Next, two suggestions:

If you are able to share a couple of the images where you are getting incorrect results, can you email<EMAIL_ADDRESS>with those images so we can try to reproduce the issue?  And also confirm that you still observe this issue when you only run on those images?
Can you try rolling the repo back to a commit from a few months ago, e.g. this one and try again?  There were some changes to run_tf_detector_batch.py in December that shouldn't have impacted this, and we haven't been able to reproduce this issue, but let's double-check.

Thanks.

Also, were all images impacted, or just some?

Dear Mr. Morris,
We ran the detector on two different devices and the results were the same, exactly the same images were affected and also the values were the same throughout the different runs.
I am not fully assured, if we applied the "use_image_queue", here is a typical example of how I ran the detector:
Preparation:

conda activate cameratraps-detector
cd c:\git
set PYTHONPATH=c:\git\cameratraps;c:\git\ai4eutils

Test-run:

python c:\git\cameratraps\detection\run_tf_detector.py c:\git\md_v4.1.0.pb --image_file c:\Users\Tobia\Documents\I_00017b.jpg

Batch-run:

python c:\git\cameratraps\detection\run_tf_detector_batch.py c:\git\md_v4.1.0.pb c:\Users\Tobia\Pictures\VF_12 c:\Users\Tobia\Pictures\VF_12\out_Y.json --recursive

I sent the images to the<EMAIL_ADDRESS>as you recommended.
is the format of the bounding box information as stored in the JSON file like beneath?

[x_min, y_min, width of the bb, height of the bb]

Hello, I think we solved the problem,
the format of the bounding box information is:

[x_min, y_min, width of the bb, height of the bb]

By y_min + height of the bb you will get y_max.
All works well now and the lines match perfectly with the bounding boxes drwan by the test run.
I am very sorry for  any inconvenience caused.

Great!  No inconvenience at all, always better to ask if you think there might be a bug.  Let us know if you have any other questions!

@TobiasHabesha you save my day with this answer


[Feature Request] [Enhancement] Chat with self

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

It would be awesome to be able to send chat messages to yourself. I sometimes use multiple computers and want to share short notes across multiple computers (e.g. command line outputs), without having to use KBFS.

Telegram has implemented a similar functionality, by allowing to send chat messages and attachments 'to yourself'. In Telegram, it is called 'Saved messages'.

The cool thing about Keybase is that you could already set an expire time in chats, so if this would be implemented, you could let your notes (chat with yourself) expire after a preset time. :+1:

-----BEGIN PGP SIGNATURE-----
Comment: Verify on keybase.io/verify

iHUEARYIAB0WIQRAH9WC8Z8pbdyV2u0j01kO08oWKQUCW30WYwAKCRAj01kO08oW
KXYTAQDcJjB11xou7nfR76+rTEsn2ILh5AJSAzuQ+ddmFKMcSwEA0CZqZ3jssTLA
/y02V3SYzVpedI0z7xgZbgTiP+CZ7gQ=
=ru96
-----END PGP SIGNATURE-----

Ah, nice! Just tried it, and it works. :+1:
An enhancement would be to show 'Saved Messages' instead of your own name and icon.
-----BEGIN PGP MESSAGE-----
Comment: Verify on keybase.io/verify

owGbwMvMwCGmfDmS7/IpMU3G031JDNG1CjcdM3QU8jKTUxUVvEqLSxRKijJTUxQy
S3QUEvNAtEJ5flF2sR4XV3hqTg5IUCE1LyMxLzk1NzUPJFmak6JQkpGap5CUqlCS
r1CckV+uoB6cWAY0xDe1uDgxPbVYXSEzr7gkNTFFIT9NoTK/tEghvzxPIS8xNxVi
R3J+HtD8jlIWBjEOBlkxRRYH+atNH+dr5t6ZeustzL2sTEDH3mXg4hSAiZz9wPBX
Ssnc8n622dlVuk/sSq/oTF9gLK/h5pPKNcnhxvOLgfV3GRlW8q9xKZr+c1PYosVb
10sWSe1/4t+098hXjuVmKl9W2OvwAgA=
=i+oy
-----END PGP MESSAGE-----

This is not working for me- when I start a new chat and add myself it won't prompt me to send a message like it does when I add someone else.

That is quite strange, I was able to start a chat with myself on a Mac device and the messages showed up on all other devices as well.
I can't do it again now, as the chat already exists. Maybe there is someone else who can try it on Android / Windows (?)
-----BEGIN PGP MESSAGE-----
Comment: Verify on keybase.io/verify

owE1kL8vQ1EYhm9/iLqJRoJaaD8xUGkqBolFKFMHESFpRQynvZ/ek557Tt1z6rZD
DSajSAwdkE6IsJhYTJaOGgYRsVgkJPwD3Cus7/vkffJ9u50BLRQZaq2EW81I3Hfu
682FlVVKZmVxIluYZGJutXZzt2wSBVTCRpkqBKlswguYgDQ4RALJMQQl3JjYCgjk
PdihygSrKpGtg+BuOk/yYOAmzSMQboAyESyUkhRQgjSFgwaUS78oYyDc2v7DXYEE
BxlL6noa8oQPKzAEUFdVIJQDF07CQ7zFXzVhNhKjClihUsmka67m0Ktt9G6QwkLB
EZBJBMcU3iQou+otuvoUN2xBDRiDDOWGcCSMTMf1nXJQi4S0gchgcCZ2v/15FLee
9h/f///W5ve+pOkdXf/J26VPe643FsaHr4779j4+KtGu60BZ/yy9Nl8utK2eJX+q
X/suHjYeTu+j/mx4bbH+NXsyOh6sJbszsduzg7Gp51T7Dw==
=LBnR
-----END PGP MESSAGE-----

@spiralmike maybe try sending a chat via command line. the name of the chat is your username twice separated by comma, and to just sent a message "test" it is the command below.
keybase chat send username,username test

I was stuck with the same issue @spiralmike mentioned on Mac, and @junderw's CLI tip here helped.

Thanks, @junderw . The CLI tip worked, and the self chat can be continued in all clients.

Ah, good to see that we found a way to 'chat with ourselves' to keep notes.
So, the solution is

(1) Looking up your own username and beginning a chat with yourself using the graphical interface,
or (2) invoking the command keybase chat send yourUsername,yourUsername Test using the command line interface (CLI).

I will mark this issue as closed, as we found these two solutions.
Feel free to follow me on Keybase (keybase.io/ellipticcurv3)
-----BEGIN PGP MESSAGE-----
Comment: Verify on keybase.io/verify

owFNUc1rE0EU39gW20WLHsxFik8qdBeWlCr06AfFYDWH+kmrCJ1sXpIhs/PWndms
KR6kgoh6EMGDXsSbULzoPyAKUnstCopHoQh6UOrFYulMk7S9zbz34/f1Hu3tcfrz
w8szg8tLeT/3Kve5PKijuJCNsem5KRy/OnVt/ub5U/UAakQV0AQKEXSdacgQqpTK
CjDIWMuuRsLNOdd1oDRRKJqoRuyigRiDJI2q4LoXKTAECIpEqjlJ4Mp1j4M35kOJ
qMFlDdIYWoYBKJOQKkwkixCYkSpjjUtpIQy2xVpttarB2pUlryUsrvOQCeBSY1Jl
IQZGhBLwjvpm1mwLWWhIUWS5ZxvYKjOFbWKFZmSJL3f0g50fuIRKz+7Q65IILnFb
EryJ0qRvMk8ao0JAxJKGgXNlMqvURFIQClJYCexzq1BDaGzojLY6sr0VEQVUE1s/
GaAQlIFxYgo81zHudRIUOI2iEDzWPAzTpHnMd++lvU6+3xnKH+49eejT/O/nfvTt
yddf3cP37bJndtyBfd3J7sBZH126s3pm4eyJ8oPX32/fCIaKP97/e9azMv5l7u27
W97qdWetr/Qn9+HAhfvrBx+/vDvz8cWRvz8fFq8srLwZfvr/9OL+PRs=
=+EMy
-----END PGP MESSAGE-----


haproxy error while enabling cloud foundry tcp routing

I add the following configuration for haproxy, and got stuck at updating haproxy instance
 instance_groups:
  - name: haproxy
    jobs:
    - name: haproxy
      properties:
        ha_proxy:
+         tcp_routing:
+           port_range: 1024-10240

Continue? [yN]: y

Task 259064
Task 259064 | 06:33:10 | Preparing deployment: Preparing deployment (00:00:17)
Task 259064 | 06:33:41 | Preparing package compilation: Finding packages to compile (00:00:01)
Task 259064 | 06:33:49 | Updating instance haproxy: haproxy/235821b0-f352-48b7-a4e2-6c138fb42275 (0) (canary) (00:21:12)
                      L Error: 'haproxy/235821b0-f352-48b7-a4e2-6c138fb42275 (0)' is not running after update. Review logs for failed jobs: haproxy
Task 259064 | 06:55:02 | Error: 'haproxy/235821b0-f352-48b7-a4e2-6c138fb42275 (0)' is not running after update. Review logs for failed jobs: haproxy

Besides, there are no haproxy related logs under /var/vcap/sys/log/haproxy.

haproxy release version: 8.6.0
cf-deployment version: v1.19.0

I found the following errors in /var/vcap/sys/log/monit/haproxy.err.log
/var/vcap/jobs/haproxy/config/ssl/cert-0.pem
[WARNING] 197/052135 (8962) : parsing [/var/vcap/jobs/haproxy/config/haproxy.config:26] : 'option httplog' not usable with frontend 'cf_tcp_routing' (needs 'mode http'). Falling back to 'option tcplog'.
[WARNING] 197/052135 (8962) : config : 'option forwardfor' ignored for frontend 'cf_tcp_routing' as it requires HTTP mode.
[WARNING] 197/052135 (8962) : config : 'option forwardfor' ignored for backend 'cf_tcp_routers' as it requires HTTP mode.
[WARNING] 197/052135 (8962) : parsing [/var/vcap/jobs/haproxy/config/haproxy.config:26] : 'option httplog' not usable with frontend 'tcp-frontend_scheduler' (needs 'mode http'). Falling back to 'option tcplog'.
[WARNING] 197/052135 (8962) : config : 'option forwardfor' ignored for frontend 'tcp-frontend_scheduler' as it requires HTTP mode.
[WARNING] 197/052135 (8962) : config : 'option forwardfor' ignored for backend 'tcp-scheduler' as it requires HTTP mode.
[ALERT] 197/052135 (8962) : Starting frontend cf_tcp_routing: cannot bind socket [<IP_ADDRESS>:2822]
[ALERT] 197/052135 (8962) : Starting frontend cf_tcp_routing: cannot bind socket [<IP_ADDRESS>:2825]
[ALERT] 197/052135 (8962) : Starting frontend cf_tcp_routing: cannot bind socket [<IP_ADDRESS>:3458]
[ALERT] 197/052135 (8962) : Starting frontend cf_tcp_routing: cannot bind socket [<IP_ADDRESS>:9100]
Tue Jul 17 05:21:35 UTC 2018: Errored starting HAProxy
rmdir: failed to remove '/var/vcap/sys/run/haproxy': Directory not empty

Those errors seem to indicate the port is either already in use, or haproxy is not privileged enough to bind to those ports.
Given the switch to BPM, and the old version involved, closing this, but if it's still an issue, feel free to re-open


Does the transaction have some problem?

Looks very strange when the secondary label is blank.

Can you please add at least a brief description? What does this PR do? The change looks like just a rearrangement of code.

Thanks for the screenshot. You mean that the 3rd tx ("ForEx") doesn't show it's target account?

How to reproduce that?

How to reproduce that?

In the splits screen - make sure there is imbalance.

I can't, it automatically adds 3rd account (imbalance account) and shows up just like your "AmEx" tx (with subtitle "3 splits").

Yeah, and then, when I click Save, then Save again, the tx gets saved with an additional Imbalance account, and the subtitle shows "3 splits". Which version does the bug show? I checked in your Google Play version.


Question: How to run docker engine from power shell if I am using Docker Desktop

Requirement
I have quit Docker Desktop. I want to start the Docker Engine again but through power shell. Is there any command available for starting docker engine if it is already installed?
Current Scenario
I can only start Docker Desktop by clicking on the Docker Desktop icon or by running the Docker Desktop exe from the command line

You can try running a script which upon clicking should initiate the Docker application.

I don't think there's currently an official way to control Docker Desktop from the command-line, but you can execute the Docker Desktop.exe binary (also see https://superuser.com/questions/1498570/how-do-i-start-docker-desktop-for-windows-from-command-line)
There's an existing feature request for controlling docker desktop from the command line; you can upvote that ticket by adding a 👍 to the first comment;

https://github.com/docker/roadmap/issues/172

I'll close this ticket as a duplicate of the above.


Update the README.file with refined scope

For function 3 close_up. This part is completed. Please review and merge pull requests.


I think should implement an parser function

I see an issue #801
I think should implement an parser function, for example:
char* data = ....; //read from network or other data source;
size_t data_len = ....;  //known when read data.
json j = parse_json(data, data_len);
call parse_json() is zero-copy, no need to convert to std::string.

We already have this, but it may be a bit hidden. You would need to write
json j = parse_json({data, data_len});

Explanation: We use input adapters for the parser, and {data, data_len} constructs one with the signature
input_buffer_adapter(const char* b, const std::size_t l)

It uses the buffer and does not make copies.
I really need to improve the documentation on this...

OK, it looks well, thank you!


Eslint couldn't find any configuration file

Run 'npm init @eslint/config' on your root project
and select 'To check syntax only'

Fix the issue


check_syntax: Structure does not contain any components

DATA BEGIN OF tables_tab OCCURS 10.
INCLUDE STRUCTURE something_void.
DATA END OF tables_tab.

try again, 2.38.3

Used 2.38.4
Found this variation:

Issue is resolved. Thanks.


naive bayes: simple compuation / example

we should showcase a simple example on data that demonstrages how we compute the model on data

https://monkeylearn.com/blog/practical-explanation-naive-bayes-classifier/

We have a rather thorough exercise on this: ex_classification_2.pdf question 1

we have added a simple demonstration (as figure), is also explained in the new vids


Testing Issues/Questions 6/29

In testing today, I have noted the following issues/questions:

When on the landing screen, and when I click on a state, then click 'back to overview,' the bar chart box appears but bar chart not loading (may still be in the works)

**Note- when I tested this on my iPhone, the chart did come up.
-When I click on the drop down box for timeline and for status, the box expands across the entire page, rather than maintaining the width of the box.
-Question: is the bar chart title "Recall Enforcement Count by State" an accurate title of what it's representing or should it be renamed? Is something like 'Active Recall Count by State' more appropriate/representative?

@jodimward can you tell me what browser you're on? I can't reproduce these issues. Anyone else seeing the issue with chart not reloading when going 'back to overview' and the dropdowns going 100% width of the page? @michaelgaigg @gclancy

works in Chrome.
Issues in IE 11 - at least with the chart.  It does not when i open the app, and does not display when i hit "Back to Overview"

we should leave the name as -is.  there are both Active and Closed recalls listed - its should be sorted with Active on the top.  The Term "recall enforcement" does come from the FDA website.
We should probably review with users and get additional input before we make any changes.

@benheb Gerry is correct- this issue came from testing in IE and I am still unable to see bar chart in this view. The chart is appearing in Firefox and Chrome but the proportion/size of chart varies in each. In Mozilla the chart fills the box, in Chrome, chart does not fill the box. Not a major issue - just wanted to make you aware. See screen grabs below.
Looks like the drop down box issue was fixed in IE.
I am losing the 'back to overview' button. It does appear upon entry to the app, but after  clicking on 'show details,' then closing the box and clicking on a new state 'back to overview' does not appear.  If I click on details, then hit the 'back' arrow, 'back to overview' button does appear. This issue was also duplicated in Firefox, and chrome, but was not happening on my iPhone 6.
Population impact is a great add! Looks great in all browsers tested but on iPhone, the population number is appearing without commas

I think these are all resolved now, closing.


WIP: free-threaded python

This PR adapts nanobind to run on free-threaded Python builds. The implementation is still rather incomplete, so please don't use this for anything for now.
The changes so far include the following:

[x] a FREE_THREADED cmake parameter to opt into free threaded behavior. It's a no-op on non-free-threaded Python builds.
[x] threading awareness for list accessors and sequence type casters.
[x] protected access to the central CPP->Python hash table (internals.inst_c2p) and and keep-alive lists data structure (internals.keep_alive). This uses a sharding approach based on pybind11 PR #5148 by @colesbury to reduce lock contention.

My plan is to avoid locking centralized data structures if possible (except for the the sharded locking scheme mentioned above). This should improve scalability compared to pybind11, which currently has to acquire a lock to the entire internals data structure several times per dispatched call. This is costly and seems counter to the design of the free-threaded Python implementation with its local locks.
The following shared data structures still need work:

[ ] internals.type_c2p_fast, internals.type_c2p_slow: types register themselves with these hash tables when a type binding is created. This mostly happens at module initialization time. One option would be to shard the internals.type_c2p_fast data structure and use it as a cache for internals.type_c2p_slow protected with 1 global lock. A more radical option would be to somehow freeze one or both data structures after a module has been initialized and treat it as read-only following that, in which case no locking would be needed. This would come with severe limitations though -- for example, users would not be able to dynamically inherit from C++ classes in Python since this would require updating the internals.type_c2p_* hash tables.
[ ] internals.nb_type_dict, internals.nb_static_property, internals.nb_static_property: these are either created once or aren't on the critical path. Should be easy to deal with.
[ ] internals.funcs: Not on the critical path, these are just used for leak reporting. Fine to add a central lock for this data structure.
[ ] internals.translators: Two options: either make read-only following module initialization (this means that exceptions can't be added later). Or protect with a lock. This could be okay since this list is accessed when raising an exception (which is considered a slow operation in any case).

Dear @colesbury,
following your work on the pybind11 free-threaded support, I was wondering if I could ask two quick questions about getting something similar into nanobind.

Does the free-threaded version of Python provide a fast/portable way of getting a core and/or thread ID for sharding data structures? This is for situations where an existing pointer address isn't available that could be used to segregate a lookup.

The failing test in this PR happens only in free-threaded builds, and I suspect that it is a regression in GC behavior. More details here: https://discuss.python.org/t/reference-leaks-in-free-threaded-3-13-version/61467/3. Do you have any ideas what might be going wrong?

Thanks!

Hi @wjakob,

There are a few possible APIs depending on the use case. PyThreadState_Get() returns a unique address per-thread. _Py_ThreadId() is probably a bit faster, but it's not a public API. If you go that route, I'd suggest copy-pasting the implementation rather than calling _Py_ThreadId() directly, but that's up to you. If you need small consecutive integers, you are probably best off with a thread_local variable.

I replied to the forum post: https://discuss.python.org/t/reference-leaks-in-free-threaded-3-13-version/61467/7

If you every C extension calls PyUnstable_Module_SetGIL(m, Py_MOD_GIL_NOT_USED) then PYTHON_GIL=0 is not necessary. (The environment variable overrides what the extensions specify). In addition to @vfdev-5's link, there are some more details in the free-threading howto guide. If some PyUnstable_Module_SetGIL are missing and PYTHON_GIL=0 is not set, then you'll see a warning about the GIL being enabled printed in the tests. I don't see that warning in the test output, so I don't think you need to set the environment variable.

One more thing: PyObject_Malloc() now should only be used for allocating PyObject* (and not for PyObject** or other structs). I think some or all of the current PyObject_Malloc() usages should be PyMem_Malloc() (and PyObject_Free -> PyMem_Free().
https://docs.python.org/3.13/howto/free-threading-extensions.html#memory-allocation-apis
One annoying thing is that tp_doc needs to be PyObject_Malloc'd for 3.12, but PyMem_Malloc'd for 3.13+.
I think the other usages can use PyMem_Malloc unconditionally.

Thank you for the clarification @colesbury.

nanobind uses the PyType_FromMetaclass API on v3.12+ and doesn't allocate tp_docs, so that should be okay.

Do you know if there is any difference between PyMem_Malloc and PyObject_Malloc for the other uses pre-v3.13? (If there is no difference, I would switch all of them over instead of making a version-dependent change).
In general, the reason for using the Python allocation API for non-Python objects was to leverage its slab allocator, which has generally been faster than a C-style malloc() or C++ new. That would be nice to preserve when making a change here.

The issue with the leek seems more complex, I responded on the Python forum.

@colesbury: I have two more questions about functions that weren't mentioned in PEP 703.

are PyGILState_Ensure() and PyGILState_Release() no-ops in free-threaded builds? Although the GIL is gone, it seems to me that these at least still compile to function calls when looking at the CPython headers, so there is presumably some cost even if their implementations don't do anything. Or do they do something? Should I be careful to #ifdef calls to these functions when building free-threaded extensions?

same question, but about the opposite direction: what do PyEval_SaveThread() and PyEval_RestoreThread() in free-threaded builds.

(These pairs are commonly called in existing pybind11/nanobind extensions to mark boundaries between parallel C++ code and previously GIL-protected Python regions.)
And an unrelated question about PEP 703: Py_BEGIN_CRITICAL_SECTION can release prior locks held by the thread to avoid deadlocks. I'm wondering about the semantics of a critical section in this case. A traditional critical section executes atomically, but this approach seems inherently non-atomic. What is the purpose of such a relaxed critical section, and what assumptions can still be made about  it?
I'm asking about critical sections because I would like to provide a builtin nanobind annotation to protect C++ instances from concurrent access (for unsafe/legacy code). Basically I'm wondering about the right primitive to build on, and whether Py_BEGIN_CRITICAL_SECTION provides enough guarantees.
Thanks!

Hi @wjakob -

There's not a substantial difference between PyMem_Malloc and PyObject_Malloc pre-3.13. They have the same performance characteristics so you can switch all of them over instead of making a version-dependent change.
PyGILState_Ensure and related APIs, including PyEval_SaveThread, are still required in the same places. They're not no-ops even when they no longer acquire/release a global interpreter lock. At a high level, you can think of them as managing thread states (i.e., PyThreadState). Threads are still required to have a valid, active thread state when calling most Python C APIs. More concretely, one of the major purposes is to synchronize with the garbage collector, which can't run while threads are mutating Python objects.

I'll reply about Py_BEGIN_CRITICAL_SECTION in a follow up comment.

The Py_BEGIN/END_CRITICAL_SECTION() pairs may (implicitly) define multiple atomically executed critical sections. For example:
Py_BEGIN_CRITICAL_SECTION(obj);
obj->x++;    // first atomically executed
obj->y--;    //  executed critical section
Py_DECREF(other); /* may call arbitrary code via finalizer */
obj->z *= 2; // second atomically executed critical section
Py_END_CRITICAL_SECTION();

In the above example:

Py_BEGIN_CRITICAL_SECTION(obj) acquires the per-object lock on obj.
obj->x++ and obj->y-- together execute atomically like in a traditional critical section
Py_DECREF(other) may internally temporarily release the per-object lock because finalizers can usually call arbitrary code.  This can happen if it calls PyEval_SaveThread() or begins a new internal critical section (which might block). Importantly, when Py_DECREF returns, the thread is guaranteed to hold the lock for obj. It's just not guaranteed to have held it continuously.
obj->z *= 2 then executes atomically
Py_END_CRITICAL_SECTION() releases the lock on obj.

The implicit breakup into multiple smaller atomically executed critical sections occurs at the same places where the GIL would have been released -- Py_DECREF() in this case.
Py_BEGIN_CRITICAL_SECTION is less straight-forward than a plain mutex, but often easier to use when dealing with the Python C API because:

It's semantics are similar to the GIL regarding which places it may be implicitly, temporarily released
Many Python C API calls including the ubiquitous Py_DECREF() may call arbitrary code so using plain mutexes often requires substantial refactoring or risks deadlocks.

If you are dealing mostly with, for example, the C++ STL then plain mutexes are probably appropriate. If you're dealing mostly with the Python C API, then Py_BEGIN_CRITICAL_SECTION is probably easier to use.

Thank you for the clarification @colesbury. That makes a lot of sense. So the new critical sections are really how things have always been with possible code execution through Py_DECREF() or even context switches to other threads while holding the GIL.
I'm think I'm done with all of the tweaks to nanobind and now wanted to test that it actually works as expected. This led me to a surprising result with v3.13rc1.  I wrote a test that launches 10 threads that each construct 1M objects and destroy them afterwards.
You can run it as follows with this PR
$ python3.13 -m pytest  tests/test_thread.py

The file contains just a single test:
def test01_object_creation():
    from test_thread_ext import Counter

    def f():
        n = 1000000
        r = [None]*n
        for i in range(n):
            r[i] = Counter()
        del r

    parallelize(f, n_thread=8)
    gc.collect()

I would expect performance to stay mostly constant until the n_threads parameter exceeds the number of physical cores of the OS. Instead, performance seems to be roughly linear in n_threads, which means that there is a bottleneck somewhere.
Interrupting the interpreter via Ctrl-C indicates that this bottleneck seems to be related to the construction of the Counter type in the example. However, the  bottleneck occurs inside Python, and before it is forwarded to nanobind. Here is a backtrace:
  * frame #0: 0x0000000198dfff88 libsystem_kernel.dylib` swtch_pri  + 8
    frame #1: 0x0000000198e3ce34 libsystem_pthread.dylib` cthread_yield  + 32
    frame #2: 0x000000010026aaa0 python3.13` _PyMutex_LockTimed [inlined] _Py_yield  + 208 at lock.c:46
    frame #3: 0x000000010026aa9c python3.13` _PyMutex_LockTimed(m=0x00000001005f8a88, timeout=-1, flags=_PY_LOCK_DET
ACH)  + 204 at lock.c:88
    frame #4: 0x000000010026b4c0 python3.13` PyMutex_Lock(m=<unavailable>)  + 8 at lock.c:582
    frame #5: 0x000000010022e980 python3.13` _PyCriticalSection_BeginSlow [inlined] _PyMutex_Lock(m=0x00000001005f8a
88)  + 80 at lock.h:49
    frame #6: 0x000000010022e96c python3.13` _PyCriticalSection_BeginSlow(c=0x0000000173e2aac8, m=0x00000001005f8a88
)  + 60 at critical_section.c:20
    frame #7: 0x000000010013fc5c python3.13` _PyType_LookupRef [inlined] _PyCriticalSection_BeginMutex(c=0x000000017
3e2aac8, m=<unavailable>)  + 524 at pycore_critical_section.h:119
    frame #8: 0x000000010013fc2c python3.13` _PyType_LookupRef(type=0x0000020000d70010, name=0x00000001005b96f8)  +
476 at typeobject.c:5256
    frame #9: 0x0000000100152370 python3.13` lookup_maybe_method(self='0x2001f611b40', attr=<unavailable>, unbound=0
x0000000173e2ab7c)  + 32 at typeobject.c:2521
    frame #10: 0x000000010014d850 python3.13` slot_tp_init [inlined] lookup_method(self='0x2001f611b40', attr=<unava
ilable>, unbound=0x0000000173e2ab7c)  + 28 at typeobject.c:2543
    frame #11: 0x000000010014d834 python3.13` slot_tp_init(self='0x2001f611b40', args=(), kwds='0x00000000')  + 56 a
t typeobject.c:9773
    frame #12: 0x00000001001433b0 python3.13` type_call(self='0x20000d70010', args=(), kwds='0x00000000')  + 464 at
typeobject.c:1990

Looking at the CPython code, it seems to me that there is a caching scheme in place that should make it possible to avoid the critical section. However, for some reason, this isn't happening.
Do you have any ideas what could be wrong?
Thank you!

I think there is a combination of two performance issues:
First, instances of nanobind.nb_method (i.e., Counter.__init__) don't use deferred reference counting (nor are they  immortal). So reference counting on those methods from multiple threads is going to be a bottleneck and inhibit scaling. Unfortunately, we don't have a public API currently to mark objects as using deferred reference counting. I think we can probably figure out a workaround, but it'd be good to get a public API (likely with the PyUnstable_ prefix) in 3.14.
The second problem is in the implementation of the MRO type cache in CPython. Basically, the fast-path lookup fails so we fall back to the locking slow path, but we're also not enabling future lookups in the fast-path to succeed. This case only happens with entries that don't use deferred reference counting (like `nanobind.nb_method), which is why we missed it, but it makes that case worse: instead of having a contended atomic operation, we have a contended lock, which is even slower.

Thank you for looking into this @colesbury! For context: nanobind uses a custom function object to implement an efficient function dispatch mechanism (i.e., faster and more flexible than the builtin C function wrappers). It is central to the design of the library—this design choice preventing multi-threaded speedups in free-threaded builds would be bad news.
Could you let me know if you see any way to force nb_method / nb_func to adopt deferred reference counting, even if hacky and only usable in a particular Python version? Rather than having a nice API in v3.14, I think it would be good to introduce unstable hack in place for v3.13. The latter is what I expect people to play around with when attempting to adapt their extension projects for free-threading.

I tried doing the hack myself. Based on the CPython internals, I added the function
void enable_deferred(PyObject *op) {
    assert(PyType_IS_GC(Py_TYPE(op)) && _Py_IsOwnedByCurrentThread(op) &&
           op->ob_ref_shared == 0);
    op->ob_gc_bits |= 64;
    op->ob_ref_local += 1;
    op->ob_ref_shared = _Py_REF_QUEUED;
}

Calling this on the function objects seems to fix the issue with critical sections. However, I'm still not seeing multithreaded speedups. Examining the callstack shows that most of the time is spent dealing with shared refcount atomics.
Does this mean that nanobind needs to bite the bullet and make immortal types and function objects? Is it correct to assume that this will break nanobind's leak tracking? For context: one feature of the library is that it complains loudly if any of its objects (classes, functions, instances) are still alive after Python has full shut down and invokes the Py_AtExit() callbacks.

I tried the main branch (v3.14.0) as well immortalizing the functions and still observed significant performance regressions.
Then I thought I'd try this in plain Python, and it turns out that the behavior there is similar. So perhaps it's better to understand the situation there.
Here is a reproducer:
import threading

def parallelize(func, n_threads):
    barrier = threading.Barrier(n_threads)

    def wrapper():
        barrier.wait()
        return func()

    workers = []
    for _ in range(n_threads):
        t = threading.Thread(target=wrapper)
        t.start()
        workers.append(t)

    for worker in workers:
        worker.join()

def f():
    def q():
        return 1
    for i in range(1000000):
        q()

parallelize(f, n_threads=8)

Performance on an M1 Max laptop (macOS) on AC power

n_threads
Runtime

1
49ms

2
202ms

4
610ms

8
2310ms

When I move the q function to the top level, the performance is worse.

n_threads
Runtime

1
63ms

2
246ms

4
1402ms

8
5601ms

Especially in the former case with a callable declared per thread, I would have expected the runtime cost to be relatively flat until 8 threads (matching the number of performance cores in this machine.)

Does this mean that nanobind needs to bite the bullet and make immortal types and function objects?

Yes, deferred reference counting isn't fully implemented in 3.13 and is more of a place, so functions and types need to be immortalized.

I tried the main branch (v3.14.0) as well immortalizing the functions...

I'll take a look at this today or tomorrow.

Hi @wjakob -
Here's a patch that demonstrates how to make functions and type objects immortal:
https://gist.github.com/colesbury/99e15d904d84d239231f465a5aca6c36
If you are doing multi-threaded benchmarking, you won't want to use suppress_immortalization. The tradeoff in 3.13 is that you either:

immortalize objects (with the associated leaks on exit), and can scale to well to multiple threads/cores
suppress immortalization (avoid leaks), but can't scale to multiple threads/cores

The other change was to move the from test_thread_ext import Counter outside of the function body of test01_object_creation. Closed over local variables are implemented using cell objects. Reading from a cell object currently takes a lock on the cell object instance. We should probably fix this for 3.14.

Thank you very much @colesbury, it fixes the performance regression. I am now seeing the following performance on the v3.14 (main) branch:

n_threads
Runtime

1
172ms

2
223ms

4
335ms

8
503ms

The cell performance caveat you mention sounds tricky to figure out for users, that would be good to fix indeed.

Thank you for all your help so far @colesbury.  I was wondering about one more thing:
In your pybind11 implementation, you sharded the (very frequently accessed) instance map based on the top 44 bits of the pointer address. The rationale was that this region is related the thread ID, and that way we can limit lock contention if every thread mostly works with its own objects. This sounded good to me, and I copied your approach in nanobind.
One potential issue is that nanobind extensions talk to each other through shared data structures, and that means that such a sharding scheme will effectively become part of the "ABI" (i.e. difficult to modify after the fact without breaking the ABI contract). It's the same also in pybind11. Hence I want to be sure that this is a good long-term solution.
Therefore, I was wondering where this came from, and what can be said about it? A few questions:

Discarding the bottom 20 bits splits memory into 1MB-sized chunks., which isn't very much So it seems it can't directly map to the thread ID.

There are actually two allocators: the system malloc() and mimalloc(). Do both of them allocate spatially segregated heaps for each thread? (In nanobind, pointers used for sharding can either be from a memory region allocated via PyObject_Malloc, or they can be on the C++ heap created via operator new/malloc())

Do you know if this behavior is consistent across platforms?

Thank you!

Hi @colesbury,
thank you your the detailed explanation and clarifying my misunderstanding. The PR is now almost done in the sense that all the internal data structures are protected for free-threading.
I wanted to ask about your thoughts regarding one more thing:
Binding tools like nanobind and pybind11 are often used to bind existing code. However, that code might often not be thread-safe and therefore unsafe to use in free-threaded Python. It's worse than pure Python code because of the possibility of memory-unsafe operations that crash the process.
To amelierate such issues, I would like to add a way for nanobind to lock Python objects involved in a function call (without having to modify the function itself).
Example: with this feature, the user could change a binding of a function with 3 named arguments
m.def("func", &func, nb::arg("argument_1"), nb::arg("argument_2"), nb::arg("argument_3"));

into one guaranteeing that the PyMutex of the first and third argument is held while the function runs.
m.def("func", &func, nb::arg("argument_1").lock(), nb::arg("argument_2"), nb::arg("argument_3").lock());

In general, this sounds like something that Py_BEGIN_CRITICAL_SECTION() and Py_BEGIN_CRITICAL_SECTION2() are made for. However, the interface I am describing would in principle allow to take out more than 2 locks.
At first, I thought this is simple: I'll just sort all of the objects by pointer address and then run PyMutex_Lock() on the ob_mutex of their PyObject *. But then I realized that ob_mutex is likely not part of the public API, and that it will be locked away if there is a free-threaded limited API at some point in the future.
Do you think what I am trying to do is possible in some forward-compatible way?
Thanks!

Hi @wjakob - I don't think there's a way to do what you are proposing. You should avoid using PyMutex_Lock to lock PyObject.ob_mutex because that can lead to deadlocks. The object might already be locked by a critical section when your functions are called. Any given lock should only be locked with the critical section APIs or with PyMutex_Lock, but not a mix.
If possible, I'd recommend limiting the implementation to locking one or two arguments so that you can use the critical section APIs.
We do something similar in CPython with Argument Clinic: https://github.com/python/cpython/blob/782217f28f0d67916fc3ff82b03b88573686c0e7/Objects/setobject.c#L1998. In our cases:

The vast majority of uses lock a single object, typically the "self" object. There's only one a few cases where it makes sense to lock two objects at once.
It's not applicable everywhere: sometimes you need to lock a field on some argument or do some setup before locking.

I've continued working on the free-threading PR and am now happy with it. Besides argument-level locking, the PR now also provides expanded documentation in docs/free_threaded.rst explaining how this all works, and what to watch out for.
I will leave it up for a few days in case someone else wants to take a look (@oremanj, @colesbury, @vfdev-5?)
@colesbury, I followed the approach you suggested, which was to only allow <= 2 locks per call and leverage the Python critical section API.
I have one request for you -- not critical, but perhaps something to look into for v3.14? The immortalization snippet you shared works well, but it does seem like an implementation detail leaking to a place where it doesn't belong. Probably CPython should add a PyObject_Immortalize`` function or similar (there is _Py_SetImmortal`, but only within the interpreter).

(Sorry, the above sounded unnecessarily stressful :-) — if anyone wants to review the change, of course you can have more than a few days. It is a quite big change).

The issue you referenced won't occur with nanobind, which uses a more fine-grained locking policy (as opposed to a global mutex for internals). The list of registered exception handlers in particular is assumed to be static/read-only following plugin initialization and not locked at all.

I read through the PR and it looks good to me, although I don't have a lot of familiarity with nanobind.

Thank you @colesbury. Would you be open to adding an offical API call for the immortalization step? I'm concerned that having this fragment (https://github.com/wjakob/nanobind/pull/695/files#diff-6de720f0a86306e2563f4f4606136d14fb439bad73da2fb7641029d0e37e6d95R1181) be a part of nanobind is not a good long-term solution.

@wjakob - yes, I would like it as part of the C API. We will need to propose it to the C API Working Group: https://github.com/capi-workgroup/decisions/issues
I think we will want at least two functions:

One to mark an object as immortal
One to mark an object as using deferred reference counting, as that will be the more appropriate behavior in 3.14+

I realized one more thing: the nb::dict iterator is tricky because it relies on the thread-unsafe PyDict_Next API. I at first tried to put a python critical section into the iterator object, but that is likely not a good idea because the iterator objects are often copied. (In particular, my impression from the Python critical section is that repeated lock acquisition of the same object triggers some kind of costly fallback path)
So for now the guidance is for the user to add a nb::ft_object_guard when iterating over dictionaries (see the added documentation). I am open to other solutions if you have suggestions.

Thank you very much for the thorough feedback @oremanj.

So for now the guidance is for the user to add a nb::ft_object_guard when iterating over dictionaries (see the added documentation). I am open to other solutions if you have suggestions.

The new C++20 input_iterator concept does not require input iterators to be copyable, so a potential solution here might be to give the dict iterator itself a ft_object_guard member, thus making it move-only. (This could be done using conditional compilation only for FT builds in order to not present a backcompat hazard.) I think this would work fine with most user code, which is just iterating over a dict; but it's certainly possible to construct cases that would no longer compile under this transformation, since the non-rangeified standard library algorithms are still defined in terms of "LegacyInputIterator" which does require copyability. I think it's worth making it anyway, because it's so easy otherwise to forget to lock the dict while iterating, and it's much easier to fix compilation errors than it is to fix thread-safety bugs.

Thank you for the helpful feedback everyone! Two more updates:

f36ce0960a9f0c0f3d674846be0e28ddea3c0a43, which makes the nb::dict iterator non-copyable while adding locking.
68f5f83fb9324b1f5a62865421459ef576c67b68 makes it possible to lock an object with unnamed arguments without suffering the (very minor) overheads of the "complex" function dispatcher. Very niche, but maybe someone with a high performance use case will appreciate it 🤓

This feature has been in the works for a while, and I will merge it for now. If there are any previously undiscovered problems, please let me know here or open a separate issue. My plan is to wait a bit more for things to stabilize and then push out a new release.
In principle, this PR should not affect existing (non-free-threaded) extensions. However, it is a whopping 2K diff with a rewrite of internal data structures. So I am again pinging users who have chimed in on GitHub in the past: @WKarel, @ManifoldFR, @hpkfft, @yosh-matsuda, @garth-wells, @luigifcruz, @awni, @qnzhou, @skallweitNV, @oremanj, @wojdyr, @jmalkin, @Chronum94. It would be great if you could compile your projects against the master branch and let me know if anything breaks between ee2384615ff5d80e5c746b6be2485b09a013aef7 (revision prior to merging this PR) and the latest master revision.

MLX tests clear on current master. Thanks for the heads up.

My FFT extension is all good with the current master.   Thanks!

Thanks! Worked like a charm.

Sorry for the delay in responding. Our unit tests didn't notice the change so everything is good for us.

@colesbury I've just released v2.2.0 on PyPI with the free-threading support included. Thank you for all of your help with this PR.


Remove images paste logic

Right now, copying file in Finder and pasting it in Messenger doesn't paste the file as attachment(in case for example .zip or .doc file), neither as an image (in case of png/jpg), but it pastes that file osx system icon. Also, pasting file from such an app as Snappy doesn't work (Messenger just does nothing. I have checked code, and there was some problem with generating fake drag&drop by MMFakeDragInfo). I have tested possible scenarios, and have found that all current logic isn't necessary, as pasting works perfectly well without it.
This bug occurred on macOS Sierra, as well as OSX El Capitan.
Tested solution on macOS Sierra, and all paste file types work well. Correct me if I didn't take into account some other paste-scenario and that pull request will break it.

@greg

Pasting files works for me, but pasting screenshots that were taken to the clipboard (⌃⌘⇧4) no longer works.

Works fine for me. Sometimes I just need to paste twice..

Correct, but it's not "sometimes", it's every time the content of your clipboard changes -- if you read the paste method, you'll see that it writes the image data to a temp file and replaces the clipboard, but doesn't actually paste (or attempts to and it doesn't work).

I want to merge this, not for the original state reason (that it's useless) but because the code is of poor quality and too hacky for my taste.
However, some things I'd like understand before merging:

Why is do we still need and implementation of - (IBAction)paste:(id)sender that just calls [[NSApplication sharedApplication] sendAction:@selector(paste:) to:nil from:self] ?

This diff doesn't remove MMFakeDragInfo which seems to be used for clipboard stuff. Where else in the code is MMFakeDragInfo used and is there a reason those other uses shouldn't be updated as well?


Bio Profiles Scroller with a button.

Bio Profiles Scroller with a button.

Profile details are set in an object array and they will be iterated

Looks Nice! 🎉


Registering a new top level namespace for Bosch Rexroth.

Dear all,
in my role as Open Source Officer and Product Security Officer at Bosch Rexroth I would like to register a new top level namespace for Bosch Rexroth.
Namespace | Description | Administered By | Taxonomy
rexroth | Namespace for use by Bosch Rexroth | Bosch Rexroth | RESERVED
Before using the RESERVED namespace, I will document the taxonomy of the namespace and make publicly available.
Best Regards
Klaus Ziegler
Engineering Excellence - processes, methods, tools DC/ENE1
Tel. +49 9352 18-6225
Fax +49<PHONE_NUMBER>669
Mobil +49<PHONE_NUMBER>1
<EMAIL_ADDRESS>www.boschrexroth.com
Bosch Rexroth AG
Maria-Theresien-Straße 23
97816 Lohr am Main
GERMANY
Sitz: Stuttgart, Registergericht: Amtsgericht Stuttgart HRB 23192
Vorstand: Dr. Steffen Haack (Vorsitzender), Thomas Donato, Holger von Hebel, Reinhard Schäfer
Vorsitzender des Aufsichtsrats: Dr. Markus Forschner

@SpessartZiegler
feel free to pullrequest the needed change as soon as you have your taxonomy published.

any update, @SpessartZiegler ?

Not yet. I'm waiting for an internal approvement. I hope In can publish a taxanomy in October.

if your internal processes are already kicked-off, it might be favorable putting your desired namespace as RESERVED.
Feel free to drop a pullrequest with the needed changes.


rails/importmap-rails

Worth keeping an eye on

Played with it for a bit. It looks great. But not sure how the work with third-party libs will be organized yet.

Been playing around with this a bit today and I think we might need to create a version of the controllers that doesn't get compiled. We could then reference these on the importmap.
https://github.com/hotwired/stimulus-rails/pull/39#issuecomment-772290602 I think this comment could give us a good idea of what we want. I'm not sure if we'll need to change our import { Controller } from 'stimulus' to match what https://github.com/hotwired/stimulus-rails uses by default in the importmap (import "@hotwired/stimulus")

import { Application } from "@hotwired/stimulus"
import { registerPolarisControllers } from 'https://cdn.skypack.dev/polaris-view-components'

const application = Application.start()
registerPolarisControllers(application)

This currently seems to work with a webpacker-less version of Rails


Add optional icon prop to Collapsible

Checklist:

[ ] Test added / Snapshots updated
[ ] Documentation added / updated

It’s not an icon size, it’s a “gap” between icon and text. “Icon” literally
can be anything of any size.
Вт, 14 сент. 2021 г. в 21:29, Dmitry Markov @.***>:

@.**** commented on this pull request.
In stories/CollapsibleStory.tsx
https://github.com/allthings/elements/pull/1201#discussion_r708527189:

         direction="column"

         flex="flex"

       >

         <Relative>

           <Icon name="alarm" size="s" />

           <CountIndicator count={42} left="12" top="-10" />

         </Relative>

       </View>

     }

     initiallyCollapsed={false}

     tabIndex={1}

     title="Section with icon"

   >

     <View

       direction="row"

       // alignV="center"

could be deleted, right?
In src/Collapsible/Collapsible.tsx
https://github.com/allthings/elements/pull/1201#discussion_r708527986:

         <Text

           style={{

           ...(icon ? { paddingLeft: '16px' } : {}),

is icon always 16px? it's better to extract as a constant and add docs
that icon should be 16px max
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/allthings/elements/pull/1201#pullrequestreview-754290668,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AABKFJZDECRDNS2MVRMHWGLUB6ICJANCNFSM5D5QID5Q
.

--
Kind regards,
Valeriy Tverdohleb


improvements for logging

Scope & Purpose
Enterprise companion PR: https://github.com/arangodb/enterprise/pull/644
Docs PR: https://github.com/arangodb/docs/pull/616
Improvements for logging. This adds the following startup options to arangod:

--log.max-entry-length: controls the maximum line length for individual log messages that are written into normal logfiles by arangod (note: this does not include audit log messages).
Any log messages longer than the specified value will be truncated and the suffix '...' will be added to them. The purpose of this parameter is to shorten long log messages in case there is not a lot of space for logfiles, and to keep rogue log messages from overusing resources.
The default value is 128 MB, which is very high and should effectively mean downwards-compatiblity with previous arangod versions, which did not restrict the maximum size of log messages.

--audit.max-entry-length: controls the maximum line length for individual audit log messages that are written into audit logs by arangod. Any audit log messages longer than the specified value will be truncated and the suffix '...' will be added to them.
The default value is 128 MB, which is very high and should effectively mean downwards-compatiblity with previous arangod versions, which did not restrict the maximum size of log messages.

--log.in-memory-level: controls which log messages are preserved in memory (in case --log.in-memory is set to true). The default value is info, meaning all log messages of types info, warning, error and fatal will be stored by an instance in memory (this was also the behavior in previous versions of ArangoDB). By setting this option to warning, only warning log messages will be preserved in memory, and by setting the option to error only error messages will be kept.
This option is useful because the number of in-memory log messages is limited to the latest 2048 messages, and these slots are by default shared between informational, warning and error messages.

Honor the value of startup option --log.api-enabled when set to false. The desired behavior in this case is to turn off the REST API for logging, but was not implemented. The default value for the option is true, so the REST API is enabled. This behavior did not change, and neither did the behavior when setting the option to a value of jwt (meaning the REST API for logging is only available for superusers with a valid JWT token).

[x] :hankey: Bugfix (requires CHANGELOG entry)
[x] :pizza: New feature (requires CHANGELOG entry, feature documentation and release notes)
[ ] :fire: Performance improvement
[x] :hammer: Refactoring/simplification
[x] :book: CHANGELOG entry made

Backports:

[x] No backports required

Related Information

[x] Docs PR: https://github.com/arangodb/docs/pull/616
[x] Enterprise PR: https://github.com/arangodb/enterprise/pull/644

Testing & Verification

[x] The behavior in this PR was manually tested
[x] This PR adds tests that were used to verify all changes:

[x] Added new integration tests (e.g. in server_parameters)

Link to Jenkins PR run:
http://<IP_ADDRESS>:8080/view/PR/job/arangodb-matrix-pr/13864/

Tests blue


Qustion: How to Set Multiple Cookies with a Strict Server?

version: v2.4.0
server: echo
strict-server

Currently, OAS does not support situations where there are multiple set-cookie headers (https://github.com/OAI/OpenAPI-Specification/issues/1237). This means that it is not possible to include multiple set-cookie headers in a Strict Server response (it is possible to have both set-cookie and Set-Cookie, but the fields are duplicated in Go).
There is no way to access echo.Context in Strict Server, so it is not possible to set cookies with it.
Is there a way to set multiple cookies in Strict Server?
(I looked for examples and tests, but I'm sorry if I missed anything!)

This should have been posted in the discussion, sorry!

https://github.com/oapi-codegen/oapi-codegen/discussions/1802


Fahrenheit support

Describe The Bug:
I am getting an error message that I believe is due to using Fahrenheit instead of Celsius. In the Homebridge web-ui, I am seeing the proper temperature, but in the iOS Home app, it is saying 153 degrees instead of 67 degrees. This makes it impossible to control, as that is outside of the range.
To Reproduce:
Use an A/C configured for Fahrenheit mode.
Expected behavior:
Proper temperature to show in the iOS Home app.
Logs:
[6/30/2024, 8:26:29 PM] [homebridge-connectlife-ac] This plugin generated a warning from the characteristic 'Cooling Threshold Temperature': characteristic was supplied illegal value: number 67 exceeded maximum of 35. See https://homebridge.io/w/JtMGR for more info.

Plugin Config:
{
    "name": "ConnectLife AC",
    "deviceNickName": "Air Conditioner",
    "loginID"<EMAIL_ADDRESS>    "password": "hidden",
    "platform": "ConnectLifeAcPlugin"
}

**Environment:**

* **Plugin Version**: 1.2.1
* **Homebridge Version**: <!-- homebridge -V -->
* **Node.js Version**: v20.15.0
* **NPM Version**: <!-- npm -v -->
* **Operating System**: Debian GNU/Linux Bookworm (12)

Hi.
Thanks for this issue report. I will take a look tomorrow to see what is wrong. If you have access to your ConnectLife app can you try to change the temperature unit to Celsius by navigating to Your AC -> Settings -> Temperature Unit.
After that, test it and then confirm if the issue is from here.
Thanks.

Awesome, 1.3.0 has fixed this.
Not necessarily related to this issue, but I guess I'm confused about the expected behavior of the plugin in general.
The plugin reads the data fine, and whatever temperature I have the AC unit set to shows up in the Home app perfectly. However, it does not seem to be able to push data. When I set the AC to off in the home app, or adjust the temperature, nothing changes on my window AC unit. Furthermore, if I change the "Cool to" target, and then force close the app, that does not persist either.
Can you tell me what the expected behavior is for these actions?

I tested only with split AC.
So you say you have a window AC and when you change the temperature from the HomeKit app it doesn't work?
The expected behavior is to work.
Maybe I will make a Debug option to output the logs from the external API server (from ConnectLife)

I'll open a new issue to keep this thread clean, and I'll share any additional details that could potentially help.


Fs rotate credentials apib

Dokumentace k endpointu na rotování credentials na FS.
fixes: https://github.com/keboola/kbc-manage-api-php-client/issues/72

Already solved in https://github.com/keboola/kbc-manage-api-php-client/pull/76


[GHSA-5g97-whc9-8g7j] node-static and @nubosoftware/node-static vulnerable to Directory Traversal

Updates

Affected products
Description

Comments
This CVE should be update to reflect it was discovered and disclosed by @lirantal

Hey @lirantal, re this PR as well as https://github.com/github/advisory-database/pull/1977
We don't tend to add discovery notes to the text body of advisories. Sorry.

I'm aware of that already but without altering some other parts of the advisory I can't post an update request (not even if I add something to the comments).
Can you please update both this PR and the other one with actually attributing the CVE entry here to my user?

I can't actually. The credit system it tied to repo advisories which neither of these CVEs are. I can keep this request in mind for the future but at the moment there's nothing I can do.

I'm not entirely sure what this means but you can see that I've been credited for it here over at Snyk https://security.snyk.io/vuln/SNYK-JS-NUBOSOFTWARENODESTATIC-3149927 and you can see I've also requested the credit to apply in a former PR here to the repository previously too https://github.com/github/advisory-database/pull/1841
Is there some other way you want me to request the attribution?

PR here to the repository previously too #1841

Indeed and we've discussed that before here https://github.com/github/advisory-database/pull/237

Is there some other way you want me to request the attribution?

Sadly no. The attribution at the moment is a two fold thing where we
a. Credit users who aid maintainers in repo advisories via discovery/reporting/fixing/whatever
b. Credit users who help us enrich our DB via the PRs in this repo.


Fuse split rotary for Group Query Attention

CC @masahi as the original author of this optimization :)

nice, does a big model that use MQA / GQA benefit from this pass? The speed up for 13B was much smaller than 7B when I tested.

llama2 70b uses GQA. Indeed the speed up is small. Only 2% I observed


Slow QScript plan generation

A few explains with approximate timings from the repl:
explain select meta(brewery).id as brewery_meta_id, brewery.name as brewery_name, beer.name as beer_name, beer.brewery_id as beer_brewery_id from `/cb/beer-sample/brewery` as brewery join `/cb/beer-sample/beer` as beer on meta(brewery).id = beer.brewery_id where beer.name = "Pale"

~ 1 minute

explain SELECT META(brewery).id AS brewery_meta_id, brewery.name AS brewery_name, beer.name AS beer_name, beer.brewery_id AS beer_brewery_id, beer.category AS beer_category FROM `/cb/beer-sample/brewery` AS brewery JOIN `/cb/beer-sample/beer` AS beer ON META(brewery).id = beer.brewery_id WHERE beer.category = "North American Ale"

No return after a few minutes (canceled)

explain select meta(brewery).id as brewery_meta_id, brewery.name as brewery_name, beer.name as beer_name, beer.brewery_id as beer_brewery_id from `/cb/beer-sample/brewery` as brewery join `/cb/beer-sample/beer` as beer on meta(brewery).id = beer.brewery_id

~ 45 seconds

explain select brewery.name as brewery_name from `/cb/beer-sample/brewery` as brewery join `/cb/beer-sample/beer` as beer on meta(brewery).id = beer.brewery_id

~ 1 second

@alissapajer This takes precedence over the join work.

@jdegoes I'm on it.

@drostron also noticed that when using * instead of specific fields in the SELECT clause it comes back very quickly.  Also the more fields that were added, the longer it took.

@damonLL thanks for extra the info. This is similar to what I fixed before, so I need to figure out how to make our QScript optimizations resilient to this once and for all. The difference here seems to be the added join.

Ok I just brought down the compilation time of the ~45 second query above to ~0.8sec spent in main QScript compilation. Now 0.8sec is still way too slow in the big picture, and I'll do some more investigation here in case there is more low-hanging fruit.
Also the query in the bug report that never returned, returned the QScript in ~0.9sec. Again too slow for what our customers need, but much more usable than never.
This was the same problem as before, just applied to other cases. I have an idea about how to apply the solution more generally so we won't keep hitting the same cases...

Just a touch more documentation of timing: I'm seeing the "never" query returning in couchbase in a total of ~2.0 seconds. So half the time is QScript, half is elsewhere.


Add Code for Naïve Bayes Algorithm

I would like to work on this under GSSoC'21. I will add the complete code from scratch. Please assign it to me.

Duplicate


Sia issue

A critical error loading Sia has occured: Siad unexpectedly exited. Error log: Sia Daemon v1.3.1
Loading...
(0/6) Loading siad...
(1/6) Loading gateway...
(2/6) Loading consensus...
difficulty adjustment hardfork incompatibility detected
Stack Trace or error message
Environment

Sia version: 1.3.1
OS:10.13.2

Any useful logs
Feature Request
Check to see if the feature is on the roadmap.  If it is not on the roadmap then clearly describe your feature request and why it would benefit Sia.
Sia roadmap

Please follow these instructions to fix: https://blog.sia.tech/troubleshooting-the-recent-hardfork-ca77e0b17f0f


Bump net2 and miow to get rid of invalid memory layout assumption

Fixes #1390
After getting net2 0.2.36 and miow 0.2.2 fixed and published we can bump mio so it forces the usage of dependencies not making invalid memory layout assumptions on std::net::SocketAddr.

So, does mio 0.6 support Rust back to 1.18 and this is not negotiable? Then we have a problem. Because net2 won't build on so old Rust. And it's nothing I did with the 0.2.36 changes. net2 has not built worked with so old Rust for many versions from what I can find.

Since these other crates in the dependency chain does not regard an MSRV bump as a breaking change, it's somewhat hard for mio to provide that guarantee. I'd argue that the best would be to merge this, bump the MSRV to 1.31.0 (the oldest version I can make it work with) and simply let the (almost guaranteed) very few people using something older simply not bump their mio dependency. They currently can't bump their net2 or miow dependency anyway :shrug:.
Every yearly Rust survey have showed that very very few use anything older than the latest stable Rust version.

@carllerche I don't use Mio v0.6 any more, do you know of any use cases that needs to support < Rust 1.31?

Thanks for all the work @faern.

@Thomasdezeeuw Will you release 0.6.23 now or does that release wait for something more?

Waiting on #1353.


Setup Release Action

Description

Add semantic release for release
Release the package when develop is merged to release.

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


#328 | sharing locality in map

@timlinux

LGTM thanks

Can you resolve the conflicts so we can merge.


Websocket installation without enabling secure connection

I have been trying to install the latest websocket plugin on a dev server using simple http and unsecured ws connection.
I get lots of errors that I have not seen before. Here is my config doc:
#start websocket settings
WEBSOCKET_PORT=8080
WEBSOCKET_PROXY_BACKEND_HOST=<IP_ADDRESS>
WEBSOCKET_PROXY_BACKEND_PORT=80
WEBSOCKET_REDIRECT_PORTS=80
#username used for server-side operations (e.g. agent signer)
WEBSOCKET_USER=websocket
WEBSOCKET_PASSWORD=****
#debug/test settingg
WEBSOCKET_DEBUG=false
WEBSOCKET_TEST_MODE=false
WEBSOCKET_MAX_MSG_SIZE=15977336
#security settings
#WEBSOCKET_FILTER=com.tc.websocket.filtrestart serverer,com.tc.websocket.filter.AllowedCharsFilter
WEBSOCKET_ALLOW_ANONYMOUS=false
WEBSOCKET_THREAD_COUNT=1
WEBSOCKET_EVENT_LOOP_THREADS=2
WEBSOCKET_MAX_CONNECTIONS=8000
WEBSOCKET_ALLOWED_ORIGINS=<IP_ADDRESS>, <IP_ADDRESS>, cktest.lanl.gov
#network encryption settings
WEBSOCKET_ENCRYPT=false
#WEBSOCKET_KEYSTORE_PATH=C:/domino/websocket.jks
#WEBSOCKET_KEY_PASSWORD=*****
#WEBSOCKET_KEYSTORE_PASSWORD=*****
#WEBSOCKET_KEYSTORE_TYPE=JKS
WEBSOCKET_COMPRESSION_ENABLED=true
WEBSOCKET_SEND_BUFFER=16384
WEBSOCKET_RECEIVE_BUFFER=16384

See attached log and error files:
console.log.txt
error-log-0.xml.txt
startup.log.txt
trace-log-0.xml.txt

Update 1:
I removed everything from the config document and the server started up nicely, albeit with lot of warnings.
[20E8:0002-1CE8] 07/11/2016 04:12:24 PM  HTTP JVM: xockets.io service: Opening trusted session to gain access to the config document.
[20E8:0002-1CE8] 07/11/2016 04:12:24 PM  HTTP JVM: xockets.io service: Config session is CN=csaba/O=home
[20E8:0002-1CE8] 07/11/2016 04:12:24 PM  HTTP JVM: xockets.io service: Loading websocket configuration from notes.ini
[20E8:0002-1CE8] 07/11/2016 04:12:24 PM  HTTP JVM: xockets.io service: ****WARNING: WEBSOCKET_USER and WEBSOCKET_PASSWORD are not setup.  xockets.io will run under a trusted session.****
[20E8:0002-1CE8] 07/11/2016 04:12:24 PM  HTTP JVM: xockets.io service: Send buffer is 8192 bytes
[20E8:0002-1CE8] 07/11/2016 04:12:24 PM  HTTP JVM: xockets.io service: Receive buffer is 8192 bytes
[20E8:0002-1CE8] 07/11/2016 04:12:24 PM  HTTP JVM: xockets.io service: ****WARNING: All origins are allowed. Not recommended****
[20E8:0002-1CE8] 07/11/2016 04:12:24 PM  HTTP JVM: xockets.io service: Loading 2 event loop thread(s).
[20E8:0002-1CE8] 07/11/2016 04:12:24 PM  HTTP JVM: xockets.io service: Loading 1 other background thread(s).
[20E8:0002-1CE8] 07/11/2016 04:12:24 PM  HTTP JVM: xockets.io service: Purge interval is 900 seconds.
[20E8:0002-1CE8] 07/11/2016 04:12:24 PM  HTTP JVM: xockets.io service: Compression disabled
[20E8:0002-1CE8] 07/11/2016 04:12:24 PM  HTTP JVM: xockets.io service: Maximum connections 200
[20E8:0002-1CE8] 07/11/2016 04:12:24 PM  HTTP JVM: xockets.io service: ****WARNING: Websocket connections not encrypted.****
[20E8:0002-1CE8] 07/11/2016 04:12:24 PM  HTTP JVM: xockets.io service: ****WARNING: Anonymous access is allowed.****
[20E8:0002-1CE8] 07/11/2016 04:12:24 PM  HTTP JVM: xockets.io service: No websocket filter registered.
[20E8:0002-1CE8] 07/11/2016 04:12:25 PM  HTTP JVM: xockets.io service: xockets.io ready and listening on 8889 running version 2.0.6
[20E8:0002-1CE8] 07/11/2016 04:12:25 PM  XSP Command Manager initialized
[20E8:0002-1CE8] 07/11/2016 04:12:27 PM  HTTP Server: Started

I will investigate further

Update 2:
It works now. I had to use the full user name in my config document such as
websocket websocket/home
with the short name it did not work.
I still get one error message

but it does not seem to effect the server.
Can you please clarify, if these security settings are correct and if I need to add the websocket user anywhere else:

Looks like you have it covered.  Just make sure the id you are using has
appropriate ACL settings to websocket.nsf and any other .nsf it will
interact with.
On Monday, July 11, 2016, Csaba Kiss<EMAIL_ADDRESS>wrote:

Update 2:
It works now. I had to use the full user name in my config document such as
websocket websocket/home
with the short name it did not work.
I still get one error message
[image: image]
https://cloud.githubusercontent.com/assets/2583367/16750610/d9062a6c-4787-11e6-8fa7-3f0fc261c106.png
but it does not seem to effect the server.
Can you please clarify, if these security settings are correct and if I
need to add the websocket user anywhere else:
[image: image]
https://cloud.githubusercontent.com/assets/2583367/16750643/1037ba3c-4788-11e6-9973-6f648df65431.png
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
https://github.com/mwambler/xockets.io/issues/18#issuecomment-231899945,
or mute the thread
https://github.com/notifications/unsubscribe/AEI46RjGUFXlAjNQmv4QrvgYB3MeN2_eks5qUteqgaJpZM4JJsIe
.

--
Mark Ambler

Just to make sure.
What ACL does the websocket user need for websocket.nsf (I use: Manager with delete) and for websocketupdate.nsf?

On Jul 11, 2016, at 6:10 PM, mwambler<EMAIL_ADDRESS>wrote:
Looks like you have it covered. Just make sure the id you are using has
appropriate ACL settings to websocket.nsf and any other .nsf it will
interact with.
On Monday, July 11, 2016, Csaba Kiss<EMAIL_ADDRESS>wrote:

Update 2:
It works now. I had to use the full user name in my config document such as
websocket websocket/home
with the short name it did not work.
I still get one error message
[image: image]
https://cloud.githubusercontent.com/assets/2583367/16750610/d9062a6c-4787-11e6-8fa7-3f0fc261c106.png
but it does not seem to effect the server.
Can you please clarify, if these security settings are correct and if I
need to add the websocket user anywhere else:
[image: image]
https://cloud.githubusercontent.com/assets/2583367/16750643/1037ba3c-4788-11e6-9973-6f648df65431.png
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
https://github.com/mwambler/xockets.io/issues/18#issuecomment-231899945,
or mute the thread
https://github.com/notifications/unsubscribe/AEI46RjGUFXlAjNQmv4QrvgYB3MeN2_eks5qUteqgaJpZM4JJsIe
.

--
Mark Ambler
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub https://github.com/mwambler/xockets.io/issues/18#issuecomment-231902356, or mute the thread https://github.com/notifications/unsubscribe/ACdrR-YrZp3tqsojywIN5diU1XWVTtBeks5qUtthgaJpZM4JJsIe.

Editor with deletion should do... Designer or higher on target nsf for
rhino / ssjs scripts
On Monday, July 11, 2016, Csaba Kiss<EMAIL_ADDRESS>wrote:

Just to make sure.
What ACL does the websocket user need for websocket.nsf (I use: Manager
with delete) and for websocketupdate.nsf?

On Jul 11, 2016, at 6:10 PM, mwambler<EMAIL_ADDRESS><javascript:_e(%7B%7D,'cvml','notifications@github.com');>> wrote:
Looks like you have it covered. Just make sure the id you are using has
appropriate ACL settings to websocket.nsf and any other .nsf it will
interact with.
On Monday, July 11, 2016, Csaba Kiss<EMAIL_ADDRESS><javascript:_e(%7B%7D,'cvml','notifications@github.com');>> wrote:

Update 2:
It works now. I had to use the full user name in my config document
such as
websocket websocket/home
with the short name it did not work.
I still get one error message
[image: image]
<
https://cloud.githubusercontent.com/assets/2583367/16750610/d9062a6c-4787-11e6-8fa7-3f0fc261c106.png

but it does not seem to effect the server.
Can you please clarify, if these security settings are correct and if I
need to add the websocket user anywhere else:
[image: image]
<
https://cloud.githubusercontent.com/assets/2583367/16750643/1037ba3c-4788-11e6-9973-6f648df65431.png

—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<
https://github.com/mwambler/xockets.io/issues/18#issuecomment-231899945>,
or mute the thread
<
https://github.com/notifications/unsubscribe/AEI46RjGUFXlAjNQmv4QrvgYB3MeN2_eks5qUteqgaJpZM4JJsIe

.

--
Mark Ambler
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub <
https://github.com/mwambler/xockets.io/issues/18#issuecomment-231902356>,
or mute the thread <
https://github.com/notifications/unsubscribe/ACdrR-YrZp3tqsojywIN5diU1XWVTtBeks5qUtthgaJpZM4JJsIe
.

—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
https://github.com/mwambler/xockets.io/issues/18#issuecomment-231902728,
or mute the thread
https://github.com/notifications/unsubscribe/AEI46WUGqZMV2cxqjvYsO7ZnF55u8x7mks5qUtwCgaJpZM4JJsIe
.

--
Mark Ambler


Add an option to not render config if there's only one permutation

I left this with the default behavior unchanged and the option to set it to 1 which is the one that makes the most sense I think. But I would also consider that changing the default to 1 might make sense.
Fixes https://github.com/tfoote/yatm-v2/issues/1
I'm still learning Rust so haven't grokked how to effectively add testing coverage for this.

Thanks I rebased and fixed the formatting caught by CI.


Run in series

@aldeed here's a proposal to solve running in parallel/series re: https://github.com/DispatchMe/meteor-mocha/issues/6
In readme:
Run in parallel
By default dispatch:mocha will run in series. This is a safety mechanism since running a client test and server test which depend on DB state may have side-effects.
If you design your client and server tests to not share state, then you can run tests faster.
Run in parallel simply by exporting the environment variable TEST_PARALLEL=1 or TEST_PARALLEL=true before running.

I made the change to shouldRunInParallel bug. But the other changes you suggest cause the print to appear in the incorrect order in parallel mode.

@keyscores You can solve the print header issue by changing that function to this:
function printHeader(type) {
  const lines = [
    '\n--------------------------------',
    `----- RUNNING ${type} TESTS -----`,
    '--------------------------------\n',
  ];
  lines.forEach(line => {
    if (type === 'CLIENT') {
      clientLogBuffer(line);
    } else {
      console.log(line);
    }
  });
}

No prob. See now.

Good observations. It looks clean now.


Sponsor image is broken

I think it's because it's pointing to the master branch (I think the path can be relative to the root instead of absolute)

@arielj Fixed by this commit: https://github.com/fastruby/pecas/commit/bb13e193500e6065ea54bb6f7996acf7148750e9


[Event Request] Codeunit 6638 "Sales-Get Return Receipts" - OnAfterTransferLinesToSalesDoc

Please add the following Event OnAfterTransferLinesToSalesDoc in Codeunit 6638 "Sales-Get Return Receipts"
    procedure CreateInvLines(var ReturnRcptLine2: Record "Return Receipt Line")
<...>
                until Next() = 0;
                //>><< New event
                OnAfterTransferLinesToSalesDoc(SalesHeader);
            end;
        end;

    [IntegrationEvent(false, false)]
    local procedure OnAfterTransferLinesToSalesDoc(VAR SalesHeader : Record "Sales Header");
    begin
    end;

Hi @AdrijaSipaviciute
You have existing OnAfterCreateInvLines(SalesHeader); which could be used here.
We can add just var if it is necessary.

Hi @AleksandricMarko
I agree, we will use OnAfterCreateInvLines event. Var is not required. Issue can be closed.

Thanks for reporting this. We agree, and we’ll publish a fix asap, either in an update for the current version or in the next major release. Please do not reply to this, as we do not monitor closed issues. If you have follow-up questions or requests, please create a new issue where you reference this one.
Build ID: 12046.


Adaptive throttling for mouse events

Currently, mouse events fire at a fixed rate of 20 per second. This is an acceptable middle ground, but is suboptimal for most users.

For systems that can handle > 20 events per second, we're hobbling mouse performance.
For systems where the target machine has no mouse input (e.g., console-only display), we're clogging the socket between the browser and TinyPilot with 20 junk events per second.

We should instead use adaptive throttling that increases and decreases throttling depending on:

The measured round-trip times of previous mouse event messages between the browser and TinyPilot
Recent failures to write mouse events to the target system

@JRansomed - if you get a chance, I'm curious to hear what your performance is like on the current version. What should happen is that you'll likely see a slight delay in keystrokes the first few times you move the mouse across the screen, but it should quickly throttle mouse events down to a max of once per 2 seconds, so it should be infrequent enough that it doesn't impact keystroke forwarding.


Question about HyenaDNA working

Hello,
I have been using HyenaDNA to pre-train it on my custom dataset, and I wanted some insight into its working based on the output logs from the pre-training run. For every epoch, after updating model weights based on the training data, the tool evaluates the performance on the validation data by calculating val/loss. In the process, it loads validation data from two different dataloaders (Validation Dataloader 0 and Validation Dataloader 1). I provided the test data separately from the validation data, and after varying the train : validation : test splits, I found that the size of Validation Dataloader 1 changes in proportion to the size of the test set. Why does this happen, given that the test set is separate from the validation set, and that the tool reports a separate value of test/loss after every epoch?

I don't really understand your issue.
Validation Dataloader 1 is the test dataloader, that's just how Lightning handles it.
Are you using the Hg38 or species dataloader?
For HG38, take a look here.  It's similar for the species dataloader.
This defines exactly what dataset is used for each dataloader.  Make sure you're passing the right dataset object to the right dataloader.  This is the same for Pytorch dataloaders too, vs Lightning.
I recommend adding breakpoints and stepping through the code line by line in the dataloader to see the objects are exactly as you expect.

Thank you for the clarification! I'm new to deep learning and wasn't aware that Validation Dataloader 1 indeed is the test dataloader, not the validation dataloader.

Thank you for the clarification! I'm new to deep learning and wasn't aware that Validation Dataloader 1 indeed is the test dataloader, not the validation dataloader.


Lets Encrypt returning 400 Bad Request for certificate signing requests?

I've been using dehydrated reliably for years, but noticed today when I went to renew some certs that the requests are failing with:
  + ERROR: An error occurred while sending post-request to https://acme-v02.api.letsencrypt.org/acme/new-order (Status 400)

Details:
HTTP/2 400
server: nginx
date: Sat, 24 Sep 2022 00:20:50 GMT
content-type: application/problem+json
content-length: 107
boulder-requester: 609382046
cache-control: public, max-age=0, no-cache
link: <https://acme-v02.api.letsencrypt.org/directory>;rel="index"
replay-nonce: 0101NNOevri97g8xtGCk0ljInrw7lgEUwLPOPHDbhXCpWX0

{
  "type": "urn:ietf:params:acme:error:malformed",
  "detail": "JWS verification error",
  "status": 400
}

Any idea what the culprit may be?

FWIW I worked around this by deleting the certs/accounts directory for the domains. I guess the key got out of sync or something?

I got this today for the first time:
+ ERROR: An error occurred while sending head-request to https://acme-v02.api.letsencrypt.org/acme/new-nonce (Status 503)

Details:
HTTP/2 503
server: nginx
date: Thu, 27 Oct 2022 23:50:04 GMT
content-type: application/problem+json
content-length: 90
cache-control: private
retry-after: 3

/dehydrated/dehydrated: line 737: 1: unbound variable
  + ERROR: An error occurred while sending post-request to https://acme-v02.api.letsencrypt.org/acme/order/11690994/138565828467 (Status 400)

Details:
HTTP/2 400
server: nginx
date: Thu, 27 Oct 2022 23:50:05 GMT
content-type: application/problem+json
content-length: 112
cache-control: public, max-age=0, no-cache
link: [<https://acme-v02.api.letsencrypt.org/directory>](https://acme-v02.api.letsencrypt.org/directory);rel="index"
replay-nonce: 1DFA7pHrb7cFoE2br2Rk-_Jc9orXrSwMLxT6afaeVk2IUzg

{
  "type": "urn:ietf:params:acme:error:badNonce",
  "detail": "JWS has no anti-replay nonce",
  "status": 400
}

/dehydrated/dehydrated: line 737: 1: unbound variable
EXPECTED value GOT EOF

Let's Encrypt had planned downtime on Oct 23, 2022 that got moved to this weekend:
October 28, 2022 20:00 - October 31, 2022 20:00 UTC
https://letsencrypt.status.io/pages/55957a99e800baa4470002da
I was getting tons of errors on staging (had numerous downtime periods) and one of two production endpoints were down at one point or another. Just a heads-up for anyone with errors recently.

i cannot remembered the place to specific the challenge url.. by example to use acme-v02.api.letsencrypt.org event the default https://acme-v02.api.letsencrypt.org


Find the correct fields when using page filter on struct fields in parquet

Which issue does this PR close?

Closes #8456
Rationale for this change

What changes are included in this PR?

The issue is in this line  c.column_descr().name() == column.name() in find_column_index datafusion/core/src/datasource/physical_plan/parquet/page_filter.rs . When struct fields have the same name as the column names that condition is returning the struct field instead of the column field.
Are these changes tested?
Yes I have added a test which is taken from the reproduction code.

Are there any user-facing changes?
No

I took the liberty of merging this branch with main and running cargo fmt which will hopefully get the CI to pass

Thanks again @manoj-inukolunu


Taxonomy Management: implement update concreteness command

#3556

This pull request introduces 2 alerts when merging 95cea697daa07a937168f4ee260984c38806a43b into a4e09015fcb04f58e1071bffe9ecf5710edce2ad - view on LGTM.com
new alerts:

2 for Unused format argument

Comment posted by LGTM.com


Support ALTER TABLE t REORGANIZE PARTITION

What problem does this PR solve?

Issue Number: close #8113
What is changed and how it works?
Adding timodel.ActionReorganizePartition to the allowDDLList and include it for updatePartition in DoHandleDDL.
Check List
Tests

Unit test
Integration test

Questions
Will it cause performance regression or break compatibility?
Do you need to update user documentation, design documentation or monitoring documentation?
Release note
Adding support for ALTER TABLE ... REORGANIZE PARTITION

Could you please fix the failed unit tests and add a ALTER TABLE ... REORGANIZE PARTITION SQL to here: https://github.com/pingcap/tiflow/blob/master/tests/integration_tests/partition_table/data/prepare.sql#L28 to test whether TiCDC can handle this DDL expectedly.

Could you please fix the failed unit tests and add a ALTER TABLE ... REORGANIZE PARTITION SQL to here: https://github.com/pingcap/tiflow/blob/master/tests/integration_tests/partition_table/data/prepare.sql#L28 to test whether TiCDC can handle this DDL expectedly.

Hi @asddongmen, I have added such test as well. Could you please review it now?

@asddongmen @zhaoxinyu @tangenta PTAL, I have updated the patch and included the requested test.

/merge

/retest

/run-verify

/run-engine-integration-test

/run-kafka-integration-test

/run-MySQL-integration

/run-verify
/run-engine-integration-tests


Run makemigrations to add missing migrations file

Fixes #185. No tests were added since this is only adding migrations file.

The only thing is one of the models we're previously edited (#184). Even though that PR was merged, it was still generating migration files. Should we undo that also?

No, it's ok. I don't really understand why django includes the verbose name and non-db stuff in the migration, it's really annoying to have to regenerate migrations when you change some working :x
Thank you for your work!


Tooltip flickering

The tooltips for halted and resume buttons in the sidebar sometimes flicker when hovering over the button.
This was tested on iso6-next and iso5-next on firefox.
Steps to reproduce:

Hover over the Stop (or Resume) button of the sidebar
The tooltip sometimes briefly appears on top of the button and then snaps to the right of it

@Hugo-Inmanta can you add a recording of this?

Screencast from 09-02-2023 11:17:21.webm


YouTube DASH bestvideo+bestaudio excluding WebM?

Hello,
I read the format selection readme:
https://github.com/rg3/youtube-dl/blob/master/README.md#format-selection
But I still have got a question:
What would the format selection have to look like if you would want to get YouTube DASH bestvideo+bestaudio excluding WebM?
I mean so that you will get the best H.264 video and the best AAC audio and not WebM.
I only need H.264 video and AAC audio because hardware acceleration does not work on WebM.
Regards

Would:
-f bestvideo[ext=mp4]+bestaudio[ext=mp4]
be correct?

Yes.


[Bug] The name of the Widget is 'TreeSelect' in Widget Pane and 'SingleSelectTree' in the canvas

Description
Release/Production - It is observed that the name of the Widget is 'TreeSelect' in Entity Explorer but when it is dragged to canvas the name of the widget is 'SingleSelectTree'
Expected Result:
Name of the widget should be same both in Canvas and Widget pane
Steps to reproduce the behaviour:

Launch Appmsith app in the release Environment
Open any of the App
Expand widget pane and check for TreeSelect Widget
Drag and drop Tree select tp Canvas and observe the name

Important Details

Version: [11.3]
OS: [MacOS Big sur]
Browser [chrome, safari]
Environment [production, release]

Is there anyone working on this issue?

I wanna work on this issue.

@SriSatyaT It's all yours! 🎉
Please don't forget to read the Contribution Guidelines. Would appreciate if you can open a PR within the next 2 days.
Also, please don't forget to register with Appsmith's Hacktoberfest Community in order to be eligible for Appsmith swag.

@ipankajchaudhary
Thank you for showing interest in Appsmith.
Sorry, this issue has already been claimed. I would request you to please look at some of our other Good First Issues

@SriSatyaT It's all yours! 🎉
Please don't forget to read the Contribution Guidelines. Would appreciate if you can open a PR within the next 2 days.
Also, please don't forget to register with Appsmith's Hacktoberfest Community in order to be eligible for Appsmith swag.

Sure :)

i'm intrested

i'm intrested

Hey thanks for showing intrest. I'll make pr by tomorrow. Hope you grab the other issue.

Pls review this PR #8474


Showcase Submission for code/2-variables/4-random

Thank you Mohammed Ayath (aka GD Cyber) for your contribution! A member of the Coding Train team will review it shortly.

Guys help my project is tweaking
Mohammed Ayath (aka GD Cyber)

Hi @GDCybernetix, thank you for submitting! It's my preference that the thumbnail images are screenshots of the sketches themselves. Would you mind if I swapped out the image for a screenshot of your sketch? Great job coding!

I have replaced with an image from the sketch.

Thank you @kfahn22!


feat: initial liquidity deduction for pair protection

Summary of changes

Report of required housekeeping

[ ] Github issue OR spec proposal link
[ ] Wrote tests
[ ] Added a relevant changelog entry to CHANGELOG.md

(FOR ADMIN) Before merging

[ ] Added appropriate labels to PR
[ ] Squashed all commits, uses message "Merge pull request #XYZ: [title]" (coding standards)
[ ] Confirm added tests are consistent with the intended behavior of changes
[ ] Ensure all tests pass

Codecov Report

Merging #12 (e3c4fcc) into fix/provide-slippage (31f5256) will increase coverage by 0.08%.
The diff coverage is 97.43%.

:exclamation: Your organization is not using the GitHub App Integration. As a result you may experience degraded service beginning May 15th. Please install the Github App Integration for your organization. Read more.
@@                   Coverage Diff                    @@
##           fix/provide-slippage      #12      +/-   ##
========================================================
+ Coverage                 88.24%   88.33%   +0.08%
========================================================
  Files                        19       19
  Lines                      3421     3454      +33
========================================================
+ Hits                       3019     3051      +32
- Misses                      402      403       +1

Impacted Files
Coverage Δ

contracts/terraswap_pair/src/testing.rs
99.32% <96.00%> (-0.12%)
:arrow_down:

contracts/terraswap_pair/src/contract.rs
92.15% <100.00%> (+0.26%)
:arrow_up:


qt webkit for qt4 is very old, upgrade to community version of qtwebkit for qt4

There is a community version of QtWebKit that is based on a much more recent version webkit.
https://gitorious.org/webkit/qtwebkit-23/
https://blogs.kde.org/2012/11/14/introducing-qtwebkit-23
Most distributions are using that.
https://tracker.debian.org/pkg/qtwebkit
https://build.opensuse.org/package/show?project=openSUSE%3AFactory&package=libQtWebKit4
http://packages.ubuntu.com/trusty/libqtwebkit-dev

Which packages using qt4 do you mean to target? I would guess they might often better be migrated to qt5.

Upgrading packages to qt5 is a lot of work and might not even be desired for upstream packages. The package which would need the newer qtwebkit is blink.
I would think that the adapted branch has a drop in replacement for the webkit directory.

Blink is a fork of WebKit. Why would it depend on qtwebkit?

Blink here is not the webengine blink, but the voip application blink.
http://icanblink.com/
https://github.com/NixOS/nixpkgs/blob/master/pkgs/applications/networking/instant-messengers/blink/default.nix

Aha, nice coincidence :-)

Yeah, the concrete issue is that an extension to blink has been developed and is about to be released as foss. The extension lets you edit collaboratively on a text document while doing chat or voip call, via the same connection. This is using webodf.
Unfortunately, the webkit in qt4 is not up to the task.

(triage) Qt has seen many changes. Close?

(triage) is anyone still interested in this? we don't know the current status, so I will close the issue in a month if nobody replies back.

Let’s just close it now, since I already asked a quarter year ago. ;)


Feature Request: Add a option to set a indentation of QTreeWidget

Issue Report Checklist

[x] Searched the issues page for similar reports
[x] Read the relevant sections of the Spyder Troubleshooting Guide and followed its advice
[ ] Reproduced the issue after updating with conda update spyder (or pip, if not using Anaconda)
[ ] Could not reproduce inside jupyter qtconsole (if console-related)
[ ] Tried basic troubleshooting (if a bug/error)

[ ] Restarted Spyder
[ ] Reset preferences with spyder --reset
[ ] Reinstalled the latest version of Anaconda
[ ] Tried the other applicable steps from the Troubleshooting Guide

[x] Completed the Problem Description, Steps to Reproduce and Version sections below

Problem Description
I use a narrow window for outline explorer and project explorer. So a indentation of QTreewidget is long for me. What do you think about adding a option to set a indendation?

Paste Traceback/Error Below (if applicable)

PASTE TRACEBACK HERE

Versions

Spyder version: spyder 4.0.0dev lastest commit
Python version: 3.6.8
Qt version: 5.9.4
PyQt version: 5.9.2
Operating System name/version: 4.20.3-1-MANJARO

Dependencies

PASTE DEPENDENCIES HERE

Please don't add an option. Simply reduce the current indentation so things look better after your change.

@ccordoba12 Ok. Thak you for your reply.


Bug: GuDebugLog does not report end of match

In some instances such as using alt+f4, slow disk, or file being read while it was being written to. The debug log file will no longer write new information. This is a hold over bug for all previous versions.

The primary issue is using File.ReadAllText, while it quick to read compared to File.Read, it uses FileShare.None as the default option when reading files. This is causing the debug.log file to be held open by GUvrs preventing the Gods Unchained client from writing new data.
The resolution is going to be not using File.ReadAllText and instead using File.Read so that FileShare.ReadWrite can be supplied so that GUvrs does not old a file lock open on the file.

This is now fixed in 9f128fe686c93817f81f8eacd4d42e21b57a6dee pending a new release.


Remove the "self" argument from ignore_exists, which was causing initial...

... migrations to fail
Because ignore_exists is a function not a class method, it does not need a self argument.
Additionally, the Migration.forwards method does not pass "self" to the function.
Fix thanks to Jason Michalski.

Thanks!  But, this is already fixed and part of 2.3.2!

sorry, 2.4.2


Fix: Disallow sharded for KeyType.Main

Allow sharded only for KeyType.Custom

closes #1511

Status verification: ✅


Fix/instrumentation

Record latest block number for StateTransition jobs
Currently, StateTransition jobs record the starting block number instead of the ending block when processing multiple blocks. This PR changes it to record the ending block number (external_id) specifically for StateTransition jobs, while keeping the behavior the same for other job types.

coverage: 67.448% (-0.001%) from 67.449%
when pulling fd4d688dd62e419525c6ddb9cf5ebd0639922c30 on fix/instrumentation
into a008642b1708530c9b0a7ec3cac1e57529b949ea on main.


Assess KLAYTN integration

https://docs.klaytn.com/

Klaytn mainnet is called Cypress, was launched on Jun/27/2019:

1-second block generation and confirmation time
4K TPS
Low gas price: 1/10th of Ethereum
Fully compatible EVM
Consensus is supported by 19 "reputable" corporations worldwide (current number of consensus nodes is shown in https://scope.klaytn.com/)

Laytn can be partitioned into three logical subnetworks based on their roles and purposes:

Core Cell Network (CCN): made of Core Cells (CCs) that verify and execute txs submitted through Endpoint Nodes (ENs). CCN is responsible for creating and propagating blocks throughout the network.
Endpoint Node Network (ENN): made of ENs that mainly create txs, handle RPC API requests and process data request from service chains.
Service Chain Networks (SCN). SCNs are Klaytn subnetworks composed of auxiliary blockchains independently operated by dApps. Service chains are connected to the main chain via ENs.

Klaytn Cypress (Mainnet):

RPC URL: https://public-node-api.klaytnapi.com/v1/cypress
Chain ID: 8217
Symbol: KLAY
Explorer URL: https://scope.klaytn.com

Klaytn Baobab (Testnet):

RPC URL: https://api.baobab.klaytn.net:8651
Chain ID: 1001
Symbol: tKLAY
Explorer: https://baobab.scope.klaytn.com
Klaytn Faucet: https://baobab.wallet.klaytn.com/access?next=faucet

*Warning: klaytn faucet requires a sign-in process in which a private key must provided. Anyone using this faucet should first a random private key that will be only used for getting tKLAY from the faucet, and eventually sending tKLAY to the regular testnet master address used for smart contracts deployment and price feeds updates. *

Given a private key, Klaytn Faucet provides 150 KLAY every 24 hours

Complete!


production ready?

Thanks for the Svelte Native framework. I liked what I have seen so far.
However, before I invest more time and energy, I wanted to know if Svelte Native is production ready yet or not?
Are there any pending issues that may cause major issues for app developers? Are most/all Nativescript features available through Svelte Native? Is the Svelte Native framework ready for complex apps?
Please feel free to add other details along the lines of above. This would help other developers make informed decisions for  their new/future projects.

Following...

It is the least supported of the Nativescript frameworks. People have put it in production since the joy of Svelte is sometimes worth the risk :). From my limited knowledge, most serious apps are either Nativescript Core, Angular or Vue (as these were all official packages and the maintainers are on the core nativescript team). I try to fix bugs when I come across them or when they are reported. I also advocate for svelte-native concerns with svelte maintainers.

Thanks. Please update this issue if things change in future.