Ignore jspm_packages

There is a request on https://github.com/feross/standard/issues/467.
jspm is another package manager, it saves packages downloaded from npm or github to jspm_packages folder. It would be nice to add it to the default ignore lists.

Sorry, I'd rather not merge this. See https://github.com/feross/standard/issues/467#issuecomment-211654516 I hope you understand.

Yes, I can understand.

This is somehow strange, since standard's ignore already does some assumptions about bundle names. JSPM became quite popular, so I'd be glad if this were reviewed.

How about extracting the sane ignores? I'm willing to maintain them.
https://www.npmjs.com/package/sane-eslint-ignore
https://github.com/mightyiam/sane-eslint-ignore/blob/master/lib/index.json

@chenxsan thanks for your work on vscode-standardjs :)


Use remote plugin and removed related dependencies from package.json

Use the remote plugin feature instead of installed packages.
See https://buf.build/docs/generate/tutorial#4.-generate-code-using-remote-plugins
@AMontagu

Hi @fijemax,
you mean replacing protoc by buf ?
If this is your question / suggestion, then @AMontagu and myself are already looking into it, e.g. see here:
https://github.com/socotecio/django-socio-grpc-example/tree/main/api
@AMontagu came also up independently with a similar approach.

Hi @markdoerr ,
I am actually working with @AMontagu, I made this issue for him as so that he remember to made this evol.


Add kubevirt hyperconverged-cluster-operator (HCO) to community-operators

HCO operator repository is:
https://github.com/kubevirt/hyperconverged-cluster-operator
Signed-off-by: orenc1<EMAIL_ADDRESS>Thanks submitting your Operator. Please check below list before you create your Pull Request.
New Submissions

[x] Does your operator have nested directory structure?
[ ] Have you selected the Project Community Operator Submissions in your PR on the right-hand menu bar?
[x] Are you familiar with our contribution guidelines?
[x] Have you packaged and deployed your Operator for Operator Framework?

[x] Is your submission signed?
[x] Is operator icon set?

Updates to existing Operators

[ ] Did you create a ci.yaml file according to the update instructions?
[ ] Is your new CSV pointing to the previous version with the replaces property if you chose replaces-mode via the updateGraph property in ci.yaml?
[ ] Is your new CSV referenced in the appropriate channel defined in the package.yaml or annotations.yaml ?
[ ] Have you tested an update to your Operator when deployed via OLM?
[ ] Is your submission signed?

Your submission should not

[x] Modify more than one operator
[x] Modify an Operator you don't own
[x] Rename an operator - please remove and add with a different name instead
[x] Submit operators to both upstream-community-operators and community-operators at once
[x] Modify any files outside the above mentioned folders
[x] Contain more than one commit. Please squash your commits.

Operator Description must contain (in order)

[x] Description about the managed Application and where to find more information
[x] Features and capabilities of your Operator and how to use it
[x] Any manual steps about potential pre-requisites for using your Operator

Operator Metadata should contain

[x] Human readable name and 1-liner description about your Operator
[x] Valid category name1
[x] One of the pre-defined capability levels2
[x] Links to the maintainer, source code and documentation
[x] Example templates for all Custom Resource Definitions intended to be used
[x] A quadratic logo

Remember that you can preview your CSV here.
--
1 If you feel your Operator does not fit any of the pre-defined categories, file an issue against this repo and explain your need
2 For more information see here

/ok-to-test

/hold
will add com.redhat.openshift.versions label to specify which version (tag) of community-operators index image to publish on.

/hold cancel

/test deploy-operator-on-openshift

/hold
temporary CSV for test purposes.

/hold cancel
The PR is now updated with the actual manifests.


IN PROGRESS: Allow for sharing a version of a talk--for review, etc.

Not ready for review yet. Just starting the PR here.

Merging this in but hidden bcause I stupidly made other changes in this PR that I want elsewhere now.


Manifest parameters not working or complete

I have a version of my localized help working using the following manually created manifest:
Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: Demandware Infocenter
Bundle-SymbolicName: com.demandware.doc.help; singleton="true"
Bundle-Version: 1.0.0
Bundle-Vendor: Demandware Incorporated
Bundle-Localization: plugin

I'm trying to get the OT to produce this using the command line arguments. I'm supplying the following arguments:
	<property name="args.eclipsehelp.language" value="zh" />
	<property name="args.eclipsehelp.country" value="CN" />
	<property name="args.eclipse.provider" value="Demandware" />
	<property name="args.eclipse.version" value="1.0" />
	<property name="args.eclipse.symbolic.name" value="com.demandware.doc${doc_output}; singleton=true" />

Note: the first two properties are still documented incorrectly on source forge as using "eclipse" instead of "eclipsehelp". Assuming there might be a similar bug, I tried the properties with both strings.

What I'm getting is:
Bundle-Version: 0.0.0
Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Localization: plugin
Bundle-Name: %name
Bundle-Vendor: %providerName
Eclipse-LazyStart: true
Bundle-SymbolicName: com.demandware.dochelp; singleton=true; singleton:=true

So it looks like the provider parameter isn't working. Also, there doesn't seem to be a way to specify a Bundle-Name (I'm using the DITA-OT on a Mac, if that makes a difference.)

Thinking this should be closed for 3.0 -- the eclipse map specialization will likely be moved to an external plugin and no longer bundled with DITA-OT, as it is not actually an OASIS standard document type, instead reflecting just one of IBM's specializations (still in fairly wide use in IBM, but regardless, it should probably not be part of the off-the-shelf DITA-OT download). CC: @easirois for awareness, if you haven't been part of that discussion elsewhere.

No, I have not followed the discussion somewhere else. I think the singleton reference in the symbolic name parameter is not helping the issue.  Having the %value in the manifest should inhibit it from being loaded. They are there in case those value are translated.
We used that code for years internally without an issue. That said, it could be that newer versions of Eclipse are stricter with the manifest file then they were in the 3.x version.  If it's still an issue, I would need more info about the version of eclipse being used to display the content.

This issue should not be marked as obsolete. I was not using the eclipsemap specialization, just plain dita and attempting to localize the output. The build arguments worked for the properties files, but not for the manifest - that was the bug.
If you are considering removing any support for eclipse as an output, I'd wonder what you think will replace it as a full-fledged help system generated from the DITA-OT. The tocjs plugin is a antiquated, since it still uses an iframe, and nothing else is appropriate for help systems, since the other targets don't include search or a TOC.

My mistake - I did not actually realize that we generated the Manifest when not using the Eclipse Plug-in map. Eric's last comments from 2014 gave me the impression this was related to the specialization.
The Eclipse help format itself is not currently being considered for removal - only the related specialized map, which could then be added back in manually as a plugin.

Looking at the original sample, the symboliname parameter should not have the singleton=true value in the Ant paramter, that part is added to the manifest file when the manifest is created.
This:

Should be:

That said, something is not working with the Eclipsehelp output when you have build parms in 2.3.1.  Looking into that a bit more.


rework checks.sh

Rework, complete and test the needed tools and libs based on a clean, fresh Ubuntu 18.04

done in #94


Repair the Computer Blue test

coverage: 63.15%. remained the same
when pulling 48036402a75cf104e4b1aa6ecfcbb27968f1554c on fix-mb-test
into e116753ba799a7225e4a5a90c0fc7ae8d400d8a2 on main.


Some local search ideas

I'm first going to profile and speed things up. Then I want to try dividing, say, some iterations over each route and try to very locally improve each route.

Yeah nah this turned into an MDP for the handling sub-problem. That's a bit tricky to get right - the current implementation appears to work, but I want to be more certain it works and is a good idea before merging it in. At least it's not infeasible :-).

@EmielK I'm going to write some tests today/tomorrow to make sure the handling is rock-solid. Then the MDP needs some work, and hopefully by Friday this is all wrapped up.

@EmielK I'm merging this in once it passes Travis.


Complete migration strategy functionality

Edited by @0x-r4bbit:
Adding some context here:
There were a bunch of missing pieces and bugs in the migration strategy.
Some of them have been addressed in #47

@3esmit I've added some context to this issue.
I'm unsure however what's the current state of migration. If I remember correctly, there were still some things missing.
Can you please add a comment here with what's left to be done for migration only?

Fixed on #59


Not much help for complex objects

If you are working lists composed of custom classes, this code doesn't help much.

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

ID: 7550db03-fb38-f27b-59a3-ef202349e2f1
Version Independent ID: 088ccbb9-47bf-da50-c637-07d142e9834f
Content: How to: Find the Set Difference Between Two Lists (LINQ) (C#)
Content Source: docs/csharp/programming-guide/concepts/linq/how-to-find-the-set-difference-between-two-lists-linq.md
Product: dotnet-csharp
GitHub Login: @BillWagner
Microsoft Alias: wiwagn

Thanks for your feedback @Kberg81. We do cover that scenario in the API reference:
https://docs.microsoft.com/en-us/dotnet/api/system.linq.enumerable.except
But it's a good suggestion to enhance this topic to show custom classes too.


Questions

Looks like a nice app but the code is cursed, its pre write based, outdated.
Also while im not saying you should stop working on this project, darkend exists.

💀 darkend

why are you everywhere

nolife github user

Looks like a nice app but the code is cursed, its pre write based, outdated.
Also while im not saying you should stop working on this project, darkend exists.

Is Darkend open source?

Looks like a nice app but the code is cursed, its pre write based, outdated.
Also while im not saying you should stop working on this project, darkend exists.

Is Darkend open source?

It is, and he's the dev.
Darkend got discontinued 4 days ago BTW. Your script is great (although in my Windows 10 machine it crashes after a couple hours every time), I encourage you to keep it up.

Looks like a nice app but the code is cursed, its pre write based, outdated.
Also while im not saying you should stop working on this project, darkend exists.

Is Darkend open source?

It is, and he's the dev.
Darkend got discontinued 4 days ago BTW. Your script is great (although in my Windows 10 machine it crashes after a couple hours every time), I encourage you to keep it up.

Oh thanks i didn't know, I will continue but i don't have much time to work on it because of school. I'll release an update soon which will hopefully fix all the bugs and add support for multiple accounts.


Adding a new TPP sample for batch normalization

Summary:

Refactored existing sample equation/equation_batchnorm.c along the lines of deeplearning/fullyconnected_tpp

should we merge in this state or are some more commits comming?

BTW, while it's fine to skip padding/stride options. We need to support:
if ( norm_type == 0 ) {
  if ( fuse_type == 0 ) {
    fusedbatchnorm_desc.fuse_ops = LIBXSMM_DNN_FUSEDBN_OPS_BN;
  } else if ( fuse_type == 1 ) {
    fusedbatchnorm_desc.fuse_ops = LIBXSMM_DNN_FUSEDBN_OPS_BN_RELU;
  } else if ( fuse_type == 2 ) {
    fusedbatchnorm_desc.fuse_ops = LIBXSMM_DNN_FUSEDBN_OPS_BN_ELTWISE;
  } else if ( fuse_type == 3 ) {
    fusedbatchnorm_desc.fuse_ops = LIBXSMM_DNN_FUSEDBN_OPS_BN_ELTWISE_RELU;
  } else if ( fuse_type == 4 ) {
    fusedbatchnorm_desc.fuse_ops = LIBXSMM_DNN_FUSEDBN_OPS_BN_RELU_WITH_MASK;
  } else if ( fuse_type == 5 ) {
    fusedbatchnorm_desc.fuse_ops = LIBXSMM_DNN_FUSEDBN_OPS_BN_ELTWISE_RELU_WITH_MASK;
  } else {
    /* shouldn't happen */
    return -1;
  }
}

as in the original driver.

Tue main goal of opening this PR was to gain general feedback. I think this is done so now I'm changing the state to WIP. Let's keep this PR pending (I will update it following the comments from @alheinecke and with changes implied by integration for CNN, which is in progress right now)

changed the base to dnn_refactor
please split the code into driver and implementation, implementation goes into samples/op_lib_tpp

you might want to merge dnn_refactor into your branch such that all the weird conflicts go away


Splunk search failed: EOF when importing entities

Hi there,
I am currently experiencing issues when importing entities into my prod environment.  When running a terraform plan or apply I will reliably but inconsistently receive the below error:
PS> terragrunt plan
Acquiring state lock. This may take a few moments...
module.kpi_base_searches["windows_memory"].itsi_kpi_base_search.kpi_base_search: Refreshing state... [id=986272b4-fd32-c3dc-2ba9-bb012e54fca0]
module.kpi_base_searches["windows_cpu"].itsi_kpi_base_search.kpi_base_search: Refreshing state... [id=504927d4-123f-fe39-28ac-0bbfbe7354d0]
module.kpi_base_searches["windows_network"].itsi_kpi_base_search.kpi_base_search: Refreshing state... [id=2a2c0794-917b-aa81-fa33-a615eca4ed80]
module.kpi_base_searches["windows_disk_space"].itsi_kpi_base_search.kpi_base_search: Refreshing state... [id=b308fc68-e090-742c-c957-bf8f6bee0ff9]
module.services["service_vm_1"].itsi_service.services: Refreshing state... [id=8443fdc9-7f36-d7ca-4216-63270cef4251]
module.services["service_vm_2"].itsi_service.services: Refreshing state... [id=3c715417-7bd0-e9e1-bf67-f934fca08c31]
module.services["service_vm_3"].itsi_service.services: Refreshing state... [id=79c5dc89-da1d-e059-ed3d-3c06fef10ec5]
module.services["service_vm_4"].itsi_service.services: Refreshing state... [id=aab00e09-8171-5917-99bd-0127f6a80bc1]
╷
│ Error: Splunk search failed: EOF
│
│   with module.import_entities.data.itsi_splunk_search.itsi_entity_search,
│   on ..\..\modules\itsi\entities\main.tf line 11, in data "itsi_splunk_search" "itsi_entity_search":
│   11: data "itsi_splunk_search" "itsi_entity_search" {
│
╵
Releasing state lock. This may take a few moments...
time=2023-05-25T16:32:37+10:00 level=error msg=Terraform invocation failed in C:/Repos/abc123
time=2023-05-25T16:32:37+10:00 level=error msg=1 error occurred:
        * exit status 1

If I wait long enough, and repeat the command enough (sometimes 10+), it will eventually succeed and create the entities etc as expected.
Here is a sanitised copy of the SPL for the entity search:
search index=abc
| rex "'VMName':(| )'(?<vmname>.*?)"
| rex "'Environment':(| )\'(?<environment>.+)\',"
| rex "'Roles':(| )\'(?<role>.*?)\'"
| rex "'HostName':(| )'(?<physical_host>.*?)'"
| rex "'OS': '(?<os>.*?)'"
| eval vmname=upper(vmname)
| eventstats latest(physical_host) as physical_host by vmname
| stats values(*) AS * by vmname
| eval entity_type=case(os LIKE "WINDOWS%", "Windows", os LIKE "RHEL%", "Linux")
| where (environment=Environment1" OR environment=Environment2" OR environment=Environment3" OR environment=Environment4") AND isnotnull(entity_type)
| eval environment=mvjoin(environment, ",")
| rename vmname AS host
| table host, physical_host, environment, role, entity_type

However, if I use the below dummy search, it works reliably, every time.
| makeresults count=1
| streamstats count
| eval host = case(count=1, "manxlegend123")
| eval physical_host = case(count=1, "box123")
| eval environment = case(count=1, "env-123)
| eval role = case(count=1, "manxlegendtest")
| eval entity_type = case(count=1, "Windows")
| table host physical_host environment entity_type role

It feels like there is some sort of timeout occurring due to the complexity of the search, but I have not been able to identify the issue or setup the debugging mode of the provider.
Thanks
Brandon

Hi, @manxlegend!
I agree, it looks like you receive a timeout due to the complexity of the search or Splunk sadness.
You can extend the timeout in the Splunk search data source by specifying timeout field in seconds (by default it is 60 sec):
https://registry.terraform.io/providers/TiVo/splunk-itsi/latest/docs/data-sources/splunk_search#timeout
data "itsi_splunk_search" "test_search" {

  search {
    query = <<-EOT
        search index=abc
        | rex "'VMName':(| )'(?<vmname>.*?)"
        | rex "'Environment':(| )\'(?<environment>.+)\',"
        | rex "'Roles':(| )\'(?<role>.*?)\'"
        | rex "'HostName':(| )'(?<physical_host>.*?)'"
        | rex "'OS': '(?<os>.*?)'"
        | eval vmname=upper(vmname)
        | eventstats latest(physical_host) as physical_host by vmname
        | stats values(*) AS * by vmname
        | eval entity_type=case(os LIKE "WINDOWS%", "Windows", os LIKE "RHEL%", "Linux")
        | where (environment=Environment1" OR environment=Environment2" OR environment=Environment3" OR environment=Environment4") AND isnotnull(entity_type)
        | eval environment=mvjoin(environment, ",")
        | rename vmname AS host
        | table host, physical_host, environment, role, entity_type
    EOT

    earliest_time = "-14d"
    timeout       = 120
  }

}

In order to make your deployment faster, you can consider to use savedsearch: https://registry.terraform.io/providers/splunk/splunk/latest/docs/resources/saved_searches
And load results via search datasource using: | loadjob savedsearch="owner:app:saved_search_name"

Hi @masha1997
I have increased the timeout period to 120s and I have also tried loading from a saved search like you have suggested, however I still unfortunately get: Splunk search failed: EOF
I dont think the issue issue is related the timeout period as when I run a plan the error is returned within a few seconds.  It seems to me its got something to do with data or search query that it doesnt like.

Hi @manxlegend,
so far I'm unable to reproduce this sort of failure on our side.
We use this data source very often internally and never have this issue.
I suspect that EOF error means that Splunk API returned some whitespace rows that are failing to be parsed as JSON objects, but not sure why that would happen. It could be an issue with Splunk infrastructure or potentially something specific to your Server or Client environments.
We could probably try some shot in the dark "fix" for that (e.g. make sure we discard whitespace-only lines), but it'd be better if we could actually understand the problem first.
Could you please provide us with some more details about your environment?
In particular, what version of Splunk are you using, on what OS is it hosted and version of ITSI provider. And also, how many rows does your search return and are any of its results multi-value?

@dmitrykruglov sorry for the late reply.  I agree I think its to do with the whitespace error. I see that you done a release to 1.0.0-beta.4 to improve search functionality.  I have upgraded to 1.0.0-beta.5 just now and the search is running every time now.  Thank you @dmitrykruglov and @masha1997 for your help.

@manxlegend thank you for the update, glad to hear that it's fixed!


Merge upstream v0.2.6

Merge upstream version v0.2.6 and

remove the --mount extension (originally https://github.com/osrf/rocker/pull/46) in favor of --volume added in https://github.com/osrf/rocker/commit/dc046c7d0965892d5dbb8156aefa8306c74fd4fb, and make --mount an alias for --volume for backwards compatibility (c81c2ffa59223519bda810611ac981e97019b61f)
do not tag detect_os images, see also https://github.com/Intermodalics/rocker/pull/6#issuecomment-941629368 and https://github.com/osrf/rocker/pull/133#issuecomment-941622117  (b9637f7fb47f8596c8b5bdd95036dc21e1609841)

It seems working for me as well and it tracks upstream mostly, so LGTM

Although,
$ sudo dpkg --configure python3-rocker
Setting up python3-rocker (1:0.2.6-1intermodalics) ...
  File "/usr/lib/python3/dist-packages/rocker/core.py", line 230
    print(f"Running docker tag {self.image_id} {image_name}")
                                                           ^
SyntaxError: invalid syntax

dpkg: error processing package python3-rocker (--configure):
 subprocess installed post-installation script returned error exit status 1
Errors were encountered while processing:
 python3-rocker

In:
$ lsb_release -a
LSB Version:	core-9.20160110ubuntu0.2-amd64:core-9.20160110ubuntu0.2-noarch:printing-9.20160110ubuntu0.2-amd64:printing-9.20160110ubuntu0.2-noarch:security-9.20160110ubuntu0.2-amd64:security-9.20160110ubuntu0.2-noarch
Distributor ID:	Ubuntu
Description:	Ubuntu 16.04.7 LTS
Release:	16.04
Codename:	xenial


[ACR] Update registry SKU

This checklist is used to make sure that common issues in a pull request are addressed. This will expedite the process of getting your pull request merged and avoid extra work on your part to fix issues discovered during the review process.
PR information

[x] The title of the PR is clear and informative.
[x] There are a small number of commits, each of which have an informative message. This means that previously merged commits do not appear in the history of the PR. For information on cleaning up the commits in your pull request, see this page.
[x] Except for special cases involving multiple contributors, the PR is started from a fork of the main repository, not a branch.
[x] If applicable, the PR references the bug/issue that it fixes.
[x] Swagger files are correctly named (e.g. the api-version in the path should match the api-version in the spec).

Quality of Swagger

[x] I have read the contribution guidelines.
[x] My spec meets the review criteria:

[x] The spec conforms to the Swagger 2.0 specification.
[x] The spec follows the guidelines described in the Swagger checklist document.
[x] Validation tools were run on swagger spec(s) and have all been fixed in this PR.

/cc @SajayAntony

Hi There,
I am the AutoRest Linter Azure bot. I am here to help. My task to analyze the situation from the AutoRest linter perspective. Please review the below analysis result:
File: arm-containerregistry/2017-06-01-preview/swagger/containerregistry.json
Number of linter errors/warnings before the PR: 12
Number of linter errors/warnings after the PR: 12
Thanks for your co-operation.

@olydis Thank you for review this PR. Can we please merge if it looks good? Thanks.

No modification for AutorestCI/azure-sdk-for-node

No modification for AutorestCI/azure-sdk-for-ruby

No modification for AutorestCI/azure-sdk-for-python


Sugarscape with instantaneous growback

@adamamer20 there is enough time to deliver this one, right?

@rht sure, i'm working on it. it shouldn't be too long.

Any update on this one? This one should be the highest priority, I think.

Any update on this one? This one should be the highest priority, I think.

yep, do not worry. by tomorrow I should be done.


Add new custom DocCarousel React Component

Code Task Complete ⚡
✨ View the Asana Task here ✨
Description of Changes
(A brief idea of what reviewers should be looking for, or the expected behavior of the new update.)
To enhance the docs site, allow flexibility for writing docs, and improve the internal workflow of the docs team - requesting to add a scrolling carousel in docusaurus feature. similar to the docs homepage.
The new React Component is called DocCarousel
Loom of component walk through
https://www.loom.com/share/e9fb915ad99b4a6d966e618108cae25f
Preview Links
https://deploy-preview-3160--docs-getdbt.netlify.app/
Additional Info
Documentation for this component available here

@mirnawong1, responding to your Asana questions here as it's easier to paste code. Added a slidesPerView prop which can be passed into the component to control how many columns the carousel displays on desktop. A max of 4 columns can be set, any number set higher than that will revert to 4 columns. Example below:
<DocCarousel slidesPerView={3}>

  <Card />
  <Card />
  <Card />
  <Card />
  <Card />
  <Card />

</DocCarousel>

And regarding having multiple rows per carousel slide, that is possible with a little html structuring. Each top-level element is converted into a slide. So if we wanted two cards stacked on top of each other per slide, we can wrap those two cards in a div like the example below:
<DocCarousel slidesPerView={2}>

    <Card {...props} />

    <Card {...props} />

    <Card {...props} />

    <Card {...props} />

    <Card {...props} />

    <Card {...props} />

</DocCarousel>

Which would ultimately look like:

@mirnawong1 Looks like that's due to the content in the cards being a different size. When stacking two cards on top of each other per column, the only way i can think of keeping them the same height is by using the same amount of content per card.
But my recommendation would be to use single-row sliders. Each slide is equal height, so when cards are in the slider on a single row, they will always be equal height no matter the content. When stacking 2 on top of each other, those two cards have no way of knowing what the heights are of the next two stacked cards in the next column.

ah yea, you're right! i was going to for too much here! wow, this looks amazing to me and i think ready to ship??

tested. it out and looks awesome! future sugg could be to have the arrow bring you back to the beginning maybe but lets see if its even necessary!

Sounds good it is merged, thanks @mirnawong1!!

thank you so much, Jason and Wendy (🙏 ) for all your help!


Document how to use 3.0's SilkTouch

On the back of #559
This includes:

[ ] The different form factors and their differences
[ ] How to use the Source Generator
[ ] How to use the CLI
[ ] The configuration files

[ ] How the AdditionalFiles work (and what the user has to do)
[ ] How the .editorconfig option(s) work (and what the user has to do to use them)

[ ] Configuring the Scraper

[ ] All JSON configuration options
[ ] What each XML mod does

[ ] What additional configuration options each XML mod takes (i.e. the Vulkan-specific mods taking a link to the Vulkan XML specification in the modOptions)

[ ] Configuring the Emitter (if necessary?)
[ ] Configuring the Overloader (if necessary?)
[ ] Perhaps more?

This is mandated by the approved 3.0 proposals, but will leave this open as a reminder.


chore(sidecar): expose a version endpoint

As part of our next releases, we are going to start using the Sidecar's CARGO_PKG_VERSION to reliably keep track of versions of the software that node operators are running. Ideally, this should also be available as a header on a per-request basis.
This issue consists in adding this functionality with both a version API endpoint and an HTTP header x-sidecar-version.
A more generic approach could be to introduce a more elaborate Capabilities enum along with the version, similar to Ethereum's engine api specs, but I think this is overkill for our current needs.

For the sake of continuity, this should probably be implemented as a JSON-RPC method, i.e. bolt_getVersion


PS-55 Register new parcel page/form

Not the best visually, but because of time pressure don't want to spend too much time on that. Most importantly it works :D (prints entered data inside browser console as of now)

Adding screenshot:


Lazy loading Form module

Framework7 version: 7.0.7

Describe the bug
function initAjaxForm in form.lazy.js is not available from global code throught app instance, therefore form-ajax-submit is not working after lazy loading module

I suggest this


Fix null value representation in ORC files

Description
When I first implemented the ORC writer code, I decided to skip null or mismatched values in ORC files because they made some troubles.
Now, we need appropriate representations of them.

Null values are stored as nulls.
For string type columns, the non-null values are stored as their toString() values.
For non-string type columns, it's impossible to store mismatched values usually. Rows that have any of this kind of mismatched values are skipped. We can check this with skippedLines.

Related Issue : https://github.com/metatron-app/metatron-discovery/issues/2752
How Has This Been Tested?

Import & wrangle
s5k_1.csv.txt
Select set command.
Put null as expression, column9 < 2 as condition. Then click "Add"
Click "Snapshot"
If you see (null)-contained rows, then passed.

Need additional checks?
Yes, please.
Types of changes

[x] Bug fix (non-breaking change which fixes an issue)
[ ] New feature (non-breaking change which adds functionality)
[ ] Breaking change (fix or feature that would cause existing functionality to change)

Checklist:

[ ] I have read the CONTRIBUTING document.
[x] My code follows the code style of this project.
[ ] My change requires a change to the documentation.
[ ] I have added tests to cover my changes.

run build
deploy to 4


[Meta] Best frequency to run at?

I Googled around and checked the issues here but I couldn’t find a real answer.
I currently run the test every 4 hours, but I’d rather have hourly data. I have 2.5 gigabit internet which can use a lot of data when speedtesting, so I’ve been afraid to increase the frequency to hourly.  What frequency does everyone use for their tests?

If you don't have a data cap you can test as much as you want 😅.
Just keep in mind that testing might also influence your own use of the bandwidth, as in testing to much might cause buffering in live streaming or latency increase while online gaming. As well the other way around, your own bandwidth usage will influence the test, when downloading a big file or game update might influence the test results.
Personally I test every second hour (6 */2 * * *), it gives me a nice balance of having enough data and not test to much. As the end of the day we pay to use the bandwidth, not just for testing it 😉 .

Going to convert this to a discussion, not really an issue per say


tree: Mark internal types as system types

Description
Tree has several types that meet the requirements to be @system (grouped under InternalTypes) but predate the system tag. Now that system has public facing docs, they should be tagged accordingly.
In the future we may want to remove the InternalTypes grouping/pattern used on these types as it causes some issues with TypeScript reexports in customer code, as well as breaks API-Extractor in some cases. Regardless of if we make a such a change, making them as system better communicates their status.
Reviewer Guidance
The review process is outlined on this wiki page.

Seems like a changeset would be worth it to announce this somehow? Especially since @system is not a standard tag.

These types are still all nested under InternalTypes which your not supposed to refer to, system is just providing redundant but more standard documentation for this via https://fluidframework.com/docs/build/releases-and-apitags/ . As we haven't had any issue with customers using them, I don't think there is a need to call this our and spend customer time reading about it.
If we do end up moving them out of internalTypes, then that may warrant a changeset, but even in that case its not supposed to impact customers in any way, and even new customers not reading the changeset have to be expected to not use these, so relying on changesets to inform people of the semantics of system doesn't seem like a robust approach.

These types are still all nested under InternalTypes which your not supposed to refer to,

Ah, I didn't know about internalTypes. Seems fine to skip the changeset then.


Parse email formatting

Hello, we've been using the email forwarding as a way to share emails in Zulip. One nit that has shown up is that Zulip doesn't preserve the email's original formatting. I was wondering if it was possible to allow Zulip to parse an email's formatting to render in Zulip? The naive approach to this would be to have an email parser that converts the document into markdown that is then rendered by the client. It's probably not possible to map all of styling available in emails to markdown without increasing complexity and maintenance. However I think it would still be desirable even if it only covers the simple case (bolds, italics, etc.)

I believe our system already uses html2text.HTML2Text() to convert any HTML markup in a text/html email into markdown before sending it into Zulip.  If you have an example of the raw content of an email where this isn't working, we can look at improvements to that (one possible issue would be if the email is using e.g. style= rules to set font-weight rather using <strong> tags).

@timabbott I can't share the particular emails since they aren't public. But I can say for certain that no styling is being applied to email messages. I what I tend to do is write an email to someone and CC the the stream mailing list so that we have a full log of it on Zulip that we can use for discussion, and none of the emails I've ever sent have had styling, nothing bold or anything.

If you can provide a modified copy of the emails with no private content, just the formatting (e.g. change all the text to xxxs), that'd be helpful.
Also, what Zulip version are you running?

I don't know if that's needed, currently no styling is applied. You could easily test this with sending email to the gateway with bolding and it will be unbolded in Zulip.

While reproducing #13416 I also reproduced this bug. You can see in the zulip stream that there's no styling but in my email I have bold italics and underlines.
I'm using Mail.app Version 13.0 (36<IP_ADDRESS>.4)

I don't think that's strictly speaking a bug, it was intentionally done that way in the code, but I think it does make sense to change this behavior. The way it is now is that if the message provides a plaintext version of the message, we use that, rather than trying to render html:
def extract_body(message: message.Message, include_quotes: bool=False) -> str:
    import talon
    global talon_initialized
    if not talon_initialized:
        talon.init()
        talon_initialized = True

    # If the message contains a plaintext version of the body, use
    # that.
    plaintext_content = get_message_part_by_type(message, "text/plain")
    if plaintext_content:
        if include_quotes:
            return plaintext_content
        else:
            return talon.quotations.extract_from_plain(plaintext_content)

    # If we only have an HTML version, try to make that look nice.
    html_content = get_message_part_by_type(message, "text/html")
    if html_content:
        if include_quotes:
            return convert_html_to_markdown(html_content)
        else:
            return convert_html_to_markdown(talon.quotations.extract_from_html(html_content))

@timabbott Should we favor the html version by default?

Alternatively, we could add an option in the email address (like .show-sender) to tell the system to use HTML, and keep plaintext as the default behavior.

Hmm.  I think the current behavior is correct -- if they provide a plain-text version, that's likely to be better markdown-like content and more reasonable to process than the output of converting HTML to markdown.  But I think it makes sense to have an option to control which is preferred, maybe documented as this:

.prefer-html: By default, Zulip prefers the plain-text (text/plain) content of emails when available, and converts emails that are only available in HTML format (text/html) to markdown.  With this option, Zulip will use the HTML format (text/html) version of an email even if a text/plain version is available.

I can imagine us at some point choosing to swap the default behavior down the line, so it might make sense to implement .prefer-text at the same time (but perhaps not document it, since it does nothing), and then we can think about an experiment of swapping which approach we prefer as a separate issue.

I think having .prefer-text makes sense. For documentation purposes, I think it should documented along with .prefer-html and mention that it included by default. There's no reason if it's documented it can't be changed. And then there is already documentation ready when the change is made.

Yeah, that's reasonable; we can just document that it is the default, but should we change the default in the future, will prefer text/plain.


map_fn produces inconsistent results when using numpy vs. tf constants

System information

Have I written custom code (as opposed to using a stock example script provided in TensorFlow): Nope
OS Platform and Distribution (e.g., Linux Ubuntu 16.04): Ubuntu 16.04
TensorFlow installed from (source or binary): Binary
TensorFlow version (use command below): 1.5
Python version: 3.5.2
Bazel version (if compiling from source):
GCC/Compiler version (if compiling from source):
CUDA/cuDNN version: CUDA 9, cudnn 7
GPU model and memory: Quadro M1200 4GB
Exact command to reproduce: See below

Describe the problem
According to the map_fn docs, second example https://www.tensorflow.org/api_docs/python/tf/map_fn
elems = (np.array([1, 2, 3]), np.array([-1, 1, -1]))
alternate = map_fn(lambda x: x[0] * x[1], elems, dtype=tf.int64)
## alternate == [-1, 2, -3]

I ran this
elems = (np.array([1, 2, 3]), np.array([-1, 1, -1]))
output = tf.map_fn(lambda x: x[0] * x[1], elems, dtype=tf.int64)
sess = tf.Session()
print(sess.run(output))

which returns [-1  2 -3] as expected
But if I run
elems = tf.constant(((1, 2, 3), (-1, 1, -1)), dtype=tf.int64)
output = tf.map_fn(lambda x: x[0] * x[1], elems, dtype=tf.int64)
sess = tf.Session()
print(sess.run(output))

The output is [2 -1], which is not what I expected since the input is the same numbers with the same shape.
The output should be the same? Is there something special going on with numpy arrays?
Interesting read: https://stackoverflow.com/questions/45905601/how-does-tf-map-fn-work

No, if you replace the values you'll understand what's happening.
For example, try this:  elems = tf.constant(((10, 2, 3), (-10, 2, -1)), dtype=tf.int64)
It will output [ 20 -20].
As you can see, when using constants map_fn thinks you want to apply the lambda function to the vecors, not the matrix.  Not sure it's an expected behavior though.

Hmm, I read the source code and it checks if the input is a sequence. But this behaviour seems to be vaguely documented though.


Unintended Uninstall of Windows Apps

I found this script and thought it would be the ideal way to set up my computer with Visual Studio to do some coding.  It was not clear by running the full script a lot of Windows 10 apps would be uninstalled permanently (e.g Minecraft, Xbox app).  Is there as simple script to reinstall these or a way to use this script to reinstall them?

I agree, I fall to that script from Microsoft documentation, I thought it was safe and only did what it said, install "Full Desktop App" env.
This is a damn **** script (sorry), but I just saw it uninstalling a lot of my app and got a notification about UAC trying to be disabled.

That absolutely not acceptable, will never trust Microsoft documentation external links anymore (btw, came from https://docs.microsoft.com/en-us/learn/modules/introduction-to-windows10-dev/2-installing-tools-automatically)
Waste my time, now I need to review any accounts perform by the script.


Change the UI of quiz page to look like home page

This will change Quiz UI to look more like the home page theme, issue #70

Thank you for contributing! Merging it🚀
Happy Hacktoberfest!!


📚 Epic: Advance code sync

In basic scenarios, a simple copy of train.py might be enough. However, in more realistic ones the entire Git workspace needs to be transferred - dvc exp can create snapshots like this. This tool (or idea) should be reused for proper workspace copy.

I was assuming to copy current folder or clone repo like a runner does.
This first might be more convenient that the later since you can sync non yet committed code

Closed with #237


Proposal: Improve the precision and speed of DateHeaderValueManager

The System.Timer that fetches the time from the RTC in DateHeaderValueManager has an interval of one second. That means the precision can not be higher than one second.
Also, calls to GetDateHeaderValue call PumpTimer() which involves a lock, effectively serializing all calls to this method.
The following proposal improves the precision and speed of DateHeaderValueManager:
Instead of PumpTimer(), have StartTimer() and StopTimer() methods.
StartTimer will:

Calculate a _lastReadTime long value. (more on this later)
Calculate a _lastReadStringTime string or byte array value.
If the object isn't disposed,  set a volatile\interlocked boolean value called _timerIsRunning to true and start the timer loop.

The timer loop, will read the UTC time from the RTC every 10 ms, convert it to ticks and store it in a long called _currentTime.
GetDateValue() will look like this:
 byte[]/string GetDateValue()
{
  if(!_timerIsRunning){StartTimer();}
     return ReadDateValue();
}

private ReadDateValue()
{
long currentTime;
if(_disposed)
{
 currentTime = GetFromRTC();
}
else
{
  currentTime = ReadCurrentTime(); //This performs a dirty read on _currentTime, or Interlocked.Read on 32-bit systems.
}

if (_lastReadTime - currentTime > threshold \* 100 ms*\)
{
  if (interlocked.CompareExchange(ref _lastReadTime, ref currentTime)
  {
    var _newTimeString = CalculateTimeString(_lastReadTime);
    Interlocked.CompareExchange(ref _lastReadTimeString, ref _newTimeString);
  }
}

 return _lastReadTimeString;

}

This proposal eliminates the lock in PumpTimer() and increases the time precision to 100ms.
I'm not sure this will move the overall performance needle in Kestrel but I think it's worth checking out.
I can provide a PR if the team finds this approach interesting.

Make sure to show some performance results with the pull request. That'll be more convincing than anything else.

That means the precision can not be higher than one second.

Just curious, why would you need a precision higher than one second when format used is RFC1123, e.g. Sat, 28 Nov 2015 20:45:30 GMT?

@khellang  :smile:  I didn't even look at that time format. I'll have to rethink this.
@davidfowl I'll have a PR ready in a day or two.

The date header is used to workout if caches need to be updated vs max-age (which is normally minutes, hours, days, weeks, months or even a year) http://www.w3.org/Protocols/rfc2616/rfc2616-sec13.html#sec13.2.3 not sure a second here or there is that important in the scheme of things...

Looks like this has been merged. If there's additional work to be done, please feel free to open another one.
Thanks for the PR!


Fix ChronosStore storeID getter

Move the storeID getter to the instance, as the StoreMixin accesses storeIDs as a property of the stores not the constructors.

Reviewer: @aldipower

Nice catch 👍

Nice! With test! :)


[CARBONDATA-2115] Docummentation - Scenarios in which aggregate query is not fetching …

Added the FAQ on Scenarios in which aggregate query is not fetching

Can one of the admins verify this patch?

Can one of the admins verify this patch?

Can one of the admins verify this patch?


oneview_ethernet_network bug

So coincidentally I started to configure networks using terraform, and think I may have exposed the issue I was having related to network lookups happening improperly in profiles, but now I am seeing it on a much less convoluted resource for me implementation wise..   I am configuring about 25 vlan's using resources just like the ones below.
I snipped out the 20+ other vlan's to give a clean example.
resource "oneview_ethernet_network" "ETH_VLAN_150" {
  name    = "ETH_VLAN_150"
  type    = "ethernet-networkV4"
  vlan_id = 150
  smart_link = true
}
resource "oneview_ethernet_network" "ETH_VLAN_672" {
  name    = "ETH_VLAN_672"
  type    = "ethernet-networkV4"
  vlan_id = 672
  smart_link = true
}

No code change between subsequent TF plans:
PS C:\gitrepos\terraform\networks> C:\terraform12\terraform.exe plan
Refreshing Terraform state in-memory prior to plan...
The refreshed state will be used to calculate this plan, but will not be
persisted to local or remote state storage.

oneview_ethernet_network.ETH_VLAN_672: Refreshing state... [id=ETH_VLAN_672]

------------------------------------------------------------------------

An execution plan has been generated and is shown below.
Resource actions are indicated with the following symbols:
-/+ destroy and then create replacement

Terraform will perform the following actions:

  # oneview_ethernet_network.ETH_VLAN_150 must be replaced
-/+ resource "oneview_ethernet_network" "ETH_VLAN_150" {
      ~ category                = "ethernet-networks" -> (known after apply)
      ~ connection_template_uri = "/rest/connection-templates/2b7dc71e-2ff5-46cd-b004-5229f473942e" -> (known after apply)
      ~ created                 = "2021-04-13T15:35:37.822Z" -> (known after apply)
      ~ etag                    = "503ed9aa-70b0-4205-bd04-6105c6f29dd3" -> (known after apply)
        ethernet_network_type   = "Tagged"
      ~ fabric_uri              = "/rest/fabrics/60fd6f94-2d16-43d6-bbd7-90531bf45bda" -> (known after apply)
      ~ id                      = "ETH_VLAN_150" -> (known after apply)
      - initial_scope_uris      = [] -> null
      ~ modified                = "2021-04-13T15:35:37.822Z" -> (known after apply)
      ~ name                    = "ETH_VLAN_672" -> "ETH_VLAN_150"
        private_network         = false
        purpose                 = "General"
      ~ scopesuri               = "/rest/scopes/resources/rest/ethernet-networks/02ec89b4-2573-4a7f-a7a4-2ad3344c26b4" -> (known after apply)
        smart_link              = true
      ~ state                   = "Active" -> (known after apply)
      ~ status                  = "OK" -> (known after apply)
        type                    = "ethernet-networkV4"
      ~ uri                     = "/rest/ethernet-networks/02ec89b4-2573-4a7f-a7a4-2ad3344c26b4" -> (known after apply)
      ~ vlan_id                 = 672 -> 150 # forces replacement
    }

Plan: 1 to add, 0 to change, 1 to destroy.

------------------------------------------------------------------------

5 seconds later I rerun TF:
PS C:\gitrepos\terraform\networks> C:\terraform12\terraform.exe plan
Refreshing Terraform state in-memory prior to plan...
The refreshed state will be used to calculate this plan, but will not be
persisted to local or remote state storage.

oneview_ethernet_network.ETH_VLAN_150: Refreshing state... [id=ETH_VLAN_150]
oneview_ethernet_network.ETH_VLAN_672: Refreshing state... [id=ETH_VLAN_672]

------------------------------------------------------------------------

No changes. Infrastructure is up-to-date.

This means that Terraform did not detect any differences between your
configuration and real physical resources that exist. As a result, no
actions need to be performed.

To be clear, If I re-run this multiple times, every time I plan I get varying results, where the networks are not properly correlating with the objects in oneview. It's seemingly random which networks don't matchup.

This is really starting to become a major issue for us.  It's not just network resources, its the profiles as well.
There must be a bug when there are many items in the state file, and it's caching or resolving improperly.  Everytime I rerun a plan/apply I get different results.
Let me know what I need to do to expedite.

We are able to reproduce the issue. We are working on this and will get back to you.

Appreciate that - this is probably the biggest bug in terms of priority, because it has now forced us to do this on profiles because idempotency is a hard requirement, when running TF in a CI/CD pipeline.
  lifecycle {
    ignore_changes = [
      name,
      boot,
      bios_option,
      hardware_name,
      connection_settings[0].connections[0],
      connection_settings[0].connections[1],
      connection_settings[0].connections[2],
      connection_settings[0].connections[3],
      connection_settings[0].connections[4],
      connection_settings[0].connections[5],
      local_storage[0].controller[0].logical_drives[0].bootable,
      local_storage[0].controller[0].logical_drives[0].name
    ]
  }

We have found the root cause of this issue. The fix will be provided as part of OV 6.20

The issue is already fixed and it will be available with OV 6.20 . The OV release is scheduled for mid July.

@rismoney Hi Rich,
This issue has been fixed in v6.2.0, and, therefore, I will be proceeding to close this issue.
If you have any other concerns please feel free to open a new issue. Thank you.


get_variables constraint doesn't work

import tensorflow as tf
a = tf.get_variable('a', shape=[], constraint=lambda t: tf.clip_by_value(t, -2, 2))
sess = tf.Session()
sess.run(a.assign(3.))
sess.run(a)

I tried on tf 1.8.0 and tf 1.5.0, both outputs 3

If you read the API:
constraint: An optional projection function to be applied to the variable
        after being updated by an `Optimizer` (e.g. used to implement norm
        constraints or value constraints for layer weights). The function must
        take as input the unprojected Tensor representing the value of the
        variable and return the Tensor for the projected value
        (which must have the same shape). Constraints are not safe to
        use when doing asynchronous distributed training.

Thanks, I got it. The constraint is only applied after being updated by a Optimizer


Fix application trigger issue and update time trigger text

Fixes issues with re-registering ApplicationTrigger

@jefinch20,
Thanks for your contribution as a Microsoft full-time employee or intern. You do not need to sign a CLA.
Thanks,
Microsoft Pull Request Bot


Regression: Some v1 protocols do not have their pipettes recognized in v3.15.2

overview
Pipette calibration is always skipped when running an API v1 protocol on v. 3.15.2.  API v2 protocols run normally, with pipette calibration occurring for them.  This behavior was not observed in prior versions (v 3.10.3).

current behavior
Every time an API v1 protocol is run on an OT-2 running server version 3.15.2 and using app version 3.15.2, pipette calibration is completely skipped.  There is no prompt to remove the trash pin cover and calibrate the pipette heads.  It is skipped entirely, and labware calibration continues as normal.  Protocols do work normally, but I feel that missing this calibration data may cause drift over time.
This was observed with a protocol that uses a P300_multi and a P300_single Gen1 pipettes.

steps to reproduce
Create a protocol that uses both pipettes.  Attach Gen1 P300_multi and P300_single pipettes to the OT-2.  Attempt to run a API v1 protocol.  Observe that pipette calibration is skipped.

expected behavior
The app should prompt you to remove the trash bin cover and place a pipette tip on the pipette.
Then, pipette calibration should occur.

┆Issue is synchronized with this Wrike Task by Unito

No longer applicable due to the deprecation and removal of PAPIv1


error ?

Thank you for great codes!
My environment is pip3, ubuntu, ... I completed all libs ..
But, I got an error in last command line:

W1, W2, loss_vs_epoch = cbow.run()
Traceback (most recent call last):
File "", line 1, in
AttributeError: 'function' object has no attribute 'run'

Would you help me ?
Regards,

Hi @chocosando,
I just tested the example again and it works. If you do import word2veclite, does this give you any problems?

Hello,
There is no error in "import word2veclite"
My error is similar to second issue:
"ValueError: shapes (2,7) and (2,7) not aligned: 7 (dim 1) != 2 (dim 0)"
My version of numpy is 1.14.2 .  Should I use 1.13 version ?

Thank you so much!
It works well. : )

Great, I am going to close this issue then!


InvalidArgumentException on install

Laravel version: 5.0.1
html package added!
composer require caffeinated/modules

[InvalidArgumentException]
Could not find package caffeinated/modules at any version for your minimum-stability (stable). Check the package spelling or your minimum-stability

Now that Laravel 5 is released, you'll need to reference Caffeinated Modules with the @dev tag within your composer.json file until I get a stable 1.0 release out.
composer require doesn't seem to do this automatically.


moved code from AppLayoutRouterLayout to AppLayoutRouterLayoutBase and

changed AppLayoutRouterLayout to be an intermediate class only defining
a viewport to keep backwards compatibility. I have been using a copy of AppLayoutRouterLayout locally as a nested layout for several months now, everything is working fine. Parent layout in my case is just a simple router layout extending div implementing BeforeEnterObserver to check security, without any content added directly. With this change I wouldn't need to copy the AppLayoutRouterLayout (and keep updating the copy on every new release), just to extend the AppLayoutRouterLayoutBase instead.

For reference, see https://github.com/appreciated/vaadin-app-layout/issues/220

Do you also want to add an UI test with your specific usecase that actually uses the AppLayoutRouterLayoutBase?
So when f.e. for development reasons your feature breaks the developer will be informed automatically.

I have added the test, I tried to make it according your app-layout-ui-test-left test, but removed unnecessary stuff.


checkin policy is not satisfied even after closing the code review request ,any idea ?

I had installed the checkin policy on VS 2015. Before i did a checkin it asked to submit for a code review. I did submit for a code review to one of my other colleague.. he then went and approved my changes. So the code review is done. I went in and tried to checkin the same file but it still shows that the code review is not yet done.

Hi @kriskoneru Have you configured the "Require Code review to be closed" setting? If this is set, then even if the code review is complete, the policy may require that the code review work item state is set to closed (which it doesn't do by when you approve / reject the code review in VS).

Ok.. thank you yes previously i did set check the option for "Require Code reivew to be closed". Now when i unchecked the option. i am able to checkin once the code review is complete.

Glad you got it sorted!


Ruff fails to reject invalid syntax in annotation scopes

Ruff produces no errors for these three lines:
type X[T: (yield 1)] = int
type Y = (yield 1)
def _f[T](x: (yield 1)) -> (y := 3): return x

But they are syntax errors in Python:
>>> type X[T: (yield 1)] = int
  File "<stdin>-0", line 1
SyntaxError: yield expression cannot be used within a TypeVar bound
>>> type Y = (yield 1)
  File "<stdin>-1", line 1
SyntaxError: yield expression cannot be used within a type alias
>>> def _f[T](x: (yield 1)) -> (y := 3): return x
...
  File "<stdin>-2", line 1
SyntaxError: yield expression cannot be used within the definition of a generic

Producing errors for these cases feels low priority, because I don't know why anyone would do this other than to be difficult; I noticed it while looking at the parser. Still, I'd expect Ruff to tell me about all SyntaxErrors in my Python code.
Ruff has a few analogous rules for constructs that produce syntax errors at runtime:

https://docs.astral.sh/ruff/rules/yield-outside-function/
https://docs.astral.sh/ruff/rules/await-outside-async/

Not sure if the "parser" label is appropriate here. This sort of thing cannot really be detected in the parser itself, because it requires contextual information that is only available once you have a parse tree. In CPython, these errors get detected during symtable construction. In Ruff, I think it makes the most sense to detect them in standard AST-based lint rules, similar to the two rules I mentioned above.
The AST nodes affected are yield, yield from, await, and the walrus. This applies to all forms of annotation scopes: TypeVar bounds/constraints, generic class bases, generic function annotations, and the values of type aliases.

Fair point... In that case, I wonder if this is this even a "bug". Perhaps this could be classified as a "feature request for a new rule" 😛

Thanks! So, as per the grammar this is a valid syntax which is why the parser doesn't raise a syntax error.
Module(
   body=[
      TypeAlias(
         name=Name(id='X', ctx=Store()),
         type_params=[
            TypeVar(
               name='T',
               bound=Yield(
                  value=Constant(value=1)))],
         value=Name(id='int', ctx=Load()))],
   type_ignores=[])

Correct me if I'm wrong but I believe that in CPython this is being done at compile time. There are a couple more syntax errors which we want to look into, so this should be a new rule. Also, all of these syntax errors which are being raised at compile time would be categorized in a "Correctness" (or similar) category after #1774 is done.


figuring out branch

I'll just close this request so we can move on... I don't want to mess up anything


[QA] Change MultiQuery Prompt, Add Hybrid Search (BM25 + Embedding), Cohere Reranker & LLM Chain Filter

[QA] Change MultiQuery Prompt, Add Hybrid Search (BM25 + Embedding), Cohere Reranker & LLM Chain Filter
This Issue is to track QA efforts on https://github.com/astronomer/ask-astro/pull/247

Summary of Observations
This is just a quick summary from my side, feel free to add more to this @vatsrahul1001
Improvements in Answer Quality and Source Attribution

There has been a noticeable enhancement in the quality of answers and the relevance of cited sources across the board. This applies to both questions that previously received satisfactory responses and those that did not.

Expected Degradation of Astro SDK Read Doc Related Questions

With the de-ingestion of the Astro SDK Read Docs, some of these related questions have less relevant responses. However, this is expected and not related to the RAG pipeline changes.

Expected Degradation of Astro SDK Read Doc Related Questions

With the de-ingestion of the Astro SDK Read Docs, some of these related questions have less relevant responses. However, this is expected and not related to the RAG pipeline changes.

Source Documents Ordering Incorrect in Slack

This is expected and already being tracked in a separate issue.

Noteworthy Examples of Answer Improvements (Compared to Previously Incorrect Answers)

Question: "Do you know of Astronomer cosmos?"

Previous Inadequate Answer: "I'm sorry, but I don't have information on 'Astronomer Cosmos'..."
Revised Accurate Answer: "Yes, Astronomer Cosmos is a powerful tool for running dbt workflows in Apache Airflow. It provides an easy-to-use, flexible solution to running dbt projects in Airflow. Cosmos expands your dbt project into a Task Group or a full DAG (Directed Acyclic Graph), with each step of a model rendered as an Airflow task..."

Question: "What is the default schedule of a dag and how do I turn it off altogether?"

Previous Inadequate Answer: "The default schedule of a DAG in Airflow is None, which means the DAG will not be scheduled to run automatically..."
Revised Accurate Answer: "The default schedule of a DAG in Airflow is timedelta(days=1), which means it will run once per day. If you want to turn off the scheduling of a DAG altogether, you can set the schedule_interval parameter to None when you're defining your DAG..."

Question: "What is Astro SDK?"

Previous Inadequate Answer: "I'm sorry, but there's no such thing as the Astro SDK. Astronomer offers the Astro CLI..."
Revised Accurate Answer: "The Astro Python SDK is an open-source tool and Python package for DAG development built and maintained by Astronomer. Its purpose is to simplify the process of writing DAGs in Apache Airflow, particularly for Extract, Load, Transform (ELT) use cases. This allows pipeline authors to focus more on writing business logic in Python, and less on setting Airflow configurations."

Question: "How to install astronomer-providers"

Previous Inadequate Answer: "To install Astronomer's provider packages, you can use pip, the Python package manager. Here is the general command: pip install astronomer-providers-<provider-name>"
Revised Accurate Answer: "You can install the astronomer-providers package using pip, Python's package installer. Here are the steps:

To install dependencies for the core provider, run the following command in your terminal:pip install astronomer-providers
```"

Question: "What is the latest version for Astronomer Providers?"

Previous Inadequate Answer: "I'm sorry, but I don't have the latest information on the version of Astronomer Providers..."
Revised Accurate Answer: "The latest version for Astronomer Providers is 1.18.4."

Difference in Source Documents Count

The process of sourcing documents has been refined. Previously, rewording a user query three times (each pulling 4 documents) would yield between 4 to 12 source documents, depending on duplicates.
The current system employs a reranker that consistently returns 10 documents. These are subsequently reviewed by a GPT-3.5 model to filter out irrelevant documents, resulting in a more focused set of 5 to 10 documents.


Convert num_planets to an int to prevent -n from crashing the program

I received the error below when trying to use the -n flag.
Traceback (most recent call last):
File "play.py", line 72, in
call_engine(options)
File "play.py", line 24, in call_engine
state, id = State.generate(options.num_planets)
File "/home/infergo/planet-wars/api/_state.py", line 469, in generate
for i in range(num_planets - 2):
TypeError: unsupported operand type(s) for -: 'str' and 'int'
(Bart van Dijk, 2598117)

Thanks for the pull request. I must not have tested that option.


An example with modular folder structure

Hey y'all, I'm working on a nice example I'd like to eventually put in the docs / book, but I'm a little stuck on making it modular.
The current minimal example looks nice, but it quickly gets cumbersome to have a bunch of definitions in one massive file. Here's what I'm trying to do roughly:

Structuring a project this way will make it easier to add new functionality to a GraphQL project made in Juniper. The only problem I'm having is I don't know how to "merge" these separate schemas into one schema at the end at compile time.
I've created a little repository to illustrate the goal: https://github.com/savovs/juniper-schema
A minimal example would be if you have more than one module.
i.e. in a module hello:
schema.gql
type Query {
   hello(name: String!): String! @juniper(ownership: "owned")
}

mod.rs
use juniper;
use juniper_from_schema::graphql_schema_from_file;
use super::Context;

graphql_schema_from_file!("src/graphql/hello/schema.gql");

pub struct Query;

impl QueryFields for Query {
  fn field_hello(
    &self,
    executor: &juniper::Executor<'_, Context>,
    name: String,
  ) -> juniper::FieldResult<String> {
    Ok(format!("Hello, {}!", name))
  }
}

And in a module users:
schema.gql
type Query {
  # The directive makes the return value `FieldResult<String>`
  # rather than the default `FieldResult<&String>`
  currentUser: String! @juniper(ownership: "owned")
}

mod.rs
use super::Context;
use juniper;
use juniper_from_schema::graphql_schema_from_file;

graphql_schema_from_file!("src/graphql/users/schema.gql");

pub struct Query;

pub struct User {
  name: String,
}

impl QueryFields for Query {
  fn field_current_user(
    &self,
    executor: &juniper::Executor<'_, Context>,
  ) -> juniper::FieldResult<String> {
    let user = User {
      name: String::from("Ferris"),
    };

    Ok(format!("The current user is {}.", user.name))
  }
}

These modules can contain anything you want. There's just one thing I couldn't figure out.
How would you then "plop" their Query and Mutation types into the root query and mutation types of the root schema?
Like, for example in the root graphql module of the repo I linked:
use juniper;

mod hello;
mod users;

pub struct Context;
impl juniper::Context for Context {}

pub struct Query;

#[juniper::object(
    Context = Context,
)]
impl Query {
    // ..hello::Query
    // ..users::Query
    // ^ How do I put the contents of these here at compile time?
    // The idea is to have a nice folder structure separated by concern.
}

pub struct Mutation;

#[juniper::object(
    Context = Context,
)]
impl Mutation {}

pub type Schema = juniper::RootNode<'static, Query, Mutation>;

I think having this would enable us to make more scalable projects. I've already used this folder structure in a JavaScript-based GraphQL server in production and it's great. Really easy to add stuff to.

Basically, I'm trying to do this: https://graphql-modules.com/

This is currently not possible. See #182.
Maybe something could also be done on the juniper-from-schema side.
Closing as a duplicate.


Separate containers and custom feedback

In this repo's README you said:

the example allows the user to drag elements from left into right, and from right into left.

Is it possible to have it just from left into right? Like separate containers: one just for dragging, and one just for dropping?
Can you remove the feedback shadow on drop and write a custom feedback function?
Thanks

You should use moves and accepts for this.
dragula({
  moves: function (el, container, handle) {
   return container === left;
  },
  accepts: function accepts (el, target, source, sibling) {
    return target === right;
  }
});

When you're about to drop an element, it provides you a feedback of your element with a level of opacity.

What would you have it do instead?

So, what I'm trying to accomplish is this:

drag the element from left container to the right container (you already helped me with that, thanks!)
on over the right container, animate its properties (like height, width, bg color), and hide the transparent element
on drop hide the dropped element

You could accomplish the second with a CSS rule: .gu-mirror { display: none }.
As for the third one, you could just do:
drake.on('drop', function (el) {
  // hide el
});


Added 1 candidate with 1 node

added @dinoval:matrix.org with 1 node

@ironoa Element handle of the user was verified


added missing build step to access admin end

This pull request fixes the error  Error: ENOENT: no such file or directory, open '/srv/app/build/index.html' when strapi is run in production.
The cause of the error is the missing build step for the admin dashboard and the fix is to add the command
bash -c "strapi build && strapi start"

 Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.You have signed the CLA already but the status is still pending? Let us recheck it.

okay


[fix] restore functioning of --host CLI flag with no arg

Fixes https://github.com/sveltejs/kit/issues/2521. Also lets you specify these values in svelte.config.js, which wasn't working either

I'm going to go ahead and merge this and push it out since the bug seems to be affecting a fair number of people


Blinking Error when Using loadSpec()

Hi @mrin9.
I've been trying to use RapiDoc as open API YAML spec viewer with no luck for last few days. I'm using it with below code.
<template>
    <div>
        <rapi-doc style="height:100vh; width:100%" ref="specref" render-style="read" :spec-url="specurl">
        </rapi-doc>
    </div>
</template>

<script setup>
import { ref, onMounted } from "vue"
import { parse } from 'yaml'

const route = useRoute()
const specurl = ref('')
const specref = ref(null)
const apiPath = route.params.path.join('/')
const config = useRuntimeConfig()

specurl.value = apiPath

// const path = `/repositories/${apiPath}`
const path = `OAI/OpenAPI-Specification/main/examples/v3.0/api-with-examples.yaml`
let { data: spec, error: err } = await useAsyncData('spec', () => $fetch(path, {
    method: 'GET',
    baseURL: 'https://raw.githubusercontent.com',
    headers: {
    },
    params: {}
}))

onMounted(() => {
    let apispec = specref.value
    let data = parse(spec.value)
    apispec.loadSpec(data)
})
</script>

The API spec loads for about 1 sec and then redirected automatically to error page (unable to load spec) immediately after.

Stacks:

Nuxt 3 and VueJS
RapiDoc 9.3.4
NPM

Please help. Thanks in advance.

Won't it be simpler/easier to use a simple static html like this: https://rapidocweb.com/examples/api-demo.html ?

This isnt a RapiDoc's issue.


Clean up mock datasets and old versions

There are a lot of "dirty" releases of RiverBench and some mock datasets (e.g., example-triples) that should not make it to the first release. This needs to be cleaned up.

Done.


invalid_assignment false positive with mixed migrated files

Tools • Dart 2.9.0 (build 2.9.0-21.0.dev cfeb1d647a)
In the following code an invalid_assignment is triggeredfor value assignment.
//-------------------- a.dart

// @dart = 2.8
import 'b.dart';
class _BottomAppBarClipper extends CustomClipper<int> {}
void main() {
  // A value of type 'Listenable' can't be assigned to a variable of type 'CustomClipper<Path>'.
  // Try changing the type of the variable, or casting the right-hand type to 'CustomClipper<Path>'.
  CustomClipper<int> value = true ? _BottomAppBarClipper() : ShapeBorderClipper();
}

//-------------------- b.dart

// @dart = 2.9
abstract class Listenable {}
abstract class CustomClipper<T> extends Listenable {}
class ShapeBorderClipper extends CustomClipper<int> {}

/cc @scheglov

@leafpetersen Are there any spec changes necessary for Null Safety and LUB?
The spec says in 19.10.2 Least Upper Bounds says:

Here two sets of types are {CustomClipper<int*>*, Listenable*, Object*, _BottomAppBarClipper*} and {CustomClipper<int>, Listenable, Object, ShapeBorderClipper}. But CustomClipper<int*>* and CustomClipper<int> are not the same type, so we exclude it from the intersection.
The upper / lower bounds spec does not change rules for interface types.
When we started working on Null Safety in analyzer we found that nullability suffixes are problematic for LUB, so @stereotype441  suggested stripping them off, and apply after LUB, which makes sense because supertypes cannot be ?. But their type arguments can be. So, I think we need some clarification of LUB of interface types for Null Safety.

@eernstg @leafpetersen

I can't reproduce this in either the analyzer or the CFE.  Interestingly, if I remove the type annotation on value though, I do see an inferred type of Listenable in both implementations:
//-------------------- a.dart

// @dart = 2.8
import 'b.dart';
class _BottomAppBarClipper extends CustomClipper<int> {}
void main() {
  // A value of type 'Listenable' can't be assigned to a variable of type 'CustomClipper<Path>'.
  // Try changing the type of the variable, or casting the right-hand type to 'CustomClipper<Path>'.
  var value = true ? _BottomAppBarClipper() : ShapeBorderClipper();
  int z = value; // Error indicates value is inferred as Listenable
}

@scheglov @johnniwinther I'll spec up the expected behavior for LUB here, but I don't understand why I'm seeing different behavior with and without the type annotation.

Spec proposal here:  https://github.com/dart-lang/language/pull/1109 .

@scheglov wrote:

Here two sets of types are {CustomClipper<int*>*, Listenable*, Object*, _BottomAppBarClipper*}
and {CustomClipper<int>, Listenable, Object, ShapeBorderClipper}. But
CustomClipper<int*>* and CustomClipper<int> are not the same type, so we exclude it
from the intersection.

Prior to any computations on these sets, I think it's worth considering the elements: I would expect that a superinterface relation does not introduce the legacy marker * at the top level: For example, with legacy classes class A {} and class B extends A {}, B has A as a superinterface, not A*. In contrast, with legacy classes class C<X> {} and class D extends C<int> {}, D has C<int*> as a superinterface. The point is that if an expression has type B then it can also be considered to have type A, and this transition does not introduce a different nullability; but with type arguments in superinterfaces specified in legacy libraries, we must add * (because the legacy code can override inherited members without nullability related constraints).
This would make the two sets (with depths) {CustomClipper<int*>/2, Listenable/1, Object/0, _BottomAppBarClipper/3} and {CustomClipper<int>/2, Listenable/1, Object/0, ShapeBorderClipper/3}, which yields Listenable.
So isn't that what the analyzer actually does already?
In comments on https://github.com/dart-lang/language/pull/1109 I'm suggesting that we might want to reduce the sets at each depth (e.g., the set at depth 2: {CustomClipper<int>, CustomClipper<int*>}) using NNBD_TOP_MERGE where possible (yielding {CustomClipper<int>}), which would yield the LUB CustomClipper<int>.

@leafpetersen You need to disable implicit casts to get this error. In legacy libraries it is allowed by the spec.
analyzer:
  strong-mode:
    implicit-casts: false

@eernstg Yes, as I described in my first comment, we do remove top-level * suffixes from the super-interfaces. And yes, we get Listenable as the result of LUB now. But I guess this is not perfect :-)

we do remove top-level * suffixes

Right; I was thinking about not having them in the first place, cf. the text here:

A direct super-interface of a class defined in a legacy library (...)
has all generic arguments (...) marked as legacy types.

It doesn't say that the type which is the super-interface as a whole is marked as legacy, only its type arguments and down. But it shouldn't make much difference. ;)

This was fixed by adapting Least Upper Bound implementation for null safety, as requested in https://github.com/dart-lang/sdk/issues/42837.


Fix download action

Replace ImageISOURL to ImageBuildISOURL to show the download button for the images with an ISO URL

@matoval sorry for pulling the rug from under your feet. Can you move this change here:
https://github.com/RedHatInsights/edge-frontend/blob/master/src/Routes/ImageManager/ImageTable.js#L210-L219
and there:
https://github.com/RedHatInsights/edge-frontend/blob/master/src/Routes/ImageManager/ImageTable.js#L173-L198


UCX: applications do not work without charmrun/mpirun

Crash observed on application startup on golub:
charm/tests/charm++/simplearrayhello $ ./hello
------- Partition 0 Processor 0 Exiting: Called CmiAbort ------
Reason: UCX: UcxInitEps: runtime_kvs_put error failed: 5
[0] Stack Traceback:
  [0:0] _Z14CmiAbortHelperPKcS0_S0_ii+0x4d  [0x54800d]
  [0:1]   [0x54812d]
  [0:2] _Z8LrtsInitPiPPPcS_S_+0xd6f  [0x54d2bf]
  [0:3] ConverseInit+0x1ce  [0x54d8de]
  [0:4] charm_main+0x27  [0x48c307]
  [0:5] __libc_start_main+0xf5  [0x2abf9af0b495]
  [0:6]   [0x486360]

Running with Charmrun works fine:
charm/tests/charm++/simplearrayhello $ ./charmrun ./hello

Running on 1 processors:  ./hello
Charm++> Running in non-SMP mode: 1 processes (PEs)
Converse/Charm++ Commit ID: v6.9.0-535-g549280a73
[...]

I'm seeing the same error when trying to run namd@git-master built against<EMAIL_ADDRESS>with ucx back-end. (I tried compiling namd@git-master with charm++@git-master but that failed so I ended up building it with 6.10.1 version.) Adding a charmrun in front of the application does not solve the problem
charmrun +p16 namd2 stmv.namd ++mpiexec ++remote-shell mpiexec --oversubscribe </dev/null &> mpirun_$run

srun --mpi=pmix_v2 -N 2 -n 8 -c 2 charmrun namd2 stmv.namd </dev/null &> srun_$run

both fail with an error similar to the above but the srun case first prints the following statements a couple of times before crashing with the UcxInitEps error :
Running on 1 processors:  namd2 stmv.namd
charmrun>  /usr/bin/setarch x86_64 -R  mpirun -np 1  namd2 stmv.namd

What would the workaround for this case be ?
Hoping that this is the right place for this question as opposed to the namd mailing list, let me know if that's not the case and I'll post there instead.

I realized that this could be due to the fact that OpenMPI was built without PMIx support. When I built charm++ with the slurmPMI2 backend, everything worked as expected. Apologies for the unnecessary post on the issue tracker.
It might be good to have a check during charm++ configure that would raise a warning about the OpenMPI missing PMIx support when the ompipmix flag is passed.


Using official imagenet-1k

Checklist

I have searched related issues but cannot get the expected help.
I have read related documents and don't know what to do.

Describe the question you meet
I have download imagenet-1k and extract it to ILSVRC，here is my directory structure :
├── ILSVRC
│   ├── Annotations
│   │   └── CLS-LOC
│   ├── Data
│   │   └── CLS-LOC
│   └── ImageSets
│       └── CLS-LOC

I would like to use mmlcs/datastes/imagenet.py to train my model,  it seems that an data/imagenet/meta/val.txt is required.
After checking tutorial, I guess that val.txt should contain these lines:
ILSVRC2012_val_00000001.JPEG 65
ILSVRC2012_val_00000002.JPEG 970
ILSVRC2012_val_00000003.JPEG 230
ILSVRC2012_val_00000004.JPEG 809
ILSVRC2012_val_00000005.JPEG 516

Is there any script to convert it from ILSVRC ?

Would you please update it to README.md ?

I will add a link to this document.


Question about default type in addresses

Hi @pond,
The address complex type's type sub-attribute's default value is 'work'. This surprised me, as it is not a required sub-attribute. And no other complex types have defaults for their sub-attributes. In this commit some have been removed from other complex types. Could it be that the address complex type was missed and should also be cleared of this default?
Thanks.

Yeah, I mean I'm a bit worried that this might constitute a breaking change for some clients but it's an odd default and given the commit you reference - and thank you very much for digging that up, super useful! - it does look like something that was overlooked.

@s-andringa https://github.com/RIPAGlobal/scimitar/pull/92

This is now in v2.7.0.

...and v1.8.0.


Rebuild app

Rebuild app without WebView

[x] Login
[x] PIN
[x] Show tokens
[x] Biometric login
[x] Edit secrets (add, rename, delete)
[x] QR Code scanning
[ ] Account management
[ ] Sort secrets #30

Key PIN

Currently WIP
Legacy archive repository: https://github.com/ltheinrich/etopan_legacy

Legacy archive repository moved to https://github.com/etopa/etopan_legacy

Read-only Android app version available (0.0.5)

Read/Write Android app available (no account management yet)
Legacy archive repository deleted

Added QR Code scanning e734524bed1d58b4a5c0189e7a6c2e1dddb6ccb4


Value of type T is not assignable to T & U even when T extends U

At least in the case of U being a nonempty finite union of singleton types, it seems that T extending U does not imply that T is not assignable to T & U, even though every value of type T is also a value of type U.
However, the distributive conditional type T extends U ? T : never is considered assignable to U even though it should have the same set of values as T since we assume that T extends U.

TypeScript Version:  3.5.1 and 3.7.0-dev.20190907

Search Terms: enum intersection extends not reduced
Code
type A = 1 | 2;
function f<T extends A>(a: T): A & T  { return a; } // Error: Type '1' is not assignable to type '2'.
function g<T extends A>(a: T extends A ? T : never): A & T  { return a; } // OK

Expected behavior: Compiles.
Actual behavior: Does not compile.
Playground Link: https://www.typescriptlang.org/play/index.html#code/C4TwDgpgBAglC8UCMUA+UBMBuAUAMwFcA7AY2AEsB7IqPAHgBUoIAPYCIgEwGdYA+ABQBDAFxQGASjFwAZOKhQA3lABOEYARU0hWKAF8gA
Related Issues: https://github.com/microsoft/TypeScript/issues/28830
For context, I am attempting to write a function that takes a union tag and a payload and returns a matching new instance of one of the members of a tagged union.
Here is some further exploration in that direction: https://www.typescriptlang.org/play/index.html#code/C4TwDgpgBAglC8UCMUA+UBMBuAUAMwFcA7AY2AEsB7IqPAHgBUoIAPYCIgEwGdYA+ABQBDAFxQGASjFwAZOKhQA3lABOEYARU0hWKAF98xMlRoBzRszYce-YWKat2XXnAD88sUQgA3CCqmwUHJMSqrqmtq6BjjkROwqeEIk0ACySjgKCqLIuAax8YnJUABy6ZlQ2dg40YSkFNRQABYWjtYugtmSYgIpqMUSQUqdegrKahpaQ3pRhnUmUOQtVs62nZZONm4eUF6+-t29-YOKw6NhEzQn0-pQs8YNAFZLG+12Q-YjrSuHUO5Mnj4-AEen0BnITh8zuMIlMZrV7jQANbPNqBDr2daorb-HaA-bvcSfZY2EFHdwQhgjcGnAF7ULQyZXOFGeo0AA2KJWMHRBMpmJWpLBvJGv22uyBB1Bx1O9PCjKE1z0QA

You need to be careful with literal types because they don't always work the way that other types work. Consider whether you really want to union or intersect.
type A = 1 | 2;
function f1<T extends A>(a: T): A | T  { return a; }

type B = {n: 1 | 2};
function f2<T extends B>(b: T): B & T  { return b; }

TS Playground

I definitely want to intersect, since I want to narrow, not widen. In that example, A | T is just A. The second case isn't quite what I'm interested in, since I want to construct one of the two narrowed versions of B from a fixed value of n.

Got you: so there is a cascade of failures in type comparisons where TS looks at f and doesn't see that it should be equivalent to writing the longhand g.
type A = 1 | 2;
function f<T extends A>(a: T): A & T  { return a; }
/*
Type 'T' is not assignable to type '(1 & T) | (2 & T)'.
  Type 'A' is not assignable to type '(1 & T) | (2 & T)'.
    Type '1' is not assignable to type '(1 & T) | (2 & T)'.
      Type 'T' is not assignable to type '2 & T'.
        Type 'A' is not assignable to type '2 & T'.
          Type '1' is not assignable to type '2 & T'.
            Type '1' is not assignable to type '2'.
              Type 'T' is not assignable to type '2'.
                Type 'A' is not assignable to type '2'.
                  Type '1' is not assignable to type '2'.
*/

function g<T extends A>(a: T extends A ? T : never): A & T  { return a; }

This does not look right; even this form of g works:
type A = 1 | 2;
function g<T>(a: T extends A ? T : never): A & T  { return a; } // OK

Basically when attempting to assign T to the intersection it falls back to the constraint entirely, forgetting that it was generic; unfortunately, the type needs to be both generic and A to work.
The conditional type works because T in the true branch is actually a substitution type which is basically like an intersection T & A, so it precisely has the generic and concrete qualities you need.
I wonder if a type parameter can fall back to an intersection if it fails generally.

This is kind of confusing - the constraint already implies (a certain kind of) assignability from T to A, so returning T & A is a more confusing way of returning T.
@weswigham thoughts?

function f<T extends A>(a: T): A & T  { return a; } is
function f<T extends 1 | 2>(a: T): T & 1 | T & 2 { return a; } after distribution. T's constraint isn't assignable to that (it's missing T), and T itself isn't assignable (since those non-T components exist). We're missing a rule where we distribute a type paramter's constraint (should it be a union) onto the type parameter itself in order to handle scenarios like this one.


[Enhancement] Map-Data Cache

I haven't looked at the code and the last time i messed with map-rendering was years ago... but i guess the Pathing module only needs the map_rect and continent_rect data to render the markers on the (mini-)map - so wouldn't it make sense to cache this data locally? This way, API outages wouldn't affect the marker-rendering on the maps.
You could basically just store the neccessary data (map-id, map_rect, continent_rect) in a CSV/JSON file whenever you read it from the API (for example when a user enters a new map) and fall back to this file if the API isn't available. And by shipping a base CSV/JSON file with all current map-data you could even ensure that it would even work if the API is down and the player enters a map he never visited before.

This is now fixed in the latest version of the module. Thanks. 👍


Walkthroughs: Add a New Grid, Add a New Service

Type of change?

[ ] Bug fix
[ ] New feature
[x] Enhancement
[ ] Breaking change (breaks backward compatibility)

Description, Context, Motivation

Document how to add a new grid to the application (with sample code).
Document how to add a new service to the application (with sample code).
Some updates to the walk through for adding a new page.

Checklist:

[x] All tests passed
[x] The code follows the code style and conventions of this project
[x] The change requires a change to the documentation
[x] I have updated the documentation accordingly

This change is

Closing this request as it hasn't had a substantive review in over a week. By now, I have a lot more work done on top of this. I'll create a new PR when that work is ready for review. Its difficult to do small PRs for single tasks when it takes so long (and multiple reminders) to get a review.


Loading webview fails: Could not rewrite csp

For Visual Studio Codespaces we load a webview that holds the creation process information right after connecting to a Codespace, but the loading seems to be failing under VS Code insiders latest commit.

VSCode Version: 1.47.0-insider
-Commit: 84f52fe1c0124307046ac0f5443493cda946e60f
OS Version: Debian GNU/Linux

Steps to Reproduce:

Open online.visualstudio.com
Create and connect to a Codespace
The Creation Log tries to open a webview but fails to load the resource with the following error

Does this issue occur when all extensions are disabled?: Yes/No

Just checked and the markdown preview (also webview based) seems like it works. Is there a way to trigger the creation log view after you've already connected so that I can easily test this? Also, do I need to be on ppe?
The CSP error should be non-fatal but it could cause some code not to be loaded.

@mjbvz You might need to change your settings under Codespaces portal to insiders channel.
You also can load the webview after connecting to a Codespace by right-clicking on the environment in the tree view and select View Creation Log. You could also execute the command directly from the command palette.

Thanks. I think the csp problem is a red herring. The reason the content can't load seems to be:
ENOPRO: No file system provider found for resource 'file:///home/vsonline/.vscode-remote/extensions/ms-vsonline.vsonline-1.0.2361/out/bundle/splash-bundle.js'
    at b.withProvider (https://online-ppe.core.vsengsaas.visualstudio.com/workbench-page/web-standalone/insider-84f52fe/out/vs/workbench/workbench.web.api.js:1630:299)
    at async b.withReadProvider (https://online-ppe.core.vsengsaas.visualstudio.com/workbench-page/web-standalone/insider-84f52fe/out/vs/workbench/workbench.web.api.js:1630:418)
    at async b.readFile (https://online-ppe.core.vsengsaas.visualstudio.com/workbench-page/web-standalone/insider-84f52fe/out/vs/workbench/workbench.web.api.js:1634:405)
    at async Object.t.loadLocalResource (https://online-ppe.core.vsengsaas.visualstudio.com/workbench-page/web-standalone/insider-84f52fe/out/vs/workbench/workbench.web.api.js:2791:625)
    at async f.loadResource (https://online-ppe.core.vsengsaas.visualstudio.com/workbench-page/web-standalone/insider-84f52fe/out/vs/workbench/workbench.web.api.js:3820:781)
splash-bundle.js:1 Failed to load resource: the server responded with a status of 404 ()
splash-bundle.js:1 Failed to load resource: the server responded with a status of 404 ()

I think 35c339382828c093a0e562d10d248cb65e5f1188 should fix this but I cannot test in VSO. @osortega Can you please pick up the latest VS code bits from master and see if it fixes the problem?

Closing as it sounds like it is fixed for VSO
Also the CSP error should now be fixed. Let me know if you see any further problems


eslint sort-import vs dprint sort imports

I am using version 0.44.0 and eslint sort-import config:
    "sort-imports": [
      "error",
      {
        "ignoreDeclarationSort": true,
        "allowSeparatedGroups": true
      }
    ],

Does this sort:
import { StubResizeObserver, fetchHTML, stubResizeObserver } from '../../test_utils/test-helper.js';

Meanwhile dprint does:
import { fetchHTML, StubResizeObserver, stubResizeObserver } from '../../test_utils/test-helper.js';

I tried using dprint config like:
  "typescript": {
    "lineWidth": 120,
    "quoteStyle": "preferSingle",
    "binaryExpression.operatorPosition": "sameLine",
    "typeLiteral.separatorKind": "comma",
    "module.sortImportDeclarations": "caseSensitive",
    "module.sortExportDeclarations": "caseSensitive"
  },
  "plugins": [
    "https://plugins.dprint.dev/typescript-0.88.7.wasm"
  ]

But it always does a case insensitive sort. I am trying to match eslint and dprint together to make the DX nicer, any recommendations?

Use:
{
  "exportDeclaration.sortNamedExports": "caseSensitive",
  "importDeclaration.sortNamedImports": "caseSensitive"
}

Then you can remove the eslint rule as it's no longer necessary because the formatter handles it for you now.
Side note: module.sortImportDeclarations is for sorting individual import declarations in a module rather than the named imports within an import declaration.
https://dprint.dev/playground/#code/JYWwDg9gTgLgBAbzgZRgVwEYCUCmBnYALxwHkM8coA3SgGjgDMcYBjACwAkAVAWQBl6edNnxFS5SjShwAvoygQQcAOQA6VQHp1GmPhgB9NDGAAbPDr0BaNjhNhKqgFZ5lAbiA/config/N4WAUABBBECmAeAHA9gJwC4BFYGMA2AhqgegJbIB2AdAM5roByBAtrACYCiS9N0AXDBwEasAMqwKNUmQBusaABpwUaKWYoM2fERLlqdDE1ZsAkup79BwsRKmz54AL7ggA/plugin/typescript

That worked, thank you! I didn't see this Config page at first! Thank you https://dprint.dev/plugins/typescript/config/

For what it’s worth, when I first discovered dprint, I struggled to find individual plugin config docs as well. So maybe something could  be improved about the website

Hey, I just bumped in a similar issue, I configured dprint, but it's not enforcing the order for types, am I missing something in here?


Resource show fails on resources with parentheses in the name

Description
Command az resource show with a resource name that includes parentheses returns "--resource-type was unexpected at this time" in PowerShell 5.0 console.
Repro Steps

Open PowerShell console
Run az resource show -g "TestGroup" --name "ResourceName(NestedForSomeReason)" --resource-type "Microsoft.OperationsManagement/solutions" (resource type is example)

Result:
--resource-type was unexpected at this time.
C:\WINDOWS\system32>  "C:\Program Files (x86)\Microsoft SDKs\Azure\CLI2\wbin\\..\python.exe" -Im azure.cli resource show
 -g TestGroup --name ResourceName(NestedForSomeReason) --resource-type Microsoft.OperationsManagement/solutions

Remarks
Parentheses are currently allowed (as far as I know) in resource names, so the CLI should be able to handle them. I know that the parentheses should probably be escaped somehow, but the CLI does not allow for parentheses to be escaped. Neither PowerShell escaping with --name "ResourceName`(NestedForSomeReason`)" nor python escaping with --name "ResourceName\(NestedForSomeReason\)" works.

Environment summary
Install Method: How did you install the CLI? (e.g. pip, interactive script, apt-get, Docker, MSI, nightly)
Answer here: MSI
CLI Version: What version of the CLI and modules are installed? (Use az --version)
Answer here: 2.0.12
OS Version: What OS and version are you using?
Answer here: Windows 10 Enterprise
Shell Type: What shell are you using? (e.g. bash, cmd.exe, Bash on Windows)
Answer here: PowerShell 5.1.14

The following syntaxes work:
CMD.exe
az resource show -n name(stuff)
bash
az resource show -n 'name(stuff)'
Powershell is not an actively supported shell for CLI 2.0. However, you could try:
az resource show --% -n name(stuff)
The --% is supposed to disable Powershell's inbuilt parsing for anything after the escape sequence.

Thank you for the information. I appreciate knowing PowerShell is not currently supported. Unfortunately, using --% did not work, but I was able to work around the issue with
cmd.exe /c "az resource show -g `"TestGroup`" --name `"ResourceName(NestedForSomeReason)`" --resource-type `"Microsoft.OperationsManagement/solutions`"" | Out-String

Hey @tjprescott, do you know if the supportability of PowerShell as the shell have changed in the past 5 years or so?

@sassdawe I'm no longer on the CLI team so I don't know that answer. @jiasli could you answer this?

PowerShell is supported now.
You have to quote ResourceName(NestedForSomeReason) twice, one for PowerShell, one for CMD:
> az group --debug --name '"ResourceName(NestedForSomeReason)"'
cli.knack.cli: Command arguments: ['group', '--debug', '--name', 'ResourceName(NestedForSomeReason)']

See:

https://github.com/Azure/azure-cli/blob/dev/doc/quoting-issues-with-powershell.md
https://learn.microsoft.com/en-us/cli/azure/use-azure-cli-successfully#use-quotation-marks-in-parameters


Show up Error "Undefined class constant 'App\Providers\RouteServiceProvider::HOME'"

After i did "php artisan ui:auth". This error shows up when i access /login.

In your app/RouteServiceProvider.php you can add that. Take a look at the default laravel/laravel on github For your specific Laravel version for an example


Switch surrounding pair implementation to be text-based

If we are in a lang without syntax tree, use text-based
If we are in a string or comment within a language with a syntax tree, start with text-based, but switch to parse tree if no delimiters found within current string / comment

Bonus: Treat a sequence of comments or strings as a single comment / string from this perspective

Impl for text-based is to just walk left from char, keeping track of what you see and walking over pairs

Why do we want to switch to this method for languages with syntax tree?

The main driver for me was being able to select inside brackets within a string, esp eg in talon capture definitions.  I could see an alternative where we first run the text-based version if we're within a string or comment, then switch to syntax tree version if we don't find delimiters within the given string / comment.  But @AndreasArvidsson may have other thoughts

Fwiw one disadvantage of text-based approach in languages with syntax tree is that it might be tougher to support pair types where we know it's a pair because of its node type, eg for html tags

Combining text with parse tree sounds good

ok @maciejklimek your code lives to see another day 😊

I think a good general rule is to have a wide choice of different modifiers available at the backend(vscode side),
provide sensible default at the talon side, but also make it configurable if the user wishes to do a slightly different thing.
In this case, this would mean having a different modifier or and argument to an existing modifier that would implement the new behaviour.
Currently though, I think configuring cursorless on the talon side is not that easy because it requires one to fork the code, or do some weird stuff like sed and the code is changing so fast that forking is not good.
what do you think?

Not sure I totally follow, but would a VSCode extension setting not make sense here? Can you give an example of the type of configuration you're after?

I wasn't sure if the behavior in the second case(the one with the string),  would be always preferred.
I imagine that one could prefer to take the syntax tree based matching, instead of the text one in the case with the string.
This is probably a very infrequent case,  but it seems to me we could support even this case,
with very low cost.
I think that having this as parameter of the request, is better than having it as the extension setting in vscode,
cause it is more flexible.
But this case is infrequent enough, that i am also fine with the version you proposed :)
I really need this text version in these talon files, I often want to clear the strings with clear maching

I think we can start with one behavior and if people find that they have problem with it we can always add a setting or an additional word/modifier later. Does that work for every one?

👍

works for me.  fwiw we could potentially get around this one with #124, or by making it so that the scope finder code will expand again if you currently have something of that scope type selected.  With the latter you'd just repeat the command to get the bigger scope

Ok I believe we should tackle #311 first, because that will then automatically handle the tiebreak logic when your cursor is sitting on a delimiter


Speed up codegen

cargo codegen takes around 6s to run. Most of it is running black. We could probably speed it up by running black only once, for all the generated code, instead of once for each generated file.
Probably same for cargo fmt
You can profile the codegen with cargo codegen --profile

Related: ruff's formatter has reached alpha and beta should follow soon:

https://github.com/astral-sh/ruff/milestone/4
https://github.com/astral-sh/ruff/milestone/5

I tried out ruff format in alpha, and it still has some problems, so we'll wait for beta.
cargo fmt is now the bottleneck. Running it once for each file is about as fast as running it once for a whole folder, so the same optimization as in #3368 won't work there.
Until we get ruff format, there is very little we can do right now to speed up codegen, except for generating less code

We're using ruff format since a few months, and it's great, but now cargo fmt is the bottleneck (by far). Hard to speed that up, except for generating less code.

I think we can close this then. We wanted to reduce the amount of generated code for a while but that's orthogonal to what we wrote here


Add the ability to pass absolute paths in through the cli.

Hello, thank you for all of your work on this excellent tool.
I've run into a use case where I would like to use css-ast-diff to process a large batch of diffs that may potentially span multiple drives (on windows).
This change would allow users to pass an "--absolute-paths" flag through the CLI and the filenames will not be rewritten relative to the current directory.
These changes seem to be working well for me, and I figured I would see if you would like to pull them in to the main project.

This is great, thanks so much for contributing!