refactor: consistency

Hi @reggi
I like that you collected these fortune messages and shared them! I always find them fun or funny when I get one.
I noticed a typo while reading them and started to create a PR for a single line fix, but then I kept reading and noticed some more, and saw an opportunity to improve the overall consistency of the collection with a simple build step to generate the other file formats from the text file.
The corrections I made are all overtly obvious grammatical/syntactical ones. I didn't worry about stylistic things or misplaced commas, etc. I know that part of the allure of fortune cookie messages can be the occasional bad translation or strange phrasing, and I generally avoided engaging those cases as well. In case it's not clear what I meant by the previous sentence, here's an example from your collection with a link to someone's take/explanation:

May the warm winds of heaven blow softly upon your sprint.

https://followingfunny.com/2011/10/10/fortune/
In addition to generating other file formats, the build script ensures additional consistency in things like file names, whitespace, a simple deduplication algorithm (which removed several duplicates), etc. You can read the comments in the script to get precise clarity.
Re: ESM: Here's a link to the current LTS version of the Node documentation that addresses JSON import assertions: https://nodejs.org/docs/latest-v16.x/api/esm.html#json-modules
Final notes:
Implementing consistent file naming is a breaking change (as is switching to ESM), and I didn't increment the package version in this PR. I just wanted to mention that in case you decide to accept it.
I also wrote this simple, self-contained React app to review the quotes as I was working on the PR — it works without any build step, using just a local static file http server (I used this one):

viewer.html
<!doctype html>

  <meta charset="utf-8" />
  <meta name="description" content="fortune cookie messages" />
  <meta name="viewport" content="width=device-width, initial-scale=1" />

  <title>fortune cookie messages</title>

  <link rel="preconnect" href="https://fonts.googleapis.com">
  <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
  <link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;600&display=swap" rel="stylesheet">

I hope you find this PR useful. Thanks again for sharing your collection.

Hah! @jsejcksn thanks so much for this, and thanks for your help over on stack-overflow!
Thoughts:

I found the archive of physical fortune cookies which this is based on, I still have it ❤🥠
One issue is I added more to the pile, so I'd like to update the list and I have to go through them.
I remember adding duplicates because I have duplicates! I thought it was interesting to include that data somehow.
I'd like to re-enter and check the spelling of the ones you changed, If indeed they are spelled wrong on the fortune then we may want to keep them wrong in here.
I have a new list I just hand-entered going through them in a google doc
I see some of the ones you added are in this list! Coincidentally I have some of those fortunes!
I'd be interested in a deno cut but as a static array in a ts file, i'd consider the same for node with a js file as well.
You can add your site as a gh-pages to this repo if you want, then the link to the repo could go to it?

I am struggling with the integrity of the pages. As in adding new ones that I don't physically have in my possession. I feel like the fort knox of fortune cookies, as in every one in the repo is backed by a piece of paper. Gold as to fortune paper, as  fortune is to cash? Or when the dollar was backed by gold. Anyway. I'd be down to add a CSV for third-party contributions but with some real-world backing, perhaps a photo on twitter or instagram with a real non-bot user? Or mail me your fortunes (lol)! What I'm afraid of is people making PR's of nonsense fortunes they've heard about online cluttering this repo up.
Here's an example of one I found that is authored that way:

@reggi Thanks for sharing those thoughts and explaining more.

I found the archive of physical fortune cookies which this is based on, I still have it ❤🥠

Reading this was simultaneously somewhat expected, yet still a surprise to me.

I see some of the ones you added are in this list! Coincidentally I have some of those fortunes!

I actually didn't contribute any: During the cleanup, I noticed that the JSON file had some additional fortunes appended to the end of the list that weren't in the text file, and I simply copied them to the text file.

You can add your site as a gh-pages to this repo if you want, then the link to the repo could go to it?

Thanks for your welcoming suggestion. I think that can be addressed in a separate PR if you want to include it — especially if it involves another branch. I shared it here simply to give you insight into my process (and to share an artifact of that in case you found it useful).
Re: the Google spreadsheet link:
I couldn't access it when I tried. Perhaps you can double-check that its access level is set to public if you intended for me and other viewers of this PR to be able to view it.
Re: no. 2 through no. 5 and the rest of your message:
When I found the repo, the personal nature of the collection wasn't clear to me — I didn't realize that it was intended as a digital copy of the verbatim strings of the messages from your personal preservation, and that you "[felt] like the fort knox of fortune cookies, as in every one in the repo is backed by a piece of paper." I also didn't assume that you mis-typed anything when transcribing. And with those in mind, I hope it makes sense to hear that I wouldn't have even begun the PR had I understood this aspect. Since this is very personal to you, I completely understand wanting to maintain the accuracy of the details in that way. I think somehow including digital evidence (like those photos) in a directory of the repo will help communicate the nature of what you described.
So — that said — are there parts of the PR that you want? My effort in this was to help make it more usable by others and easier for you to maintain: just keep updating the text file and generate the other artifacts.
Toward the former concern: if you want to keep duplicates, perhaps that part of the build step can be omitted and documented as an exported function that can be used by consumers who don't want the duplicates.
Do you want to just update the text file and regenerate the other file formats, keeping the build script, ESM, etc.? How would you like for this PR to proceed?

Ah! Ok good learnings here.
Can you split this PR into two one with just the build.mjs file and another with the fortune-cookies.txt?
I am worried about dropping cjs support for older versions of node, any ideas on how to support both?  I'm also curious if the package main file could just be the json file could be support for both CJS and MJS like that?
I agree with removing dupes for release I can add a build step for that.

I'll try setting up a github action to build the files and publish, so no need to include the built files here.

@reggi

Can you split this PR into two one with just the build.mjs file and another with the fortune-cookies.txt?

Of course! But before I do that, I'd like to respond to some of what you said:

I am worried about dropping cjs support for older versions of node, any ideas on how to support both?

Are you trying to support unsupported versions of Node? All versions of Node that aren't already past end-of-life have support for ESM. CommonJS was very useful when there was no standardized module system in JavaScript, but now it's a relic. If you are committed to supporting those ancient versions of Node (and a non-standard module system), there's the package entry points feature.

I'm also curious if the package main file could just be the json file could be support for both CJS and MJS like that?

Importing of JSON modules in ESM requires the use of an import assertion which is a stage 3 proposal, (it's considered experimental until finalized because there's a [microscopically small] possibility that the syntax/behavior could still change before then), so I don't recommend providing a JSON file as the entrypoint for ESM consumers right now. Beyond any potential stability concerns, it would require consumers to know that your entrypoint is JSON ahead of time and to actually use the import assertion syntax when importing your (JSON) package:
import fortunes from 'fortune-cookie' assert {type: 'json'};

IMO, this is suboptimal DX for the consumer because of the increased cognitive load, and I recommend providing a JS module entrypoint that handles this for them "behind the scenes" — see my comments in index.mjs.

I'll try setting up a github action to build the files and publish, so no need to include the built files here.

I'm not sure if you meant that you are thinking about removing the generated files from the repo. If so, here's a (perhaps unconventional) opinion for perspective:
I think there's great value in keeping those build artifacts in the repo (in a directory or even if in a different branch from the source): not everyone has the same experience level in tooling (so not everyone can build — and, even if they could, it's such a chore when you just need a single file), so having equal access to static artifacts in the same way as static source is a win for accessibility.
It's very annoying to me when I need access to some built artifact in an npm package (e.g. a generated wasm module in a non-Node environment like Deno, etc.) and I can't get it from GitHub because it doesn't exist in the repo (or it's only included as one asset in a binary tarball/zip archive in a release), so I have to either download/extract/cleanup (which is even more cumbersome if it's needed as a resource provided by an automated network request) or go find it at some third-party CDN (e.g. unpkg), relying on its availability. (end of rant)
So...

Are you positive that you need to support CJS?
How do you plan to handle build? (so I know how to restructure this PR and create the next one)

@reggi While awaiting your reply, I went ahead and rebased this PR: now it only addresses the build step and generation of artifacts (the other file formats besides the source text file — ES module, JSON, Markdown).
I also added JSDoc type annotations in the build script during the refactor, and now it only deduplicates the fortunes for the generated artifacts and not the text source (per our discussion above).
Hopefully that helps reduce complexity here by separating concerns — and if you decide to consider the other changes, those can be handled in separate PRs.


Improvements to Shared Heartbeat Driver

Summary
This pull will allow us to see which board's heartbeat fails, when a dependent board faults due to a missing heartbeat. WIP
Changelist

Heartbeat status is now stores the status of individual boards in the low 5 bits of a 32 bit int, with each bit representing the individual status of a detected board.

0: Fault
1: Not Checked or Happy

Added App_SharedHeartbeatMonitor_BroadcastState to driver

Gets a struct of heartbeat CAN callbacks to expose can to the shared directory, and a state to broadcast, broadcasts state through CAN as appropriate.

Testing Done

[x] Passing CI tests
[ ] Flashed on car

Resolved Issues
None.
Checklist
Please change [ ] to [x] when you are ready.

[x] I have read and followed the code conventions detailed in README.md (This will save time for both you and the reviewer!).
[x] If this pull request is longer then 500 lines, I have provided explicit justification in the summary above explaining why I cannot break this up into multiple pull requests (Small PR's are faster and less painful for everyone involved!).

Status: working on debugging FSM failing tests...
Locally:
[  FAILED  ] 5 tests, listed below:
[  FAILED  ] FsmFaultTest.check_state_transition_fault_state_heartbeat_timeout
[  FAILED  ] FsmFaultTest.papps_ocsc_sets_mapped_pedal_percentage_to_zero_and_sets_fault
[  FAILED  ] FsmFaultTest.sapps_ocsc_sets_mapped_pedal_percentage_to_zero_and_sets_fault
[  FAILED  ] FsmFaultTest.apps_disagreement_sets_mapped_pedal_percentage_to_zero_and_sets_fault
[  FAILED  ] FsmFaultTest.brake_actuated_sets_mapped_pedal_percentage_to_zero_and_sets_fault_if_papps_pressed

Current status:

FSM tests fail... no idea why.
CubeMX Code Gen for PDM failing... also no idea why.

Status: FSM tests still failing

FSM is broadcasting a heartbeat fault when there should be none

Status:
Found error. Heartbeat status is larger than 5 bits, so when we check for equality with 0x1F (good status), the check fails (0x1F assumes a 5 bit status size).

Status:

All CI tests pass.
More extensive car testing to be done when battery is back in car.

TODO

More extensive car testing [ ]
Remove HeartbeatStatus CAN message, replace with CAN fault for every board [ ]

Status
Feature should work, tests need to be fixed to use new CAN alerts.
TODO

[ ] Update tests to use new CAN alerts/warnings.
[ ] Move configs for can funcs to main with extern
[ ] Test on car

Status

All CI tests passing.
Car testing is next.
Ready for code review.

consider switching to arrays to keep track of state, bitmask stuff is confusing and not necessary for this application

Agreed! Though I think it would make sense to have a heartbeat flag struct... just because each status bit inherently has a "name" (the board to which it corresponds to)... I'll work on dropping the one-hot encoding in favor of this.


FR: add multiple custom filter panels

Thank you for developing this plugin, which has been very helpful for my Obsidian document editing.
I would like to add multiple custom filter panels.
For example, creating a "Movies-2024" filter panel that will record the movies I've watched in 2024. Every time I open the "Movies-2024" board, I can filter out the corresponding movie information.

Hello ! I like this idea. I was already thinking about a "saved/favorite search query" feature which would be very similar, I will see how I can mix both.

See https://github.com/jillro/obsidian-cards-view-plugin/pull/40.


Improve default Layout.xml/mods.lua for proxying

Ideally, it would be as simple as copying the existing proxies, and it would be clear how to put them in different positions.
Right now, it's multiple steps to create player proxies. It's not clear to a beginner how the default mods.lua code is involved.
Also, we could try to make the answer to everyone's first question, "How do I put the players on top of eachother in the middle of the screen?" more obvious and apparent and guessable.

There is no setupjudge proxy all proxy code is now explicit and organized in mods.lua


timers for RFC Ed Queue state labels are inaccurate

Describe the issue
When documents in the RFC Editor's Queue are listed on a working group's document page, they have a timer label that says "In state for NN days; goal is <60 days." However, the number of days shown is for the document's entire time in the queue, not for the state shown. The placement of the timer label implies that it is referring to the queue state. For example, a document's queue state label says "AUTH48" and the timer label next to it says "In state for 133 days; goal is < 60 days", but the document has only been in AUTH48 for 28 days. If there was ever a goal for AUTH48, it was 2 days, but there's not an official goal now. For the example here, the label should say "In state for 28 days".
I'm not sure where the goal of "<60 days" came from. The current SLA specifies service levels for RFC Editor-controlled Time (RET), which is the time a document spends in EDIT and RFC-EDITOR states, but these levels change depending on how many pages are in the queue. Perhaps the "goal is <60 days" text should be dropped.
Code of Conduct

[X] I agree to follow the IETF's Code of Conduct

Info for addressing this:
The goal of 60 days is set here with a comment
# loosely based on the Publish Path page at the iesg wiki

That badge is indeed keying on the rfcqueue state and is not considering the rfceditor state at all. (The code is from 2012...)
Later in the same file, the auth48_alert_badge() looks into the rfceditor state. I'm not certain whether the events needed for tracking time in that state will be reliably available though I suspect they will.

I found the IESG Publish Path page, which covers goals for docs before they enter the queue but doesn't discuss goals of docs once in the queue. It may have had different info in 2012. The current SLA went into effect in 2016.


fix: Issues with the CDK Deployment

#3894
The CDK deployment having issues.

HEy, @jolo-dev
We are updating to uv. Could you use #3916 as inspiration for this fix?

HEy, @jolo-dev
We are updating to uv. Could you use #3916 as inspiration for this fix?

Hey @ogabrielluiz,
Sounds good 👍
Will do!


Multiple CSRs posted to Venafi TPP causing errors in certificate state.

(https://github.com/jetstack/cert-manager/files/6318079/talkingheads-10.logs.txt)
We have an issue where certificate signing requests are being sent to venafi/TPP multiple times during issuance/renewal of a certificate. This has reduced in frequency as compared with version 1.2.0 but still happens. Ref https://github.com/jetstack/cert-manager/issues/3843 and the master issue for this = https://github.com/jetstack/cert-manager/issues/3603
This happens something like 1 in 20 times and is more likely on renewal rather than initial certificate issuance. Here is a sequence of certificates we created and then which were renewed. The cert called talkingheads-13 submitted two CSRs for the renewal and the certificate is now in an error state in TPP. From there cert-manager retries hourly.
talkingheads-10-hzw4f          True                 True      tpp-venafi-issuer-cluster   system:serviceaccount:cert-manager:cert-manager   8h
talkingheads-10-ssgh4          True                 True      tpp-venafi-issuer-cluster   system:serviceaccount:cert-manager:cert-manager   22h
talkingheads-11-c6gxb          True                 True      tpp-venafi-issuer-cluster   system:serviceaccount:cert-manager:cert-manager   9h
talkingheads-11-dglk5          True                 True      tpp-venafi-issuer-cluster   system:serviceaccount:cert-manager:cert-manager   22h
talkingheads-12-bd5gr          True                 True      tpp-venafi-issuer-cluster   system:serviceaccount:cert-manager:cert-manager   99m
talkingheads-12-pdhq4          True                 True      tpp-venafi-issuer-cluster   system:serviceaccount:cert-manager:cert-manager   22h
talkingheads-13-4sxps          True                 True      tpp-venafi-issuer-cluster   system:serviceaccount:cert-manager:cert-manager   22h
talkingheads-13-zkqnv          True                 False     tpp-venafi-issuer-cluster   system:serviceaccount:cert-manager:cert-manager   39m
Attaching logs from cert-manager showing the two CSR submissions. Note these look to be the same CSR submitted twice.
Anything else we need to know?:
Kubernetes version:
1.18 (OSE)
Cloud-provider/provisioner:
On prem Venafi TPP
cert-manager version:
V1.3.0
Install method: e.g. helm/static manifests
Static Manifests
talkingheads-10.logs.txt
talkingheads-13.logs.txt
/kind bug

Thanks for opening the issue!
I am guessing this is a different issue than #3603 where there was more than one CertificateRequest created per renewal cycle for a Certificate.
In this case it apears to be multiple certificate signing requests for CertificateRequest, so could be an issue with the certificate-request controller or the  venafi issuer.

/priority important-soon

Attaching an example of the logs at the TPP side . Note that with version 1.2 we saw a single CSR entry and with v 1.3 we see two CSRs each time. This doesn't always result in failure as we sometimes see a single cert returned however sometimes we see two certs and that causes the cert to end up in an error state on renewal.
v1.2_example.csv
v1.3_example.csv

Have tried building cert-manager with an ealier version of vcert (https://github.com/jetstack/cert-manager/commit/308a0f44052a8954fdc5a81195e68c817aab446d) to no avail. I plan to do a slightly manual git bisect between 1.2.0 and 1.3.0 to see if I can pin down the point at which this behaviour started.

Results from a git bisect between 1.2.0 and 1.3.0
oot@certmanagerbuild:/home/andy/cert-manager# git bisect good
bad96f51027d0d48e0829e014bab0e532e373a34 is the first bad commit
commit bad96f51027d0d48e0829e014bab0e532e373a34
Merge: 19ae739ab 127acfc7e
Author: jetstack-bot<EMAIL_ADDRESS>Date:   Fri Mar 26 15:20:58 2021 +0000
Merge pull request #3582 from lalitadithya/vault_health_check_and_namespace_fix

Vault health check and namespace fix

pkg/internal/vault/fake/vault.go | 12 ++++++++++--
pkg/internal/vault/vault.go      | 38 +++++++++++++++++++++++++++++++++-----
pkg/internal/vault/vault_test.go |  4 +++-
pkg/issuer/vault/setup.go        | 12 ++----------
4 files changed, 48 insertions(+), 18 deletions(-)

Hi - For some reason git bisect gave me the wrong commit to blame (resulting in me undoing the revision above in the most recent master which didn't fix the problem). I have re-tested and the last good version and first bad version are as follows.
Last Good version: "git-commit"="127acfc7e163c206f22ddaa30899cbcd5837b426" "version"="v1.2.0-151-127acfc7e163c2"
First Bad version: "git-commit"="442d7dbc080fbbb70b53a48668d5eb743c799688" "version"="v1.2.0-165-442d7dbc080fbb-dirty"
https://github.com/jetstack/cert-manager/commit/442d7dbc080fbbb70b53a48668d5eb743c799688
My apologies for any confusion caused by the output above!

The issue is with a 1 second timeout in controller.go
for i := 0; i < workers; i++ {
wg.Add(1)
// TODO (@munnerz): make time.Second duration configurable
go wait.Until(func() {
defer wg.Done()
c.worker(ctx)
}, time.Second, stopCh)
}
I have tested with a longer timeout and the issue doesn't occur (our TPP instance usually takes circa 5 seconds to issue). There is a TODO to make the timeout configurable and I believe that would fix our issue.

The issue is with a 1 second timeout in controller.go

I think this period might be the period of how often new items are pulled out of workqueue and synced rather than a timeout.
Regardless of whether that is the right fix for this issue, it might make sense to allow for that period to be configurable. I have created a new issue for that #3915 and marked it as a good first issue in case someone wants to give it a try.

I have done some more digging on this - the issue appears intermittent in that I can have a fully working system then kill off the controller pod and when it comes back up have the dual CSR logs in TPP.
By coincidence we have had an issue with the back end CA which has exposed something about the issue due to the time it's taking for the certs to get into an error state on TPP. Note I know the retrieval of these certs failed however I think it highlights a timing issue.
The attached is from HEAD with a few additional logging entries I added to highlight the control flow. It shows the calls to sign() made by the sync function .
10:00:14.485578 -> No pickupID hence calling client.RequestCertificate()
10:00:15.089206 -> No pickupID hence calling client.RequestCertificate()
On the first time around we see no pickupID (as expected) however we see a second call which happens before the pickupID is in place. The pickupID isn't availble until
10:00:25.966394
Hence the controller loop is calling the sync function which is calling the venafi sign function twice prior to the pickupID being present. I think there needs to be an indication somewhere as soon as the cert is being requested to prevent another request from being issued as the sign function only looks for pickupID.
errorcondition.txt

I have tried a patch where I added an "in progress" annotation to the CR during the client.RequestCertificate call which prevented other instances of the sign function from re-requesting the CR. Once an error occurs or the function returns a pickupID which is annotated on the CR then I set this to blank.
This results in the issue going away for me.
Would you like me to submit a pull request after I tidy it up or do you think there is a different way to resolve the issue ?

Adding a link to a related Slack thread here .
/cc @wallrj as he has worked on TPP more.

Hence the controller loop is calling the sync function which is calling the venafi sign function twice prior to the pickupID being present. I think there needs to be an indication somewhere as soon as the cert is being requested to prevent another request from being issued as the sign function only looks for pickupID.

From the logs, it appears that perhaps what is happening is that:

A CertificateRequest gets synced, Sign function issues a request to Venafi TPP (Timeouts hardcoded here it seems)
Somehow the same CertificateRequest is being synced again before the first sync cycle has finished and we end up issuing another request.

It would be good to understand what has caused the CertificateRequest being re-synced again, perhaps there is some higher level flaw? I have not been able to reproduce this issue, so haven't seen the full log from controller.

I have tried a patch where I added an "in progress" annotation to the CR during the client.RequestCertificate call which prevented other instances of the sign function from re-requesting the CR. Once an error occurs or the function returns a pickupID which is annotated on the CR then I set this to blank

At the moment we usually update the statuses and annotations of resources once- when we exit a function, i.e here for the above mentioned Sync function. Doing it in other places throughout the function would increase the complexity + require some extra co-ordination, but perhaps that is ok, if there is no other way around this issue.
It would be good to hear what others think.

Hi - We've completed testing on the patched version which caches in-flight requests to TPP as well as the pickupID and it works successfully. Should I submit a PR?

Hi, I think if you have the code already, it might make sense to PR- it'd always be easier for us to comment on code!

other workers (or indeed the same worker) seeing the pickupID annotated on the object

I do still think there might be an issue in why another worker would reconcile the same object before the pickupID annotation has been applied.
I would have expected the sequence to be:

A newly created CR get processed, a worker picks it up from the workqueue, eventually calls the Sign functions and calls client.RequestCertificate which returns the PickupID, which we then apply as an annotation to the CR
Applying the annotation causes the CR to be re-synced because its state has been updated.

I don't see why the CR would get re-synced before the annotation has been applied as there shouldn't have been any other state changes at that point and we return nil from Sign function here.
Some related conversation on Slack https://kubernetes.slack.com/archives/CDEQJ0Q8M/p1621939868081400, I thought perhaps the event recorder is to blame, but I see that we apply the annotations and the state change at the same time in the deferred function.
Maybe we are returning with an error here or here? Those would both cause a reconcile as we update CR's state in both cases and return an error in one case.

/remove-lifecycle rotten

This issue has gone away and isn't present in v1.8.0.


Doesn't work with files larger than 100MB?

Hi!
First thanks for the Stirling PDF, fantastic tool!
I'm having problems with PDFs larger than 100MB for any function, I tried to use split but it gave the error HTTP error status: 413.

I tested it with a 93MB PDF and it worked.
Is there a way to configure it to allow you to work with large PDF files?

This will be your reverse proxy configuration most likely, you should see other issue tickets for same issue raised you can use as reference for possible fixes

This will be your reverse proxy configuration most likely, you should see other issue tickets for same issue raised you can use as reference for possible fixes
Thank you!

The problem was the CloudFlare reverse proxy, I only left the NGINX reverse proxy and it worked.


React capstone project - Metrics webapp

What does this PR do?
In this PR I create a Completed Stock Screener Website which is a tool quickly find current stock prices in USA companies...
Description of the task to be completed 👎
Setup the project with React.
Setup Redux Store
Fetch the API to the Store
Dispatch the API to the Components
Apply the Desing

Submit For Second Time Review.


vcpkg manifest mode cannot bootstrap non-x64 Linux

In vcpkg manifest mode,
vcpkg.cmake will call bootstrap-vcpkg.sh to build vcpkg executable if not yet.
On Linux, bootstrap.sh will always download Linux x64 cmake and ninja binaries, so they won't run on non-x64 platforms, such as ARM.
In such case, user can install the correct architecture of cmake and ninja by himself, and then pass -useSystemBinaries flag to bootstrap-vcpkg.sh.
But in manifest mode, extra flags cannot be passed to bootstrap-vcpkg.sh.
I suggest to support VCPKG_FORCE_SYSTEM_BINARIES environment variable in bootstrap.sh as well, as an alternative to -useSystemBinaries.
Similarly, VCPKG_DISABLE_METRICS vs -disableMetrics

@strega-nil Could you please take a look?
Thanks.

Neither non-x64 Linux nor Alpine x64 work, because Alpine C library is musl

Yeah, it's likely that we need to do a more complete rewrite. This will be solved before we stabilize manifests; until that point, you're going to have to, unfortunately, run the bootstrap script yourself.

It is easy to implement VCPKG_FORCE_SYSTEM_BINARIES=1 in bootstrap.sh
so that user can set once for both bootstrap and vcpkg install

@linquize fair enough; do you want to write that?

You write

ARM64 OK

Okay, please reopen this issue if you meet it again.


Ensure traverse is only called on objects

Current coverage is 80.02%

Merging #254 into master will increase coverage by +0.22% as of f79c682

@@            master    #254   diff @@
======================================
  Files           40      40
  Stmts         3278    3279     +1
  Branches       775     776     +1
  Methods          0       0
======================================
+ Hit           2616    2624     +8
+ Partial        230     225     -5
+ Missed         432     430     -2

Review entire Coverage Diff as of f79c682

Powered by Codecov. Updated on successful CI builds.


Arrow keys randomly stop working

Issue Type: Bug
Frequently, probably every 10-20 hours of use, VSCode randomly stops responding to the right & down arrow keys. Up & left keep working normally. No alternate function replaces the normal navigation function; VSCode just doesn't respond to those keys at all. I can switch to other windows for other applications and the arrow keys work normally there, and then I switch back to VSCode and the arrow keys still don't work there. I can open and close different files within VSCode, and VSCode still does not respond to those keys. I have to close and restart VSCode in order to restore arrow key functionality.
VS Code version: Code - Insiders 1.55.0-insider (892a1083cb2b9b3987ff7edc85376b5d9764433d, 2021-03-16T05:11:50.271Z)
OS version: Darwin x64 20.3.0
Remote OS version: Linux x64 4.4.0-31-generic

System Info

Item
Value

CPUs
Intel(R) Core(TM) i7-9750H CPU @ 2.60GHz (12 x 2600)

GPU Status
2d_canvas: enabledgpu_compositing: enabledmetal: disabled_offmultiple_raster_threads: enabled_onoop_rasterization: enabledopengl: enabled_onprotected_video_decode: unavailable_offrasterization: enabledskia_renderer: disabled_off_okvideo_decode: enabledwebgl: enabledwebgl2: enabled

Load (avg)
2, 2, 2

Memory (System)
16.00GB (4.01GB free)

Process Argv
--crash-reporter-id 59b5e7e7-e7ff-454f-9611-dce47e33f26c

Screen Reader
no

VM
0%

Item
Value

Remote
SSH: <IP_ADDRESS>

OS
Linux x64 4.4.0-31-generic

CPUs
Intel(R) Xeon(R) CPU E5-1650 v4 @ 3.60GHz (12 x 1393)

Memory (System)
62.85GB (18.73GB free)

VM
0%

Extensions (10)

Extension
Author (truncated)
Version

remote-ssh
ms-
0.65.1

remote-ssh-edit
ms-
0.65.1

vscode-bazel
Baz
0.4.0

gitlens
eam
11.3.0

dbc
lha
1.2.3

python
ms-
2021.4.643775328-dev

vscode-pylance
ms-
2021.3.1

jupyter
ms-
2021.4.641214696

cpptools
ms-
1.2.2

vscode-proto3
zxh
0.5.3

A/B Experiments
vsliv695:30137379
vsins829:30139715
vsliv368:30146709
vsreu685:30147344
python383cf:30185419
pythonvspyt602:30263608
vspor879:30202332
vspor708:30202333
vspor363:30204092
vstry244:30244315
pythonvsdeb440:30224570
pythonvsded773:30223139
pythonvspyt875:30259475
pythonvsnew554:30265444
pythontb:30258533
vscoresta800:30265947
vsc_aa:30263845
vspre833cf:30267465
vsfjg287:30275553

If you are able to enter this state again, please try the following:

Run the command Developer: Toggle Keyboard Shortcuts Troubleshooting
This will activate logging of dispatched keyboard shortcuts and will open an output panel with the corresponding log file.
Press exactly the keybinding you desire (<arrow_down>)
check what VS Code detects and what command is invoked.

If you are having trouble understanding the output, please feel free to paste here and I can try to help.


Develop

Dependency management
Development version bumped

@rultor merge this please

@rultor merge this please

@mkanev OK, I'll try to merge now. You can check the progress of the merge here

@rultor merge this please

@mkanev Done! FYI, the full log is here (took me 1min)


Speed bottleneck when accumulating progress_bar_metrics

🐛 Bug
Since trainer.progress_bar_metrics copies to cpu (via metrics_to_scalars calling .item(), compare L591 of trainer/connectors/logger_connector/result.py), it is not possible to accumulate and average progress bar metrics inside a custom ProgressBar without creating a speed bottleneck due to copying to cpu after every training iteration.
To Reproduce
Log some scalar tensors, call trainer.progress_bar_metrics after each batch in your custom progress bar, observe speed bottleneck (especially in multi-GPU training).
Expected behavior
Checking that progress bar metrics are actually scalars and copying to cpu are two different things. trainer.progress_bar_metrics could return scalar tensors, which can be copied to cpu in the ProgressBar as needed (i.e. only when printing).
cc @carmocca @edward-io @ananthsub @rohitgr7 @kamil-kaczmarek @Raalsky @Blaizzy @kaushikb11 @awaelchli @borda @akihironitta

Hi!
We could do your suggested change. But it would be a breaking change for any other component that relies on the values of progress_bar_metrics being simple floats.

it is not possible to accumulate and average progress bar metrics inside a custom ProgressBar without creating a speed bottleneck due to copying to cpu after every training iteration.

What exactly are you trying to do in your custom ProgressBar? Accumulating and averaging is a responsibility of our internal logging components, so I would suggest not trying to do this at the progress bar callback level.

I have a dictionary of scalar loss tensors that should be accumulated until the next printout happens in the progress bar, and then these should be averaged. If there is already accumulating and averaging happening in the internal components for all of progress_bar_metrics, could you point me to the piece of code? So far if i do not accumulate the values myself, the values seem to be way more unstable, so i assumed the values in trainer.progress_bar_metrics will be the latest ones

Thanks, I understand what you are trying to do now.
The recommended approach, in that case, is to use a torchmetrics.Metric instance that you would update, self.log("foo", avg_metric) and you could access through your LightningModule to extract the .compute() value on-demand.
https://torchmetrics.readthedocs.io/en/stable/aggregation/mean.html
Here's a simple example:
import os

import torch
from torch.utils.data import DataLoader, Dataset

from pytorch_lightning import LightningModule, Trainer, Callback
from torchmetrics import MeanMetric

class RandomDataset(Dataset):
    def __init__(self, size, length):
        self.len = length
        self.data = torch.randn(length, size)

    def __getitem__(self, index):
        return self.data[index]

    def __len__(self):
        return self.len

class BoringModel(LightningModule):
    def __init__(self):
        super().__init__()
        self.layer = torch.nn.Linear(32, 2)
        self.my_metric = MeanMetric()

    def forward(self, x):
        return self.layer(x)

    def training_step(self, batch, batch_idx):
        self.my_metric.update(batch_idx + 1)
        self.log("my_metric", self.my_metric, prog_bar=True)
        return self(batch).sum()

    def configure_optimizers(self):
        return torch.optim.SGD(self.layer.parameters(), lr=0.1)

class MySimpleProgressBar(Callback):
    def on_train_batch_end(self, trainer, pl_module, *args, **kwargs):
        print(pl_module.my_metric.compute())

def run():
    train_data = DataLoader(RandomDataset(32, 64), batch_size=2)
    model = BoringModel()
    trainer = Trainer(
        default_root_dir=os.getcwd(),
        limit_train_batches=3,
        max_epochs=1,
        enable_model_summary=False,
        enable_checkpointing=False,
        enable_progress_bar=False,
        logger=False,
        callbacks=MySimpleProgressBar()
    )
    trainer.fit(model, train_data)

if __name__ == "__main__":
    run()

okay thanks, that seems to work. However, this feels like a workaround since we are mixing logging responsibilities into the model. I'm not sure what the design goal is, if it is desirable to keep logging and model separate, but to me it seems doing this either in the progress bar or the LoggerConnector would be more intuitive.
Plus one could actually log things dynamically, rather than having to define a variable for each in the init. This makes things easier e.g. when there is a loss that is only turned on after say a certain number of epochs, or in specific hyperparameter settings. I solved it like this for now:
    def training_step(self, batch, *args, **kwargs):
        losses = self.forward_train(batch)
        losses["loss"] = sum(list(losses.values()))

        log_dict = {}
        metric_attributes = []
        for k, v in losses.items():
            if not hasattr(self, k):
                metric = MeanMetric()
                metric.to(self.device)
                setattr(self, k, metric)

            metric = getattr(self, k)
            metric(v.detach())
            log_dict["train/" + k] = metric
            metric_attributes += [k]

        for (k, v), k_name in zip(log_dict.items(), metric_attributes):
            self.log(k, v, logger=True, prog_bar=True, on_step=True, on_epoch=False, metric_attribute=k_name)
        return losses


Use Roslyn's editorconfig support

Resolves https://github.com/OmniSharp/omnisharp-roslyn/issues/1657

thanks a lot, this is a very welcome change!
I left some small comments and just have a few questions:

should we not add the discovered editorconfig to the watcher here https://github.com/OmniSharp/omnisharp-roslyn/blob/3163c234bc0cb2ece67624791a66d735b295b907/src/OmniSharp.MSBuild/ProjectManager.cs#L371 ? so far it was not needed because the options were reapplied before formatting
it would be good to have some extra test similar to this one https://github.com/OmniSharp/omnisharp-roslyn/blob/3163c234bc0cb2ece67624791a66d735b295b907/tests/OmniSharp.MSBuild.Tests/ProjectWithAnalyzersTests.cs#L67 that verifies that analyzer diagnostic options from editorconfig are correctly loaded
I wasn't aware of the EditorConfigFiles msbuild item - in which versions of VS is this supported? (I think in the past it wasn't possible to provide your own custom file path)

it would be good to have some extra test similar to this one

Yep, I agree

should this code be conditioned on editorconfig being enabled in OmniSharp?

Yeah, there are a few places to update if we want to disable the analyzer part. With it being under FormattingOptions I wasn't sure the expected behavior.
I'll update soon.


Text does not show when updating state

When the text (@State) is updated, the component does not show it:
@State var text          = NSAttributedString(string: "Type text here...")
RichTextEditor(text: $text, context: context)
.focusedValue(.richTextContext, context)
.focused($isFocused)
The initial text works, but when text is updated, it does not get rendered.

Hi @pkasson
That's unfortunately a side-effect of striving for better performance, since the text editor would otherwise be redrawn whenever you type.
I've been thinking about adding an internal binding that always writes out to the external one, but also listen for those changes and update whenever the external one changes.
For now, you can use setter functions in the rich text context, which affect the editor.

Thanks - that worked.  I agree, there is a balancing act on updating content that has rich content and performance

Next Q - how can I set the BG color - it appears maybe using the Theme, but I can't see how to set it to white.

You can set a color with the rich text action approach.

How do you do that ?

You can trigger a RichTextAction.
The documentation is a bit fuzzy about this, but you can see some examples in the docs:
https://danielsaidi.github.io/RichTextKit/documentation/richtextkit/context-article

Yes, quite fuzzy - didn't find anything around this ... thanks for trying - will find another RTF editor.


To-do list

-- Included the add functionality. When the add button is clicked, items are added to the list.
-- A delete function to delete individual todos
-- A function to clear all completed todos
-- All todos have a checkbox that when checked changes the completed property from false to true

Instead of using window.onload, it's better to use the DOMContentLoaded event. This ensures that your script runs after the DOM is fully loaded.
https://github.com/enocol/to-do-list_copy/blob/aecda21238cc0aab5c7bb7eeac5a68cf7ab22468/src/index.js

Also it would be nice if you're consistent with the CSS property names.
https://github.com/enocol/to-do-list_copy/blob/aecda21238cc0aab5c7bb7eeac5a68cf7ab22468/src/styles.css


rfc: Network Graph Visualization

Leverage stat to create a high level visual overview of everything inside (and outside) of the mesh.
An example of what this could look like:

Dashboard
User Stories

As a developer, I would like to explore the network graph associated with my service, so that I can debug a current issue.
As an operator, I would like to narrow down external traffic to a specific service that is failing, so that I can contact the service's owner to get it fixed.
As someone looking to adopt conduit, I would like to visually show some of the observability features, so that others can understand the benefit of adoption.

Features

Add a new tab (Network)
Provide a dropdown to select namespace.
Render the high level resource types (deployments) with directed arrows showing traffic both to and from. This would show external traffic coming into a node.
Clicking on a node will dive into a "detail" view for that resource, showing every pod and the traffic going to these.
Show basic stats next to each edge (success rate, latency) with color coding.

Grafana
User Stories

As an operator, I would like to have a high level view of the health of my services, so that I can feel good about everything working as it should.

Features

New network graph dashboard
Graphviz plugin for rendering the entire state
Namespace dropdown

CLI
User Stories

As a developer, I would like to see an overview of the connections to my service, so that I can understand if the changes I made were successful.

Features
conduit graph
Display network graph for one or many resources.

This command will hide resources that have completed, such as pods that are in the Succeeded or Failed phases.

Examples:
  # Output graph for default namespace
  conduit graph

  # Graph the incoming/outgoing traffic for the web deployment
  conduit graph deploy/web

  # Graph everything in the walrus namespace
  conduit -n walrus graph

Options:
      --all-namespaces=false: If present, list the requested object(s) across all namespaces. Namespace in current context is ignored even if specified with --namespace.
  -E, --end-time='': If present, sets the end of the measured window to the specified time.
      --no-headers=false: When using the default or custom-column output format, don't print headers (default print headers).
  -l, --selector='': Selector (label query) to filter on, supports '=', '==', and '!='. (e.g. -l key1=value1,key2=value2)
  -w, --window='10s': Time period over which stats are measured.

Usage:
  conduit graph (TYPE [NAME | -l label] | TYPE/NAME ...) [flags] [options]

Use "conduit options" for a list of global command-line options (applies to all commands).

Example output:
    vote-bot
     1ms|93%
        |
        v
       web
        +
 100%   |     86%
emoji<--+-->voting
 1ms          1ms

Open Questions

How should multiple resource types be handled?
Should there be an extreme detail view that shows everything we've got for specific resource types, as a card?
How valuable is the grafana and/or dashboard integration?
Should the grafana integration be more integrated in the existing dashboards?
Is the CLI/Grafana work work the cost?

It occurs to me that on terminals where Unicode is supported (i.e. a vast majority of them these days, we could even use Unicode box-drawing characters as well, for extra fanciness.

Minimum Effort
My hypothesis is that the first deliverable (sorted by effort) would be in the grafana dashboards. Any ideas on where best to add the graph?
CLI
I think you're right about the CLI. I wonder if we could be better served by doing an update to stat's output.

As for Grafana, I think this makes most sense as a separate page, since it potentially spans namespaces and acts as a top-level view of the cluster.

Okay, updates:

Removing the CLI integration. There are some potentials for a better experience via. tables or something else.
The existing grafana plugin doesn't let you define the diagram dynamically. It is more for coloring nodes and edges via. metric values.

So, this is reduced to just integration with the conduit dashboard for now.

Historical --------------------------------
Grafana
User Stories

As an operator, I would like to have a high level view of the health of my services, so that I can feel good about everything working as it should.

Features

New network graph dashboard
Graphviz plugin for rendering the entire state
Namespace dropdown

CLI
User Stories

As a developer, I would like to see an overview of the connections to my service, so that I can understand if the changes I made were successful.

Features
conduit graph
Display network graph for one or many resources.

This command will hide resources that have completed, such as pods that are in the Succeeded or Failed phases.

Examples:
  # Output graph for default namespace
  conduit graph

  # Graph the incoming/outgoing traffic for the web deployment
  conduit graph deploy/web

  # Graph everything in the walrus namespace
  conduit -n walrus graph

Options:
      --all-namespaces=false: If present, list the requested object(s) across all namespaces. Namespace in current context is ignored even if specified with --namespace.
  -E, --end-time='': If present, sets the end of the measured window to the specified time.
      --no-headers=false: When using the default or custom-column output format, don't print headers (default print headers).
  -l, --selector='': Selector (label query) to filter on, supports '=', '==', and '!='. (e.g. -l key1=value1,key2=value2)
  -w, --window='10s': Time period over which stats are measured.

Usage:
  conduit graph (TYPE [NAME | -l label] | TYPE/NAME ...) [flags] [options]

Use "conduit options" for a list of global command-line options (applies to all commands).

Example output:
    vote-bot
     1ms|93%
        |
        v
       web
        +
 100%   |     86%
emoji<--+-->voting
 1ms          1ms

Apparently graph layout is a tough problem. There's a library that has implemented the same algorithm as GraphViz (and it works with d3!):
https://github.com/dagrejs/dagre-d3


Build fixes

This branch contains build fixes for ASDF 3.3. It also contains the same fixes for Bazel as my previous pull request #15 .

I was about to submit a patch for the ASDF 3.3 part of this PR when I stumbled upon it.
@hankhero : do you plan to merge this one?
It would help if the next version in Quicklisp would contain the fix.


Skip only comment?

I have this comment that I don't want rustfmt to touch, so I tried putting #[rustfmt::skip] on it, like so:
#[rustfmt::skip]
/*
    Pointer	Code points	Notes
    1133	U+00CA U+0304	Ê̄ (LATIN CAPITAL LETTER E WITH CIRCUMFLEX AND MACRON)
    1135	U+00CA U+030C	Ê̌ (LATIN CAPITAL LETTER E WITH CIRCUMFLEX AND CARON)
    1164	U+00EA U+0304	ê̄ (LATIN SMALL LETTER E WITH CIRCUMFLEX AND MACRON)
    1166	U+00EA U+030C	ê̌ (LATIN SMALL LETTER E WITH CIRCUMFLEX AND CARON)
 */
const SPECIAL_POINTERS:[u32;4] = [1133,1135,1164,1166];

Unfortunately, this also leads to the code line below the comment to be skipped; as you can see, it hasn't fixed up the :[u32;4] or added spaces after the commas. However, if I remove the #[rustfmt::skip], the comment gets mangled as the code line gets fixed.
There's an obvious fix here, of course, which is to cut the comment and the #[rustfmt::skip] attribute, let rustfmt format the line, and then paste them back. But that only works right now and if the line was to be changed in the future, it'd be left untouched by rustfmt again, which is undesirable.

I still think it'd be nice to have a directive that just skipped a comment from being formatted but not any code it was attached to, but I'd understand if you closed this comment as a non-issue.

Agreed with @ytmimi, and also want to add that I understand this ask and it's something we'd be open to considering. However, attributes wouldn't be an appropriate avenue because syntactically it's not the comment that's being attributed, it's the item, expression, etc.
Perhaps some kind of marker within the comment itself could be considered one day, e.g.:
/* rustfmt::avert-your-eyes
....

but even still there'd likely be some edge cases due to rustfmt working with the AST, and not the underlying tokens and characters in the source files


Enable switch in view

Enable option to display a switch to turn on and off GPS directly from dialog.

Hi @rodrigo-martinezd how's work on this plugin feature going?
I asked you about this earlier in July and you said your target date was August. Any progress on this?
Thanks for the taking time to create this plugin


Tag management

Describe the solution you'd like

A separate page in the menu to show all the tags.
It's optional to control whether to show tags in the home page. Because some tags I don't want to see on the page all the time, such as my ex's name ^^

Type of feature
User Interface (UI)
Additional context
No response

As an initial way of "hiding" tags you could updates the tags you don't want to see to be nested and change to tree view. This way you will need to click into the top level tag to see the tags you don't want to see regularly
E.g.
new tag structure

Tags tree view

A separate page in the menu to show all the tags.

Sounds like a good idea.

Because some tags I don't want to see on the page all the time, such as my ex's name ^^

So, what’s the reason behind creating this tag?

She was perhaps not ex when those memos were taken.


Bug in get_next_power_of_2

The simple-serialise (Merkleisation section) reads:

next_pow_of_two(i): get the next power of 2 of i, if not already a power of 2, with 0 mapping to 1. Examples: 0->1, 1->1, 2->2, 3->4, 4->4, 6->8, 9->16

In the merkle proofs, helpers are defined by:
def get_next_power_of_two(x: int) -> int:
    """
    Get next power of 2 >= the input.
    """
    if x <= 2:
        return x
    else:
        return 2 * get_next_power_of_two((x + 1) // 2)

def get_previous_power_of_two(x: int) -> int:
    """
    Get the previous power of 2 >= the input.
    """
    if x <= 2:
        return x
    else:
        return 2 * get_previous_power_of_two(x // 2)

Unfortunately, the first one is buggy (e.g. for 0 it returns 0 which is not a power of 2 and is different to what the simple-serialise specs reads.)
Here is a fix, proved correct with Dafny (the fact that it computes the next power of 2 of a given natural number requires more lemmas, not included in this post):
function get_next_power_of_two(n : int) : int
    requires n >= 0
    ensures get_next_power_of_two(n) >= 1
{
    if n <= 1 then 1
    else 2 * get_next_power_of_two( (n + 1) / 2)
}

The second one  get_previous_power_of_two is not clearly defined.
Anyway it seems buggy as well as it returns 0 for 0 which is not a power of 2.
What is the previous power of 2 >= input? Is it the power of 2, say k, such that 2^k < input <= 2^{k+1}?
Is it the largest power of 2 that is strictly smaller than the input? If yes, we also have a (provably) correct version of it.

The naming is pretty terrible here (different names for two very similar functions). And then for the incorrect one: in one place (get_generalized_index) it indeed should return 1 (but it will never be called with 0, so it does not matter), and in the other (merkle_tree) it should be 0 (no extra padding necessary, although a tree with 0 leaves is quite strange, maybe padding of 1 is fine as default there). And then it does not seem to be used anywhere else in the specs.
I'm not opposed to changing it to handle the 0 -> 1 properly, and unifying the names. That said, the ssz folder is planned to move out, to be replaced with that ssz draft repo once that is updated, and then we won't have this buggy function anymore.
Thanks for documenting this, I think I'll prioritize bringing the draft up to date and online so we won't have these issues anymore. :+1:

Thanks for that.
It is probably safer to document it and even it is not called with 0 now, it may happen in the future.
But overall, what is the mathematical spec of these functions?
This is what we have in our Dafny code at the moment:
 /** Get the next power of two.
     *
     *  @param  n   A positive integer.
     *  @return     The smallest power of 2 that is larger than n.
     */
    function get_next_power_of_two(n : nat) : nat
    requires true // n is a nat which is an int >=0 so pre-condition is true.
    ensures get_next_power_of_two(n) >= 1
    ensures get_next_power_of_two(n) >= n + 1 // result should be > n
    ensures n >= 1 ==> (get_next_power_of_two(n) / 2) < n // previous power of two should be < n

@protolambda We have opened our repository on formal verification of Eth2.0 using Dafny.
Here are power_of_2 spec and proofs

See #1907, the code is not used anywhere really, but I made an illustrative fix, while we figure out #1901.


KAFKA-17488: Cleanup (test) code for Kafka Streams "metric version"

We note that StreamsMetricsImpl is created with the default value Version.LATEST and only use builtInMetricsVersion to pass it to Objects.requireNonNull. So I have removed builtInMetricsVersion from StreamsMetricsImpl as well as removed BUILT_IN_METRICS_VERSION_CONFIG and BUILT_IN_METRICS_VERSION_DOC since they became unused.
I have based this work on KIP-444 and KIP-743.

Hi, @mjsax! Could you review it? :)

Thanks for the update. Overall LGTM -- one more minor question.

Thanks for the PR @fonsdant! Merged to trunk.


No module named pipes in Python 3.13

Traceback (most recent call last):
  File "<pyshell#1>", line 1, in <module>
    import talkey
  File "/home/wilbur/.local/lib/python3.13/site-packages/talkey/__init__.py", line 4, in <module>
    from .tts import Talkey, enumerate_engines, create_engine, TTSError
  File "/home/wilbur/.local/lib/python3.13/site-packages/talkey/tts.py", line 3, in <module>
    from .base import TTSError
  File "/home/wilbur/.local/lib/python3.13/site-packages/talkey/base.py", line 2, in <module>
    import pipes
ModuleNotFoundError: No module named 'pipes'

Cause: The pipes library is considered a 'dead battery' and has been removed from standard Python.
Workaround: pip install standard-pipes


App center is down

App center website is down, first codePush servers were down many times and now app center is down, is there any fix to those issues

Its been down for at least 5 hours.

They are/were down quite a while (17.5 hours) and it seems it's still intermittend, you can check their status page at: https://status.appcenter.ms/

Apr 03, 2023 - 21:47 UTC
Investigating - We apologize for the inconvenience caused as our Appcenter portal is currently down. Our team is investigating the issue and we'll update you as soon as possible. Thank you for your understanding.

Apr 04, 2023 - 15:14 UTC
Monitoring - We have taken steps to mitigate the issue, but the problem is not fully resolved and may reoccur. As of now, our portal is accessible and we're actively monitoring the situation. Thank you for your patience and understanding.

Appcenter is down again, but their status page does not indicate there is a problem.

It is down again.

Hi, and thanks for reaching us out. For more insight into potential issues, I recommend visiting the AppCenter Status page, where you can identify any existing problems. Additionally, for queries regarding crashes or other concerns, feel free to reach out to AppCenter support team for prompt assistance.


Stay home should be THE message front and center for USA.

Stay home should be THE message front and center for USA.
The less aggressive measures I published March 6 no longer make sense in lockdown.

This whole section needs to be replaced with "Stay Home" until we figure out what we are dealing with.
Lower your overall risk with everyday choices
Taken together, making safer every-day choices on average — not just this week but for the next several months — can flatten the curve. Continue to support your local economy, but go off peak; staggering by even 15 minutes can reduce crowding. Everything from restaurants to art museums to public transport will be less risky (and more pleasant!) off peak.
Non-contact sports are better than contact ones. E.g., Tennis is better than (>) rugby
Takeout > eat on restaurant patio > eat in restaurant
Video streaming options > movie theatre
Outside events > inside events (small events also are better than large ones)
Delivery/curbside pickup > going in person
Remote observance > religious service attendance
Birthday cupcakes > birthday cake (if candle blowing is involved)
Drink your coffee/beer/cocktail at a table instead > drink your coffee/beer/cocktail at the bar
Live performers are going to be hard hit economically. Consider supporting their work on Patreon, directly via PayPal, or attend only the smaller shows. Promote them on social media. Buy their work directly.

From the CDC site (https://www.cdc.gov/coronavirus/2019-ncov/cases-updates/summary.html?CDC_AA_refVal=https%3A%2F%2Fwww.cdc.gov%2Fcoronavirus%2F2019-ncov%2Fsummary.html)
'The United States nationally is currently in the initiation phases, but states where community spread is occurring are in the acceleration phase. The duration and severity of each phase can vary depending on the characteristics of the virus and the public health response.'
The United States is a big country, with 50 states, each handling this in a different way. Therefore, community spread is going to be occurring at different rates in different places. It is not known what the after-infection immunity period is like or if this can recur (not sure about this, needs research). Therefore, the best thing to do, if not required by your employer, is to stay home until this curve has sufficiently flattened.
Do not dine out.
Do not go to the movies - listen to the radio, watch TV, listen to podcasts, do puzzles, play board games, create an in-home disco.
Do not go to church - use home rituals or streaming services.
Do not go to work unless you must, and when you return have a routine for coming back so as not to bring the virus into your home.
Do not go shopping for non-essentials.
If you get restaurant food delivered, use a service that you can prepay and have the delivery person leave the food on the doorstep. Order well before you want to eat so you can isolate the food for a few hours, then heat it up if needed.
When you go grocery shopping, wear gloves and isolate your purchases (and your gloves!) in a safe spot for a few hours before unpacking.
Get outside! But keep walking. Say hi to people, get some social interaction, but get it in passing. Don't stop and form groups. Make sure and wave to all the pets being walked.

This feel super critical! Should we use the text provided by @pitviper6 above? Maybe without the sentence that's flagged as needing research?

@jmcmurry: looks like this issue was adequately addressed, so we can close this issue.


Feature Request: Proportional Scrolling

I would be interesting and useful if the scrolling sync was proportional to the number of lines of each file.
For example:
A file with 100 lines and other file with 50 lines in a split panel.
The behavior would be something like this:
If in the first file I scroll to the line 50, the other file should be on line 25. And so...

I don't know exactly how to code extensions in VSCode, but it would work something like this in this pseudocode:
linesFileA = getLines(fileA)
linesFileB = getLines(fileB)

percentLineA = currentLine(fileA) * 100 / linesFileA

syncLineB = linesFileB * percentLineA / 100

setPosition(fileB, syncLineB)

And the same the other way around.
I know that's not how VSCode extensions works, but I hope the idea is understandable ^^"

@moxwel Thanks very much for this idea and yes I think it's very clear and useful.
I will add this as another todo task.


add gamifyclub token

Add GMFC token

I can help stop wasting your time refer this zakimzf/profile#1


I just upgraded flutter and when I hide a window the app quits. I've only tested linux.

I just upgraded flutter and when I close a window onWindowClose never gets called and the app quits. I've only tested linux.
It worked before the latest flutter released today.

It's simple to reproduce.  This works fine in Flutter 3.7, but it quits the app on 3.10.
Modify the example app.
void main() async {
  WidgetsFlutterBinding.ensureInitialized();
  await windowManager.ensureInitialized();
// add setPreventClose(true) ############
  await windowManager.setPreventClose(true);

  @override
  void onWindowClose() {
    windowManager.hide();
  }

I tried a bunch of stuff and couldn't fix it.
One thing I noticed:
g_signal_connect(get_window(plugin), "delete_event",
G_CALLBACK(on_window_close), plugin);
why "delete_event" and not "delete-event"?  I tried delete-event and it made no difference, but wondering if that's a bug.

?

Unfortunately, the engine prevented WindowManager from listening to this event.
https://github.com/flutter/engine/pull/40033/files#r1200216166

Hi @sgehrman,
I am wondering if you've managed to get it working? I am facing the same issue on Ubuntu 22.10 and latest flutter (3.10.4).
Trying to make: setPreventClose and onWindowClose work together to suppress the close button and ask user if they want to minimize app instead.
I've "blindly" added the: g_signal_connect(window, "delete-event", G_CALLBACK(gtk_widget_hide_on_delete), NULL); line in the: my_application.cc, but it has no effect really -> Clickin the x button in the title bar closes the app immediately.

Please update to 0.3.5, this version has already fixed this issue


Soundness: Global ASM

Following LLVM, Rust allows global ASM in a module. This means that crates can have arbitrary code that we cannot analyze.
Likelihood
We know of crates that use this feature
Mitigation
We could fail any crate that uses this feature, but this would block any use of those crates, even if they did not use any of the risky features. Even worse, this would block all consumers of such crates, from even compiling, again even if they do not use any of the dangerous features.
Unlike for inline ASM in a function, where we can insert assert(0) as a mechanism to guarantee soundness, there is no obvious way to only fail code paths that use the injected ASM.

[x] Raise a warning if global asm appears
[ ] Incorporate that warning into viewer

Path to soundness

[ ] Support ASM in CBMC

Documentation
https://rust-lang.github.io/rfcs/1548-global-asm.html

The "Raise a warning" item can be mark as done, right?

Capturing the current behavior as of c3d41b94896: Kani produces a codegen warning, but does not cause verification to fail. For example, on the following test (adapted from the one here):
pub mod sally {
    std::arch::global_asm!(
        ".global foo",
        "foo:",
        "jmp baz",
    );

    #[no_mangle]
    pub unsafe extern "C" fn baz() {}
}

// the symbols `foo` and `bar` are global, no matter where
// `global_asm!` was used.
extern "C" {
    fn foo();
    fn bar();
}

pub mod harry {
    std::arch::global_asm!(
        ".global bar",
        "bar:",
        "jmp quux",
    );

    #[no_mangle]
    pub unsafe extern "C" fn quux() {}
}

#[kani::proof]
fn main() {
    assert!(1 + 1 == 2);
}

Kani produces two codegen warnings:
 WARN kani_compiler::codegen_cprover_gotoc::compiler_interface Crate global_asm contains global ASM, which is not handled by Kani
 WARN kani_compiler::codegen_cprover_gotoc::compiler_interface Crate global_asm contains global ASM, which is not handled by Kani
warning: 2 warnings emitted

but verification passes:
RESULTS:
Check 1: main.assertion.1
         - Status: SUCCESS
         - Description: "assertion failed: 1 + 1 == 2"
         - Location: global_asm.rs:32:5 in function main

SUMMARY:
 ** 0 of 1 failed

VERIFICATION:- SUCCESSFUL


Previous documentation versions

On the main documentation page
ie
https://wintercms.com/docs/v1.2/docs/setup/installation
there is a version dropdown in the top left.
however no options other that 1.2 are available

What's the status of the new version of that selector @bennothommo?

@LukeTowers the changes on the staging site need to be merged in first, but theoretically all that's required is for us to split off the docs into another branch for the older versions and add some additional deployment triggers to re-render the older docs.

This has been merged and deployed: https://wintercms.com/docs


[Snyk] Fix for 2 vulnerabilities

Snyk has created this PR to fix 2 vulnerabilities in the maven dependencies of this project.
Snyk changed the following file(s):

master/pom.xml

Vulnerabilities that will be fixed with an upgrade:

Issue
Score
Upgrade

Path Traversal SNYK-JAVA-ORGSPRINGFRAMEWORK-8230372
  167
org.springframework:spring-webflux:  5.3.18 -> 6.1.14 Major version upgrade No Known Exploit

Path Traversal SNYK-JAVA-ORGSPRINGFRAMEWORK-8230373
  167
org.springframework:spring-webmvc:  5.3.18 -> 6.1.14 Major version upgrade No Known Exploit

[!IMPORTANT]

Check the changes in this PR to ensure they won't cause issues with your project.
Max score is 1000. Note that the real score may have changed since the PR was raised.
This PR was automatically created by Snyk using the credentials of a real user.

Note: You are seeing this because you or someone else with access to this repository has authorized Snyk to open fix PRs.
For more information:
🧐 View latest project report
📜 Customise PR templates
🛠 Adjust project settings
📚 Read about Snyk's upgrade logic

Learn how to fix vulnerabilities with free interactive lessons:
🦉 Path Traversal

:tada: Snyk checks have passed. No issues have been found so far.
:white_check_mark: code/snyk check is complete. No issues have been found. (View Details)


How to search for feed name instead of all articles?

I have a lot of RSS feed urls in the urls files,
I find it not very convenient to navigate through them.
When I press / to search the feeds name, the result contains the feed articles, but mixed with articles from other feed.
Do newsboat have some feature to search only feeds names?
Something like nnn's type-on-nav function, to filter out the unmatched feeds name?
Thanks!

I don't think Newsboat has that feature at the moment.
However, it does have 2 features which might come close enough:

The goto-title operation allows you to go to the next feed which contains the entered text as a part of the title.
By default, it is not bound to any key combination, so you will have to add a bind-key line in your config, e.g.:bind-key g goto-title

The filter language allows you to filter the list of feeds based on attributes like feedtitle.
To use it, press shift+F to open the filter editor, enter feedtitle =~ "part of the title", and press ENTER.
This will filter the feeds by title, based on the entered regex.
If you want to get back to the full list of feeds, press ctrl+f to clear the filter.
For move filter options, see the filter documentation

Both options are really great!!
Did not know newsboat have the goto-title key!
Thank you very much!!!


Restrict to user locations

Features

Locations on the ‘User Locations’ Page  are now restricted to the locations assigned to the user’s merchant

[Delivers#109350082]

What about checks during location update?

@wnowicki Ready

@wnowicki Ready


spacing in navbar

i think there is unnecessary spacing in the navbar making it look less professional. so i want to allign home etc. tabs to the right with appropriate spacing in between. furthermore i would like to change the text size of tabs in navbar to make it look more pleasing. kindly assign this task to me under gssoc-ext and hacktoberfest-accepted

@yatulearn I would like to work on this issue under gssoc-extd. Kindly assign me this issue and put necessary labels and levels to this issue.


Import [Warning]: Game files wasn't found

I imported every single file of the game, and it gives me "Game files wasn't found", what could be the cause of this?

Unity 2020.x is unsupported.
If game using another engine version, please share some files.

Unity 2020.x is unsupported.
If game using another engine version, please share some files.

Support for Unity versions up to 2020.2.0 has been recently added to my AssetRipper fork.


After choosing an area for drag and drop,  not all objects in the defined area are moving along as I drag it.

                >userAgent: Mozilla/5.0 (Windows NT 10.0; Win64;

After choosing an area for drag and drop,  not all objects in the defined area are moving along as I drag it.

                >userAgent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/<IP_ADDRESS> Safari/537.36
                email: undefined
                username: romer.benitez

If not just sticky notes, such as link icons? How about other widget object types?


Speech CLI doesn't support apple silicon so well.

I am using an apple silicon laptop.
I installed the .NET 6 successfully. And I installed the speech CLI successfully too:
darwin@Darwins-MBP ~ % dotnet tool install --global Microsoft.CognitiveServices.Speech.CLI

Welcome to .NET 6.0!
---------------------
SDK Version: 6.0.400

Telemetry
---------
The .NET tools collect usage data in order to help us improve your experience. It is collected by Microsoft and shared with the community. You can opt-out of telemetry by setting the DOTNET_CLI_TELEMETRY_OPTOUT environment variable to '1' or 'true' using your favorite shell.

Read more about .NET CLI Tools telemetry: https://aka.ms/dotnet-cli-telemetry

----------------
Installed an ASP.NET Core HTTPS development certificate.
To trust the certificate run 'dotnet dev-certs https --trust' (Windows and macOS only).
Learn about HTTPS: https://aka.ms/dotnet-https
----------------
Write your first app: https://aka.ms/dotnet-hello-world
Find out what's new: https://aka.ms/dotnet-whats-new
Explore documentation: https://aka.ms/dotnet-docs
Report issues and find source on GitHub: https://github.com/dotnet/core
Use 'dotnet --help' to see available commands or visit: https://aka.ms/dotnet-cli
--------------------------------------------------------------------------------------
Tools directory '/Users/darwin/.dotnet/tools' is not currently on the PATH environment variable.
If you are using zsh, you can add it to your profile by running the following command:

cat << \EOF >> ~/.zprofile
# Add .NET Core SDK tools
export PATH="$PATH:/Users/darwin/.dotnet/tools"
EOF

And run `zsh -l` to make it available for current session.

You can only add it to the current session by running the following command:

export PATH="$PATH:/Users/darwin/.dotnet/tools"

You can invoke the tool using the following command: spx
Tool 'microsoft.cognitiveservices.speech.cli' (version '1.23.0') was successfully installed.

But it seems the speech CLI doesn't support apple silicon so well:
darwin@Darwins-MBP ~ % export PATH="$PATH:/Users/darwin/.dotnet/tools"
darwin@Darwins-MBP ~ % spx
Unhandled exception. System.BadImageFormatException: Could not load file or assembly '/Users/darwin/.dotnet/tools/.store/microsoft.cognitiveservices.speech.cli/1.23.0/microsoft.cognitiveservices.speech.cli/1.23.0/tools/net6.0/any/spx.dll'. An attempt was made to load a program with an incorrect format.

File name: '/Users/darwin/.dotnet/tools/.store/microsoft.cognitiveservices.speech.cli/1.23.0/microsoft.cognitiveservices.speech.cli/1.23.0/tools/net6.0/any/spx.dll'
zsh: abort      spx

I don't know if it is a doc issue or a production issue.

Document Details
⚠ Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

ID: 91e2ab62-8804-694f-f51a-ab5cef82c2d6
Version Independent ID: 3eac47ce-d629-6a1f-914b-ce60ab13ebae
Content: Quickstart: The Speech CLI - Speech service - Azure Cognitive Services
Content Source: articles/cognitive-services/Speech-Service/spx-basics.md
Service: cognitive-services
Sub-service: speech-service
GitHub Login: @eric-urban
Microsoft Alias: eur

@darwin-xu
Thanks for the feedback! We are currently investigating and will update you shortly.

Hello @darwin-xu  Could you please share more details of your system, what's your versison? Thanks.

Sure no problem.
macOS version: 12.5.1
dotnet version: 6.0.400
microsoft.cognitiveservices.speech.cli version: version '1.23.0'
The spx.dll is in PE32+ format, I don't know if it supports apple silicon or not.
darwin@Darwins-MBP ~ % file /Users/darwin/.dotnet/tools/.store/microsoft.cognitiveservices.speech.cli/1.23.0/microsoft.cognitiveservices.speech.cli/1.23.0/tools/net6.0/any/spx.dll
/Users/darwin/.dotnet/tools/.store/microsoft.cognitiveservices.speech.cli/1.23.0/microsoft.cognitiveservices.speech.cli/1.23.0/tools/net6.0/any/spx.dll: PE32+ executable (console) x86-64 Mono/.Net assembly, for MS Windows

I have another macOS with intel chip, which works totally fine for speech CLI.

Hello @darwin-xu
Yes, it works for my old MBP as well, I have bring this issue to product team for investigation and fixing. Thanks for reporting this.  I will update here once I get any news.

@YutongTie-MSFT have you reproduced the issue on the apple silicon macOS?

Hello @darwin-xu
I have no latest version MBP so I have escalated this issue to product team, would you like a support ticket to have a support engineer help you to check on this issue as well?

Yes, please.

Hello @darwin-xu
Could you please send me an email at<EMAIL_ADDRESS>with your Azure Subscription ID?
From doc point, I will close it at this moment since we have nothing to do with doc now.
We will now proceed to close this thread. If there are further questions regarding this matter, please respond here and @YutongTie-MSFT and we will gladly continue the discussion.

I am having this issue also, did this get resolved?

I am also experiencing this issue. Any updates, @YutongTie-MSFT?

I've just come across this issue using cognitiveservices.speech.cli  '1.26.0'. I got the same error when I invoked the 'spx' command.
dotnet --info

.NET SDK (reflecting any global.json):
Version:   6.0.407
Commit:    d8659ea151
Runtime Environment:
OS Name:     Mac OS X
OS Version:  13.2
OS Platform: Darwin
RID:         osx.13-arm64

As a workaround, you can install dotnet-sdk-6.0.404-osx-x64.pkg (or any other x64 version) on an Apple silicon mac and run it via Rosetta:
$ uname -m
arm64

$ dotnet --info
.NET SDK (reflecting any global.json):
 Version:   6.0.404
 Commit:    be4f3ec411

Runtime Environment:
 OS Name:     Mac OS X
 OS Version:  ...
 OS Platform: Darwin
 RID:         osx-x64
 Base Path:   /usr/local/share/dotnet/x64/sdk/6.0.404/

global.json file:
  Not found

Host:
  Version:      6.0.12
  Architecture: x64
  Commit:       02e45a41b7

.NET SDKs installed:
  6.0.404 [/usr/local/share/dotnet/x64/sdk]

...

We are having the same issue as well. What's the status on this issue?

We are having the same issue as well. What's the status on this issue?

+1

One year later this is still an open issue - M3 Max


Add documentation about how to let Rust do logging and let Dart get those logs

Context:
https://github.com/fzyzcjy/flutter_rust_bridge/issues/443#issuecomment-1147261290 , where @thomas725 asks about this.

I can paste my own code that works in my production environment here.
Btw my code not only logs to Dart, but also logs to Android/iOS "standard" logging as well.
api.rs
pub struct LogEntry {
    pub time_millis: i64,
    pub level: i32,
    pub tag: String,
    pub msg: String,
}

pub fn create_log_stream(s: StreamSink<LogEntry>) -> Result<()> {
    logger::SendToDartLogger::set_stream_sink(s);
    Ok(())
}

logger.rs
use std::sync::Once;
use std::time::{Duration, SystemTime, UNIX_EPOCH};

use flutter_rust_bridge::StreamSink;
use lazy_static::lazy_static;
use log::{error, info, warn, Log, Metadata, Record};
use parking_lot::RwLock;
use simplelog::*;

use crate::frb::api::LogEntry;

static INIT_LOGGER_ONCE: Once = Once::new();

pub fn init_logger() {
    // https://stackoverflow.com/questions/30177845/how-to-initialize-the-logger-for-integration-tests
    INIT_LOGGER_ONCE.call_once(|| {
        let level = if cfg!(debug_assertions) {
            LevelFilter::Debug
        } else {
            LevelFilter::Warn
        };

        assert!(
            level <= log::STATIC_MAX_LEVEL,
            "Should respect log::STATIC_MAX_LEVEL={:?}, which is done in compile time. level{:?}",
            log::STATIC_MAX_LEVEL,
            level
        );

        CombinedLogger::init(vec![
            Box::new(SendToDartLogger::new(level)),
            Box::new(MyMobileLogger::new(level)),
            // #[cfg(not(any(target_os = "android", target_os = "ios")))]
            TermLogger::new(
                level,
                ConfigBuilder::new()
                    .set_time_format_str("%H:%M:%S%.3f")
                    .build(),
                TerminalMode::Mixed,
                ColorChoice::Auto,
            ),
        ])
        .unwrap_or_else(|e| {
            error!("init_logger (inside 'once') has error: {:?}", e);
        });
        info!("init_logger (inside 'once') finished");

        warn!(
            "init_logger finished, chosen level={:?} (deliberately output by warn level)",
            level
        );
    });
}

lazy_static! {
    static ref SEND_TO_DART_LOGGER_STREAM_SINK: RwLock<Option<StreamSink<LogEntry>>> =
        RwLock::new(None);
}

pub struct SendToDartLogger {
    level: LevelFilter,
}

impl SendToDartLogger {
    pub fn set_stream_sink(stream_sink: StreamSink<LogEntry>) {
        let mut guard = SEND_TO_DART_LOGGER_STREAM_SINK.write();
        let overriding = guard.is_some();

        *guard = Some(stream_sink);

        drop(guard);

        if overriding {
            warn!(
                "SendToDartLogger::set_stream_sink but already exist a sink, thus overriding. \
                (This may or may not be a problem. It will happen normally if hot-reload Flutter app.)"
            );
        }
    }

    pub fn new(level: LevelFilter) -> Self {
        SendToDartLogger { level }
    }

    fn record_to_entry(record: &Record) -> LogEntry {
        let time_millis = SystemTime::now()
            .duration_since(UNIX_EPOCH)
            .unwrap_or_else(|_| Duration::from_secs(0))
            .as_millis() as i64;

        let level = match record.level() {
            Level::Trace => Self::LEVEL_TRACE,
            Level::Debug => Self::LEVEL_DEBUG,
            Level::Info => Self::LEVEL_INFO,
            Level::Warn => Self::LEVEL_WARN,
            Level::Error => Self::LEVEL_ERROR,
        };

        let tag = record.file().unwrap_or_else(|| record.target()).to_owned();

        let msg = format!("{}", record.args());

        LogEntry {
            time_millis,
            level,
            tag,
            msg,
        }
    }

    // ref: Dart [front_log]包
    const LEVEL_TRACE: i32 = 5000;
    const LEVEL_DEBUG: i32 = 10000;
    const LEVEL_INFO: i32 = 20000;
    const LEVEL_WARN: i32 = 30000;
    const LEVEL_ERROR: i32 = 40000;
}

impl Log for SendToDartLogger {
    fn enabled(&self, _metadata: &Metadata) -> bool {
        true
    }

    fn log(&self, record: &Record) {
        let entry = Self::record_to_entry(record);
        if let Some(sink) = &*SEND_TO_DART_LOGGER_STREAM_SINK.read() {
            sink.add(entry);
        }
    }

    fn flush(&self) {
        // no need
    }
}

impl SharedLogger for SendToDartLogger {
    fn level(&self) -> LevelFilter {
        self.level
    }

    fn config(&self) -> Option<&Config> {
        None
    }

    fn as_log(self: Box<Self>) -> Box<dyn Log> {
        Box::new(*self)
    }
}

pub struct MyMobileLogger {
    level: LevelFilter,
    #[cfg(target_os = "ios")]
    ios_logger: oslog::OsLogger,
}

impl MyMobileLogger {
    pub fn new(level: LevelFilter) -> Self {
        MyMobileLogger {
            level,
            #[cfg(target_os = "ios")]
            ios_logger: oslog::OsLogger::new("vision_utils_rs"),
        }
    }
}

impl Log for MyMobileLogger {
    fn enabled(&self, _metadata: &Metadata) -> bool {
        true
    }

    #[allow(unused_variables)]
    fn log(&self, record: &Record) {
        #[cfg(any(target_os = "android", target_os = "ios"))]
        let modified_record = {
            let override_level = Level::Info;

            record.to_builder().level(override_level).build()
        };

        #[cfg(target_os = "android")]
        android_logger::log(&modified_record);

        #[cfg(target_os = "ios")]
        self.ios_logger.log(&modified_record);
    }

    fn flush(&self) {
        // no need
    }
}

impl SharedLogger for MyMobileLogger {
    fn level(&self) -> LevelFilter {
        self.level
    }

    fn config(&self) -> Option<&Config> {
        None
    }

    fn as_log(self: Box<Self>) -> Box<dyn Log> {
        Box::new(*self)
    }
}

mycode.dart, where things like Log.d is a pure-Dart logger that I wrote for my internal usage. You may use print etc.
class _VisionUtilsRsImplExtended extends VisionUtilsRsImpl
    with
        FlutterRustBridgeSetupMixin,
        FlutterRustBridgeTimeoutMixin,
        VisionUtilsFrbLogMixin,
        VisionUtilsFrbErrorReportMixin {
  static const _kTag = 'VisionUtilsRsImplExtended';

  _VisionUtilsRsImplExtended._raw(super.inner) : super.raw() {
    Log.d(_kTag, 'inside constructor, call setupMixinConstructor');
    setupMixinConstructor();
  }

  @override
  Future<void> setup() async {
    final config = await visionUtilsConfig;

    await rustSetUp(
        release: config.release, pseudoSessId: config.pseudoSessId, hint: FlutterRustBridgeSetupMixin.kHintSetup);

    createLogStream().listen((event) {
      Log.instance.log(event.level, _kRustTagPrefix + event.tag, '${event.msg}(rust_time=${event.timeMillis})');
    });
  }

  @override
  Duration? get timeLimitForExecuteNormal {
    return isInDebugMode ? const Duration(seconds: 30) : const Duration(seconds: 15);
  }

  @override
  void log(String message) => Log.d(_kTag, message);
}

@internal
mixin VisionUtilsFrbLogMixin<T extends FlutterRustBridgeWireBase> on FlutterRustBridgeBase<T> {
  static const _kTag = 'VisionUtilsFrbLogMixin';

  @override
  Future<S> executeNormal<S>(FlutterRustBridgeTask<S> task) async {
    final startTime = DateTime.now();
    Log.d(_kTag, '(Flutter) executeNormal [${task.debugName}] start');

    final result = await super.executeNormal(task);

    Log.d(_kTag,
        '(Flutter) executeNormal [${task.debugName}] end delta_time=${DateTime.now().difference(startTime).inMilliseconds}ms');

    return result;
  }
}

/cc @thomas725

Btw my code not only logs to Dart, but also logs to Android/iOS "standard" logging as well.
that's a lovely feature, thank you for sharing!

I found I could get rid of most errors by adding those 3 lines to my Cargo.toml file:
lazy_static = "1.4.0"
log = "0.4.17"
simplelog = "0.12.0"

Also since my flutter_rust_bridge project layout is copied from https://github.com/Desdaemon/flutter_rust_bridge_template I had to remove :frb: from use crate::frb::api::LogEntry;
I believe use parking_lot::RwLock; is referencing some private code of your's, but I guess replacing with use std::sync::RwLock; should give me the same result.
Now I got 3 errors left:

no method named set_time_format_str found for struct simplelog::ConfigBuilder in the current scope (line 37)
no method named is_some found for enum Result in the current scope
method not found in Result<RwLockWriteGuard<'_, Option<StreamSink<api::LogEntry>>>, PoisonError<RwLockWriteGuard<'_, Option<StreamSink<api::LogEntry>>>>> (line 67)
type Result<RwLockWriteGuard<'_, Option<StreamSink<api::LogEntry>>>, PoisonError<RwLockWriteGuard<'_, Option<StreamSink<api::LogEntry>>>>> cannot be dereferenced (lines 69 & 125)

btw parking_lot is a public Rust library, find it using Google

no method named set_time_format_str found for struct simplelog::ConfigBuilder in the current scope (line 37)

That is a method in crate simplelog

btw parking_lot is a public Rust library, find it using Google

oh, thanks for the hint.. it's name sounds very domain specific ;)

That is a method in crate simplelog

do I maybe need an older version? I've added simplelog = "0.12.0".

Sure. Those are minor details and surely you can choose your own :)

I would have liked to have access to the logger level definitions in flutter, so I though I move them from logger.rs SendToDartLogger struct over into my api.rs LogEntry struct + adding pub keyword to each of them, but now the flutter_rust_bridge_codegen step fails with:
WARN  lib_flutter_rust_bridge_codegen::commands] command="sh" "-c" "dart pub global run ffigen --config \"/tmp/.tmpdxyP7q\"" stdout=Running in Directory: '/'
    Input Headers: [/tmp/.tmpNcb8i7.h]
     stderr=Unhandled exception:
    FileSystemException: Cannot create file, path = 'temp_for_macros.hpp' (OS Error: Permission denied, errno = 13)

Did I do something stupid or is support for pub const within a struct a not yet implemented feature of the flutter_rust_bridge?

"Permission denied" - sounds like a separate problem. Maybe create a new issue. And check do you have /tmp folder?

sounds like a separate problem. Maybe create a new issue.

your right, I did, see: https://github.com/fzyzcjy/flutter_rust_bridge/issues/494

And check do you have /tmp folder?

I do. Otherwise I guess flutter_rust_bridge_codegen wouldn't be able to complete successfully with that api.rs pub struct impl block with pub consts commented out, since it always writes /tmp/*.h files.

How do I use the logger on the rust side after the stream has been setup by the dart side?

See how rust do standard logging. use log::info; info!("wow");

Oh! Nice! Thank you!
To get it to compile for android, I had to remove the modified_record in lines 173 to 177 and use the original record instead, because:
error[E0599]: no method named `to_builder` found for reference `&Record<'_>` in the current scope

Are you using a different version of the log crate then the latest = 0.4.17? Or are you using a different rust compiler? Mine is 1.60.0 (7737e0b5c 2022-04-04).

log 0.4.14 in my case, but anyway just modify code accordingly

well that's strange, even if I specify version 0.4.14 in my Cargo.toml file, delete Cargo.lock and run cargo update in my rust crate's folder, it regenerates a Cargo.lock that again uses the log crate version 0.4.17

I would like to add something to this thread that might be useful for relative beginners, like me. My IDE kept complaining about the following code snipped, because IntoDart is not implemented for LogEntry, which is true.
pub struct LogEntry {
    pub time_millis: i64,
    pub level: i32,
    pub tag: String,
    pub msg: String,
}

pub fn create_log_stream(s: StreamSink<LogEntry>) -> anyhow::Result<()> {
    Ok(())
}

Don't try implementing this yourself, because flutter_rust_bridge will generate it for you. It does sound kind of obvious now that I'm writing this down, but it took me an hour to figure this out... 😅

Don't try implementing this yourself, because flutter_rust_bridge will generate it for you. It does sound kind of obvious now that I'm writing this down, but it took me an hour to figure this out...

Feel free to add some doc at proper places and make a PR :)

@thomas725 That is a rust-language problem unrelated to my package indeed :) Try asking on StackOverflow, the logging package, etc

Feel free to add some doc at proper places and make a PR :)

Done :-) (#506)

I briefly update the doc to point to this issue, since this issue contains all code already.
https://github.com/fzyzcjy/flutter_rust_bridge/blob/master/book/src/feature/stream.md


[dy] Support serialize Polars dataframe

Description

Resolves https://github.com/mage-ai/mage-ai/issues/4102.
In order to serialize a polars dataframe, we have to write some metadata about the output variable so that we can determine whether or not to use polars or pandas when serializing. This PR adds a type.json file to the variable directory that currently just stores the type of the variable which will be used when reading the output data. If there is no file, we will fallback to the previous logic.
How Has This Been Tested?

[x] Tested locally with the example in the issue

[x] Tested with S3 remote variable directory
[x] Unit test

Checklist

[x] The PR is tagged with proper labels (bug, enhancement, feature, documentation)
[x] I have performed a self-review of my own code
[x] I have added unit tests that prove my fix is effective or that my feature works
[x] I have commented my code, particularly in hard-to-understand areas
[ ] I have made corresponding changes to the documentation
[ ] If new documentation has been added, relative paths have been added to the appropriate section of docs/mint.json

cc: @wangxiaoyou1993

@wangxiaoyou1993 Thanks for catching those issues. I tested it more with S3 and found some issues, so I fixed those as well as addressed your comments. I also changed the name of the file to type.json to differentiate it.

@wangxiaoyou1993 addressed your comments


Rename SHAMapStoreImp::stopping() to SHAMapStoreImp::handleHealth()

Context of Change
A recent change modified the name of a member function from SHAMapStoreImp::health() to SHAMapStoreImp::stopping().  Personally, I find the name change to stopping() misleads me when I read the source code.  The function stopping() performs the job of looking at the health of rippled and sleeping the thread if rippled is not sufficiently healthy.
I would never expect a function named stopping() that returns a bool to sleep the thread.
This pull request renames that function to SHAMapStoreImp::handleHealth().  To assist with readability, handleHealth() returns an enum of either stopping or keepGoing.  If handleHealth() returns stopping, then rippled is attempting to shut down and appropriate actions should be taken.
Type of Change

[x] Refactor (non-breaking change that only restructures code)

@nbougalis, I disagree that the function's primary purpose is to determine whether we should stop.  I believe the function's primary purpose is to sleep the thread if rippled is currently unhealthy.  The thread may be awakened because the server is stopping, but that is not the primary point of the function.  Expand the diff to show the internals of the function so you can see what's going on.
I'm not arguing that handleHealth is the best name.  But neither healthy nor stopping represent the intent behind the function as I currently understand it.  As it stands the return value from the function is a side effect of the primary purpose of the function.

@scottschurr I'd love to have the word wait in the name somewhere - or something that implies that this function can sleep.

or yield()?

Maybe waitForHealth()?  If that has too many characters, possibly healthWait()?

@scottschurr I'm fine with either of those. It's hard to name this function because it does two things - it waits for a condition and it returns if we're stopping. I understand why it does that, but it makes it hard to put a name to it. Anyway, either of those names sounds good to me. Thanks!

Rebased to 1.9.2.

@nbougalis, this pull request how has two (non-authorized) approvals, and I've squashed the commits.  So I think this pull request is ready to go.  I'll have to leave it to you to mark the pull request as passed, since I no longer have those permissions.  Thanks.

Rebased to 1.10.0-b1.  @nbougalis, I believe this pull request is ready to be marked as passed.  Please let me know if it needs any changes.  Thanks.


Consider including 'awesome' prefix in project name

It's common for these kinds of lists (meta-list) to start with "awesome".  I think it might make it more discoverable.

@alanpearce oooh, agreed - awesome-checker-services can be done, I think GitHub redirects old repo traffic to the new one as well?

According to the documentation, it does so for everything.

Done!


[NT-1741][NT-1743][NT-1744] Adding Segment SDK and deprecating Koala

📲 What
Analytics at Kickstarter, prior to this PR, entailed the use of two internal clients. Both Koala and our DataLake clients send events to destinations our Insights team can digest. There are a couple of different things happening in this PR that are all closely related to one another. First, we are adding another dependency that will become our new go-to analytics tool. Segment will be added as a client while we simultaneously deprecate Koala. Furthermore, we are getting rid of the Koala namespace entirely and moving forward with KSRAnalytics. To summarize, we are:

Deprecating Koala
Adding Segment and implementing its basic functionality
Renaming all files and objects that were previously associated with the Koala namespace
Fixing a lot of tests

🤔 Why
Kickstarter is moving forward with Segment as our primary analytics tool and this involves not only removing Koala but also incrementally adding functionality that sends  useful data to Segment.
🛠 How
Segment  provides an SDK with handy methods, which we implement in here.