Support registering file watchers statically on initialize.

I'm trying to understand the intention of the spec around 'didChangeWatchedFiles'. I think I understand the behavior for when 'dynamicRegistration' flag is set to  'true' in ClientCapabilities. In a nutshel, in that case, the server can register dynamically with specific glob patterns the server is interested in.
However, if 'dynamicRegistration' is set to false. What does that mean then?
Following along with other 'static' regustrations, I was expecting there would be a something in ServerCapabilities (returned by server initialization) where a server could somehow declare the patterns of files its interested in. But there doesn't seem to be anything like that.
So that brings me to my question, how does a server, in the static case, declare which file changes the server is interested in?

Good point. You can't right now. In a first implementation I made that a configuration in the client library.
But it would be quite straight forward to add it. Code wise here: https://github.com/Microsoft/vscode-languageserver-node/blob/dbaeumer/declarationSupport/client/src/client.ts#L1148
The DidChangeWatchedFilesRegistrationOptions can be reused for the server caoabilities.
Interested in providing a PR?

I clarified this as suggested. Still keeping this open to add static file watching configuration.

It makes sense for "generic" (not language-specific) clients to need it in order to decide which server to talk to when opening files/folders - I assume this is also essential for multiple servers with overlapping functionality co-existing.
IMO though the server typically holds the most knowledge about the language and should know better what extensions are actually relevant also know this may differ between language versions.
So I'm thinking if the server is allowed to "announce" its own watchers, the client should always honour these and only have the option to reduce the list, but not expand.
i.e. it wouldn't make much sense for a client to send *.py changes to a server which only supports *.go
This assumes clients implement the filtering correctly and run paths first through client's and then server's glob patterns, so that e.g. if client registers for *.*, server supports *.go and main.go changes, the notification still goes through.


fix:[PLG-627] Data integrity fix for GCP asset types

Description

append projectId(accountId) to the docId for gcp asset types to make it unique. Assets that need changes are Bigquery dataset, Bigquery table, dataproc and VM.
removed a duplicate insert in target table for dataproc
refer jira for more info: https://paladincloud.atlassian.net/browse/PLG-627

Problem
for some assets, the asset name is used as document Id in ES which may lead to data integrity issues, because asset name is not unique across multiple accounts
Solution
Make the doc Id unique by appending accountId to it
Fixes # (issue if any)
Type of change
Please delete options that are not relevant.

[X] Bug fix (non-breaking change which fixes an issue)
[ ] New feature (non-breaking change which adds functionality)
[ ] Chore (no code changes)
[ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
[ ] This change requires a documentation update

How Has This Been Tested?
Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also
list any relevant details for your test configuration

[ ] run the db script to update the target configs
[ ] run the collector and shipper.
[ ] verify the docIds of these assets in ES
[ ] test the accountId filter added for gcp VM policies: run the gcp vm policy rules and verify violations for VM still exists

Tested screenshots:

Checklist:

[ ] My code follows the style guidelines of this project
[ ] My commit message/PR follows the contribution guidelines of this project
[ ] I have performed a self-review of my code
[ ] I have commented my code, particularly in hard-to-understand areas
[ ] I have added tests that prove my fix is effective or that my feature works
[ ] New and existing unit tests pass locally with my changes

Other Information:
List any documentation updates that are needed for the Wiki

Summary by CodeRabbit

New Features

Enhanced the targetConfig for various cloud resources, allowing for more detailed identification with additional keys such as projectId, accountid, and region.

Impact

Improvements provide richer metadata for querying and managing cloud resources, leading to better resource management across platforms.

@ershad-paladin quick observation, it is better we add target type to _docid as well. Some times you may have the same resource name across asset types in the same account. We do the same for AWS. Please check.

@ershad-paladin quick observation, it is better we add target type to _docid as well. Some times you may have the same resource name across asset types in the same account. We do the same for AWS. Please check.

thanks @santhosh-challa, thats a valid case and I have addressed that now


MessagePassing.propagate() eats up size named argument.

Following the tutorial, the following code doesn't work and complains KeyError: size when executing return self.propagate(edge_index, x=x, size=(x.size(0), x.size(0))).
import torch
from torch_geometric.nn import MessagePassing
from torch_geometric.utils import add_self_loops, degree

class GCNConv(MessagePassing):
    def __init__(self, in_channels, out_channels):
        super(GCNConv, self).__init__(aggr='add') # "Add" aggregation.
        self.lin = torch.nn.Linear(in_channels, out_channels)

    def forward(self, x, edge_index):
        # x has shape [N, in_channels]
        # edge_index has shape [2, E]

        # Step 1: Add self-loops to the adjacency matrix.
        edge_index = add_self_loops(edge_index, num_nodes=x.size(0))

        # Step 2: Linearly transform node feature matrix.
        x = self.lin(x)

        # Step 3-5: Start propagating messages.
        return self.propagate(edge_index, x=x, size=(x.size(0), x.size(0)))

    def message(self, x_j, edge_index, size):
        # x_j has shape [E, out_channels]

        # Step 3: Normalize node features.
        row, col = edge_index
        deg = degree(row, size[0], dtype=x_j.dtype)
        deg_inv_sqrt = deg.pow(-0.5)
        norm = deg_inv_sqrt[row] * deg_inv_sqrt[col]

        return norm.view(-1, 1) * x_j

    def update(self, aggr_out):
        # aggr_out has shape [N, out_channels]

        # Step 5: Return new node embeddings.
        return aggr_out

The reason is that in https://github.com/rusty1s/pytorch_geometric/blob/master/torch_geometric/nn/conv/message_passing.py#L80, **kwargs doesn't include size key, which is a separate named argument in the argument list.

Thank you! I updated the order of arguments in the documentation.

The updated GCNConv tutorial using the following code (I just copied it from the documentation) still errors out for me (KeyError: 'size'):
import torch
from torch_geometric.nn import MessagePassing
from torch_geometric.utils import add_self_loops, degree

class GCNConv(MessagePassing):
    def __init__(self, in_channels, out_channels):
        super(GCNConv, self).__init__(aggr='add') # "Add" aggregation.
        self.lin = torch.nn.Linear(in_channels, out_channels)

    def forward(self, x, edge_index):
        # x has shape [N, in_channels]
        # edge_index has shape [2, E]

        # Step 1: Add self-loops to the adjacency matrix.
        edge_index = add_self_loops(edge_index, num_nodes=x.size(0))

        # Step 2: Linearly transform node feature matrix.
        x = self.lin(x)

        # Step 3-5: Start propagating messages.
        return self.propagate(edge_index, size=(x.size(0), x.size(0)), x=x)

    def message(self, x_j, edge_index, size):
        # x_j has shape [E, out_channels]

        # Step 3: Normalize node features.
        row, col = edge_index
        deg = degree(row, size[0], dtype=x_j.dtype)
        deg_inv_sqrt = deg.pow(-0.5)
        norm = deg_inv_sqrt[row] * deg_inv_sqrt[col]

        return norm.view(-1, 1) * x_j

    def update(self, aggr_out):
        # aggr_out has shape [N, out_channels]

        # Step 5: Return new node embeddings.
        return aggr_out

Here's a simple bit of code to reproduce the error:
import numpy as np

conv = GCNConv(16, 32)

# Simple random node features
x = torch.zeros((5, 16), dtype=torch.float)
x[np.arange(5), np.random.randint(0, 16, 5)] = 1

# Generate simple undirected edge index
edge_unit = torch.tensor([[0, 1],
                          [1, 0]], dtype=torch.long)
edge_index = torch.cat(tuple([i + edge_unit for i in range(5 - 1)]), dim=1)

# Reproduce KeyError: 'size'
x = conv(x, edge_index)

Oops, this is really embarrassing. Pulling from master resolves this issue. In addition, the example is now fully tested. Sorry for the inconvenience!


How can I download the generated QR code?

It creates a PNG image; download it like you would any other image.


Doesn't work on IE11

One of the dependencies https://github.com/airbnb/react-with-styles-interface-css , uses Object.assign that is not supported by IE11. I have opened a PR https://github.com/airbnb/react-with-styles-interface-css/pull/15 to fix that.
I know this can be done by changing webpack config and polyfilling but I think this would be a better fix.

Indeed, react-dates requires using https://npmjs.com/airbnb-browser-shims or the equivalent to ensure that all browsers that can be supported are.
Thanks for the PR - anything we can fix, we certainly will, but running an app without polyfills isn’t a good idea anyways.

@ljharb SingleDatePicker, unfortunately, does not work in IE 11.
I tried in my app with https://npmjs.com/airbnb-browser-shims and even on your storybook: http://airbnb.io/react-dates/?selectedKind=SingleDatePicker (SDP)&selectedStory=default&full=0&addons=1&stories=1&panelRight=0&addonPanel=storybook%2Factions%2Factions-panel
After click on Calendar the Input loses focus and calendar is closed. Due to that, you can't select a date nor switch a month.

Is there anyway around this?  I'd be suprised if airbnb didn't make it work with IE11

I believe this is a bug fixed in master but unreleased (and thus unpublished to storybook).
As to the original issue, that’s been closed by #356.


ISIS3.8 Data Area and ASP Examples

Historically, the ISIS data has never been kept under explicit version control. New kernels have been added and/or moved as needed. We are actively working to get the data area under version control #531, #3239, and #3282.
With the release of ISIS 3.8.1, we have updated the ISIS data area. Here is a link to the PR where the issues encountered and fixes are enumerated. Using an ISIS version < 3.8.0 with the new data area will result in issues for:
Known Applications Impacted:
(Certain Mars calibration programs)

mical
moccal
mocproc
ctxcal
hical
hicalbeta
hicalproc
thmbasemap1
thmproc

Known Sensor Models Impacted:

CTX
MOC
HiRISE
THEMIS
Anything else ISIS supported that uses SPICE and collected Mars data

So, this line in your example will fail if the user is keeping up to date on their data, but not on their ISIS version (or any other permutation where the data != code).
As I said above, we are working on versioning the data too, but in the short term, this is likely to be an issue that we all see coming in from users.

Thanks, this is good to know. It does make sense that old code can't handle new data. Hopefully when the dust settles down on the many changes ISIS undergoes the coupling need not be so tight, so say new software can still read old data, or at least give a meaningful error message. I will keep this in mind.

When ASP 2.7.0 gets released, it will be compiled against a more recent ISIS release, and a more recent reference ISIS data area.  We only make ASP releases approximately annually, and with the rapid rate of change in ISIS, we're just going to be behind.
However, as Jay indicates, the problem isn't really related to how fast the ISIS codebase is moving, but the fact that the ISIS data area is not versioned.  This is a known issue for ISIS, and something that they are working to attempt to get solved.


#P07. As Participant, I would like to view my team's information.

Visible items should only include:

Team Name
Slack Display Names of Members

@AMcCall22 please :)

@AMcCall22
I'm just checking-in with this issue, since it's still "Open".
How are you and @stephy getting on with progress, or has this been sorted via a different PR now?

Hi Tim, I have arranged with Stephy to take the PR on from here as we were going to combine them. Apologies  I wasn’t able to complete (did make a start and passed on the detail to her. I also let Stefan know) but I have to focus on my MS4 at the moment... Ali Sent from Mail for Windows 10 From: Tim NelsonSent: 09 November 2020 13:02To: Code-Institute-Community/ci-hackathon-appCc: AMcCall22; MentionSubject: Re: [Code-Institute-Community/ci-hackathon-app] #P07. As Participant, I would like to view my team's information. (#24) @AMcCall22I'm just checking-in with this issue, since it's still "Open".How are you and @stephy getting on with progress, or has this been sorted via a different PR now?—You are receiving this because you were mentioned.Reply to this email directly, view it on GitHub, or unsubscribe.


Add quarantine filter in customer grid

You need to upgrade the node version from 14 to 16 in CI


Thanks!


Can't even start from scratch

Describe the bug
After hours of trying to fix errors, I asked for the Bolt thing to start from scratch. It can't even make it to step 1.
[plugin:vite:import-analysis] Failed to resolve import "./components/Dashboard" from "src/App.tsx". Does the file exist?
/home/project/src/App.tsx:4:26
17 |  import { QueryClient, QueryClientProvider } from "@tanstack/react-query";
18 |  import { Layout } from "./components/Layout";
19 |  import { Dashboard } from "./components/Dashboard";
|                             ^
20 |  const queryClient = new QueryClient();
21 |  function App() {
at TransformPluginContext._formatError (file:///home/project/node_modules/vite/dist/node/chunks/dep-CDnG8rE7.js:49242:41)
at TransformPluginContext.error (file:///home/project/node_modules/vite/dist/node/chunks/dep-CDnG8rE7.js:49237:16)
at normalizeUrl (file:///home/project/node_modules/vite/dist/node/chunks/dep-CDnG8rE7.js:64033:23)
at async eval (file:///home/project/node_modules/vite/dist/node/chunks/dep-CDnG8rE7.js:64165:39)
at async TransformPluginContext.transform (file:///home/project/node_modules/vite/dist/node/chunks/dep-CDnG8rE7.js:64092:7)
at async PluginContainer.transform (file:///home/project/node_modules/vite/dist/node/chunks/dep-CDnG8rE7.js:49083:18)
at async loadAndTransform (file:///home/project/node_modules/vite/dist/node/chunks/dep-CDnG8rE7.js:51916:27)
at async viteTransformMiddleware (file:///home/project/node_modules/vite/dist/node/chunks/dep-CDnG8rE7.js:61873:24
Click outside, press Esc key, or fix the code to dismiss.
You can also disable this overlay by setting server.hmr.overlay to false in vite.config.ts.
Link to the Bolt URL that caused the error
https://bolt.new/~/sb1-viml4m
Steps to reproduce
Ask to start from scratch.
It fails.
Expected behavior
Build something useful.
Screen Recording / Screenshot
No response
Platform
Browser name = Chrome
Full version = <IP_ADDRESS>
Major version = 130
navigator.appName = Netscape
navigator.userAgent = Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/<IP_ADDRESS> Safari/537.36
performance.memory = {
  "totalJSHeapSize": 128658583,
  "usedJSHeapSize": 124331571,
  "jsHeapSizeLimit":<PHONE_NUMBER>
}
Username = prescott
Chat ID = 7e1bcdc73e7d

Additional context
No response

Hi @prescott,
If the model is failing to start the project over, it may be necessary to open a new Bolt chat and create a new project. There are some programming challenges that AI can not yet solve automatically. When the AI repeatedly fails on fixing an issue, manual intervention may be required to avoid excessive token consumption. This page here has some useful information for leveraging the AI most effectively. Hope this helps!


OS X - Add default keyboard shortcuts to hide/minimize editor window?

I really like hiding windows in OS X and use it all the time (shortcut cmd+h).
Someone already might have thought about implementing it because there is a function call to createMenuBar in the OS X code (see https://github.com/godotengine/godot/blob/master/platform/osx/os_osx.mm#L1710). But it is not implemented for some reason.
I fiddled a bit around and implemented a menu bar and everything was working ... mostly. A problem i encountered is that by adding the default shortcuts a developer would no longer be able to set these as input for their game in the project settings -> input map window. But then again the same goes for other system wide shortcuts (e.g. CMD+ALT+D to hide the dock).
I wanted to know if the menu bar is something that could/should be implemented into Godot.

Closed due to being implemented in PR #9812