open a file in a new tab

 this topic is not fixed at all dude. why closed? it's a bug not a question and still there. the only way to open a new tab is to get back in navigation tabs history, after having double click on the file. Then another tab is opened https://github.com/microsoft/vscode/issues/193027

Please read about Preview Mode and how to turn it off if you don't want it.
https://code.visualstudio.com/docs/getstarted/userinterface#_preview-mode
/duplicate

Thanks for creating this issue! We figured it's covering the same as another one we already have. Thus, we closed this one as a duplicate. You can search for similar existing issues. See also our issue reporting guidelines.
Happy Coding!

Normally with the preview mode if you double-click it will open a new tab

https://code.visualstudio.com/docs/getstarted/userinterface#_preview-mode
"When you start editing the file or use double-click to open the file from the Explorer, a new Tab is dedicated to that file." → no = bug

ok I'm done I will turn it off


Invalid property 'allowFullScreen' found on tag 'iframe'

Appeared in v7.31.9
https://developer.mozilla.org/en-US/docs/Web/HTML/Element/iframe#attr-allowfullscreen

Will be fixed by #3455.


bug: FloatTitle is overwritten when loading Oil

Did you check the docs and existing issues?

[X] I have read the docs
[X] I have searched the existing issues

Neovim version (nvim -v)
0.9.2
Operating system/version
Fedora Silverblue 38
Describe the bug
At https://github.com/stevearc/oil.nvim/blob/977da9ac6655b4f52bc26f23f584d9553f419555/lua/oil/init.lua#L714, the code checks if FloatTitle is defined, and if not sets up a definition for this. At least on NeoVim 0.9.2, this line always returns false (e.g. lua print(vim.inspect(pcall(vim.api.nvim_get_hl_by_name, "FloatTitle"))) prints false), thus overwriting the FloatTitle definition. This is because nvim_get_hl_by_name is deprecated and does nothing and its replacement, nvim_get_hl, takes two arguments: a namespace ID, and a list of options.
Steps To Reproduce

Use a theme that defines something like hi FloatTitle guifg=red gui=bold
Load oil on NeoVim 0.9.2 (or 0.9.0 or newer based on when nvim_get_hl_by_name was deprecated)
Run hi FloatTitle, observe the lack of gui=bold

Expected Behavior
FloatTitle is left alone.
Directory structure
No response
Repro
-- save as repro.lua
-- run with nvim -u repro.lua
-- DO NOT change the paths
local root = vim.fn.fnamemodify("./.repro", ":p")

-- set stdpaths to use .repro
for _, name in ipairs({ "config", "data", "state", "runtime", "cache" }) do
    vim.env[("XDG_%s_HOME"):format(name:upper())] = root .. "/" .. name
end

-- bootstrap lazy
local lazypath = root .. "/plugins/lazy.nvim"
if not vim.loop.fs_stat(lazypath) then
    vim.fn.system({
        "git",
        "clone",
        "--filter=blob:none",
        "--single-branch",
        "https://github.com/folke/lazy.nvim.git",
        lazypath,
    })
end
vim.opt.runtimepath:prepend(lazypath)

vim.cmd("hi def FloatTitle guifg=red gui=bold")

-- install plugins
local plugins = {
    "folke/tokyonight.nvim",
    {
        "stevearc/oil.nvim",
        config = function()
            require("oil").setup({
                -- add any needed settings here
            })
        end,
    },
    -- add any other plugins here
}
require("lazy").setup(plugins, {
    root = root .. "/plugins",
})

-- add anything else here

Did you check the bug with a clean config?

[X] I have confirmed that the bug reproduces with nvim -u repro.lua using the repro.lua file above.

You definitely found a bug, but the diagnosis is off. While nvim_get_hl_by_name is deprecated, it does still function. That lua definition is just for typechecking and (possibly?) documentation generation. The real implementation is in C and definitely still works.
The issue here was that I was using pcall to check if the function returned an error, and it always did so because I was mistakenly not passing in the mandatory second argument.
Thanks for the report!

@stevearc Thanks! :tada:


WIP: TLS1.3 FFDHE Support

Added FFDHE Key exchange Support in TLS1.3 KeyShare extension.

Checklist

[x] tests are added or updated

I'm not actually sure that this is useful. It's my understanding
that FFDHE really was too late, and that X25519 and X448 are more
useful.

Changed target branch to master. And rebased source branch to master and cherry-picked my changes. Requesting to review.

The travis failure is relevant. Please run "make update" and commit the result. CLA still outstanding.

In theory it might be useful to use FFDHE when there are quantum computers big enough to break the smaller size ECDHE DLP but not big enough to break the larger size DLP for FFDHE. Of course the time window when this condition will be true might be small enough so it would not make much sense to implement and use FFDHE anyway.
The other major TLS libraries already implement it, but it is of course not necessary for interop with them as they also support ECDHE including the X25519.

Personally I'm of the view that we should support it. It was always the intention that we would but it was never seen as a big enough priority to actually get done.

@mattcaswell Committed make update changes. Individual CLA I have signed and sent the photograph of it in mail yesterday.

Hmmm...I don't seem to have received the CLA??

Travis failed and the failure does seem relevant.
test/sslapitest.c:3513:51: error: variable 'kexch_groups_size' may be uninitialized when used here [-Werror,-Wconditional-uninitialized]
    if ((SSL_set1_groups(serverssl, kexch_groups, kexch_groups_size) != 1)
                                                  ^~~~~~~~~~~~~~~~~
include/openssl/ssl.h:1408:42: note: expanded from macro 'SSL_set1_groups'
        SSL_ctrl(ctx,SSL_CTRL_SET_GROUPS,glistlen,(char *)(glist))
                                         ^~~~~~~~
test/sslapitest.c:3491:26: note: initialize the variable 'kexch_groups_size' to silence this warning
    int kexch_groups_size;
                         ^
                          = 0
test/sslapitest.c:3513:37: error: variable 'kexch_groups' may be uninitialized when used here [-Werror,-Wconditional-uninitialized]
    if ((SSL_set1_groups(serverssl, kexch_groups, kexch_groups_size) != 1)
                                    ^~~~~~~~~~~~
include/openssl/ssl.h:1408:60: note: expanded from macro 'SSL_set1_groups'
        SSL_ctrl(ctx,SSL_CTRL_SET_GROUPS,glistlen,(char *)(glist))
                                                           ^~~~~
test/sslapitest.c:3490:22: note: initialize the variable 'kexch_groups' to silence this warning
    int *kexch_groups;
                     ^
                      = NULL

Fixed Testcase compilation issues and updated. Regarding CLA, I forwarded the mail again to<EMAIL_ADDRESS>Please check.

CLA received - thanks. Close/reopen to kick CLA bot.

this fixes #6519

Updated dh_key2buf to add padding if incase DH public key size is lesser then Size of P. As per Section <IP_ADDRESS> in RFC 8446.

The code truncates the leading zero bytes of the key share.
reproducer is in scripts/test-tls13-dhe-shared-secret-padding.py in tlsfuzzer
also, I'm not sure, but some failures also look like the padding of shared secret isn't solved (I'm getting quite regular decryption failures when using ffdhe)
also, any reason why the ffdhe groups are not enabled by default? especially on server side?

I'm not sure we want to add it to the defaults; I know it was a TODO comment.  I wonder if Matt has another view now?

I wonder if the ability to use ffdhe2048 or similar for -groups and Groups shouldn't be mentioned in SSL_CONF_cmd(3).
While the man page doesn't list all possibilities explicitly, it does give examples for the two main classes (ECDHE and EdDHE) of them...

Can you confirm that with TLS 1.2 we do not negotiate those groups? A test with TLS 1.2 would be nice.

You should not even offer the groups for 1.2 clients.

If you offer the group, a TLS 1.2 server should not understand them as far as I know. I think that if you want to use those group in TLS 1.2, you should do it like it was done in TLS 1.2, which includes sending the group in the proper message. But we do not want to support FFDHE in TLS 1.2.
So I want to make sure that an OpenSSL server when it's configured as TLS 1.2 does not interpret the groups being send as part of the group extension will decide to use that group. When acting as client and a server picks that group it should also reject it.

Ping @raja-ashok - looks like there are some outstanding comments for you to resolve.

@kroeckx Added checks to prevent sending FFDHE in TLS1.2 and lower versions client hello. Please check once.

@raja-ashok I don't see fixes for the padding issues...

@tomato42 I started checking. I will fix and update you.

you can use scripts/test-dhe-no-shared-secret-padding.py and scripts/test-ecdhe-padded-shared-secret.py in tlsfuzzer to verify the the behaviour in TLS 1.2 and earlier doesn't regress

@tomato42 Result of scripts/test-dhe-no-shared-secret-padding.py shows all testcase passed except 2 SSLv3 testcases. Can you please guide what is the issue in padding.

SSLv3 test cases are likely failing because SSLv3 is disabled
check if you can run openssl s_client -ssl3 -connect google.com:4433 and see if it is not failing with "unknown option -ssl3" – if it is, sslv3 is unsupported so test cases that depend on it are expected to fail, you can safely ignore those failures, the version dependent tests are there for completeness, not because they are necessary for OpenSSL in particular
but I can't tell for sure without knowing more: which configuration options did you use for compile? what are the error messages printed by tlsfuzzer?

@tomato42 Yes. SSLv3 cases are failing because SSLv3 is disabled in my OpenSSL build. Other than that I am not able to find any other padding related failures in scripts/test-dhe-no-shared-secret-padding.py.

good, but remember that this is just regression test, the test for the new code is in scripts/test-tls13-dhe-shared-secret-padding.py, as I wrote in https://github.com/openssl/openssl/pull/8178#issuecomment-465546572

Is the WIP title for this still appropriate? Are the padding issues now resolved?

@mattcaswell @tomato42 Yes. Padding issue is resolved. Added padding check while parsing key_share extn.
I will squash all the commits to 2 commit. One for changes and the another one for testcode changes.
Other than that ordering of ffdhe in default supported group is not conlcuded, which is raised by @kroeckx

@mattcaswell @tomato42 Yes. Padding issue is resolved. Added padding check while parsing key_share extn.

but the problem I mentioned is not that openssl doesn't check for that error (honestly, I didn't test that), the problem is that openssl doesn't pad key shares or shared secret when it should
because of that lack of padding in shared secret in TLS 1.3, the derived encryption keys are incorrect and the tlsfuzzer rejects the encrypted messages from OpenSSL server:
...
"TLS 1.3 with ffdhe2048" repeat 454...
OK

"TLS 1.3 with ffdhe2048" repeat 455...
OK

"TLS 1.3 with ffdhe2048" repeat 456...
OK

"TLS 1.3 with ffdhe2048" repeat 457...
Error encountered while processing node <tlsfuzzer.expect.ExpectEncryptedExtensions object at 0x7f86c552aa10> (child: <tlsfuzzer.expect.ExpectCertificate object at 0x7f86c552aa50>) with last message being: None
Error while processing
Traceback (most recent call last):
  File "scripts/test-tls13-dhe-shared-secret-padding.py", line 211, in main
    runner.run()
  File "/home/hkario/dev/tlsfuzzer/tlsfuzzer/runner.py", line 184, in run
    header, parser = self.state.msg_sock.\
  File "/home/hkario/dev/tlsfuzzer/tlslite/messagesocket.py", line 102, in recvMessageBlocking
    for res in self.recvMessage():
  File "/home/hkario/dev/tlsfuzzer/tlslite/messagesocket.py", line 84, in recvMessage
    for ret in self.recvRecord():
  File "/home/hkario/dev/tlsfuzzer/tlslite/recordlayer.py", line 922, in recvRecord
    data = self._decryptAndUnseal(header, data)
  File "/home/hkario/dev/tlsfuzzer/tlslite/recordlayer.py", line 817, in _decryptAndUnseal
    raise TLSBadRecordMAC("Invalid tag, decryption failure")
TLSBadRecordMAC: Invalid tag, decryption failure

so, no, I'm afraid that it's not fixed as of aaa0710eee0

Other than that ordering of ffdhe in default supported group is not conlcuded, which is raised by @kroeckx

what about documentation?

@tomato42 I checked this failure for this particular case(ffdhe 2048) OpenSSL sent 256 bytes of public key. And padding is not required in this case. So I think this Bad Record Mac error is related to something else, I will check that.
There was another test case in which public key was 255 bytes, in which OpenSSL added padding bytes and sent 256 bytes key share. Attached a snapshot please go through.

@tomato42 I checked this failure for this particular case(ffdhe 2048) OpenSSL sent 256 bytes of public key. And padding is not required in this case. So I think this Bad Record Mac error is related to something else, I will check that.

yes, I'm quite sure that it's related to the calculated shared secret, the result of the DH key exchange that is then fed to the HKDF-Extract function to calculate Handshake Secret, see https://tools.ietf.org/html/rfc8446#page-93
I'm quite sure that OpenSSL does not pad that input (as it must be unpadded in TLS 1.2, but must be padded in TLS 1.3)

@raja-ashok what is the status of the PR? Have the issue identified by @tomato42 been addressed?

yes, that last patch – 8a7a0da – does seem to fix padding issue, test-tls13-dhe-shared-secret-padding.py and test-dhe-no-shared-secret-padding.py pass for me now
documentation changes are still missing

@tomato42 Can you please guide which section of documentation need to update for this change. No new APIs are introduced. Should I need to update man page of SSL_CTX_set1_groups ?

@tomato42 Can you please guide which section of documentation need to update for this change. No new APIs are introduced. Should I need to update man page of SSL_CTX_set1_groups ?

as I wrote previously, I had SSL_CONF_cmd(3) in mind, description of -groups and Groups specifically. Yes, updating SSL_CTX_set1_groups(3) would be nice too.

@tomato42 Please review the updates on docs.

@mattcaswell All the issues are closed for this PR and it is ready for merge. Please check and process.

@raja-ashok why did you remove ffdhe2048 from default? Matt later agreed that it should be enabled: https://github.com/openssl/openssl/pull/8178/files#r289905969

Added ffdhe2048 back to the default list.

@mattcaswell Would you please re-approve with the recent changes?

Woop! Pushed. Thanks! :-)


Three sorries about OfNat, ble, etc

The following three declarations in Tactic.Positivity.Core seem to be the last sorries in mathlib4:
lemma pos_of_isNat [PartialOrder A] [AddMonoidWithOne A]
  (_ : NormNum.IsNat e n) (_ : Nat.ble 1 n = true) : 0 < (e : A) := sorry

lemma nonneg_of_isNat [PartialOrder A] [AddMonoidWithOne A]
  (_ : NormNum.IsNat e n) : 0 ≤ (e : A) := sorry

lemma nz_of_isNegNat [PartialOrder A] [Ring A]
  (_ : NormNum.IsInt e (.negOfNat n)) (_ : Nat.ble 1 n = true) : (e : A) ≠ 0 := sorry

It would be good to fill in their proofs, both for philosophical purity and because some metaprogramming (such as an autograder checking for sorryAx) will probably fail as long as they remain.
@dwrensha points on on Zulip that at least one of them is actually false!

lemma pos_of_isNat [StrictOrderedSemiring A]
    (h : NormNum.IsNat e n) (w : Nat.ble 1 n = true) : 0 < (e : A) := by
  rw [NormNum.IsNat.to_eq h rfl]
  apply Nat.cast_pos.2
  simpa using w

lemma nonneg_of_isNat [OrderedSemiring A]
    (h : NormNum.IsNat e n) : 0 ≤ (e : A) := by
  rw [NormNum.IsNat.to_eq h rfl]
  exact Nat.cast_nonneg n

lemma nz_of_isNegNat [StrictOrderedRing A]
    (h : NormNum.IsInt e (.negOfNat n)) (w : Nat.ble 1 n = true) : (e : A) ≠ 0 := by
  rw [NormNum.IsInt.neg_to_eq h rfl]
  simp only [ne_eq, neg_eq_zero]
  apply ne_of_gt
  simpa using w

work, but then def normNumPositivity can't generate the relevant typeclasses.
There we can't just use let _ ← synthInstanceQ (q(StrictOrderedSemiring $α) : Q(Type u)) because NormNum.derive is already giving us weaker typeclasses.

Fixed by #1375.


doc: add readme explaining how to share dataset on the hub

I propose to add this document to share the steps I follow to upload my custom dataset on the hub since I think it can be useful to all the people in the group creating their own dataset.
The super important feature is file compression.

@cccntu, this is indeed a new feature which has less than one month if I recall correctly. This feature explained here for example. :blush:


Add Apache NiFi integration

This would simplify deployment and management of DStream processes within Apache NiFi flow execution environment.
Unlike other sub-projects (to provide RI of DStream), the primary goal of this one is to simplify management , control and deployment of DStream processes regardless of their execution environment (Local, Tez, Spark etc.).

Initial integration was added. Needs sample, documentation and tests. Will address it as separate issues.


Fixed security problem detected with cargo audit

Hi - the statrs you had fixed in your dependencies had a dependency (nalgebra) that had a security vulnerability. This PR updates the dependencies and removes this vulnerability.
Crate:     nalgebra
Version:   0.23.2
Title:     VecStorage Deserialize Allows Violation of Length Invariant
Date:      2021-06-06
ID:        RUSTSEC-2021-0070
URL:       https://rustsec.org/advisories/RUSTSEC-2021-0070
Solution:  Upgrade to >=0.27.1
Dependency tree:
nalgebra 0.23.2
└── statrs 0.13.0
    └── stattest 0.0.0
        ├── statistical_comparisons 0.1.0
        └── hyperloglog-rs 0.1.56
            └── statistical_comparisons 0.1.0

error: 1 vulnerability found!

@larsgw plz do check this PR out when you have time

Sorry that it shows up as closed instead of merged, I wanted to rebase and change the commit message but the interface didn't allow me to do so.

No worries, do you need me to do anything or it was merged fine?

It was merged fine, thank you!


thread 'main' panicked at 'called Option::unwrap() on a None value'

When using the examples provided within src/lib.rs
tokio::runtime::Runtime::new().unwrap().block_on(async {
    let transport = boinc_rpc::Transport::new("<IP_ADDRESS>:31416", Some("1033644eaad1ea7d91bc48a749f1620b"));
    let mut client = boinc_rpc::Client::new(transport);

    println!("{:?}\n", client.get_messages(0).await.unwrap());
    println!("{:?}\n", client.get_projects().await.unwrap());
    println!("{:?}\n", client.get_account_manager_info().await.unwrap());
    println!("{:?}\n", client.exchange_versions(&boinc_rpc::models::VersionInfo::default()).await.unwrap());
    println!("{:?}\n", client.get_results(false).await.unwrap());
})

I get a panic:
thread 'main' panicked at 'called `Option::unwrap()` on a `None` value', /Users/gms8994/.cargo/git/checkouts/rust-boinc-rpc-cf23ed20e457ad15/65e00a8/src/lib.rs:313:34

I can run any single call correctly; is there some bug with keeping track of the state of the connection?

Hello @vorot93
Thanks for this library.
I am going to use this library for BOINC client, but got this error at start.
Starting BOINC Client...
thread 'main' panicked at 'internal error: entered unreachable code', D:\Boid\Current\Boid_Desktop\Github_Samples\rust-boinc\rust-boinc-rpc\src\lib.rs:340:22
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
error: process didn't exit successfully: `target\debug\boinc-client.exe` (exit code: 101)

I used tokio = { version = "0.2", features = ["macros"] }.

I don't know how I can fix this error, I would like you to help me.
Thanks again!


chromedriver: add dbus to libraries

It is apparently required since version 94.
Fixes #139547

Motivation for this change
Chromedriver doesn’t run otherwise.
Things done

Built on platform(s)

[x] x86_64-linux
[ ] aarch64-linux
[ ] x86_64-darwin
[ ] aarch64-darwin

[ ] For non-Linux: Is sandbox = true set in nix.conf? (See Nix manual)
[ ] Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
[x] Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
[x] Tested execution of all binary files (usually in ./result/bin/)
21.11 Release Notes (or backporting 21.05 Release notes)

[ ] (Package updates) Added a release notes entry if the change is major or breaking
[ ] (Module updates) Added a release notes entry if the change is significant
[ ] (Module addition) Added a release notes entry if adding a new NixOS module

[x] Fits CONTRIBUTING.md.

Incidentally, a couple of questions:

Should I add a test to check that chromedriver runs (essentially copy-pasting from the manual), to avoid similar accidents in the future?
The resulting wrapper script includes the original LD_LIBRARY_PATH twice (the new value ends with :$LD_LIBRARY_PATH'${LD_LIBRARY_PATH:+':'}$LD_LIBRARY_PATH), so it seems that the explicit reference to $LD_LIBRARY_PATH in wrapProgram invocation is redundant; should I remove it while I’m here?

If there are no obvious downsides to these changes that I’m oblivious to, should they go into this PR or separate ones?

Should I add a test to check that chromedriver runs (essentially copy-pasting from the manual), to avoid similar accidents in the future?

If you want to.

The resulting wrapper script includes the original LD_LIBRARY_PATH twice (the new value ends with :$LD_LIBRARY_PATH'${LD_LIBRARY_PATH:+':'}$LD_LIBRARY_PATH), so it seems that the explicit reference to $LD_LIBRARY_PATH in wrapProgram invocation is redundant; should I remove it while I’m here?

Yes please, line 50 should be.
wrapProgram "$out/bin/chromedriver" --prefix LD_LIBRARY_PATH : "${libs}"

Thanks!


Replace Otto with goja

https://github.com/dop251/goja

Full ECMAScript 5.1 support (yes, including regex and strict mode).
Passes nearly all tc39 tests tagged with es5id. The goal is to pass all of them.
On average 6-7 times faster than otto. Also uses considerably less memory.

;-)

Hi @SchumacherFM , we're experiencing performance problems with otto. Could you share, why you've decided not to migrate to goja after all (ht master still vendors otto even after this issue has been closed)?

@marcin-ptaszynski Are you experiencing performance problems with ht because of otto or are you unsatisfied with otto "outside" of ht?
You know: The performance of the JS-interpreter has absolutely no impact on ht.

Hi @vdobler, I have no performance problem with ht. I was just googling around for other people's experiences with goja and stumbled upon this issue and it got me to wonder. If ottos performance doesn't impact ht, then I guess you didn't have much reason to migrate to goja.

We have not yet used intensively the JS features of ht. But even then I think switching from otto to goja is negligible. The pages which ht should test have a more worse overall performance than otto ;-)
If a tested page would return below 1ms then maybe we can start thinking about replacing otto ;-)

@SchumacherFM , thanks


[ci] Sanitize macOS brew entirely

Closes: #259.

Both versions: fixup symlinks as shown in https://github.com/actions/setup-python/issues/577#issuecomment-1386066001
This version: remove and reinstall brew.  Possibly more ideal for our overall environment.  Unclear how stable this is.

Time consideration: GHA has a lot installed via brew, uninstallation took 4 minutes.  Fixing the symlinks and running upgrade (on today) took 3 minutes 11 seconds.
Relates: #250, #252, #257.

This change is

We thingk #259 will be faster and safer over time.  Purging brew seems like a potential recipe for disaster, especially if the GHA runner was utilizing something that was already installed from brew.


:memo: Update README

Codecov Report
All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 100.00%. Comparing base (fde3e67) to head (755893a).

Additional details and impacted files
@@            Coverage Diff            @@
##              main        #7   +/-   ##
=========================================
  Coverage   100.00%   100.00%
=========================================
  Files            3         3
  Lines           14        14
=========================================
  Hits            14        14

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


Refactor for Rego code to be within ScubaGear module

💡 Summary
ScubaGear is currently deployed as a zipped package with manual instructions on installation and usage. To migrate to delivery/deployment via a package repository all Rego code should be included in publishing.
Motivation and context
This would be useful because it supports publishing ScubaGear to a public repository #645
Implementation notes
Reference #94, #645, #677 for context and additional information
-ScubaGear functinality has access to packaged Rego Code (e.g., Invoke-RunRego)
Acceptance criteria

[ ] ScubaGear executes properly when installed from a package repository
[ ] ScubaGear executes properly when imported directly from source code baseline

There's positives and negatives to doing this due to the fact that the OPA executable has to be downloaded separately.
+ Makes it easier to include the Rego code with the ScubaGear PowerShell package. - May run into issues with system file path permissions where OPA executable has to reach out to the Rego code location. Which can be in a number of different places depending on where the user has installed.
My thinking was to download a copy of our Rego code along with the OPA executable during initial setup from installing the ScubaGear module. This way the rego code itself will be in the user's currently executing directory along with OPA executable.

I'd like to see it in the module as part of the signed catalog if possible.  File permission concerns noted - I am making an assumption that the installed ScubaGear module directory is at lead 'read' to the user.  The assumption seems reasonable (until it is not).

Closed with PR #704


use more accurate function return values for static analysis

Description

During current static analysis process, turbopack will give all function a default JsValue::Constant(ConstantValue::Undefined) as one of possible return value of function, but function always has a return value when the last statement of function body is ReturnStatement.
Although there maybe be dead loop or throw error syntax inside of function, but that case shouldn't affect static analysis process.
This PR add a check before setting the initial return values for function, which will make the static analysis process more accurate.
Testing Instructions
check the diff result of snapshot.

Thanks


Testing on juicefs + es, then es service crashes frequently

The log information is as follows：

After referring to https://www.elastic.co/guide/en/elasticsearch/reference/7.16/index-modules-store.html, by adding the parameter node.store.allow_mmap: false, although the service no longer crashes, the performance will get worse

What's the version of kernel? Can you try to disable the kernel cache by --attr-cache=0
Also, collecting the access log while reproducing the bug will be very helpful.

I have set --attr-cache=0, but still have such problems

my linux kernel version:  3.10.0-862.14.4, may be a bug in the kernel?

It's possible, can you cat /jfs/.accesslog while reproducing the problem? then post the access log here

upgraded kernel version from 3.10.0-862 to 5.4.190,
jdk version from openjdk-17.0.1 to oraclejdk-17.0.3,
but still have such problems

Please collect the accesslog, or tell us the exact steps to reproduce the issue, thanks!

And what's the mount options?

_netdev,allow_other,cache-dir=/data/jfs-cache,cache-size=921600,attr-cache=0,entry-cache=0,dir-entry-cache=0,get-timeout=120,put-timeout=120,io-retries=60,max-uploads=60,max-deletes=12,buffer-size=16384,upload-limit=2048,prefetch=30,no-usage-report,metrics=<IP_ADDRESS>:9567

I have the same problem。

We can confirm that this is a bug, will fix it.

This should be fixed by #2336


add: glennwatson.net to the built-with page.

 Issue by glennawatson
Friday Feb 08, 2019 at 03:19 GMT
Originally opened as https://github.com/Wyamio/Wyam.Web/pull/81

Just a bit of shameless self promotion.

glennawatson included the following code: https://github.com/Wyamio/Wyam.Web/pull/81/commits

 Comment by daveaglick
Tuesday Feb 12, 2019 at 19:44 GMT

Nothing wrong with a little shameless self promotion 😄


Add support for building Swift on Windows with clang-cl and MSVC

Caveat
Please note: this PR on its own does not constitute actual support for building on Windows upon merging this PR.
For this, apple/swift-clang#45 and apple/swift-llvm#33 will have to be merged.
After this, I will break up my branch: https://github.com/hughbe/swift/tree/improve-win-instructions (that has a fully building Swift compiler) into multiple PRs (20 or so - 1 for each sub-project) and submit them.
If this is merged and you try to build Swift on Windows with MSVC, expect many thousands of build errors - many are duplicates, and all have been addressed in my branch above.
This could take a while, so hold your horses :)
Discussion

We get linker errors (unresolved external symbol _TMps16TextOutputStream) linking swiftPrivate.dll. For now building swiftPrivate is disabled in order to get the stdlib all building. This will need to be fixed at some point!
We get "no such module 'ucrt'" errors building stdlib/public/platform. For now building swiftMSVCRT is disabled in order to get the stdlib all building. This will need to be fixed at some point!

Firstly, thanks Saleem! I've addressed most of your comments. For those I'm not entirely clear with or dispute, I've left comments.

We should split this out and get it merged first.
I'm not quite sure what commit you mean by this? GitHub isn't making it clear :)

This is because clang is required: you need modules. There are module definitions that need to be pulled into the system SDK.

How do we overcome this?

I'm gonna also tag some Apple folks so they can chip in (no excuses now that Thanksgiving is over ;) )
@gottesmm @gribozavr @jrose-apple
Also, @modocache for your previous experience portin'

@hughbe as to how to overcome the modules issue: simple, dont use MSVC until such a day as it actually supports modules.  You already must build clang to build swift.  So you already have clang.  You can use the just built clang to build the runtime.
That said, it seems that if you are sufficiently clever, you should be able to just copy the module maps into the appropriate SDK locations, and then use cl to build swiftc and the runtime and then use swift to build just the stdlib, which would use clang, which would allow you to use modules.  Although, since the swift compilation is done manually .... this may actually be easier in practice than it appears at first glance.

The runtime will eventually require that it be built with Clang once we enable the Swift calling convention too.

The runtime will eventually require that it be built with Clang once we enable the Swift calling convention too.

I had a feeling that would happen - basically this gets us building with MSVC, but that's not really the complete goal. Once this is merged, I'll add support for clang-cl which should get the runtime working in the long run.

Okay, thanks all for your comments. I've addressed all of them hopefully. I've had to rebase due to merge conflicts. I also ran a Clang build on my Linux VM and that seems to be working (had to fix the new line-directive-file-script for python using bash).
I also simplified some of the ICU stuff and addressed some TODOs

That's all of my comments, but @compnerd and @llvm-beanz might still have more. (And yes, in the long-term we definitely should be building the runtime with the just-built Clang.)

I still think you should change how you're handling finding ICU and move the code into the FindICU.cmake file so that you're within CMake's convention.

I still think you should change how you're handling finding ICU and move the code into the FindICU.cmake file so that you're within CMake's convention.
👍 2

You're right - I don't really know where I was coming from in my previous attempt!! So ugly, unconventional and unecessary.
I've fixed this and rebased to make things simple. Only thing that's changed is this commit: https://github.com/apple/swift/pull/5904/commits/dfea553002f0d793a9d4caad5101cc16582639d7

I've fixed this and rebased to make things simple. Only thing that's changed is this commit: dfea553

That commit doesn't seem to be part of the PR, and when I click the link for it nothing shows up.

My bad, I fixed some comment typos so had to rebase again: https://github.com/apple/swift/pull/5904/commits/1a8d539f06b4101b99a5564c13f05aa102d779e1

Managed to get onto a computer to fix the merge conflicts - won't be available until at least Wednesday to address any comments that may come up (if any, I think most people have taken a look and given their thoughts).

I've fixed the merge conflicts and removed some changes based on the new updates to the CMake infrastructure. Nothing's been added - hopefully we can avoid endless merge conflicts by merging this soon now that everyone's had their comments addressed, I hope.

Friendly ping - would be good to get this re-reviewed while its still fresh in everyones minds

Okay - I've applied some knife cutting to this PR, and have changed several commits and extracted them to their own PRs. This PR is now limited to clang-cl and MSVC specific functionality. E.g. compiler arguments, and linker errors.

@swift-ci please clean test

PR should be fairly easy to review - use ?w=1 in the URL to simplify the diff

This should be a relatively simple change now. It's also one of the final requirements for getting swiftc.exe compiled on Windows. Would be nice to get this one merged soon

@swift-ci please clean test

Build failed
Jenkins build - Swift Test OS X Platform
Git Commit - 13c530e00962910d6c6fbe81e0b9cf2f85ab992b
Test requested by - @hughbe

Build failed
Jenkins build - Swift Test Linux Platform
Git Commit - 13c530e00962910d6c6fbe81e0b9cf2f85ab992b
Test requested by - @hughbe

@swift-ci please smoke test Linux Platform
@swift-ci please test Linux Platform

Build failed
Jenkins build - Swift Test Linux Platform
Git Commit - f3207a9c5b8ad5744c90e7d37d0e7dbc4c9d09b4
Test requested by - @hughbe

@swift-ci please clean smoke test

@swift-ci please clean smoke test

@swift-ci please clean smoke test

@swift-ci please clean smoke test

This is actually a super simple change now - most of the work has been done. Would be awesome to get this merged in soon! Means that anyone can fully build Swift on Windows, when #7626 and #7588 (but not necessarily run compiled code fully until #7489)


Update portage cataloger to new generic cataloger

Follow up to https://github.com/anchore/syft/pull/1281 , porting the php cataloger to the new generic.Cataloger.
I've also removed two unused fields from the portage metadata struct, leading to a json schema change.

JSON schema diff
❯ diff schema/json/schema-4.1.0.json schema/json/schema-5.0.0.json
232a233
>         "virtual_path",
238a240,242
>         "virtual_path": {
>           "type": "string"
>         },
1236,1237d1239
<         "package",
<         "version",
1242,1247d1243
<         "package": {
<           "type": "string"
<         },
<         "version": {
<           "type": "string"
<         },

Note: there seems to be changes from previous PRs that did not update the JSON schema.


NOT for parenthetic expressions

Boolean algebra as it relates to the use of NOT for parenthetic expressions

[x] I have read freeCodeCamp's contribution guidelines.
[x] My pull request has a descriptive title (not a vague title like Update index.md)
[x] My pull request targets the master branch of freeCodeCamp.
[x] None of my changes are plagiarized from another source without proper attribution.
[x] My article does not contain shortened URLs or affiliate links.

If your pull request closes a GitHub issue, replace the XXXXX below with the issue number.
Closes #XXXXX

Thank you @lstar19 for your contribution!


Anyone figure out how to use with SwiftUI?

Have you tried? What issues are you running into?
I'm planning to do a SwiftUI version - but until then maybe there are some low hanging fruits that we can patch to make the current version work with SwiftUI

@mikaoj It has surprised me today, with Xcode 11.5 update, the BSImagePicker actually worked!
A few days earlier, I gave it a try earlier and it crashed when activating the picker.
For the moment, I've merely wrapped it with the UIViewControllerRepresentable.  I'll try to see if I can use the SwiftUI-UIKit's Coordinator with the callback based API.
struct ContentView: View {
    @State var isPresentedSheet = false
    var body: some View {
        Button("Select Image") {
            self.isPresentedSheet = true
        }
        .sheet(isPresented: self.$isPresentedSheet, content: {
            ImagePickerCoordinatorView()
        })
    }
}

public struct ImagePickerCoordinatorView {
    @Environment(\.presentationMode) var presentationMode: Binding<PresentationMode>
}

extension ImagePickerCoordinatorView: UIViewControllerRepresentable {

    public typealias UIViewControllerType = ImagePickerController

    public func makeUIViewController(context: Context) -> ImagePickerController {
        let picker = ImagePickerController()
        return picker
    }

    public func updateUIViewController(_ uiViewController: ImagePickerController, context: Context) {

    }
}

Cool. If any of that would make it easier for people to use it with SwiftUI feel free to submit a PR :)

@mikaoj I can't figure out a way to call the presentImagePicker. As the UIViewControllerRepresentable call the .present(I guess) method implicitly, therefore, if I use presentImagePicker, it will causing the controller being presented twice, which resulting in crash.
Is there another way I can pass/assign the callbacks? For example, as a property of the picker.
Or do the ImagePickerController has a delegate patter? The Apple's coordinator solution is actually based on delegates sadly.

It does have a delegate you can set.
The intent was for the delegate to be used for more advanced use-cases and the closures for the more common ones.
So try setting yourself as imagePickerDelegate and implement the ImagePickerControllerDelegate protocol

@mikaoj Thanks! It plays very well with the SwiftUI by using the delegate pattern. I do hope the next version of SwiftUI works better with closures and hopefully the publishers as well.
Here I attach a very basic implementation of the SwiftUI/UIKit bridge.
import SwiftUI
import Photos
import BSImagePicker

public struct ImagePickerCoordinatorView {
    @Environment(\.presentationMode) var presentationMode: Binding<PresentationMode>

    private func dismiss() {
        self.presentationMode.wrappedValue.dismiss()
    }
}

extension ImagePickerCoordinatorView: UIViewControllerRepresentable {

    public typealias UIViewControllerType = ImagePickerController

    public func makeUIViewController(context: Context) -> ImagePickerController {
        let picker = ImagePickerController()

        picker.settings.selection.max = 5
        picker.settings.selection.unselectOnReachingMax = false
        picker.settings.theme.selectionStyle = .numbered
        picker.settings.fetch.assets.supportedMediaTypes = [.image]

        picker.imagePickerDelegate = context.coordinator

        return picker
    }

    public func updateUIViewController(_ uiViewController: ImagePickerController, context: Context) {

    }

    public func makeCoordinator() -> Coordinator {
        return Coordinator(self)
    }
}

extension ImagePickerCoordinatorView {
    public class Coordinator: ImagePickerControllerDelegate {
        private let parent: ImagePickerCoordinatorView

        public init(_ parent: ImagePickerCoordinatorView) {
            self.parent = parent
        }

        public func imagePicker(_ imagePicker: ImagePickerController, didSelectAsset asset: PHAsset) {
            print("Selected: \(asset)")
        }

        public func imagePicker(_ imagePicker: ImagePickerController, didDeselectAsset asset: PHAsset) {
            print("Deselected: \(asset)")
        }

        public func imagePicker(_ imagePicker: ImagePickerController, didFinishWithAssets assets: [PHAsset]) {
            print("Finished with selections: \(assets)")
            parent.dismiss()
        }

        public func imagePicker(_ imagePicker: ImagePickerController, didCancelWithAssets assets: [PHAsset]) {
            print("Canceled with selections: \(assets)")
            parent.dismiss()
        }

        public func imagePicker(_ imagePicker: ImagePickerController, didReachSelectionLimit count: Int) {
            print("Did Reach Selection Limit: \(count)")
        }
    }
}

I have tried the code above but it doesn't seem to be working, have you tried a different solution?


Added an InPlaceFormAction server action and related xsp-config

It has long annoyed me that there is no simple action for showing and hiding InPlaceForms so I created one!
Basically just copied the ChangeDynamicContentAction and modified as necessary.
Note: I have modified extlib-dynamiccontent.xsp-config to add the complex property config, I understand this is generated somehow but I don't know how to do that so that area might need a look over. I added some properties to the related messages as well.

Hi Cameron,
Thanks for your contribution, seems handy alright. We will review it and be in touch shortly.
Thanks,
Padraic

Thanks Padraic!

Hi Cameron,
Thanks very much contributing to the Extension Library. Your contribution has been bluewashed and is now part of the 12th ExtLib release.
Thanks,
Padraic

Thanks again, I'm very pleased to contribute!


Upgrade geth & parity docker images

Both geth and parity are running on ancient implementations. Upgrade to parity 2.2.7 and geth 1.8.20

@epheph -- I think we can hand this over to @petong

Yes, everything should be good to go with the next release. Although I suppose we should do it again-again to activate constantinople ?

@petong is this actually done?


The cupsd process occupies 100% of the CPU and the service cannot be used anymore. It must be restarted to recover

This problem will appear after a period of time, and it is becoming more and more frequent now. Please help me
After running normally for a period of time, this issue may occur. The cups service runs in the Docker container and the system is Centos8.4
/The error message displayed in the var/log/cups/errorlog log is as follows:
D [22/Apr/2024:04:31:10 +0000] [Client 11987] GET /?action=dzsap_download&link=../../../../../../../../../../../../../etc/passwd HTTP/1.1
D [22/Apr/2024:04:31:10 +0000] cupsdSetBusyState: newbusy="Active clients and dirty files", busy="Active clients and dirty files"
D [22/Apr/2024:04:31:10 +0000] [Client 11987] Read: status=200, state=3
D [22/Apr/2024:04:31:10 +0000] [Client 11987] No authentication data provided.
E [22/Apr/2024:04:31:10 +0000] [Client 11987] Request for non-absolute resource "/?action=dzsap_download&link=../../../../../../../../../../../../../etc/passwd".
D [22/Apr/2024:04:31:10 +0000] [Client 11987] cupsdSendHeader: code=403, type="text/html", auth_type=0
D [22/Apr/2024:04:31:10 +0000] [Client 11987] Closing because Keep-Alive is disabled.
D [22/Apr/2024:04:31:10 +0000] [Client 11987] Closing connection.

D [22/Apr/2024:04:31:10 +0000] [Client 11987] HTTP_STATE_WAITING Closing for error 32 (Broken pipe)
D [22/Apr/2024:04:31:10 +0000] [Client 11987] Closing connection.

cups version is 2.4.7    use cupd-pdf 3.0.1

We could use some more details about your configuration - number of clients and printers, and whether or not you are connected. To the internet?
The log shows a known HTTP attack underway, probing your server…

We use a third-party Windows plugin to connect to the Windows network printing client, which then connects to the cups server. The windows environment is connected to the internet. Only one cups.pdf printer has been defined. Below are cups.conf:
PageLogFormat
MaxLogSize 32m
MaxClients 2048
ErrorPolicy abort-job
MaxJobs 0
PreserveJobFiles No
PreserveJobHistory No

Configuration file for the CUPS scheduler.  See "man cupsd.conf" for a
complete description of this file.

Log general information in error_log - change "warn" to "debug"
for troubleshooting...
LogLevel debug
Only listen for connections from the local machine.
Listen localhost:631
Listen <IP_ADDRESS>:8600
Listen /var/run/cups/cups.sock
Show shared printers on the local network.
Browsing On
BrowseLocalProtocols dnssd
Default authentication type, when authentication is required...
DefaultAuthType Basic
DefaultEncryption Never
Web interface setting...
WebInterface Yes
Restrict access to the server...

  # Job/subscription privacy...
  JobPrivateAccess default
  JobPrivateValues default
  SubscriptionPrivateAccess default
  SubscriptionPrivateValues default
Job-related operations must be done by the owner or an administrator...

    Order deny,allow

    Require user @OWNER @SYSTEM
    Order deny,allow

All administration operations require an administrator to authenticate...

    AuthType Default
    Require user @SYSTEM
    Order deny,allow

All printer operations require a printer operator to authenticate...

    AuthType Default
    Require user @SYSTEM
    Order deny,allow

Only the owner or an administrator can cancel or authenticate a job...

    Require user @OWNER @SYSTEM
    Order deny,allow

    Order deny,allow

Set the authenticated printer/job policies...

  # Job/subscription privacy...
  JobPrivateAccess default
  JobPrivateValues default
  SubscriptionPrivateAccess default
  SubscriptionPrivateValues default
Job-related operations must be done by the owner or an administrator...

    AuthType Default
    Order deny,allow

    AuthType Default
    Require user @OWNER @SYSTEM
    Order deny,allow

All administration operations require an administrator to authenticate...

    AuthType Default
    Require user @SYSTEM
    Order deny,allow

All printer operations require a printer operator to authenticate...

    AuthType Default
    Require user @SYSTEM
    Order deny,allow

Only the owner or an administrator can cancel or authenticate a job...

    AuthType Default
    Require user @OWNER @SYSTEM
    Order deny,allow

    Order deny,allow

Set the kerberized printer/job policies...

  # Job/subscription privacy...
  JobPrivateAccess default
  JobPrivateValues default
  SubscriptionPrivateAccess default
  SubscriptionPrivateValues default
Job-related operations must be done by the owner or an administrator...

    AuthType Negotiate
    Order deny,allow

    AuthType Negotiate
    Require user @OWNER @SYSTEM
    Order deny,allow

All administration operations require an administrator to authenticate...

    AuthType Default
    Require user @SYSTEM
    Order deny,allow

All printer operations require a printer operator to authenticate...

    AuthType Default
    Require user @SYSTEM
    Order deny,allow

Only the owner or an administrator can cancel or authenticate a job...

    AuthType Negotiate
    Require user @OWNER @SYSTEM
    Order deny,allow

    Order deny,allow

WebInterface Yes
ServerAlias *

We use a third-party Windows plugin to connect to the Windows network printing client, which then connects to the cups server. The windows environment is connected to the internet. Only one cups.pdf printer has been defined. Below are cups.conf:
PageLogFormat
MaxLogSize 32m
MaxClients 2048
ErrorPolicy abort-job
MaxJobs 0
PreserveJobFiles No
PreserveJobHistory No
#
# Configuration file for the CUPS scheduler.  See "man cupsd.conf" for a
# complete description of this file.
#

# Log general information in error_log - change "warn" to "debug"
# for troubleshooting...
LogLevel debug

# Only listen for connections from the local machine.
Listen localhost:631
Listen <IP_ADDRESS>:8600
Listen /var/run/cups/cups.sock

# Show shared printers on the local network.
Browsing On
BrowseLocalProtocols dnssd

# Default authentication type, when authentication is required...
DefaultAuthType Basic
DefaultEncryption Never

# Web interface setting...
WebInterface Yes

# Restrict access to the server...
<Location />
  Order allow,deny
  Allow all
</Location>

# Restrict access to the admin pages...
<Location /admin>
  Order allow,deny
  Allow all
</Location>

# Restrict access to configuration files...
<Location /admin/conf>
  AuthType Default
  Require user @SYSTEM
  Order allow,deny
  Allow all
</Location>

# Restrict access to log files...
<Location /admin/log>
  AuthType Default
  Require user @SYSTEM
  Order allow,deny
  Allow all
</Location>

# Set the default printer/job policies...
<Policy default>
  # Job/subscription privacy...
  JobPrivateAccess default
  JobPrivateValues default
  SubscriptionPrivateAccess default
  SubscriptionPrivateValues default

  # Job-related operations must be done by the owner or an administrator...
  <Limit Create-Job Print-Job Print-URI Validate-Job>
    Order deny,allow
  </Limit>

  <Limit Send-Document Send-URI Hold-Job Release-Job Restart-Job Purge-Jobs Set-Job-Attributes Create-Job-Subscription Renew-Subscription Cancel-Subscription Get-Notifications Reprocess-Job Cancel-Current-Job Suspend-Current-Job Resume-Job Cancel-My-Jobs Close-Job CUPS-Move-Job CUPS-Get-Document>
    Require user @OWNER @SYSTEM
    Order deny,allow
  </Limit>

  # All administration operations require an administrator to authenticate...
  <Limit CUPS-Add-Modify-Printer CUPS-Delete-Printer CUPS-Add-Modify-Class CUPS-Delete-Class CUPS-Set-Default CUPS-Get-Devices>
    AuthType Default
    Require user @SYSTEM
    Order deny,allow
  </Limit>

  # All printer operations require a printer operator to authenticate...
  <Limit Pause-Printer Resume-Printer Enable-Printer Disable-Printer Pause-Printer-After-Current-Job Hold-New-Jobs Release-Held-New-Jobs Deactivate-Printer Activate-Printer Restart-Printer Shutdown-Printer Startup-Printer Promote-Job Schedule-Job-After Cancel-Jobs CUPS-Accept-Jobs CUPS-Reject-Jobs>
    AuthType Default
    Require user @SYSTEM
    Order deny,allow
  </Limit>

  # Only the owner or an administrator can cancel or authenticate a job...
  <Limit Cancel-Job CUPS-Authenticate-Job>
    Require user @OWNER @SYSTEM
    Order deny,allow
  </Limit>

  <Limit All>
    Order deny,allow
  </Limit>
</Policy>

# Set the authenticated printer/job policies...
<Policy authenticated>
  # Job/subscription privacy...
  JobPrivateAccess default
  JobPrivateValues default
  SubscriptionPrivateAccess default
  SubscriptionPrivateValues default

  # Job-related operations must be done by the owner or an administrator...
  <Limit Create-Job Print-Job Print-URI Validate-Job>
    AuthType Default
    Order deny,allow
  </Limit>

  <Limit Send-Document Send-URI Hold-Job Release-Job Restart-Job Purge-Jobs Set-Job-Attributes Create-Job-Subscription Renew-Subscription Cancel-Subscription Get-Notifications Reprocess-Job Cancel-Current-Job Suspend-Current-Job Resume-Job Cancel-My-Jobs Close-Job CUPS-Move-Job CUPS-Get-Document>
    AuthType Default
    Require user @OWNER @SYSTEM
    Order deny,allow
  </Limit>

  # All administration operations require an administrator to authenticate...
  <Limit CUPS-Add-Modify-Printer CUPS-Delete-Printer CUPS-Add-Modify-Class CUPS-Delete-Class CUPS-Set-Default>
    AuthType Default
    Require user @SYSTEM
    Order deny,allow
  </Limit>

  # All printer operations require a printer operator to authenticate...
  <Limit Pause-Printer Resume-Printer Enable-Printer Disable-Printer Pause-Printer-After-Current-Job Hold-New-Jobs Release-Held-New-Jobs Deactivate-Printer Activate-Printer Restart-Printer Shutdown-Printer Startup-Printer Promote-Job Schedule-Job-After Cancel-Jobs CUPS-Accept-Jobs CUPS-Reject-Jobs>
    AuthType Default
    Require user @SYSTEM
    Order deny,allow
  </Limit>

  # Only the owner or an administrator can cancel or authenticate a job...
  <Limit Cancel-Job CUPS-Authenticate-Job>
    AuthType Default
    Require user @OWNER @SYSTEM
    Order deny,allow
  </Limit>

  <Limit All>
    Order deny,allow
  </Limit>
</Policy>

# Set the kerberized printer/job policies...
<Policy kerberos>
  # Job/subscription privacy...
  JobPrivateAccess default
  JobPrivateValues default
  SubscriptionPrivateAccess default
  SubscriptionPrivateValues default

  # Job-related operations must be done by the owner or an administrator...
  <Limit Create-Job Print-Job Print-URI Validate-Job>
    AuthType Negotiate
    Order deny,allow
  </Limit>

  <Limit Send-Document Send-URI Hold-Job Release-Job Restart-Job Purge-Jobs Set-Job-Attributes Create-Job-Subscription Renew-Subscription Cancel-Subscription Get-Notifications Reprocess-Job Cancel-Current-Job Suspend-Current-Job Resume-Job Cancel-My-Jobs Close-Job CUPS-Move-Job CUPS-Get-Document>
    AuthType Negotiate
    Require user @OWNER @SYSTEM
    Order deny,allow
  </Limit>

  # All administration operations require an administrator to authenticate...
  <Limit CUPS-Add-Modify-Printer CUPS-Delete-Printer CUPS-Add-Modify-Class CUPS-Delete-Class CUPS-Set-Default>
    AuthType Default
    Require user @SYSTEM
    Order deny,allow
  </Limit>

  # All printer operations require a printer operator to authenticate...
  <Limit Pause-Printer Resume-Printer Enable-Printer Disable-Printer Pause-Printer-After-Current-Job Hold-New-Jobs Release-Held-New-Jobs Deactivate-Printer Activate-Printer Restart-Printer Shutdown-Printer Startup-Printer Promote-Job Schedule-Job-After Cancel-Jobs CUPS-Accept-Jobs CUPS-Reject-Jobs>
    AuthType Default
    Require user @SYSTEM
    Order deny,allow
  </Limit>

  # Only the owner or an administrator can cancel or authenticate a job...
  <Limit Cancel-Job CUPS-Authenticate-Job>
    AuthType Negotiate
    Require user @OWNER @SYSTEM
    Order deny,allow
  </Limit>

  <Limit All>
    Order deny,allow
  </Limit>
</Policy>

WebInterface Yes
ServerAlias *

No more occurrences after closing the external network port


[stable/redis-ha] Simplify livenessProbes, remove readinessProbes

What this PR does / why we need it:
This PR removes exec-based probes that execute redis-cli PING.
In issue #13747 it was discovered that there is a surprisingly large overhead
associated with spawning shell scripts in each container. 3 pods * 2
containers * 2 probes results in 12 shell script executions, which is
compounded by a large, as-yet unexplained, runc overhead.
Considering the nature of redis-ha, these introspective probes are not
necessary since availability and role is determined by the sentinels.
A simple tcpSocket livenessProbe check will confirm open ports that are
ready for communication. The set of sentinel containers then
establishes "readiness" and the address of master and slaves though
a native consensus implementation.
The StatefulSet provides a headless Service which resolves to all active
sentinel Pod IPs via RR DNS. The sentinels in turn elect a master which
is reachable via an "announce" Service with publishNotReadyAddresses
enabled to ensure a stable service IP address for each Pod.
Hence a readinessProbe is needed for neither Redis nor Sentinel.
The entire redis-ha-healthchecks ConfigMap was deleted since none of the
scripts are in use anymore.
Which issue this PR fixes

fixes #13747 (closed only by bot due to expiry)

Special notes for your reviewer:
@ssalaues I've followed your suggestion from https://github.com/helm/charts/issues/13747#issuecomment-515169315 but think now that readinessProbes do not give us any benefit. Please consider this point and review accordingly. I'm open for discussion.
Through my extensive testing I have ideas for more PRs that will be submitted subsequently (why do we still have RBAC and ServiceAccount?, we should probably  alias redis-cli='timeout 3 redis-cli')
Checklist
[Place an '[x]' (no spaces) in all applicable fields. Please remove unrelated fields.]

[x] DCO signed
[x] Chart Version bumped
[x] Variables are documented in the README.md
[x] Title of the PR starts with chart name (e.g. [stable/chart])

@ssalaues I've followed your suggestion from #13747 (comment) but think now that readinessProbes do not give us any benefit. Please consider this point and review accordingly. I'm open for discussion.

Yeah I agree. Sorry for the delay, I've been traveling this past week with limited internet access.

/ok-to-test

/lgtm

Through my extensive testing I have ideas for more PRs that will be submitted subsequently (why do we still have RBAC and ServiceAccount?, we should probably alias redis-cli='timeout 3 redis-cli

The RBAC and ServiceAccount were added semi recently likely for environments that are very strict and/or don't want to use the default account. As for the timeout, this is actually something I was testing out. I've noticed that sometimes a forced failover can take some time because it's waiting for a response from a non existent master. I'm gonna be opening up a PR that makes rolling upgrades a bit smoother and includes this addition.

The RBAC and ServiceAccount were added semi recently likely for environments that are very strict and/or don't want to use the default account.

@ssalaues, I  thought they are simply remnants from the old failover logic, which used kubectl and which you removed yourself?
What else would this Role be needed for?
rules:
- apiGroups:
    - ""
  resources:
    - endpoints
  verbs:
    - get

I see, so I was mistaken. That was all added in https://github.com/helm/charts/pull/11842
Not sure what this is for, but anyway.


Demo page still has precent typos

precent => percent typos fixed in commit "2ab662423afa6208720fd0a75d717809296f65b0" are still visible on the demo page.
Thank You for the useful module!

Hi, @priithansen , thanks for you issue, I'll fix it

Hi, @priithansen , thanks for you issue, I'll fix it


Correct documentation text

My english is poor, so the docs text isn't pretty. Necessary to edit the text by somebody who is english native speaker.

Anybody taken this up? Just started using Svelte recently. I speak decent English. Willing to help

Great! Feel free to PR any correction =)

Is help still needed here? I'm a native English speaker who is new to open-source and would like to contribute!

Is help still needed here? I'm a native English speaker who is new to open-source and would like to contribute!

Cool! Will be happy to merge your PRs. =)

Cool! Will be happy to merge your PRs. =)

Thanks @kindoflew - great work: https://github.com/AlexxNB/svelte-chota/pull/19

Thanks @kindoflew - great work: https://github.com/AlexxNB/svelte-chota/pull/19

No problem! Thanks for all the cool stuff you make! (I'm currently using tinro to build my personal site!)

No problem! Thanks for all the cool stuff you make! (I'm currently using tinro to build my personal site!)

Nice! Tinro's README.md also may be improved 😉

Nice! Tinro's README.md also may be improved 😉

I'm on it!

I'm on it!


Please add working examples

Can you add a working example of this library?
I can’t get it to work.

Wil let you know as soon as possible if i get it working.
Did you try to have apple implement this natively? It seems really to be a missing feature. Awsome thinking and work.

The reddit version does work. What i'm getting is errors (won't build) cause of:

Unable to infer complex closure return type; add explicit type to disambiguate
Or
Cannot convert value of type 'Text' to closure result type 'TupleView<(Any, Any)>'

So i'm having a view:
struct CoinsView: View {     var body: some View {         RequestView(StatsResponse.self, Request {             Url("https://api.blockchain.info/stats")             Method(.get)             Header.Accept(.json)         }) { statsresponse in             Text("Hello world")         }     } }
With the following struct:
struct StatsResponse: Decodable, Identifiable {     let id: UUID = UUID()     let market_price_usd: Double     let hash_rate: Double     let minutes_between_blocks: Double     let estimated_transaction_volume_usd: Double     let miners_revenue_usd: Double     let trade_volume_btc: Double     let trade_volume_usd: Double     let total_fees_btc: Int     let n_btc_mined: Int     let n_tx: Int     let n_blocks_mined: Int     let totalbc: Int     let n_blocks_total: Int     let blocks_size: Int     let nextretarget: Int     let difficulty: Int     let estimated_btc_sent: Int     let miners_revenue_btc: Int     let total_btc_sent: Int     let timestamp: Int }
and my contentView contains (the main view)
struct ContentView: View {     var body: some View {         CoinsView()     } }
i tried alot of combinations as per-docs and as in the reddit example, it keeps erroring.
Not sure what i'm missing here.
I want a list with all those values. Had it working but it showed no content (only print(statsresponse) it would print:

StatsResponse( .... ALL KEY / VALUES .... )
So it DOES work but it keeps complaining when using the values in my views

.onObject is what i want to use.
Thanks.

You were so close! You just forgot the placeholder in the RequestView for when it is loading:
struct CoinsView: View {
    var body: some View {
        RequestView(StatsResponse.self, Request {
            Url("https://api.blockchain.info/stats")
            Method(.get)
            Header.Accept(.json)
        }) { statsresponse in
            Text(statsresponse != nil ? "\(statsresponse!.estimated_btc_sent)" : "")
            Text("Loading...")
        }
    }
}

You can see I added below your Text("Hello World") (which I changed to show some retrieved data) a Text("Loading..."). This shows while the request is being performed. In the case of the Reddit app, I made a SpinnerView for loading. You could do something similar, or just use Text or a clear Rectangle, doesn't really matter.

Hi thanks @carson-katri
I’s not that well explained in the guide so i missed that. It seems very nice how simple this is once you get the hang of it. It’s maybe the error text saying something that don’t seem to make it clear what was missing!
Thank you for your time!
Case closed

Glad it worked! Can’t wait to see what you make with it. I’ll see if I can improve the guide. A lot of SwiftUI’s error messages are confusing if you don’t know it well enough. I may even make it so you don’t have to provide a loading view.

Can you give a short note how to use it with array objects the right way?
RequestView( [ToDos].self, Request {             Url("https://someapi.returing.a.json.string.array/")             Header.Accept(.json)             Method(.get)         }) { todos in             List(todos != nil ? todos{ $0.id } : [] ) { todo in                 Text("Data: \(todo)")             }             SpinnerView()         }
What's the best way to do this? The AnyRequest<[Todos]> is also not working for me.
i want to parse a json:
["item1", "item2"]
array there is only an array returned no json objects.
not sure how the struct should be something like?:
struct Todos: Codable, Identifiable {     let id: UUID = UUID()     let title: String }
This is not working for me as xcode is again complaining identifiable
i'm using xcode 11 beta 7 by the way (At ObservableObject was changed (deprecated)) they now use "@Published" ..

So you're trying to retrieve an array of Strings, or an array of JSON objects? If it's an array of Strings, can you point me to an API that responds with that so I can try to get something working?

https://api.myjson.com/bins/17msc3

Here's a simple example:
struct ContentView: View {
    var body: some View {
        RequestView([String].self, Request {
            Url("https://api.myjson.com/bins/17msc3")
        }) { items in
            List(items ?? [], id: \.self) { item in
                Text(item)
            }
            Text("Loading...")
         That's insanity, works flawless!
Ok so if our apps are done, you want a linkback to a site?

Happy to help! Just a link to the repo or the repo name somewhere in the app with any of the other open source packages you all used is fine.


Add mergebot workflow

This pull request introduces a new GitHub Actions workflow for the mergebot. The most important changes include the addition of the mergebot.yml file, which configures the workflow to trigger on pushes to the main branch and uses the withstudiocms/mergebot action.
New GitHub Actions workflow:

.github/workflows/mergebot.yml: Added a new workflow named mergebot that triggers on pushes to the main branch and uses the withstudiocms/mergebot action. The workflow is conditioned to run only if the repository owner is withstudiocms and uses a secret for the Discord webhook.

Thank you for submitting your Pull Request, the following links will become available for preview shortly:

StudioCMS Documentation

StudioCMS Demo (node-playground) (Also deployed with package changes)

StudioCMS Ui Demo (ui-playground)


Add some commonly ignored files to .gitignore

Most of these should really go into your personal global .gitignore, shouldn't they?

@gvanrossum Could go either way, I grabbed most of these from mypy and cpython 😄 .  Feel free to close out if you feel differently.

The larger the project the more junk it accumulates in its .gitignore. Let's start lean.

@gvanrossum No problem, thanks for taking a look!


ttrpc buffer exceed max size error not properly handled

Description
When ttrpc recv content exceeding max buffer size, it may return status generated error which will be ignored by caller function and proceed to dereferencing returned pointer(which is nil), thus causing containerd to panic, specifically this line of code p:             p[:mh.Length],
Steps to reproduce the issue
No response
Describe the results you received and expected
in vendor/github.com/containerd/ttrpc/channel.go instead of returning nil, return truncated content instead or adding null ptr checking in vendor/github.com/containerd/ttrpc/client.go
What version of containerd are you using?
1.5
Any other relevant information
No response
Show configuration if it is related to CRI plugin.
No response

Hi! I am a Computer Science student at the University of Texas at Austin. I am currently taking virtualization (CS 360v) and I would like to contribute to this project. I saw this issue opened a couple years ago and I would like to work on it, but I was wondering if it was still open.


attempt to print validation errors

Description of changes

Issue Resolved

Fixes #
We are currently having issues with validation errors, that appear to be related to prod/ staging geolocation.

lol idk


Synchronization problem.

There is currently a problem when we try to set a new stream and play it directly after.
Taken from StationPlayerController.cpp
case radiostream::Event::NewStationRequested:
    {
        const auto station = std::any_cast<Station>(data);
        context_.status_.change_text(context_.localizer_.get_localized_text("Loading stream..."));
        context_.status_.change_color(StatusBar::Color::PROCESSING);
        context_.station_player_.set_station(station);
        context_.station_player_.play();
        context_.status_.change_text(context_.localizer_.get_localized_text("Stream playing"));
        context_.status_.change_color(StatusBar::Color::FINISHED);
    }
break;

Both StationPlayer::set_station() and StationPlayer::play() are implemented this way:
void StationPlayer::play()
{
    auto thread = std::thread([this]()
    {
        stream_manager_.play();
    });
    thread.detach();
}

and
void StationPlayer::set_station(const Station& station)
{
    station_ = station;
    auto thread = std::thread([this]()
    {
        stream_manager_.set_stream(station_.ip_);
        check_if_song_title_has_changed();
        notify(std::make_any<Station>(station_), radiostream::Event::StationBeingPlayedChanged);
    });
    thread.detach();
}

So it might happen that the thread that executes the play method might get created before the thread in set_station. In case of event mentioned above it makes it possible that play is executed before the set_station and in effect station will not start playing. This is unintended and should be fixed.

Solved by #26 PR.


Fix multi-stage Docker image build

Only the first stage of the Dockerfile was being built
https://github.com/docker/build-push-action/issues/315
I've tested that an image built with this fix works as expected:
https://github.com/wilsonianb/rafiki/pull/31

:confused: I'm still getting some weird images with this fix and need to investigate some more.

Ok, I think I was having issues mis-managing local images and containers and I have renewed confidence in this fix.

Thanks @wilsonianb if you're confident then I'm confident.


IndexError when joining two DuckDBDataFrame

Following on from #219  (thanks for the fix!):
In [1]: !cat lightbulbs.csv
kind,price,make
standard,30,emcsquare
capsule,40,emcsquare
candle,10,emcsquare
standard,20,maxwells
capsule,45,maxwells
candle,11,maxwells
standard,90,voltaires
capsule,95,voltaires
candle,80,voltaires

In [2]: from sqlframe.duckdb import DuckDBSession

In [3]: session = DuckDBSession()

In [4]: import sqlframe.duckdb.functions as F

In [5]: lightbulbs = session.read.csv('lightbulbs.csv')

In [6]: min_prices = lightbulbs.groupBy('kind', 'make').agg(F.min('price'))

In [7]: lightbulbs.join(min_prices, 'make')
---------------------------------------------------------------------------
IndexError                                Traceback (most recent call last)
Cell In[7], line 1
----> 1 lightbulbs.join(min_prices, 'make')

File ~/scratch/.venv/lib/python3.12/site-packages/sqlframe/base/operations.py:48, in operation.<locals>.decorator.<locals>.wrapper(self, *args, **kwargs)
     46 if new_op < last_op or (last_op == new_op == Operation.SELECT):
     47     self = self._convert_leaf_to_cte()
---> 48 df: t.Union[_BaseDataFrame, _BaseGroupedData] = func(self, *args, **kwargs)
     49 df.last_op = new_op  # type: ignore
     50 return df

File ~/scratch/.venv/lib/python3.12/site-packages/sqlframe/base/dataframe.py:998, in _BaseDataFrame.join(self, other_df, on, how, **kwargs)
    996 new_df.pending_join_hints.extend(self.pending_join_hints)
    997 new_df.pending_hints.extend(other_df.pending_hints)
--> 998 new_df = new_df.select.__wrapped__(new_df, *select_column_names)  # type: ignore
    999 return new_df

File ~/scratch/.venv/lib/python3.12/site-packages/sqlframe/base/dataframe.py:775, in _BaseDataFrame.select(self, *cols, **kwargs)
    773                 resolved_column_position[ambiguous_col] += 1
    774             else:
--> 775                 cte = ctes_with_column[resolved_column_position[ambiguous_col]]
    776             ambiguous_col.set("table", exp.to_identifier(cte.alias_or_name))
    777 # If an expression is `CAST(x AS DATETYPE)` then we want to alias so that `x` is the result column name

IndexError: list index out of range

I see. Yet again this can be worked around by providing an alias on the function.
Tonight I will try a different approach of automatically aliasing functions which should generally solve this. Thanks for reporting!

I think this is the right direction, but it is a big change. So it will take a bit. A workaround while doing this is to alias your functions.