mWeb - Chat - Unable to click on any attachments

If you haven’t already, check out our contributing guidelines for onboarding and email<EMAIL_ADDRESS>to request to join our Slack channel!

Action Performed:

Go to staging.expensify.cash
Log in with any account
Select any user to chat
Click on attachment and preview it

Expected Result:
Able to see the attachment in preview.
Actual Result:
Unable to click on attachment
Workaround:
Unknown
Platform:
Where is this issue occurring?
Web
iOS
Android
Desktop App
Mobile Web ✔
Version Number:  <IP_ADDRESS>
Logs: https://stackoverflow.com/c/expensify/questions/4856
Notes/Photos/Videos: Any additional supporting documentation
https://user-images.githubusercontent.com/43996225/124006023-c272c780-d9a7-11eb-9956-14679bd24680.mp4
Expensify/Expensify Issue URL:
View all open jobs on Upwork

Triggered auto assignment to @sketchydroide (Engineering), see https://stackoverflow.com/c/expensify/questions/4319 for more details.

:wave: Friendly reminder that deploy blockers are time-sensitive ⏱ issues! Check out the open StagingDeployCash deploy checklist to see the list of PRs included in this release, then work quickly to do one of the following:

Identify the pull request that introduced this issue and revert it.
Find someone who can quickly fix the issue.
Fix the issue yourself.

This can be retested as the regression which caused this is fixed.

Confirmed this is working on mWeb 🎉


docs(confluent): add details for actions pod for confluent

Checklist

[x] The PR conforms to DataHub's Contributing Guideline (particularly Commit Message Format)
[x] Links to related issues (if applicable)
[x] Tests for the changes have been added/updated (if applicable)
[x] Docs related to the changes have been added/updated (if applicable). If a new feature has been added a Usage Guide has been added for the same.
[x] For any breaking change/potential downtime/deprecation/big changes an entry has been made in Updating DataHub

Let's wait to merge this until we figure out what is going on here..

Agreed, seems like there are more issues than just the config instructions. If it's going to be in the guide it should work.


⚠ Bofrost.at has degraded performance

In 284150d, Bofrost.at (https://www.bofrost.at) experienced degraded performance:

HTTP code: 200
Response time: 1581 ms

Resolved: Bofrost.at performance has improved in 3d37eb8 after 1 hour, 8 minutes.


Bump minimum version to iOS 9

I just checked Apple's Developer Website and 92% of the iOS devices are using iOS 9 and up.

I think it would be better if we accepted iOS 9 and up.
What do you guys think? 🤔

LGTM 🙌

[x] Me
[x] @vsouza
[x] @victorgama
[ ] @dkhamsing

+1 for iOS 9+
I am also seeing problems on iOS 8.1 simulators during an xcodebuild test which I do not think Apple is going to fix anytime soon.
This also confirms it:
https://david-smith.org/iosversionstats/

Yes its time to drop iOS 8!

Any update on this one?

I believe we had enough positive feedback to validate the change. Thank you all.

@lfarah you should update https://github.com/vsouza/awesome-ios/blob/master/.github/PULL_REQUEST_TEMPLATE.md also :)

Hooray! :+1:


update thanos-receive-controller img due  to upgrade golang to 1.16

https://github.com/open-cluster-management/backlog/issues/11916
https://github.com/observatorium/thanos-receive-controller/pull/76
Signed-off-by: Song Song Li<EMAIL_ADDRESS>

/lgtm

/test test-e2e

/retest

/retest


Please add support for MTProxy is behind HAProxy

My MTProxy is behind nginx and I have to use proxy_protocol but all the statistics becomes <IP_ADDRESS> pretty much useless.
Would you please add support for proxy_protocol ?
PROXY_PROTOCOL = True
Like this does support proxy_protocol.
https://github.com/alexbers/mtprotoproxy

I try to add this capability to proxy. Thanks for your suggestion.


Switch S3 paths to use virtual-style pathing

To resolve issue https://github.com/chef-customers/aws_native_chef_server/issues/59

Thank you for your contribution @jeffj254 !!
I'm pretty sure this will lint cleanly but we'll see that for sure as soon as I hit the merge button


[DNM] Dev prov test

Issue #, if available:
Description of changes:
Adding nucleus changes for device provisioning using plugins
Why is this change necessary:
How was this change tested:
Unit tests
POC running local plugin
Any additional information or context required to review the change:
Checklist:

[ ] Updated the README if applicable
[x] Updated or added new unit tests
[x] Updated or added new integration tests
[ ] Updated or added new end-to-end tests
[ ] If your code makes a remote network call, it was tested with a proxy

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

No major concerns, only a few minor comments, otherwise LGTM


renovatebot(deps): update ribbon to v2.7.17

This PR contains the following updates:

Package
Update
Change
References

com.netflix.ribbon:ribbon
patch
2.7.16 -> 2.7.17
homepage

com.netflix.ribbon:ribbon-eureka
patch
2.7.16 -> 2.7.17
homepage

com.netflix.ribbon:ribbon-httpclient
patch
2.7.16 -> 2.7.17
homepage

com.netflix.ribbon:ribbon-loadbalancer
patch
2.7.16 -> 2.7.17
homepage

com.netflix.ribbon:ribbon-transport
patch
2.7.16 -> 2.7.17
homepage

Renovate configuration
:date: Schedule: At any time (no schedule defined).
:vertical_traffic_light: Automerge: Disabled by config. Please merge this manually once you are satisfied.
:recycle: Rebasing: Whenever PR is stale, or if you modify the PR title to begin with "rebase!".
:no_bell: Ignore: Close this PR and you won't be reminded about these updates again.

[ ] If you want to rebase/retry this PR, check this box

Available now for Enterprise: Renovate Pro with real-time webhook handling and priority job queue.

 Thank you for your submission, we really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.null seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account.You have signed the CLA already but the status is still pending? Let us recheck it.

 Thank you for your submission, we really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.null seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account.You have signed the CLA already but the status is still pending? Let us recheck it.


Modified binding-engine API

This is related to #194.
I did a few modifications to the bindingEngine public API but there are quite a few things that you should be aware of.

It's not well tested <_<

I considered bindingEngine is for "outside" usage. If something depends on it I did not update it.

The main changes are:

I merged propertyObserver and expressionObserver into a single method observer(scope, expression). It has a fast-path where expression is a simple property then it would use simpler code (basically the old propertyObserver code).

I extended collectionObserver with an optional expression string. Idea is that you can call it like before: collectionObserver(myArray) or you can observe an expression that evaluates to a collection, similar to how observer() can observe an expression: collectionObserver(scope, 'selectedUser.orders'), which is handy.

Some implementation notes:

For my collection expression observer, I had to add an evaluate method to the result of observer(scope, expr). It is handy and evaluates expr in the context of scope. I did not publicly publish it into the PropertyObserver contract, though. It may be useful to do so.

Speaking of the PropertyObserver interface, it was already a misnommer when returned from expressionObserver, it still is... ValueObserver perhaps?

I changed the collectionObserver contract so slightly by failing fast when receiving an invalid parameter, which is good practice for public APIs. I did so by moving the throw when scope is not an Array nor a Map outside of subscribe.

I do not know how to declare overloads properly with your typing transformer. collectionObserver should actually be typed as either (Array|Map) or (Object, string).

Notifying the callback when a collection expression changes is done directly. I was not sure if I should enqueue a micro task or something. This ought to be fine since it's called from inside a change notification (so already inside a micro-task, right?).

I invented a new array change record type: "reset", it's used when the array completely changed. It seems the array observation code does not quite do that when, say, an array is sorted but I couldn't figure it out. It's valuable to have such a notification, because on massive changes an array diff is just too costly and too big to be efficient or useful.

There is another API I would like to introduce: dependencyObserver(scope, path) with a specific use-case in mind, but I will stop here for now. (This API would be useful for scenarios such as @computedFrom or aurelia-validation computedFrom).

BTW sorry, I don't know what the diff is totally different. My guess is that it has to do with line-endings or tabs :(

@jods4- thanks for the PR.  We're in the middle of some heavy refactoring in templating/binding/etc- will look at this after we get that in.

@jods4 I'm going to close this PR for now. We've made some serious refactorings in there. Take a look and if you want consider submitting a new PR on top of the new stuff.

@EisenbergEffect So from what I see the API surface exposed is basically the same as before, but wrapped in a BindingEngine class.
My PR does not match the new code but is rather trivial to port to the new code.
The point it tackled where mostly public API design and I think my comments in #194 still apply.
This PR did the following things, which can still easily be done to BindingEngine:

propertyObserver() and expressionObserver() can easily be merged in a single entry point observer() that accepts any expression, with a fast path if the expression is just a property. It will be easier to use and understand.
Similarly, collectionObserver() could be extend to accept any path to an expression. Which will have a nice similarity with the observer() API above and is quite useful.

@jdanyow Your feedback is needed here. It would be a breaking change...so only if it can be completed by EOB Friday. Decision is up to you.

Apologies, I don't have time to work through all this, add tests, etc, before tomorrow with everything else that needs to get done for the beta.  We could make an additive change to the BindingEngine API in the future.
We should consider whether it would be useful for this omnipotent observer API to take into account the things we've added to the repeat in terms of expression unwrapping to enable observing collection mutation through value-converter boundaries.
It might also be beneficial to explore this API in a plugin and gather feedback from the rest of the community like we're doing with aurelia-async.
Does this sound reasonable?

I agree with @jdanyow that this API seems a bit rushed right now. There are many use-cases and many details that are not trivial to decide upon. Like observing paths, expressions, observing collections, observing dependencies only, handling behaviours (like signal), handling value converters...
I think it's a bit early to set this in stone and it needs more experimentations. Iterating on a plugin with feedback from more people seems like a very good idea.

Absolutely. We can always add things in the future. With the Beta, the main thing we want is to ensure no more breaking changes. We can still add new features for Beta 2. By the time we hit Beta 2, I want to have a feature freeze so that we can work solely on bug fixes, performance, quality for the v1 release. After that, we can add more new features again for v1.1 (but no breaking changes).


Echoing multiple lines in exit_cb handler not working

Works:
call job_start('true', {'exit_cb': {-> execute('echo "foo"', '')}})

This prints "foo", as expected.
Does not work:
call job_start('true', {'exit_cb': {-> execute('echo "foo\nbar"', '')}})

I'd expect this to print two lines (or at least one, the last one), but it prints none.

The echo command causes the text to scroll up.  Vim then fixes that by redrawing.  So that's working as intended.
You can either set 'cmdheight' to 2 or higher, or add a sleep to give the user a chance to read the message.

Hmm, I'm not sure I understand where the redraw is coming from.
I mean, assuming the default cmdheight=1, :echo "foo\nbar" prints 2 lines followed by the obligatory Press ENTER or type command to continue.
Why doesn't it work the same in the exit handler (without using :sleep)?

Hmm, I'm not sure I understand where the redraw is coming from.
I mean, assuming the default cmdheight=1, :echo "foo\nbar" prints
2 lines followed by the obligatory Press ENTER or type command to continue.
Why doesn't it work the same in the exit handler (without using :sleep)?

The "press enter" prompt is part of the normal interactive command loop.
It is not used for asynchronous messages.  These asynchronous callbacks
can be invoked any time, they are not supposed to interrupt what the
user is doing.  Vim makes sure the screen is updated, which means
messages may be cleared. If you want to make sure they show up you could
open a window to put the message in.
--
hundred-and-one symptoms of being an internet addict:
127. You bring your laptop and cellular phone to church.
/// Bram Moolenaar --<EMAIL_ADDRESS>-- http://www.Moolenaar.net   \
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \
\\  an exciting new programming language -- http://www.Zimbu.org        ///
\\            help me help AIDS victims -- http://ICCF-Holland.org    ///


Fix sed inplace option to run with both GNU and OSX sed

The sed 'inplace' argument used in the update script seems to be specific to OSX sed and the script complains "sed: can't read : No such file or directory" when running GNU sed used by Linux distributions. I assume an explicit creation of the backup file then removing it will make both systems happy. Only tested with GNU sed, can a OSX user confirm this workaround is ok ?

Thanks!


Side Navigation for categories

Hi,
Does someone have any idea how te create a side navigation for all the categories (also children (sub categories)). If a Child (sub category) is selected i want the parent collapsed/selected and the child selected:
Category 1
Category 2 (selected)
Category 2.1
Category 2.2 (selected)
Category 2.3
Category 3
Category 4

Hi Sander,
You can do something like this:
var currentCategory = Catalog.GetCategory();
foreach (var category in Catalog.GetAllRootCategories().OrderBy(x =>
x.SortOrder))
{
var currentCategoryTrue = currentCategory != null && category.Id ==
currentCategory.Id; var categoryIsParentOfCurrent = currentCategory != null
&& currentCategory.Path.Contains(category.Id.ToString());
 @category.Title @if(category.Categories.Any()){
if (currentCategoryTrue || categoryIsParentOfCurrent) {
@RenderCategories(category)  } }  }
@helper RenderCategories(uWebshop.Domain.Category category)
{
var currentCategory = Catalog.GetCategory();
foreach (var subcategory in category.Categories.OrderBy(x => x.SortOrder))
{
var subcssClass = string.Empty;
var currentCategoryTrue = currentCategory != null && subcategory.Id ==
currentCategory.Id;
var categoryIsParentOfCurrent = currentCategory != null &&
currentCategory.Path.Contains(subcategory.Id.ToString());

@subcategory.Title
        @if(subcategory.Categories.Any())
{
if(currentCategoryTrue || categoryIsParentOfCurrent)
{

@RenderCategories(subcategory)

}
}

}
}
Kindest Regards
Tom Steer
Lead Web Developer, V8Media Ltd
T: 01432 268175
I: www.v8media.co.uk
My Working Hours: Monday - Thursday (8:00 - 4:15)
Office Hours: Monday - Friday (9:00 - 5:00)
Link to Us
http://www.linkedin.com/company/v8media?trk=hb_tab_compy_id_568254
Read our Blog http://blog.v8media.co.uk/
Tweet Us https://twitter.com/V8MediaUK
Like Us http://www.facebook.com/v8mediaUK
V8Media Ltd. Registered in England No. 07032824, Suite 203, Berrows
Business Centre, Bath Street, Hereford, HR1 2HE
On 12 February 2015 at 13:24, Sander Nieling<EMAIL_ADDRESS>wrote:

Hi,
Does someone have any idea how te create a side navigation for all the
categories (also children (sub categories)). If a Child (sub category) is
selected i want the parent collapsed/selected and the child selected:
Category 1
Category 2 (selected)
Category 2.1
Category 2.2 (selected)
Category 2.3
Category 3
Category 4
—
Reply to this email directly or view it on GitHub
https://github.com/uWebshop/uWebshop-Releases/issues/20.

Dear Tom,
Thanks but something went wrong...
'uWebshop.API.ICategory' does not contain a definition for 'Path' and no extension method 'Path' accepting a first argument of type 'uWebshop.API.ICategory' could be found (are you missing a using directive or an assembly reference?)
I'm in between to versions of uWebshop (i guess) so maybe I'm missing something!?

Looks like Path may have been removed since I last worked with uWebshop but
it looks like there is a GetUmbracoPath() extension method for all uwebshop
entities.
Kindest Regards
Tom Steer
Lead Web Developer, V8Media Ltd
T: 01432 268175
I: www.v8media.co.uk
My Working Hours: Monday - Thursday (8:00 - 4:15)
Office Hours: Monday - Friday (9:00 - 5:00)
Link to Us
http://www.linkedin.com/company/v8media?trk=hb_tab_compy_id_568254
Read our Blog http://blog.v8media.co.uk/
Tweet Us https://twitter.com/V8MediaUK
Like Us http://www.facebook.com/v8mediaUK
V8Media Ltd. Registered in England No. 07032824, Suite 203, Berrows
Business Centre, Bath Street, Hereford, HR1 2HE
On 12 February 2015 at 14:10, Sander Nieling<EMAIL_ADDRESS>wrote:

Dear Tom,
Thanks but something went wrong...
'uWebshop.API.ICategory' does not contain a definition for 'Path' and no
extension method 'Path' accepting a first argument of type
'uWebshop.API.ICategory' could be found (are you missing a using directive
or an assembly reference?)
I'm in between to versions of uWebshop (i guess) so maybe I'm missing
something!?
—
Reply to this email directly or view it on GitHub
https://github.com/uWebshop/uWebshop-Releases/issues/20#issuecomment-74076013
.

Got it working, I used some old namespaces and everything worked again.


Publish MQTT Last Will and Testament

Is your feature request related to a problem? Please describe.
Sometimes my tablet with WallPanel running loses WiFi connection.
I'd like to add automation to HA to check whether the tablet is connected.
Describe the solution you'd like
WallPanel publishes its state (Online/Offline) with retain flag in its LWT topic
Describe alternatives you've considered
I can use battery status or the like, but it is non-standard and requires more code/less reliable compared to LWT

If your device has no WiFi there is no way to communicate with HA and report it has not WiFi.   Just have HA ping the device by IP address or check the devices on your network.

Ping is not the right way if we have MQTT.
Could you have a read about how LWT works and comment back?
Also, is it possible to have feedback on mqtt commands in state topic?

any chance to have it included in one of the next betas?
hope it's not a HUGE task..

As far as I now, nobody has taken up the lead on this.  Do you have a pull request for this?


Foundation Documentation

[ ] what do we have now @clastzoo & @hirsch88

[ ] extract the common sense diff old to new @clastzoo & @hirsch88

[ ] check other design systems @Gagne87

[ ] get the pain points of the users of the docs @mladenplaninicic & @hirsch88

[ ] start creating the blueprint

[ ] make user tests

https://www.figma.com/file/CWbj6tAqdWkpkRHEgle5V5/Structure?node-id=1314%3A3217&t=BGWT1NAV6zwDudBl-11

https://www.duetds.com/
https://designsystem.axa.com/development
https://sdx.swisscom.ch/
https://design.gitlab.com/
https://carbondesignsystem.com/components/button/usage/
https://www.audi.com/ci/en/renewed-brand.html
https://telekom.github.io/scale/?path=/docs/setup-info-scale-and-angular--page&globals=locale:en;colorMode:dark
https://www.decathlon.design/726f8c765/p/189012-logo/b/452ccc


Mac pkill wiki not appearing

Removed template as this issue pertains to the repository.
The Readme references a link to the GitHub wiki for the following:
Read here if your mac has /usr/local/bin/pkill.
"Here" is linking to: https://github.com/rogalmic/vscode-zsh-debug/wiki/macOS:-avoid-use-of--usr-local-bin-pkill
This link, as well as the Wiki, appears to be dead.

Looks like it's supposed to be https://github.com/rogalmic/vscode-bash-debug/wiki/macOS:-avoid-use-of--usr-local-bin-pkill.

Changed the link in README, thanks for pointing that out.


fix(dpg): duplicated names in CodeWriterScopeDecalarations

right now we don't try to resolve duplication in the names inside a CodeWriterScopeDeclarations which will generate fields with duplicated names, like the case in https://github.com/Azure/azure-sdk-for-net/issues/29223#issuecomment-1167917629
this commit will fix the issue:

try to assign a new name if the currently requested name is occupied
add unit test

Description
Add your description here!
Checklist
To ensure a quick review and merge, please ensure:

[ ] The PR has a understandable title and description explaining the why and what.
[ ] The PR is opened in draft if not ready for review yet.

If opened in draft, please allocate sufficient time (24 hours) after moving out of draft for review

[ ] The branch is recent enough to not have merge conflicts upon creation.

Ready to Land?

[ ] Build is completely green

Submissions with test failures require tracking issue and approval of a CODEOWNER

[ ] At least one +1 review by a CODEOWNER
[ ] All -1 reviews are confirmed resolved by the reviewer

Override/Marking reviews stale must be discussed with CODEOWNERS first

preview change in sdk repo: https://github.com/Azure/azure-sdk-for-net/pull/30502


Change Sub-menu Text

Describe the bug
In the "ui_dashboard.html" page, we have the "UI Dashboard" sub-menu under Pages in the top Bar. Please change "UI Dashboard" to "Dashboard" and run the redirect to "dashboard.html" page.
File/Files you will work on
ui_dashbaord.html
Possible Lines of Code
Adjust already working content instead of adding more lines of code.
Result or Final Looks
We are suppose to redirect the user to the dashboard environment from the "UI dashboard" and not to the same page.

Hi! I want to work on this issue.

It has been assigned to you.

Please review the PR.


sched::clone doesn't pass ownership of closure to new thread.

The current implementation of of sched::clone doesn't pass ownership of the the closure called by callback into the newly created thread, only a reference. This means that when the call to clone ends, the callback is actually dropped, releasing all associated memory. This most likely means that the closure that actually gets run in the child thread is a reference to invalid memory when it is run.
Recommended fix is to unbox the CloneCb into a raw pointer and box it back up again in callback. This would mean that the closure would be dropped at the end of the callback in the child thread, rather than at the end of the call to clone.

I'll have a patch in a few minutes.

Without https://github.com/rust-lang/rust/issues/28796 being stabilised, std::sched::clone shouldn't support actual closures at all. It makes no sense for clone to accept a closure with references as the child thread then assumes that everything being referenced lives longer than itself and the parent thread assumes that all borrows that the child thread had were dropped when the call to clone succeeded.
In light of this, I think I'll make a patch to change clone to accept something more like what the syscall does now (i.e. fn(T) -> isize with a T passed into clone.

This is still a problem, and makes clone completely broken (rather than the expected horribly unsafe because it's clone). FnBox has been fixed for a while, though it would be a breaking change to improve CloneCb to be Box<FnOnce()> instead of Box<FnMut()>. That said, fixing the other correctness issues there to make it Box<FnMut() -> isize + Send + 'static> instead would also be breaking, so might as well make it FnOnce() at the same time.
On top of that &mut [u8] is not a great choice for the stack type, as you need the borrow for up to 'static, not just for the duration of clone(), and the most obvious ways to allocate [u8; stack size] will break in practice.

@talchas would you like to try rewriting clone?  I wouldn't worry about preserving backwards-compatibility; it probably can't be done in a way that also fixes clone's problems.

I'd go with
    pub fn clone<F: FnOnce() -> c_int + Send + 'static>(
        cb: F,
        stack: *mut [u8],
        flags: CloneFlags,
        signal: Option<c_int>,
    ) -> Result<Pid> {
        extern "C" fn callback<F: FnOnce() -> c_int + Send + 'static>(data: *mut c_void) -> c_int {
            let cb: Box<F> = unsafe { Box::from_raw(data as *mut F) };
            (*cb)()
        }

        let cb = Box::into_raw(Box::new(cb));
        let res = unsafe {
            let combined = flags.bits() | signal.unwrap_or(0);
            let ptr = (stack as *mut u8).add((*stack).len());
            let ptr_aligned = ptr.sub(ptr as usize % 16);
            libc::clone(
                callback::<F>,
                ptr_aligned as *mut c_void,
                combined,
                cb as *mut c_void,
            )
        };
        let res = Errno::result(res).map(Pid::from_raw);

        // In CLONE_VM we need to free the callback on both sides
        if flags.contains(CloneFlags::CLONE_VM) || res.is_err() {
            unsafe { Box::from_raw(cb); }
        }

        res
    }

but there's a lot of fairly reasonable bikeshed options: taking *mut F (and probably having users just leak it or do it wrong) or Box<FnOnce() -> c_int + Send + 'static>, maybe taking Box<[u8]> for stack. Then there's the option of not doing closures at all since they're still kinda sketchy in CLONE_VM (anything calling into the allocator in the new mostly-process is), though then the benefit vs libc is small.

Taking raw pointers isn't much better than having the user call FFI functions directly.  Could stack be a &'static mut [u8] instead?  Granted, it would probably have to be unsafely created.  Or if you take Box<[u8]> for the stack, who would be responsible for deallocating it, the parent, the child, or both?
What's the point of taking a closure argument if it must be 'static?  Is that any different than taking a plain function pointer?  If there is a good reason to use a closure argument, then your Box::into_raw logic looks correct.
I think your logic for CLONE_VM is backwards.  The parent should free the callback, unless that flag is set.
Finally, this function should definitely be unsafe.

Yeah, I didn't do &'static because it would need unsafe anyways, and didn't do Box<[]> because of the freeing issues, and statically allocating a buffer is maybe useful sometimes.
You still want a closure, even if it's 'static; you can move in a String/ints/anything else owned still.
Yes, I forgot which way around CLONE_VM worked, and making it unsafe is probably good too.

Hm.  The child process/thread thing will never free stack, and unless CLONE_VM is set then the parent can do whatever it wants with the stack after return.  So maybe it doesn't need to be 'static.  Would it be better to make stack a &mut [u8], with a note in the documentation that it must outlive the child process if CLONE_VM is set?  Or should we remove CLONE_VM from CloneFlags, and create a separate clone_vm function that requires a static array for stack?

Having a separate CLONE_VM certainly could be reasonable, as the mechanics around memory safety and lifetimes are completely different. For non-VM ones you can drop the 'static requirement, use &mut [u8], and use &mut cb rather than boxing it (but that one definitely should be unsafe for similar reasons to CommandExt::pre_exec).
Looking more at clone(2), I guess there's also the issue that all the SETTID/CLEARTID/PIDFD stuff causes it to write to the varargs slots which there is no way to fill in, so setting those flags has no use other than being UB. Similarly, SETTLS can't be specified, and I guess would be reason enough to make clone_vm() be unsafe as well, since tls is assumed to be set up properly for safe code.

Yeah, good catch.  You should remove those flags too, or create separate functions to enable their use.


Browser testing

In #615 I suggested it would be possible to write a generic tool for running tests in the browser. I now have a proof of concept here: https://github.com/tombentley/osric. This issue is to figure out if that tool is part of ceylon.test or should remain distinct.
The proof of concept is composed of two parts. The server module is a http server built on top of ceylon.http.server which serves up:

an index page
require.js
a ceylon reop
and calls the client module's run().

The client module basically just runs ceylon.test on the given module, but using a TestListener which will report back to the server.
Things to resolve include:

Is this really generally useful enough to merit inclusion in ceylon.test?

A lot of browser stuff is interactive and no not a natural fit for ceylon.test which is aimed more at automated unit testing. OTOH it would be good to be able to unit test things without having to do it manually in the browser.

Currently the ceylon.test event classes are not serializable, so the proof of concept serializes them "by hand".

People will also want to be able to run tests using browsers they don't have installed locally. That's probably not something ceylon.test should get too deeply mired in.

Not everyone's browsers will be on the $PATH or called the same thing, so we probably need a configgable list of browsers local to each project/user.

So what do people think? Is this something that ceylon.test should provide OOTB, or should it be a 3rd party thing. If it's something for ceylon.test what's the minimal functionality it should have before we would be willing to merge it?

I'm not sure about this approach, because people would want to use it for testing their web applications, they would need control mouse/keyboard interaction, browser windows, browser alert/prompt dialogs, taking screenshots of current page when assertion fails, etc. ... so I'm curious if Selenium WebDriver wouldn't be better for it.

@thradec, exactly: The question is how useful is it to run unit tests in the browser, because ceylon.test isn't going to go into interactive testing a la Selenium. My feeling is that it's only of marginal use, so I'm erring towards leaving ceylon.test completely alone and essentially merging a copy of the proof of concept into the sdk tests for ceylon.interop.browser, simply so we have tests for that.


Ensure UniqueCandidateList checks for unique phone, unique email and/or unique studentId?

kiv for discussion

Addressed under issue #102


Create helper methods on BeamLocation (Suggestion)

Hey there!
Loving the new updates to this package, API has become much cleaner with the recent releases.
I find that I'm constantly using state.pathBlueprintSegments.contains(...) and state.pathParameters.containsKey(...) etc... So thought it would be useful to create methods such as:
  bool contains(String pathSegment) =>
      _state.pathBlueprintSegments.contains(pathSegment);

As a way of keeping the API uncluttered, maybe this could be added as an extension on BeamLocation?
Lemme know your thoughts :) thanks as always!

Indeed, great idea! 😃
Will do.


debug/elf: does not properly apply DWARF RELA relocations

What version of Go are you using (go version)?

go version go1.14.4 linux/amd64

Does this issue reproduce with the latest release?
Yes
What operating system and processor architecture are you using (go env)?
go env Output
$ go env
GO111MODULE=""
GOARCH="amd64"
GOBIN=""
GOCACHE="/home/vic/.cache/go-build"
GOENV="/home/vic/.config/go/env"
GOEXE=""
GOFLAGS=""
GOHOSTARCH="amd64"
GOHOSTOS="linux"
GOINSECURE=""
GONOPROXY=""
GONOSUMDB=""
GOOS="linux"
GOPATH="/home/vic/go"
GOPRIVATE=""
GOPROXY="https://proxy.golang.org,direct"
GOROOT="/usr/lib/go-1.14"
GOSUMDB="sum.golang.org"
GOTMPDIR=""
GOTOOLDIR="/usr/lib/go-1.14/pkg/tool/linux_amd64"
GCCGO="gccgo"
AR="ar"
CC="gcc"
CXX="g++"
CGO_ENABLED="1"
GOMOD="/home/vic/go/src/test/test/go.mod"
CGO_CFLAGS="-g -O2"
CGO_CPPFLAGS=""
CGO_CXXFLAGS="-g -O2"
CGO_FFLAGS="-g -O2"
CGO_LDFLAGS="-g -O2"
PKG_CONFIG="pkg-config"
GOGCCFLAGS="-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build635738080=/tmp/go-build -gno-record-gcc-switches"

What did you do?
I'm trying to get the PC ranges from the Linux kernel DWARF information:
1) Get the debug version of any mainstream Linux Kernel image, uncompressed (disclaimer: it's big!)
wget http://http.us.debian.org/debian/pool/main/l/linux/linux-image-4.19.0-10-amd64-dbg_4.19.132-1_amd64.deb
ar x linux-image-4.19.0-10-amd64-dbg_4.19.132-1_amd64.deb
tar xf data.tar.xz
# The vmlinux image should be at usr/lib/debug/vmlinux-4.19.0-10-amd64

2) Get the DIE offset for a compilation unit (here I'm using ./init/main.c)
$ llvm-dwarfdump usr/lib/debug/vmlinux-4.19.0-10-amd64 --name=./init/main.c | grep DW_TAG_compile_unit
0x000217db: DW_TAG_compile_unit

3) Try to use the debug/elf and debug/dwarf libraries to print the PC ranges for this CU:
package main

import (
	"debug/elf"
	"fmt"
	"log"
)

func main() {
	file, err := elf.Open("usr/lib/debug/vmlinux-4.19.0-10-amd64")
	if err != nil {
		log.Fatal(err)
	}
	defer file.Close()

	dw, err := file.DWARF()
	if err != nil {
		log.Fatal(err)
	}

	reader := dw.Reader()
	reader.Seek(0x000217db) // Offset value is from llvm-dwarfdump output

	// Read entry at that offset
	entry, err := reader.Next()
	if err != nil {
		log.Fatal(err)
	}

	// Read PC ranges from DIE
	ranges, err := dw.Ranges(entry)
	if err != nil {
		log.Fatal(err)
	}

	for i := range ranges {
		fmt.Printf("range %d: [0x%x, 0x%x]\n", i, ranges[i][0], ranges[i][1])
	}
}

What did you expect to see?
One can use llvm-dwarfdump to show the correct PC ranges for this DIE:
$ llvm-dwarfdump usr/lib/debug/vmlinux-4.19.0-10-amd64 --name=./init/main.c
usr/lib/debug/vmlinux-4.19.0-10-amd64:	file format ELF64-x86-64

0x000217db: DW_TAG_compile_unit
[...]
              DW_AT_ranges	(0x000023e0
                 [0xffffffff810020b0, 0xffffffff81002983)
                 [0xffffffff81002983, 0xffffffff8100298b)
                 [0xffffffff82457574, 0xffffffff82457589)
                 [0xffffffff82457589, 0xffffffff8245759b)
                 [0xffffffff8245759b, 0xffffffff824575ad)
                 [0xffffffff824575ad, 0xffffffff824575d9)
                 [0xffffffff824575d9, 0xffffffff82457605)
                 [0xffffffff82457605, 0xffffffff82457693)
                 [0xffffffff82457693, 0xffffffff824576e9)
                 [0xffffffff824576e9, 0xffffffff8245773e)
                 [0xffffffff8245773e, 0xffffffff824578d3)
                 [0xffffffff8100298b, 0xffffffff810029b9)
                 [0xffffffff81722909, 0xffffffff817229b3)
                 [0xffffffff810029b9, 0xffffffff810029f7)
                 [0xffffffff810029f7, 0xffffffff81002a26)
                 [0xffffffff824578d3, 0xffffffff824578fb)
                 [0xffffffff824578fb, 0xffffffff82457920)
                 [0xffffffff82457920, 0xffffffff82457978)
                 [0xffffffff82457978, 0xffffffff824579d3)
                 [0xffffffff824579d3, 0xffffffff82457aa7)
                 [0xffffffff82457aa7, 0xffffffff82457ab8)
                 [0xffffffff81002a26, 0xffffffff81002a6d)
                 [0xffffffff82457ab8, 0xffffffff82457ac2)
                 [0xffffffff82457ac2, 0xffffffff82457aea)
                 [0xffffffff82457aea, 0xffffffff82457b5b)
                 [0xffffffff82457b5b, 0xffffffff82457b61)
                 [0xffffffff82457b61, 0xffffffff82457b67)
                 [0xffffffff82457b67, 0xffffffff82457b6d)
                 [0xffffffff82457b6d, 0xffffffff82457b73)
                 [0xffffffff82457b73, 0xffffffff824580a2)
                 [0xffffffff824580a2, 0xffffffff824582ba)
                 [0xffffffff817229b3, 0xffffffff81722ab2))
[...]

What did you see instead?
The displayed ranges seem to be completely off:
$ ./test
range 0: [0x20b0, 0x2983]
range 1: [0x2983, 0x298b]
range 2: [0x574, 0x589]
range 3: [0x589, 0x59b]
range 4: [0x59b, 0x5ad]
range 5: [0x5ad, 0x5d9]
range 6: [0x5d9, 0x605]
range 7: [0x605, 0x693]
range 8: [0x693, 0x6e9]
range 9: [0x6e9, 0x73e]
range 10: [0x73e, 0x8d3]
range 11: [0x298b, 0x29b9]
range 12: [0x722909, 0x7229b3]
range 13: [0x29b9, 0x29f7]
range 14: [0x29f7, 0x2a26]
range 15: [0x8d3, 0x8fb]
range 16: [0x8fb, 0x920]
range 17: [0x920, 0x978]
range 18: [0x978, 0x9d3]
range 19: [0x9d3, 0xaa7]
range 20: [0xaa7, 0xab8]
range 21: [0x2a26, 0x2a6d]
range 22: [0xab8, 0xac2]
range 23: [0xac2, 0xaea]
range 24: [0xaea, 0xb5b]
range 25: [0xb5b, 0xb61]
range 26: [0xb61, 0xb67]
range 27: [0xb67, 0xb6d]
range 28: [0xb6d, 0xb73]
range 29: [0xb73, 0x10a2]
range 30: [0x10a2, 0x12ba]
range 31: [0x7229b3, 0x722ab2]

What seems to be the problem?
There seems to be a problem with the way relocations are applied to the PC ranges.
Here are the relevant relocations for this DIE - looked up with readelf -r. The offset 0x000023e0 is shown above in the DW_AT_ranges attribute.
Relocation section '.rela.debug_ranges' at offset 0x1f561d40 contains 923208 entries:
  Offset          Info           Type           Sym. Value    Sym. Name + Addend
0000000023e0<PHONE_NUMBER>01 R_X86_64_64       ffffffff81000000 .text + 20b0
0000000023e8<PHONE_NUMBER>01 R_X86_64_64       ffffffff81000000 .text + 2983
0000000023f0<PHONE_NUMBER>01 R_X86_64_64       ffffffff81000000 .text + 2983
0000000023f8<PHONE_NUMBER>01 R_X86_64_64       ffffffff81000000 .text + 298b
000000002400<PHONE_NUMBER>01 R_X86_64_64       ffffffff82457000 .init.text + 574
000000002408<PHONE_NUMBER>01 R_X86_64_64       ffffffff82457000 .init.text + 589
000000002410<PHONE_NUMBER>01 R_X86_64_64       ffffffff82457000 .init.text + 589
000000002418<PHONE_NUMBER>01 R_X86_64_64       ffffffff82457000 .init.text + 59b
000000002420<PHONE_NUMBER>01 R_X86_64_64       ffffffff82457000 .init.text + 59b
000000002428<PHONE_NUMBER>01 R_X86_64_64       ffffffff82457000 .init.text + 5ad
000000002430<PHONE_NUMBER>01 R_X86_64_64       ffffffff82457000 .init.text + 5ad
000000002438<PHONE_NUMBER>01 R_X86_64_64       ffffffff82457000 .init.text + 5d9
000000002440<PHONE_NUMBER>01 R_X86_64_64       ffffffff82457000 .init.text + 5d9
000000002448<PHONE_NUMBER>01 R_X86_64_64       ffffffff82457000 .init.text + 605
000000002450<PHONE_NUMBER>01 R_X86_64_64       ffffffff82457000 .init.text + 605
000000002458<PHONE_NUMBER>01 R_X86_64_64       ffffffff82457000 .init.text + 693
000000002460<PHONE_NUMBER>01 R_X86_64_64       ffffffff82457000 .init.text + 693
000000002468<PHONE_NUMBER>01 R_X86_64_64       ffffffff82457000 .init.text + 6e9
000000002470<PHONE_NUMBER>01 R_X86_64_64       ffffffff82457000 .init.text + 6e9
000000002478<PHONE_NUMBER>01 R_X86_64_64       ffffffff82457000 .init.text + 73e
000000002480<PHONE_NUMBER>01 R_X86_64_64       ffffffff82457000 .init.text + 73e
000000002488<PHONE_NUMBER>01 R_X86_64_64       ffffffff82457000 .init.text + 8d3
000000002490<PHONE_NUMBER>01 R_X86_64_64       ffffffff81000000 .text + 298b
000000002498<PHONE_NUMBER>01 R_X86_64_64       ffffffff81000000 .text + 29b9
0000000024a0<PHONE_NUMBER>01 R_X86_64_64       ffffffff81000000 .text + 722909
0000000024a8<PHONE_NUMBER>01 R_X86_64_64       ffffffff81000000 .text + 7229b3

As we can see, these relocations are relative to the .text and .init.text sections. If we do the math, adding Addend to Sym.Value, the result is exactly the output from llvm-dwarfdump above.
However, the Go program behaves differently. After looking into it, the culprit seems to be the following, in debug/elf/file.go:
// relocSymbolTargetOK decides whether we should try to apply a
// relocation to a DWARF data section, given a pointer to the symbol
// targeted by the relocation. Most relocations in DWARF data tend to
// be section-relative, but some target non-section symbols (for
// example, low_PC attrs on subprogram or compilation unit DIEs that
// target function symbols), and we need to include these as well.
// Return value is a pair (X,Y) where X is a boolean indicating
// whether the relocation is needed, and Y is the symbol value in the
// case of a non-section relocation that needs to be applied.
func relocSymbolTargetOK(sym *Symbol) (bool, uint64) {
        if ST_TYPE(sym.Info) == STT_SECTION {
                return true, 0
        }
        if sym.Section != SHN_UNDEF && sym.Section < SHN_LORESERVE {
                return true, sym.Value
        }
        return false, 0
}

Not sure if I'm reading this correctly, but the first if statement seems to assume that relocations relative to sections are either absolute relocations, or that the section addresses are always 0. But this is not the case here.
After removing this offending if statement, the output of the above program is correct again and matches the llvm-dwarfdump output:
$ ./test
range 0: [0xffffffff810020b0, 0xffffffff81002983]
range 1: [0xffffffff81002983, 0xffffffff8100298b]
range 2: [0xffffffff82457574, 0xffffffff82457589]
range 3: [0xffffffff82457589, 0xffffffff8245759b]
range 4: [0xffffffff8245759b, 0xffffffff824575ad]
range 5: [0xffffffff824575ad, 0xffffffff824575d9]
range 6: [0xffffffff824575d9, 0xffffffff82457605]
range 7: [0xffffffff82457605, 0xffffffff82457693]
range 8: [0xffffffff82457693, 0xffffffff824576e9]
range 9: [0xffffffff824576e9, 0xffffffff8245773e]
range 10: [0xffffffff8245773e, 0xffffffff824578d3]
range 11: [0xffffffff8100298b, 0xffffffff810029b9]
range 12: [0xffffffff81722909, 0xffffffff817229b3]
range 13: [0xffffffff810029b9, 0xffffffff810029f7]
range 14: [0xffffffff810029f7, 0xffffffff81002a26]
range 15: [0xffffffff824578d3, 0xffffffff824578fb]
range 16: [0xffffffff824578fb, 0xffffffff82457920]
range 17: [0xffffffff82457920, 0xffffffff82457978]
range 18: [0xffffffff82457978, 0xffffffff824579d3]
range 19: [0xffffffff824579d3, 0xffffffff82457aa7]
range 20: [0xffffffff82457aa7, 0xffffffff82457ab8]
range 21: [0xffffffff81002a26, 0xffffffff81002a6d]
range 22: [0xffffffff82457ab8, 0xffffffff82457ac2]
range 23: [0xffffffff82457ac2, 0xffffffff82457aea]
range 24: [0xffffffff82457aea, 0xffffffff82457b5b]
range 25: [0xffffffff82457b5b, 0xffffffff82457b61]
range 26: [0xffffffff82457b61, 0xffffffff82457b67]
range 27: [0xffffffff82457b67, 0xffffffff82457b6d]
range 28: [0xffffffff82457b6d, 0xffffffff82457b73]
range 29: [0xffffffff82457b73, 0xffffffff824580a2]
range 30: [0xffffffff824580a2, 0xffffffff824582ba]
range 31: [0xffffffff817229b3, 0xffffffff81722ab2]

I'm a bit surprised that a vmlinux image has any relocations.  Why isn't the image fully linked?

So I'm a bit out of my depth here
Interestingly, all the relocations in .rela.debug_ranges are just an exact copy of .debug_ranges - at least on that image above, and on a few other I tried, so it seems totally superfluous.
--
Otherwise, the previous iteration of the code in debug/elf (prior to https://go-review.googlesource.com/c/go/+/195679/6/src/debug/elf/file.go ) had a comment saying:
		// There are relocations, so this must be a normal
		// object file, and we only look at section symbols,
		// so we assume that the symbol value is 0.

I'm really no ELF/DWARF expert, but I don't understand the rationale behind "we assume that the symbol value is 0"

Digged into it a bit more - this is due to CONFIG_X86_NEED_RELOCS in the kernel config (indeed related to CONFIG_RELOCATABLE):
https://github.com/torvalds/linux/blob/18445bf405cb331117bc98427b1ba6f12418ad17/arch/x86/Makefile#L198
so it looks like passing --emit-relocs to the linker can potentially cause breakage, if I can trigger the emission of a DW_AT_ranges attribute. I'll try to provide a self-contained test-case that doesn't depend on a 500MiB ELF file

Ok, here's a standalone repro case: https://github.com/vikmik/dwarf-relocation-golang-bug
This builds a little binary with --emit-relocs.
I used a linker script to force the use of multiple code sections (with one hardcoded address), to make sure .debug_ranges / DW_AT_ranges is used.
You should be able to just run make to see the issue

For now I suppose we'll have to fork debug/elf to make our code happy.
However I'm not sure that removing the if statement that checks the symbol type (and return 0 if it's a section) is the right thing to do. It seems sane to me, but I am also fairly confident that I'm missing something :) If you have any advice to share, I'm all ears.
Thanks! Happy to provide more info if needed

FWIW, I suspect the reason the kernel is not fully linked is related to https://lore.kernel.org/patchwork/patch/499246/


Ability to remove form-validation-state values before bootstrap variables is loaded

I'm working on a project whereby I can't include anything between _variables.scss file and _forms.scss and therefore am unable to use map-remove() to remove the "valid" form-validation-state before it's too late. What I can do is set "valid" to an empty map before the variables are loaded, but then there are errors when _forms.scss calls the form-validation-state() mixin. I'm wondering if there is any sense in adding a check to see if "color" and "icon" exist before calling the mixin, like so:
@each $state, $data in $form-validation-states {
  @if map_has_key($data, color) and map_has_key($data, icon) {
    @include form-validation-state($state, map-get($data, color), map-get($data, icon));
  }
}

At first, I had a negative impression of this proposal, but after thinking about this for a while I became interested.
I look not only at validation but also the whole. Currently, the way to remove items from a map, such as theme colors, requires a lot of work (import each our sass files), but addition and modification are easy.
But if we can do the following controls, customization will be easier and consistancy:
$theme-colors: (
  "primary": #0074d9, // Modify
  "custom-color": #900 // Add
  "info": null // Remove!!
);

// Bootstrap and its default variables
@import "../node_modules/bootstrap/scss/bootstrap";

Necessary changes in Bootstrap may be:
@each $color, $value in $theme-colors {
  @if ($value != null) {
    .alert-#{$color} {
      @include alert-variant(theme-color-level($color, $alert-bg-level), theme-color-level($color, $alert-border-level), theme-color-level($color, $alert-color-level));
    }
  }
}

Yes I agree it should be broader than validation. The checking for null is a bit of a nuisance though. It would be handy if the map-merge function removed any keys with null values. I guess another approach would be to have another variable, e.g. $theme-colors-exclude: () !default; and immediately after the map-merge we loop through the exclusions and remove them from the map. That could possibly work better.

I think a cleaner solution might be to remove the map-merge of $form-validation-states in _variables.scss completely.
Sure, making form-validation-state ignore blank states works, but it feels like a clunky solution. Ideally, it would be easy to prevent the "valid" state from being added to $form-validation-states in the first place.
This currently isn't possible because the "valid" and "invalid" states are forcefully merged into whatever else $form-validation-states contains:
// bootstrap/scss/_variables.scss

$form-validation-states: () !default;

$form-validation-states: map-merge(
  (
    "valid": (
      "color": $form-feedback-valid-color,
      "icon": $form-feedback-icon-valid
    ),
    "invalid": (
      "color": $form-feedback-invalid-color,
      "icon": $form-feedback-icon-invalid
    ),
  ),
  $form-validation-states
);

Whereas if $form-validation-states was merely given a default value, it could easily be provided as a configuration variable, like all other bootstrap configuration:
// bootstrap/scss/_variables.scss

$form-validation-states: (
  "valid": (
    "color": $form-feedback-valid-color,
    "icon": $form-feedback-icon-valid
  ),
  "invalid": (
    "color": $form-feedback-invalid-color,
    "icon": $form-feedback-icon-invalid
  ),
) !default;

// my-app.scss

// ...other Bootstrap configuration here...

$form-validation-states: (
  "invalid": (
    "color": $form-feedback-invalid-color,
    "icon": $form-feedback-icon-invalid
  )
);

@import "bootstrap/scss/bootstrap";

Of course, this means you'd need to provide the color values. But chances are, if your Bootstrap configuration is sophisticated enough that you're customizing form states, you've likely already defined your own color variables.

Agree

If the suggestion by @kylefox solves this, that'll be addressed when we ditch all our map merges (see #28508). Thoughts @twbs/css-review?

I think ditching the map-merge()s is the way to go. It way easier to understand what's going on and easier to get control over what people (don't) want to generate.

Closing per last comment—the referenced PR has been merged into master for our upcoming v4 release.


Why use Event.sinkEvents+Event.setEventListener rather than element.addEventListener?

Even weirder that addEventListener is actually used in the nav list detail archetype for the submenus, mixed with Event.sinkEvents and Event.setEventListener for top menu items.

The reason for that is because top menu items are of type com.google.gwt.dom.client.AnchorElement, so they have no such method as addEventListener. The submenus are of type com.vaadin.polymer.paper.PaperItemElement which happen to have addEventListener.
is there a better solution?

Use an Anchor widget? .cast() the AnchorElement into a Vaadin EventTarget?

I am going to give it a try. Are there any recommendations against using '''Event.setEventListener''' ?


Will Langsmith open source in the future？

There is currently no plan to open source LangSmith, though we plan to keep the service free of charge for individuals


Initial changes to support topography

Modify domain, function space construction.
Add initial condition (WIP)
TODO: Align with ClimaCore topography packages.
modified:   ../../Domains/domain.jl
modified:   ../../Domains/make_function_space.jl
new file:   init_2d_mountain_advection.jl
Not functional [Dependency on ClimaCore.jl]

@akshaysridhar, is this still a relevant PR? If not, please close it.

Does #264 supersede this?


API bug in 1.9.3 with PHP7

As per this StackOverflow post, the new 1.9.3 version (only?) have a problem with the XML RPC response and PHP7 support:
http://magento.stackexchange.com/questions/140761/soap-connection-problems-after-1-9-3-0-update
The fix being to patch
Mage_Api_Model_Server_Handler_Abstract::processingMethodResult(array $result)
To look like this instead
public function processingMethodResult($result)
{
    if (is_array($result)) {
        foreach ($result as &$row) {
            if (!is_null($row) && !is_bool($row) && !is_numeric($row)) {
                if (is_array($row)) {
                    $row = $this->processingMethodResult($row);
                } else {
                    $row = $this->processingRow($row);
                }
            }
        }
    } else {
        if (!is_null($result) && !is_bool($result) && !is_numeric($result)) {
            $result = $this->processingRow($result);
        }
    }
    return $result;
}

Hopefully this will save someone a few hours. ;)

If you have objects in your results you can use the following code:
/**
     * Prepare Api data for XML exporting
     * See allowed characters in XML:
     * @link http://www.w3.org/TR/2000/REC-xml-20001006#NT-Char
     *
     */
    public function processingMethodResult($result)
    {
        /*original but broken code:
        foreach ($result as &$row) {
            if (!is_null($row) && !is_bool($row) && !is_numeric($row)) {
                $row = $this->processingRow($row);
            }
        }
        return $result;
        */
        if (is_array($result)) {
            foreach ($result as $key => $row) {
                if (is_object($row))
                {
                    continue;
                }

                if (!is_null($row) && !is_bool($row) && !is_numeric($row)) {
                    if (is_array($row)) {
                        $result[$key] = $this->processingMethodResult($row);
                    }
                    else {
                        $result[$key] = $this->processingRow($row);
                    }
                }
            }
        } else {
            if (!is_null($result) && !is_bool($result) && !is_numeric($result)) {
                $result = $this->processingRow($result);
            }
        }
        return $result;
    }

I also had to replace &$row with $key => $row. Hope this helps

Yeah, I'm actually using this version because I wanted the extra objects to get outputted too - for example giftcard & storecredit information tied to an order.
Not that pretty, but it has some sanity-checks, for example checking if the object is inheriting from Varien_Object before processing the results from getData();   Also makes sure an array of objects is represented as an array in the XML, not struct with named object instances.
public function processingMethodResult($result)
{
    if (is_array($result)) {
        foreach ($result as &$row) {
            if (!is_null($row) && !is_bool($row) && !is_numeric($row)) {
                if (is_array($row)) {
                    $objectArr = false;
                    foreach ($row as &$rowitem) {
                        if (is_object($rowitem) && $rowitem instanceof Varien_Object) {
                            $rowitem = $this->processingMethodResult($rowitem->getData());
                            $objectArr = true;
                        }
                    }
                    if ($objectArr) {
                        $row = array_values($row);
                    }
                    $row = $this->processingMethodResult($row);
                } else {
                    $row = $this->processingRow($row);
                }
            }
        }
    } else {
        if (!is_null($result) && !is_bool($result) && !is_numeric($result)) {
            $result = $this->processingRow($result);
        }
    }
    return $result;
}

Just fyi the code above from @bubach didn't work for me - see https://github.com/digitalpianism/bugfixes/issues/3#issuecomment-254574830 but the code from @tobihille did. thanks.

Sorry about that, never used the API with objects not inheriting from Varien_Object, but I modified the code above to support both types.

Guys, just one question - does this bug manifest on PHP 5.6 too?

@icurdinj I believe so.
@bubach your modified code still doesn't work I'm afraid. (Also tagging @digitalpianism)
with your new code and shoppingCartShippingList($sessionId, $cartId);
array(4) {
  [0]=>
  object(stdClass)#3 (0) {
  }
  [1]=>
  object(stdClass)#4 (0) {
  }
  [2]=>
  object(stdClass)#5 (0) {
  }
  [3]=>
  object(stdClass)#6 (0) {
  }
}

Previous working code from @tobihille
array(4) {
  [0]=>
  object(stdClass)#3 (6) {
    ["code"]=>
    string(46) "royalmail_UK_STANDARD_FIRST_CLASS_SMALL_PARCEL"
    ["carrier"]=>
    string(9) "royalmail"
    ["carrier_title"]=>
    string(10) "Royal Mail"
    ["method"]=>
    string(36) "UK_STANDARD_FIRST_CLASS_SMALL_PARCEL"
    ["method_title"]=>
    string(33) "Standard First Class Small Parcel"
    ["price"]=>
    float(4.04)
  }

... etc

@joolswills please let me know which is the working code so I can apply to: https://github.com/digitalpianism/bugfixes/issues/3#issuecomment-254574830

the code from https://github.com/Inchoo/Inchoo_PHP7/issues/79#issuecomment-254504096
I assumed there was a reason why @bubach did it differently though - and his method (although not yet working), may be preferable. I don't know as I've not looked into it closely.

This bug is not specific to PHP 7, it is a bug with <IP_ADDRESS> as confirmed here:
http://magento.stackexchange.com/questions/140810/what-is-different-between-magento-1-9-2-4-and-magento-1-9-3/140826#140826
As such it probably shouldn't be included in this extension, even though the fix is useful info and appreciated.  There are it seems a number of bugs in <IP_ADDRESS> that make it very likely that Magento will release <IP_ADDRESS> shortly.

I used
    public function processingMethodResult($result)
    {
        if (is_object($result) && is_callable(array($result, 'toArray'))) {
            $result = $result->toArray();
        }
        if (is_array($result)) {
            foreach ($result as &$row) {
                if (is_object($row) && is_callable(array($row, 'toArray'))) {
                    $row = $row->toArray();
                }
                if (!is_null($row) && !is_bool($row) && !is_numeric($row)) {
                    if (is_array($row)) {
                        $row = $this->processingMethodResult($row);
                    } else {
                        $row = $this->processingRow($row);
                    }
                }
            }
        } else {
            if (!is_null($result) && !is_bool($result) && !is_numeric($result)) {
                $result = $this->processingRow($result);
            }
        }
        return $result;
    }

That should work with Collections as well.

I agree with @durzel . This extension is not the place for this fix. But, if someone wants to start a "General Magento Core Fixes" extension, I would wholeheartedly support it. :-)

I simply used the first code that seemed to work for me, and have not investigated the code posted by tobihille or bjoern-tantau - either of which might be way better/stable. As far as the bugfixing module, see https://github.com/digitalpianism/bugfixes :)

@bubach , thanks for the heads-up for digitalpianism/bugfixes. That looks like a good place for this fix.

There may still be a PHP 7 based bug, unless I'm missing a strange logic issue somewhere. I was tackling this bug today myself and discovered that - even if the resulting array appears identical with a dump - if the data is passed through the foreach by reference (foreach ($result as &$row)) and returned to the SoapServer, it would result in a set of empty results for certain functions. (For instance, salesOrderList.)
By modifying the foreach loop to simply use $key => $row rather than a reference, the SoapServer would return the full results as expected. (This also fixed some issues with other third party API responses, where I would sometimes see a 'missing encoding' error.)
Am I the only one with this issue? I was able to duplicate both on a running server as well as in a vagrant box with different environments. It could somehow relate to third-party modules but I didn't see anything obvious.

it would result in a set of empty results for certain functions. (For instance, salesOrderList.)
Am I the only one with this issue?

Can't reproduce. salesOrderList is always filled for me.


Clarify available State information in context

I thought it would make the upgrade process easier for other users by making it clearer which props must be passed via props and which can still be passed via context.
As far as I can make out, only history and location are available via context.

Thanks for the PR, @zenlambda! Would you mind rebasing on current master? The tests should pass now.

@mjackson I'll make the correction and do the rebase. Thanks!

Thanks, @zenlambda !


Add CodeQL Workflow for Code Security Analysis

Summary
This pull request introduces a CodeQL workflow to enhance the security analysis of this repository.
What is CodeQL
CodeQL is a static analysis tool that helps identify and mitigate security vulnerabilities. It is primarily intra-function but does provide some support for inter-function analysis. By integrating CodeQL into a GitHub Actions workflow, it can proactively identify and address potential issues before they become security threats.
For more information on CodeQL and how to interpret its results, refer to the GitHub documentation and the CodeQL documentation (https://codeql.github.com/ and https://codeql.github.com/docs/).
What this PR does
We added a new CodeQL workflow file (.github/workflows/codeql.yml) that

Runs on every pull request (functionality to run on every push to main branches is included as a comment for convenience).
Runs daily.
Excludes queries with a high false positive rate or low-severity findings.
Does not display results for git submodules, focusing only on our own codebase.

Validation
To validate the functionality of this workflow, we have run several test scans on the codebase and reviewed the results. The workflow successfully compiles the project, identifies issues, and provides actionable insights while reducing noise by excluding certain queries and third-party code.
Using the workflow results
If this pull request is merged, the CodeQL workflow will be automatically run on every push to the main branch and on every pull request to the main branch. To view the results of these code scans, follow these steps:

Under the repository name, click on the Security tab.
In the left sidebar, click Code scanning alerts.

Is this a good idea?
We are researchers at Purdue University in the USA. We are studying the potential benefits and costs of using CodeQL on open-source repositories of embedded software.
We wrote up a report of our findings so far. The TL;DR is “CodeQL outperforms the other freely-available static analysis tools, with fairly low false positive rates and lots of real defects”. You can read about the report here: https://arxiv.org/abs/2310.00205
Review of engineering hazards
License: see the license at https://github.com/github/codeql-cli-binaries/blob/main/LICENSE.md:
Here's what you may also do with the Software, but only with an Open Source Codebase and subject to the License Restrictions provisions below:

Perform analysis on the Open Source Codebase.

If the Open Source Codebase is hosted and maintained on GitHub.com, generate CodeQL databases for or during automated analysis, CI, or CD.

False positives: We find that around 20% of errors are false positives, but that these FPs are polarized and only a few rules contribute to most FPs. We find that the top rules contributing to FPs are: cpp/uninitialized-local, cpp/missing-check-scanf, cpp/suspicious-pointer-scaling, cpp/unbounded-write, cpp/constant-comparison, and cpp/inconsistent-null-check. Adding a filter to filter out certain rules that contribute to a high FP rate can be done simply in the workflow file.

Is this spam or is this someone real? It looks like spam.

@jadonk I'm real. We have forked over two hundred repositories to study the benefits of static analysis tools. We actually opened three PRs a few months ago https://github.com/beagleboard/librobotcontrol/pull/222 https://github.com/beagleboard/librobotcontrol/pull/223 and https://github.com/beagleboard/librobotcontrol/pull/224 that were bugs found with CodeQL.
After forking each repository, manually building and analyzing each one, and presenting the results in the paper, we decided to reach out to devs and provide them with a CodeQL configuration to their respective repositories. While the process in which PRs was raised was automated, I can assure you that our intents are genuine and our biggest concern is improving code quality. If you have any questions, please feel free to follow up.

k. how to get it to run now?

@jadonk You can see the results of the analysis in the Security tab under Code Scanning alerts. We recognize that CodeQL may flag errors that are false positives, or even errors that you may choose not to fix (e.g. runtime considerations). For these errors, you can dismiss them with a note in the interface.

nothing there. just says configure scanning tool.

@jadonk Do you mind sharing a screenshot? (this is what it looks like on our fork)

And if you click 'Configure scanning tool'?

If I had to guess, it's because there haven't actually been any runs of this workflow yet. The workflow is currently set to run nightly and on a PR (notice the commented-out trigger for a push to the main branch).

I simply am not sure what I'm turning on and worry it will incur charges, etc. I am clearly being overly trusting to enable this. This doesn't feel like "security" to click to turn on features you don't understand.

Yes, I have just forked this repository again, changed the CodeQL workflow to run on every push, and here is before the workflow gets run:

And after the workflow finishes running:

The workflow needs to be run at least once, first, before it will upload to Code Scanning.

@jadonk Any update?

working.

Great!


As a User, I want to block multiple time slots for an uncertain task

[ ] implement Block class
[ ] implement parsing for Block command
[ ] fix graphical elements for Block display
[ ] correct REGEX for valid Block check

@jjingrong can you help me with the fixing of graphical elements and correct REGEX?

Right now it looks like this


It is better to always disable the 'Paste' action in the view all containers explorer for emulator blob containers

Storage Explorer Version: 1.32.0-dev (95)
Build Number: 20231020.6
Branch: rel/1.32.0
Platform/OS: Windows 10/Linux Ubuntu 20.04/MacOS Sonoma 14.0(Apple M1 Pro)
Architecture: x64/x64/x64
Azurite Version 3.26.0
How Found: From running test cases
Regression From: Not a regression
Steps to Reproduce

Install and run Azurite 3.26.0.
Expand 'Emulator & Attached -> Storage Accounts -> (Emulator - Default Ports) (Key)'.
Right click the 'Blob Containers' node -> Click 'View All'.
Copy one blob container from another storage account.
Go to the view all containers explorer.
Check whether the 'Paste' action is disabled.

Expected Experience
The 'Paste' action is disabled.
Actual Experience
The 'Paste' action is enabled.
Additional Context

There is a failed activity when pasting one non-empty blob container to the view all containers explorer.

The action 'Paste Blob Container' is always disabled.

Paste is simply hidden now

Verified this issue on the rel build 20231021.1. The action 'Paste' is removed from the context menu.


Use tag/branch name as 'release_name'

Hello!
How to use tag/branch name which I specify during deployment (for example deployer.phar -vv deploy production --tag="0.0.1_testtag") as "release_name" in releases folder instead of numbers?
I know about "set('release_name', function () {" but can't implament this with tag/branch name.
Thank you in advance!

set('release_name', function () { get branch here; see other examples in recipes; });


[AA] fix: entrypoint deployment reliability

:clipboard:
Overview
Changes account-abstraction contract deploy files to use ContractFactories and removes deployments using hardhat-deploy.
hardhat-deploy sometimes fails silently, producing contract addresses and txHashes without effects (possibly nonce issues)
Changes
changes deploy scripts to a contractFactory pattern and makes it consistent with other boba/rollup deploy scripts
Testing
cd packages/account-abstraction
yarn deploy

Question to re: deterministic deployments.
It seems odd to me that the upstream repo would basically prevent deterministic deployments to chains that have protection.
What can be done about it?
My concerns are that if the entrypoint contracts become something like safe-deployments from Gnosis (standardizes addresses) and we ship this to prod with undeterministic addresses, it would make us uncompatible. Thoughts?

ohh upstream does have deploy scripts that uses the sdk - which has deterministic deploy through the arachnid proxy(which we cant support - so entrypoint address might differ between mainnet and boba). We could still do a deterministic deploy using another factory contract - one that we deploy or we could use the factory we used for gnosis safes too. If we use the latter - we could have same addresses for all entrypoints across boba instances and in addition also other chains that choose to use the gnosis factory.
since the addresses ultimately depend on the factory - chains with replay protection could end up having different addresses depending on the factory they use, but we can ensure that all our instances have the same address, until there is a standardized factory for these chains (like gnosis)
We could also have multiple entrypoints at the same time, but its easier for developers to follow if we can mark one as preferred and stick to that.
So i removed the deterministic part from the scripts with this change, but adding that part back in (#571 )
what deterministic deployer factory do we use? the gnosis factory?

Codecov Report
Base: 48.51% // Head: 48.51% // No change to project coverage :thumbsup:

Coverage data is based on head (e59b004) compared to base (0074559).
 Consider uploading reports for the commit 2a243ff to get more accurate results

:mega: This organization is not using Codecov’s GitHub App Integration. We recommend you install it so Codecov can continue to function properly for your repositories. Learn more
Additional details and impacted files
@@           Coverage Diff            @@
##           develop     #549   +/-   ##
========================================
  Coverage    48.51%   48.51%
========================================
  Files          132      132
  Lines         5551     5551
  Branches      1123     1123
========================================
  Hits          2693     2693
  Misses        2858     2858

Flag
Coverage Δ

coverage
48.51% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

:umbrella: View full report at Codecov.
:loudspeaker: Do you have feedback about the report comment? Let us know in this issue.


fix SampleCards bug in universal_poker/card_set.

Same as #181.
added some comments to the function CardSet::SampleCards.

It seems impossible since I accidentally deleted the repository of PR(#181). Sad.

Oh no! :( Yeah it seems that the commits are now pointing to an unknown repository.
Well if you find a way to get it back or feel motivated enough to redo it, it's still a very welcome fix.

The fix is included in this PR. So to me, it is OK to merge this PR and close PR(#181).

Oh really? The fix is only 3 lines in card_set.cc in this commit: https://github.com/deepmind/open_spiel/pull/183/commits/c89bc02df17c8435c34e580a82fb7768ec11ea4b  ?

Yes. It is a single character fix : )

Haha, the best kind! Ok I will import this and it will be merged in next Monday's update after review. (Please leave it open). Thanks!

Hi @Liuweiming, I had an issue importing this. I think it's on our end because we have been making a lot of changes that affect the workflow between our internal repos and github.
Could you pull from master and push any merge commits ?
Sorry for the trouble!

It's been fixed and imported, thanks @jblespiau and @tewalds !
Will get merged in the next Monday update, thanks!

OK did have a look at the pull request and this is perfectly fine. Didn't expect a error there but in latter versions this function was not used.
@lanctot thanks for your message at linkedin it did receive it


BlockCollapser fails for ClassicalRegister conditions

Environment

Qiskit Terra version: 0.24 and 0.25rc1
Python version: All
Operating system: All

What is happening?
The BlockCollapser class fails for blocks containing multiple nodes with full ClassicalRegister conditions on the same registers.
How can we reproduce the issue?
Minimal example
from qiskit import QuantumCircuit
from qiskit.converters import circuit_to_dag
from qiskit.dagcircuit.collect_blocks import BlockCollector, BlockCollapser

qc = QuantumCircuit(1, 2)
qc.x(0).c_if(qc.cregs[0], 0)
qc.y(0).c_if(qc.cregs[0], 1)

dag = circuit_to_dag(qc)
blocks = BlockCollector(dag).collect_all_matching_blocks(
    lambda _: True, split_blocks=False, min_block_size=1
)
dag = BlockCollapser(dag).collapse_to_operation(blocks, lambda circ : circ.to_instruction())

---------------------------------------------------------------------------
CircuitError                              Traceback (most recent call last)
Cell In [5], line 14
      8 dag = circuit_to_dag(qc)
     10 blocks = BlockCollector(dag).collect_all_matching_blocks(
     11     lambda _: True, split_blocks=False, min_block_size=1
     12 )
---> 14 dag = BlockCollapser(dag).collapse_to_operation(blocks, lambda circ : circ.to_instruction())

File ~/mambaforge/envs/pec/lib/python3.9/site-packages/qiskit/dagcircuit/collect_blocks.py:368, in BlockCollapser.collapse_to_operation(self, blocks, collapse_fn)
    366 # Add classical registers used in conditions over registers
    367 for reg in cur_clregs:
--> 368     qc.add_register(reg)
    370 # Construct a quantum circuit from the nodes in the block, remapping the qubits.
    371 wire_pos_map = {qb: ix for ix, qb in enumerate(sorted_qubits)}

File ~/mambaforge/envs/pec/lib/python3.9/site-packages/qiskit/circuit/quantumcircuit.py:1425, in QuantumCircuit.add_register(self, *regs)
   1421 for register in regs:
   1422     if isinstance(register, Register) and any(
   1423         register.name == reg.name for reg in self.qregs + self.cregs
   1424     ):
-> 1425         raise CircuitError('register name "%s" already exists' % register.name)
   1427     if isinstance(register, AncillaRegister):
   1428         for bit in register:

CircuitError: 'register name "c" already exists'

What should happen?
No error.
Any suggestions?
The collapse_to_operation method is incorrectly collecting the full classical register from all conditional nodes in a block as a list, when it should be a set to avoid duplication.

Thanks for the report, and yeah, that does appear to be the direct reason.

I would like take a crack at this one, if someone can assign it to me.


Display IDC version on page footer

Figure out how to get Drupal to know the current idc-isle-dc commit hash (preferrably, the output of git describe)
Display that hash on IDC page footers as the IDC version

This will allow evaluators to cite a specific software/stack version when filing bug reports and other issues

what aaron's comment says ^^


Select destination path when adding file

It would be very handy to be able to select destination path from the "Download panel". Currently, it's possible to type the path by it's not that handy as clicking "select path" and navigating to desired location.

It is impossible for a web front end to know the file system hierarchy of the server, which you have no information about. I would like to suggest using the default dir set globally and use better tools (e.g. a bunch of bash scripts) for file management.
If you want this feature anyway, you can ask aria2/aria2 for the API, despite that this feature has been rejected for dozens of times.

file system hierarchy of the server
I'm not sure if we are on the same page - I would like to choose location on my computer where the file would be stored after downloading.

use better tools (e.g. a bunch of bash scripts)

I would argue that those aren't necessarily better ;-) (handy at times, but…)

If you want this feature anyway, you can ask aria2/aria2 for the API, despite that this feature has been rejected for dozens of times.

There is dir (https://aria2.github.io/manual/en/html/aria2c.html?highlight=dir#cmdoption-d) property you mentioned, and it seems that it's possible to set it globally (Aria2 settings -> basic settings) and it's possible to set it in download dialogue, but in the latter case you have to type it manually (vide https://addons.cdn.mozilla.net/user-media/previews/full/189/189863.png?modified=1530209437). But saying that I think, that this issue would once again fit better in https://github.com/RossWang/Aria2-Integration - correct?

@woj-tek For some reasons like security, applications running in the browser cannot obtain directory information from the computer. So, AriaNg could not add this feature.

OK, I was somewhat aware of that (obscuring path when selecting file to upload) yet I thought it would be possible in similar way as uploading works. However pondering it more, AriaNg passes path to aria2 so it won't work like that.
Trying to approach it from different angle - would it be possible to add a couple of predefined paths so it would be possible to:

select them from drop-down list
mark one of them as default
have the field as editable so you could change the path on the fly

nice benefit would be auto-creating path/directories if it doesn't exist.

@woj-tek AriaNg supports history of download directory

It doesn't seem to work for me - each time I have to type in complete path in the download dialogue (field it's empty and there is no history)

Do you use the latest release version (0.5.0) ? When you successfully start a new task, AriaNg would save the dir directory setting, and you can click the text box and choose on of them next time.


The global chain contains INPUT specific rules

The current global chain is documented as "something we want for all" and it is used in the 3 master chains (INPUT, OUTPUT and FORWARD).
However, it contains rules that are specific to the INPUT chain, for instance:
ip protocol icmp icmp type echo-request limit rate 4/second accept

It does not really make sense to rate limit the echo request in the OUTPUT or FORWARD chain. So this rule is more for the INPUT chain.
IMHO, only the rules which are always valid for all the master chains should end up in the global chain. And I wonder whether state tracking (ct state established,related accept) makes sense in the FORWARD chain...
In any case, ICMP handling (both as input and as output) should IMHO be moved into specific rules like we have for most protocols.

BTW, the default ICMP configuration is somehow broken with echo request allowed both in and out but no echo reply allowed in either direction. So ping does not work (in either direction).
One more reason to move the ICMP rules away from the global chain and let users define which kind of ICMP traffic they want to allow.

yeah sounds good to me

I'd suggest to have the ICMPv4/v6 packet types allowed for each chain as parameters of nftables, something like:
class nftables (
  Array[String] $in_icmp6
  Array[String] $out_icmp6
    ...
  ]

with perhaps default lists of ICMPv4/ICMPv6 packets to allow in each direction or simply a default "accept" all ICMP traffic. Then use these parameters to add individual rules in inet_filter.
If I understand the proposal correctly the global chain will be reduced to just:
        chain global {
                ct state invalid drop
        }

as ct state established,related accept will be moved to INPUT and OUTPUT. Comments?
@LionelCons Perhaps if @duritong  and @keachi  like the proposal you could produce a proposal for the default values of

nftables::in_icmpv6
nftables::in_icmpv4
nftables::out_icmpv6
nftables::out_icmpv4

If I understand the proposal correctly the global chain will be reduced to just:

Not really because in FORWARD perhaps it makes no sense to have any rules involving conntrack.
So, remove global?

or just keep it empty.

It could indeed be handy to have a common chain shared by all the master chains (BTW, should it be called common rather than global?).
But this common chain should be empty by default.
The ICMP rules should end up in separate files and the connection tracking should be added to the INPUT and OUTPUT chains, probably using variables like we have already for most of the rules.
For maximum flexibility, it should be possible to get a configuration with no rules at all by changing a few variables.

I can confirm that the conntrack rules moved out of the global chain work fine.
As for the default ICMP rules, this is really a matter of taste. I am in favour of a very limited set of rules but others prefer to allow everything, only limiting the rate. See for instance https://wiki.nftables.org/wiki-nftables/index.php/Simple_ruleset_for_a_server.

@LionelCons could you please shared with us your preferred defaults for ICMP4/6 in/out traffic so we can use them as a base to start discussing?

Here is what I allow for the incoming traffic:

IPv4: echo-request, echo-reply, time-exceeded, destination-unreachable
IPv6: IPv4 + neighbour-advertisement, neighbour-solicitation, router-advertisement

This mainly allows ping and traceroute to work.
I do not filter the outgoing traffic.

The main question is: what do we want in the API?
nftables::in_icmpv4 and nftables::out_icmpv4 or nftables::in_icmp_ping4 and nftables::out_icmp_ping4?
An incoming ping allowed means echo-request allowed in and echo-reply allowed out...

Ok, thanks. I'll check the RHEL8 defaults (as suggested by @feandil) and come back with a proposal in code.

If I'm not reading it wrong, the RHEL8 default (checked on a 8.2 image) is:

In

ICMPv6: All accepted (no rate limit for any type)
ICMPv4: Al accepted (no rate limit for any type)

Out: All traffic accepted so no ICMP-specific rules apply.

RHEL8.2 rules: http://cern.ch/stikked/view/70c7ee72
@keachi @duritong, comments?

There's a proposal in code available.

@LionelCons For info the proposed patch allows setting your configuration by doing:
nftables::rules::icmp::v4_types:
  - "echo-request limit rate 4/second"
  - "echo-reply"
  - "time-exceeded"
  - "destination-unreachable"
nftables::rules::icmp::v6_types:
  - "echo-request limit rate 4/second"
  - "echo-reply"
  - "time-exceeded"
  - "destination-unreachable"
  - "nd-neighbor-advert"
  - "nd-neighbor-solicit"
  - "nd-router-advert"

leading to this ruleset:
...
        chain default_in {
                ip protocol icmp icmp type destination-unreachable accept
                ip protocol icmp icmp type echo-reply accept
                ip protocol icmp icmp type echo-request limit rate 4/second accept
                ip protocol icmp icmp type time-exceeded accept
                ip6 nexthdr ipv6-icmp icmpv6 type destination-unreachable accept
                ip6 nexthdr ipv6-icmp icmpv6 type echo-reply accept
                ip6 nexthdr ipv6-icmp icmpv6 type echo-request limit rate 4/second accept
                ip6 nexthdr ipv6-icmp icmpv6 type nd-neighbor-advert accept
                ip6 nexthdr ipv6-icmp icmpv6 type nd-neighbor-solicit accept
                ip6 nexthdr ipv6-icmp icmpv6 type nd-router-advert accept
                ip6 nexthdr ipv6-icmp icmpv6 type time-exceeded accept
...

Very good!
Note that it seems that one could also write:
nftables::rules::icmp::v4_types:
  - "{ destination-unreachable, time-exceeded, parameter-problem }"

I don't know if this is intended but this allows a more compact set of rules...

I really appreciate this idea of exposing the icmp types to class parameters.
echo-reply is allowed by conntrack with established,related. I never opened echo-reply but echo-request works fine.

Great, thanks :) I'll remove the draft flag once #15 is merged (need that patch to run the test suite).


Excessive line feeds in server output

Describe the bug:
Excessive line feeds in server output.
To Reproduce:
Start SEGSAdmin, start server, observe logins and actions.
Expected behavior:
Line feeds that make sense, if any.
SEGS Version:

SEGS Build ID: 0.6.1

Can you be more specific? Is this line returns? Can you post a screenshot?

Running under Windows 7

I'll defer to @Miles, but I think this is a known unsolvable bug.
I think we're all open to suggestions.

Is it Qt-specific?

My understanding is yes.

Just to clarify, the issue is with the excessive white space between lines?

I believe so. If that's the case, some internet sleuthing seems to indicate that carriage returns are being treated as newlines and str.replace("\r", "") may resolve the issue.
From here: https://forum.qt.io/topic/85162/qtextedit-and-carriage-return-r-character/3

Thanks @broxen , I went with changing appendPlainText() to insertPlainText()
From the docs, appendPlainText():
Appends a new paragraph with text to the end of the text edit.
insertPlainText():
Convenience slot that inserts text at the current cursor position.

I'll push a PR this evening

Fantastic


Pomcho555 add browser autofill

Proposed changes

The original saml2aws provide --browser-autofill option to speed up your login, it's also nice to have this option through this tool.

Type of change

[ ] Bugfix (non-breaking change which fixes an issue)
[x] New feature (non-breaking change which adds functionality)
[ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
[ ] Documentation update (if none of the other choices apply)

Checklist

[x] Add or update tests that prove the fix is effective or that the feature works
[x] Add or update workflows for deployment
[x] Add or update README, CHANGELOG

Outcome

Explain the outcome of the change (screenshot or sample output if appropriate)
saml2aws automatically fills the username and password on a browser after you filled them in the prompt of awslogin

Are there any known use cases (or test cases) not covered by this change (or out of scope)?
Compatibilities of each browser is out of scope of this PR since saml2aws does this job.

Hi @kyhau
Can you review this PR when you have time?