Is it possible to ignore a particular declaration

:question: Guidance

Affected Languages

[X] TypeScript or Javascript
[ ] Python
[ ] Java
[ ] .NET (C#, F#, ...)

General Information

JSII Version: 1.11.0
Platform:     Linux docker-desktop 4.19.128-microsoft-standard #1 SMP Tue Jun 23 12:58:10 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux

The Question
I have a file which is roughly equivalent to https://github.com/aws/aws-cdk/blob/master/packages/%40aws-cdk/core/lib/runtime.ts. Running it through jsii gives warnings like:
lib/runtime.ts:16:14 - message TS9999: JSII: Ignoring VariableDeclaration node (it cannot be represented in the jsii type model)

16 export const booleanToTerraform: Mapper = identity;

The warnings make sense, but really this file doesn't need to be compiled for other languages. It is just needed for the runtime execution, so ignoring it would be ideal.
It does need to be referenced by code external to the package, so I can't exclude from the index.
I've tried adding @internal to tsdocs on everything exported, but the warnings persisted.
I've tried adding to excludeTypescript, but then it doesn't compile.
Alternatively, just suppressing warnings from this particular file would probably be fine.

Hey!
We do not currently support ignoring those declarations.
To a certain extent, the "correct" way to "move them out of way" is to simply move them into a separate .ts file, which you simply do not export from your entry point (typically index.ts).
That being said, I understand this is unnecessary overhead, and we are working on mechanisms that will allow users to silence warnings in various ways (either globally, or per declaration/statement). It might be a little while before this is done though.

I thought that might be the case. Thanks for the confirmation.
Looking forward to more having more controls.


Website: improve anchors for slow loading pages

@bclehmann from Discord #1966 suggested adding an onload event to scroll to an anchor after the page is finished loading

Following-up, @bclehmann does this seem reasonable?
<body onload="scrollToUrlAnchor()">

function scrollToUrlAnchor() {
    const urlAnchor = window.location.href.split('#')[1];
    if (urlAnchor) {
        window.scrollTop = document.querySelector(`#${urlAnchor}`).offsetTop;
    }
}

You can simply use window.location.hash rather than splitting on the hashtag.
But yeah, this sounds good, I've looked since and I think we have to use window.load, since document.DOMContentLoaded does not wait for things like stylesheets which are likely to change the offsetTop of the target.

You can simply use window.location.hash rather than splitting on the hashtag.

Nice! Changing to:
function scrollToUrlAnchor() {
    if (window.location.hash) {
        window.scrollTop = document.querySelector(window.location.hash).offsetTop;
    }
}


Flyout IconImageSource issue

[Enter feedback here]
It is said in the doc that by setting "IconImageSource" property, the icon will appear on the detail page, provided that it have a title bar. But that is not working. My objectif is to customize that hamburger icon that toggle the "IsPresented" property of the flyout page. Thank you

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

ID: 86a77021-9359-304a-5d49-a4feadf2f8fb
Version Independent ID: 86a77021-9359-304a-5d49-a4feadf2f8fb
Content: FlyoutPage - .NET MAUI
Content Source: docs/user-interface/pages/flyoutpage.md
Product: dotnet-mobile
Technology: dotnet-maui
GitHub Login: @davidbritch
Microsoft Alias: dabritch

Hi @Cisco0911
I just tried it and it seems like it works correctly and iOS and Mac Catalyst, but not other platforms. The engineers have a bug logged for it: https://github.com/dotnet/maui/issues/15211


Show description in function completions

It would be good if we could show some description when tabbing through completions - currently we show nothing.

Implementation-wise it's a little tricky as descriptions are stored per-overload, and we haven't yet picked an overload. It would be nice to at least show some more generic description however.

Also note that a solution to this should also cover showing fallback descriptions for unresolved functions (search the codebase for "https://github.com/Azure/bicep/issues/4588").

Closed by #5398


⚠ ClamAV has degraded performance

In c27c8ff, ClamAV (https://spamassassin.apache.org/) experienced degraded performance:

HTTP code: 200
Response time: 93 ms

Resolved: ClamAV performance has improved in 7b8e9f0.


multiple content: for bottom pane

I would like to also use the Advanced Search Widget with your Related Table widget. How do I specify more than one content:
in the div tag?
content: '

','

'

@friendde I'm trying to guess what you want to accomplish, do you want to have the Advanced Search Widget as a new tab in the Related Table Widget?

I don't think I want a new tab (unless it's necessary). But I do want to be able to configure the app to use both widgets. I am confused on how to configure the bottom pane so both widgets can be used in the application. Basically add your widget. Both widgets require the bottom pane content:
to be configured.

Ah, I see. Try this:
content: '

'

'

You might need to play around with the width/height.

Just a side note, they don't necessarily need the bottom pane configured, you can place each widget anywhere in theory, but since the related records widget is quite large, I recommend placing it in a bottom or top pane.

Thanks, it places the RelatedRecords Tab underneath the Attributes tab. I am ok with that. Thanks for making this. I have another question but I will ask in the chat at the CMV page.

@friendde You might be able to fit them side by side by using float:left in the css.


no-unsafe-any: Allow import declarations

PR checklist

[X] Addresses an existing issue: #2494
[X] New feature, bugfix, or enhancement

[X] Includes tests

[ ] Documentation update

Overview of change:
Always allow import statements in no-unsafe-any.
CHANGELOG.md entry:
[bugfix] no-unsafe-any: Allow import declarations

Did a complete rewrite. I also have a branch testing out applying the rule to tslint itself, but that will have to wait until the fixes are published globally (else lint:from-global won't work).


Add in/out params info to functions

Add a description of each input and output parameter for every function. See:
https://github.com/numpy/numpy/blob/master/doc/example.py
and
http://legacy.python.org/dev/peps/pep-0257/

Duplicate of #122.


Fix running count

The agent is stopped prematurely (at max idle time) since when running count is calculated it compares the job id instead of the agent id to the configured agent id.

This is indeed a bug. Thanks for fixing it!


dbus-broker.service: Main process exited, code=exited, status=203/EXEC

Hi, after using the modified dbus systemd service the system fails to reboot. The logs show the following:
 Jul 29 17:14:09 pc systemd[1]: dbus-broker.service: Main process exited, code=exited, status=203/EXEC
Jul 29 17:14:09 pc systemd[1292]: dbus-broker.service: Failed at step EXEC spawning /usr/bin/dbus-broker-launch: Permission denied
Jul 29 17:14:09 pc systemd[1292]: dbus-broker.service: Failed to execute /usr/bin/dbus-broker-launch: Permission denied

My systemd service is as follows:

[Unit]
Description=D-Bus System Message Bus
Documentation=man:dbus-broker-launch(1)
DefaultDependencies=false
After=dbus.socket
Before=basic.target shutdown.target
Requires=dbus.socket
Conflicts=shutdown.target

[Service]
Type=notify
Sockets=dbus.socket
OOMScoreAdjust=-900
LimitNOFILE=16384
ProtectSystem=full
PrivateTmp=true
PrivateDevices=true
ExecStart=/usr/bin/dbus-broker-launch --scope system --audit
ExecReload=/usr/bin/busctl call org.freedesktop.DBus /org/freedesktop/DBus org.freedesktop.DBus ReloadConfig
RestrictAddressFamilies=AF_UNIX
IPAccounting=yes
ProtectKernelTunables=yes
ProtectKernelModules=yes
ProtectKernelLogs=yes
ProtectHostname=yes
ProtectClock=yes
UMask=077
AmbientCapabilities=CAP_BPF CAP_PERFMON
CapabilityBoundingSet=~CAP_AUDIT_CONTROL CAP_AUDIT_READ CAP_DAC_READ_SEARCH
CapabilityBoundingSet=~CAP_SYS_RAWIO
CapabilityBoundingSet=~CAP_SYS_PTRACE
CapabilityBoundingSet=~CAP_DAC_* CAP_FOWNER CAP_IPC_OWNER
CapabilityBoundingSet=~CAP_NET_ADMIN
CapabilityBoundingSet=~CAP_KILL
CapabilityBoundingSet=~CAP_NET_BIND_SERVICE CAP_NET_BROADCAST
CapabilityBoundingSet=~CAP_SYS_NICE CAP_SYS_RESOURCE
CapabilityBoundingSet=~CAP_SYS_BOOT
CapabilityBoundingSet=~CAP_LINUX_IMMUTABLE
CapabilityBoundingSet=~CAP_SYS_CHROOT
CapabilityBoundingSet=~CAP_BLOCK_SUSPEND
CapabilityBoundingSet=~CAP_LEASE
CapabilityBoundingSet=~CAP_SYS_PACCT
CapabilityBoundingSet=~CAP_SYS_TTY_CONFIG
CapabilityBoundingSet=~CAP_SYS_ADMIN
# CapabilityBoundingSet=~CAP_SETUID CAP_SETGID CAP_SETPCAP
CapabilityBoundingSet=~CAP_CHOWN CAP_FSETID CAP_SETFCAP
CapabilityBoundingSet=~CAP_NET_RAW
CapabilityBoundingSet=~CAP_IPC_LOCK
NoNewPrivileges=yes
ProtectControlGroups=yes
RestrictNamespaces=yes
LockPersonality=yes
MemoryDenyWriteExecute=yes
RestrictRealtime=yes
RestrictSUIDSGID=yes
SystemCallFilter=~@raw-io
SystemCallArchitectures=native
CPUShares={{ dbus_cgroups_cpushares | default('1024') }}
CPUQuota={{ dbus_cgroups_cpuquota | default('20%') }}
MemoryLimit={{ dbus_cgroups_memorylimit | default('1G') }}

[Install]
Alias=dbus.service

Do you know what's the cause of this issue?

Last manual check I did, I did not identify any issue and from github actions, on ubuntu 20.04, it starts fine too per https://github.com/juju4/ansible-harden-systemd/runs/7604412584?check_suite_focus=true#step:10:121
Note that your example file does not match expected output created by this ansible role as can be seen on https://github.com/juju4/ansible-harden-systemd/runs/7604412584?check_suite_focus=true#step:13:390
Which distribution and release are you using?
can you try to comment line by line the different hardening settings and see when it starts fine?
The "permission denied" seems to indicate a file access issue.
what's the output of following commands?
ls -l /usr/bin/dbus-broker-launch
ls -lZ /usr/bin/dbus-broker-launch
getfacl /usr/bin/dbus-broker-launch

Did you try to comment line by line the different hardening settings and see when it starts fine?

Yes, I did in a VM now and found the issue I think. Thanks!


Fix headers for MUSL compatibility

The MUSL headers generally don't like being included as <sys/foo.h> when the preferred means is <foo.h> (example: time.h) and will complain loudly when this happens.  It's unnecessary noise, and it
potentially draws attention from real warnings that might otherwise be overlooked.

@kr Can I get an up/down on whether this will be merged please?  It's over a year old, but it's a one-liner.

Fixed in cf95cbce4af653dcf64e6162f7d73e3a570becfb.

Thanks!


Errors executing tests on VS Code

Not experienced with Dotnet or C Sharp. I'm trying to run tests with dotnet test C:\DEVELOPMENT\DOTNET\server\Sygic.Corona.Infrastructure.Tests\Sygic.Corona.Infrastructure.Tests.csproj 4 pass but 3 fail with The configuration file 'local.settings.json' was not found and is not optional. The physical path is 'C:\DEVELOPMENT\DOTNET\server\Sygic.Corona.Infrastructure.Tests\bin\Debug\netcoreapp3.1\local.settings.json'
Can you please assist ? I looked at the path in the error and the file doesn't exist

Of course file doesn't exist because it is contains sensitive data like connection strings, secrets etc ...
Those test are integration tests so you have to provide your own config file. It is enough to provide only values needed in specific test. In this case there is test for our private SMS gateway so of course there is no reason for you to run it.

Thanks for the reply @Daziko . I know that the file contains sensitive data, I was thinking about a dummy file with dummy data describing each field. I was just trying to make it work as there is no much details on what does what. However it's a good initiative but you need to make it more understandable to the people willing to contribute to end this pandemic.
So please help by providing more details on how to make it work.

Desired values are in configuration description in read me file (README.md)
Example of azure function local config is bellow. Just provide your values. For esxample there is Twilio section so grab Twilio config keys from readme.md and provide values from your twilio account etc..
{
  "IsEncrypted": false,
  "Values": {
    "AzureWebJobsStorage": "UseDevelopmentStorage=true",
    "FUNCTIONS_WORKER_RUNTIME": "dotnet",
    "YourSecretValue": "***-****",
    "YourSecretSetting": true
  }
}

Thanks, will try that and let you know.

@Daziko Tried to deploy on azure and have everything set up (I guessà but when I try to access the API url, there is an error: Function host is not running. What could it be?


Wrong demo link

Hi! The link to the Plunker demo in the README.md seems to be wrong. Also in https://rmodal.js.org/

Thanks!

Hi, @aarongarciah. Please disable your ad blocker.
The demo link is correct ;)

Now it works. But I haven't disabled my ad blocker 🤔 Thanks

Could just be plunker being down at the time of your first comment.


API Lifecycle Weekly - May 5th, 2022

This is a weekly public meeting to discuss the different areas of the API lifecycle and governance, push forward discussions around how the API lifecycle applies to OpenAPI and AsyncAPI, and work on extensions, platform ops collections, tooling, and blueprints that will help the community be more successful.
Agenda:

Platform Ops (Specifications, Design, Mocking, Documentation, Environments, Testing, Security, Monitoring, Discovery, Workspaces, Client, Source Control, CI/CD, Gateway, APM, Orchestration, Observability, Governance, Analytics, Teams,Change, Automation)

OpenAPI Security Scanner API - Check in on the OpenAPI Security Scanner API.

Blueprint - Moving forward blueprints, elements, and creating content, workshops, and curriculum.

Explorer - Playing around with a new tool for filtering and understanding how things work.
Lifecycle - The public workspace where blueprints are published.
Pipeline Flows (Repo) - Visual diagrams of common lifecycle blueprints.
Worshops - The current outline for workshops.

Platform Governance (Workspace) - Move forward with storytelling around linting rules.

OpenAPI Linting API - Our API for linting OpenAPI.
Default Rules (Evaluation) - What are the default set of linting governance rules.

Please add any agenda items you’d like to discuss below, and we will meet weekly, and push forward projects, stories, collections, and tools to support our work.

Previously....security, gateways, rules, and shift left, but shield right.


GE Link PAR38 Bright White Zigbee Bulb - PSB38-BW30

Device information
PSB38-BW30
Home Assistant Device information

GE Wink PAR38
ZLL Light
by GE_Appliances
Connected via [Silicon Labs EZSP](http://<IP_ADDRESS>:8123/config/devices/device/b70c349f2f08012344dac712cfb9113f)
Firmware: 0x01030400
Zigbee info
IEEE: 7c:e5:24:00:00:05:fd:d0
Nwk: 0x12cd
Device Type: Router
LQI: 255
RSSI: -80
Last seen: 2023-10-23T12:13:34
Power source: Mains

Checklist

[x] I have created a single PR per device. When you have multiple submissions please create separate PR's.
[x] For lights - I have only included the gzipped files (*.gz), not the raw CSV files.
[x] For lights - I have provided a CSV file per supported color mode. Look that up in Developer Tools -> States

Additional info

perfect thanks.


dalleVersion Image Sizes

Was just using the latest version and noticed that when setting:
'dalleVersion' => 3,
It does not respect the size setting:

I have confirmed this in my usage area:

Am I missing a setting elsewhere?
Thanks!

Was pointed out to me:
The size of the generated images. Must be one of 256x256, 512x512, or 1024x1024 for DALL·E-2 models. Must be one of 1024x1024, 1792x1024, or 1024x1792 for DALL·E-3 models.
So, guess will need to figure out how to change the image sizes in dropdown based on model?

Good morning,
It's been a while since I had time to develop on the project.
From memory, sizes are defined in an enumeration.
It is possible that there is a check on the authorized sizes that must be
removed.
Kind regards
Le lun. 9 déc. 2024 à 13:15, Susan @.***> a écrit :

Was pointed out to me:
The size of the generated images. Must be one of 256x256, 512x512, or
1024x1024 for DALL·E-2 models. Must be one of 1024x1024, 1792x1024, or
1024x1792 for DALL·E-3 models.
So, guess will need to figure out how to change the image sizes in
dropdown based on model?
—
Reply to this email directly, view it on GitHub
https://github.com/EasyGithDev/PHPOpenAI-Playground/issues/6#issuecomment-2527765236,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AA23LERIGIJXOW4FHRMK6732EWCXXAVCNFSM6AAAAABTIQWVO6VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDKMRXG43DKMRTGY
.
You are receiving this because you are subscribed to this thread.Message
ID: @.***>

--
Cordialement,
Florent Brusciano

Thanks for reply.
There are issues to solve:

index needs input to choose between models
index needs input to choose image sizes based on dall-e 2 / 3. Must be one of 256x256, 512x512, or 1024x1024 for DALL·E-2 models. Must be one of 1024x1024, 1792x1024, or 1024x1792 for DALL·E-3 models.

Not sure the best way to do this, but for our needs, we are going to experiment with cookies and use something like this in conf.php:
'dalleVersion' => isset($_COOKIE['dalleVersion']) ? (int)$_COOKIE['dalleVersion'] : 3,
Will experiment in class and see what we can come up with.


[FEATURE] Metadata UUID Support

[FEATURE] Metadata UUID Support #1164
Draft

@humcqc thank you! Do tests pass for all EmbeddingStores that support storing metadata?

I've just tested the ones having the filter test : EmbeddingStoreWithFilteringIT
-> ElasticSearch, Milvus, InMemory, PG Vector ( JSON, JSONB, Columns)

@langchain4j @humcqc Any chance we can get this approved and merged? With PgVectorEmbeddingStore I'd like to add a metadata column of type UUID which points to the parent table PK of the embedding table which has a type UUID.

@langchain4j @humcqc Any chance we can get this approved and merged? With PgVectorEmbeddingStore I'd like to add a metadata column of type UUID which points to the parent table PK of the embedding table which has a type UUID.

@langchain4j It should be ok to merge.
@sjivan by that time you can still use deprecated method :
    @Deprecated
    public Metadata add(String key, Object value) {
        return put(key, value.toString());
    }

@langchain4j @humcqc Any chance we can get this approved and merged? With PgVectorEmbeddingStore I'd like to add a metadata column of type UUID which points to the parent table PK of the embedding table which has a type UUID.

@langchain4j It should be ok to merge.
@sjivan by that time you can still use deprecated method :
    @Deprecated
    public Metadata add(String key, Object value) {
        return put(key, value.toString());
    }

@humcqc thanks for getting the PR ready to merge. The workaround of the deprecated method does not work with PgVectorEmbeddingStore metadata because if the field in question is declared as "foo uuid", when the retreiver reads the column "foo" it introspects the type via JDBC and when it sees its of type UUID, it fails with an unssupported type exception. Hopefully this is no longer the case after change.

@langchain4j Done.

@langchain4j I've seen that some modules are in java 17
Is it possible to do the same thing for langchain4j-ollama ?

@humcqc yes, if there is a good reason for that


docs: missing steps in docker getting-started guide

Following the Docker Getting Started Guide does not fully work. This PR adds the missing steps.

Need to set Valid Redirect URIs to not run into Invalid parameter: redirect_uri error.
Need to set Web origins to not run into CORS error.
Added expected result after sign-in.

Updated the guide to the new admin console, which fixes the issue:
https://github.com/keycloak/keycloak-web/pull/348


2to3 community/

Ignore all python files from src/ directories though (if these existed)

are there any src python files? I am not sure if those are converted...

are there any src python files? I am not sure if those are converted...

in any case: there is a question whether we should convert a community python 2 code..you can envision interfacing from python3 to a python2 code!!

are there any src python files? I am not sure if those are converted...

in any case: there is a question whether we should convert a community python 2 code..you can envision interfacing from python3 to a python2 code!!

I found them in Ramses. But I think they're used as analysis tools only. I don't want to touch them in principle, we should maybe get an updated upstream version though.

Don't replace ints with longs - longs no longer exist in Python 3 (https://www.tutorialspoint.com/python3/python_numbers.htm)

the line before defines long as a vector...!!!

the line before defines long as a vector...!!!

Ah, I see. That is just evil... We should rename it to something more sensible than a reserved keyword.

But well spotted!

longv is much better. thanks.


Disabling unwanted space error in LaTeX

I have been looking at other issues, but can't seem to find a fix to this one. I am getting an error in latex where syntastic shows me an error saying HW12.tex | 10 error | possible unwanted space at '{' when I have an open curly brace. It doesn't highlight a certain character, so I don't know where the space is.
Here is the output when I run :SyntasticInfo
Syntastic version: 3.8.0-110 (Vim 800, Neovim, Linux)
Info for filetype: tex
Global mode: active
Filetype tex is active
The current file will be checked automatically
Available checkers: chktex lacheck
Currently enabled checkers: lacheck chktex

Is there anyway to disable this specific error, since it doesn't prevent the compiler from working?

possible unwanted space at '{' is a lacheck message, and there doesn't seem to be any way to disable it on lacheck's side.  You can kill it on syntastic's side with quiet_messages:
let g:syntastic_tex_lacheck_quiet_messages = { 'regex': '\Vpossible unwanted space at' }

Sadly, useful linters for LaTeX are still missing.

Ok, thanks. That worked.


KafkaChannel don't update even when trigger is deleted using DistributedKafkaDispatcher

Describe the bug
I'm using DistributedKafkaDispatcher,  then i created broker and some trigger subscribing the broker, the kafkachannel's config is correct.
Then i remove some trigger and the kafkachannel's config not updating forever.
The dispatcher log
{"level":"error","ts":"2022-04-26T11:50:28.211Z","logger":"eventing-kafka-channel-dispatcher","caller":"controller/kafkachannel.go:210","msg":"Failed To Update KafkaChannel Status","error":"Operation cannot be fulfilled on kafkachannels.messaging.knative.dev \"e-f4ef66c69088d108-kne-trigger\": the object has been modified; please apply your changes to the latest version and try again","stacktrace":"knative.dev/eventing-kafka/pkg/channel/distributed/dispatcher/controller.Reconciler.Reconcile\n\tknative.dev/eventing-kafka/pkg/channel/distributed/dispatcher/controller/kafkachannel.go:210\nknative.dev/pkg/controller.(*Impl).processNextWorkItem\n\tknative.dev/pkg@v0.0.0-20211206113427-18589ac7627e/controller/controller.go:542\nknative.dev/pkg/controller.(*Impl).RunContext.func3\n\tknative.dev/pkg@v0.0.0-20211206113427-18589ac7627e/controller/controller.go:478"}

Knative release version
v1.1
Detailed Broker and Triggers and logs
I have only one trigger 'hmqm-integration-prod-hmqm-test-0' and the channel's config have two channel using the same name:
  - subscriberUri: http://broker-filter.knative-eventing.svc.cluster.local/triggers/cosmoim-integration-prod/hmqm-integration-prod-hmqm-test-0/9af07add-4460-4a5b-b6af-1a2e6e7ce3bf
    uid: 7e61f1a3-bf03-47cd-892d-fc1942e90b9e

  - subscriberUri: http://broker-filter.knative-eventing.svc.cluster.local/triggers/cosmoim-integration-prod/hmqm-integration-prod-hmqm-test-0/0e90c61d-8b87-4dd0-9051-d79ce290c383
    uid: 84ddc1bf-f102-4273-9892-b0cc230782bd

https://gist.github.com/zhaojinxin409/cc4d90da2c6b390490e8791f771d1605

Published in knative/eventing, should not be related to kafkachannel


cannot build gitea builder

error while trying to build gitea builder

Branch: development
Commit_ID:  23d753f738abbc7add99b98b6c23619ab20671d2

can't reproduce

working fine now.


Update QUICHE from 53c94d968 to 8eb90efcb

https://github.com/google/quiche/compare/53c94d968..8eb90efcb
$ git log 53c94d968..8eb90efcb --date=short --no-merges --format="%ad %al %s"
2022-07-13 vasilvv Mark the float version of QuicTime::Delta operator* as non-constexpr
2022-07-13 bnc Remove FrameSequence and MetadataSerializer.
2022-07-12 martinduke Update QUIC connection ID encryption library to reflect draft-ietf-quic-load-balancers-14.
2022-07-12 wub Add missing flag counts for --quic_dispatcher_send_connection_close_for_tls_alerts.
2022-07-12 bnc Add BalsaVisitorInterface::OnHeader().
2022-07-12 birenroy Adds a QUICHE flag to control oghttp2 debug trace logging.
2022-07-11 vasilvv Switch QuicServer to use QuicEventLoop instead of QuicEpollServer
Signed-off-by: Ryan Hamilton<EMAIL_ADDRESS>

/assign @mattklein123

This includes a QUICHE fix that https://github.com/envoyproxy/envoy/pull/22176 was forced to work around.


HTTP Server with chunked transfer encoding

I want to implement Twitter-like functionality of continuously streaming data without closing the connection. Websockets don't work for me for this particular situation.
Twitter server
Twitter Streaming API client shard currently has this implementation (simplified) of streaming tweets:
class Twitter::StreamAPI
  def stream_tweets(&block)
    http_client.get(path) do |response|
      puts "RESPONSE HEADERS: #{response.headers}"
      loop do
        yield response.body_io.gets.not_nil!
      end
    end
  end
end

And an application may do this:
def stream_tweets
  twitter_stream_api.stream_tweets do |tweet|
    pp tweet
  end
end

It has following headers: RESPONSE HEADERS: HTTP::Headers{"connection" => "close", "content-Encoding" => "gzip", "content-type" => "application/json", "date" => "...", "server" => "tsa", "transfer-encoding" => "chunked", "x-connection-hash" => "..."} and it actually continuously  gets the response! Each time a new tweet is posted, this block is yielded, the connection stays alive forever!
Yes, that's true, I already have Telegram bot posting new tweets in a channel.
Implementing the same functionality
After some googling I've found that Twitter might use Chunked transfer encoding.
As I can see in the CHANGELOG:

Added support for sending chunked content in HTTP server (thanks @bcardiff)

But HTTP::Server::Response::Output#unbuffered_write is private. :thinking:
Therefore, I clearly don't get how to serve chunked responses.
My trials
So far, this is what I've tried to do:
server.cr
require "http/server"

port = 5000

server = HTTP::Server.new(port) do |context|
  puts "Got request"
  context.response.headers["Transfer-Encoding"] = "chunked"
  context.response.upgrade do |socket|
    puts "Upgraded"
    loop do
      puts "Writing"
      chunked_write(socket, "Query: #{context.request.query}".to_slice)
      sleep 5
    end
  end
end

def chunked_write(io, slice)
  slice.size.to_s(16, io)
  io << "\r\n"
  io.write(slice)
  io << "\r\n"
end

puts "Listening on #{port}"
server.listen

client.cr
require "http/client"

client = HTTP::Client.new("localhost", port: 5000)

client.get "/" do |response|
  puts "Got response"
  loop do
    puts "Response: " + response.body_io.gets.not_nil!
  end
end

Output
This is server output:
Listening on 5000
Got request
Upgraded
Writing
Writing
...

And this is what I got on the client. Note that the output is empty until I press Ctrl-C on server:
Nil assertion failed (Exception)
0x481887: *CallStack::unwind:Array(Pointer(Void)) at ??
0x4a6310: not_nil! at /opt/crystal/src/class.cr 65:0
0x4f5b07: initialize at /opt/crystal/src/http/content.cr 55:26
0x4f5a69: new at /opt/crystal/src/http/content.cr 54:5
0x4676dd: __crystal_main at /opt/crystal/src/http/common.cr 36:11
0x47b469: main at /opt/crystal/src/main.cr 12:15
0x7f938bd4c830: __libc_start_main at ??
0x462659: _start at ??
0x0: ??? at ??

Please help me implementing a chunked server in Crystal!

You should append \n to sent text to gets in client and do io.flush. And you don't need to use upgrade and create chunk response manually. Simplified  server.cr is here:
require "http/server"

port = 5000

server = HTTP::Server.new(port) do |context|
  puts "Got request"
  # `context.response.headers["Transfer-Encoding"] = "chunked"` is default.
  loop do
    puts "Writing"
    context.response.puts "Query: #{context.request.query}"
    context.response.flush
    sleep 5
  end
end

puts "Listening on #{port}"
server.listen

@vladfaust if @MakeNowJust didn't make that crystal clear: crystal already handles writing chunked responses. Just keep on writing to the output response, and call flush when you want to ensure the client receives the message. If there is no content length header, the response will automatically select chunked encoding for you.

@RX14 Thank you for detailed explanation!

@RX14 @MakeNowJust thank you guys. Should I create a separate issue stating that we need more docs for that? @RX14 Your quote could be used.

Regarding docs: no. I prefer to use StackOverflow, it's a living "missing docs and examples". It's simply impossible to put every use case in documentation. So this should be really asked in StackOverflow.

Also I'm thinking that I don't know much about IO. flush is kinda magic for me. I suppose there are lots of developers coming from Ruby / Python who never work with IO so close. They may struggle too.

@RX14 please: https://stackoverflow.com/questions/46298660/how-to-create-a-streaming-http-server-in-crystal


Holiday Updates, Part 2

Add near parity for Typesafe vs Shocon backends
Cross run tests against Typesafe vs Shocon backends
Adds more tests
Adds preliminary cats module
Add unidoc task
Add scoverage plugin

Current coverage is 32.60% (diff: 38.46%)

No coverage report found for master at a5edf6f.

Powered by Codecov. Last update a5edf6f...6b62d58

Current coverage is 47.39% (diff: 41.89%)

No coverage report found for master at a5edf6f.

Powered by Codecov. Last update a5edf6f...4632488

Current coverage is 36.68% (diff: 31.00%)

No coverage report found for master at a5edf6f.

Powered by Codecov. Last update a5edf6f...c8a5f9b

Current coverage is 36.68% (diff: 31.00%)

No coverage report found for master at a5edf6f.

Powered by Codecov. Last update a5edf6f...c8a5f9b


Bug report

Describe the bug
When I add something it doesn't go in the queue.
To Reproduce
Adding a comic to the software with queue, I was trying to read https://www.webtoons.com/en/action/omniscient-reader/episode-10/viewer?title_no=2154&episode_no=11
Kea Version
What version of Kea were you using? Latest in releases.

Kea actually requires the link of the page were all chapters are listed (for your example the link would be: https://www.webtoons.com/en/action/omniscient-reader/list?title_no=2154).
I hope this helps and sorry for the inconvenience.

Thank's for the quick response, it fixed my issue. Thank you!


Unicode characters are rendered as emoji on mobile website homepage preview

There’s probably some CSS properties we can use to disable this.

I would like to fix this.

@paulomenezes Go for it! Clone the repo and run the following commands to setup the website for development:
cd website
npm install
npm run start

You'll then get a URL in the terminal that you can open.

I found that we can use  right after the unicode to prevent this be rendered as an emoji, but I don't know if is the best solution because this image can be replaced in the future.


Feature Request: Create a instrumentation for Feign

"Feign makes writing java http clients easier".
It also supports adding Request Interceptors https://github.com/Netflix/feign#request-interceptors that could be used to instrument Feign

As an alternative, you can use OkHttp with Feign and use https://github.com/openzipkin/brave/tree/master/brave-okhttp

ps feign isn't the easiest thing to manage right now as interceptor only
affects inbound. Ex you have to play games to catch the other side (by
using an invocation handler or hacking a decoder or the like).
rejigging this part would probably be good for
https://github.com/OpenFeign/feign and emulate how okhttp does it.
The advantage of doing this in feign level is that you can use the template
name or class name of the feign interface as the span name, which makes it
look prettier than "GET"

The greatest advantage for me at this moment is that Feign already provides an integration with Hystrix: https://github.com/OpenFeign/feign/tree/master/hystrix
That's why I wanted to see Feign being supported so I could easily have: Feign + Hystrix for circuit-breaker + Zipking for distributed tracing.
The implementation that I was able to write to have this integration working is too "complex" to be easily consumed: https://github.com/redhat-helloworld-msa/hola/blob/master/src/main/java/com/redhat/developers/msa/hola/HolaResource.java#L95-L114

we can probably do this, but it is a little tricky, especially when
layering with things like hystrix
in the mean time, you can look at sleuth which already supports
feign+hystrix https://github.com/spring-cloud/spring-cloud-sleuth

In thinking this through, I think that Feign would be best as a "local span".
For example, feign's span would correlate to the method being invoked. Considering that the feign.Client implementation is traced in the case of OkHttp, we'd end up with something like this.
For example, feign's local span would have a child RPC span for each http request attempt:
{name: github.contributors // start when the method is invoked
  {name: get ["cs", "error"] }, // new span logged by okhttp
  {name: get ["cs", "cr"] },  // new span logged by okhttp
} // finish when the method returns

We could add to it later, like add annotations, etc, but the easiest way to get started is to create a span and assume the client is instrumented.

So just wondering, is this still an issue considering the changes that have been pushed in by @adriancole ? I was also kind of curious about this feature set, good to see my old buddy @rafabene had the same idea.

The tricky part with feign is not doing double-dip tracing. For example, if OkHttp is below, it should really own the client span, similarly ApacheHC. A "cheap" way out would be to wrap feign.Client, but it is scarcely better than, and could interfere with transport-level tracing. When thinking about how to implement this, see how it goes with and without a traced client underneath.

The other tricky part is the entrypoint. a wrapped Feign builder is neat, though this interferes with the Hystrix one! You could make hystrix an optional dep and do 2 entrypoints: TracingFeignBuilder and TracingHystrixFeignBuilder :P

probably good time to try this as Brave 4.3 is out

Sleuth defines a wrapper for feign clients (https://github.com/spring-cloud/spring-cloud-sleuth/tree/master/spring-cloud-sleuth-core/src/main/java/org/springframework/cloud/sleuth/instrument/web/client/feign)
Should we port the code from sleuth to brave instrumentation now that Sleuth is using Brave ?
That would makes sense as it's how it is for Kafka for example.

The way it's done in Sleuth is shameful :P It would be better for someone to actually try to write it from scratch.

nothing new here? :(

we could do something like this, though I wouldn't integrate spring cloud loadbalancer, etc, as that's where it gets gnarly. This means this code might not be literally used by sleuth.
https://github.com/spring-cloud/spring-cloud-sleuth/blob/master/spring-cloud-sleuth-core/src/main/java/org/springframework/cloud/sleuth/instrument/web/client/feign/TracingFeignClient.java
Any volunteers?


Update parsing-lync-published-category-instances.md

Removed gray halo around two alerts in the page.

:white_check_mark: Validation status: passed

File
Status
Preview URL
Details

docs/parsing-lync-published-category-instances.md
:white_check_mark:Succeeded

For more details, please refer to the build report.
Note: If you changed an existing file name or deleted a file, broken links in other files to the deleted or renamed file are listed only in the full build report.

Closing this request and adding changes to my version.


conda-forge package

Is it possible to publish any new release package to conda-forge and conan?

Hi @domcir, so far the releases to Conan have always been done my someone in the community. We've never done this ourselves.
If you want to do it, feel free to do so. Otherwise, I could do it as well.


I can't upload my text file to firebase storeage

I've followed the instructions and set all the parameter accordingly. The code seems fine when it comes to writing something into SPIFFS but when it comes to uploading it to the firbase storage it says "File not found". Please help, thanks.

This repository is for the library that works with RTDB database and legacy Firebase Cloud Messaging only.

You should read comments in the library examples carefully.

That is because file name you provide to the upload function does not exist in flash filesystem.
You can upload the sketch data using the upload tool plugin in Arduino IDE by creating the data folder with your files inside at the same path of your sketch file.
The simplest way to test without upload sketch data is testing with download example first.
Then test upload example with the file that you download previously.

Hi, I’ve tried the DownloadFile and it worked fine. It can download and read the file in Firebase Storage. But when I swap to UploadFile and change mime type to “text/plain”, the same message appeared “File not found”.
Sent from Mailhttps://go.microsoft.com/fwlink/?LinkId=550986 for Windows
From: Suwatchai @.>
Sent: Sunday, 5 March, 2023 2:53 AM
To: @.>
Cc: MUHAMMAD DANISH BIN @.>; @.>
Subject: Re: [mobizt/Firebase-ESP32] I can't upload my text file to firebase storeage (Issue #267)
That is because file name you provide to the upload function does not exist in flash filesystem.
You can upload the sketch data using the upload tool plugin in Arduino IDE by creating the data folder with your files inside at the same path of your sketch file.
The simplest way to test without upload sketch data is testing with download example first.
Then test upload example with the file that you download previously.
—
Reply to this email directly, view it on GitHubhttps://github.com/mobizt/Firebase-ESP32/issues/267#issuecomment-1454840288, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AR4AWRPOFCL565HXRU6MJMLW2OFQZANCNFSM6AAAAAAVPUQG3Y.

You should post your code and all the debug message on serial to see what's wrong in your code.

Please use Github instead of using Email reply.

I’ve posted it on GitHub thanks.
From: Suwatchai @.>
Sent: Sunday, 5 March, 2023 4:02 AM
To: @.>
Cc: MUHAMMAD DANISH BIN @.>; @.>
Subject: Re: [mobizt/Firebase-ESP32] I can't upload my text file to firebase storeage (Issue #267)
Please use Github instead of using Email reply.
—
Reply to this email directly, view it on GitHubhttps://github.com/mobizt/Firebase-ESP32/issues/267#issuecomment-1454858880, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AR4AWROALJYSYVP6PNGZ4ZTW2ONVRANCNFSM6AAAAAAVPUQG3Y.
You are receiving this because you authored the thread.Message ID: @.***>

As I said, you should post your code not snippets and all Serial debug.

Sorry, I’ve posted the full one.
From: Suwatchai @.>
Sent: Sunday, 5 March, 2023 4:14 AM
To: @.>
Cc: MUHAMMAD DANISH BIN @.>; @.>
Subject: Re: [mobizt/Firebase-ESP32] I can't upload my text file to firebase storeage (Issue #267)
As I said, you should post your code not snippets and all Serial debug.

—
Reply to this email directly, view it on GitHubhttps://github.com/mobizt/Firebase-ESP32/issues/267#issuecomment-1454862067, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AR4AWRJKUM4EHRCB6EPZTRLW2OPB5ANCNFSM6AAAAAAVPUQG3Y.
You are receiving this because you authored the thread.Message ID: @.***>

The issue will be fixed soon. I will inform you when it is available.


add MagicLink in the test case

Specifically, it's needed in TestTicket so the devcon folks can see how they can generate one of those.

I have refactored testURL so that the Ticket tests are now in testTicket and the Cheque tests are in testCheque.
The test testTicketURLSunshine constructs a magic link

I have refactored testURL so that the Ticket tests are now in testTicket and the Cheque tests are in testCheque.
The test testTicketURLSunshine constructs a magic link


Merge docs and add links

Fixes https://github.com/rapidsai/cucim/issues/397
Fixes https://github.com/rapidsai/cucim/issues/395

Symlinks top-level README and CHANGELOG into python/cucim/
Adds links to the developer page on PyPI and Anaconda
Also adds links for docs, source, etc.

cc @grlee77 @gigony

Also confirmed that running python setup.py sdist resolved the symlinks correctly to include the README.md and the CHANGELOG.md in the sdist produced.
With python setup.py bdist_wheel, this content gets copied into the METADATA file included in the .whl.

rerun tests
(CI had some issue pulling from the repo)

@gpucibot merge


Rename {super,sub} set methods to clearly indicate relation of operands

I just realized that methods like Set#subset? apply in exactly the opposite direction to what I might expect.
I would probably read a predicate method subset?(b) as "is b a subset? (of the receiver)", i.e. b ⊂ a But instead a.subset?(b) returns true if a ⊂ b.
These semantics are the same as in Ruby. I suspect they have it that way to have the same operand relation as with the comparison operators. But it's really confusing. When reading the code, you can't  beyond doubt recognize which way it is.
So I'm proposing to rename these methods to a differnt, less ambiguous name. Adding a simple _of suffix would fix this. a.subset_of?(b) clearly means a ⊂ b.

Set#subset? => Set#subset_of?
Set#proper_subset? => Set#Proper_subset_of?
Set#superset? => Set#superset_of?
Set#proper_superset? => Set#proper_superset_of?

This also affects proposed similar methods for Hash (see https://github.com/crystal-lang/crystal/pull/7500#issuecomment-738044914)

Bang methods apply to the receiver. a.includes?(b) means "does a include b"? So a.subset?(b) naturally means "is a a subset of b?". So I don't this needs to change.
That said, adding the "of" suffix makes it a bit more readable.

Bang methods apply to the receiver. a.includes?(b) means "does a include b"? So a.subset?(b) naturally means "is a a subset of b?". So I don't this needs to change.
That said, adding the "of" suffix makes it a bit more readable.

I don't follow how you see a relation to bang methods. This is not about question mark representing nilable methods. Even if there is one, it's not obvious, which supports the argument that the API should be more explicit.
These are all predicate methods. And as such, either way to read the relation between receiver and arg is possible. And as I mentioned above, I intuitively read a.subset?(b) as asking a: "is b a subset?"
Removing this ambiguity is a good improvement.

I don't follow how you see a relation to bang methods. This is not about question mark representing nilable methods. Even if there is one, it's not obvious, which supports the argument that the API should be more explicit.
These are all predicate methods. And as such, either way to read the relation between receiver and arg is possible. And as I mentioned above, I intuitively read a.subset?(b) as asking a: "is b a subset?"
Removing this ambiguity is a good improvement.

Oh, sorry, I meant "question method".

And as I mentioned above, I intuitively read a.subset?(b) as asking a: "is b a subset?"

That's the thing. Whenever there's a.method?(b) it means "Is 'a method? b'" true? In the case of a.subset?(b) it means "is a a subset of b"? In the case of a.includes?(b)" is "does 'a includes b' hold true?". aalways appears **before**b` in the sentence.
A question method is always asking "Are you ...?" or "Do you ...?". It never asks something about the argument.
That said, I think the "of" suffix makes this a bit clearer.

Oh, sorry, I meant "question method".

And as I mentioned above, I intuitively read a.subset?(b) as asking a: "is b a subset?"

That's the thing. Whenever there's a.method?(b) it means "Is 'a method? b'" true? In the case of a.subset?(b) it means "is a a subset of b"? In the case of a.includes?(b)" is "does 'a includes b' hold true?". aalways appears **before**b` in the sentence.
A question method is always asking "Are you ...?" or "Do you ...?". It never asks something about the argument.
That said, I think the "of" suffix makes this a bit clearer.


Test discovery leaves too many files locked - causes problems for metaprogramming

Description
When using dotnet test (and presumably other approaches), the discovery phase locks dll files, which are kept  locked for the duration of the execution phase. This means that if any of the files are actually outputs (meta-programming artefacts), they will prevent the second (etc) test runs from executing successfully
Steps to reproduce

write a test that emits a dll (meta-programming, AssemblyBuilder etc) to the test folder during execution
run the test (file is generated)
run the test again (file cannot be regenerated as it is locked by discovery)

A more complete set of repro steps (including command-line and git commit) is in this report (I initially filed against xunit, and was redirected here)
Expected behavior
Subsequent test runs succeed, via one of (I have no strong views on which):

not locking files between discovery and execution
allowing an inclusion/exclusion filter from dotnet CLI to prevent unwanted locks from happening
implementing shadow-copy so that it doesn't matter what is locked (in the transient folder)
having obvious options (presumably in dotnet tooling hooks) to allow the test directory to be cleaned between runs

Actual behavior
File is locked; subsequent test runs fail
Environment
Windows 10  x64, dotnet 1.0.0, vstest.console 15.0.26228.0

One more option is to use System.Reflection.Metadata for discovery instead of Assembly.Load, then load only the assemblies that actually have extensions. Here's some sample code I've used for similar purposes.

@mgravell I could clean the output folder between test runs by adding following Target to test project. Hope this will help workaround the issue.
  <Target Name="CleanGeneratedTestFiles" BeforeTargets="PrepareForBuild" Condition="'$(TargetFramework)' != ''">
    <RemoveDir Directories="$(OutputPath)" />
  </Target>

If I've a test project test.dll and it generates a.dll during test execution. Now a.dll is generated during first run, for the second run we observe a.dll is getting loaded during dotnet test invocation. So when the test actually executes, it cannot generate/overwrite a.dll again. Since a.dll is generated at runtime, test.dll doesn't depend on a.dll, so it's weird why a.dll should get loaded during second test run (for discovery or execution). Is this understanding correct?
From a conceptual standpoint, the testhost process (which executes the test) and test platform has no knowledge of any test framework, it doesn't load the assemblies (it's a bug if it does). Knowledge of test framework and finding the tests in an assembly is with an adapter. Some adapters can possibly use metadata approach suggested by @aelij, a few frameworks allow code to be executed during discovery (e.g. xunit), they may not be able to use it.

I think the test host loads assemblies in order to discover extensions (see here for example). Couldn't that also be a problem?

See https://github.com/Mnuzz/AutoHotkey.FSharp/tree/31d34922e1163d1a1fe98fff2e66976df2f9039f for a (possible) self-contained reproduction of this issue from VS Test Runner.

The dll locking is absolutely annoying. Every build = fail. Need to kill discoveryengine first before build.

@mgravell The issue is because the TestMethods are creating some dll on runtime, & are unable to clean them up after they are executed, since the newly created dll's are loaded in the host process. This causes an issue during second run as the dll is already created, hence the Testmethod cannot create it again.
Can you please try the solution codito proposed.
@llehn the discoveryengine has been replaced by our new testplatform in VS2017.5

@mgravell , can you please review my above comment, & confirm if it works for you?

@mgravell , as per explanation above, I'm closing issue. Please reopen it if there is a need to discuss more on it.

@Aaronontheweb Can you please create new issue with detail repro steps?


FAB Button square in shape

FAB Button square in shape.

On what platform? This isn't happening on Android and iOS.

Yep. This is happening on my Android device (v6.0.1)

@tonholis - Ensure the renderer has installed properly through NuGet. In the references folder of the Android project, you should see the two references:

SuaveControls.FloatingActionButton
SuaveControls.FloatingActionButton.Droid


Documentation is not clear that this requires SimplSharpReflectionInterface to work

Update documentation to clearly list dependencies.

Thanks for this, I've updated the documentation to include a section on dependencies.


Organ donor registration on Completed Transaction

Once govuk_content_models change is merged, I'll update this PR.
https://trello.com/c/caDndyIX
Completed transaction pages need to optionally show organ donor registration promotion. Form fields are stored as presentation_toggles on Edition: https://github.com/alphagov/govuk_content_models/pull/292

Checking "Promote organ donor registration" shows the URL text input:

If you've chosen to promote, entering the URL is mandatory:

In general :+1:
I think it would be great if @fofr could review this - I'm not sure about the placeholder URL. Unless you View Source (or similar), you can't copy the URL, so why have it? If it's the default, why don't we make it the default?

I can't access the Trello card which may answer my question: Why does the URL need to be editable?
I agree with @jamiecobbett’s point about having a default value rather than a placeholder.
"Organ donor registration promotion" is hard to read. Using the active voice it can be made better:
"Promote organ donor registration". This could be the label for the checkbox, and checking it could toggle the display of the URL, if the URL must be editable. These are mostly reckons, I still need to review the changes in-app.

@fofr: The URL needs to be editable because it contains tracking query parameters, which are unique for each completed transaction page.
About the labels, these have been suggested by Nayeema and @marksheldonGDS. I like your suggestions, would like them to confirm if they look OK.
The only reason I've not toggled the URL display based on the checkbox value is because I'm assuming that content editors might have access to the URL before they'd turn-on the promotion, and it'll be good to allow them to store those URLs without having to turn-on the promotion. Also, when they turn off the promotion, I've chosen to not blank out the URL, so that when they decide to turn it on again, they don't have to search for the URL, and also so that it remains as a record. So I've decided to keep those to fields independently editable. This is one assumption which I hoped to get tested during Product Review.

@vinayvinay The changes @fofr is suggesting for the labels are great, so use those. Also, as @fofr suggests we should show/hide the URL when the checkbox is toggled on/off.

@fofr: i've updated the labels and added the toggle functionality.

I've added a couple of notes, otherwise it looks good :smile:

@fofr: i've made the changes you suggested.
also, i've simplified the form a bit after you last looked: https://github.com/alphagov/publisher/commit/845f6afcc788941e989772dc91999f0cfe523d5b

Looks good to me :+1:

:gift_heart:


Make sure the submit action can only be fired once with once: true

Not sure if this is already ensured. There is an option to make an event listener to only able be fired once, which can be beneficial in preventing duplicate submissions.
https://developers.google.com/web/updates/2016/10/addeventlistener-once

Though of course if the submission failed maybe we should also be able to let them try again?

Not really urgent for now.


RFR: Diff any object master

@kevinmook here is the dyph3 changes, you can pass lambdas into the merge_text method to handle the splitting and joining. Its is currently set up to default to backward compatibility

@aamontal woo! Thanks!


Unlock Broadlink Devices if locked to the Cloud

Existing Locked RM4 pros can be unlocked without resetting, just found out, you can have the best of both worlds, the cloud services and node-red. You can do this by unchecking the lock device property in the device property from within the app.
Step One:
Tap your RM 4 Pro

Step Two:
Tap the top right hand corner of the screen the triple dots button and tap the property button

Step Three:
Uncheck the lock device option.

Step Four:
Profit

Added this to the readme in the 2.1.5 release

mine is not working... even though I have unchecked the unlock option... still node-red is not able to communicate with it. I'm seeing it on the router and I can see the IP and MAC... so the wifi connection works, doesn't work on local. Any other method to test it?


sprintfix: 修复探测文件服务到 2.0 Proxy 10020/10030 端口不通的问题 (fixed #1239)

Codecov Report

Merging #1419 (04f11f0) into v2.3.1-dev (e48a3ce) will increase coverage by 0.00%.
The diff coverage is 100.00%.

@@             Coverage Diff             @@
##           v2.3.1-dev    #1419   +/-   ##
===========================================
  Coverage       73.86%   73.86%
===========================================
  Files             369      369
  Lines           25068    25073    +5
===========================================
+ Hits            18517    18521    +4
- Misses           6551     6552    +1

Impacted Files
Coverage Δ

apps/node_man/constants.py
96.25% <ø> (ø)

...collections/agent_new/check_policy_gse_to_proxy.py
100.00% <100.00%> (ø)

...nents/collections/agent_new/choose_access_point.py
94.90% <0.00%> (-0.47%)
:arrow_down:

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.


[Bug] passwords of some accounts are lost due to doris upgrade from 1.1.4 to 1.2.0

Search before asking

[X] I had searched in the issues and found no similar issues.

Version
doris-1.2.0-rc04
What's Wrong?
1、doris's version upgrade from  1.1.4 to 1.2.0
2、passwords of some accounts are lost
What You Expected?
origin accounts and passwords not changed after doris upgrade finished
How to Reproduce?
No response
Anything Else?
no
Are you willing to submit PR?

[ ] Yes I am willing to submit a PR!

Code of Conduct

[X] I agree to follow this project's Code of Conduct

duplicate


Websocket Connections resuliting in Forbidden

I've been working with Headlamp for quite a while now however, I never had a working websocket connection. I first figured out that the host was not added to the cors for kube-apiserver, however after adding that the issue persisted.
The verbose kube-apiserver logs show
I0602 17:59:03.237196       1 authorization.go:87] "Forbidden" URI="/api/v1/namespaces?watch=1&resourceVersion=4560559" reason=""

for all requests coming from Headlamp.
When trying to make the request using CURL the following is returned:
{
  "kind": "Status",
  "apiVersion": "v1",
  "metadata": {},
  "status": "Failure",
  "message": "pods \"kube-apiserver-master.rph\" is forbidden: User \"system:anonymous\" cannot watch resource \"pods\" in API group \"\" in the namespace \"kube-system\"",
  "reason": "Forbidden",
  "details": {
    "name": "kube-apiserver-master.rph",
    "kind": "pods"
  },
  "code": 403
}

However when directly opening the websocket to the kube-apiserver the websocket does connect.
I assume that it is an issue in the nginx configuration, but after hours of trail-and-error I have not been able to figure anything out. This is the configuration being used by nginx-ingress
# configuration for kube-system/headlamp
upstream kube-system-headlamp-k8s.roleplayhub.dev-rph-k8s-headlamp-80 {zone kube-system-headlamp-k8s.roleplayhub.dev-rph-k8s-headlamp-80 256k;
	random two least_conn;
	server <IP_ADDRESS>:4466 max_fails=1 fail_timeout=10s max_conns=0;
}

server {
	listen 80;listen [::]:80;
	listen 443 ssl;listen [::]:443 ssl;
	ssl_certificate $secret_dir_path/kube-system-headlamp;
	ssl_certificate_key $secret_dir_path/kube-system-headlamp;

	server_tokens on;

	server_name k8s.roleplayhub.dev;

	set $resource_type "ingress";
	set $resource_name "headlamp";
	set $resource_namespace "kube-system";
	if ($scheme = http) {
		return 301 https://$host:443$request_uri;
	}
	large_client_header_buffers 4 64k;

	location / {
		set $service "rph-k8s-headlamp";
		proxy_http_version 1.1;

		proxy_connect_timeout 60s;
		proxy_read_timeout 60s;
		proxy_send_timeout 60s;
		client_max_body_size 1m;
		proxy_set_header Host $host;
		proxy_set_header X-Real-IP $remote_addr;
		proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
		proxy_set_header X-Forwarded-Host $host;
		proxy_set_header X-Forwarded-Port $server_port;
		proxy_set_header X-Forwarded-Proto $scheme;
		proxy_buffering on;
		proxy_pass http://kube-system-headlamp-k8s.roleplayhub.dev-rph-k8s-headlamp-80;

	}

}

Any ideas on how to resolve this or debug the issue any further? I love headlamp and would love to see websockets in action as well!

Thanks for reporting @rowan-vr . Do you happen to have an idea what was the last Headlamp version that worked for you? That would help us look in the right direction.

Hi, I've solved the problems!
It was because some default config settings from nginx-ingress-controller (https://docs.nginx.com/nginx-ingress-controller/) (NOT THE SAME AS nginx-ingress) were preventing websocket connections.
To make it work using nginx-ingress-controller you have to enable the following flags in the ingress resource annotations:
   nginx.org/proxy-buffering: "false"
   nginx.org/websocket-services: "headlamp"

Oh right. We should try and add some better docs for this… or maybe we can detect the error and make a suggestion of how to fix it.


Show coverage for python wrappers

Current coverage is 89.31%

Merging #106 into master will decrease coverage by -0.22% as of 1ff0438

@@            master    #106   diff @@
======================================
  Files           60      65     +5
  Stmts         3918    4091   +173
  Branches         0       0
  Methods        227     273    +46
======================================
+ Hit           3508    3654   +146
  Partial          0       0
- Missed         410     437    +27

Review entire Coverage Diff as of 1ff0438

Powered by Codecov. Updated on successful CI builds.

https://codecov.io/github/ORNL-CEES/Cap/python/source/wrappers?ref=d5bfa6a2b742c56931b5e150eecbb9770034ce42

patch did NOT work
headers are not showing up

don't get it...


Some small suggestions/fixes

Hi! First off -- great component, much better than my attempt at a tag input.
I have noticed a few things that I thought I'd mention:

When using an autocomplete, an option to pre-select the first item would be nice, to prevent the user from having to press down->enter, instead of just enter.
When using an autocomplete with more than a few items, the dropdown that appears can obstruct the rest of the view, and also seems to flicker as it finds whether it should appear above or below the input

Maybe an option for maximum number of results to show in the dropdown
Maybe an option for minimum number of characters before the dropdown shows

When using an autocomplete, the backspace behaviour is a bit buggy, most of the time it just re-displays the autocomplete dropdown on keydown, and will never select/remove an earlier tag. If you tab off of the field and shift-tab back to the field, it lets you remove a single tag with backspace before returning to the aforementioned behaviour

<EMAIL_ADDRESS><EMAIL_ADDRESS>

Hi @rosslavery, thanks!
I'll have a look! Most of these bugs belong to another library I've written, but I've actually spent little time on it so far

I second these issues. On iPhone/Pixel form factor (Chrome, Safari), other issues are - auto-complete pop-up flickering up/down, obstructing the input field, hiding the X on long tags, not being able to delete with delete key, and not allowing editing of the tag in a consistent manner.


Design Learn Section and cards as mentioned in the workplan

@deepakDOTexe can i work on this ?

@deepakDOTexe Can i wok on this ? I didn't get assigned to any of the issue in that repo

@kumarmanish03 Go ahead @geeks5551 You already have 2 issues assigned.

any new issue that I can take?

can i take any new issue ?

@achalesh27022003 you can work on this as @kumarmanish03 has not made any updates on this

@deepakDOTexe  Hey I want to work on this (previously i am busy on Geekhaven repo issues)
I will surely make pr soon (as i completed almost half of it). Plz assign it to me

@deepakDOTexe sir please check this out. If not required close the issue or assign it to someone. Thanks!


Seeing the following error when trying to get to any of the az iot ops commands

My az --version is:
azure-cli                         2.54.0
core                              2.54.0
telemetry                          1.1.0
Extensions:
arcappliance                      0.2.31
azure-iot-ops                    0.1.0b1
connectedk8s                      1.3.20
connectedvmware                   0.1.12
customlocation                     0.1.3
k8s-extension                      1.4.1
Dependencies:
msal                            1.24.0b2
azure-mgmt-resource             23.1.0b2
Python location 'C:\Program Files (x86)\Microsoft SDKs\Azure\CLI2\python.exe'
Extensions directory 'C:\Users\ColinRippey.azure\cliextensions'
Python (Windows) 3.11.5 (tags/v3.11.5:cce6ba9, Aug 24 2023, 14:21:31) [MSC v.1936 32 bit (Intel)]
Legal docs and information: aka.ms/AzureCliLegal
Your CLI is up-to-date.
When I run az iot --help I see:
D:\a_work\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\cryptography/hazmat/backends/openssl/backend.py:27: UserWarning: You are using cryptography on a 32-bit Python on a 64-bit Windows Operating System. Cryptography will be significantly faster if you switch to using a 64-bit Python.
Unable to load extension 'azure-iot-ops: No module named 'kubernetes.client.exceptions''. Use --debug for more information.
Group
az iot : Manage Internet of Things (IoT) assets.
Subgroups:
central : Manage IoT Central resources.
dps     : Manage Azure IoT Hub Device Provisioning Service.
hub     : Manage Azure IoT hubs.
To search AI knowledge base for examples, use: az find "az iot"
I'm guessing the line Unable to load extension is an issue that needs resolving, happy to provide more details and/or try steps.

@colinrippeyfinarne thanks for submitting this issue.
Can you please try updating (or removing) the arcappliance extension you have installed? There is a dependency conflict issue which should be resolved with one of those two mentioned options.

Hi @colinrippeyfinarne, I cannot repro the issue with same version of the extension you installed. However, have you try uninstall and reinstall the kubernetes using pip install kubernetes to see if that fix the issue? And could you also provide the --debug output if it's not fixed? thanks for the patience.

I'll try this today and also the suggestion from @digimaun and let you know the results.

Closing the issue. If you are still running into problems after trying the suggested, let us know and we can re-open.


Fix prediction errors due to incorrect checking of extracted entities

Proposed changes:

Change rasa.core.test.EvaluationStore to tolerate duplicates or differences in ordering when comparing for a given message the expected entities and the actually extracted entities

Status (please check what you already did):

[x] added some tests for the functionality
[ ] ~updated the documentation~ checked that no changes to docs are needed
[x] updated the changelog (please check changelog for instructions)
[x] reformat files using black (please check Readme for instructions)

@JEM-Mosig pinging you as this is waiting for your review.


Fix grey_getText

Fix #456

sure, I updated the text. the PR is set to allow edits from maintainers. feel free to make any adjustments as necessary.
I will be back on Monday. 😄


Unable to resize Editor window

From pierre.raybaut on 2010-04-23T02:42:00Z
At first Spyder startup or after running 'spyder --reset' the editor window
width seems to be fixed: the associated dockwidget can't be resized.
More data on how to reproduce this issue is needed, so please do no hesitate
to comment this issue by adding the following informations:

how to reproduce this issue
your configuration details -- see 'About' dialog box in Spyder (OS,
Spyder's version, PyQt version, Qt version)

Original issue: http://code.google.com/p/spyderlib/issues/detail?id=212

From pierre.raybaut on 2010-04-23T00:43:23Z
Here is another similar report: http://groups.google.com/group/spyderlib/t/3ea427a0ab9f3f19

From pierre.raybaut on 2010-04-23T02:52:33Z
Status: Fixed


Remove and destroy fastly_tls_subscription.cache-staging

b3385ad3768154778afafe042b74dd34eb1ecbba has cleaned up ~all of cache-staging, but the TLS subscription remains because I can't destroy it myself. Can someone with more Fastly access take care of cleaning it up?
Assigning to @zimbatm by default since I don't know precisely who has that access.

It's just eelco and me that have access right now.


Add gzip to buildTools

Issue

Buildkite builds are failing because gzip is missing

checklist

[X] This PR contains all the work required to resolve the linked issue.

[] This PR results in breaking changes to upstream dependencies.

[] The work contained has sufficient documentation to describe what it does and how to do it.

[X] The work has sufficient tests and/or testing.

[X] I have committed clear and descriptive commits. Be considerate as somebody else will have to read these.

[X] I have added the appropriate labels to this PR.

bors r+


Annotate lister

This required a hack because of python/mypy#1458.
What should be done now? Should we wait for a fix from mypy or is it better to add this and later update this code when a fix comes out?

Automated message from Dropbox CLA bot
@sharmaeklavya2, it looks like you've already signed the Dropbox CLA. Thanks!

Hmm, another solution to this would be to just use two different variable names for the two different possible result types (would probably call them matching_files and grouped_matching_files rather than just result_list and result_dict, but whatever), but then just eliminate the result variable and just at the end do:
if group_by_types:
    return grouped_matching_files
return matching_files

Do you think that'd be cleaner @sharmaeklavya2?

Nice suggestion! It worked and it looks better. I have updated this PR.

Great, merged!


Adds gcsweb to istio.io to use its certs

Use isito.io nginx proxy to redirect gcsweb.istio.io to in cluster service.

alternative would be to start using cert manager like
https://github.com/istio/admin-sites/tree/master/fortio#fortio-on-istio
which I think we eventually want to move to for all of our sites ?


Support syncing subfolders only

In my example, I'd sync only /media/frigate/clips, which in my case has 5GB. My whole /media has /media/frigate/recordings which has almost 700GB in size.

That's fine, you can use /media/frigate/clips as your path.


Tighten security of our Auth Token (JWT) via CSRF prevention techniques

References

Requires https://github.com/DSpace/DSpace/pull/3001  (REST PR MUST be merged prior to, or at the same time as this PR)

Description
This PR makes minor changes to the Angular UI corresponding to the tightened security applied in https://github.com/DSpace/DSpace/pull/3001
Namely, it does the following:

Updates Logout to send a POST request (instead of GET), as required by ttps://github.com/DSpace/DSpace/pull/3001
Ensures a new X-DSpace-UI custom header is passed on every request (see new DSpaceHeaderInterceptor & corresponding tests).  This new header is used to pass the UI's URL/origin to the backend just in case the Origin or Referer headers are not sent.  As Angular Universal seems to not send the Origin or Referer headers, this custom header is primarily for SSR requests (as user browsers tend to send either Origin or Referer or both).

Instructions for Reviewers

Review the code & tests
Install & run against https://github.com/DSpace/DSpace/pull/3001

When run with yarn start (AoT compilation), verify that Login succeeds. When in production mode, a Login will trigger SSR during the hard refresh.  So, this Login will not succeed if you ran main against  https://github.com/DSpace/DSpace/pull/3001 (as the X-DSpace-UI header is required for SSR to use the Auth Token)
Also verify Logout still works.  Again, if you ran main against ttps://github.com/DSpace/DSpace/pull/3001, then logout would not succeed, as it is currently sent via a GET request.

WARNING: End-to-end tests are EXPECTED TO FAIL with this PR.  The reason is that e2e testing runs against live backend which is NOT currently running  https://github.com/DSpace/DSpace/pull/3001.  This results in CORS policy errors as the X-DSpace-UI custom header will be blocked.

You can see these CORS errors locally by running yarn run e2e:ci. They look will look like this:

[1019/123317.621:INFO:CONSOLE(0)] "Access to XMLHttpRequest at 'https://dspace7.4science.cloud/server/api/sites' from origin 'http://localhost:4000' has been blocked by CORS policy: Request header field x-dspace-ui is not allowed by Access-Control-Allow-Headers in preflight response.", source: http://localhost:4000/ (0)

Checklist

[x] My PR is small in size (e.g. less than 1,000 lines of code, not including comments & specs/tests), or I have provided reasons as to why that's not possible.
[x] My PR passes TSLint validation using yarn run lint
[x] My PR doesn't introduce circular dependencies
[x] My PR includes TypeDoc comments for all new (or modified) public methods and classes. It also includes TypeDoc for large or complex private methods.
[ ] My PR passes all specs/tests and includes new/updated specs or tests based on the Code Testing Guide.

[x] If my PR includes new, third-party dependencies (in package.json), I've made sure their licenses align with the DSpace BSD License based on the Licensing of Contributions documentation.

@atarix83 : Thanks for your testing!  I took a look at the demo sites you linked to, and I think there might be a configuration issue with the Angular UI (but I'm not 100% certain).  Here's what I see:

First off, the REST API looks correct.  I can see that it's got dspace.ui.url and dspace.server.url set properly as the values appear in the dspaceUI and dspaceServer properties on the homepage: https://dspace7test.dev01.4science.cloud/server/
However, the Angular UI looks like it may have incorrect configurations.

If I access https://dspace7test.dev01.4science.cloud/home and try to login, I see that the  new X-DSpace-UI header is set to http://localhost:4001.  I would expect it to be set to https://dspace7test.dev01.4science.cloud/, as that's the full URL of the Angular UI.

Because of that UI configuration, I suspect this is what I suspect happening:

First, I'm assuming you are running the UI in production mode with SSR / Angular Universal enabled.
When you login from the UI, a hard refresh is triggered. The request will look something like: https://dspace7test.dev01.4science.cloud/reload/1603981488190?redirect=%2Fhome in Chrome DevTools
That hard refresh triggers Angular Universal/SSR (as it's similar to hitting reload in your browser). So, a 'status' request is first made via Angular Universal to the backend. This request should send the X-DSpace-UI header.  But, since the value of that header is http://localhost:4001, the backend will block access to the JWT (as the JWT was generated using an original origin of https://dspace7test.dev01.4science.cloud/)
Assuming that is occurring, on the backend in the DSpace logs, you'd see a WARNING like: EPerson [email] at Origin 'http://localhost:4001' tried to reuse a token which is not valid for this Origin or EPerson.   That warning is telling you that the JWT exists, but it was attempted to be reused by a different origin or person (in this case, a different origin).

Overall, I think the problem here is that your frontend configuration needs to be something like:
ui: {
  ssl: true
  host: 'dspace7test.dev01.4science.cloud',
  port: 80,
  namespace: '/',
},

Essentially, the X-DSpace-UI header is set based on the values in your ui configuration. And it needs to match the URL set in dspace.ui.url on the REST API backend. If I'm misunderstanding your setup let me know.

@paulo-graca : Were there any error messages in the logs or Chrome DevTools that might give a hint as to why Shibboleth wasn't working properly? Did you test logging in via Shibboleth using the HAL Browser as well (with  DSpace/DSpace#3001 installed)?  I'm just trying to see if I can narrow down the issues that are specific to Shibboleth.  Thanks for your testing!

@atarix83 : A quick update for you.  With @paulo-graca 's help, I found an issue on the backend with Shibboleth logins from the Angular UI.  Previously, Shibboleth logins worked from the HAL Browser, but didn't work from Angular UI unless you set jwt.login.token.include.origin = false on the backend.  I believe that is now fixed (see https://github.com/DSpace/DSpace/pull/3001#issuecomment-721418142).
It is possible this is the issue you were seeing in your initial tests.  So, if you can find time to retest, I'd appreciate it!  Keep in mind though (as I previously mentioned) the UI settings in the Angular configs still need to match the dspace.ui.url on the backend for everything to work as expected.

Closing, replaced by #977.  I've figured out a way to simply enable CSRF Protection in Spring Security with customizations to allow it to work for Shibboleth & cross domain. Therefore, this "tighten security" approach is no longer necessary.


Face card stagger

Add a feature to repeat advantage face cards while avoiding brave chains.
For example Lartoria Eresh Waver comp for Christmas 2020, card order should be Lartoria Eresh Lartoria or Eresh Lartoria Eresh. As of right now, FGA seems to go straight to Waver's Buster card after the 2nd card

@MathewSachin I would like to help implement this feature, but I am not familiar with the code base. When you have some time, could you point out the relevant classes that I should be looking for?
I was thinking about creating a way to recognize different servant face cards (similarly how we can register custom CEs).
That would also allow some use cases like prioritizing NP Gain for a specific servant, and so on

@LouizFC  Per-servant priority is not much difficult to code, but, the UI would get very messed up with it.
See #137 which asked for selecting specific servant's cards, for my reasoning.
Brave chains feature was what I came up with as a compromise and implemented in #212. The files changed in that pull-request are the ones most relevant to you, if you still want to experiment.

Now, regarding this issue, Avoid brave chains does have the problem of only looking left to right on the cards so in some cases what it picks will not be the most optimal, but, I've found it satisfactory for all my use cases till now. I mean, if we're face-carding anyways, taking another turn is no big deal.
Take an example of getting the following cards (B, A, Q are Buster, Arts, Quick respectively) and assuming the default card priority with Avoid brave chains:
Lartoria (B) Eresh (B) Eresh (B) Waver (A) Waver(B)
You would expect it to pick Eresh (B) Lartoria (B) Eresh (B).
But, since it only looks left to right as of now, it picks Lartoria (B) Eresh (B) Waver (B).
Since Lartoria (B) and Eresh (B) have the same priority, it picks the first one from the left, which is Lartoria (B). It then picks Eresh (B). Now, it can't pick another Eresh (B) because Avoid brave chains ensures that the consecutive cards are of different servants (unless an NP is included). So, it chooses Waver (B) which is the card with the next highest priority and also of a different servant.
This is the case this issue is asking an improvement over.
But, it's not really simple to fix it while keeping the existing card priority mechanism.
Like, if instead, the cards were Lartoria (B) Eresh (A) Eresh (Q) Waver (A) Waver (B). There's no choice but to pick Lartoria (B) first since it is WB which is the highest priority in the default case we're assuming.

Take an example of getting the following cards (B, A, Q are Buster, Arts, Quick respectively) and assuming the default card priority with Avoid brave chains:
Lartoria (B) Eresh (B) Eresh (B) Waver (A) Waver(B)
You would expect it to pick Eresh (B) Lartoria (B) Eresh (B).
But, since it only looks left to right as of now, it picks Lartoria (B) Eresh (B) Waver (B).

I haven't read the code yet, so assuming what you just said, the problem is the card order?
If the problem is the card order, I think that pre-processing duplicate cards should be enough.

Lets assume the way you are current weighing is the following (let me know if it is correct):

the card type from 1 to 9 based on the priority configured
sorting them in crescent order, and picking the first 3
"Avoid Brave Chains" drops consecutive cards.
the following card priority (WB(1), WA(2), WQ(3), B(4), A(5), Q(6), RB(7), RA(8), RQ(9))
So, in the example, the card weight would be:

|   WB (1)   |   WB(1)   |   WB(x)*  |    A(5)   |   B(4)   |
Lartoria (B) | Eresh (B) | Eresh (B) | Waver (A) | Waver(B) |
* the "x" means the card is out of the sorting

The resulting order would be:
Lartoria (B) | Eresh (B) | Waver (B)

To have Eresh (B) Lartoria (B) Eresh (B), we could add a "sorting step" to before card priority is calculated. This sorting step would group the cards by type and servant, then iterate the over the "grouped" cards and redistribute then like so:
Input: Lartoria (B) | Eresh (B) | Eresh (B) | Waver (A) | Waver (B)

Grouping: Lartoria (B) (1) | Eresh (B) (2) | Waver (A) (1) | Waver (B) (1)
// we sort so the cards with most appearances goes first
Sorting: Eresh (B) (2) | Lartoria (B) (1) | Waver (A) (1) | Waver (B) (1)

First iteration:  Eresh (B) | Lartoria (B) | Waver (A) | Waver (B)
Second iteration: Eresh (B)

Pre-processed Order: Eresh (B) | Lartoria (B) | Waver (A) | Waver (B) | Eresh (B)
Output (after calculating priority): Eresh (B) Lartoria (B) Eresh (B)

Then feed this card order to the priority calculator.
Another example, with "double, double cards" would be:
Input: Lartoria (B) | Lartoria (B) | Waver(B) | Eresh (B) | Eresh (B)

Processing: Lartoria (B) (2) | Waver (B) (1) |  Eresh (B) (2)
Sorting: Lartoria (B) (2) | Eresh (B) (2) | Waver (B) (1)
First Iteration: Lartoria (B) | Eresh (B) | Waver (B)
Second Iteration: Lartoria (B) | Eresh (B)

Output: Lartoria (B) | Eresh (B) | Waver(B) | Lartoria (B) |  | Eresh (B)
Result: Lartoria (B) | Eresh (B) | Lartoria (B)

@LouizFC I decided to go with a simpler approach

Step 1: Sort cards by user-specified priority
Step 2: Pick top 3 priority cards and group by servant
Step 3: If number of groups:

3: fallback to Normal card selection
2: Ideal case: Sort descending by group size and stagger. g[0][0], g[1][0], g[0][1]
1: Pick the highest priority card belonging to another servant. If none, fallback to normal card selection. If found, remove least priority card from the only existing group and treat the newly picked card as another group and follow the same procedure for 2 groups.

I'll make this available in Avoid Brave chains with Rearrange cards so that people can keep the existing behaviour of Avoid Brave chains if they want to.

@LouizFC I decided to go with a simpler approach

Step 1: Sort cards by user-specified priority
Step 2: Pick top 3 priority cards and group by servant
Step 3: If number of groups:

3: fallback to Normal card selection
2: Ideal case: Sort descending by group size and stagger. g[0][0], g[1][0], g[0][1]
1: Pick the highest priority card belonging to another servant. If none, fallback to normal card selection. If found, remove least priority card from the only existing group and treat the newly picked card as another group and follow the same procedure for 2 groups.

I'll make this available in Avoid Brave chains with Rearrange cards so that people can keep the existing behaviour of Avoid Brave chains if they want to.


Retain order of AND, OR filter children.

If we retain the order, it enables short-circuiting. People can put a
more selective filter earlier in the list and lower the chance that
later filters will need to be evaluated.
Short-circuiting was working before #9608, which switched to unordered
sets to solve a different problem. This patch tries to solve that
problem a different way.
This patch moves filter simplification logic from "optimize" to
"toFilter", because that allows the code to be shared with Filters.and
and Filters.or. The simplification has become more complicated and so
it's useful to share it.
This patch also removes code from CalciteCnfHelper that is no longer
necessary because Filters.and and Filters.or are now doing the work.

This patch moves filter simplification logic from "optimize" to
"toFilter", because that allows the code to be shared with Filters.and
and Filters.or. The simplification has become more complicated and so
it's useful to share it.

Note on this part: in theory, there is a performance risk here, since if toFilter() is called more often than optimize(), it means we'd do the simplification work more often. As far as I can tell, this isn't a big risk, since calls to toFilter() are generally either going through AbstractOptimizableDimFilter.toOptimizedFilter (which are cached) or are happening in places that are once per query, not once per segment (like FilteredAggregatorFactory's constructor).
Doing the above analysis made me feel like collapsing DimFilter and Filter would be a good idea.

This patch moves filter simplification logic from "optimize" to
"toFilter", because that allows the code to be shared with Filters.and
and Filters.or. The simplification has become more complicated and so
it's useful to share it.

Note on this part: in theory, there is a performance risk here, since if toFilter() is called more often than optimize(), it means we'd do the simplification work more often. As far as I can tell, this isn't a big risk, since calls to toFilter() are generally either going through AbstractOptimizableDimFilter.toOptimizedFilter (which are cached) or are happening in places that are once per query, not once per segment (like FilteredAggregatorFactory's constructor).
Doing the above analysis made me feel like collapsing DimFilter and Filter would be a good idea.


Async HEAD response hangs on application attempt to stream body

Yes, HEAD responses don't have bodies, but if an application tries to stream a body from a HEAD response anyway then the Body stream hangs.
I would expect the Body stream to return a None chunk immediately.
As an example, the following program never prints the “got chunk” message, whereas changing the request method from Head to Get causes the program to not hang.
extern crate futures;
extern crate reqwest;
extern crate tokio_core;

use futures::Stream;

fn main() {
    let mut reactor = tokio_core::reactor::Core::new().unwrap();
    let client = reqwest::unstable::async::Client::new(&reactor.handle()).unwrap();
    let future = client
        .request(reqwest::Method::Head, "http://example.com")
        .unwrap()
        .send();
    println!("CHECK: running request…");
    let mut response = reactor.run(future).unwrap();
    println!("CHECK: running response body…");
    let (maybe_chunk, _remainder_of_body) = reactor.run(response.body_mut().into_future()).unwrap();
    println!("CHECK: got chunk {:?}", maybe_chunk);
}

I believe this is from a bug in hyper. hyper master recently merged some fixes with handling bodies for messages that are defined as not allowed to have messages. That'd include a response for a HEAD that otherwise sends a Content-Length header.

Fix confirmed. I built and ran my example against the master branches of reqwest, hyper, and hyper-tls, and the process correctly printed the final “got chunk” message and exited.


Recent Screen shows flickering and black screen

Steps to reproduce:

Create a new flutter app - I created the basic one from Android Studio, without any modification
Execute "flutter run --release"
App Launches on Mobile
Go to Recent Screen

Expected Behaviour:

The App Goes into a preview mode with the standard animation

Actual Behaviour:

There is a weird flicker
There is some animation near the status bar
Preview shows "Black"

Device Details:
Mi A1 - Android Version 9 - [scr.zip](Screen Recording)

Other native apps work fine

@0n4li does this behavior occur running the app directly from terminal (instead of Android Studio)?
https://github.com/flutter/flutter/issues/64414#issuecomment-679105289

@0n4li does this behavior occur running the app directly from terminal (instead of Android Studio)?
#64414 (comment)

Yes. Irrespective of Android Studio. In fact I see this issue with other flutter apps which I downloaded from Google Play Store.
Native apps work fine. Only seeing this with Flutter Apps.

Hi @0n4li,
I created a new app, ran flutter run --release on Android device 8.1.0 and switched to recent apps and saw no issues.

I am latest stable (1.20.4).
Can you provide flutter doctor -v and also if you could try the same on other device / emulator to see if you still see same behavior.
Thanks.

Hi @0n4li,
I created a new app, ran flutter run --release on Android device 8.1.0 and switched to recent apps and saw no issues.

I am latest stable (1.20.4).
Can you provide flutter doctor -v and also if you could try the same on other device / emulator to see if you still see same behavior.
Thanks.

Like I said, the behavior is not specific to the app i created.
It happens with any other Flutter App that I download from Play Store.
I tried a to install a few apps mentioned here: https://www.thedroidsonroids.com/blog/apps-made-with-flutter
Mine is an Mi A1 - An Android One phone. Currently I do not have any other device to try it.

@0n4li
I installed couple of app from the link you mentioned above and didn't see the black screen or flickering issue.
Can you try the same on an emulator and see ?
Thanks

@0n4li
I installed couple of app from the link you mentioned above and didn't see the black screen or flickering issue.
Can you try the same on an emulator and see ?
Thanks

I understand that it could be device specific.
But my phone is Android One phone. Mi A1.

Since I don't have the specific device to replicate the issue and the issue isn't replicable on the devices I tried, I am keeping this issue open for further analysis.

Hi @0n4li I found a workaround for this issue in my apps.
@darshankawar closed my issue for duplication, so i posted the content here in order to help to find a fix.
I had the same problem in a couple of Motorola devices,
I can avoid it adding a little delay into onResume() callback override into the MainActivity:
 //Workaround to avoid error with screenshot in the task manager
    override fun onPause() {
        Thread.sleep(100)
        super.onPause()
    }

I hope this detail can help in found a quickly and best solution.
Please see the https://github.com/flutter/flutter/issues/66288 for more detail for my issue.

Hi @0n4li I found a workaround for this issue in my apps.
@darshankawar closed my issue for duplication, so i posted the content here in order to help to find a fix.
I had the same problem in a couple of Motorola devices,
I can avoid it adding a little delay into onResume() callback override into the MainActivity:
 //Workaround to avoid error with screenshot in the task manager
    override fun onPause() {
        Thread.sleep(100)
        super.onPause()
    }

I hope this detail can help in found a quickly and best solution.
Please see the #66288 for more detail for my issue.

Ok thanks. Will try it.
Just a couple of questions:

When the Flutter App is open, clicking on Recent Screen button has an animation to take the app from full screen to thumbnail. It doesn't happen gracefully for Flutter Apps. There is a weird flicker before i see the thumbnail. You can see it here: https://github.com/flutter/flutter/files/5251630/scr.zip. Does this fix it?

Also there is some animation on the status bar. It is more prominent if we change the color of Status bar.

@CristianTorrado  I tried your solution. It fixed the thumbnail issue. No longer black screen.
However the recent screen animation is still not graceful. There is a flicker and then the app jumps directly to recent screen.
Same happens when clicking Home from the App.

I'm getting the same issue, flicker and black screen on motorola g6 plus android v9.
I did a test in 3 versions of the same basic  application (flutter, kotlin and java).
only flutter shows the issue.

I'm getting the same issue, flicker and black screen on motorola g6 plus android v9.
I did a test in 3 versions of the same basic application (flutter, kotlin and java).
only flutter shows the issue.

I believe it is an issue in so called pure Android phones. Mine is Mi A1 and Motorola is close to Android One

I have the same issue if your looks like this:

but calling
    override fun onPause() {
        Thread.sleep(100)
        super.onPause()
    }

in the MainActivity doesnt change anything

same issue on nokia 8

I had success with putting the Thread.sleep under super.onPause and increasing the timeout to 200ms (my guess about the animation time), then I get the preview and no flickering.
  protected void onPause() {
    super.onPause();
    try {
      Thread.sleep(200);
    } catch (InterruptedException e) {
      e.printStackTrace();
    }
  }

Might be related to https://github.com/flutter/flutter/issues/57541

I have the same issue on my Mi A1 with any app built with Flutter, from the Google Play Store, from command line or Android Studio in any flavour. I've tried changing the launcher just in case and it didn't help.
Anything I can run on the device to help pinpoint what is going on? Lemme know!

Hi,
My Xiaomi Mi A1 also had a strange behavior when previewing my Flutter app in the Android task manager. The preview screen was all white.
Thanks to @CristianTorrado for his workaround.
Thanks to @bjartebore for his adaptation.
I couldn't find the Java file where to place it so I used the following Kotlin file instead:
android/app/src/main/<PROJECT_SPECIFIC>/MainActivity.kt
With the following content:
package <PROJECT_SPECIFIC>

import io.flutter.embedding.android.FlutterActivity

class MainActivity: FlutterActivity() {
    protected override fun onPause() {
        super.onPause()
        try {
            java.lang.Thread.sleep(200)
        } catch (e: InterruptedException) {
            e.printStackTrace()
        }
    }
}

And it works for me. My app doesn't suffer this issue anymore.
Just like @Sergio-Mira , I'm happy to assist in testing or providing information to solve this issue on the long run.

Is this still happening on recent versions of Flutter?

Hello @zanderso ,
I commented out the lines mentioned in my previous reply.
When I open the task manager, my app preview is visible as it should.
So, I don't seem to have the problem anymore.
Here are some version details:
flutter --version
Flutter 3.0.5 • channel stable • https://github.com/flutter/flutter.git
Framework • revision f1875d570e (4 weeks ago) • 2022-07-13 11:24:16 -0700
Engine • revision e85ea0e79c
Tools • Dart 2.17.6 • DevTools 2.12.2

Cool. It sounds like this doesn't repro anymore, so I'm going to close this as presumed fixed. Please feel free to re-open this issue with repro instructions if this is actually still happening.