403 forbidden post batch_id

Access Forbidden
Can not get batch ID throw api, response code is 403. Due some investigation, we found this ticket: https://github.com/sendgrid/sendgrid-csharp/issues/185. However it was not helpfull, since we have only one account and we pretty sure we use admin account.
Steps to Reproduce
$sendGrid = $this->getNewSendGrid();
$response = $sendGrid->client->mail()->batch()->post();

class SendGrid\Response#98 (3) {
  public $_status_code =>
  int(403)
  public $_body =>
  string(56) "{"errors":[{"field":null,"message":"access forbidden"}]}"
  public $_headers =>
  string(648) "HTTP/1.1 403 FORBIDDEN
Server: nginx
Date: Thu, 14 Jul 2016 03:37:02 GMT
Content-Type: application/json
Content-Length: 56
Connection: keep-alive
Access-Control-Allow-Methods: POST, OPTIONS
Access-Control-Max-Age: 21600
Access-Control-Expose-Headers: Link
Access-Control-Allow-Origin: *
Access-Control-Allow-Headers: AUTHORIZATION, Content-Type, On-behalf-of, x-sg-elas-acl
Content-Security-Policy: default-src https://api.sendgrid.com; frame-src 'none'; object-src 'none'
X-Content-Type-Options: nos"...
}

Technical details:

sendgrid-php Version: master (latest commit: [commit number])
PHP Version: 5.x

Hi @altairdeark,
Our support team can help with this issue: https://support.sendgrid.com
Thanks!

I have a API key with all the possible permissions and I got "access frobidden" when posting to the endpoint "mail/batch". I'm using CURL.
I haven't found an answer in the documentation/support forum

@gsusI,
Please open up a ticket with https://support.sendgrid.com. They will be able to dig deeper into your account and figure out what is going on with your key.

Request #716584

The issue for me seems to be that not all the permissions allowed can be managed through the UI.

We encountered this as well. It looks like a systematic problem, rather than case-specific.

@oytuntez,
Can you also submit a support ticket?

Did that as well, thank you.

Oytun Tez
*M O T A W O R D *- The World's Fastest Human Translation Platform.
J S O N - L A N G - JSON specification for localization file exchange.
I AM A FACT - Entrepreneurification!
On Thu, Jul 28, 2016 at 5:55 PM, Elmer Thomas<EMAIL_ADDRESS>wrote:

@oytuntez https://github.com/oytuntez,
Can you also submit a support ticket?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/sendgrid/sendgrid-php/issues/263#issuecomment-236037133,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AAoE--SxldtGtya7xai0fAbr32exJwEdks5qaSVFgaJpZM4JMFXp
.

I have to publicize this, because I don't understand why 1) this is not documented, 2) we are being redirected to Support even though this is probably a known defect.
Here is the support response:

Hi,
Thank you for contacting us.
Unfortunately, when creating an API key from Sendgrid UI it doesn't have all the detailed permissions. The required scope of this call is not an automatic one, so it needs to be added via an API call. I recommend you to create a new API key via API V3 with Basic Authentication and add more permissions to it. You can also update an already created API key.
Create API Key: POST https://api.sendgrid.com/v3/api_keys
Update API Key: PUT https://api.sendgrid.com/v3/api_keys/{api_key_id}
Here you can find more API calls related to API Key and also all the permissions that you add to it:
API key
Post
Update
Permisions
Please note that you can't add General permissions and Billing Permissions to the same API key.
Please let me know if it helps and if I can help you with anything else.
Best regards,

I cannot find any information about using Basic Auth to authenticate.  As far as I can tell, the v3 API only accepts api_key for authentication.  Could you point me to an example of how to use Basic Auth.

@gmhawash,
Yes, the v3 API only accepts an API Key for authentication.
Why do you need Basic Auth?
Are you having trouble with your API Key? If so, please reach out to https://support.sendgrid.com and they can help.
Thanks!

I want to create subusers and apikeys for them from the API.
My root/parent API Keys do not have the permission to create subusers or apikeys or to change permissions on the API key and there is no way to assign them in the UI.
So, I first need to give the parent API key these permissions, and in order to do so, I need to login with username/password using Basic Auth, change the API key permissions, and use the API key from that point forward.

@gmhawash,
Please reach out to our support team at https://support.sendgrid.com. I'm hoping they can help you work through a solution that would fit your needs.

API v3 does accept Basic Auth.
Basically you need to set a header with something like:
"Authorization: Basic " . base64_encode("$username:$password")
Where $username & $password belong to the main user.
Including that header you will be able to use the endpoint api_keys/ to set the permissions

And @oytuntez is very right, it should be documented properly to avoid this thread (and its duplicates) to keep growing.

Thanks for the feedback @gsusI, I will put in a request with our documentation team.

I would take it a bit further and rather than having to force the header for basic auth, make Basic Auth authentication as a first class citizen (like API key), and allow for passing in username and password combo or an api_key.

@gsusI Thanks a lot for saving my time. Sendgrid's documentation is definitely flawed.

In an effort to be helpful, here's what I just learned from connecting the dots across several SendGrid documentation pages, the most helpeful of which was this one.

Update my API key permissions

NOTE: This can only be done via the API. It is not possible to do this through the web app.
NOTE: This is not a PATCH request, but rather a PUT. This meant, I needed to first GET the existing scopes and then append the new ones. Otherwise, it overwrites all the existing keys. Side note: whoa! It would be nice to support PATCH here, or make the dangerzone more clear in the docs.
NOTE: This must be done with your username and password. It cannot be done using an API auth key. Username and password are passed as a base64 encoded string in the header.

Get the base64 encoding: echo -n "<username>:<password>" | openssl base64
Now you can send it in your header like this, curl -H "Authorization: $base64creds"

NOTE: You must send the name of the API key, even if it already has one.
Copy the batch scope permissions and include them in your PUT web request to /v3/api_keys/<your key>
Finally, you're ready to make the web request to update your API key's scope.

Your full API key is a three part value separated by dots. The {your_api_key} value is the second part. I.e. do not use the name and do not send the entire key value.

Now you can finally make the web request to generate a batch id!

See an example on the curl examples page

@papaben I guess you meant to write "it overwrites all the existing scopes" instead of "it overwrites all the existing keys", didn't you?

Anyone coming here because of the 403: FORBIDDEN error when creating a batch ID using the client.request method should know that (as of 2021) you can set teh required permissions in the UI.
Mail Send > Scheduled Sends
https://app.sendgrid.com/settings/api_keys


Frameworks to investigate where to position

semaphoreui - Started as an AWX alternative, morphed into AWX alternative with support for terraform, opentofu, bash, powershell, pulumi, docker, python
netpalm - ReST based network device broker

let me get on that


pull request for e2e test at 01/07/2017 20:15:09

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


feat: allow module safe queries in ICA

Description

closes: #5784
Commit Message / Changelog Entry
feat: allow module safe queries in ICA

see the guidelines for commit messages. (view raw markdown for examples)

Before we can merge this PR, please make sure that all the following items have been
checked off. If any of the checklist items are not applicable, please leave them but
write a little note why.

[ ] Targeted PR against the correct branch (see CONTRIBUTING.md).
[ ] Linked to Github issue with discussion and accepted design OR link to spec that describes this work.
[ ] Code follows the module structure standards and Go style guide.
[ ] Wrote unit and integration tests.
[ ] Updated relevant documentation (docs/) or specification (x/<module>/spec/).
[ ] Added relevant godoc comments.
[ ] Provide a commit message to be used for the changelog entry in the PR description for review.
[ ] Re-reviewed Files changed in the Github PR explorer.
[ ] Review Codecov Report in the comment section below once CI passes.

Summary by CodeRabbit

New Features

Implemented a safe query mechanism for interchain accounts, including a whitelist of safe queries.
Added new RPC handler for managing safe module queries in interchain account transactions.

Tests

Added comprehensive tests for new functionalities, including querying interchain accounts and safe module query handling.

Documentation

Updated codec registration and function signatures to support new interchain account querying and transaction execution features.

Codecov Report
Attention: 35 lines in your changes are missing coverage. Please review.

Comparison is base (310a4bd) 81.49% compared to head (578d006) 81.45%.
Report is 27 commits behind head on main.

Additional details and impacted files

@@            Coverage Diff             @@
##             main    #5785      +/-   ##
==========================================
- Coverage   81.49%   81.45%   -0.04%
==========================================
  Files         199      200       +1
  Lines       15203    15246      +43
==========================================
+ Hits        12389    12419      +30
- Misses       2348     2354       +6
- Partials      466      473       +7

Files
Coverage Δ

.../apps/27-interchain-accounts/host/keeper/keeper.go
90.07% <100.00%> (+0.07%)
:arrow_up:

modules/core/04-channel/keeper/keeper.go
90.90% <100.00%> (+0.13%)
:arrow_up:

modules/core/04-channel/keeper/upgrade.go
92.46% <100.00%> (+0.15%)
:arrow_up:

...s/27-interchain-accounts/host/keeper/msg_server.go
76.31% <67.85%> (-23.69%)
:arrow_down:

...es/apps/27-interchain-accounts/host/types/query.go
66.66% <66.66%> (ø)

...les/apps/27-interchain-accounts/host/types/msgs.go
44.00% <0.00%> (-56.00%)
:arrow_down:

... and 11 files with indirect coverage changes

This PR is not ready to be merged because no e2e tests are written

@crodriguezvega may I create a separate issue for all docs related changes? Including:

changelog
migration
docs/docs

I think this makes more sense to do since we wouldn't need to run all the workflows for doc changes + doc changes should not be backported

I will go ahead and merge the PR. Thank you @srdtrk for the superb work on this one. If someone would still like to do a review, please post your comments and we can deal with them in a separate PR. Once the backport for this PR is opened I will start working on reverting the API breaking change.


Add data disclaimer

Currently we're showing raw data direct from the network on the dashboard, and this raw data is downloadable there too.
I think we need a "disclaimer" stating that these data are raw, haven't been quality controlled, and haven't had any calibration/corrections applied (aside from whatever factory calibration the sensors received).
I'm thinking a short statement (and link to the FAQ) on the dashboard page itself (perhaps next to the download button below the map), and then also add more information about this to the FAQ.

Here's a draft of the text: https://docs.google.com/document/d/1AThfZEEU9wp7KP7n3t-sX6oHqOwDnfrWvliiJcLNEj4/edit?usp=sharing

I created a branch https://github.com/Ribbit-Network/ribbit-network-dashboard/tree/107-add-data-disclaimer here to make the change.

Were you planning on making the update @spestana or want me to push it to the site?

I'll open a PR to that branch. thanks!


Error Import Scan Results with API

Hi,
I have set up the defect dojo using the ./setup.bash (master branch) on Ubuntu 16.04.
I tried to import a scan report using the API. But it shows the following error.
`Response Body
{
"error_message": "global name 'Resolver404' is not defined",
"traceback": "Traceback (most recent call last):\n\n  File "/usr/local/lib/python2.7/dist-packages/tastypie/resources.py", line 221, in wrapper\n    response = callback(request, *args, **kwargs)\n\n  File "/usr/local/lib/python2.7/dist-packages/tastypie/resources.py", line 461, in dispatch_list\n    return self.dispatch('list', request, **kwargs)\n\n  File "/usr/local/lib/python2.7/dist-packages/tastypie/resources.py", line 493, in dispatch\n    response = method(request, **kwargs)\n\n  File "/usr/local/lib/python2.7/dist-packages/tastypie/resources.py", line 1401, in post_list\n    updated_bundle = self.obj_create(bundle, **self.remove_api_resource_names(kwargs))\n\n  File "/home/xxx/yyy/VulManSys/django-DefectDojo/dojo/api.py", line 884, in obj_create\n    self.is_valid(bundle)\n\n  File "/usr/local/lib/python2.7/dist-packages/tastypie/resources.py", line 1313, in is_valid\n    errors = self._meta.validation.is_valid(bundle, bundle.request)\n\n  File "/home/nadeeshani/Desktop/ExternalProducts/VulManSys/Temp/django-DefectDojo/dojo/api.py", line 805, in is_valid\n    get_pk_from_uri(uri=bundle.data['engagement'])\n\n  File "/home/nadeeshani/Desktop/ExternalProducts/VulManSys/Temp/django-DefectDojo/dojo/api.py", line 748, in get_pk_from_uri\n    except Resolver404:\n\nNameError: global name 'Resolver404' is not defined\n"
}`

@NShani Thank you for your awesome work to get this fixed! Aaron addressed a couple other discovered issues and incorporated your code into his PR. If you would like a DefectDojo shirt as a thank you for your contribution, please email me<EMAIL_ADDRESS>


Java package tutorial instructions contains some inaccuracies and omits a key point

The instructions for the Java package tutorial needs a bit of an update in order to help things go a bit smoother for the user.

the value of the @Package annotation's repository field should not contain the docker.io prefix
in the section on exposing the application on the web the instructions fail to mention that the @Package annotation needs to have the publish field added with a value of true. This is critical to the success of the tutorial as without this field the locally built image doesn't get pushed to Docker Hub and none of the scheduled replica pods can start
the service that is created on the remote Kubernetes cluster is not a LoadBalancer service but a ClusterIP service. That's fine but the instructions state that the new pods run behind a LoadBalancer service (or words to that effect)

Created PR https://github.com/metaparticle-io/package/pull/110

CLosing this since #110 merged.


fix(ci): Optimism unit / integration tests

Overview
Fixes the CI such that unit / integration tests run when the optimism feature flag is enabled.

AFK - will fix the integration test after I'm back at my desk. Don't merge for now.


#3060 - update drawer.css z-index

Related to https://github.com/saadeghi/daisyui/issues/3060
Should prevent any elements in DaisyUI from having a higher z-index than the drawer.

Thanks for the PR.
It is a quick fix but I think 10 is such a random value for z-index. This will potentially break the websites that are relying on the current behavior. We try to be neutral about the z-index values since it is something developers should decide about based on their content.
Sometimes, based on the website content, we may need some components to appear on top of drawer and sometimes under the drawer for example we may want a toast notification to be visible on top of the drawer.
To fix the z-index issue of #3060 I prefer to find a solution to remove the z-index value from steps instead of increasing the z-index of drawer.
Let me know if you have a question.


The woodcutting overlay thinks I'm not woodcutting when I'm a monkey

I'm not sure if there's actually a way to solve this, since the overlay is using the player's animation to figure out if there's any woodcutting going on, but it doesn't look like there's any animation for woodcutting while you're a monkey.

Can this be fixed? I don't think there is a way to determine if you are woodcutting without an animation.

If it's impossible, the overlay could show something helpful like Woodcutting not detectable in monkey form when the player gains wc experience in this state.

Unfortunately I'm not in a position to check right now, but I think I was still getting woodcutting noises, even if there wasn't any visible animation going on. It's possible that the animation may still be playing, to some degree, since that's one source of sound effect playback. It's also possible that the server's just sending "yo, there's a sound" messages to the client, in which case, Soy's suggestion is probably the best we can do, barring wierd heuristic magicks

I just checked, it would appear as though every attempt to gather a log (even an unsuccessful one) does play a chopping noise, at least, as long as you've got the "Area sound volume" (ie sfx that have a position) turned on. Though, as far as the devtools are concerned, I'm definitely not animating:

@Adam-, can this be closed?

This is still a valid issue, I just think it can't be fixed currently.

A chopped tree leaves a tree stump before a new one respawns. I was thinking this could be used as an indicator for Idle notifier.

Having a notification when a nearby tree falls sounds like it would have a lot of false positives. We could probably get away with sending a notif if you are monkey & have an axe & also are next to a tree which falls though.


Is there a way to finetune my own task?

i want to use it in medical field

What type of supervision do you have?

i wanna try fully supervised first

What type of supervision do you have?

i wanna try fully supervised first

Sure, just load the pretrained weights and set up a cross entropy loss between your supervised detections and DeDoDe. Your detections should be an images with ones at detections and 0s otherwise.

Ill upload the training scripts of dedode later this week, then youll be able to see the setup.

Ill upload the training scripts of dedode later this week, then youll be able to see the setup

Lifesaver!

@52THANOS now there are reference training scripts in the experiments folder, hope that helps. Let me know if something is unclear.


KP-1212 ([Docker] method Run Docker Command - JSON output option)

KP-1212 in Jira

@kenskyfish This PR also contains commits from KP-1342, because I decided to base branch KP-1212 on the KP-1342 branch to avoid merge conflicts once KP-1342 is merged into develop. You can test both PRs independently, but KP-1342 must be merged first.


Remember only permanent bottom tabs

Fixes #77249
Fixes #77013
All bottom tabs until shader editor are permanent; further tabs will not appear at start, so they shouldn't be remembered. Maybe there is a better way to enforce that than hard-coding a specific editor though .-.

Maybe as an idea:
diff --git a/editor/editor_node.cpp b/editor/editor_node.cpp
index da14f5374c..b943a8b82e 100644
--- a/editor/editor_node.cpp
+++ b/editor/editor_node.cpp
@@ -5257,7 +5257,9 @@ void EditorNode::_save_central_editor_layout_to_config(Ref<ConfigFile> p_config_
 	int selected_bottom_panel_item_idx = -1;
 	for (int i = 0; i < bottom_panel_items.size(); i++) {
 		if (bottom_panel_items[i].button->is_pressed()) {
-			selected_bottom_panel_item_idx = i;
+			if (bottom_panel_items[i].permanent) {
+				selected_bottom_panel_item_idx = i;
+			}
 			break;
 		}
 	}
@@ -5663,7 +5665,7 @@ void EditorNode::_scene_tab_changed(int p_tab) {
 	set_current_scene(p_tab);
 }

-Button *EditorNode::add_bottom_panel_item(String p_text, Control *p_item) {
+Button *EditorNode::add_bottom_panel_item(String p_text, Control *p_item, bool p_permanent) {
 	Button *tb = memnew(Button);
 	tb->set_flat(true);
 	tb->connect("toggled", callable_mp(this, &EditorNode::_bottom_panel_switch).bind(bottom_panel_items.size()));
@@ -5679,6 +5681,7 @@ Button *EditorNode::add_bottom_panel_item(String p_text, Control *p_item) {
 	bpi.button = tb;
 	bpi.control = p_item;
 	bpi.name = p_text;
+	bpi.permanent = p_permanent;
 	bottom_panel_items.push_back(bpi);

 	return tb;
diff --git a/editor/editor_node.h b/editor/editor_node.h
index 65f85a76c9..db7bcb2f44 100644
--- a/editor/editor_node.h
+++ b/editor/editor_node.h
@@ -252,6 +252,7 @@ private:
 		String name;
 		Control *control = nullptr;
 		Button *button = nullptr;
+		bool permanent = true;
 	};

 	struct ExportDefer {
@@ -904,7 +905,7 @@ public:

 	bool is_exiting() const { return exiting; }

-	Button *add_bottom_panel_item(String p_text, Control *p_item);
+	Button *add_bottom_panel_item(String p_text, Control *p_item, bool p_permanent = true);
 	void make_bottom_panel_item_visible(Control *p_item);
 	void raise_bottom_panel_item(Control *p_item);
 	void hide_bottom_panel();

I thought about that, but this flag would serve no purpose other than give information when saving editor state. But I guess it's more robust solution 🤔

Ok I added a permanent flag and set it for editor that are permanent. For now the option is not exposed to EditorPlugin, but could be probably useful for user plugins.
I kept it as a separate commit, but I guess it's more likely to be accepted.

Thanks!

https://github.com/godotengine/godot/issues/78281 Should be fixed as well, I think?

#78281 Should be fixed as well, I think?

Tested, doesn't seem to be.

It should be fixed. This PR only fixes saving state, if you already had wrong tab saved it will still be bugged on first launch.

It should be fixed. This PR only fixes saving state, if you already had wrong tab saved it will still be bugged on first launch.

Maybe we should add a hack to discard saved bottom docks if they aren't permanent?


Back to live btn in preview

On room preview (open by "jump to first unread"), if the user hits the "jump to bottom" icon, it now closes the preview to bring back the user at the bottom of the live (differs from the back button since the back button closes the preview with the live remaining where it was before opening the preview)

Add some padding around the "jump to bottom" icon so it's easier to tap on it

LGTM


Seamless Path switch

I'm working on a rail shooter game using the path creator and contains alternate paths that can be taken.
The problem is that the transition of paths is not smooth, the player immediately snaps to next point. I want the player to smoothly fly to the newly entered path. How do I do that?
    private void OnTriggerEnter(Collider other)     {         if (other.GetComponent<PathCreator>())         {             if (pathcreator.gameObject == other.gameObject)                 return;             pathcreator = other.GetComponent<PathCreator>();             distanceTravelled = pathcreator.path.GetClosestDistanceAlongPath(transform.parent.position);             Debug.Log(pathcreator.path.GetClosestDistanceAlongPath(transform.parent.position));         }     }

If movement are controlled by setting the transform's position, then
float smoothingFactor = 0.5f; // Value from 0 to 1. Determines how smoothly the movement will be performed. In this case, the smaller the value, the smoother it is
travelledDistance = pathCreator.path.GetClosestDistanceAlongPath(transform.position); // Find the nearest point along the path and get its distance from the initial point (If I understand it correctly)
transform.position = Vector3.Lerp(currentPosition, pathcreator.path.GetPointAtDistance(travelledDistance), smoothingFactor) // Smoothly move from the current position to a point along the line

If movement are controlled by setting the transform's position, then
// Value from 0 to 1. Determines how smoothly the movement will be performed. In this case, the smaller the value, the smoother it is
float smoothingFactor = 0.5f;

// Find the nearest point along the path and get its distance from the initial point (If I understand it correctly)
travelledDistance = pathCreator.path.GetClosestDistanceAlongPath(transform.position);

// Smoothly move from the current position to a point along the line
transform.position = Vector3.Lerp(currentPosition, pathcreator.path.GetPointAtDistance(travelledDistance), smoothingFactor)

The lerp conflicts with main movement function called during Update():
     void SetSpeed(float speed)     {         //dolly.m_Speed = x;         if (pathcreator)         {             speed /= 10;             distanceTravelled += speed * Time.deltaTime;             transform.parent.position = pathcreator.path.GetPointAtDistance(distanceTravelled);             transform.parent.rotation = pathcreator.path.GetRotationAtDistance(distanceTravelled);             currentSpeed = speed;         }     }

At the time of the trigger, you assign pathcreator and distanceTravelled a new value. Now, in Update, all you need to do is change the position via Lerp:
transform.parent.position = Vector3.Lerp(transform.parent.position, pathcreator.path.GetPointAtDistance(traveledDistance), movementSmoothingFactor)

You can also do the same thing for rotation
transform.parent.rotation = Quaternion.Lerp(transform.parent.rotation, pathcreator.path.GetRotationAtDistance(traveledDistance), rotationSmoothingFactor)


Fourier Correction

Updates to a lot of codes because we decided last minute to switch to Fourier analysis. Mostly looking for feedback, did create a few additional files to (in the future be done on a "div" branch). We will need to delete the "fourier" add-ons, but this is slightly for save-keeping.
Also happened to change some basic things in latex related to images.
@janewliang Looksy
Why?
We've discovered that PCA is too powerful. And we are firm believers that weakness is a strength. And so we've gone with Fourier.
For those who I haven't talked to about this, we this the PCA vectors we collinear to the hrf or otherwise causing it to act out for some people (possibly overfitting when the variance explained by the first 6 pcas were very high). I compare the outcomes (in terms of t-statistics and beta values) for we used Fourier 6 instead of PCA 6 and we saw some were super similar to the PCA versions and some were very different (but is a good way). Moreover we know that Fourier is pretty unlikely to overfit by construction (and even more unlikely to be very collinear with the hemodynamic response. I did add 6 Fourier features instead of 4.... sorry.
All in all, I think this is a good improvement on end results.

Where exactly did you do the Fourier analysis? You changed a lot of files but I'm having difficulty finding which file exactly. The bh_t_beta files that we worked on last Thursday look the same to me right now

Most files I changed a lot have _fourier after them. There are a few new
ones, but in general it's not new ideas per se
On Saturday, December 12, 2015, Rachel Lee<EMAIL_ADDRESS>wrote:

Where exactly did you do the Fourier analysis? You changed a lot of files
but I'm having difficulty finding which file exactly. The bh_t_beta files
that we worked on last Thursday look the same to me right now
—
Reply to this email directly or view it on GitHub
https://github.com/berkeley-stat159/project-alpha/pull/168#issuecomment-164171165
.

Dear all,
I hope this finds you well. Having spend 12+ hours after our meeting on Wednesday cleaning up and finding why overlapping of our Benjamini Hochberg multiple comparison of p-values, and there other thresholds using upper quantiles of abs(t-statistic) and abs(beta) were not providing accuracy results to find locations of activations regions.
My first conclusions where 2 fold;
(1) was that the brains fail to line up enough that a lot of the area interpretation is lost via this problem alone and
(2) the certain subjects linear regression models overfit, and inclusion of 6 principle components created collinearity with our predicted Hemodynamic response function. These generally occurred when the variance explained by these principle components where much larger than our lower threshold of .4 (40% variance explained)  ** recall this is all in terms of principle components of the A^T A matrix , where A is the masked voxel time courses.
Introduction of Fourier
In attempts to correct for this problem (of overfitting/collinearity), and with a firm understanding that the 6 fourier features would fail to introduce such collinearity and explanation of variance, I ran models with 6 fourier features instead. Let’s call this model “_fourier”.
For the subjects with ~40% variance explained by the first 6 principle, the beta values and t-statistics from this new model (“_fourier”) compared to the old model (with the 6 principle components “_pca”). Impressed by this outcome (as we saw earlier that _fourier was less able to predicted the BOLD response than the _pca model in the model selection analysis). I decided to implement the analysis for all subjects
Parameter Selection for “multiple comparison” and threshold analysis
While trying to find a single set of parameters to utilize across all subjects for all of these analyses, I discovered that for Benjamini Hochberg the Q value was much more variable or each subject than the other threshold analysis. And as such, even though Benjamini Hochberg is more theoretically sound, it is less strong in our case.
Recall that Benjamini Hochberg requires a Q (generally thought of as an \alpha value) and # of neighbors selection for neighbor smoothing, and our threshold statistics require an quantile value of the proportion of values saved, and a # of neighbors for neighbor smoothing.
In general, the data fails to provide many regions of activation, as the only current method for such analysis is now requires per subject analysis separately (by eye), the charts to find these patterns can be created by running “image_outlay_final.py”. As such, our conclusions should probably only include identification of the frontal lob (@kentchen, I still need the full range of possibilities of actual activation locations created for at  “sub001” at least)
Basic “Bro” Conclusion
In general the only are that sticks out to me is the frontal cortex as previously noted. #BasicBro
******* Please review/comment and add my stuff

This all feels far more like art than science at this point (since, to be frank, our biggest motivation and metric for deciding which models/parameters to use is by visual inspection on the per-subject base, which does not lend itself well to future extensions and reproducibility). But I support the Fourier argument, which had already been raised several weeks ago: Fourier has better justification than PCA, even though the model selection seemed to favor PCA. And since our goals are to model/identify active regions rather than prediction, I think that good interpretability is key.

I also think your reasoning and conclusions for the Fourier process is justified. Some parts of your explanation could be better worded, I think, but that'll probably just be cleared up when we go through the paper one last time. I don't really remember what the motivation to use PCA over fourier analysis was when we were at that crossroads, but it's awesome that you backtracked.

Really great work. I'm going to merge.


Issue with missing namespaces and indirect dependencies

Problem
Recently setup cookiecutter to automate mod creation. Tried a test mod, and this was the error log I had.
1>B:\Dev\VS 2019\MSBuild\Current\Bin\Microsoft.Common.CurrentVersion.targets(2106,5): warning MSB3258: The primary reference "Assembly-CSharp" could not be resolved because it has an indirect dependency on the .NET Framework assembly "mscorlib, Version=<IP_ADDRESS>, Culture=neutral, PublicKeyToken=b77a5c561934e089" which has a higher version "<IP_ADDRESS>" than the version "<IP_ADDRESS>" in the current target framework. 1>B:\Dev\VS 2019\MSBuild\Current\Bin\Microsoft.Common.CurrentVersion.targets(2106,5): warning MSB3258: The primary reference "Assembly-CSharp" could not be resolved because it has an indirect dependency on the .NET Framework assembly "System, Version=<IP_ADDRESS>, Culture=neutral, PublicKeyToken=b77a5c561934e089" which has a higher version "<IP_ADDRESS>" than the version "<IP_ADDRESS>" in the current target framework. 1>B:\Dev\VS 2019\MSBuild\Current\Bin\Microsoft.Common.CurrentVersion.targets(2106,5): warning MSB3258: The primary reference "Assembly-CSharp" could not be resolved because it has an indirect dependency on the .NET Framework assembly "System.Core, Version=<IP_ADDRESS>, Culture=neutral, PublicKeyToken=b77a5c561934e089" which has a higher version "<IP_ADDRESS>" than the version "<IP_ADDRESS>" in the current target framework. 1>B:\Dev\VS 2019\MSBuild\Current\Bin\Microsoft.Common.CurrentVersion.targets(2106,5): warning MSB3258: The primary reference "Assembly-CSharp" could not be resolved because it has an indirect dependency on the .NET Framework assembly "System.Xml, Version=<IP_ADDRESS>, Culture=neutral, PublicKeyToken=b77a5c561934e089" which has a higher version "<IP_ADDRESS>" than the version "<IP_ADDRESS>" in the current target framework. 1>B:\Dev\VS 2019\MSBuild\Current\Bin\Microsoft.Common.CurrentVersion.targets(2106,5): warning MSB3258: The primary reference "Assembly-CSharp" could not be resolved because it has an indirect dependency on the .NET Framework assembly "System.Xml.Linq, Version=<IP_ADDRESS>, Culture=neutral, PublicKeyToken=b77a5c561934e089" which has a higher version "<IP_ADDRESS>" than the version "<IP_ADDRESS>" in the current target framework. 1>B:\Dev\VS 2019\MSBuild\Current\Bin\Microsoft.Common.CurrentVersion.targets(2106,5): warning MSB3258: The primary reference "Assembly-CSharp" could not be resolved because it has an indirect dependency on the .NET Framework assembly "System.Configuration, Version=<IP_ADDRESS>, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" which has a higher version "<IP_ADDRESS>" than the version "<IP_ADDRESS>" in the current target framework. 1>B:\Dev\VS 2019\MSBuild\Current\Bin\Microsoft.Common.CurrentVersion.targets(2106,5): warning MSB3258: The primary reference "Assembly-CSharp" could not be resolved because it has an indirect dependency on the .NET Framework assembly "System.Runtime.Serialization, Version=<IP_ADDRESS>, Culture=neutral, PublicKeyToken=b77a5c561934e089" which has a higher version "<IP_ADDRESS>" than the version "<IP_ADDRESS>" in the current target framework. 1>B:\Dev\VS 2019\MSBuild\Current\Bin\Microsoft.Common.CurrentVersion.targets(2106,5): warning MSB3258: The primary reference "Assembly-CSharp" could not be resolved because it has an indirect dependency on the .NET Framework assembly "System.Security, Version=<IP_ADDRESS>, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" which has a higher version "<IP_ADDRESS>" than the version "<IP_ADDRESS>" in the current target framework. 1>B:\Steam\steamapps\common\RimWorld\Mods\Test Mod\Source\Test_Mod.cs(2,7,2,15): error CS0246: The type or namespace name 'RimWorld' could not be found (are you missing a using directive or an assembly reference?) 1>B:\Steam\steamapps\common\RimWorld\Mods\Test Mod\Source\Test_Mod.cs(3,7,3,12): error CS0246: The type or namespace name 'Verse' could not be found (are you missing a using directive or an assembly reference?) 1>B:\Steam\steamapps\common\RimWorld\Mods\Test Mod\Source\Test_Mod.cs(5,7,5,12): error CS0246: The type or namespace name 'Verse' could not be found (are you missing a using directive or an assembly reference?)
I tried re-adding UnityEngine.dll and Assembly-CSharp.dll but continued to have this error.

Fixed. Was using .Net 3.5 Framework, needed .Net 4 Framework instead


Microsoft Graph Explorer get calendars api call returning deleted calendars for the user

-> Getting deleted calendars along with active calendars when I am using below Api call
'https://graph.microsoft.com/v1.0/me/calendars'
Is this expected behavior of this call? if yes how can I get only active calendars, is there any provision for that?

This is the priority item for a client, is there any way to prioritize this request pls?

Hey @jithender9966 ,
Apologies for the delay.
I am unable to reproduce this on my end... did the user run a delete query to delete the unwanted calendar? e.g
DELETE https://graph.microsoft.com/v1.0/me/calendar/{calendar-id


Prompt before throwing away a user's hotkey changes.

Description of the new feature/enhancement
Prompt the user before throwing away their hotkey changes.  Right now when editing hotkeys there is an "are you sure?" type prompt on every hotkey change, but once finished if the user closes the settings tab all changes are discarded.  A user could spend a lot of time manually entering in hotkey changes only to have them thrown away.

Thanks for the suggestion! This is actually already being tracked by another issue on our repo - please refer to #10627 for more discussion.
/dup #10627


Update count_tokens() to be accurate for the Claude 3 series of models

Plenty of apps, including ourselves, validate token counts before sending requests to the API to proactively handle errors

    def count_tokens(
        self,
        text: str,
    ) -> int:
        """Count the number of tokens in a given string.

        Note that this is only accurate for older models, e.g. `claude-2.1`. For newer
        models this can only be used as a _very_ rough estimate, instead you should rely
        on the `usage` property in the response for exact counts.
        """
        # Note: tokenizer is untyped
        tokenizer = self.get_tokenizer()
        encoded_text = tokenizer.encode(text)  # type: ignore
        return len(encoded_text.ids)  # type: ignore

The function appears not to be accurate for newer models
It would be super useful to either make it or accurate or tell us how we can do it ourselves before sending the request

Hi @rbehal! Unfortunately, it's no longer possible to provide ahead-of-time client-side accurate token counts. The server should respond with token counts after the response is completed, but I recognize that this is not ideal when trying to use every last token of the context window. My best advice for now is use heuristic estimates and give yourself a buffer, but we're definitely considering ways of making this a better developer experience.

Thanks for the reply, that seems so strange to me though. What do you mean exactly by "heuristic estimates", do you have a recommendation anywhere?


Add more tests for pair

Add tests for JsonPairStorage, JsonSerialisablePair and AddPairCommand.

Typos have been resolved @wz2k


The X11 connection broke (error 1). Did the X11 server die?

This is

xrdp v0.9.19 with
xorgxrdp v0.2.18 backend (not VNC)
Linux
Guacamole
Firefox client
with initial-program (single application, not desktop) set.

I have a custom QT application running as initial-program, which I think is crucial to get the error (I mean the GUI framework being QT). I also have KillDisconnected=true and IdleTimeLimit=3600 configured in sesman.ini.
Now when closing the browser tab, the IdleTimeLimit starts counting. If it passed, xrdp should be sending a SIGTERM to the session. At least I believe that, from what I read from the source. To do some clean-up work in my program, I implemented a signal handler that handles SIGTERM correctly on my test machine. However it does not when running it under xrdp. Instead I get the following error when SIGTERM should have been sent:
The X11 connection broke (error 1). Did the X11 server die?
And from what I see I think that instead it's being SIGKILLed, so that I cannot clean-up.
Search engines bring up some ideas about memory shortage for the X11 server, but nothing that helped me fixing that.
Some ideas:
If you'd like to reproduce this, you might need a QT app to test. Maybe there is one in the repos, but I found these:

https://learnubuntumate.weebly.com/qt-calculator.html
https://qalculate.github.io/

If it cannot be fixed (easily) I would also be grateful for workaround ideas. Maybe there is some customizable hook that is triggered before the xrdp shutdown code is run, so that I can kill -SIGTERM it normally beforehand? Maybe I could implement a watchdog that could terminate my program before it gets killed (but what should I listen for)?
Ideas about the reason for the error:
Maybe X11 is killed before SIGTERM is sent?

@saddy001 - my understanding of the countdown timer is that it's implemented currently in xorgxrdp. When the timer reaches its limit, the X server simply quits.
I'm not familiar with Qt. Is there a signal emitted by the event loop when the X server fails which could be caught by the app?

Yes, I catch the signal and it works in my testing setup. But not when run in xrdp, there it is SIGKILLed.

xrdp doesn't send a SIGKILL - it uses SIGTERM for the session.
It could be that the session code in systemd is doing this. What's your base OS?

Ubuntu 20.04.4 focal

I watched and have the default systemd config and no service config that specifies another KillSignal (default is SIGTERM as man systemd.kill states).

Thanks.
Are you running a desktop as well as your custom application, or just the application?

I tried to summarize my whole setup in the first comment:

* with initial-program (single application, not desktop) set.

My apologies - I missed that.
I think we need to find out where that SIGKILL is coming from - I can't see how it can be xrdp or xorgxrdp. This stackoverflow answer has some pointers on that.

A couple of thoughts:-

Try sudo ausearch to see if anything's logged you don't have permissions to view.
Attach a debugger to your program after it's started with sudo gdp -p <pid> to see what happens when the X server exits.

Maybe that will give us some more clues.

Thanks for your help.
I already run ausearch under root.
I attached gdb, typed "continue" and triggered an exit. The log:
# gdb -p 11622
GNU gdb (Ubuntu 8.1.1-0ubuntu1) 8.1.1
Copyright (C) 2018 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word".
Attaching to process 11622
[New LWP 11624]
[New LWP 11625]
[New LWP 11626]
[New LWP 11634]
[New LWP 11635]
[New LWP 11636]
[New LWP 11637]
[New LWP 11638]
[New LWP 11639]
[New LWP 11640]
[New LWP 11641]
[New LWP 11642]
[New LWP 11643]
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
0x00007f51b11aebb9 in __GI___poll (fds=0x55f9404704a0, nfds=1, timeout=4975) at ../sysdeps/unix/sysv/linux/poll.c:29
29	../sysdeps/unix/sysv/linux/poll.c: Datei oder Verzeichnis nicht gefunden.
(gdb) continue
Continuing.
[Thread 0x7f51949a4700 (LWP 11634) exited]
[Thread 0x7f517d714700 (LWP 11643) exited]
[Thread 0x7f51ac3f1700 (LWP 11626) exited]
[Thread 0x7f51acbf2700 (LWP 11625) exited]
[Thread 0x7f51ad3f3700 (LWP 11624) exited]
[Thread 0x7f517f7fe700 (LWP 11642) exited]
[Thread 0x7f517ffff700 (LWP 11641) exited]
[Thread 0x7f516c686700 (LWP 11640) exited]
[Thread 0x7f5184e87700 (LWP 11639) exited]
[Thread 0x7f5185688700 (LWP 11638) exited]
[Thread 0x7f518668a700 (LWP 11636) exited]
[Thread 0x7f5186e8b700 (LWP 11635) exited]
[Thread 0x7f51b205a0c0 (LWP 11622) exited]
[Inferior 1 (process 11622) exited with code 01]

Since this is not too informative, I then set a breakpoint on exit:
# gdb -p 12446
GNU gdb (Ubuntu 8.1.1-0ubuntu1) 8.1.1
Copyright (C) 2018 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word".
Attaching to process 12446
[New LWP 12453]
[New LWP 12454]
[New LWP 12455]
[New LWP 12458]
[New LWP 12459]
[New LWP 12460]
[New LWP 12461]
[New LWP 12462]
[New LWP 12463]
[New LWP 12464]
[New LWP 12465]
[New LWP 12466]
[New LWP 12467]
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
0x00007fe3556a8bb9 in __GI___poll (fds=0x558e52bddeb0, nfds=1, timeout=4880) at ../sysdeps/unix/sysv/linux/poll.c:29
29	../sysdeps/unix/sysv/linux/poll.c: Datei oder Verzeichnis nicht gefunden.
(gdb) b exit
Haltepunkt 1 at 0x7fe3422f7900 (10 locations)
(gdb) continue
Continuing.
[Thread 0x7fe338e9e700 (LWP 12458) exited]

Thread 1 "python" hit Breakpoint 1, __GI_exit (status=1) at exit.c:139
139	exit.c: Datei oder Verzeichnis nicht gefunden.
(gdb) bt
#0  __GI_exit (status=1) at exit.c:139
#1  0x00007fe33c9a90d4 in QXcbConnection::processXcbEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /home/user/pylibs/lib/python3.9/site-packages/PySide2/Qt/plugins/platforms/../../lib/libQt5XcbQpa.so.5
#2  0x00007fe33c9cf693 in xcbSourceDispatch(_GSource*, int (*)(void*), void*) () from /home/user/pylibs/lib/python3.9/site-packages/PySide2/Qt/plugins/platforms/../../lib/libQt5XcbQpa.so.5
#3  0x00007fe3452bd537 in g_main_context_dispatch () from /usr/lib/x86_64-linux-gnu/libglib-2.0.so.0
#4  0x00007fe3452bd770 in ?? () from /usr/lib/x86_64-linux-gnu/libglib-2.0.so.0
#5  0x00007fe3452bd7fc in g_main_context_iteration () from /usr/lib/x86_64-linux-gnu/libglib-2.0.so.0
#6  0x00007fe3486fc1cc in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /home/user/pylibs/lib/python3.9/site-packages/PySide2/Qt/lib/libQt5Core.so.5
#7  0x00007fe34869f21a in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /home/user/pylibs/lib/python3.9/site-packages/PySide2/Qt/lib/libQt5Core.so.5
#8  0x00007fe3486a81d3 in QCoreApplication::exec() () from /home/user/pylibs/lib/python3.9/site-packages/PySide2/Qt/lib/libQt5Core.so.5
#9  0x00007fe343533e08 in Sbk_QApplicationFunc_exec_ () from /home/user/pylibs/lib/python3.9/site-packages/PySide2/QtWidgets.abi3.so
#10 0x0000558e507506dc in cfunction_vectorcall_NOARGS (func=0x7fe34041c400, args=<optimized out>, nargsf=<optimized out>, kwnames=<optimized out>) at /tmp/build/80754af9/python-split_1631797238431/work/Objects/methodobject.c:489
#11 0x0000558e507befdc in _PyObject_VectorcallTstate (kwnames=0x0, nargsf=<optimized out>, args=0x7fe33f6fa8e0, callable=0x7fe34041c400, tstate=<optimized out>)
    at /tmp/build/80754af9/python-split_1631797238431/work/Include/cpython/abstract.h:118
#12 PyObject_Vectorcall () at /tmp/build/80754af9/python-split_1631797238431/work/Include/cpython/abstract.h:127
#13 call_function (kwnames=0x0, oparg=<optimized out>, pp_stack=<synthetischer Zeiger>, tstate=0x558e517ff880) at /tmp/build/80754af9/python-split_1631797238431/work/Python/ceval.c:5075
#14 _PyEval_EvalFrameDefault (tstate=<optimized out>, f=0x7fe33f6fa740, throwflag=<optimized out>) at /tmp/build/80754af9/python-split_1631797238431/work/Python/ceval.c:3487
#15 0x0000558e50848753 in _PyEval_EvalFrame () at /tmp/build/80754af9/python-split_1631797238431/work/Include/internal/pycore_ceval.h:40
#16 function_code_fastcall (globals=<optimized out>, nargs=<optimized out>, args=<optimized out>, co=<optimized out>, tstate=0x558e517ff880) at /tmp/build/80754af9/python-split_1631797238431/work/Objects/call.c:330
#17 _PyFunction_Vectorcall () at /tmp/build/80754af9/python-split_1631797238431/work/Objects/call.c:367
#18 0x0000558e507bfebb in _PyObject_VectorcallTstate (kwnames=0x0, nargsf=<optimized out>, args=0x7fe356455750, callable=0x7fe355145670, tstate=<optimized out>)
    at /tmp/build/80754af9/python-split_1631797238431/work/Include/cpython/abstract.h:118
#19 PyObject_Vectorcall () at /tmp/build/80754af9/python-split_1631797238431/work/Include/cpython/abstract.h:127
#20 call_function (kwnames=0x0, oparg=<optimized out>, pp_stack=<synthetischer Zeiger>, tstate=0x558e517ff880) at /tmp/build/80754af9/python-split_1631797238431/work/Python/ceval.c:5075
#21 _PyEval_EvalFrameDefault (tstate=<optimized out>, f=0x7fe3564555e0, throwflag=<optimized out>) at /tmp/build/80754af9/python-split_1631797238431/work/Python/ceval.c:3518
---Type <return> to continue, or q <return> to quit---

#22 0x0000558e50848753 in _PyEval_EvalFrame () at /tmp/build/80754af9/python-split_1631797238431/work/Include/internal/pycore_ceval.h:40
#23 function_code_fastcall (globals=<optimized out>, nargs=<optimized out>, args=<optimized out>, co=<optimized out>, tstate=0x558e517ff880) at /tmp/build/80754af9/python-split_1631797238431/work/Objects/call.c:330
#24 _PyFunction_Vectorcall () at /tmp/build/80754af9/python-split_1631797238431/work/Objects/call.c:367
#25 0x0000558e507bfebb in _PyObject_VectorcallTstate (kwnames=0x0, nargsf=<optimized out>, args=0x558e5185a100, callable=0x7fe33d0c2280, tstate=<optimized out>)
    at /tmp/build/80754af9/python-split_1631797238431/work/Include/cpython/abstract.h:118
#26 PyObject_Vectorcall () at /tmp/build/80754af9/python-split_1631797238431/work/Include/cpython/abstract.h:127
#27 call_function (kwnames=0x0, oparg=<optimized out>, pp_stack=<synthetischer Zeiger>, tstate=0x558e517ff880) at /tmp/build/80754af9/python-split_1631797238431/work/Python/ceval.c:5075
#28 _PyEval_EvalFrameDefault (tstate=<optimized out>, f=0x558e51859f90, throwflag=<optimized out>) at /tmp/build/80754af9/python-split_1631797238431/work/Python/ceval.c:3518
#29 0x0000558e508478e2 in _PyEval_EvalFrame () at /tmp/build/80754af9/python-split_1631797238431/work/Include/internal/pycore_ceval.h:40
#30 _PyEval_EvalCode () at /tmp/build/80754af9/python-split_1631797238431/work/Python/ceval.c:4327
#31 0x0000558e508f9bac in _PyEval_EvalCodeWithName (qualname=0x0, name=0x0, closure=0x0, kwdefs=0x0, defcount=0, defs=0x0, kwstep=2, kwcount=0, kwargs=<optimized out>, kwnames=<optimized out>, argcount=<optimized out>,
    args=<optimized out>, locals=<optimized out>, globals=<optimized out>, _co=<optimized out>) at /tmp/build/80754af9/python-split_1631797238431/work/Python/ceval.c:4359
#32 PyEval_EvalCodeEx () at /tmp/build/80754af9/python-split_1631797238431/work/Python/ceval.c:4375
#33 0x0000558e508489eb in PyEval_EvalCode (co=<optimized out>, globals=<optimized out>, locals=<optimized out>) at /tmp/build/80754af9/python-split_1631797238431/work/Python/ceval.c:826
#34 0x0000558e508f9c5b in run_eval_code_obj () at /tmp/build/80754af9/python-split_1631797238431/work/Python/pythonrun.c:1219
#35 0x0000558e5092d705 in run_mod () at /tmp/build/80754af9/python-split_1631797238431/work/Python/pythonrun.c:1240
#36 0x0000558e507d260d in pyrun_file (fp=0x558e518652f0, filename=0x7fe35646cda0, start=<optimized out>, globals=0x7fe356480b80, locals=0x7fe356480b80, closeit=1, flags=0x7ffe0dbe4bc8)
    at /tmp/build/80754af9/python-split_1631797238431/work/Python/pythonrun.c:1138
#37 0x0000558e5093249f in pyrun_simple_file (flags=0x7ffe0dbe4bc8, closeit=1, filename=0x7fe35646cda0, fp=0x558e518652f0) at /tmp/build/80754af9/python-split_1631797238431/work/Python/pythonrun.c:449
#38 PyRun_SimpleFileExFlags () at /tmp/build/80754af9/python-split_1631797238431/work/Python/pythonrun.c:482
#39 0x0000558e50932c7f in pymain_run_file (cf=0x7ffe0dbe4bc8, config=0x558e517fe020) at /tmp/build/80754af9/python-split_1631797238431/work/Modules/main.c:379
#40 pymain_run_python (exitcode=0x7ffe0dbe4bc0) at /tmp/build/80754af9/python-split_1631797238431/work/Modules/main.c:604
#41 Py_RunMain () at /tmp/build/80754af9/python-split_1631797238431/work/Modules/main.c:683
#42 0x0000558e50932d79 in Py_BytesMain () at /tmp/build/80754af9/python-split_1631797238431/work/Modules/main.c:1129
---Type <return> to continue, or q <return> to quit---

#43 0x00007fe3555b5c87 in __libc_start_main (main=0x558e507dad80 <main>, argc=2, argv=0x7ffe0dbe4db8, init=<optimized out>, fini=<optimized out>, rtld_fini=<optimized out>, stack_end=0x7ffe0dbe4da8) at ../csu/libc-start.c:310
#44 0x0000558e508b7bc3 in _start ()
(gdb)

Sadly I don't know enough about C to interpret the stack.

Good work.
It looks like the Qt function QXcbConnection::processXcbEvents() (C++) is calling exit directly. Indeed, that seems to be the case:-
https://github.com/qt/qtbase/blob/08d6cb7673aa51bc0532d71db4134f4912e14769/src/plugins/platforms/xcb/qxcbconnection.cpp#L997-L1004
There's a C function called atexit() which allows you to register a handler which is called when exit() is called. Is that something you can add to your application?

We've got it! Thank you!
That's why my signal handler did receive nothing and why ausearch found no kill.
I will register an exit handler and I am done.

Thanks for raising a very interesting issue!


Helpful error message when user forgets to run argospm update

$ argospm install translate-en_es
Traceback (most recent call last):
  File "/home/argosopentech/onmt-models/env/lib/python3.8/site-packages/argostranslate/package.py", line 216, in get_available_packages
    with open(settings.local_package_index) as index_file:
FileNotFoundError: [Errno 2] No such file or directory: '/home/argosopentech/.local/cache/argos-translate/index.json'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/home/argosopentech/onmt-models/env/bin/argospm", line 5, in <module>
    argospm.main()
  File "/home/argosopentech/onmt-models/env/lib/python3.8/site-packages/argostranslate/argospm.py", line 108, in main
    args.callback(args)
  File "/home/argosopentech/onmt-models/env/lib/python3.8/site-packages/argostranslate/argospm.py", line 29, in install_package
    available_packages = package.get_available_packages()
  File "/home/argosopentech/onmt-models/env/lib/python3.8/site-packages/argostranslate/package.py", line 224, in get_available_packages
    raise Exception('Local package index not found,' +
Exception: Local package index not found, use package.update_package_index() to load it

Maybe it's easier to automatically update the package list if the user has forgotten argospm update before argospm install or argospm search?

Yes auto updating if there isn't already a local package index is probably a good idea.

Done here https://github.com/argosopentech/argos-translate/pull/178

Could you tell  me the solution when input the example of python error,thanks！：）

发生异常: Exception
Local package index not found, use package.update_package_index() to load it
During handling of the above exception, another exception occurred:
File "E:\UAV sofewave\text fangyi .py", line 8, in
available_packages = argostranslate.package.get_available_packages()
# Download and install Argos Translate package

available_packages = argostranslate.package.get_available_packages()
package_to_install = next(
filter(
lambda x: x.from_code == from_code and x.to_code == to_code, available_packages
)
)
argostranslate.package.install_from_path(package_to_install.download())

You need to call:
argostranslate.package.update_package_index()

Sorry the documentation was confusing so I updated it.


Added Try/Catch example to styleguide

One of the few things missing, it seems

Do they even use try/catch in any code?

Yep, if try catches are used this is how they will look, good thought.


Caching Error When Creating and Saving New Product

I have discovered some weird behavior when I try to create a product in my local developement environment. Namely, if some of the fields on the Stock and Pricing tab are left unfilled and the Save button is pressed, the systems attempts to save the item but them bounces one to a 404 Page which says (using Django debug info) that media/cache/long_image_name_here.jpg is not found.
When one diligently fills out all of the fields, the item is created successfully.

Page not found (404)

Request Method:
GET

http://localhost:8000/media/cache/99/2a/992ab059225fc7d7f9f81064e64e021d.jpg

django.views.static.serve

"/Users/selfishman/www/sites/Playground/Django-tut/django-oscar/kindbook/media/cache/99/2a/992ab059225fc7d7f9f81064e64e021d.jpg" does not exist

You're seeing this error because you have DEBUG = True in your Django settings file. Change that to False, and Django will display a standard 404 page.

I believe this is simply an issue with reporting validation to the user properly and preventing the saving before all the needed fields are populated.
My dependencies on this fully stock project.
Babel==2.4.0
Django==1.10.7
django-appconf==1.0.2
django-compressor==2.1.1
django-extra-views==0.6.4
django-haystack==2.5.1
django-oscar==1.4
django-tables2==1.7.1
django-treebeard==4.1.1
django-widget-tweaks==1.4.1
factory-boy==2.8.1
Faker==0.7.13
mock==2.0.0
olefile==0.44
pbr==3.0.1
phonenumbers==8.5.0
Pillow==4.1.1
purl==1.3.1
pycountry==17.5.14
python-dateutil==2.6.0
pytz==2017.2
rcssmin==1.0.6
rjsmin==1.0.12
six==1.10.0
sorl-thumbnail==12.4a1
Unidecode==0.4.20

It looks like you haven't configured your media URLs correctly for development - see the relevant section of the Django documentation.
You can also refer to the Oscar sandbox setup .

Closing doe to no feedback from OP. Feel free to reopen if there is an issue in the core (rather than a project-level configuration issue).


Bintray soon to be sunsetted

As per https://jfrog.com/blog/into-the-sunset-bintray-jcenter-gocenter-and-chartcenter/ Bintray will be sunsetted as of May 1, 2021.
We are currently looking to update/remove any dependencies that rely on bintray,  and a number of systems follow these instructions for pulling down and installing sbt: https://www.scala-sbt.org/release/docs/Installing-sbt-on-Linux.html
Just checking in to see if there are any plans to publish someplace else

@nicholasnbg I have an issue here to track Bintray sunset - https://github.com/sbt/sbt/issues/6294
Feel free to comment there.


The keyword "site builder" is missing from this entire document

The keyword "site builder" is missing from the title, the section before the fold, and the rest of the document. This makes it difficult to find this doc when using "site builder" in the search query.

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

ID: 33e27a9b-62ab-c8d3-c20e-7895d24a4fd8
Version Independent ID: b5da75cf-aa28-4910-038b-19ca0ec71ba7
Content: Work with modules - Commerce | Dynamics 365
Content Source: articles/commerce/work-with-modules.md
Service: dynamics-365-commerce
Product: ****
Technology: ****
GitHub Login: @phinneyridge
Microsoft Alias: stuharg

@ricdlee, thank you for letting us know about this issue. I have forwarded it to the author for consideration.

@ricdlee, thank you for letting us know about this issue. I have forwarded it to the author for consideration.

@bicyclingfool can you please review this comment?


Define the database schema for the app

Summary
Define the database schema for the app. Mainly tables and columns and how they relate to each other.
We will be using a Postgres database, so take that into account
Work Scope

[ ]  Create a markdown file that explains how the database is laid out. Perhaps a good place to start with this would be a google spreadsheet.

This would have been good, but is now overcome by events


Dependency update

To resolve https://github.com/frictionlessdata/implementations/issues/34
    - six >=1.9
    - click >=3.3
    - requests >=2.5
    - python-dateutil >=2.4
    - jsonschema >=2.5
    - unicodecsv >=0.14
    - isodate >=0.5.4
    - rfc3986 >=1.1.0
    - tabulator >=1.20

Do you want to send a PR to fix that? All you want to do is to update the deps and bump the build number. Also, consider adding yourself as a maintainer so you can fix and merge this next time :wink:


CSS Grid support

CSS Grid support just landed in Chrome, Firefox, Opera, and Safari (including iOS) in March 2017. As automatic updates go out in the coming days, Grid will be at ~72% support by the end of May (by my estimate). There is a polyfill to get support in IE9+.

CSS Grid is way more useful than Flexbox in my experience. Since Flexbox is part of core, I'd like to see Grid added as well. Or, rather than bloat core by adding classes for CSS Grid, we could remove Flexbox from core and make both Flexbox and CSS Grid into optional add-ons.
Thoughts?
(Related issue: https://github.com/tachyons-css/tachyons/issues/343)

Have been noodling on this quite a bit and like most things in my life, feel conflicted. I really like airing on the side of accessibility (in this case in the form of access to non broken ui) - while it is in evergreen browsers there is also a lot of red there from my perspective. For me even 1% of users is still enough to worry about when considering the scale of the internet.
I still don't know how I feel about flex box being in core either. I will definitely create an add on optional module for css grid - because while I have my beliefs about how I like to approach building the web, I don't believe everyone has to share my beliefs.
This is in line with my general thoughts lately about Tachyons and the conflict I currently have internally about where to take the project in the future. As I built tachyons for myself to solve my own problems and absolutely never expected more than 20 people to use it - my general philosophy has been to not include things that I don't constantly use myself. But as the project grows I've been wrestling with whether or not to bend to the wishes of many of the awesome users utilizing tachyons even if I disagree with them. And opens up a larger point of if I should just let go of the project and have people from the community maintain it / contribute more. The only hesitation I have here is that I don't know if Tachyons would have ever come into existence if I listened to smart and awesome developers in the first place :) But recognizing that as more people use Tachyons I emotionally feel a larger obligation to let it fit their needs and recognize I can start a new project no one uses that reflects what I want / need in a css toolkit.
Sorry for the long slightly unrelated response. This has definitely been weighing on me of late as I see more and more companies adopting Tachyons. Definitely interested in community thoughts.

@mrmrs As a maintainer in a similar situation, I suggest you focus on what you want the project to be. If you start going down the path of merging features due to pressure, then you will (1) get a less cohesive, curated product (which is why people came to tachyons in the first place) and (2) stop having fun (which can lead to burnout and feelings of guilt). Speaking from experience.
Personally, if you don't use Flexbox, I would consider removing it from core. You can add interested contributors to that repo and let them go wild. It's a win-win.
I say: make tachyons whatever you want it to be. The big companies have sufficient resources already -- they can fork their own internal version if they don't like your decisions. That happens all the time with my project standard.
Rock on! 🎸

I had a stab at this and ended up with something that seems somewhat usable, although my mnemonics approach might need some work.

display: grid → dg, dg-ns dg-m etc

Some prefixes for column start/end:

grid-column-start → gcs, gcs-ns etc
grid-column-end → gce etc
grid-column-start: span → gcss
grid-column-end: span → gces

Same for row:

grid-row-start → grs
grid-row-end → gre
grid-row-start: span → grss
grid-row-end: span → gres

So for example gre4 becomes grid-row-end: 4 while gres4 becomes grid-row-end: span 4.
I haven't followed through with gaps in my prototype, but I imagine a few gaps would be useful too:

grid-gap → gg
grid-row-gap → grg
grid-column-gap → gcg

Gaps would probably be most useful if they took the same scale as padding, so perhaps grg1 becomes var(--spacing-extra-small) in scss terms.
In actually defining the grid itself, I found that it is probably most common to write custom CSS to define the grid widths, because the grid itself is often a mix of fractions and minmax expressions.  It's possible to define some grid-template-columns that e.g. repeat 1fr 6 times (to get a simple 6-column layout).
This gives us something like this (with the usual -l and -m and -ns modifiers):

Something here

There be dragons

There be dragons

my-custom-grid-definition would define the grid, something I'd have to do myself of course, not part of tachyons.  The custom grid definition could be implicitly responsive (i.e. have different declarations for different breakpoints) or it could be atomic, requiring me to specify which layout I want at different breakpoints.  This is up to the customization of course.
This completely ignores named areas, as they would be pretty hard to provide in a generic framework, I believe.
My prototype uses sass, and a tiny excerpt is below (showing only dg and grs5 variations):
.dg {
    display: grid;
}
/*...*/
.grs5 {
    grid-row-start: 5;
}
@media #{$breakpoint-not-small} {
    .dg-ns {
        display: grid;
    }
    /*...*/
    .grs5-ns {
        grid-row-start: 5;
    }
}

@media #{$breakpoint-medium} {
    .dg-m {
        display: grid;
    }
    /*...*/
    .grs5-m {
        grid-row-start: 5;
    }
}

@media #{$breakpoint-large} {
    .dg-l {
        display: grid;
    }
    /*...*/
    .grs5-l {
        grid-row-start: 5;
    }
}

One glaring problem is that this doesn't work with an unlimited number of columns.  And as the number of supported columns (or rows) increases, so does the size of this file.

/cc @dangayle FWIW (ref #343)

@mogsie It looks like you've put a lot of effort into figuring out a viable approach. I was thinking about how one might go about this a while back as well. Once I started into the mental planning phase, I realized that I was making a mistake. I think you've done the same. And if I'm being completely honest, I don't see easy solutions for (1) where to go from here or (2) how to implement an agnostic, flexible CSS Grid solution with fallbacks that can be used in a framework.
CSS-based grids have always been kind of hack-ish using wrappers and widths to push things around. CSS Grid, on the other hand, is kind of radically different. The grid layout is defined in CSS. No need for rows and other extraneous markup hacks to make it all work: your markup doesn't create the grid, so you wind up with a far more rigid separation of layout and markup. Done right, CSS Grid means less CSS and not more, including media queries.
Recreating that in markup is just duplicating what CSS Grid already does. One article (You do not need a CSS Grid based Grid System - Rachel Aaron) on this subject had a very poignant conclusion:

If you limit yourself to what has gone before, by only using the parts of Grid that you can recreate in older browsers, or by using some framework that is limiting itself, you miss out on the creative possibilities of using Grid. In that case why bother? You may as well use the legacy code only, and that would indeed be a shame.

A couple others: The benefits of learning how to code layouts with CSS; The future of layout with CSS: Grid Layouts. The general direction seems to be that to fully take advantage of CSS Grid, we'll wind up hand-coding CSS layouts. Which is a good thing. In truth, it'll be likely more flexible and probably even more efficient when you consider how you need fewer media queries, markup changes to support layouts, etc. But that's still radically different.
This isn't going to make frameworks obsolete.  But once people quit trying to recreate legacy stuff with CSS Grid (I'm assuming there were more than a few moments where you wanted to pull your hair out), frameworks will probably wind up divorcing components from layout as much as possible.
Tachyon's components fit into a couple categories, IMO. You have what are effectively full-page layouts with the articles or 404 pages, and some others like cards that definition lists that are effectively layout and grid agnostic. Plug and play.
Those components are items that get placed on a grid. Right now, some use existing float grid components internally. Most can be redone with flexbox, which can still be--and should be--used with CSS Grid to take advantage of their differences. They can compliment each other.
The trickiest part, IMO, is that CSS Grid is absolutely going to change how frameworks are written. That's going to make things harder on framework developers, but it could end up making things even easier on front-end developers. Whether Tachyon should go in that very different direction is @mrmrs's call.

Thank you for your thoughful response @bluestrike2, it's exactly the type of feedback I was hoping for.  I don't see atomic css in general or tachyons specifically as a "framework" per se, more a technique with a particular implementation. It allows me to express the style of an element in the very element definition.
I didn't pull my hair out implementing a standard story layout using this atomic CSS approach.  Supporting IE10 was a bit difficult, however.  Doing CSS grid in this way does have a few limitations, and that's probably why I'm spending so much time here, to try to see if those limitations are worth it, and if it should just be documented explicitly as no this shouldn't be done as part of a standard tachyons thing, for these reasons: or something like that.
The limitations I've hit upon are:

If Tachyons defines any grid, it would be a bland, generic 12-column one probably.  Very much "against" the spirit of CSS Grid.  Probably each project would want to define its own grids; possibly in an atomic and responsive way, just not use any predefined grid from this project.
It is highly unlikely that tachyons can define any grid areas with names, since names are so open ended.

When it comes to supporting IE (with display: -ms-grid etc) you're effectively limiting yourself quite a lot, since the common denominator, this means:

explicitly specifying start columns/rows and end spans for every item, not relying on auto-filling or grid-row-start: span 2
defining additional rows and columns tracks for grid gaps.  This means explicitly defining all the grid rows you might possibly need.

I do see value in defining cross browser (CSS Grid + -ms-grid) classes that try to gloss over these limitations, and make use of actual grid support in about 72% of browsers (a lot of the remaining 28% are mobile phones where a fallback should be more than adequate).  However, I don't think that it's in Tachyons' interest to include these in the base set (especially given the -ms- grid gap hack).
Example code
/* define the track (IE10+ gets a 1rem grid-gap) */
.my-custom-columns {
  -ms-grid-columns: 8rem 1rem 1fr 1rem 33%;
  grid-template-columns: 8rem 1fr 33%;
  grid-gap: 1rem;
}

.grid-row-2 {
    -ms-grid-row: 3; /* row 3 is "actually" row 2 due to grid-gap hack */
    grid-row-start: 2;
}

.grid-row-span-2 {
  -ms-grid-row-span: 3; /* Needs to span the grid gap too */
  grid-row-end: span 2;
}

Using this approach it's feasible to re-use the grid-row-span-2 type across various projects, but leave the actual grid definition (my-custom-columns) in the project itself (it's just harder to re-use it).
I vote for closing this issue, or perhaps documenting in the README why it's not such a great idea.

css grids are the future and the 12 column thing will be a thing of the past. That said IE will continue to slow up progress for some years to come. Just chiming in. I am opting to start using grids now minus gaps because IE.


An idea: enable BYOK (Bring Your Own Kernel) on k8s with Kata runtime by leveraging special pod_sandbox container

In some scenarios users would like to use specific kernels (with different versions, configs, modules, parameters, etc.) to run their containers in k8s. Designing a mechanism to achieve this goal:
1, Imagine a special kind of docker image - Kernel Docker Image. Just as its name implies, the image contains a kernel (/boot/vmlinuz) and the corresponding modules (/lib/modules/$(uname -r)/). Besides, a 'pause' binary is added into it. So it's also a pause image.
2, Designate this special image as the pod_sandbox container image. Currently the sandbox image is a node-level setting in k8s/containerd. Patches are needed to make it a per-pod configuration.
3, Traditionally, when Kata create pod_sandbox container, a hypervisor process will be spawned with a preset kernel on host (/usr/share/kata-containers/vmlinuz.container). But here, instead, Kata use the kernel inside Kernel Docker Image to launch the VM.
4, Basically, that's all. There are still some details need to be handled, eg. mod probing. But overall they're not critical.
In general, by doing this, we bring pluggable kernel to k8s pod/containers.
What do you guys think? Thanks :-)

Hi @smarton6626 - thanks for raising the query. I think.... we already support that to some extent in Kata :-)  If you have a look at https://github.com/kata-containers/documentation/issues/294, Kata can currently support a 'kernel per pod' using annotations to the pod YAML.
That will get you the ability to choose which kernel runs for which pod (and also if no annotations are present, a pod will still get the default kernel).
Modules are slightly more tricky, but I think have been shown to be possible with Kata before. The things with modules for kata are:

by default the kata kernel has modules disabled I believe
you would need to get the modules visible to the kernel (so either build them into the image file, or somehow mount a host side directory into the VM filesystem space)
the container workloads themselves by default will not be able to see those module dirs or request a kernel module load - but, maybe modules should not be getting loaded by the containers themselves, so.....
you may need some mechanism to trigger module loads. iirc, this was done last time (for GPU modules for instance) using hooks...

There are two things we could really do with that I am aware of wrt all of this:

We could really do with proper documentation around the annotations for the kata kernel and image over-rides for k8s
We were discussing adding/supporting an annotation for each and every kata config item in the kata configuration file in the k8s YAML - that discussion is over at https://github.com/kata-containers/runtime/issues/753 I think

/cc @bergwolf @mcastelino for any status update on that annotations work.

Hi, @grahamwhaley , thanks for your reply! Yes, kata already supports that to some extent. But, IMO, it's not flexible enough as BYOK, and, somehow it makes users coupled with the platform.
For example, in a private k8s cloud,  to use a specific kernel the user needs to deliver the kernel file to k8s administrator, then administrator put the kernel into all nodes and tell the user the kernel-file-path on host (exposure?).
And in a public cloud, that's nearly impossible...

Ah, I see what you mean @smarton6626 - yeah, that is going to be more difficult. So, you'd need to deliver an image for kata to use, and you are suggesting maybe that could be delivered in another docker image. Interesting idea. I'm sure there are going to be some hurdles to get over there - I'll leave that for others with more knowledge in those areas to think about :-)

Yes! @grahamwhaley - Docker image is regarded as the ultimate solution for app packaging, also I think it could be as for kernel :-)

@smarton6626 thanks for raising this, I have some security concerns. The "user" (hacker/cracker) would be able to:

Create a fake kernel that would be loaded by QEMU and executed by seabios.
Build a linux kernel with vulnerabilities in the namespaces, the workload would be able to scape from them and have access to the kata-agent and vsock/serial port to inject payloads.
2.2. Use BPF to control the communication between the kata-agent and kata-shim/kata-proxy

From my point of view, I wouldn't like to include this feature in kata

@devimc thanks for your input! I understand your concerns. My knowledge is limited. I just consult:
About 1, a user of public cloud (eg. aws ec2) has full control of his/her VM instance, also could create fake kernel. Is that similar with kata scenario?
About 2, still think about the VM in public cloud. Cloud vendor also inject some agents (eg. qga) to VMs, and user could access them and serial port. Are they similar with kata-agent?

You could just do this (place vmlinuz/x on the hosts) with a daemonset today, right?

@egernst - hmm... yes, that's right. But, it's somewhat heavy. For each kernel, the user needs to add a daemonset to k8s, and wait for it being applied to all nodes.
Besides, should the user create the daemonset? Should the user be granted privilege to write file on hosts?
I think it's about the way in which k8s being used. Sometimes the user is also the administrator of k8s cluster. But in a bigger organization, usually there will be a team to build, maintain and operate a private cloud, thus the user and the administrator are decoupled, and the user's authority usually is constrained.


A section for 'Best practices'

There's an issue (https://github.com/nodejs/node/issues/2165) with HFS+ where unicode paths returned by the file system are not necessarily the same as the ones that were written because HFS+ forces certain code points to be in NFD form apparently. The consensus looks to be to avoid unicode normalization in node and instead delegate the normalization task to the user.
I could litter all related methods in fs and process with a note that strings aren't necessary comparable depending on file system, but I think a better approach would be a  section where we could advice on pitfalls like this.

Sounds less "best practices" and more "here be dragons", but I agree that it'd be good to document some of the weird and unexpected things users might need to be aware of.

Thanks @silverwind .
Just to urge that the docs should not make it out to be a thorny issue. It's actually very simple and straightforward to work with when one takes a few minutes to understand it. It's filesystems 101 essentially. When people don't understand how Unicode normalization works they tend to panic and reach for the normalize-everything footgun. That's the real danger.
Perhaps it would be good to start with a section on non-case preserving filesystems to make people aware of that and then frame the Unicode normalization in the same light (it is exactly the same concept). And also to emphasize that normalization should only ever be used to compare data, never to change it when storing or passing on. A few links to some of Linus' rants might also help.

I can help with writing out a draft for this if needed.

I didn't refer to it as "here be dragons" due to difficulty, it was because it's a thing that can easily be an invisible footgun, so awareness is important. I generally read "best practices" as, "these are some good ways to do a thing" and not "absolutely do this, or you will suffer".
Also, I'm not sure linking to Linus' rants is quite the tone we'd want to set.

I don't particulary like 'here be dragons', as I hear a certain tone of 'unfinished content', or as Wikipedia puts it:

"Here be dragons" means dangerous or unexplored territories, in imitation of a supposed medieval practice of putting dragons, sea serpents and other mythological creatures in uncharted areas of maps.

'Best practice' implies to me that there is bad practice that will bite you in edge cases, but I'm open to more suggestions of course. Naming things is hard.
@jorangreef you are very knowledgeable on this subject, and I'd love if you could write something up once we've decided on a name. I think it'd best handled in a PR to the website repo then.

@silverwind I have a draft "Best practices when working with filesystems" which is up at: https://www.dropbox.com/s/7b1swypm08v76wo/Best practices when working with filesystems.html?dl=0
It focuses on case, Unicode form and timestamp resolution differences between filesystems. These are similar concepts and once understood they can be applied to other aspects of filesystem differences such as inodes, permissions etc. I picked these three since they are similar and help to reinforce the idea that code needs to take filesystem behavior into account and preserve user data as much as possible, without resorting to a lowest common denominator approach. Please let me know what you think and what can be improved.
Should this be linked to under "File System" in the API docs? Perhaps with a short 1 paragraph summary? Should I submit the pull request to nodejs/node?

I'll read up on that on the weekend, thanks.
I think it would fit nicely in a separate section here at https://nodejs.org/en/docs/, which is likely managed on the website repo. Of course we should like to it eventually from fs and the relevant process methods.

Some more title suggestions:

Working with Node.js
Gotchas (Strikes me a bit as a slang)
Common Pitfalls (might be too negative)

@jorangreef wow, you went into great detail there, great writeup indeed!
I'd say as a first step, you create a PR on the website repo to add it in markdown form, just like this one here: https://github.com/nodejs/node/issues/330.
I think at this kind of detail, this would qualify and warrant a 'guides' section.

Thanks @silverwind I have created the pull request at https://github.com/nodejs/new.nodejs.org/issues/249
At the moment it is not linked to from the docs anywhere. Will someone else create the guides section?

Oh by the way, this is fixed: https://nodejs.org/en/docs/guides/


Alert box styling seems not to actually work

Now that it's released (I was never able to get it to build locally), I notice that the alert-box styles added in #10034/#10021 don't actually seem to take effect:

In regular markdown documents, they are correctly injected, but refer to css variables (--theme-error-background etc) which seem to only exist inside notebooks. Where do these variables come from?
In notebooks, the CSS file appear not to be injected at all. Perhaps this is a bug in the code notebook handling of VSCode, and no in this reposistory

Environment data

VS Code version: 1.68.0
Jupyter Extension version (available under the Extensions sidebar): v2022.5.1001610507
Python Extension version (available under the Extensions sidebar): N/A
OS (Windows | Mac | Linux distro) and version: Gitpod
Python and/or Anaconda version: N/A
Type of virtual environment used: N/A
Jupyter server running: Remote

Expected behaviour
These lines should inject a stylesheet into the markdown cells of notebooks
https://github.com/microsoft/vscode-jupyter/blob/d3f539ed4a586c195485f0ec8e0a5fbf1cdcd391/package.json#L2059-L2061
Actual behaviour
The styles are only injected into plain markdown documents, and there the CSS variables aren't available.
Steps to reproduce:
Open https://nbviewer.org/github/ipython/ipython-in-depth/blob/master/examples/Notebook/Notebook Basics.ipynb in vscode, note that the alert boxes do not render differently.
Create a markdown file containing

I'm in danger

and open the markdown preview. Note that the colors are absent but the indentation is present.

I personally think we should revert the code added in the previous PRs used to address this issue (as it doesn't work), and re-do this as extension into the notebook Markdown renderer as described here These lines should inject a stylesheet into the markdown cells of notebooks

IMO the bug here is that the jupyter notebook viewer doesn't respect markdown.previewStyles; if other vscode extensions add extra styles for markdown, these should probably be visible in jupyter notebooks too.

I currently use alert boxes in student assignments for jupyter notebook in order to make it easier for students to see the question prompts. In JupyterLab, the default alert styles have low contrast between the text and  the background:

## No color style

Some text
here

Because of this low contrast I explicitly set the color so that the text is easier to read in JupyterLab, which is the editor most of our students use:

## Black color style

Some text
here

This works really well and makes things easier to read. However, because of this issue in VS Code preventing the alert boxes from being displayed, this is what the students using VS Code see in these assignments:

This makes them unusable and they are currently either changing to a light theme, switching back to JupyterLab to work, or having two windows open side by side. Is there any workaround for this that would allow students working in vscode to actually see the alert boxes, or at least have the text automatically switch color to white when in vscode? JupyterLab shows this just fine in dark mode:

Looks like https://github.com/microsoft/vscode-jupyter/issues/8399 has regressed and perhaps needs to be re-implemented.

@amunger assigning to you as the PR was reverted and pending the investigation into what caused the issue in markdown and how we can address that.

Alert styling was one of the simplest ways of rendering styled alert boxes in Jupyter notebooks for many years. More recently, use of MyST syntax, such as admonition blocks, provide another way of including richer styled content in a markdown block.
In JupyterLab, this is rendered using the jupyterlab-myst extension; a VS Code extension —  ExecutableBookProject.myst-highlight — supports rendering for MyST markdown extensions such as admonition blocks, but I don't think these extensions work in the notebook rendering context?

I don't see any alert styling on the notebook at https://nbviewer.org/github/ipython/ipython-in-depth/blob/master/examples/Notebook/Notebook Basics.ipynb

Seems like there isn't a pre-release for the notebook renderers extension, so I just don't have the code

new version was never released. doing that now and it should be available with insiders

verify you see the colors in a markdown preview for a markdown cell with contents

Enter edit mode by pressing `Enter` or using the mouse to click on a cell's editor area.

Enter command mode by pressing `Esc` or using the mouse to click *outside* a cell's editor area.

Do not attempt to type into a cell when in command mode; unexpected things will happen!


2 files found with path 'lib/arm64-v8a/librenderscript-toolkit.so' from inputs:

Please complete the following information:

Library Version [e.g. v1.0.0]
Affected Device(s) [e.g. Samsung Galaxy s10 with Android 9.0]

Describe the Bug:
When I add dependency, build failed with error below
2 files found with path 'lib/arm64-v8a/librenderscript-toolkit.so' from inputs:
 - C:\Users\Abdullah\.gradle\caches\transforms-3\23515a2d5ac95b51b5e088c48f2c0985\transformed\landscapist-transformation-2.3.2\jni\arm64-v8a\librenderscript-toolkit.so
 - C:\Users\Abdullah\.gradle\caches\transforms-3\ff9c9829dce8f7dd285ca53b4fe40b06\transformed\cloudy-0.1.2\jni\arm64-v8a\librenderscript-toolkit.so
If you are using jniLibs and CMake IMPORTED targets, see
https://developer.android.com/r/tools/jniLibs-vs-imported-targets

Expected Behavior:
A clear description of what you expected to happen.

Hi @akardas16, sorry for the late response, You can resolve this issue by adding this to the module that uses Cloudy or your app module.
packagingOptions {
    pickFirsts.add("lib/*/librenderscript-toolkit.so")
}

Hi @akardas16, sorry for the late response, You can resolve this issue by adding this to the module that uses Cloudy or your app module.
packagingOptions {
    pickFirsts.add("lib/*/librenderscript-toolkit.so")
}

Still not working. I have got same error after adding it


Test mock .ics or events.json file

Use https://codesandbox.io to test FullCalendar with a basic .ics or events.json file with 2-3 events.

Solved by https://github.com/finos/calendar/pull/53.


Different postscript output

Hi
I have used to convert pdftops in linux, i am getting different type of postscript output as tested below.

If i use only text in PDF i am getting the postscript with the character i could able to find
If i use one text box  and one image the entire postscript comes as binary.

Let me know this is the feature of the pdftops?
Thanks in Advance

pdftops is not a Matlab utility or under maintenance in export_fig - it is an external applications (part of Xpdf). You need to ask this question on their website.

Hi Altmany,
Thanks for your advise, i will post the question to Xpdf forum.


rename query -> itiriri

Pull Request Test Coverage Report for Build 181

0 of 0   changed or added relevant lines in 0 files are covered.
70 unchanged lines in 1 file lost coverage.
Overall coverage decreased (-11.3%) to 88.684%

Files with Coverage Reduction
New Missed Lines
%

build/compiled/lib/Query.js
70
33.33%

Totals

Change from base Build 167:
-11.3%

Covered Lines:
543

Relevant Lines:
613

💛  - Coveralls

Pull Request Test Coverage Report for Build 181

0 of 0   changed or added relevant lines in 0 files are covered.
70 unchanged lines in 1 file lost coverage.
Overall coverage decreased (-11.3%) to 88.684%

Files with Coverage Reduction
New Missed Lines
%

build/compiled/lib/Query.js
70
33.33%

Totals

Change from base Build 167:
-11.3%

Covered Lines:
543

Relevant Lines:
613

💛  - Coveralls


Consider adding this project to Bazel's CI.

If I read this documentation correctly:
https://github.com/bazelbuild/continuous-integration/blob/master/buildkite/README.md
It is possible to include our project in the list of projects tested by Bazel as they make changes. This would let them (and us) discover if any new release is about to break us.
See #101 for the motivation.

Maybe I'll start this with a simple build on Ubuntu 18.04.

https://github.com/bazelbuild/continuous-integration/issues/811

Added, the dashboard is at:
https://buildkite.com/bazel/github-dot-com-googleapis-google-cloud-cpp-spanner
The builds are red now, but it is because the build is serving a purpose.
Closing this issue


Categorical features in sklearn API warning

How you are using LightGBM?
LightGBM component: Python package
Environment info
Operating System: macOS Catalina Version 10.15.2 (19C57)
CPU/GPU model: 1,4 GHz Quad-Core Intel Core i5
C++ compiler version: Apple clang version 11.0.3 (clang-1<IP_ADDRESS>)
Python version: 3.7
Error message and / or logs

I use the categorical_feature option in LGBMRegressor and I get the following warning:
UserWarning: Using categorical_feature in Dataset. warnings.warn('Using categorical_feature in Dataset.')
Is this expected? Do you know why is this happening, what does it mean?
Reproducible example(s)
import pandas as pd
from sklearn.datasets import load_iris
from lightgbm import LGBMRegressor
from category_encoders import OrdinalEncoder

X = load_iris()['data']
y = load_iris()['target']

X = OrdinalEncoder(cols=[3]).fit_transform(X)

dt = LGBMRegressor()
dt.fit(X, y, categorical_feature=[3])

Yes, it is expected. This warning was originally introduced to make users sure that their categorical features were not lost.
Please refer to #792.
And we already have a request to refactor group of warnings related to cat. features: #3379. Feel free to comment there and share your opinion on how these warnings can be improved.


configure fails on gcc 6.0

I've been trying to compile on fedora 24 and I'm running into this bug issue:
src/auto/config.log
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.

It was created by configure, which was
generated by GNU Autoconf 2.69.  Invocation command line was

  $ auto/configure --enable-multibyte --enable-python --enable-rubyinterp --enable-luainterp --with-tlib --srcdir=. --cache-file=auto/config.cache

## --------- ##
## Platform. ##
## --------- ##

hostname = fedora24.local
uname -m = x86_64
uname -r = 4.5.3-300.fc24.x86_64
uname -s = Linux
uname -v = #1 SMP Thu May 5 01:56:27 UTC 2016
....
## ----------- ##
## Core tests. ##
## ----------- ##

configure:2531: loading cache auto/config.cache
configure:2617: checking whether make sets $(MAKE)
configure:2639: result: yes
configure:2697: checking for gcc
configure:2713: found /usr/bin/gcc
configure:2724: result: gcc
configure:2953: checking for C compiler version
configure:2962: gcc --version >&5
gcc (GCC) 6.0.0 20160406 (Red Hat 6.0.0-0.20)
Copyright (C) 2016 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

configure:2973: $? = 0
configure:2962: gcc -v >&5
Using built-in specs.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/usr/libexec/gcc/x86_64-redhat-linux/6.0.0/lto-wrapper
Target: x86_64-redhat-linux
Configured with: ../configure --enable-bootstrap --enable-languages=c,c++,objc,obj-c++,fortran,ada,go,lto --prefix=/usr --mandir=/usr/share/man --infodir=/usr/share/info --with-bugurl=http://bugzilla.redhat.com/bugzilla --enable-shared --enable-threads=posix --enable-checking=release --enable-multilib --with-system-zlib --enable-__cxa_atexit --disable-libunwind-exceptions --enable-gnu-unique-object --enable-linker-build-id --with-linker-hash-style=gnu --enable-plugin --enable-initfini-array --disable-libgcj --with-isl --enable-libmpx --enable-gnu-indirect-function --with-tune=generic --with-arch_32=i686 --build=x86_64-redhat-linux
Thread model: posix
gcc version 6.0.0 20160406 (Red Hat 6.0.0-0.20) (GCC)
configure:2973: $? = 0
configure:2962: gcc -V >&5
gcc: error: unrecognized command line option '-V'
gcc: fatal error: no input files
compilation terminated.
configure:2973: $? = 1
configure:2962: gcc -qversion >&5
gcc: error: unrecognized command line option '-qversion'; did you mean '--version'?
gcc: fatal error: no input files
compilation terminated.

What happened to make you close this issue? Did it disappear on "make reconfig" or similar? Or was it something else?

For some reason doing configure with --enable-rubyinterp was causing the issue, as soon as I dropped that flag I was able to configure and install correctly. I tried doing configure using --with-tlib as well and that did not help.
./configure --enable-fail-if-missing     --enable-luainterp --with-luajit     --enable-perlinterp     --enable-pythoninterp     --enable-python3interp     --enable-rubyinterp     --enable-tclinterp     --enable-multibyte     --enable-fontset
....
checking for tgetent in -lcurses... no
no terminal library found
checking for tgetent()... configure: error: NOT FOUND!
      You need to install a terminal library; for example ncurses.
      Or specify the name of the library with --with-tlib.

I do indeed have ncurses installed:
~/git/vim [master] $ sudo dnf search ncurses*
Last metadata expiration check: 0:14:19 ago on Thu May 12 23:26:38 2016.
============================================================================== N/S Matched: ncurses* ==============================================================================
ncurses-libs.x86_64 : Ncurses libraries
ncurses-libs.i686 : Ncurses libraries
ncurses.x86_64 : Ncurses support utilities
ncurses-c++-libs.x86_64 : Ncurses C++ bindings
ncurses-c++-libs.i686 : Ncurses C++ bindings
ncurses-compat-libs.x86_64 : Ncurses compatibility libraries
ncurses-compat-libs.i686 : Ncurses compatibility libraries
ncurses-base.noarch : Descriptions of common terminals
ncurses-term.noarch : Terminal descriptions
ncurses-devel.x86_64 : Development files for the ncurses library
ncurses-devel.i686 : Development files for the ncurses library
ncurses-static.x86_64 : Static libraries for the ncurses library
ncurses-static.i686 : Static libraries for the ncurses library
nudoku.x86_64 : Ncurses based Sudoku game
dhex.x86_64 : Ncurses based hexadecimal editor with a diff mode
Vuurmuur-tui.x86_64 : Ncurses based interface for modifying Vuurmuur configuration
wavemon.x86_64 : Ncurses-based monitoring application for wireless network devices

Here's the full log.
The only things which stood out where errors similar to this:
configure:11256: result: no
configure:11262: checking --with-tlib argument
configure:11297: result: empty: automatic terminal library selection
configure:11305: checking for tgetent in -ltinfo
configure:11330: gcc -o conftest -g -O2  -L. -Wl,-z,relro -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -fstack-protector -rdynamic -Wl,-export-dynamic -Wl,--enable-new-dtags -Wl,-z,relro    -L/usr/local/lib conftest.c -ltinfo     >&5
/usr/bin/ld: /tmp/cceImN4i.o: relocation R_X86_64_PC32 against undefined symbol `tgetent' can not be used when making a shared object; recompile with -fPIC
/usr/bin/ld: final link failed: Bad value
collect2: error: ld returned 1 exit status
configure:11330: $? = 1

Are you install ncurses-devel?
$ sudo dnf install ncurses-devel

Yeah, it's installed....
~ $ sudo dnf install ncurses-devel-6.0-5.20160116.fc24.x86_64
Last metadata expiration check: 0:47:36 ago on Thu May 12 23:26:38 2016.
Package ncurses-devel-6.0-5.20160116.fc24.x86_64 is already installed, skipping.
Dependencies resolved.
Nothing to do.
Complete!

On Friday, May 13, 2016 at 9:47:26 AM UTC+12, Daniel Hodges wrote:

I've been trying to compile on fedora 24 and I'm running into this bug issue:
src/auto/config.log
...
gcc: error: unrecognized command line option '-qversion'; did you mean '--version'?
gcc: fatal error: no input files
compilation terminated.
It seems the error is in src/auto/configure

I've just installed gcc 6 on Ubuntu 16.04, and built vim using --enable-rubyinterp with no trouble.  My config.log contains the errors you report; it continues:
configure:2993: checking whether the C compiler works
I conclude that those errors are not your problem.  You may have concluded the same, since --enable-rubyinterp has nothing to do with that part of configure's processing.
Regards, John Little

Hi everyone!
If someone hits the same problem, the solution is to add:
LDFLAGS="$LDFLAGS -fPIC"
to 'configure' command line invocation. It seems something (probably a tool from autotools - autoconf) does not provide -fPIC into LDFLAGS in Fedora. Because when I manually compile the code (although I need to add <term.h> as include) with -lncurses, it compiles correctly. So either gcc/ld uses -fPIC without my notice, when I use gcc manually, or autoconf does not set it....