Azure blobs - setting AzureBlobsStorageDriver  host does not work for non-emulated requests

Summary
I'm using libcloud to connect to Azure Gov, so I need to change host in my AzureBlobsStorageDriver connection object (which uses <account>.blob.core.usgovcloudapi.net instead of the default <account>.blob.core.windows.net). This does not work - the call fails with Unexpected status code: 400.
This broke after https://issues.apache.org/jira/browse/LIBCLOUD-1033 was merged ~2 years ago.
Detailed Information
https://issues.apache.org/jira/browse/LIBCLOUD-1033 adds support for Azurite, which largely assumes libcloud users would be setting host only if using an Azure emulator. Thus, it will always set an account_prefix=key IFF a host is specified, which will break non-emulated Azure calls (see how a list containers call has a separate Request URI for Emulated calls).
A workaround for those not using emulators was proposed here, to set the key to '' (empty string). This workaround also does not work - the call also fails with Unexpected status code: 400.
After a lengthy debugging session I figured out why the proposed workaround does not work: Setting key to the empty string does not prevent account_prefix from being set (it also gets set to the empty string). Further, doing this adds an extra / to the Request URI (code here), which will cause the Azure request to fail. Setting key=None fixes this issue.
However that is not the only issue with the proposed workaround - not having a key also prevents Azure authentication from working. Therefore I had to add a driver.connection.user_id = key_variable statement after the AzureBlobsStorageDriver object was initialized to fix this.
TL;DR - my current workaround is to do this:
AzureBlobsStorageDriver(key=None, secret=<secret>, host=<storageAccount>.blob.core.usgovcloudapi.net )
driver.connection.user_id = <storageAccount>

My fix recommendation is that an emulated boolean flag parameter be added to the AzureBlobsStorageDriver initializer, which will only set the account_prefix if it's True. This should also allow the key parameter to be set with the host.
OS: Mac OS
Python version: 3.6.8
Libcloud version: 3.3.1

Thanks for reporting this.
@c-w Any chance you will be able to look at this in the near future?

Thanks for reporting this.
@c-w Any chance you will be able to look at this in the near future?

@Kami Yes, happy to look into it.

@Kami Yes, happy to look into it.

@mkcello96 I have a patch for this but I don't currently have access to an Azure Government subscription to verify the fix end-to-end. Could you instantiate the driver at version 505894fa as shown below and let me know if your issue is resolved? Thanks in advance!
from libcloud.storage.types import Provider
from libcloud.storage.providers import get_driver

cls = get_driver(Provider.AZURE_BLOBS)

driver = cls(key='your storage account name',
             secret='your access key',
             host='blob.core.usgovcloudapi.net')

Hey @c-w thanks so much for putting a fix in for this. I'm getting this error now:
Traceback (most recent call last):   File "<stdin>", line 1, in <module>   File "/Users/mkersh/Documents/libcloud/libcloud/storage/drivers/azure_blobs.py", line 221, in __init__     port=port, **kwargs)   File "/Users/mkersh/Documents/libcloud/libcloud/common/base.py", line 1008, in __init__     self.connection = self.connectionCls(*args, **conn_kwargs)   File "/Users/mkersh/Documents/libcloud/libcloud/storage/drivers/azure_blobs.py", line 191, in __init__     super(AzureBlobsConnection, self).__init__(*args, **kwargs) TypeError: __init__() got multiple values for argument 'host'
I confirmed this was on the locally-built branch:
python3 -c "import libcloud;  print(libcloud.__version__)" 3.3.2-dev

Thanks @mkcello96. This should be resolved as of b16eb28.

Working for me now @c-w,  thanks!


Enforce python version 3.5 and above

Signed-off-by: Dan Yeaw<EMAIL_ADDRESS>

Beekeeper already has python_requires, closing PR.


[RFC] runtime environment lineage metadata

At SPI, when spawn is launching an application and creates an spfs runtime, it attempts to find the least-nested spawn process to use to fork a new process. In effect it is trying to clone from a process that has not been changed by whatever spfs activation scripts that may have executed in the current runtime. However, it is fairly common for a spawn-launched application to exec such that the spawn process is gone and can't be used to fork additional processes later. In this case, the nested spfs runtime inherits the environment from the current process rather than some parent.
As we are planning to add spawn-like functionality to spfs/spk, we'll need something in spfs to approximate the behavior of spawn, and there's an opportunity to redesign the mechanism to address the shortcomings of how it works in spawn.
The first part of the proposal is to add environment capturing into an spfs runtime when a runtime is created. This would likely use the new layer annotation mechanism to store the data. The goal is to save the state of all the environment variables at the point when an spfs runtime is created, before any changes are applied to the environment.
The second part is tracking the lineage of nested runtimes, e.g., using spfs run ... from inside an spfs runtime. In addition to capturing the environment, a reference to the parent runtime's environment will also be captured.
The net effect is to make it possible that, given any runtime id, it would be possible to look up the environment that created that runtime, or find its parent environment, recursively, all the way up to the original "pristine" environment. This mimics how spawn walks the process tree to find the outermost parent spawn process, but it doesn't depend on those processes still existing.
When launching a child runtime, it would be possible to inherit the environment variables from the "pristine" environment, whether or not that process still exists. It would also be possible to make this behavior optional. There are some situations where it is desirable to run a command that is spawn wrapped but still retain the environment variables set in the current process. Currently with spawn, it is unpredictable if this will happen or not.

From the meeting today:

are there security concerns with making all runtime environments accessible via spfs commands?

could we encrypt this data and control access only to child environments? Is that secure enough?

should probably maintain the same restrictions as the /proc/<pid>/environ

possibly easier to allow spfs to set and respect file permissions in the repo, to enable this kind of ACL where the data is limited access to its related runtime processes.

We would need to also use a platform+layer approach to create a tagged chain of these if we want to maintain traceability to parent environments
Alternatively, the monitor could hold this information in memory and be willing to provide it to the processes within the appropriate namespace - via an appropriately accessible socket or something like that


No matching distribution found during installation suing dockerfile

Please make sure that this is a build/installation issue. As per our GitHub Policy, we only address code/doc bugs, performance issues, feature requests and build/installation issues on GitHub. tag:build_template
System information

OS Platform and Distribution : Ubuntu 18.04 (Docker)
TensorFlow installed from (source or binary): binary
TensorFlow version:1.12
Python version:2.7
Installed using virtualenv? pip? conda?: virtualenv

Describe the problem
Hi, i am building this data analytics project in which i need to use tensorflow using dockerfile running on raspberry pi 4 python 2.7. I did not encounter this issue when i was running the dockerfile in amd64 architecture however in raspberry pi 4 python 2.7 it gives out error no matching distribution found for this platform. P

lease do help me figure this out. Thank you in advance.
Provide the exact sequence of commands / steps that you executed before running into the problem
RUN pip install --no-cache-dir pandas sklearn keras tensorflow
&& apt-get autoremove -y
&& apt-get clean
&& rm -rf /var/lib/apt/lists/*
Any other info / logs
Include any logs or source code that would be helpful to diagnose the problem. If including tracebacks, please include the full traceback. Large logs and files should be attached.

@abby-93
We see that you are using 1.x and there is no support for it, please upgrade to 2.x and let us know, please refer to these requirements and let us know.

HI, i am still new to this but I have tried the above mentioned instructions and i am still getting the error. Is it because i am trying to install it in raspberry pi?

HI, i am still new to this but I have tried the above mentioned instructions and i am still getting the error. Is it because i am trying to install it in raspberry pi?

@abby-93
Please confirm if you are using 2.x version.

@abby-93
Please confirm if you are using 2.x version.


Avoided isinstance(…, Variable) calls in FilterExpression.resolve().

Micro-optimisation proof-of-concept.
By determining the variable type within __init__() instead of resolve() we can skip an isinstance() check at template runtime; templates are executed in production more often than the parse trees themselves, assuming the cached Loader is used. Looks to save roughly 30ns per invocation, which isn't much to write home about, I grant you.
Python 3.9.5 (default, Jun  3 2021, 11:29:17)
IPython 7.29.0

In [1]: class Variable:
   ...:     x = 1

In [2]: x = Variable()
In [3]: %timeit if isinstance(x, Variable): pass
56.7 ns ± 0.335 ns per loop (mean ± std. dev. of 7 runs, 10000000 loops each)

In [4]: x = 1
In [5]: %timeit if x: pass
18.9 ns ± 0.352 ns per loop (mean ± std. dev. of 7 runs, 10000000 loops each)

In [6]: class Old:
   ...:     def __init__(self, var):
   ...:         self.var = var
   ...:     def resolve(self):
   ...:         return True if isinstance(self.var, Variable) else False

In [7]: class New:
   ...:     def __init__(self, var):
   ...:         self.var = var
   ...:         self.is_var = isinstance(self.var, Variable)
   ...:     def resolve(self):
   ...:         return True if self.is_var else False

In [8]: old = Old(Variable())
In [9]: new = New(Variable())

In [10]: %timeit old.resolve()
136 ns ± 0.831 ns per loop (mean ± std. dev. of 7 runs, 10000000 loops each)

In [11]: %timeit new.resolve()
104 ns ± 0.837 ns per loop (mean ± std. dev. of 7 runs, 10000000 loops each)

Didn't expect to have to change a separate template tag TranslateNode to get the tests to pass locally, so let's see if anything else comes up in CI that would make it more invasive and less worthwhile.

@kezabelle Thanks :+1:


NFTForwarding Contract + Introduce JS Test Suite

Introduces NFTForwarding contract containing an NFTForwarding resource implementing NonFungibleToken.Receiver which allows forwarding of deposited NFTs to a designated recipient's NonFungibleToken.CollectionPublic. PR closes issue https://github.com/onflow/flow-nft/issues/10
In addition to the introduction of NFTForwarding account, this PR also includes a JavaScript test suite leveraging flow-js-testing. Tests are found in lib/js/test, adopting the existing directory structure found in lib/go with test helper methods and const values found in lib/js/templates.
Tests associated with this contract demanded new transactions to cover all test cases. These new transactions include:

create_forwarder.cdc - creates NFTForwarder resource with passed Address as recipient
transer_nft_to_receiver.cdc - similar to transfer_nft.cdc, but deposits NFT to NonFungibleToken.Receiver instead of NonFungibleToken.CollectionPublic
unlink_collection.cdc - unlinks the signer's ExampleNFT.ExampleNFTCollectionPublic from ExampleNFT.CollectionPublicPath
unlink_forwarder_link_collection.cdc - unlinks the signer's NFTForwarder in public storage and link's the signer's ExampleNFT.ExampleNFTCollectionPublic, replacing the public forwarding capability with a collection capability.

To support JS testing suite, GitHub CI workflow was amended to include node and Flow CLI dependency setup. These changes were largely modeled on the ci workflow outline found in the onflow/flow-ft repo .

In my most recent commit, I changed the directory structure so that all cadence code is contained in the cadence directory. This results in the following structure:
package-root
|-cadence
  |-contracts
  |-scripts
  |-transactions
|-docs
|-lib
  |-go
    |-...
  |-js
    |-...

I found that having cadence code spread among two different sub root directories made leveraging flow-js-testing methods like sendTransaction() and executeScript difficult.
While the js test suite can work as shown in previous commits, defining script and transaction paths when flow-js-testing allows for named script and transaction reference felt like it was working against the framework.


Too much wasted vertical space on the new character sheet

The new character sheet looks great, but there is far too much wasted space on the header at the top.  Nearly 20% of the sheet is taken up by the header.

on a 1080p monitor, the character sheet's default height is the full foundry display, obscuring the scene navigation and macro hotbar. Specifically as a GM, i feel this makes running things difficult, as I often have more than one sheet open and need to be able to reach the macro hotbar as well. Yes, I can resize the sheets, but before their default height left plenty of space to save me that work.
I feel this probably feels much more functional on larger/higher resolution displays, but that the standard size (especially for laptops) is still 1080p.

Yes, I can resize the sheets, but before their default height left plenty of space to save me that work.

We could consider some logic to spawn the sheet at a different default size depending on the clientHeight available.

The new character sheet looks great, but there is far too much wasted space on the header at the top. Nearly 20% of the sheet is taken up by the header.

The header is a candidate to reclaim some vertical space potentially, but it would require some additional design work. I do not see much wasted vertical space in the screenshot above, for example.

I do not see much wasted vertical space in the screenshot above, for example.
I disagree...

The font size of the character name is far too large, causing it to wrap onto a new line
The circle around the character level bloats the right hand section vertically
Look at the large area of red between "Tiefling" and the buttons on the right.  It's all wasted space.

The circle around the character level bloats the right hand section vertically

How about if you move the level number to the right of both the rest buttons and the experience tracker (rather than being on top of the experience tracker).  The XP tracker could be made shorter if you're worried about it pushing too far to the left.
Also, if XP tracking is diabled, the header could shink slightly.

Maybe the XP tracker could instead be radial and circle around the current level, and show xp values on hover?

Look at the large area of red between "Tiefling" and the buttons on the right.  It's all wasted space.

I said vertical space. The horizontal space does indeed look wasted, but only because of the wrapping of the name. That space is otherwise available to support a reasonably large name without wrapping.

I disagree...

It's fine to disagree, but you are simply voicing a personal preference. We obviously cannot change the design to suit everyone's individual preferences. That is what modules are for and why we offer the ability to use an alternative sheet entirely.

Maybe the XP tracker could instead be radial and circle around the current level, and show xp values on hover? (although this does complicate how to manually add exp/where that field should go) Real quick mockup

Quite like this, not a bad idea. I think there are still potentially some kinks to work out around editing and if we ever wanted a level up indicator. But not insurmountable.

I said vertical space. The horizontal space does indeed look wasted, but only because of the wrapping of the name. That space is otherwise available to support a reasonably large name without wrapping.

It's still wasted space regardless of whether it's horizontal or vertical.  Making better use of the horizontal space will help reduce the vertical space.  Reducing the front size of the name will help prevent this space from being wasted.

I disagree...

It's fine to disagree, but you are simply voicing a personal preference. We obviously cannot iate change the design to suit everyone's individual preferences. That is what modules are for and why we offer the ability to use an alternative sheet entirely.

Sorry, I appreciate this may have come across badly.  I don't mean to say my opinion is more valid than anyone else's.  I do think it's valid to have a discussion to try and improve the sheet though.  As I said in my initial report, I think the new sheet looks great, and a lot of hard work has gone into it.  I just think with a few tweaks it can be made even better.

We could consider some logic to spawn the sheet at a different default size depending on the clientHeight available.

I like this idea, though the user-dragged app window size seems to persist in more situations than the legacy sheet (after f5, for instance), which means its less overall work than I thought. Overall I still feel the lack of at-a-glance functionality vs the legacy sheet on a smaller display, but that's maybe outside the scope of this issue.

Even on a larger monitor the sheet takes up a significant portion of the screen. I don't mind the size though. I'm willing to trade some space for the much much nicer look. I do miss the ability to open up the character sheet in a new window though.  My typical flow as a player character was to open up my character sheet in a new window so i could see the whole board and move the player sheet to the side or a different monitor.

From a rough estimate (taking screenshots and comparing the resolution), it is about 11% wider and 47% taller than the old sheet. The width I can deal with but the height is just too much. I'm not a fan of the idea of having to resize the windows for the reason that I didn't have to before. All the information on the legacy sheets was visible in a much smaller window.
Now don't get me wrong, I LOVE how they look. It's just the hit to how they function in an active game that is making it hard for me to want to fully switch to them. Juggling 4 or so sheets was possible before but not anymore. I'm constantly finding myself having to fully close the 1 sheet I have open to see anything going on in the canvas, just to re-open the same sheet to finish what I was doing.
I'm no good when it comes to UI design, but maybe something closer to how PF2E does it might be a good place to look? Even doing things like putting the skills in a seperate tab might be helpful to reduce the bulk of things on the details tab, allowing it to be smaller. I feel like why PF2E can get away with a beautiful sheet in a small form factor is because of it's heavy uses of tabs.


New Extension: Monzo

Description
An extension to view info about Monzo accounts, spending, and to transfer money between accounts owned by the user.
Checklist

[x] I read the extension guidelines
[x] I read the documentation about publishing
[x] I ran npm run build and tested this distribution build in Raycast
[x] I checked that files in the assets folder are used by the extension itself
[x] I checked that assets used by the README are placed outside of the metadata folder

This seems a bit sensible regarding the auth. Would it be possible for us (Raycast) to deploy the proxy?

@mathieudutour You're welcome to host it, but it's somewhat non-standard in order to support not being specific to one client ID/secret. I'm not sure how useful it is more generally.
I'm not concerned about running it for the foreseeable future, it's on a free plan on Fly. If you'd rather host it it for security reasons then feel free, the proxy is available here: https://github.com/danpalmer/oauth-pkce-proxy.

Ah I see that you didn't use https://github.com/mathieudutour/pkce-proxy. The issue with using your proxy is that there is no way to tell what you are actually going to deploy there - and we are dealing with banking data here...

@mathieudutour I agree it's sensitive, and if you'd like to deploy it please be my guest, I didn't think it would be an option. I'm not going to say there's no risk here, but there are a few factors that I believe greatly reduce the risk here:

The proxy is not used for token refreshes. This means it only sees sensitive data on the initial auth, and isn't involved ongoing.
The Monzo API is largely read-only, and "writes" are limited to moving money between accounts owned by the user. Banking data is sensitive, but there is no direct financial risk exposed.
Clients/secrets are scoped to a single account. While this is the cause of needing this proxy, it also limits the scope of attacks possible with data from this proxy.

I can think of a few things we could do here...

Raycast could host the proxy.
(and/or) We (Raycast and myself) could agree on some disclaimer/warning to put on the extension that aims to be super clear about the risks.

More generally, a "use at your own risk" style flag on extensions might be a good thing for those that are both sensitive and dangerous, such as this. I'm sure there are other Raycast extensions like this given their broad access to user data.
Related, some sort of Privacy Policy mechanism, with review, might be good for extensions.

We could decide this extension is not worth the risk. This would be disappointing to me personally, but I could understand the reason.

An explicit decision would be better than this being drawn out for ages.
If this is the direction taken, it would be good to expand the docs to suggest use-cases that will not be allowed, to save developers time in the future.
I think this raises questions about distribution outside of the curated Raycast store.

Apologies for the delay on this. After testing this all seems to work fine. I've also updated the copy on the README to reflect the new state of things. I think it's important to acknowledge the Raycast proxy, and to not provide any guarantees, so I've written a first pass at something that I'm happy with, but it would be great for someone from Raycast to explicitly OK this wording, or provide an alternative that you're happy with.

@mathieudutour Great idea, thanks for your help on this!


Operand::is_rh_register()

actually, I'll just use the type.  I thought there might be multiple for ah/rh, but that's not the case.


startDeviceScan() timeout

When starting device scan I'm targetting a specific device. There is an option for timeout this function if after a while nothing is scanned? If not, there is a workaround?
Thanks

@alfacommunication-alessandro there is no timeout option for scanning. You can just create timeout by yourself in js and call stopDeviceScan after it

Yes, I did it. Thanks


Page breaks

Hey I'm looking to force a page breaks for printing in the excel sheet, is there a way to do that with js-xlsx?

Same thing here, anyone ?

Anyone please?

Page breaks and general print settings are a feature of our Pro builds.  It may be added here at some point.


only autofocus field when not touching

when opening add plugin modal it autofocuses the search field which is very useful on desktop but painful on touch devices because it brings up a keyboard
this attempts to fix it for most touch devices

LGTM

Coverage remained the same at 90.131% when pulling 3746e0694484cc91bf7fa857186ebec7aae686a0 on FinalAngel:feature/no-keyboard-add-plugin into 47104e1a4dd26deed01a229fd3cdfa7440f4e7e6 on divio:develop.

Coverage remained the same at 90.131% when pulling 3746e0694484cc91bf7fa857186ebec7aae686a0 on FinalAngel:feature/no-keyboard-add-plugin into 47104e1a4dd26deed01a229fd3cdfa7440f4e7e6 on divio:develop.


[FLINK-29128][Connectors/Kafka] Add a new situation for split changes handling result.

What is the purpose of the change
Fix the bug relative to FLINK-29128.
Add a new situation for split changes handling result to avoid the IllegalStateException which is thrown by the kafka consumer api(function: consumer.position).
Brief change log

Get the kafka consumer's assignment first, the topic partition set.
Get starting offset by the consumer if the assigned topic partition set contains the specific topic partition.
Otherwise leave information for the new situation, since this partition has been finished and unassigned.

Verifying this change
This change is already covered by existing tests, such as KafkaPartitionSplitReaderTest#testAssignEmptySplit, but the log level must set to debug.
Does this pull request potentially affect one of the following parts:

Dependencies (does it add or upgrade a dependency): (no)
The public API, i.e., is any changed class annotated with @Public(Evolving): (no)
The serializers: (no)
The runtime per-record code paths (performance sensitive): (no)
Anything that affects deployment or recovery: JobManager (and its components), Checkpointing, Kubernetes/Yarn, ZooKeeper: (no)
The S3 file system connector: (no)

Documentation

Does this pull request introduce a new feature? (no)
If yes, how is the feature documented? (not documented)

Please add a unit test, let's discuss more about how to solve this correctly in the JIRA ticket

I have just replied you in the JIRA ticket.Please check if it makes sense.
For the test case, the logger level is set to OFF in the flink-connectors/flink-connector-kafka/src/test/resources/log4j2-test.properties. If I set it to debug, will it lead to a unexpected effect?
I wonder if these is another way to test this bug since it only work when LOG.isDebugEnabled().
I have run this changes local, it works well.

I had just refresh the review request, and PatrickRen is removed accidently, please add him back.

@leozhangsr The Flink Kafka connector resides in it's own repository, if this code change is still relevant, please open the PR in https://github.com/apache/flink-connector-kafka


Assign from a pool of EIP

I'd like to be able to grab an IP from a pool of IPs. For now this in userdata does the trick for me, but this seems like useful thing for this script to support.
ALLOCATION_ID=`aws ec2 describe-addresses --filters="Name=tag:Name,Values=mail" | jq -r '.Addresses[] | "\(.InstanceId) \(.AllocationId)"' | grep null | awk '{print $2}' | xargs shuf -n1 -e`

if [ ! -z $ALLOCATION_ID ]; then
  aws ec2 associate-address --instance-id $INSTANCE_ID --allocation-id $ALLOCATION_ID --allow-reassociation
fi

Is what you want to do to get a pool of IPs based on some filter? Currently the script only allows for a pool/list of IPs to be entered on the command line.
What I have done is to populate the command line argument dynamically using CloudFormation. But that of course requires you to use CloudFormation.


fix #77 (bfinger bugs that aggregation value does not repaired when right node borrow from Left Spine node during rebalanceAfterEvict)

fix #77

Thank you for the PR! It looks good!


nixos-rebuild switch exit code shouldn't be 0 when /boot/ is lacking space

Describe the bug
nixos-rebuild switch doesn't report an error in the case of a lack of disk space on /boot
This is slightly related to #23926
Steps To Reproduce
fill /boot to reproduce the use case
[root@x1:/var/bento]# dd if=/dev/zero of=/boot/foobar bs=10M

nixos-rebuild is reporting an issue on /boot but the exit code is 0 while it failed to achieve its task.
[root@x1:/var/bento]# nixos-rebuild switch --flake .#bento-machine
warning: Git tree '/var/bento' is dirty
building the system configuration...
warning: Git tree '/var/bento' is dirty
ignoring default profile in the list of boot entries because of the following error:
[Errno 28] No space left on device
activating the configuration...
setting up /etc...
reloading user units for solene...
setting up tmpfiles

[root@x1:/var/bento]# echo $?
0

Clean /boot/foobar to restore your system
[root@x1:/var/bento]# rm /boot/foobar

Expected behavior
nixos-rebuild exit code shouldn't be 0
Metadata
Please run nix-shell -p nix-info --run "nix-info -m" and paste the result.
 - system: `"x86_64-linux"`
 - host os: `Linux 5.19.2, NixOS, 22.11 (Raccoon), 22.11.20220901.2da64a8`
 - multi-user?: `yes`
 - sandbox: `yes`
 - version: `nix-env (Nix) 2.11.0`
 - nixpkgs: `/nix/var/nix/profiles/per-user/root/channels/nixos`

totally agree

This issue has been mentioned on NixOS Discourse. There might be relevant details there:
https://discourse.nixos.org/t/introducing-bento-a-nixos-deployment-framework/21446/20

This issue has been mentioned on NixOS Discourse. There might be relevant details there:
https://discourse.nixos.org/t/nginx-works-but-doesnt-start-after-reboot/22210/3


No iconfont in mix?

Just wondering if there is plans to implement an svg -> iconfont plugin.
I found a webpack plugin called webfont, however didn't have much luck installing with laravel mix.

Now this is pretty vague. You can pretty much do everything you can with webpack already - just pass in the webpack configuration for your included loader.
When you show off what you tried we may be able to point your way! 👍


Adds AutocompleteTags and corresponding REST api

This adds an optional storage interface AutocompleteTags to the
StorageComponent and corresponding endpoints to support the UI.
/api/v2/autocompleteKeys and /api/v2/autocompleteValues?key=http.host
Cache control is always set on the keys, and it is set conditionally on values when there are more than 3. The "more than 3" allows for a freshly booting system to not confuse users (we do the same thing on /api/v2/spans?serviceName=foo endpoint).
The server accepts an environment variable AUTOCOMPLETE_KEYS
which acts as a whitelist as storing values for every tag would be
expensive.

@tacigar @zeagord @shakuzen PTAL I suspect we can merge this on green

Sure. I think so too.


daemon: Enable device auto detection for host-fw when BPF NodePort is disabled

This PR:

Restructures initKubeProxyReplacementOptions(), and splits it into two helpers.
Enables device auto detection for host-fw.
Fixes direct routing iface in the DSR check.

Reviewable per commit.

test-me-please

@brb Smoke test failed :wink: (and took 40min to report because of #11976).

Coverage increased (+0.02%) to 37.056% when pulling c0ea924bc5f5533e9c2bc6020deaefec5cea68a9 on pr/brb/autodev-hostfw into 8aade7de709d5e30c6bc5dc247c934717ec4da20 on master.

test-me-please

test-me-please

@brb Smoke test failed again :-)

@brb Smoke test failed again :-)

It was failing due to missing operator image. I've rebased against the master, let's see whether it has been fixed.

test-me-please

test-me-please

LGTM with two small nits. Feel free to ignore or defer to follow-up.

@tklauser I've added those two to my TODO list (CI passed, don't want to re-run).


softether in openwrt interface！need help?

I tried softether on the openwrt system, but it was complicated to set up sotether. I spent more than 10 hours on each setup. I hope to compile the latest version on the router. Who can write a tutorial on how to compile openwrt's softether interface?

The package is called 'softethervpn5' and is in openwrt snapshots or the 19.07-rc1/master branches. You can also try use my package-builder to try compile it for 18.06, since i wont backport it there.
I followed this setup from there back than and since the config is preserved between openwrt upgrades i never had to touch it again.

I have a problem in most of openwrt. The tap fails to run and cannot be deleted. May I ask if the operating environment is missing in openwrt?

You need to be more specific, what does not work and what did you try, Did your follow the setup i linked and at what step you got a problem?

I don't want to compile it myself. I just want to use the bridge in openwrt. The router model is: newifi3 d2. Can I help compile a bridge running on openwrt? I don't need other functions, I just want to run softether bride in newifi3 d2

It took me 12 hours to try all the firmware compiled for the newifi 3 d2 router. When the softether bridge was installed, the tap could not be turned on, and I haven't got it yet.

@Andy2244, fyi @metalefty did some packaging improvements
https://github.com/SoftEtherVPN/SoftEtherVPN/pull/1047
it allows to perform packaging in more intelligent way

@chipitsine ah nice, will use it for your next release

I solved this problem in the latest version of openwrt19.07.0-rc1. It took 7 days. Of course, I also read your article. The core problem is that the kernel is too low to support. Another problem is that the official access of Openwrt is really Too slow, I am going to make an openwrt image for access to China right away. It takes too much time to solve this problem, mainly because of the dependency of softether on the environment of openwrt. It is difficult to solve, mainly because China-openwrt is too slow, as slow as snails, but at present, there are more openwrt users in China than in the world. I think openwrt needs to do something in Asia Efforts, otherwise execute a command: opkg update takes half an hour, and then all kinds of errors, compile time, it is very inconvenient. In addition, you said that your focus is on wireguard, which has been successfully identified and blocked in China at present Just because of the Chinese video tutorial on youtube! If a software has no way to solve its own feature code, and it is not safe for itself, how to ensure the safety of users, this is why I have been using softether

Back to the question itself: The basic environment of softether installation is not supported in the default environment of openwrt: opkg install zlib libpthread librt libreadline libncurses libiconv-full kmod-tun libopenssl. Such a command cannot assemble the softether installation environment at all. My suggestion is this: Environment detection in softether5 and bundle installation environment command:
cd / tmp / && wget XXXX / zlib.IPK
Installation kit
opkg install zlib.IPK
Then softvpn5 can be successfully installed and used normally
As for the following command:
opkg update
opkg install zlib libpthread librt libreadline libncurses libiconv-full kmod-tun libopenssl
I just smiled and did n’t talk, anyway, in China, do n’t expect success, I ’m not sure about other countries
No matter whether it is SOFTETHER version 4.29 or softether version 5.0 or above, no one cares about solving this problem, so the official openwrt version takes into account the perfect network speed, perfect various support, the imagination is beautiful, the reality is cruel

The package is called 'softethervpn5' and is in openwrt the 19.07-rc1 ,
I tested this version. When the router restarts, the server information will not be saved, it will be restored to the default state which is <IP_ADDRESS>, and other information is empty.

I checked the startup document /init.d/ and tried to modify but failed. When OPENWRT restarted, vpnserver.config was not called properly

opkg install zlib libpthread librt libreadline libncurses libiconv-full kmod-tun libopenssl

On 19.07/snapshots all you should need is:
opkg install softethervpn5-server or opkg install softethervpn5-bridge

When the router restarts, the server information will not be saved, it will be restored to the default state which is <IP_ADDRESS>, and other information is empty.

Ok, i could reproduce this bug, seems atm the server_config is only written correctly if you manually stop the service via luci/system/startup or shell /etc/init.d/softethervpnserver stop.
Then you can check the save in the system-log, aka:
daemon.notice softethervpn-server[5491]: Writing vpn_server.config (AutoSaveConfigSpan set to < 259201 > seconds)

I checked the startup document /init.d/ and tried to modify but failed.

The init scripts should work fine, just make sure to stop the service once after you have made changes via the external server manager tool, so the changes get written to /usr/libexec/softethervpn/vpn_server.config.
PS: softethervpn has a very nvram unfriendly way of using its config and dynamic data, see my issue #575. I will try find a workaround for the next update, so sorry for the inconvenience.

Thank you for your efforts and look forward to your completion of the work of saving server information in subsequent updates! I have solved this problem perfectly! Since the solution I used was violent, it was simple and effective!

Here because the same problem, settings lost after openwrt reboot.
My current workaround. though extremely troublesome, sees to work on docker.

Use the configuration tool to set the settings
Edit config -> Export
Copy the file vpn_server.config manually to /usr/libexec/softethervpn
Restart

Here because the same problem, settings lost after openwrt reboot.
My current workaround. though extremely troublesome, sees to work on docker.

Use the configuration tool to set the settings
Edit config -> Export
Copy the file vpn_server.config manually to /usr/libexec/softethervpn
Restart

As @Andy2244 has mentioned above, if you stop the service, it will write to the config file and be preserved after a reboot. It's a lot easier than running docker on OpenWRT. Configure Softether, stop the service, then reboot.

Yeah sorry #575 is still open and i really don't want to allow letting Softether eat away the nvram write cycles quickly. Its a trade-off on openwrt, since its geared toward embedded devices mainly.


Volar Labs 2.0 doesn't work with Volar

Volar Labs v2.0.0
Vue Language Features (Volar) v1.8.27

It works with main branch.

Sure but the latest released versions of both extensions don't work with each other. It's possibly to force Volar Labs to older version but is there really no better way of handling it (on the vscode extension side, I suppose)?

Vue Language Tools v1.8.27 uses volar.js v1 but Vue Language Tools v2 uses volar.js v2. So they are not compatible with each other

I get your point but vscode is not like npm where you get to decide whether to upgrade to next major version or not. It just updates automatically and breaks thing. One thing is that it's a breaking change for the user and also it's not clear  why it broke since there is no notes or anything that say that it's not compatible with VLT 1.x. There is this message that says that it's not compatible which you can see if you make the panel width very wide but it can be missed easily.
That said, I get that it's a power user extension and maybe it's not that important that it breaks without warning but I still wanted to point it out in case there are better ways of handling it.
I don't know vscode extensions ecosystem but I though that there might be some ways for extensions to indicate compatibility with other extensions to make it more obvious that there is incompatibility and how it could be resolved. If nothing can be improved then feel free to close this issue.

Oh, got your point.

some ways for extensions to indicate compatibility with other extensions

This doesn't happen on VSCode side. https://github.com/vuejs/language-tools/commit/fc48ce6d10818bda3f86b4dd7abd3eb54c7a878a#diff-3c2b2dc57146f5d52dc996ede798d28b5e6163dcd75762900a25803398a099edL149 Volar uses its own way to indicate the compatible Volar Labs version

I suppose there are more important things to work on.


PGPainless-SOP

Hey, author of PGPainless here!
I came across your Medium article "Pretty Good Privacy (PGP) Painless encryption/decryption with Java".
First of all, thank you very much for sharing the word about PGPainless and for your kind words :)
Did you explore the SOP implementation PGPainless provides? I think this interface is even better suited for quick PGP implementations. If you did explore it, were there any reasons to opt for the core API instead?
If you give the SOP API a try, feel free to provide feedback :)

Hi
Thank you for reading my article and for the feedback, I really appreciate it.
The main reason I have chosen the core library as it provides control over the code and highly customizable. And I wanted an implementation that we know what happens to at least to some depth and the PGPainless core provided all of that.
Before choosing this implementation I have done some POCs around PGPainless-SOP and bouncy castle APIs as well.
In the future I will try to do more hands on about the SOP implementation and give my feedback, and will try to put something on paper / medium.


DocsArchive-<IP_ADDRESS>Auto archive content

Please don't merge this PR until target archive repo PR https://github.com/OPS-E2E-PPE/docs-archive-test-target_66a72177-2344-4277-ad01-3a6037a480a9/pull/1 is merged into live branch.
Auto archive content to https://github.com/opstest2/docs-archive-test-target_66a72177-2344-4277-ad01-3a6037a480a9.git

Docs Build status updates of commit 84285cb:
:x: Validation status: errors
Please follow instructions here which may help to resolve issue.

File
Status
Preview URL
Details

:x:Error

Details

[Error-GitBranchDeletedOrForcePushed] Cannot sync git repo to specified commit because branch Release_Archive_master_2021-06-01-02-38-40 has been deleted or has been force pushed

For more details, please refer to the build report.
If you see build warnings/errors with permission issues, it might be due to single sign-on (SSO) enabled on Microsoft's GitHub organizations. Please follow instructions here to re-authorize your GitHub account to Docs Build.
Note: Broken links written as relative paths are included in the above build report. For broken links written as absolute paths or external URLs, see the broken link report.
Note: Your PR may contain errors or warnings unrelated to the files you changed. This happens when external dependencies like GitHub alias, Microsoft alias, cross repo links are updated. Please use these instructions to resolve them.
For any questions, please:Try searching the docs.microsoft.com contributor guidesPost your question in the Docs support channel


Storage manager

This PR splits out the storage folder and sector management from the rest of the host, putting it in its own package. I have not finished updating the documentation, and I have not finished uncommenting all of the tests, the only test that remains is the smoke test. I uncommented most of the other tests, and did not run into any problems. All of the host tests are passing to the full extent that they were before this move happened.
Because the functions are now part of an exported external module, some of the concurrency conventions are being violated in the host (calling exported functions while under lock). I will clean that up in the coming week.
The host and storage layer are now properly separated, with an interface defining everything that needs to be happening for someone to write a separate one. Anyone looking to optimize or tweak the storage layer should have an easier time doing so, and will not threaten the other functions of the host by poking around.

expiryDate is definitely confusing.


ToolAssistanceField does not render icon for instruction 'Identify Element'

Describe the bug
The ToolAssistanceField status bar popup does not render an icon for the 'Identify Element' instruction
To Reproduce
Steps to reproduce the behavior:

Have Select tool active
Click on ToolAssistanceField in the status bar to open its dialog
Notice the cursor Icon is missing

Expected behavior

Current behavior

Desktop (please complete the applicable information):

OS: windows
Browser chrome
Version  112.0.5615.138
iTwin.js AppUI Version 4.0.0-dev.20
iTwin.js Version 3.7.0

Additional context
The nz-image span contains no <i class="icon icon-cursor" /> like it does in 3.7, I suspect it's missing because of this  code

Here's our defect: https://dev.azure.com/bentleycs/beconnect/_workitems/edit/1181017

Well it looks like all tools that use tools assistance:

Hi, I see the change that caused this issue, indeed, every tool that uses webfont will have this issue, I'll look into fixing it.

Hi, the fix for this was released minutes ago in 4.0.1.


Add Launch with AnVIL button

Feature Request
Add a Launch with AnVIL button. URL is https://anvil.terra.bio
This will follow the same rules as Terra -- this instance is behind scenes the same as Terra itself; it just has a different skin and url.
┆Issue is synchronized with this Jira Story
┆Issue Type: Story
┆Fix Versions: Dockstore 1.8
┆Sprint: Seabright Sprint 26 Abalone
┆Issue Number: DOCK-1073

Button works and properly links to Terra.


How to get all attrs on a model

Toran,
Is there a simple way to get all attrs on a simple store model? Basically, I want to evaluate the model for attrs to see if they've been populated, so for the case that the model is clean and has data, vs. clean and has no data.
So being able to call: model.attrsAll() and get back a filtered Ember object for example. Then I plan to check if the value of each attr is truthy, so I could put at computed property, like hasData or hasNoData.
Thanks

From model.js where obj is the model instance.
function attrs(obj) {
    var all = [];
    factory(obj).eachComputedProperty(function (key, meta) {
        if (meta.isAttribute) {
            all.push(key);
        }
    });
    return all;
}

@aronysidoro You could define a custom computed on your model that represents the aggregate of "all attrs" using the helper @snewcomer mentioned.
I use it in the model today so I can loop over and create a custom "isDiry" attr from it
var model = this;
var attributes = attrs(this);
attributes.forEach((attrName) => {
  defineProperty(model, attrName + "IsDirty", computed(function() {
    //do some work in here
  });
})

@snewcomer,
What is factory in this code?
function attrs(obj) {
    var all = [];
    factory(obj).eachComputedProperty(function (key, meta) {
        if (meta.isAttribute) {
            all.push(key);
        }
    });
    return all;
}

@aronysidoro:
https://github.com/toranb/ember-cli-simple-store/blob/master/addon/model.js#L13
from:
https://github.com/emberjs/ember.js/blob/ed298ced885b2f4b4435fbccb26b24b9a24bb68f/packages/ember-runtime/lib/system/core_object.js#L640


Helm deployment updates v2

Closes #11
Closes #19
This merges in the changes for Helm updates to main instead of the old k8s_upgrade branch (which the original helm_updates branch appears to be branched off of)

LGTM, this is just a recreate of the previous PR from the looks of it?

That is correct, just to merge all that into the main branch vs the private branch I accidentally created that other PR off of.


PageController.page crashes on a null check exception before it has content dimension

When accessing the page property of PageController before the controller is attached and has a valid content dimensions, it throws a TypeError for a "Null check operator used on a null value".
This appears as the wrong exception given that this assert is supposed to validate the dimension:
https://github.com/flutter/flutter/blob/master/packages/flutter/lib/src/widgets/page_view.dart#L388
Two suggested improvements:

Fix the assert above to check the actual nullable values instead of the null-checked getters minScrollExtent/maxScrollExtent (i.e.: the private member _minScrollExtent/_maxScrollExtent) or perhaps rely on hasContentDimensions.

Consider returning a null page when there is no content dimension or expose a way to check whether accessing the page is acceptable through the PageController API. At this point, it is a combination of checking:

pageController.hasClient && pageController.position.hasContentDimension && pageController.page != null

Hi @adaigle,
Can you please provide your flutter doctor -v and flutter run --verbose logs, and a minimal complete reproducible code sample to better address the issue.
Thank you

Thanks @maheshmnj, here's the info you requested:
flutter doctor -v

[✓] Flutter (Channel dev, 2.5.0-5.0.pre, on macOS 11.5.1 20G80 darwin-x64, locale en-CA)
    • Flutter version 2.5.0-5.0.pre at /Users/daiglea/homebrew/Caskroom/flutter/2.2.3/flutter
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision 0f465e5b2a (5 days ago), 2021-08-04 18:59:50 -0400
    • Engine revision a0d89b1a54
    • Dart version 2.14.0 (build 2.14.0-377.0.dev)

[✓] Android toolchain - develop for Android devices (Android SDK version 30.0.2)
    • Android SDK at /Users/daiglea/Library/Android/sdk
    • Platform android-30, build-tools 30.0.2
    • Java binary at: /Applications/Android Studio with Blaze.app/Contents/jre/jdk/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 11.0.8+10-b944.6916264)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Xcode 12.5.1, Build version 12E507
    • CocoaPods version 1.10.2

[✓] Chrome - develop for the web
    • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome

[✓] Android Studio (version 4.2)
    • Android Studio at /Applications/Android Studio with Blaze.app/Contents
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/6351-dart
    • Java version OpenJDK Runtime Environment (build 11.0.8+10-b944.6916264)

[✓] IntelliJ IDEA Community Edition (version 2020.3.4)
    • IntelliJ at /Applications/IntelliJ CE (stable).app
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/6351-dart

[✓] VS Code (version 1.58.2)
    • VS Code at /Applications/Visual Studio Code.app/Contents
    • Flutter extension version 3.25.0

[✓] Connected device (2 available)
    • Pixel 4a (mobile) • 0A211JEC216725 • android-arm64  • Android 11 (API 30)
    • Chrome (web)      • chrome         • web-javascript • Google Chrome 92.0.4515.131

• No issues found!

Minimal example

import 'package:flutter/material.dart';

void main() {
  // Notice that the error is "Unexpected null value" and not the assert message.
  FlutterError.onError = (detail) => debugPrint('FlutterError caught: ${detail.exception.toString()}');

  runApp(MaterialApp(
    home: MyList(),
   ));
}

class MyList extends StatefulWidget {
  @override
  State<MyList> createState() => _MyListState();
}

class _MyListState extends State<MyList> {
  late PageController _controller;

  @override
  void initState() {
    super.initState();
    _controller = PageController(initialPage: 1);
  }

  @override
  void dispose() {
    _controller.dispose();
    super.dispose();
  }

  @override
  Widget build(BuildContext context) =>
    PageView.builder(
      controller: _controller,
      itemCount: 3,
      itemBuilder: (context, index) => Focus(
        // Use _controller.page anywhere before the initial attachment. For example here:
        autofocus: index == _controller.page,

        // Safe access by checking hasContentDimensions beforehand:
        // autofocus: index ==
        //  (_controller.hasClients && _controller.position.hasContentDimensions
        //    ? _controller.page : _controller.initialPage),
        child: Center(
          child: Text('Delegate #$index'),
        ),
      ),
    );
}

flutter run --verbose

[  +79 ms] Syncing files to device Pixel 4a...
[   +1 ms] <- reset
[        ] Compiling dart to kernel with 0 updated files
[   +2 ms] <- recompile package:projects/main.dart 98da6b3b-5e4d-49dd-ac24-8e8ec01a75bd
[        ] <- 98da6b3b-5e4d-49dd-ac24-8e8ec01a75bd
[  +51 ms] Updating files.
[        ] DevFS: Sync finished
[        ] Syncing files to device Pixel 4a... (completed in 56ms)
[        ] Synced 0.0MB.
[   +1 ms] <- accept
[   +4 ms] Connected to _flutterView/0xb40000741f9e2750.
[   +3 ms] Flutter run key commands.
[   +1 ms] r Hot reload. 🔥🔥🔥
[        ] R Hot restart.
[        ] h List all available interactive commands.
[        ] d Detach (terminate "flutter run" but leave application running).
[        ] c Clear the screen
[        ] q Quit (terminate the application on the device).
[        ] 💪 Running with sound null safety 💪
[        ] An Observatory debugger and profiler on Pixel 4a is available at: http://<IP_ADDRESS>:50608/IwenigMWRLw=/
[+1042 ms]
                    ══╡ EXCEPTION CAUGHT BY WIDGETS LIBRARY ╞═══════════════════════════════════════════════════════════
                    The following _CastError was thrown building:
                    Null check operator used on a null value

                    When the exception was thrown, this was the stack:
                    #0      ScrollPosition.minScrollExtent (package:flutter/src/widgets/scroll_position.dart:139:49)
                    #1      _PagePosition.page (package:flutter/src/widgets/page_view.dart:388:22)
                    #2      PageController.page (package:flutter/src/widgets/page_view.dart:181:21)
                    #3      _MyListState.build.<anonymous closure> (package:projects/main.dart:39:43)
                    #4      SliverChildBuilderDelegate.build (package:flutter/src/widgets/sliver.dart:456:22)
                    #5      SliverMultiBoxAdaptorElement._build (package:flutter/src/widgets/sliver.dart:1214:28)
                    #6      SliverMultiBoxAdaptorElement.createChild.<anonymous closure> (package:flutter/src/widgets/sliver.dart:1227:55)
                    #7      BuildOwner.buildScope (package:flutter/src/widgets/framework.dart:2573:19)
                    #8      SliverMultiBoxAdaptorElement.createChild (package:flutter/src/widgets/sliver.dart:1220:12)
                    #9      RenderSliverMultiBoxAdaptor._createOrObtainChild.<anonymous closure>
(package:flutter/src/rendering/sliver_multi_box_adaptor.dart:349:23)
                    #10     RenderObject.invokeLayoutCallback.<anonymous closure> (package:flutter/src/rendering/object.dart:1968:59)
                    #11     PipelineOwner._enableMutationsToDirtySubtrees (package:flutter/src/rendering/object.dart:916:15)
                    #12     RenderObject.invokeLayoutCallback (package:flutter/src/rendering/object.dart:1968:14)
                    #13     RenderSliverMultiBoxAdaptor._createOrObtainChild (package:flutter/src/rendering/sliver_multi_box_adaptor.dart:338:5)
                    #14     RenderSliverMultiBoxAdaptor.addInitialChild (package:flutter/src/rendering/sliver_multi_box_adaptor.dart:422:5)
                    #15     RenderSliverFixedExtentBoxAdaptor.performLayout (package:flutter/src/rendering/sliver_fixed_extent_list.dart:205:12)
                    #16     RenderObject.layout (package:flutter/src/rendering/object.dart:1858:7)
                    #17     RenderSliverEdgeInsetsPadding.performLayout (package:flutter/src/rendering/sliver_padding.dart:137:12)
                    #18     _RenderSliverFractionalPadding.performLayout (package:flutter/src/widgets/sliver_fill.dart:167:11)
                    #19     RenderObject.layout (package:flutter/src/rendering/object.dart:1858:7)
                    #20     RenderViewportBase.layoutChildSequence (package:flutter/src/rendering/viewport.dart:510:13)
                    #21     RenderViewport._attemptLayout (package:flutter/src/rendering/viewport.dart:1580:12)
                    #22     RenderViewport.performLayout (package:flutter/src/rendering/viewport.dart:1489:20)
                    #23     RenderObject.layout (package:flutter/src/rendering/object.dart:1858:7)
                    #24     RenderProxyBoxMixin.performLayout (package:flutter/src/rendering/proxy_box.dart:116:14)
                    #25     RenderObject.layout (package:flutter/src/rendering/object.dart:1858:7)
                    #26     RenderProxyBoxMixin.performLayout (package:flutter/src/rendering/proxy_box.dart:116:14)
                    #27     RenderObject.layout (package:flutter/src/rendering/object.dart:1858:7)
                    #28     RenderProxyBoxMixin.performLayout (package:flutter/src/rendering/proxy_box.dart:116:14)
                    #29     RenderObject.layout (package:flutter/src/rendering/object.dart:1858:7)
                    #30     RenderProxyBoxMixin.performLayout (package:flutter/src/rendering/proxy_box.dart:116:14)
                    #31     RenderObject.layout (package:flutter/src/rendering/object.dart:1858:7)
                    #32     RenderProxyBoxMixin.performLayout (package:flutter/src/rendering/proxy_box.dart:116:14)
                    #33     RenderObject.layout (package:flutter/src/rendering/object.dart:1858:7)
                    #34     RenderProxyBoxMixin.performLayout (package:flutter/src/rendering/proxy_box.dart:116:14)
                    #35     RenderObject.layout (package:flutter/src/rendering/object.dart:1858:7)
                    #36     RenderProxyBoxMixin.performLayout (package:flutter/src/rendering/proxy_box.dart:116:14)
                    #37     RenderObject.layout (package:flutter/src/rendering/object.dart:1858:7)
                    #38     RenderProxyBoxMixin.performLayout (package:flutter/src/rendering/proxy_box.dart:116:14)
                    #39     RenderCustomPaint.performLayout (package:flutter/src/rendering/custom_paint.dart:545:11)
                    #40     RenderObject.layout (package:flutter/src/rendering/object.dart:1858:7)
                    #41     RenderProxyBoxMixin.performLayout (package:flutter/src/rendering/proxy_box.dart:116:14)
                    #42     RenderObject.layout (package:flutter/src/rendering/object.dart:1858:7)
                    #43     RenderProxyBoxMixin.performLayout (package:flutter/src/rendering/proxy_box.dart:116:14)
                    #44     RenderObject.layout (package:flutter/src/rendering/object.dart:1858:7)
                    #45     RenderProxyBoxMixin.performLayout (package:flutter/src/rendering/proxy_box.dart:116:14)
                    #46     RenderObject.layout (package:flutter/src/rendering/object.dart:1858:7)
                    #47     RenderProxyBoxMixin.performLayout (package:flutter/src/rendering/proxy_box.dart:116:14)
                    #48     RenderObject.layout (package:flutter/src/rendering/object.dart:1858:7)
                    #49     RenderProxyBoxMixin.performLayout (package:flutter/src/rendering/proxy_box.dart:116:14)
                    #50     RenderObject.layout (package:flutter/src/rendering/object.dart:1858:7)
                    #51     RenderProxyBoxMixin.performLayout (package:flutter/src/rendering/proxy_box.dart:116:14)
                    #52     RenderObject.layout (package:flutter/src/rendering/object.dart:1858:7)
                    #53     RenderProxyBoxMixin.performLayout (package:flutter/src/rendering/proxy_box.dart:116:14)
                    #54     RenderObject.layout (package:flutter/src/rendering/object.dart:1858:7)
                    #55     RenderProxyBoxMixin.performLayout (package:flutter/src/rendering/proxy_box.dart:116:14)
                    #56     RenderObject.layout (package:flutter/src/rendering/object.dart:1858:7)
                    #57     RenderProxyBoxMixin.performLayout (package:flutter/src/rendering/proxy_box.dart:116:14)
                    #58     RenderObject.layout (package:flutter/src/rendering/object.dart:1858:7)
                    #59     RenderProxyBoxMixin.performLayout (package:flutter/src/rendering/proxy_box.dart:116:14)
                    #60     RenderOffstage.performLayout (package:flutter/src/rendering/proxy_box.dart:3422:13)
                    #61     RenderObject.layout (package:flutter/src/rendering/object.dart:1858:7)
                    #62     RenderProxyBoxMixin.performLayout (package:flutter/src/rendering/proxy_box.dart:116:14)
                    #63     RenderObject.layout (package:flutter/src/rendering/object.dart:1858:7)
                    #64     _RenderTheatre.performLayout (package:flutter/src/widgets/overlay.dart:745:15)
                    #65     RenderObject.layout (package:flutter/src/rendering/object.dart:1858:7)
                    #66     RenderProxyBoxMixin.performLayout (package:flutter/src/rendering/proxy_box.dart:116:14)
                    #67     RenderObject.layout (package:flutter/src/rendering/object.dart:1858:7)
                    #68     RenderProxyBoxMixin.performLayout (package:flutter/src/rendering/proxy_box.dart:116:14)
                    #69     RenderObject.layout (package:flutter/src/rendering/object.dart:1858:7)
                    #70     RenderProxyBoxMixin.performLayout (package:flutter/src/rendering/proxy_box.dart:116:14)
                    #71     RenderObject.layout (package:flutter/src/rendering/object.dart:1858:7)
                    #72     RenderProxyBoxMixin.performLayout (package:flutter/src/rendering/proxy_box.dart:116:14)
                    #73     RenderCustomPaint.performLayout (package:flutter/src/rendering/custom_paint.dart:545:11)
                    #74     RenderObject.layout (package:flutter/src/rendering/object.dart:1858:7)
                    #75     RenderProxyBoxMixin.performLayout (package:flutter/src/rendering/proxy_box.dart:116:14)
                    #76     RenderObject.layout (package:flutter/src/rendering/object.dart:1858:7)
                    #77     RenderProxyBoxMixin.performLayout (package:flutter/src/rendering/proxy_box.dart:116:14)
                    #78     RenderObject.layout (package:flutter/src/rendering/object.dart:1858:7)
                    #79     RenderProxyBoxMixin.performLayout (package:flutter/src/rendering/proxy_box.dart:116:14)
                    #80     RenderObject.layout (package:flutter/src/rendering/object.dart:1858:7)
                    #81     RenderProxyBoxMixin.performLayout (package:flutter/src/rendering/proxy_box.dart:116:14)
                    #82     RenderObject.layout (package:flutter/src/rendering/object.dart:1858:7)
                    #83     RenderView.performLayout (package:flutter/src/rendering/view.dart:165:14)
                    #84     RenderObject._layoutWithoutResize (package:flutter/src/rendering/object.dart:1713:7)
                    #85     PipelineOwner.flushLayout (package:flutter/src/rendering/object.dart:885:18)
                    #86     RendererBinding.drawFrame (package:flutter/src/rendering/binding.dart:453:19)
                    #87     WidgetsBinding.drawFrame (package:flutter/src/widgets/binding.dart:883:13)
                    #88     RendererBinding._handlePersistentFrameCallback (package:flutter/src/rendering/binding.dart:319:5)
                    #89     SchedulerBinding._invokeFrameCallback (package:flutter/src/scheduler/binding.dart:1143:15)
                    #90     SchedulerBinding.handleDrawFrame (package:flutter/src/scheduler/binding.dart:1080:9)
                    #91     SchedulerBinding.scheduleWarmUpFrame.<anonymous closure> (package:flutter/src/scheduler/binding.dart:863:7)
                    (elided 11 frames from class _RawReceivePortImpl, class _Timer, dart:async, and dart:async-patch)
                    ════════════════════════════════════════════════════════════════════════════════════════════════════

The stacktrace above points directly to the null check running within the assert statement linked in the issue description. The evaluation of the assert crash rather than having the assert properly trigger with the correct exception type.
The proposed PR fixes this and allows calling controller.page in release and returns null while the controller is not attached.

reproducible on the latest stable and the master channel.

flutter doctor -v
[✓] Flutter (Channel stable, 2.2.3, on macOS 11.4 20F71 darwin-arm, locale en-GB)
    • Flutter version 2.2.3 at /Users/mahesh/Documents/flutter
    • Framework revision f4abaa0735 (6 weeks ago), 2021-07-01 12:46:11 -0700
    • Engine revision 241c87ad80
    • Dart version 2.13.4

[✓] Android toolchain - develop for Android devices (Android SDK version 31.0.0)
    • Android SDK at /Users/mahesh/Library/Android/sdk
    • Platform android-31, build-tools 31.0.0
    • ANDROID_HOME = /Users/mahesh/Library/Android/sdk
    • Java binary at: /Applications/Android Studio.app/Contents/jre/jdk/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 11.0.8+10-b944.6916264)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Xcode 12.5.1, Build version 12E507
    • CocoaPods version 1.10.1

[✓] Chrome - develop for the web
    • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome

[✓] Android Studio (version 4.2)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/6351-dart
    • Java version OpenJDK Runtime Environment (build 11.0.8+10-b944.6916264)

[✓] VS Code (version 1.58.0)
    • VS Code at /Applications/Visual Studio Code.app/Contents
    • Flutter extension version 3.25.0

[✓] Connected device (2 available)
    • macOS (desktop) • macos  • darwin-arm64   • macOS 11.4 20F71 darwin-arm
    • Chrome (web)    • chrome • web-javascript • Google Chrome 92.0.4515.131

• No issues found!

[✓] Flutter (Channel master, 2.5.0-6.0.pre.21, on macOS 11.4 20F71 darwin-arm, locale en-GB)
    • Flutter version 2.5.0-6.0.pre.21 at /Users/mahesh/Documents/flutter_master
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision 40e8620a27 (4 days ago), 2021-08-06 09:14:50 +0430
    • Engine revision 431ac604da
    • Dart version 2.14.0 (build 2.14.0-383.0.dev)

[✓] Android toolchain - develop for Android devices (Android SDK version 31.0.0)
    • Android SDK at /Users/mahesh/Library/Android/sdk
    • Platform android-31, build-tools 31.0.0
    • ANDROID_HOME = /Users/mahesh/Library/Android/sdk
    • Java binary at: /Applications/Android Studio.app/Contents/jre/jdk/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 11.0.8+10-b944.6916264)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Xcode 12.5.1, Build version 12E507
    • CocoaPods version 1.10.1

[✓] Chrome - develop for the web
    • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome

[✓] Android Studio (version 4.2)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/6351-dart
    • Java version OpenJDK Runtime Environment (build 11.0.8+10-b944.6916264)

[✓] VS Code (version 1.58.0)
    • VS Code at /Applications/Visual Studio Code.app/Contents
    • Flutter extension version 3.25.0

[✓] Connected device (2 available)
    • macOS (desktop) • macos  • darwin-arm64   • macOS 11.4 20F71 darwin-arm
    • Chrome (web)    • chrome • web-javascript • Google Chrome 92.0.4515.131

• No issues found!

The associated PR has landed, can this be closed?

Yes, thanks. Issue resolved.


Feature/hosted entry extra name

Can set the toolname and workflowname for hosted tools and workflows, respectively.

Edit: the dockstore.org/ is no longer present
https://github.com/ga4gh/dockstore/issues/1738

Since the repository can now be specified by the user, does this mean that I, as coverbeck, can create a hosted workflow in dockstore.org/agduncan? If so, are there any issues that arise from that, or is that OK?

Oops actually you've pointed out an issue with the UI. How it is supposed to be is for me for example the workflow is always in "dockstore.org/agduncan94".
Before you were limited to "dockstore.org/agduncan94/wfname", but now you could have "dockstore.org/agduncan94/wfname/wf1" and "dockstore.org/agduncan94/wfname/wf2".
I'll make the fixes now.

Some random thoughts:

Should the repository be optional?
What happens to hosted workflows that were already created before this change -- what repo will they be in? And can I create additional workflows in the same location, whatever that is?
It would be nice if this repository input were an editable dropdown, that way I could safely pick an existing repo without worrying about making a typo in the name.

@coverbeck
Just for some background, normal paths are A/B/C(/D), where D is optional you can add. We added this in the case where a docker image is used for multiple tools. We translated this to workflows too, in the case of duplicate git repository.
For existing hosted entries, they would not have any workflow/toolname set. This is a good point, as a migration needs to be added to add the column and set it to null. These would still be valid hosted entries, as the name portion is optional.
As for your last point, similar things have been brought up in order to improve the registration process in the future, though at this point it hasn't been anything concrete decided on.
@denis-yuen
For your point on confusion, the workflow version uses the material design guidelines, where the asterisk means required. If you click on the optional field it will also say optional. I think the confusion mostly stems from the lack of consistency between the two.
I agree that it adds complexity to the hosted workflows. I added it for completeness sake. Maybe it could be an advanced option?
I also agree that it makes more sense for hosted tools over hosted workflows.

I was referring to the repository name being required, not the workflow/tool name. The repository name looks like it is required, as it has an asterisk next to it.
Today, if I create a hosted workflow it gets created in dockstore.org/coverbeck, e.g., dockstore.org/coverbeck/myworkflow.
My initial question had been, if I can specify the repo, what would stop me from creating a workflow dockstore.org/agduncan/myworkflow. You said that the repository comes after the username part, and you were going to update the UI to indicate that.
So if I enter a repository name foo and a workflow name bar, then that means the name will be dockstore.org/coverbeck/foo/bar? I think that's fine if so, but:

Perhaps the UI could indicate that (but not crucial).
What repo will pre-existing hosted workflows be under?

I hope I'm not majorly misunderstanding things here.

@agduncan94 Ah, forgot material vs older dialogues. That makes sense
For hosted workflows, I'm not sure it should even be an advanced feature if we ourselves cannot think of a use-case. It would add unnecessary confusion I think. I wouldn't remove the functionality from the webservice, but I simply wouldn't show it in the UI2 under we get a request/use-case

@coverbeck Sorry for the confusion, the screenshot is out of date. So in reality the path for me is always dockstore.org/agduncan/repository/workflowname The only thing we can set are the latter two parts of the path (repo and workflowname). So you are correct with your foo/bar example.
As for your two points:

I agree, I think we should show the path that will be created as the used fills in the options.
Any existing hosted workflow will keep their naming. If you had an existing hosted workflow with the path dockstore.org/coverbeck/myworkflow, the repository is myworkflow. The workflowname is null. All this PR does is allow you to add the fourth path element, called workflowname, to new hosted workflows. I think part of the confusion stems from the UI previously asking for the workflow name, even though we store that as the repository in the db.

@agduncan94 Thanks, that clarified it -- you were saying the same thing before, but it finally clicked for me with your last comment.


Support for sorted queries

Two primary use cases for this are prioritized ACLs and longest prefix matching in routing

Do you need 1 output or many? For one aggregation (max) is enough.

We need one, but we also don't have support for aggregation yet.


Feat: Reduce the extra gaps

Describe the feature
I want to reduce the extra gaps from the Main cards of the Teams page
Add ScreenShots

Record

[X] I agree to follow this project's Code of Conduct
[X] I'm a GSSOC'24 contributor
[ ] I'm a VSoC'24 contributor
[X] I want to work on this issue

@Ayushmaanagarwal1211 go ahead


Configurable audio output, fixes #22

Very small change again.
You have to change your config file - let's break stuff every day!
@alexa-pi/coreteam Please test.

This is something I was going to suggest after changing sound cards on the CHIP yesterday.
I built it and ran it, and it works with the default 3.5mm jack.
I haven't tried with any other cards yet, but have a question.  How does this do different devices on the same card?
The raspberry pi has two devices under the card name ALSA.  Is the config.yaml set up for me to enter "CARD=ALSA,DEV=0"?

To be completely honest here, I don't know. All is does is that if you set sound/output_device, it passes that to --alsa-audio-device=, so anything that you would pass to aplay for example will work here.
Well, that's sure weird. What's your aplay -l and aplay -L? On other computers I've been using plughw:0 and plughw:1, but I gotta say, the ALSA device naming seems like magic to me so I always circle a few options until things start working.

@ShawnHarte Thanks, merging then!
Also, can you please someone test if you can set audio output to go through the analog, with HDMI connected on a Pi? I don't have any HDMI peripheral to test.

Yes audio can run through the analog out while HDMI is attached.  plughw:1 vs 0 works.  I have PA enabled on a pi3


Ethan: Watch kodeuniversity.com

Ethan requests the watch of the watch_keyword kodeuniversity\.com. See the MS search here and the Stack Exchange search in text, in URLs, and in code.

kodeuniversity\.com has been seen in 3 true positives, 0 false positives, and 0 NAAs.

Approved by Jeff Schaller in Charcoal HQ


Laravel 5.2 Fresh install Class log does not exist

When i try to install a Fresh Laravel 5.2 using Composer it gives me error:
Error Output: PHP Fatal error:  Uncaught ReflectionException: Class log does not exist in BLAH/vendor/laravel/framework/src/Illuminate/Container/Container.php:736
i tried removing cache, tried laravel installer or composer way, none worked.
both gives this error

Sounds like you're having an issue before we setup the log bindings. Are you file permissions.
Respectfully, I'm going to close this and ask if you could seek help on the forums, because I don't believe this to be a bug in laravel.

Thanks anyway though. ;)

Humor me Graham, can you please do me a favor and try to install a fresh laravel right now ?
i tried to install a fresh installition of laravel on my Production server with 3 already working laravel apps...
there is that error again.

I just installed a fresh laravel app and it worked just fine: https://i.starbs.net/a7yB.

Tnx man For checkup, @GrahamCampbell

Fatal error: Uncaught ReflectionException: Class log does not exist in /var/www/html/babynatura/vendor/laravel/framework/src/Illuminate/Container/Container.php:741 Stack trace: #0 /var/www/html/babynatura/vendor/laravel/framework/src/Illuminate/Container/Container.php(741): ReflectionClass->__construct('log') #1 /var/www/html/babynatura/vendor/laravel/framework/src/Illuminate/Container/Container.php(631): Illuminate\Container\Container->build('log', Array) #2 /var/www/html/babynatura/vendor/laravel/framework/src/Illuminate/Foundation/Application.php(674): Illuminate\Container\Container->make('log', Array) #3 /var/www/html/babynatura/vendor/laravel/framework/src/Illuminate/Container/Container.php(842): Illuminate\Foundation\Application->make('log') #4 /var/www/html/babynatura/vendor/laravel/framework/src/Illuminate/Container/Container.php(805): Illuminate\Container\Container->resolveClass(Object(ReflectionParameter)) #5 /var/www/html/babynatura/vendor/laravel/framework/src/Illuminate/Container/Container.php(775): Illuminat in /var/www/html/babynatura/vendor/laravel/framework/src/Illuminate/Container/Container.php on line 741

I am using laravel 5.1
I have install package and remove it then i have getting this error please help
Fatal error: Uncaught ReflectionException: Class log does not exist in /var/www/html/babynatura/vendor/laravel/framework/src/Illuminate/Container/Container.php:741 Stack trace: #0 /var/www/html/babynatura/vendor/laravel/framework/src/Illuminate/Container/Container.php(741): ReflectionClass->__construct('log') #1 /var/www/html/babynatura/vendor/laravel/framework/src/Illuminate/Container/Container.php(631): Illuminate\Container\Container->build('log', Array) #2 /var/www/html/babynatura/vendor/laravel/framework/src/Illuminate/Foundation/Application.php(674): Illuminate\Container\Container->make('log', Array) #3 /var/www/html/babynatura/vendor/laravel/framework/src/Illuminate/Container/Container.php(842): Illuminate\Foundation\Application->make('log') #4 /var/www/html/babynatura/vendor/laravel/framework/src/Illuminate/Container/Container.php(805): Illuminate\Container\Container->resolveClass(Object(ReflectionParameter)) #5 /var/www/html/babynatura/vendor/laravel/framework/src/Illuminate/Container/Container.php(775): Illuminat in /var/www/html/babynatura/vendor/laravel/framework/src/Illuminate/Container/Container.php on line 741


Add support for noCacheLookup API parameter

Brief
MythX OpenAPI has support for optional noCacheLookup parameter, which is not yet implemented in MythXJS. This PR submits it's implementation.
Changes

Added AnalyzeOptions.noCacheLookup optional boolean property.
Tweaked generateAnalysisRequest() to have noCacheLookup boolean argument with false value by default. It will be overriden if options.noCacheLookup is defined.
Tweaked tests.

Regards, @blitz-1306.

@Gtonizuka I was trying to respect style of argument passing there. Logic is aligning with toolName assignment there. You may pass it both ways. So, as it is required, then I will update.

@Gtonizuka As you remark is addressed, please consider another review. Thanks in advance.

I merged and will deploy a new version


Additional "post-false" reads needed with non-default CommandBehavior

context, investigating https://github.com/DapperLib/Dapper/issues/2077 , I put together this test, which is just using raw ADO.NET (no Dapper), using SingleResult, SingleRow and "both"; I am familiar with the problem of trailing faults in the TDS flow, hence Dapper does always read-to-end, but this test shows that extra row-reads after reader.Read() has reported false are necessary to observe the exceptions, with the number of extra Read() calls being query-dependent. The coded example needs at least 2 extra reads, but the OP has reported higher numbers by changing the SQL
Having to perform extra reads after seeing reader.Read() report false feels like a bug.
This behaviour is currently consistent between System.Data.SqlClient and Microsoft.Data.SqlClient
to be explicit, to see the exception in the example shown, we need to:

we call Read() to test for the expected row, get true
we call Read() to test for unexpected rows, get false
we call Read() again "just because", get false
we call Read() once more, boom: SqlException

it seems like this SqlException should have happened before Read() returned false at step 2, or should not have occurred at all; but needing to call Read() an arbitrary and unpredictable number of extra times is... not good.
risk: faults go unobserved, transactions get incorrectly committed, human sacrifice, dogs and cats living together, MASS HYSTERIA
simplified repro (using reader.NextResult() does not help, note):
[Fact]
public void ManualADONETSimplified()
{
    // note test shows *undesirable* outcome as "pass"
    using var conn = GetOpenConnection();
    using var cmd = conn.CreateCommand();
    cmd.CommandText = SQL;
    using var reader = cmd.ExecuteReader(CommandBehavior.SingleResult);

    Assert.True(reader.Read()); // 1. expected data
    Assert.False(reader.Read()); // 2. check for unexpected data
    Assert.False(reader.Read()); // 3. just because
    Assert.ThrowsAny<DbException>(() => reader.Read()); // 4. boom
}

// from https://github.com/DapperLib/Dapper/issues/2077
const string SQL = """
-- MOVE the 'SELECT 7;'-Statement here, to increase the required while(read()) calls by one.

BEGIN TRANSACTION
BEGIN TRY
    SELECT 7; --SELECT any value INSIDE TRANSACTION

    --FORCE Error
    DECLARE @intvar INT
    SET @intvar = 'A'
COMMIT TRANSACTION
END TRY
BEGIN CATCH
    ROLLBACK TRANSACTION
    ;THROW 50000, 'ERROR in Transaction', 1;
END CATCH
""";

I'm curious how other providers behave in this scenario. Particularly subsequent Read() calls, after Read() has returned false.
In SqlClient. if you specify CommandBehavior.SingleResult, any data after the first result set is drained and results/errors discarded/ignored. The draining happens on NextResult() or Close() of the reader. So the Read() behavior after false is a bit strange. That behavior doesn't seem well defined in the ADO.NET API and I suspect you may experience different results in different data providers. We should probably make the experience consistently return false every time. I don't think it should be advancing to subsequent results.
If you want to only return the first result of a statement but still return errors from subsequent result sets, don't use CommandBehavior.SingleResult. Read through all results and result sets and decide what to return or discard, including how to surface multiple potential errors from subsequent result sets.

There's only one result in the query shown. I think  what's particularly weird in this example is that the exception manifests if we call read some additional dummy times. If it didn't manifest at all, it would be vexing but at least comprehensible. Always manifesting the exception (i.e. taking note of faults while scanning over the trailing TDS) would IMO be preferable, of course, but "manifests if you call read an extra few times for no reason" is just... odd.

There's only one result in the query shown.

That's not entirely true. If there were zero subsequent errors, sure, the entire statement would only produce a single result. But SELECT 7; is a result in itself. There are no errors within that result set. The error thrown by SET @intvar = 'A' is separate and the server sends it as part of a subsequent result set. SqlClient will throw the error on the call to NextResult().
I do agree that the subsequent Read() behavior is strange. But applications should not continue calling Read() after a Read() returns false. So that behavior isn't high priority to fix.

I'm of course not super familiar with TDS, but here are some thoughts from the Npgsql perspective... We had a somewhat related discussion in https://github.com/npgsql/npgsql/issues/4377. The basic principle we arrived at was that Npgsql shouldn't swallow exceptions - these should be made visible to the user. One motivation for that is that there may e.g. be SQL statements that don't produce a resultset (e.g. INSERT/UPDATE, or SET as above), the user absolutely wants to be notified of failure for those cases, and DbDataReader is the API through which those exceptions can be made visible. So we decided that the least bad option here was to throw exceptions from Dispose, given that all DbDataReaders must eventually be disposed by the user (so it's a point where errors are bound to become observable).
(Yes, throwing from Dispose indeed isn't ideal, but we still thought this was the least bad option (compared to e.g. silently swallowing), plus there's ample prior art for throwing from Dispose/DisposeAsync, especially where that can cause I/O (e.g. FileStream))
From that perspective, the fact that an additional Read throws - after a prior Read returned false - doesn't necessarily seem like a huge problem to me; the main quesiton for me is whether, in that scenario, calling Dispose (and/or NextResult) instead of Read after Read return false would also throw the same exception. If so (@David-Engel you seem to indicate that yes, at least for NextResult), I'm not sure I see a big problem.
@vonzshik may have more to contribute here, plus I'd definitely be interested to hear your thoughts @David-Engel @mgravell.

From that perspective, the fact that an additional Read throws - after a prior Read returned false - doesn't necessarily seem like a huge problem to me

But how would you know to do this? Agree the key thing here is "don't swallow exceptions", so what I'm trying to get to here is:

what is the expected / normal / correct API usage that leads to getting the data and exceptions that occur?

Calling Read() an unknown / arbitrary number of random times seems an untennable usage pattern, so: what is the expected usage? From there, we can sensibly ask: "does SqlClient work correctly for that usage?"
For me, the expected usage is, roughly:
using var reader = cmd.ExecuteReader(...); // possibly async
do
{
    if (reader.Read())
    {
        // non-empty result set
        // not shown: inspect column metadata once only per grid
        do
        {
            // process the current row in the current grid using the column metadata
        }
        while (reader.Read()) // process each row in the current grid
    }
}
while (reader.NextResult()); // make sure we process each grid

This is generalized; if we don't actively expect additional grids we might do something more like:
using var reader = cmd.ExecuteReader(...); // possibly async
if (reader.Read())
{
    // non-empty result set
    // not shown: inspect column metadata once only per grid
    do
    {
        // process the current row in the current grid using the column metadata
    }
    while (reader.Read()) // process each row in the primary grid
}
// first grid has been fully consumed; blitz over remaining grids
while (reader.NextResult())
{
    while (reader.Read())
    {}
}

And with either of those; SqlClient currently risks silently missing exceptions unless we tack a random number of Read() calls after the do loop. So, I conclude either:

the above is not a correct statement of the expected use-case, in which case: what is?, or
SqlClient has an incorrect implementation

But how would you know to do this, and how many extra reads do you need?

When you're done with the reader, you just dispose it (or when you're done with a resultset, you call NextResult), and should be guaranteed to get any exceptions, no? Why would you need to do extra reads at that piont?
For the code above, the moment you get false from Read, you execute NextResult right? If that's guaranteed to throw any exceptions (I think @David-Engel is saying it is), then isn't that sufficient?

And with either of those; SqlClient currently risks silently missing exceptions unless we tack a random number of Read() calls after the do loop. So, I conclude either:

the above is not a correct statement of the expected use-case, in which case: what is?, or
SqlClient has an incorrect implementation

IMO it's quite clear that SqlClient has an incorrect implementation, at the very least concerning Read. There is absolutely no reason why Read should ever be able to go outside of the current result set, no matter how many times it's called.

For the code you pasted above, the moment you get false from Read, you execute NextResult right? If that's guaranteed to throw any exceptions (I think @David-Engel is saying it is), then isn't that sufficient?

Nope, NextResult isn't going to throw as long as CommandBehavior.SingleResult because SqlClient it just going to ignore every single error after the first result set.

IMO it's quite clear that SqlClient has an incorrect implementation, at the very least concerning Read. There is absolutely no reason why Read should ever be able to go outside of the current result set, no matter how many times it's called.

I agree (and @David-Engel also wrote that he finds this strange) - but at the same time applications shouldn't call Read() after another Read() has returned false. So yes, I do think this is something that should ideally be fixed (by Read() immediately returning false after another false-returning Read()), but it seems like a very low-value "theoretical correctness" fix.

Nope, NextResult isn't going to throw as long as CommandBehavior.SingleResult is specified because SqlClient it just going to ignore every single error after the first result set.

OK, that's what I was missing here, thanks. So yes - I agree that regardless of SingleResult/SingleRow/anything else, both NextResult() and Dispose() should always throw any errors communicated by SQL Server. This seems much more important to me than the first Read() question.

Personally I'd argue that Dispose() is a tricky one - sine you could already be exiting due to a fault, throwing in Dispose() can mask one fault with another (although looking at that another way: if two independent failures happened, I guess it isn't really correct to say either is automatically better); personally I'd be fine with it just throwing when using NextResult() to exhaust the result grids. It is a subjective one, though, and yes: several things do throw in Dispose() - WCF used to do that, and it was a constant source of pain :p
The Read() question: agree, that is not critical; I'm far more interested in the "getting the exceptions when used naturally" part of the question here. The only reason I even mentioned it was that the OP on the Dapper question observed that one "fix" was to add random Read() calls. I'm not saying this is a good thing, and yes: I agree that in a reasonable world: Read() would never jump into later grids.

Speaking of throwing from Dispose. The primary reason we added that to npgsql is because for returning clause postgres might return the value first and an error afterwards. So users were just reading the first row and immediately disposed the reader, in which case they had no idea that that particular query actually failed and there was no insert. Can't say for certain whether it's possible to repro a similar problem in SqlClient, but having to throw from Dispose any errors received from SqlServer seems much better rather than giving users an impression that there is no problem.

If we look at the example in the question: that's pretty much exactly the scenario (although the insert/update etc isn't shown) - so yes, it is definitely possible

@mgravell yeah, throwing from Dispose is indeed tricky, and indeed previous versions of Npgsql swallowed exceptions when they occured during disposal. But as @vonzshik writes, between this behavior (where the user isn't made aware) and throwing from dispose (which can cause the original exception to be masked), the former still seems like the better alternative. It's true that users can call NextResult() - or even DbDataReader.Close() to get those exceptions, at which point Dispose is guaranteed to not throw (that's probably what I'd do); but the point is that most users can't be expected to be aware of the nuances, and there's lots of code out there which just reads a row and then disposes, and we don't want exceptions to be lost for those cases.
@David-Engel I get the point about SingleResult now being suitable when there are multiple statements - though I understand this option to be about results; in other words, it could make sense to use this option with multiple statements, as long as only one of them produces a resultset. In that case, it still seems very important to surface errors from statements after the resultset-producing one.
I also wonder how things work regardless of SingleResult.. In other words, if I do a regular ExecuteReader (without SingleResult) with multiple statements, and call Dispose() immediately after reading the first row of the first resultset, am I guaranteed to see exceptions for errors from later statements?

I get the point about SingleResult now being suitable when there are multiple statements - though I understand this option to be about results; in other words, it could make sense to use this option with multiple statements, as long as only one of them produces a resultset. In that case, it still seems very important to surface errors from statements after the resultset-producing one.

@roji We've always surfaced errors in the context of result sets. I do understand and agree that it's bad to ignore errors. However, I'm very hesitant to have Dispose() throw. I think that will have a sizable impact. We've fixed issues in the past where Dispose() was throwing, counter to expected behavior/convention. The most recent one was brought to us by the SQL tools team.

I also wonder how things work regardless of SingleResult.. In other words, if I do a regular ExecuteReader (without SingleResult) with multiple statements, and call Dispose() immediately after reading the first row of the first resultset, am I guaranteed to see exceptions for errors from later statements?

No. Even without SingleResult, if you don't move on to subsequent results, SqlClient will not throw any errors. You must consume all results to see results and/or errors associated with them. This behavior is consistent across all the SQL drivers, as far as I know. It is a common question that pops up. We even called it out specifically in the JDBC docs. We get 1-2 JDBC issues a year from people who don't understand the multiple result set concept.
Here's another blog about it: The Curious Case of Undetected SQL Exceptions
Even System.Data.Odbc behaves this way. If you don't call NextResult(), you won't see the error. I do see a small behavior difference between SqlClient and Odbc, though. Using the repro T-SQL, System.Data.Odbc will throw on NextResult(), even when SingleResult is specified, whereas SqlClient won't throw if you call NextResult() when SingleResult is specified.
I think if your application might be running queries that could produce multiple results or errors that aren't directly associated with one result, you should ensure that you are reading everything appropriately. This means calling NextResult() until it returns false. The SingleResult option feels dangerous to me, in general, and I would only use it if I was sure I didn't care about anything after the first result.

This means calling NextResult() until it returns false.

The longer version of the rest (first link in the top post here) does read all the grids. The point is that this doesn't surface the exceptions. This feels unexpected. My expectation from SingleResult / SingleRow is that they optimize away row data; it feels unexpected that it also silently discards exceptions. If that is the accepted behaviour, then I must conclude that Dapper cannot ever use those hints as an optimization, even when I know from context that I'm expecting a single result grid or a single row. I can make that change, but it feels ... dirty and sad :(

@mgravell I'm not opposed to changing the way SingleResult/SingleRow behaves here. I think it might be useful for NextResult() to throw errors, while silently discarding row data. We should also consider what to do with warning/info messages in the same scenario. I haven't looked into those.

However, I'm very hesitant to have Dispose() throw. I think that will have a sizable impact. We've fixed issues in the past where Dispose() was throwing, counter to expected behavior/convention. The most recent one was brought to us by the SQL tools team.

I also wonder how things work regardless of SingleResult.. In other words, if I do a regular ExecuteReader (without SingleResult) with multiple statements, and call Dispose() immediately after reading the first row of the first resultset, am I guaranteed to see exceptions for errors from later statements?

No. Even without SingleResult, if you don't move on to subsequent results, SqlClient will not throw any errors. You must consume all results to see results and/or errors associated with them. [...]

Understood.
For what it's worth, we had this exact conversation on the Npgsql side (https://github.com/npgsql/npgsql/issues/4377), and ended up deciding the other way. In other words, there definitely are disadvantages to throwing from Dispose (e.g. masking the original exception as @mgravell mentioned). And I understand that some of your consumers (e.g. SQL tools team) may prefer not to have to deal with exceptions from Dispose. But at the end of the day, all that seems to me to be less important than the silent swallowing of exceptions, which is the current behavior for any code not explicitly calling NextResult(). It's a very tricky and undiscoverable requirement to require users to call NextResult() in this way just to get possible exceptions.
(of course, that's orthogonal to the two other issues discussed above, which are about fixing SingleResult/SingleRow specifically, and also ensure that Read() never goes beyond the current resultset).


Source for translation

Hello I translated program except some section. Would you please help me where comes from those (split and removed received ) I want to change them also but I couldnt find the source. Also bottom pagination explanation showing ...of .. rows?

These translation hooks should now be implemented in #1263
Once your translation is done please submit a PR with the translation files! :)

These translation hooks should now be implemented in #1263
Once your translation is done please submit a PR with the translation files! :)

@neco1982 did #1263 expose those translations for you?

@neco1982 did #1263 expose those translations for you?

 Are you able to submit the translation files as a pull request?

I'm going to close this issue out now - please do contribute back your translation data when you have a chance.


refactor(FieldTheory/PolynomialGaloisGroup): Make Polynomial.Gal an abbrev

This PR makes Polynomial.Gal an abbrev since p.Gal is basically just used as a shorthand for the much more unwieldy expression p.SplittingField ≃ₐ[F] p.SplittingField. This also solves the problem of having to redefine instances on Polynomial.Gal.

!bench

Looks acceptable to me.
maintainer merge

But according to the bench bot the abel ruffini file got 6.7% slower. So maybe it's better to have an actual def?

Perhaps, although I wonder whether the abel ruffini file might have something more serious going on, considering how slow it is.


integration/advent2011-day23.t fails on Rakudo Star  with 2018.04

not ok 33 - for $*ARGFILES.lines {...}
not ok 34 - for lines() {...}
in integration/advent2011-day23.t

Can you run it with t/fudgeandrun t/spec/integration/advent2011-day23.t and paste the full output that shows how the tests fail?

This is a Rakudo Star issue with running the test not related to OS. It's just not finding the test file README.md. I can reproduce on Linux.  It's just some assumption in the test of how the test is run.

This doesn't occur for me testing with a fresh Rakudo build on FreeBSD 11.1.

The test file README.md is absent from 6.c-errata (which is used by Rakudo Star) and should be added.

IMO the test should be changed to not read from README.md, just create a temp file, write some data to it and then read it. There's a make-temp-file helper routine to make that easier.