Suggestion: PR adding Eslint, VueTSC and automatic checkers?

Hi @Deluze, I added some conveniences to my project, and I would like to know if you are interested in a PR including:

Eslint
Prettier
Vue TSC
Debug for VSCode (currently working only with Main Process, but as Renderer Process can use DevTools debugger, it may be sufficient for now)
Automatic code checker when on development env, including with visual alerts inside de app:

Whilst I'm a fan of ESLint and Vue TSC, I do want to keep this template as clean and straight forward as possible. Developers shouldn't feel the need of removing packages/files they don't want to use, which also was the reason why I decided to make my template public next to all the countless of others out there. "No unnecessary dependency overhead" actually used to be the slogan of this template.
Your suggestion is great for projects, even personal ones, though I don't think it would be a good fit for this template.
Also: I saw you added this project to the awesome-vite list. Thank you! It feels amazing to see others share this template in any way.


Updates

Variable values would be overwritten by new values after sequentially posting datasets to Datamart.

add a notebook describing the bug of the POST API
fix the 'data' tag issue: 'data' tag will be detected from template and extract data segments accordingly
add a utils module to cover common subroutines among notebooks
update the templates and notebooks for FSI, WFP, and FAOSTAT


VueJS Support, please :)

VSCode Version: 1.12
OS Version: windows 10

Hey,
support (syntax, intellisense etc. ) of vue.js would be great.
Thanks !

We defer vue.js support to extensions. Try installing https://marketplace.visualstudio.com/items?itemName=octref.vetur


Request: Let player edit item macros

It could be a toggleable box in the module settings. I think this would be useful for players with technical knowledge so they don't need to pester their GM every time they want to test an item macro.

This is being added with the new version, should be out as soon as I get parellel modules to update their code

Newest version is out and should fix this!


BPMSPL-209 - Provide alternative to DB based job executor

ready for review

+1
Thanks for sharing the PR!

thanks Marco, will leave the PR open for one or two days more and then merge it by the end of the week.

merged into master and 6.3.x, kie-wb-distribution-wars PR will be merged once BPMSPL-210 is merged so it gets complete setup of JMS


Resolving references to CTE Columns fails

Version
1.27.0
What happened?
Resolving references to multiple CTE's with arguments fails.
This is a duplicate of #3219, but 3219 has been closed even thought the issue still persists and the relevant PR is not merged.
PR to fix this issue: https://github.com/sqlc-dev/sqlc/pull/3220
Relevant log output
sqlc generate failed.
# package
query.sql:5:28: table alias "t1_ids" does not exist

Database schema
CREATE TABLE t1
(
    id SERIAL NOT NULL PRIMARY KEY
);

SQL queries
-- name: CTERef :one
WITH t1_ids AS (
    SELECT id FROM t1
)
SELECT * FROM t1_ids WHERE t1_ids.id = sqlc.arg('id');

Configuration
{
  "version": "2",
  "sql": [{
    "schema": "schema.sql",
    "queries": "query.sql",
    "engine": "postgresql",
    "gen": {
      "go": {
        "out": "db"
      }
    }
  }]
}

Playground URL
https://play.sqlc.dev/p/9048b486f822c300301650867612e42bef8f8d512dfd12d84ad3a4cd210f4ef7
What operating system are you using?
Linux
What database engines are you using?
PostgreSQL
What type of code are you generating?
Go

If anyone else runs into this issue and lands on this page, I found it usually works if you explicitly annotate the appropriate type on the sqlc argument:
-- name: CTERef :one
WITH t1_ids AS (
    SELECT id FROM t1
)
SELECT * FROM t1_ids WHERE t1_ids.id = sqlc.arg('id')::uuid;
--                                                   ^^^^^^

This makes sqlc happy for now, until the above fix is merged.

I have a similar issue, but the workaround suggested in this case does not work.
https://play.sqlc.dev/p/3df2d3f54eff7ef74e32ffca38be69ddd9a3dc7058cbe7ae9274007e05909236
The SQL in the link is silly, as I have reduced the case as much as possible.
The actual query is trying to retrieve a single record with some conditions and insert a modified version of the same record using input provided by the user.


input parameter and property for setting the batch_shape

The following code
w = inf.Normal(np.zeros([k,d]), 1, name="w")

assert w.shape == [k,d]
assert w.sample_shape == []
assert assert w.dim == [k,d]
assert assert w.dim == w.batch_shape

is equivalent to
w = inf.Normal(0, 1, dim =[k,d])

assert w.shape == [k,d]
assert w.sample_shape == []
assert assert w.dim == [k,d]
assert assert w.dim == w.batch_shape

Note that the scalar parameters are broadcasted to the dimensions [k,d].
Instead of getting the batch_shape from the distribution parameters, these are obtained from the input parameter dim. We might call it dim instead of batch_shape for making it more understandable. As the batch_shape is a property from edward RVs, this can be already obtained. Yet, for keeping a coherence in the names, we might implement a property dim:
@property
def dim(self):
    return self.batch_shape

Closed in #bd906331b79fa95ffb28beff8bc2763668b580e9


Saving Error on Naturalcrit.com

Error Code
Error: Unauthorized

Error: Unauthorized
    at Request.<anonymous> (https://homebrewery.naturalcrit.com/homebrew/bundle.js:78380:21)
    at Emitter.emit (https://homebrewery.naturalcrit.com/homebrew/bundle.js:1954:20)
    at XMLHttpRequest.<anonymous> (https://homebrewery.naturalcrit.com/homebrew/bundle.js:78674:10)
{
  "status": 401,
  "method": "PUT",
  "url": "/api/update/xOD4GcItrCAA"
}

### Your description of what happened:

The Error just occured.

This problem should be resolved now.  If it persists for you, please followup in this thread.
Closing this comment as a duplicate.


I don't know how to install

Can I have instructions on how to install it?
I've download the requirements.txt and I don't know what to do next.
Does it work on Windows?

Blank screen after opening


Additional support for AdaGrad as a learning_rule

This is now supported since the PyLearn2 bugs in the learning rule were fixed here:
https://github.com/lisa-lab/pylearn2/pull/1521

Coverage remained the same at 100.0% when pulling c9f58c0ff9cd6bb7b42a49f095971b54cc9f8770 on adagrad into 2e6e1be49b8441f07fceea5cb13b92544c3b8b2d on master.

Coverage remained the same at 100.0% when pulling c9f58c0ff9cd6bb7b42a49f095971b54cc9f8770 on adagrad into 2e6e1be49b8441f07fceea5cb13b92544c3b8b2d on master.


Expose rotation_interval_month in KMS DA and default it to "12"

Relevant code: https://github.com/terraform-ibm-modules/terraform-ibm-kms-all-inclusive/blob/d1495563e20394125742bae7b0fe59501d95f47a/solutions/standard/main.tf#L31
Expose rotation_interval_month in KMS DA as a variable and default it to "12"

PR merged, closing


tests: drivers: spi: spi_loopback: test failed since #34731 is merged

Describe the bug
Since merge of #34731 drivers/spi: STM32: This solves SPI infinite loop on Transceive
tests/drivers/spi/spi_loopback/ is failed on

nucleo_f103rb,
nucleo_f746zg
stm32f3_disco

To Reproduce
Steps to reproduce the behavior:

west build -p auto -b nucleo_f746zg tests/drivers/spi/spi_loopback/
west flash
See error

Expected behavior
test passed
Logs and console output
*** Booting Zephyr OS build v2.6.0-rc1-284-gc00504e875e2  ***
Running test suite test_spi
===================================================================
START - test_spi_loopback
I: SPI test on buffers TX/RX 0x20010131/0x20010a1a
I: SPI test slow config
I: Start complete multiple
I: CS control inhibited (no GPIO device)
I: Passed
I: Start complete loop
I: Passed
I: Start null tx
I: Passed
I: Start half start
I: Passed
I: Start half end
E: Buffer contents are different: 0x38,0x39,0x61,0x62,0x63,0x64,0x65,0x66,
E:                            vs: 0x35,0x36,0x37,0x38,0x39,0x61,0x62,0x63,

    Assertion failed at WEST_TOPDIR/zephyr/tests/drivers/spi/spi_loopback/src/spi.c:382: spi_rx_half_end: (1 is true)
Buffer contents are different
 FAIL - test_spi_loopback in 0.54 seconds
===================================================================
Test suite test_spi failed.
===================================================================
PROJECT EXECUTION FAILED

Environment (please complete the following information):

OS: Linux,
Toolchain Zephyr SDK
Commit SHA 5f61d89233

Wonder if this is effectively a duplicate of https://github.com/zephyrproject-rtos/zephyr/issues/35297

Similar on nucleo_f413zh, I came across this while testing an SPI device. On nucleo_f413zh it is a bit different, data in RX buffer is shifted up one octet, reverting<PHONE_NUMBER>055156bc79fd8faafaf13e601438b4 fixes the issue.
*** Booting Zephyr OS build v2.6.0-rc1-299-gd999d5eb64f4  ***
Running test suite test_spi
===================================================================
START - test_spi_loopback
I: SPI test on buffers TX/RX 0x20000131/0x2000098e
I: SPI test slow config
I: Start complete multiple
I: CS control inhibited (no GPIO device)
I: Passed
I: Start complete loop
I: Passed
I: Start null tx
I: Passed
I: Start half start
I: Passed
I: Start half end
E: Buffer contents are different: 0x38,0x39,0x61,0x62,0x63,0x64,0x65,0x66,
E:                            vs: 0x37,0x38,0x39,0x61,0x62,0x63,0x64,0x65,

I have a similar issue with the nucleo_f767zi, as seen here #35561, where @jfischer-no pointed it out.

Does anyone know of a commit state where the nucleo-f103rb or nucleo-f767zi was working for SPI? I have both boards to test with, as well as the nucleo-L152.

@ddkn
you can either go back to sha1: 13303c4351d9b88f0c522cf5b5a4835a42cb6403
or simply revert  #34731 (aka sha1<PHONE_NUMBER>055156bc79fd8faafaf13e601438b4)
I hope it will fix your SPI issue.

Hi @ABOSTM,
Thanks for the response. I had tried the revert earlier, which had the buffer issue I mentioned. Where 013303c4 gives the same error message, but then @FRASTM in #35561 pointed out I need to connect D11 -> D12 for the loopback to work correctly (I assumed it was doing something internal). It works, now.


alpha should be a float

What does this implement/fix? Explain your changes.
alpha should be a float

@aliutkus right?

yes, right, in full generality


[hw/entropy] Harden the debug scenarios and other single points of failure on critical paths

Harden the debug scenarios (for example bypassing AES, and other OTP options) against fault injection attacks. Similarly to examine single points of failure on critical paths.
Marking as P0 in terms of implementation priority with respect to other hardening tasks.

I believe we have addressed these concerns in the latest hardening.
@moidx @mwbranstad @cdgori let me know if you disagree.


My adjust size which may or may not work

It's not super legible since I didn't feel like going through and substituting the charID values, but figured I'd throw up my actionmanager code for adjusting text layer sizes, so you can benchmark and see which is faster. It's not completely analogous, since I don't adjust the text layer position after the size change, it also will adjust multiple layers at once. I didn't really test it to make sure it works as is, so, uhh, have fun with that.
As an additional thought, I'm not sure how robust the hotkeys are, but if you do end up binding increase/decrease to hotkeys, you might want to introduce a multiplier to the adjustment value depending on if shift/ctrl are pressed.

Thank you. I'll take a look and try to implement it while retaining all the functionality.
By the way, do you happen to know the proper way to listen the hotkeys pressed when the extension panel is out of focus? For now I'm polling the hostfile that checks ScriptUI.environment.keyboardState. But it can only listen the state of win/ctrl/shift/alt keys (keyboardState.keyName doesn't work in this case).

I haven't really looked into how hotkeys work with the panels. I wasn't aware that they embedded chromium into CC releases before I saw your project. From glancing at a couple searches, it seems like you were able to consume regular keys for the first few updates? My guess would be that they decided the benefit for unfocused panels consuming keystrokes wasn't worth the possible confusion for the user when their hotkeys for other things didn't work.


DatastoreSessionHandler fails with error

Hi, I'm trying to configure Datastore session storage. I'm using an example from https://github.com/GoogleCloudPlatform/google-cloud-php/blob/master/src/Datastore/DatastoreSessionHandler.php
$datastore = new DatastoreClient();
$handler = new DatastoreSessionHandler($datastore);
session_set_save_handler($handler, true);
session_save_path('sessions');
session_start();

and it produces an error

Fatal error: session_start(): Failed to initialize storage module: user (path: sessions)

@vanzay
Is the client able to write to the datastore?
Have you enabled Datastore API on your Cloud Project?

@tmatsuo
Yes, writing to Datastore and API are enabled.

Hi @vanzay are you still running into trouble?
Would you mind trying to save an entity outside the session handler? This could help determine whether the problem is in the datastore side, or the session handler.
Try running something like this:
<?php
use Google\Cloud\Datastore\DatastoreClient;

// If you're not using application default credentials, be sure to inject your keyfile into the client.
$datastore = new DatastoreClient;

$key = $datastore->key('Test', 'Test');
$entity = $datastore->entity($key, [
    'key' => 'value'
]);

$datastore->upsert($entity);

print_r($datastore->lookup($key));

Here is the output for the code above:

Google\Cloud\Datastore\Entity Object ( [key:Google\Cloud\Datastore\Entity:private] => Google\Cloud\Datastore\Key Object ( [projectId:Google\Cloud\Datastore\Key:private] => investory-a7063 [path:Google\Cloud\Datastore\Key:private] => Array ( [0] => Array ( [kind] => Test [name] => Test ) ) [options:Google\Cloud\Datastore\Key:private] => Array ( [namespaceId] => ) ) [entity:Google\Cloud\Datastore\Entity:private] => Array ( [key] => value ) [options:Google\Cloud\Datastore\Entity:private] => Array ( [cursor] => [baseVersion] =><PHONE_NUMBER>511000 [className] => [populatedByService] => 1 [excludeFromIndexes] => Array ( ) [meanings] => Array ( ) ) )

And I see this item in the GCloud Datastore console.
But sessions still don't work.

It seems that the reason for the error

Fatal error: session_start(): Failed to initialize storage module: user (path: sessions)
was SSL problems.

I added the following code
    $guzzleClient = new Client(['verify' => false]);     $handler = function ($request, array $options = []) use ($guzzleClient) {         return $guzzleClient->send($request, $options);     };
and the error doesn't reproduce anymore.
Nonetheless, I still don't see session data in the Datastore console.

Is there anything in your server's error logs regarding this? Possibly some message below the reporting threshold?

@vanzay Have you set an error handler? It could provide some helpful information, if not.

I've tried it out again. And now I see session data in the console.
Perhaps, I previously mixed up environment.

Awesome! I'm going to close this out now then, please feel free to re-open if anything else comes up.


Problem with doors on V12.

Foundry: V12.328
Dungeon Draw: 3.0.2
Platform: Chromium and Electron App on Linux
Doors are not aligned with walls and don't make "holes" when drawn on walls. Tested with different systems on a fresh world without any other modules enabled. Please have a look at the attached screencast.
vokoscreenNG-2024-07-12_11-08-18.webm

Observing the same symptoms.
Foundry Stable 12 Build 331 is the server.
Firefox 128.3.1esr 64-bit is the client.

I am also seeing this behaviour since V12 as are others in the OSE/UFT Discord. Everything worked perfectly on V11.
Version 12 Stable, 12.331, Brave [Version 1.71.118 Chromium: 130.0.6723.70 (Official Build) (arm64)]

Sorry, day job has given me very few Foundry cycles recently.
I started debugging this tonight and have a hypothesis, which is that v12 somehow broke snap in Dungeon Draw... which means doors aren't snapping exactly to a given wall's x or y position, which means the code doesn't see the wall/door as overlapping and thus won't split the wall.

Just released 3.0.3 with snap fixed (at least for my local testing). This also fixed the doors-not-splitting-walls problem, as now doors are snapped, which lets them line up exactly with the wall and get detected as overlapping.
Please re-open if this doesn't fix it for you.

Just released 3.0.3 with snap fixed (at least for my local testing). This also fixed the doors-not-splitting-walls problem, as now doors are snapped, which lets them line up exactly with the wall and get detected as overlapping.
Please re-open if this doesn't fix it for you.

Just tested it.  The doors are aligned with the walls, however the sections of walls that should be "cut and deleted" or spliced out are still there.

I cannot see the option to reopen a closed issue.

I am also seeing walls overlapping doors even using DD 3.0.3. (I will make a new 'ping' incident referring to this since we apparently do not have permission to re-open this case)

Reopened, and thanks for testing! I'll do some more debugging and fix.

Apparently I built 3.0.3 without the updated code :P
I've build 3.0.4 that should now include the snap fix. Can someone besides me test and confirm happiness?

Just made a quick test using 3.0.4 and it looks good to me. 😁

This worked for my game, thanks!

Marking fixed.


Helm install with only pilot enabled doesn't work

Describe the bug
tried to start only the pilot, but failed
Expected behavior
expect user can only install network portion of istio.
Steps to reproduce the bug
~/Downloads/istio-1.0.0 :watch: 17:12:59
$ helm install install/kubernetes/helm/istio --name istio --namespace istio-system --set security.enabled=false \
  --set ingress.enabled=false \
  --set gateways.istio-ingressgateway.enabled=false \
  --set gateways.istio-egressgateway.enabled=false \
  --set galley.enabled=false \
  --set sidecarInjectorWebhook.enabled=false \
  --set mixer.enabled=false \
  --set prometheus.enabled=false \
  --set global.proxy.envoyStatsd.enabled=false \
  --set pilot.sidecar=false

(edited)
NAME                          READY     STATUS              RESTARTS   AGE
istio-pilot-c7469fb87-vfx7m   0/1       ContainerCreating   0          19h

Version
1.0.0
Is Istio Auth enabled or not?
no
Environment
k8s 1.9.9
Could use a little help troubleshoot this since there is no log for pilot pod.  cc @costinm @rshriram @ymesika
Enable network and security does work.  FYI.

@ymesika thank you - that was it, got pilot up running now.   I'll submit a PR for this soon.

@linsun another option is to add to the secret an optional: true instead of having if condition to remove the volume mount.

This is working now, and minimal profile is published

I just came across this using istioctl 1.4.0 and the --profile minimum, and pilot doesn't want to come up.
from discovery container
2019-11-17T21:33:37.222333Z     info    mcp     (re)trying to establish new MCP sink stream
2019-11-17T21:33:37.222487Z     error   mcp     Failed to create a new MCP sink stream: rpc error: code = Unavailable desc = all SubConns are in TransientFailure, latest connection error: connection error: desc = "transport: Error while dialing dial tcp <IP_ADDRESS>:15019: connect: connection refused"

from istio-proxy container
2019-11-17T21:34:09.063949Z     info    waiting for file

Has this not actually be published to the minimal profile?
What's the fix?


Superday logs sent by the users

Several cases with Superday logs came in Desk during your vacation.
The cases are: #406999, #407023, #407388, #407476

also 407618

#407832 as well and he also sent a feature request "It needs to know about sleep."

408139 sent logs as well, commented: "How about "family" or "exercise" categories?"

408168

409603

Don't think we still need this.


qt-box-editor-1.11  Click nothing

copy there qt-box-editor-1.11.exe
extract there qt-box-editor-dependecies-1.11.zip
1.09 works, but 1.11 doesn't work, and 1.11 has no error message.
Is there something wrong with my environment?Win10 1903

why you did not try the latest version?

为什么您没有尝试最新版本？

Thank you very much for your reply!I use this version because I need to be compatible with win7, win8, win10 and xp, so I can only use the lower version.

Than you are in trouble - without error message there is no possibility to find solution...
If any investigation would start (e.g. adding some debugging info) it would be in 1.12 version... Anyway AFAIK all systems you mentioned excluding win10 are officially unsupported by MS, so...

Thank you for your reply. I will think of other ways to solve this problem. Thank you!


CMake build failed with wangle:64-linux, because facebook libraries are out of date.

@nusus ,Could you please commit a pr fix this issue? and you can open a issue of facebook update,I will update it
Originally posted by @JonLiu1993 in https://github.com/microsoft/vcpkg/issues/20586#issuecomment-939207808

@nusus ,I will fix this bug in pr #20586, reopen issue #20586 and cloesed this issue


Replace lodash with lodash. deps

Hey there, we're using react-dnd-html5-backend from NPM and we're quite surprised by the size of the library. The whole react-dnd is taking 4.7M and almost all of that is only lodash. From lodash you're using only memoize, union, without and defaults functions. These are available separately from NPM taking only 148K.
I've already reported similar issue in react-dnd and also #39 might be related to this.
Would you be interested in a PR?

See https://github.com/gaearon/react-dnd/pull/517#issuecomment-244173416.

Closing based on the conversation at https://github.com/gaearon/react-dnd/pull/517.


[docs] Increase the contrast of the demos

Use a white background for the demos as much as possible:

Increase the contrast.
Less opinionated background color, closer to the most common cases.

Before
https://material-ui.com/components/text-fields/#textfield

After
https://deploy-preview-18396--material-ui.netlify.com/components/text-fields/#textfield

@mbrookes What do you think if I work on moving more demos to the outlined version?

What do you think if I keep iteration on moving more demos to the white background version?

How do you plan to differentiate the demo from the page? The outline doesn't seem sufficient to me.

After this change, if we visually compare the filled background between our implementation and material.io, we can see something is off:
material.io

material-ui.com

Except that you're comparing it to the MCW implementation, which, like several other components, doesn't follow the spec. (See also: https://github.com/mui-org/material-ui/issues/12889#issuecomment-525456431 😄)
The filled text field matches:

(And most other examples)
But not:

(Which unhelpfully doesn't provide RGBA values to use.)
Perhaps the spec has changed slightly since the last revision of the component? There's a record of contrast ratio in the discussion linked above, so it would be easy to tell.

@mbrookes Every time I ask Una about a specification question, she sends me toward material-components-web and not the material.io website. I'm confused.
(I start more and more to believe that our users are looking for a UI that looks like the Google products that are used to. I would be cautious not to upgrade to match a new spec until at least a few Google products do)

@mbrookes I think that it's really important that we display the elements on a white background as often as possible. While this change might introduce consistency. I still think that it puts us in a better place, overall. We likely want to use bg: true when displaying an element in a fullscreen context. For instance, when we display an iframe, an app bar or mobile tabs. Or when displaying an elevated Paper component, to improve the box-shadow contrast. bg: false is better suited for displaying small individual elements.


docs: use jupyterhub_sphinx_theme, add make devenv/linkcheck

We have discussed use of a jupyterhub_sphinx_theme in https://github.com/jupyterhub/team-compass/issues/524 and @choldgraf has created it. I suggest we start using it!
In this PR I adjust conf.py to look like other jupyterhub projects I've updated recently, linking out to relevant configuration references and omitting some configuration not needed etc.

Closes #6
Relates to https://github.com/jupyterhub/team-compass/issues/524#issuecomment-1366712568

should we just move that template repo to the jupyterhub/ org? That way we aren't depending on a thing attached to my personal account?

I am +1 to move that under jupyterhub too 👍🏼

@choldgraf yes go for it! I think there is sufficient agreement that this is a good idea in https://github.com/jupyterhub/team-compass/issues/524

Draft state

The opengraph preview is currently failing for the docs/ in this project, but was meant to work.

We reference choldgraf/jupyterhub-sphinx-theme but should update to jupyterhub/jupyterhub-sphinx-theme soon: https://github.com/jupyterhub/team-compass/issues/524

The jupyterhub-sphinx-theme is in the jupyterhub org, and the opengraph issues are resolved. There is an issue with the favicon, but that would be resolved by https://github.com/jupyterhub/jupyterhub-sphinx-theme/pull/11 independent of this PR.


extensions: register TestAccessor filter

We use this in Lyft's integration with Envoy Mobile. It should be harmless to add even though we don't currently need it, and it will be helpful to keep the Envoy Mobile configuration close to the Lyft one considering that we're running Envoy Mobile in production and can help identify issues at scale.
Signed-off-by: JP Simard<EMAIL_ADDRESS>

I think I'm lacking some context - let's chat today.

I'm checking to see if this is actually needed in our Lyft-side tests and will just close the PR if it's not needed.

We're already configuring this extension in https://github.com/envoyproxy/envoy-mobile/blob/1eb14c9d3026dd956b46873b2fe0287d456294af/bazel/envoy_mobile_test_extensions.bzl#L6


Add abrandell to Contributors list

Hi  @abrandell, I'm quite elated about your pull request. I wanna evolve this project to addresses various problems faced by first-time contributors. I'd love to learn about your journey in open source community, the problems, pain points you had etc.
Could you explain how you felt when you went through the tutorial, made a pull request and learned that I merged it?
We’ve recently added social share  to our web app. Could you please go to https://roshanjossey.github.io/first-contributions/#social-share and share your first contribution to open source?
Also, check out projects with easy issues while you’re there.

@Roshanjossey I've been wanting to contribute to open source projects for a while but never really understood how to to use Git. This tutorial was honestly great. Only trouble I had was trying to located where the directory was created, but I switched to the normal git-cmd.exe instead of bash and it worked fine.


Typecover not working on Sonoma 14.7

Heya
Currently trying this out and I installed Sonoma 14.7
Everything works quite alright, even touch works surprisingly, but not the typecover.
I have tried a few kext's except for BigSurface, I even tried the experimental kext from lazd, but that didnt fix the issue and broke the pen support.
I wonder if anybody has tried Sonoma 14.7 already and might have an idea on how to fix the issues.
Thanks!

Forgot to add some more context:
At the start the typecover worked without any issues during the installation process, I didnt see any other issues as well.
After the installation finished and I booted into macOS, the typecover completely stopped working in the bootloader and MacOS

Okay I fixed the issue, of course that happens once I post an issue about it.
No fixes are needed, apparently the keyboard couldnt get recognized after the installation process and all I had to do was unplug the keyboard and plug it back in. Thanks for the project! Made the installation process really not painful


C++ alternative operator tokens should be treated as keywords

C++ has a set of alternative operator tokens to refer to certain operations, which are keywords in C++. These are typically highlighted like other keywords in editors, but they're currently classified as Name according to this pygments demo.
It would be great if these could be turned into Keyword or Keyword.Operator (if the latter is possible).

Fixed by #2421 (forgot to put this in the commit message).


Handle submitting when no option selected

Hi,
When user enters search term that doesn't match to a suggestion, or they just haven't selected a suggestion, I want to handle the submit button. Specifically I want to redirect to search page with this search term.
At the moment it errors with: Cannot read property 'onSelected' of undefined.
Can you suggest a suitable approach?
Thanks!

It depends on how you're implementing it, two different ways.

If you're using the sectionConfig to define multiple sections then you will need make sure there is a "default" section. Here is an example codepen that fires when nothing is selected: https://codesandbox.io/s/yjl79nj4zv
i.e. the defaultSection.onSelected() is selected. You can replace the console.log with a window.location redirect

If you do not have sectionConfig defined, then all on-select events will be funneled into the on-selected prop and you can do as you please, such as window.location.href = 'your-url-here.com'


Make sure EnvironmentResolver::getConfig() always returns string or null

Codecov Report

Merging #113 (2d181af) into main (a31b51e) will increase coverage by 0.07%.
The diff coverage is 100.00%.

:exclamation: Current head 2d181af differs from pull request most recent head 1a34921. Consider uploading reports for the commit 1a34921 to get more accurate results

@@             Coverage Diff              @@
##               main     #113      +/-   ##
============================================
+ Coverage     62.37%   62.45%   +0.07%
- Complexity      437      439       +2
============================================
  Files            64       64
  Lines          1555     1558       +3
============================================
+ Hits            970      973       +3
  Misses          585      585

Impacted Files
Coverage Δ

src/Environment/EnvironmentResolver.php
98.63% <100.00%> (+0.05%)
:arrow_up:

:mega: We’re building smart automated test selection to slash your CI/CD build times. Learn more


Include the prefix http:// or https:// in the Image URL

The image URL needs to include the prefixes mentioned in the title of this issue.
Consider that copy such URLs do not work in Markdown files.
Just using an inline style:
![fx](//tex.s2cms.ru/png/f(x))

renders to

Instead of:

by prepending the http:// prefix
![fx](http://tex.s2cms.ru/png/f(x))

Actually the URL scheme may be omitted and such scheme-agnostic URLs are perfectly valid: https://stackoverflow.com/questions/9161769/url-without-httphttps
However, some markdown parsers (including Github) fail to detect them.
I could add the "https:" prefix for generated image URLs in the interface. But it would result in dropping old user agents without SNI (https://caniuse.com/#search=sni) if the "https" link appears on a "http" website. That's why I choose scheme-agnostic URLs for http://tex.s2cms.com/

Ok. Maybe adding an option to choose.


Which optimisations are permissible?

At the HIPERFIT reading group meeting, we discussed whether it is permissible for the optimiser to convert non-terminating programs into terminating ones.  I am still not convinced one way or the other (but currently the Futhark compiler will indeed do that).
Basically, the question is whether the two propositions "the unoptimised program computes V" and "the optimised program computes V" are connected by implication or bi-implication.
If we want this to be a bi-implication, we may hinder ourselves quite a bit, for example by not permitting removal of a division expression (even as dead code) unless we can statically prove that the divisor is non-zero.

That's bit of red herring question.
An 'optimiser' changes program semantics anyway -- its very purpose is to
change a program (with a semantics and cost model) into another one subject
to keeping something invariant.   The most important thing, I believe, is
being able to say something precise as to what an optimizer keeps invariant
and what it may change: e.g
"It rearranges data structures and computations resulting in changes (with
fingers crossed and a couple of Hail Marys: improvements) of resource
consumption, but it'll always have the same (infinitary) external behavior."
Or
"It does the above, plus furthermore doesn't increase space consumption
(absolutely or asymptotically) -- no space leaks."
Or
"It preserves (finitely observable) external behavior, and futhermore, it
never makes run time performance worse; it may improve run time
performance, including the possibility of returning something where the
original runs on for ever (in both cases according to the program
semantics, not some implementation machine)."
The latter says the optimizer may return a program that terminates more
often than the original -- this arguably falls into the category of
"improving run time".
Invariants preserved include those maintaining certain performance
relations between pairs of input programs; e.g. "the optimizer always
yields a program that is at least as fast for source program e[c/x] as for
source program let x = c in e[x]".
Fritz
On Tue, Apr 14, 2015 at 2:27 PM, Troels Henriksen<EMAIL_ADDRESS>wrote:

At the HIPERFIT reading group meeting, we discussed whether it is
permissible for the optimiser to convert non-terminating programs into
terminating ones. I am still not convinced one way or the other (but
currently the Futhark compiler will indeed do that).
Basically, the question is whether the two propositions "the unoptimised
program computes V" and "the optimised program computes V" are connected by
implication or bi-implication.
If we want this to be a bi-implication, we may hinder ourselves quite a
bit, for example by not permitting removal of a division expression (even
as dead code) unless we can statically prove that the divisor is non-zero.
—
Reply to this email directly or view it on GitHub
https://github.com/HIPERFIT/futhark/issues/47.

Determining how the optimiser may change edge cases (or modifying the language such that edge cases become impossible, e.g. by totality) is exactly the issue here.
I realised that the issue will in fact crop up with something even simpler than dead code elimination - in the expression a[-1] + diverge(), it is based on evaluation order whether the program terminates with a range error or diverges, and Futhark does not specify evaluation order.
My conclusion is to not worry much about this for now, since this seems like a profound research question, and it is mostly orthogonal to what we try to do with Futhark.

Different kinds of nontermination cannot be distinguished.  An invalid/nonterminating program may become terminating through optimisation.  There is no reason to spend more cycles on this.


chore: builds custom server example

Description
Builds a custom server example into the /examples directory. This is a successor of https://github.com/payloadcms/nextjs-custom-server.

[x] I have read and understand the CONTRIBUTING.md document in this repository

@thgh you literally ROCK!! Thank you for reviewing this so thoroughly. Such a huge help. 🙌


Simplify and extend usage documentation

Hi Frederik!
The Advanced usage section may be a bit overwhelming at first sight. I was thinking about dissecting it into smaller sections/examples that each explains only a single concept e.g. Reconnecting (see lines 41-56).
This makes it more in line with the TLS and Proxying sections and would make it easier to add/remove/edit the examples in the future. I'd also like to add a section about topic filters, closing #105.
Let me know what you think 😊
-- Felix

Hi Felix. :)
Thanks again for taking your time to improve asyncio-mqtt. It's really appreciated. 👍
Great idea to make the readme more approachable/comprehensible. In general, we lack on the documentation/examples side. I welcome all improvements in that area.
As for your specific suggestion, I think it makes great sense to split the readme up into smaller sections. Makes it easier to digest a given topic. Maybe this grows into an actual documentation (e.g., "Read the Docs" style) in the future.
 If you're up for it, you're very welcome to join the asyncio-mqtt team. :) There are no strings attached, you just contribute/maintain asyncio-mqtt whenever you feel like it (or not at all if you grow tired of it).
You'll get direct read/write rights to the repo, so you can change the code directly without PRs. Of course, you're welcome to keep the PR workflow and I'll gladly review/comment on the PRs. For minor/non-breaking changes, it's just easier to edit the repo directly.
~Frederik

As for your specific suggestion, I think it makes great sense to split the readme up into smaller sections. Makes it easier to digest a given topic.

Great! I'll write something down in the next few days :)

Your contributions so far are on point and in line with my own thinking/direction. If you're up for it, you're very welcome to join the asyncio-mqtt team. :) There are no strings attached, you just contribute/maintain asyncio-mqtt whenever you feel like it (or not at all if you grow tired of it).

Sure, I'm up for it, thanks for the trust! I'll keep with the PR workflow for most things I think, I like when someone looks over it, then I can learn from the comments :)

Great! I'll write something down in the next few days :)

Sounds good! I'll be ready to review the PR.

Sure, I'm up for it, thanks for the trust! I'll keep with the PR workflow for most things I think, I like when someone looks over it, then I can learn from the comments :)

Exellent! I'll add you right away. Welcome aboard. :)

Looking good so far. 👍 I especially like the new ### Configuring the client section. It neatly showcases the available functionality, Likewise, it's nice with several, specialized examples instead of a single, "advanced" example.
Could merge as is but let me know when you want to do so. :)

Great that you like it! 🎉

I stumbled on two things while writing this down. (1.) In #105 you said that "we use filtered_messages to deinterleave [...] messages". I still don't really understand the benefit of the example in the README over:
async with Client("test.mosquitto.org") as client:
    async with client.unfiltered_messages() as messages:
        await client.subscribe("measurements/#")
        async for message in messages:
            if message.topic == "measurements/humidity":
                # do something humidity specific
            if message.topic == "measurements/temperature":
                # do something temperature specific

Is it that with filtered_messages messages of different topics can be processed concurrently? Or that the different filters can be changed afterward more easily? Or that the filters can include special characters like measurements/+/something (though that could be easily implemented differently)?
The current way seems overly complicated to me at the moment, so I feel like I'm not seeing something 😄

(2.) is that I don't understand how to share an MQTT connection between functions. In #82 (which was sadly handled very childishly by the issue author) you said that sharing the client between different files is an anti-pattern.
I searched around quite a bit, but I didn't find anything for "sharing context managers", "sharing database connection via context managers", or similar. Maybe I'm searching in the wrong direction. Could you give me some pointers on how I can find more information on this? Or is the idea to open a new connection for each message?
I'd like to add a section about this to the README as well.

Great questions. Let me try to answer them. :)
Indeed, it's a bit strange that we have both filtered_messages vs unfiltered_messages. It's because paho-mqtt has both. Personally, I would just have unfiltered_messages (and simply call it messages) and then do the filtering manually (like you do with ifs in your example code).
asyncio-mqtt is just a wrapper around paho-mqtt. In that spirit, I decided to not change the interface too much (and keep the filtered functionality). Maybe that wasn't a wise decision. 😅
As far as I know, paho-mqtt basically reimplements the topic wildcards (+ and *) on the client for filtered_messages. So it does provide some convenience over simple ifs. Enough convenience to warrant the existence of filtered? Personally, I don't really think  so but the paho-mqtt developers apparently thought so. :)

Yeah, #82 did have some merit because we don't have examples to show how to do it proper. The conversation just got a bit off track.
To share a client between multiple functions, just pass the Client instance to the function! That's all there is to it. I usually have the async with Client() in the "main" function and then pass said Client to all other functions that want to subscribe/publish.
However, there are two problems with this approach:

Some frameworks take control over the "main" function, which makes it difficult to figure out where to create/enter the Client.
What if the connection breaks? There is no reconnect functionality.

Frameworks such as FastAPI solve (1) via their dependency system. We can give an example for FastAPI just to show how.
Problem (2) is more difficult. It requires more fundamental change. Either we make Client itself "auto-reconnect" internally, or, we create a wrapper around Client (say, ReconnectingClient) that does so. I neither case, it requires some dev work (PRs are welcome :D)

I hope that answers your questions. Those were good questions that showcases some of the rough edges in asyncio-mqtt. Keep them coming. 👍

(1.) I get that, staying close to paho.mqtt makes the asyncio-mqtt much leaner. Personally, I don't think that's worth having to deal with AsyncExitStack for multiple filters. paho.mqtt does indeed reimplement the topic wildcards in paho/mqtt/matcher.py. The logic is pretty simple. If you're ok with it, I'll take a stab at this in a while, for something like:
async with Client("test.mosquitto.org") as client:
    async with client.messages() as messages:
        await client.subscribe("measurements/#")
        async for message in messages:
            if matches(payload.topic, "measurements/+/something"):
                print(message.payload)

(2.) That makes sense! I'm actually using asyncio-mqtt inside a web framework, that's why I am struggling. Using FastAPI's dependency injection to share context is pretty neat, for other frameworks it sadly doesn't work that easily.
I read in e.g. #117 that you're leaning against using connect/disconnect directly. I think it could be a nice solution for other web frameworks, usually, there's some sort of startup/shutdown procedure. It doesn't seem too unusual to have both either, see encode/databases.
Automating reconnection would be pretty cool, I already considered that as one of the next things to do 👍

I now also added an example of how to start a listener inside a web framework without blocking the rest of the code. I'm happy about all feedback! 😊

(1.) [...] The logic is pretty simple. If you're ok with it, I'll take a stab at this in a while, for something like:
async with Client("test.mosquitto.org") as client:
    async with client.messages() as messages:
        await client.subscribe("measurements/#")
        async for message in messages:
            if matches(payload.topic, "measurements/+/something"):
                print(message.payload)

That's much cleaner and more approachable than the current API. Well done. 👍 Feels more natural to split up the semantics (iterating messages and filtering messages) into separate operations. I also see how we can add this in a backwards-compatible way. I welcome a PR with that change. :)
You could also choose to do a Message.matches like so:
 if message.matches("measurements/+/something"):

Of course, that'll mean that we have to create a asyncio_mqtt.MqttMessage class that wraps mqtt.MQTTMessage. I just put the idea here as an alternative. You decide which one that you want to proceed with (matches, Message.matches, or something new). 👍

(2.) That makes sense! I'm actually using asyncio-mqtt inside a web framework, that's why I am struggling. Using FastAPI's dependency injection to share context is pretty neat, for other frameworks it sadly doesn't work that easily.

I have some recent (though not direct) experience with FastAPI and it looks like a great framework. Can't say for other frameworks but I fear for the current state of affairs.

I read in e.g. #117 that you're leaning against using connect/disconnect directly. I think it could be a nice solution for other web frameworks, usually, there's some sort of startup/shutdown procedure. It doesn't seem too unusual to have both either, see encode/databases.

I'm probably just being stubborn/pedantic about it. 😅
In a perfect world, every (web)framework uses context managers and doesn't even expose raw "on enter"/"on exit" callbacks. There are no footguns since you can only use the client this way.
Starlette (that FastAPI builds on) actually supports context managers (https://www.starlette.io/events/) but FastAPI doesn't expose that API yet (see https://github.com/tiangolo/fastapi/pull/2944)
In the current world, few-to-none (web)frameworks use context managers and instead expose raw "on enter"/"on exit" callbacks. So we have footguns since our APIs have to expose separate "on enter"/"on exit" functions and we can't restrict their use.
Example of misuse: Call disconnect in one task while another task still relies on the connection. Or, call connect repeatedly in a background task for a crude-but-well-intentioned workaround to auto-reconnect logic.
To support all possible combinations of connect/disconnect, we have to add extra runtime checks to all functions to avoid misuse. This is what we currently (try) to do and it's to blame for a lot of the internal complexity in asyncio_mqtt.
In any case, I like to think that I can be pragmatic so in the spirit of pragmatism, let's design an API for the current world (and not the perfect world). That puts the strain on us (the asyncio-mqtt developers) to ensure that we have the proper runtime checks for connect/disconnect.

Automating reconnection would be pretty cool, I already considered that as one of the next things to do 👍

Awesome! I look forward to the discussions/PRs. 😄

I'll try to get back on track with this PR now. 😅

I now also added an example of how to start a listener inside a web framework without blocking the rest of the code. I'm happy about all feedback! 😊

Looks really good! Well done. 👍
In practice, I know that starlette depends on anyio so if it was me, I'd probably use something like:
@contextlib.asynccontextmanager
async def lifespan(app):
    async with anyio.create_task_group() as tg:
        tg.start_soon(listen)  # This is your `listen` method from the "Side by side with async web frameworks" example
        yield

routes = [
    ...
]

app = Starlette(routes=routes, lifespan=lifespan)

To be clear: That's not a "request for change". It's just an alternative example. :) You decide. 👍

As for this PR as a whole it LGTM. It's a great improvement to our documentation and it'll be a welcome resource for new and existing users alike. :)
So if you're happy with it as well, I'll merge right away. Just give your final confirmation.

Wow, thank you for the thoughtful review, I learned a lot!

You could also choose to do a Message.matches [...]

This does look even cleaner, great idea.

Starlette (that FastAPI builds on) actually supports context managers

I didn't know that (or that it's possible like that). Consider my point moot then. I admit I was mostly pushing this for my use case with starlette. The FastAPI PR that you linked looks straightforward, so when that is merged we have an elegant solution for most popular async frameworks, contrary to what I originally thought.
I don't want to storm in and add lots of functionality that later only leads to headaches, either, you're right about wanting to keep it lean. Thanks for the "example of misuse" as well. I'm onboard now with the rejection of connect/disconnect 😄

Last changes:

I included the starlette example in the "Sharing a connection" section (using asyncio, I think it's nicer to use the stdlib in the examples, even though I'm going to use anyio for my use case now) and rewrote the "Listening without blocking" one to be without starlette
I added the discussion about exposing connect/disconnect, hopefully there are going to be less questions on it now, I saw in other issues that you had to defend this quite often already 😉

If you're ok will all that, I think it's ready to merge! 😊


NIFI-12282 Move Hadoop and other NARs to Optional Profiles

Summary
NIFI-12282 Moves Apache Hadoop extensions and several other components to optional build profiles.
Changes include the following:

Moved Hadoop and Parquet NARs to include-hadoop
Moved HBase NARs to include-hbase
Moved Kudu NAR to include-kudu
Moved Solr NAR to include-solr

Apache Hadoop support varies between different vendors, which already requires custom build profiles. Both Apache Kudu and Apache Parquet components depend on several Hadoop libraries. Apache HBase and Apache Solr components each exceed 50 MB for the size of bundled NARs.
Moving these selected extensions to optional build profiles reduces the convenience binary build to around 950 MB.
Tracking
Please complete the following tracking steps prior to pull request creation.
Issue Tracking

[X] Apache NiFi Jira issue created

Pull Request Tracking

[X] Pull Request title starts with Apache NiFi Jira issue number, such as NIFI-00000
[X] Pull Request commit message starts with Apache NiFi Jira issue number, as such NIFI-00000

Pull Request Formatting

[X] Pull Request based on current revision of the main branch
[X] Pull Request refers to a feature branch with one commit containing changes

Verification
Please indicate the verification steps performed prior to pull request creation.
Build

[X] Build completed using mvn clean install -P contrib-check

[X] JDK 21

Licensing

[ ] New dependencies are compatible with the Apache License 2.0 according to the License Policy
[ ] New dependencies are documented in applicable LICENSE and NOTICE files

Documentation

[ ] Documentation formatting appears as expected in rendered files

Thanks for flagging the spacing changes @pvillard31. There were a few tab characters in the nifi-assembly pom.xml, I pushed a commit to replace the rest of the tabs with spaces.


Add "Add -> New entity" to the context menu in the hirarchy

Task linked: CU-37qa3uh Add new entity with rightlick in hierarchy


Provides opportunity to use BootBot without creating a new express server.

I had a problem while using ChatBot on Heroku; I couldn't run my express server and chatbot server at the same time, in the same app. This modification allows to do it.

Missing unit tests


Installation Issues

Hello,
I am interested in using roast, but have struggled to get it installed. I have tried setting up and running roast (environment setup with conda), but ran into a number of problems:

roast-complie.sh has a space between - and lbamtools
bySoftclip has an error (looks like no return inside the blocks?) :

bySoftclip.cpp: In member function ‘std::string bySoftclip::overlapmerge_left(std::string, std::string, int, int, int)’:
bySoftclip.cpp:1137:1: warning: control reaches end of non-void function [-Wreturn-type]
 1137 | }
      | ^
bySoftclip.cpp: In member function ‘std::string bySoftclip::overlapmerge_right(std::string, std::string, int, int, int)’:
bySoftclip.cpp:1152:1: warning: control reaches end of non-void function [-Wreturn-type]
 1152 | }
      | ^

cd-hit appears not to be installed:

Couldn't run cd-hit-est successfully, please check input reference file and path folder of external tools
   --cdHitEST                    For any library version issue ignore removing redundancy using CD-HIT-EST by setting it to 0, default 1

BAM files could not be opened Could not open BAM file. Admittedly this last one may be fixed by correcting steps 1-3 instead of the workarounds I implemented.

Thanks,
Sam

Hi Sam,

Thanks for pointing that out, it’s fixed now.

These warnings do not affect the performance/output of the tool, but I will look into that and will update accordingly.

cd-hit appears not to be installed: executable cd-hit is present in the external tools directory, however sometimes due to permission issues on a new machine or incompatibility with a different Linux version/flavor it is required to be installed and placed in the external tool folder accordingly. The version issue is also mentioned in the error message generated.

That’s not an error or problem itself instead the outcome of any earlier failed step where the bam file couldn’t be generated at all/properly, which is mostly due to an installation error of the whole tool or in any external tool/library.

I hope that answer your queries, I am closing the issue now. Feel free to reopen if still there is any issue.
Best,
Madiha


support hub push pushing multi-nested .env.keys files for monorepos

effort happening here: https://github.com/dotenvx/dotenvx/pull/121

this is done and being released as v0.25.0
dotenvx hub push apps/backend
dotenvx hub push apps/frontend

it's also smart enough to handle if you have cd-ed into your directory
cd apps/backend
dotenvx hub push


Add cache header site assets

What is the purpose of this pull request?

Site

Description
Adds cache header to site assets so caching will be done on client site as well.
See example deploy: https://lucide-i3ntvvah0-lucide.vercel.app/
Before Submitting

[x] I've read the Contribution Guidelines.
[x] I've checked if there was an existing PR that solves the same issue.

Resolves https://github.com/lucide-icons/lucide/issues/1670


dataset

Prerequisite

[X] I have searched Issues and Discussions but cannot get the expected help.
[X] I have read the FAQ documentation but cannot get the expected help.
[X] The bug has not been fixed in the latest version (master) or latest version (3.x).

💬 Describe the reimplementation questions
It is feasible to extract key frames from 8-10 videos (each video lasts for two or three minutes, and the frame rate is 30), about 1500 pictures, as the target detection data set. Is it feasible, and will there be any over fitting phenomenon?
Environment
test
Expected results
No response
Additional information
No response

It is recommended to refer to other papers. And it needs to be discussed based on the continuity of the video scene. It is hard to say whether it is suitable


Process monitoring

Add tool (log/command) to monitoring process status.
Example (Cassandra YCSB - 4 nodes, 3 clients):

node-01 installing maven
node-02 installing open-jdk-7
node-03 installing maven
node-04 setup proxy
client-01 waiting for nodes
client-02 waiting for nodes
client-03 build VM

In this case we can saw where we have problem, client-03 doesn't spawn (maybe something goes wrong)

Just to clarify you are looking for a tool to analyze the existing logs and create reports on it?

tool to analyze logs or add to perfkit code notifies to file DB and next tool to show it

Proposition how output from that tool runned in some moment of test can look are both.

No.
VM name
IPs
VM state
System state
Benchmark state
Cleaning state

| perfkit_vm_0 | <IP_ADDRESS> | Running | Installed | Waiting | -
| perfkit_vm_1 | <IP_ADDRESS>| Running | Install YCSB | - | -
| perfkit_vm_2 | - | Error | - | - | -

Currently i'm working of PoC to add that tool based on in code events.
How to run:
pkb.py --monitor run_scenario1
or:
pkb.py --monitor run_scenario1 --watch - for continues monitoring changes

Looks cool...


Compile Caching

Added compile caching with sccache to github workflows to make them faster

[x] I have followed the instructions in the PR template

When using local cache for local builds this could improve build times massively otherwise here it seems like we unfortunately dont have any improvements -> will have a look at how to improve local compile caching!


Add model SYNGO:1805 missing due to merged term

Just adding a single model that was missing in the last SynGO model push. More details in the syngo-go-cams PR.
@kltm No rush on reloading this weekend. It can wait until next week!

Apologies, missed this one. Merging for next time.


[release notes] Links in 5.0 release notes point to code on master branch, which means they aren't stable

A lot (all?) of the links in the 5.0 release notes don't point to a stable version. For example,
"A complete set of functions has been added draw" -> 'draw' links to the master branch https://github.com/raysan5/raylib/blob/master/src/raylib.h#L1258 which no longer matches the intended location, which is https://github.com/raysan5/raylib/blob/5.0/src/raylib.h#L1258
Also at least one link doesn't work - rshapes.h 404s, should it be rshapes.c? https://github.com/raysan5/raylib/blob/5.0/src/rshapes.h

@aSemy Thanks for reporting! Fixed!


Add pictures in placeholders

Hey,
thanks for this gem. Is there a way to place some picture in the PDF with your fillpdf?
I've got some PDF where an area opens an "select image file" dialoge. but i don't figured it out how to do it correctly with your lib

@N0rimaki Could you send me a blank version of your pdf? Have not added this feature yet but sounds like it could be very useful.

very nice, thank you.
https://drive.google.com/file/d/1sKkZMUj3-sNhjLTWFUM4LBZDybRe-TUW/view?usp=sharing
let me know if it works.

hey t-houssion,
have a good new year and a lot of good commits 👍
just wanted to ask about a follow-up for this :)

@N0rimaki Thanks man! I was out a bit for the holidays but looking to get back to this this week. I'll keep you updated.

@N0rimaki Could you by chance also send a version of that pdf with an image in that field? Might help in comparing a blank and filled one.

here we go
https://drive.google.com/drive/folders/1mhSupKQ1WQUcx6sNqaMYqHULOevJsjlE?usp=sharing

@N0rimaki Hey man, just wanted to update you on this, still working on it. Been pulled away on other things for a bit but going to look back into this in the coming week.

i appreciate this feedback very much :) Thank you

hey mr.. any news? :)

Are you still trying to implement this?

Are you still trying to implement this?

yes :) sorry

i guess... i need an other solution..
thank you anyway  for your work :)


Feature Request: Add cmd to compile contracts

Feature Request

Summary

It would be great if embark was easier to work with only for smart contracts & not an entire dapp.
Adding a cmd like embark compile or embark contracts compile would be useful when developing & attempting to fix any compile time errors, or to run before I want to publish my contract repo to npm

We actually already have that, thought we do a bad job advertising it.
You can run embark build --contracts to only compile contracts.
Would there be something else that would make your life easier?

ah, I guess this is just a docs issue. Thanks!

@perissology we've been discussing this very area of the docs a lot recently. Do you have any thoughts on what could've helped making this more clear?

mentioning it to start ;) https://embark.status.im/docs/embark_commands.html#build
Maybe its new in 4.0 and the hosted docs haven't been updated yet?
I think a blurb in the contracts section would be another good place to mention it as well

Right now we only have an equivalent in terms of docs for the new command: https://embark.status.im/docs/create_project.html#Creating-“contracts-only”-apps
I guess the best way forward here would be to
a) update the command reference as you've suggested
b) introduce a new small guide on "Building your app" which would cover most of the important scenarios

FYI: we're introducing a command line proposal in case you do happen to run embark compile: https://github.com/embark-framework/embark/pull/1079

Juts an FYI, the --contracts option is there since 3.1 I think, but the only way to see it was to run embark build --help, which is bad

#1079 has landed but we should still leave this open until the documentation is updated.

Here's a PR that adds documentation about embark build https://github.com/embark-framework/embark-site/pull/110
Once this lands, this issue can be closed.

Closing this as the docs have landed too.


iOS5 crash fix

Fixing symbiote crashes from iOS5. Not well tested and only run on iOS5.
Frame highlighting is off; frames still aren't right.
There is some crashing when running in the simulator > 4.2 - this patch fixes it. Not tested on 4.2, please continue to use the old 0.7.7 code for 4.2 and less.

Pulled this in with a cherry-pick


Scrollbar not hiding

I have scrollbars set to hidden but it doesn't seem to be working. I'm using the mac app.'
The setting:

See, they're not hidden:

UPDATE:
I got them to hide with some WebKit CSS!
Now just wondering what the CSS is to move the tweet drawer a little lower cuz I don't like how high it is but its good enough for now.
The CSS used:

Here is the code:
::-webkit-scrollbar {     display: none; }
Result:

I'll actually integrate that change into ModernDeck so people don't have to do that, thanks for the bug report!

Nice!


Development plan and design decisions

Development plan
Phase 1
Put everything in one bigass crate and commit shitty code. The goal is to get the core functionality 100% working. Develop with a normal cosmic iced app (or just a truly normal iced app if it turns out cosmic apps require the DE to be running).
Phase 2
De-shittify the code, implement the fastest algorithms, cleanup, etc.
Phase 3
Split the core algorithms and data structures into their own crate. There will probably be three crates: core, applet, and app. We can probably call them Gerono because the clipboard is like an hourglass in the sense that all apps will (implicitly) write to it and then any app can get data out. The clipboard is a pinch point.
Phase 4
Final polish, figure out distribution, how to ship, etc.
Design decisions

Database compression

No. Use bcachefs and enable compression on the data folder.

Database encoding

Why are we special? As in why not use sqlite? Copying to clipboard has a distinct usage pattern wherein the data is almost exclusively append-only. This means we can provide significant performance and efficiency improvements by implementing our own database format.
Use SoftbearStudios/bitcode and implement streaming support: https://github.com/SoftbearStudios/bitcode/issues/6. Implement the same log structure used for GCH. Use encoding hints liberally. A consequence of using this lib is that any change to the data types (like adding an enum) is backwards incompatible, so we'll need a migration story. Make the first byte of each shard be a version number.

Shard the database across files, trying to match the number of files to the number of cores in the machine, with some minimum file size (maybe 8MB?) before starting to shard. This means we'll be able to load the database into memory at max speed. Also use a max shard size (maybe 128MB?) so any shard-wide ops aren't horrible to do (e.g. database migration only needs to occur on shards that are modified, so most of them can be untouched, but the ones we do touch probably shouldn't be humongous).

TODO think about how and when to shard. Ideally have an old and new folder, with an atomic rename to commit the changes. Use hard links to migrate shards that didn't change. Or maybe since most shards won't change, just have an old and new shard file and do the atomic rename for those files?

Only load into memory and display in the UI the clipboard entries for the latest shard. Realistically no one is going to be scrolling through thousands of clipboard entries. For search, stream through all the other shards. Search works like in https://github.com/SUPERCILEX/gnome-clipboard-history where you do both a plaintext match and a regex match (using BurntSushi's stuff of course).
Make IDs u32s and be local per shard (as long as the max shard size is less than 4GBs we can't run out of address space so no need to worry about overflow). This means if you delete something in another shard, we'll put the delete in that shard. Move or favoriting will require copying the data to the current shard (which is what you want anyway since the item is hot and should be loaded as part of the single-shard init).
TODO We need some way to know for compaction if a shard is dirty for compaction. Maybe a marker file? Maybe rename the shard file? Maybe a single database metadata file? How to ensure atomicity/consistency?
Can we mmap the shard? No because compaction might move bytes around and append support is iffy AFAIK. So loading a shard will consist of streaming through the file, parsing each entry into a Vec and allocating a string using some slab library (actually maybe that doesn't help? Need to check the implementation. Ideally the allocator backed with a stack).
For large strings, don't actually store them in the shard (how about if they're 65K bytes or longer so we can use a u16 string len) and instead use the non-plaintext mime type handling.
Support arbitrary mime types by saving their data somewhere outside the log.

TODO figure out a design for this. Use one file per entry because we want people to be able to see their copied images for example. Maybe use mime type as directory name?

TODO can we support multiple writers? That probably requires a client/server model which I really don't like. At the very least it'd be nice to be able to know we'll corrupt things if we write. Use a lock file?
In memory, since we're storing entries in a Vec we need some way to support moves and deletes. The most cache efficient way to do this will be to use tombstones. So just slap a tombstone in place of the entry and append to the front of the list. Then compaction will take care of making sure the vec doesn't grow too big.
Tooling: we should have a cli that can read shard files (input is a list).

Stats command which shows you stats on the items in the shard.
Export command that supports human output and json output.
Debug command that analyses byte offsets etc.
Migrate command that concerts from GCH to our format. Also support Clipboard Indicator and maybe if I'm feeling bold.
Generate command which creates pseudo random shards for perf testing.

A ratui client would be cool to have. Probs the easiest to start with for development.
TODO consistency model. Figure out when to fsync changes to disk. Pretty sure we want to let normal copies go through without a sync, but maybe compaction should sync? There should be an fsync on application close.
TODO Crash resilience. Think about how the format can break and how we can recover gracefully.

Stats from my clipboard:
Stats: Stats {
    raw: RawStats {
        num_entries: 5001,
        total_str_bytes: 3701123,
        ops: OpCountStats {
            num_save_texts: 5130,
            num_deletes: 129,
            num_favorites: 1,
            num_unfavorites: 0,
            num_moves: 25,
        },
    },
    computed: ComputedStats {
        mean_entry_length:<PHONE_NUMBER>348928,
        median_entry_length: 18,
        min_entry_length: 1,
        max_entry_length: 585304,
    },
}

import matplotlib.pyplot as plt
import numpy as np

def generate_histogram(file_path):
    # Read data from the file
    with open(file_path, 'r') as file:
        numbers = [float(line.strip()) for line in file]

    # Calculate the minimum and maximum powers of 2
    min_power = int(np.floor(np.log2(min(numbers))))
    max_power = int(np.ceil(np.log2(max(numbers))))

    # Create a histogram with bins as powers of 2
    bins = 2 ** np.arange(min_power, max_power + 1)
    hist = plt.hist(numbers, bins=bins, color='blue', edgecolor='black')

    # Add labels and title
    plt.xscale('log', base=2)
    plt.xlabel('Value (log base 2)')
    plt.ylabel('Frequency')
    plt.title('Histogram of entry lengths')

    # Modify x-axis labels to show bucket ranges
    bin_ranges = [f'2^{int(np.log2(bins[i]))}' for i in range(len(bins))]
    plt.xticks(bins, bin_ranges, rotation='vertical')

    # Add space at the bottom of the plot
    plt.subplots_adjust(bottom=0.15)

    # Display the histogram
    plt.savefig("stats.png", dpi=300)

file_path = 'tmp.txt'
generate_histogram(file_path)

Prior art:

https://github.com/hluk/CopyQ

Doesn't support copying images

https://github.com/Slackadays/Clipboard

Could be cool to support a terminal interface

https://github.com/xrelkd/clipcat

Seems both too simple from a user perspective and too complex from an implementation standpoint. Implements append correctly-ish https://github.com/xrelkd/clipcat/blob/314eeb023398693b9979250a8593b87375c6679e/crates/server/src/history/driver/fs/mod.rs#L222-L227 but I don't see a removal mechanism anywhere in that file and it seems like that data isn't even saved anywhere? https://github.com/xrelkd/clipcat/blob/314eeb023398693b9979250a8593b87375c6679e/crates/server/src/manager/mod.rs#L182-L199 Looks like there's just a final compaction on shutdown? https://github.com/xrelkd/clipcat/blob/314eeb023398693b9979250a8593b87375c6679e/crates/server/src/lib.rs#L528 Wat? That's crazy.

https://github.com/Keruspe/GPaste

The most serious competitor. Easily the de facto linux clipboard manager.
Seems like it uses XML? https://github.com/Keruspe/GPaste/blob/436c4b9a344cd506e2defb1c4682c6713c4c7492/src/daemon/tmp/gpaste-file-backend.c#L50 Ouch.

This is kind of exciting, I think there's an opportunity to provide a world-class clipboard manager that beats everything else out there in terms of performance and core functionality (as long as we support arbitrary mime types).
Long term, we could support running arbitrary commands on copy, multiple front-ends, and other fancy features.

Oooooh, I just had a very interesting idea: instead of combining metadata and data in the same file (which means mmap doesn't help because you still have to stream through the entire file), what if you split data and metadata into their own files? Then metadata contains fat pointers to the data file which can be mmaped. Similarly if we make metadata enums take precisely the same amount of space, then we can also mmap metadata and do simple offset calculations to transmute some bytes into an enum. This makes compaction much more efficient as we don't necessarily have to move any data around.
In essences, this means we're writing a memory allocator because the standard optimizations apply. Instead of compaction, you could keep a free list. Instead of everything in one file, you could keep fixed block sizes around. I think I like this because it should make sharding the log files much faster and basically unnecessary for at least the first few years of people using the clipboard as an 8MiB file can hold ~250K 32 byte entries which would take ~7 years to fill up assuming you copied 100 things a day.
We have two constraints:

Adding a new entry has to be instant.
Deleting an entry has to support compaction without ending the world. So for example storing all the data in a single file is a no-no because if you have a gig's worth of clipboard entries and delete something near the beginning, that means shifting nearly the entire gig up. In theory you could get fancy and hook into the file system extents to not move any data, but then that leaves an N block sized hole which is pretty useless for other files and adds a seek for hard drives. So basically the file system will eventually have to move that data around for you anyway.

This leads to the following solution based on my clipboard data:

Use bucket allocation files for entries with powers of 2 sizes from 2^2-2^12.
Allocate a new file for anything larger than a logical disk sector size (4096).

mmap + append sounds like a big PITA sadly. Might be doable with mmaping more than is in the file or using ftruncate/fallocate. Though maybe we could just avoid ever remapping?
Also probs would need a separate metadata file for favorites if we're not going to read the entire log (which should probably be the goal as this gives us O(1) startup). Though maybe that's not worth it and we should just allocate a huge vec on startup? I don't like the fact that it forces us to hold that stuff in memory rather than letting the OS decide when to load disk pages in.
The deal with deletions is that they're implicitly continuous. If you've reached the maximum number of items/clipboard size, then every entry addition deletes an entry. Since it'll delete the oldest one, that's kind of our worst case scenario for the log because we have to shift everything back. So maybe we should actually bounce back and forth between two logs? Yeah actually I think this is the right solution. If a user says "I want my max_num items to be 1M", then lim_(t -> infinity) num_items = 1_000_000. Wait a sec, why not a ring buffer? The reason I couldn't do that before is because data was stored with metadata, but if every entry is the same size, then I can make the log a ring buffer!!! Fuckin genius.
Ok, so the idea would be that you write to a log file until you hit the max num elems and then just wrap and smash whatever's in the back. We'll need a header which notes the write head? I don't think we ever actually advance the back pointer explicitly?
Ops:

Add: easy, just a bump allocator with smash on OOM.
Move

Can support move to end by pretending like it's an add + tombstone the old.
Can support left/right swaps by literally swapping adjacent entries
Obviates the need for a MOVE op and enables only reading the end of the log.

Favorite: needs to be in a separate file to be excluded from the smash on OOM behavior of the ring allocator.

Random thoughts on the client/server stuff: it would be really cool to have this be the defacto clipboard manager for linux as this design is shaping up to be world class. I think we can have the server create a delete-on-close named pipe for reading commands. Clients open their own named pipes (as it looks like there's no good way to send file descriptors around, see https://man7.org/linux/man-pages/man2/pidfd_getfd.2.html) and send the server a message with the location of the file descriptor. It's then the server's job to broadcast messages like "new clipboard item" and reply to specific pipes for individual requests like "give me this item". The problem of course with client-server architectures is that it's super inefficient for clients to read data.  So maybe the server is a main loop with a switch between different GUIs and when you shut down a GUI it just waits to be told to open the next one? Doesn't really work for terminals where you need the server to run outside the terminal process. So maybe you keep the named pipes idea and just have clients do an initial read-only load of the data from the log file and then everything else it gets is replies from the server that say the data is located here, go look it up yourself which would mean mmapping all the data files. And I guess the server needs to notify clients when it should remap files because they grew. Could work and be reasonable efficient. Also for the applet is might actually make sense to not bother receiving data from the server and just do a load from the log each time it is opened. The theory there being that you can't copy stuff while the applet is open (so we don't need to subscribe to changes) and while the applet is closed we don't want it wasting cycles doing GUI stuff anyway. Any user action could be reflected in the UI as a lie that's immediately processed but asynchronously handled by the server. Honestly this seems like a reasonable strategy for all the GUIs? Like do we really care if you're watching the GUI as you copy stuff? Actually yeah maybe we do. So it could be a hybrid thing where you close your pipe when the user isn't looking and then open it to subscribe to events while the UI is open.

Actually unix domain sockets are precisely designed for the client/server stuff I want to do and have the same performance according to some random benchmark, so just use that instead of my half-assed multiple pipe nonsense: https://man7.org/linux/man-pages/man7/unix.7.html.

Ok so there's also sysv: https://man7.org/linux/man-pages/man7/sysvipc.7.html. Basically it sounds like I can do anything I want: move FDs around processes, shared memory between them, and synchronize their actions. Should free up the design space considerably.

More fully flushed out design
Server
The server is a (mostly) single-threaded application as everything we are doing is designed to minimize latency and maximize efficiency rather than worry about throughput. The server is implemented as a connection oriented (SOCK_SEQPACKET) unix domain socket with a core loop that simple processes requests from clients and issues syscalls using io_uring. We will tell people that old kernel and non-linux kernels are not officially supported, though PRs to do blocking I/O may be considered for acceptance.
The server's goal is to be the one and only place where data is written. On startup, the first thing it will do is open the log file and acquire an exclusive lock (https://man7.org/linux/man-pages/man2/flock.2.html). Clients only ever open files in read-only mode, so they don't care about the lock. It's only used to prevent concurrent server instances.
The server will be backend agnostic (so wayland and x11) gated by feature flags. When a feature isn't enabled, the implementation returns an error upon creation which a unifying impl uses for broadcast/merging purposes. Looks like this:
struct AllBackends {
  a: Option<BackendA>,
  b: Option<BackendB>,
}

impl Backend for AllBackends {
  // Impl with Option::map and error tuples? Or maybe handle errors internally? Maybe closures?
}

// New idea: make every client a backend since it can also send add events and request content
// Maybe use https://docs.rs/arrayvec/latest/arrayvec/struct.ArrayVec.html as message buffer

Each backend will need to return a file descriptor for io_uring to wait on. For wayland, this should be pretty easy. Haven't looked into X11 but worst case scenario a backend can start a thread and do a blocking loop which writes to an in-memory pipe that is read by io_uring. Not very efficient, but it'll cleanly handle back pressure and message passing.
All files that need to be read will be mmaped into the client and server as read-only. Writes will happen through normal write syscalls which is supposed to be coherent (and note that multiple processes mmapping the same file is also coherent as the pages are simply shared across processes). We cannot write directly to mmapped regions because there is no guarantee on when the data will be written back to disk which means we would need our own https://man7.org/linux/man-pages/man2/msync.2.html flushing policy and that sounds unpleasant. Also I doubt performance will be good assuming writes trigger page faults. With normal write syscalls, all you should get is cache flushes for the affected addresses which in practice means no overhead at all since adding a clipboard entry shouldn't involve reading and most of the time clients won't be active so no data will be in the cpu caches. Or maybe that assumption is wrong and I'd need to run perf tracking tlb flushes, but the other issues with not using mmap for reading is that then everything needs to be loaded into individual malloced buffers and that's definitely terrible for performance.
Process for adding a new clipboard entry:

io_uring notifies us that an fd did something.
Notify the corresponding backend.
The backend parses the message, sees that it's an Add type and returns the Add command.
All data communication happens over file descriptors, so the client or wayland or x11 will need to have given us a file descriptor from which to read the data.
The ring's write head is checked and used to find the next ring buffer entry to write into.

If the entry is empty, simply allocate the clipboard data and write a new entry into the ring buffer. Use pwritev to simultaneously update the entry and write head.Add {
  file_size: u16, // Anything greater than our bucket files doesn't matter, so technically we only need 12 bits
}

If size is part of a bucket allocation, then the data is plain text. Otherwise, size is just a flag. The id for the item is implicit and permanently baked into its position in the ring buffer. The entry's position is immutable for the entirety of its lifetime, including garbage collection. The tradeoff here is that we won't precisely respect the user's max items, as in if they deleted something in the middle of the ring buffer we won't skip over intermediate allocated objects to fill that hole, we'll just keep marching onwards. Also this means the maximum number of items is implicit in the size of the ring buffer.

How data allocation works:

A maximum of i32::MAX entries are allowed.
Create bucket files for powers of 2 in [2, 12).
If data is larger than or equal to 4096, allocate it by ID (the ring buffer position)

Directory structure:

$DATA_DIR/clipboard-history/

normal/: folder for all normal database and data files
favorites/: folder for all favorited entries

$CACHE_DIR/clipboard-history/

server.log: file for server log messages. Opened with truncate on

Resources for integrating with the clipboard

https://github.com/JoeyEamigh/wayclip/blob/main/src/wayland/mod.rs
https://emersion.fr/blog/2020/wayland-clipboard-drag-and-drop/
https://github.com/quininer/x11-clipboard/blob/master/src/run.rs
https://github.com/Smithay/wayland-rs/issues/690

Call the project Ringboard.

An entry ID is the concatenation of a tag ID and a ring ID, each 32 bits. So the full entry ID is 64 bits. This enables the architecture to seamlessly transition to tagged entries if I ever decides there's any point to doing that.

Next steps:

implement version handshake between server and client
add logging and tracing crates
implement allocator and make add command fully work
...

Next steps:

Implement all CLI commands (leave server implementation blank for the hard stuff like garbage collection).
Add X11 and Wayland clipboard watchers.
Finish blog post and post it in draft state.
Start posting about the project and asking for help implementing GUIs.

Dumb idea, but what if the X11/Wayland watchers are just clients? So they run in their own binaries which means I don't have to care about bloat, feature flags, performance stuff etc.

Note in blog post that metadata files are fine because they're so tiny: https://www.kernel.org/doc/html/latest/filesystems/ext4/overview.html#inline-data

Thoughts on error handling: to keep things simple, we assume that requests are only made by trusted code, so we don't bother validating the contents of requests. This also means we don't have to make the server resilient to bad clients and it can just shut down when something goes wrong. Basically we're cool with clients performing denial of server. However, assuming the code is trusted, we do perform error handling for dynamic values (for example to check that the ID a user asks us to move is valid).

Thoughts on reading data and search:

Add a RingReader interface that allows creating an iterator from any entry and can move back and forth. Look into all the things you're supposed to implement for iterators (size hint, fuse, double ended, etc). Iterates over raw entries, avoiding uninitialized entries is a higher level problem.
Add an EntryReader enum. The core interface is to_file which produces a File. For non-bucket entries this is close to free, but for Bucket entries we'll need to create a tmpfile and copy_file_range the bytes into there. Offer a method on the bucket variant that returns a byte slice.
Need to figure out how bucket resizing works. Somehow need to provide multiple shared references but take some type by value to force dropping the references at which point we can remap the file.  This is lame because we have to create a new mapping every time which is evil for the TLB etc. These ideas aren't mutually exclusive? I could have the painful references API and somebody else could just wrap it in an Rc I think.
Garbage collection should take an excess bytes percentage that only triggers garbage collection if that amount of space has been wasted. So 0 always triggers and 100 triggers if we're using 2x the storage.  Maybe 50%? Also how about having the param actually mean "collect garbage until wasted space is under the threshold." Then garbage collection can start with the biggest buckets and do minimal work to reclaim the big ticket items.
Search should have a whitelist of searchable mime types so we can search html text for example.

Oooooh, I'm a dumdum—instead of having to create a metadata file, I can just use extended file attributes! There's even user.mime_type already defined for this purpose: https://wiki.archlinux.org/title/Extended_attributes. Those metadata files were really getting under my skin, so this is sweet. Extended attributes are even stored inline if they're small: https://www.kernel.org/doc/html/latest/filesystems/ext4/dynamic.html#extended-attributes

Next steps:

[ ] Finish fuzzing
[ ] Add X11 clipboard listener client
[ ] Migrate my GCH clipboard and make the server + X11 client start on boot

https://www.freedesktop.org/software/systemd/man/latest/systemd.service.html
https://docs.rs/sd-notify/latest/sd_notify/fn.notify.html
Looks like I want a Type=notify service for the server. I can link in sd-notify behind a systemd feature (disabled by default, but used in docs for systemd setup). The client can just be Type=exec.
Restart=on-failure for both
https://www.freedesktop.org/software/systemd/man/latest/systemd.unit.html#
In the client, add Requires=server and After=server and ConditionEnvironment=XDG_SESSION_TYPE=x11. Also for both add Description=... and Documentation=a link to systemd install instructions.
The server should start with After=multi-user.target while the client should be After=graphical.target I think.

https://wiki.archlinux.org/title/Systemd#Targets

Check that the service starts and stops correctly, that the server runs at the login screen and that the client runs once I'm logged in.

[ ] Finish the blog post, cutting sections on the stuff that hasn't been implemented yet (garbage collection, configuration, etc). Make a note that those will come in a part 2 once they've been fully implemented/designed.
[ ] Write READMEs and basic docs.
Start working on egui client. The MVP is a full list of entries (https://docs.rs/egui/latest/egui/containers/scroll_area/struct.ScrollArea.html#method.show_rows), then paste to clipboard, then search, then non-text entries, then the ability to modify entries, and finally whatever polish is needed.
See if I can get anyone interested in writing a cosmic applet and/or TUI. I think I've decided that I'm not interested in writing the other clients since I personally only need a good egui one. It'd be cool if the project takes off and other people add what they need. Otherwise, I'll have the dream clipboard for myself which is good enough.
Once the egui client is in good shape, write about search in the blog post and make announcements, publish, yadada. At this point it's completely usable, just not fully optimal and might have missing bonus features.
After all of that, work on finishing the remaining todos (like gc, config, etc), write a blog post about those, and then call the project done.

Solution to the duplicates problem:

In DE clients, spend memory (uncapped because even if you managed to copy a million entries that's still only a few dozen MBs) to remember previously copied item hashes from this session (so no loading stuff from disk on startup, the premise being that you copy the same thing multiple times because you're working on it). Algorithm: after adding entry, load stored entry from server response ID to file and stream through DefaultHasher if 4096 bytes or less, otherwise just use length. Store these hashes in a BTreeMap (for better memory efficiency) and when x11 gives us something that was copied, apply the same hashing algorithm and send a move-to-front command to the server if an entry is found in our list.
In garbage collection, include a deduplication pass.
Rewrite stats command to use hashing instead of loading all entries into memory.

https://www.uninformativ.de/blog/postings/2017-04-02/0/POSTING-en.html and https://github.com/linebender/druid/blob/master/druid-shell/src/backend/x11/clipboard.rs as resources for the X11 clipboard. I think we can basically use the blog post a good reference.

For non-plain-text entries, we should add some notion of context that can be stored in extended file attributes for the UI to show. For example, if you copy a google slide, there's nothing we can show (without trying to parse Chrome's custom data format, no thanks) that will be useful. But we could ask for the X11 window title at the time of copy and save that to show in the GUI. Better than nothing.

Add mut methods for EntryReader that remap as necessary. After deduplication, rewrite stats to use new technique. After X11, fuzz and then publish.

Still not sure what to do about paste. There are three options:

Play the same game as copying and write a server that accepts a paste command. Seems like a few too many servers to me.
Write a oneshot call binary whose sole purpose in life is to paste a single ringboard entry. Seems pretty inefficient.
Write a library linked into anything that needs the ability to paste which can be compiled with an x11 and/or wayland backend. Maybe the best idea?

For deduplication it turns out you there's no point in trying to be fancy because you'd need to store the contents to avoid hash collisions, so I gave and just implemented a crappy static hash table.

For change broadcasting, it occurred to me that inotify/fanotify might be useful but I can't seem to find a way to subscribe to a file range. Otherwise we could have actually used that to subscribe to entry changes plus the write head.

UI ideas:

Add a shift+? for keyboard shortcuts
Get rid of the hover stuff and put it in a right click menu

Include actions: favorite, delete
Include info: id, mime type, content
Esc backs out

Start with first row of favorites selected

Enter pastes to clipboard
Space is equivalent to right click
Tab cycles between selecting main and favorites (remember row index of each selection)

Up/down arrows move between rows
Ctrl + N selects row num (show number overlay when holding Ctrl)

For search, it might be worth supporting incremental plain text search. That is, for every query the user types that is a superset of the previous query, we can search through only the existing results rather than having to perform a full database search again. Furthermore, we can start searching each of these results at the saved start location of the query result (minus however many prefix characters were added in the superset query). This would basically make subsequent searches instant as it's just confirming whether or not the newly expanded query still matches rather than finding the query location all over again.

Closing in favor of new issues.

For pasting I decided the library is the right approach because it allows building a daemon (that uses the library) if it turns out that's what we want.

I looked into adding migrations from https://github.com/hluk/CopyQ and https://github.com/Slackadays/Clipboard. CopyQ uses a binary format and I don't want to have to compile C++ to be able to build our CLI so that's not doable. Slackadays's clipboard defaults to being transients and only supports files or single entries from the command line, so I'm guessing most people don't actually store long-term history in there.

Ok I changed my mind about pasting. The problem with in-process pasting is that if the UI wants to exit immediately after pasting you're screwed because you need to wait for someone to bite (the compositor should immediately, but who knows) and then you can't offer good pasting services like target selection. One option is to fork on paste but if you're spawning a process on paste anyway, might was well run a paste server. Then it occurred to me that the watcher servers already have connections to x11/wayland so why not re-use those? They'll just spin up a socket that accepts files to offer as paste.


Added GopherCon AU details - no website yet.

@sjwaight are you one of the organizers?

Thanks @sjwaight !


Audio not working on certain devices

I get errors when launching the app and trying to play audio on my Huawei Y6 II (android 6) , the audio won't start and I get these errors:
`
Launching lib\main.dart on CAM L21 in debug mode...
lib\main.dart:1
Parameter format not correct -
√  Built build\app\outputs\flutter-apk\app-debug.apk.
Connecting to VM Service at ws://<IP_ADDRESS>:53182/gDtxebCclSk=/ws
I/BD.Reporter(21143): com.huawei.bd.IBDService$Stub$Proxy@5a36bc8
26
I/System  (21143): core_booster, getBoosterConfig = false
E/MediaPlayer(21143): error (1, -2147483648)
E/MediaPlayer(21143): Error (1,-2147483648)
I/MediaPlayer(21143): [HSM] stayAwake false uid: 10108, pid: 21143
E/MediaPlayer(21143): pause called in state 0
E/MediaPlayer(21143): error (-38, 0)
E/MediaPlayer(21143): Attempt to perform seekTo in wrong state: mPlayer=0x558be7c400, mCurrentState=0
E/MediaPlayer(21143): error (-38, 0)
I/MediaPlayer(21143): [HSM] stayAwake false uid: 10108, pid: 21143
E/MediaPlayer(21143): Error (-38,0)
I/MediaPlayer(21143): [HSM] stayAwake false uid: 10108, pid: 21143
E/MediaPlayer(21143): Error (-38,0)
I/MediaPlayer(21143): [HSM] stayAwake false uid: 10108, pid: 21143
`
However on my Pixel 3a XL API 29 emulator, everything works completely fine, I don't think the problem is in my code, however let me know if you want any additional info

Have you tried the example app? What audio exactly are you trying to play?? Please follow the issue template and properly format code and logs so this issue can be addressed.

The example app works fine, even though I'm still getting the same logs
`
I/BD.Reporter( 1395): com.huawei.bd.IBDService$Stub$Proxy@9d41e14
I/MediaPlayer( 1395): setDataSource(59, 0,<PHONE_NUMBER>03423487)
I/MediaPlayer( 1395): setDataSource(https://luan.xyz/files/audio/ambient_c_motion.mp3)
W/MediaPlayer( 1395): info/warning (1001, 0)
2
I/System  ( 1395): core_booster, getBoosterConfig = false
I/MediaPlayer( 1395): [HSM] stayAwake true uid: 10109, pid: 1395
I/MediaPlayer( 1395): Pid:1395 MediaPlayer::start
I/MediaPlayer( 1395): [HSM] stayAwake false uid: 10109, pid: 1395
But on the emulator its different
Launching lib\main.dart on Android SDK built for x86 in debug mode...
lib\main.dart:1
√  Built build\app\outputs\flutter-apk\app-debug.apk.
Connecting to VM Service at ws://<IP_ADDRESS>:54645/JseIti_OCc8=/ws
D/EGL_emulation(22615): eglMakeCurrent: 0xde3c92a0: ver 2 0 (tinfo 0xd620f7a0)
W/players.exampl(22615): Accessing hidden method Lsun/misc/Unsafe;->getUnsafe()Lsun/misc/Unsafe; (greylist,core-platform-api, linking, allowed)
W/players.exampl(22615): Accessing hidden method Lsun/misc/Unsafe;->objectFieldOffset(Ljava/lang/reflect/Field;)J (greylist,core-platform-api, linking, allowed)
W/players.exampl(22615): Accessing hidden method Lsun/misc/Unsafe;->compareAndSwapObject(Ljava/lang/Object;JLjava/lang/Object;Ljava/lang/Object;)Z (greylist, linking, allowed)
W/players.exampl(22615): Accessing hidden method Lsun/misc/Unsafe;->putObject(Ljava/lang/Object;JLjava/lang/Object;)V (greylist, linking, allowed)
V/MediaHTTPService(22615): MediaHTTPService(android.media.MediaHTTPService@195d337): Cookies: null
V/MediaHTTPService(22615): makeHTTPConnection: CookieManager created: java.net.CookieManager@6afe0a4
V/MediaHTTPService(22615): makeHTTPConnection(android.media.MediaHTTPService@195d337): cookieHandler: java.net.CookieManager@6afe0a4 Cookies: null
`
The audio I'm trying to play are just http mp3 links, which used to work and still do work fine on the emulator but not anymore on my Huawei Y6 II , which is not the case for the example app

This problem definitely isn't from my end, since I just tried previous versions of my app I got from my repo history and its not working, meanwhile it used to work before, exactly 11 days ago according to GitHub

You mentioned that this mp3 is a hosted file. Isn't there a chance that the file changed somehow?
It is not that uncommon for the same file to play ok on some devices and fail on different ones. Different devices have different codecs bundled with them, which affects the player.

Looking at the api`s repo there has been changes 6 days ago, I'll look into that and let you know, however failing on some devices and not on others because of the audio file is highly unlikely, and if so there would have been more specific errors I guess

I do agree with you that there should be more specific errors, but unfortunately this is something that breaks on the Android native MediaPlayer, and from our experience that part of the android API don't give us much to work on, so there isn't much that we can do from the plugin side.

Yes, the API developers have made some changes to the CDN references, thus affecting the audio files I think... They have made changes in the links so I'm closing this issue assuming its the API's fault, however I still have no idea what this means:
I/System (21143): core_booster, getBoosterConfig = false E/MediaPlayer(21143): error (1, -2147483648) E/MediaPlayer(21143): Error (1,-2147483648) I/MediaPlayer(21143): [HSM] stayAwake false uid: 10108, pid: 21143 E/MediaPlayer(21143): pause called in state 0 E/MediaPlayer(21143): error (-38, 0) E/MediaPlayer(21143): Attempt to perform seekTo in wrong state: mPlayer=0x558be7c400, mCurrentState=0 E/MediaPlayer(21143): error (-38, 0) I/MediaPlayer(21143): [HSM] stayAwake false uid: 10108, pid: 21143 E/MediaPlayer(21143): Error (-38,0) I/MediaPlayer(21143): [HSM] stayAwake false uid: 10108, pid: 21143 E/MediaPlayer(21143): Error (-38,0) I/MediaPlayer(21143): [HSM] stayAwake false uid: 10108, pid: 21143
Which are warnings I only get just recently when debugging on the Huawei Y6 II