c ++ – Sublime Text does not work properly

I installed Sublime Text on my linux. I opened the test.cpp file which contains the following code:


using namespace std;

int main() {

    cout << "Hello World!" << endl;

    return 0;

But when I run, the code only appears: (Completed in 0.9s)

Hello world does not appear, and when I put a read command either. I thought it was not executing my code, but only opening it in the sublime, I can't verify.

I've updated my YouTube brand profile photo, but it does not show up properly in comments

I created a brand account on YouTube yesterday and, having all the media ready, I started uploading photos and banners. Everything seemed to be okay and once the download finished, I noticed that the image only appears on the channel page, but not elsewhere (including the button on the upper right corner). ). I waited a day and erased my images and it solved the problem for the top corner, but in the comments section, it's still the default "letter" avatar. Even when I add new comments.

I've tried the YouTube community forums, but I was able to find only one thread with 250 positive votes and no response.

How to properly back up and restore a team site with a laptop?

Work in On-Prem SharePoint 2013.

I see many articles on the use of PowerShell commands:

Backup-SPSite http://sp/test/Claims -Path E:WorkingTestClaims.bak
Restore-SPSite -Identity http://sp/test/ClaimsRestore -Path E:WorkingTestClaims.bak

It works fine, the new site collection is created and displays the content. Most.

Problem: The site I work with is a team site and, as such, it has a notebook. In the source site, the notebook works and I put a few pages of content for this test. But in the restored site, the notebook does not show up, but gives an error. It's as if this part had not been restored.

Sorry, something went wrong
An error has occurred on the server
Looking up the Correlation ID in logs, the error is:  The system cannot find the file specified
Requested URL is: GET:http://sp:80/test/ClaimsRestore/_layouts/15/WopiFrame.aspx?sourcedoc=%2Ftest%2FClaims%2FSiteAssets%2FSharePoint%20Test%20Site%20Collection%20Notebook&action=editnew

I've also tried pre-creating the destination site collection, using the team website template. A notebook has been created. I've used the -force switch for restore. However, again, the rest of the content was there, but the notebook was broken.

What else can I do to make sure the laptop is backed up and restored successfully?

Thank you!

Does my Tamron VC lens (image stabilization) work properly for long-exposure shots taken with a tripod?

Tamron manual VC instructions below.

Note in particular:
1. Disable the VC switch when using a tripod.
2. The VC mechanism can introduce errors during long exposures.
3. When the shutter button is pressed halfway, it takes about 1 second for the VC to provide a stable picture.
4. When VC is not used, set the switch to Off.

How to use the VC mechanism
1] Turn on the VC switch.
When VC is not used, turn off the switch.
2] Press the shutter button halfway to check the VC effect.
When the shutter button is pressed halfway, it takes about 1 second for the VC to provide a stable picture.

The VC can be effective for hand-firing under the following conditions.
• Low light places
• Scenes where flash photography is prohibited
• Situations where your foot is uncertain
• Take panoramic pictures of a moving subject

The VC may not be able to give full effect in the following cases:
• When a photo is taken from a fast moving vehicle
• Shooting during the excessive movement of the camera
• Turn off the VC switch when taking pictures with the bulb setting or during long exposures. If the VC switch is ON, the VC mechanism may introduce errors.

• With the VC mechanism, sometimes the image in the viewfinder becomes scrambled just after the shutter button is pressed halfway, but it is not a malfunction.
• When VC is on, the number of recordable pictures is reduced due to the power used by the camera.
• When the VC is turned on, immediately after the shutter button is pressed halfway and about 2 seconds after the shutter release button is released, the camera will "click". This sound is the locking mechanism of the VC that turns on, not a malfunction.
• Disable the VC switch when using a tripod.
• After releasing the shutter button, the VC will continue to operate for about 2 seconds until the lock mechanism activates.

shipping – The authorized country does not work properly in magento2.3.3?

I have two stores (for example: store 1 and 2). Both have different shipping destinations.

As part of the website, I had set Store 1 Japan for authorized countries. And for Store 2, they are non-European countries (United States, Canada, etc.).

However, the problem is that when I go to the shipping page of the fund, the country that was also configured by default must be in the United States, Canada but not Japan, but unfortunately, Japan also in the list.

As you can see in the image, in the administrator's control panel, Japan is not included in the list of authorized countries of the first image. But in the shipping page of the checkout, Japan now appears in the country option.
Is this possible, only to display the authorized country in the scope of the website for the country option?

enter the description of the image here

enter the description of the image here

8 – The preview of the model does not work properly

I have a big problem with the preview of my model. For all my post (page, article and so on), I do not have the right region in my page.

My theme is Extended Classy.

If I go to see the page (not preview), I have the right page.
But if I want to see a preview of this page, I miss a region (I guess it's a region).

See my page – post-type.html.twig

        {% include '@theme/layout/header.html.twig' %}
    {% include '@theme/includes/page-head.html.twig' %}
    {% include '@theme/includes/page-breadcrumb.html.twig' %}
    {% include '@theme/includes/page-entry.html.twig' %}

{{ some displayed data }}
{% include '@theme/layout/footer.html.twig' %}

My included files work (both for preview and view), but the preview is not on this page, but guess.

The last block included is this for preview:

BEGIN OUTPUT from 'themes / theme / templates / block / block.html.twig & # 39;

And for some reason, after having this:

BEGIN OUTPUT from 'core / themes / classy / templates / content / node.html.twig & # 39;

if it helps, my .theme file:

 * Implements hook_theme_suggestions_page_alter().
function theme_theme_suggestions_page_alter(&$suggestions, $variables) {
//    $node = Drupal::routeMatch()->getParameter('node');
    if ($node = Drupal::routeMatch()->getParameter('node_preview')){
        $node = Drupal::routeMatch()->getParameter('node_preview');
//        if ($node instanceof DrupalnodeNodeInterface) {
//            $suggestions() = 'page__' . $node->bundle() . '_preview';
//            $suggestions() = 'page__node_' . $node->bundle() . '_preview';
//        }

    } else {
        $node = Drupal::routeMatch()->getParameter('node');
        if ($node instanceof DrupalnodeNodeInterface) {
            $suggestions() = 'page__' . $node->bundle();
            $suggestions() = 'page__node_' . $node->bundle();

//    dump($suggestions);


And I also have this function alstef_preprocess_node () that I pulled from this: set the block region in the node pattern

I've been stuck for hours, any help will be appreciated.

PS: I'm working on Drupal 8 with a custom theme (called here 'theme').

EDIT : I just dumped my node, and the node is null if I'm on my page – post-type.html.twig or page – post-type-preview.html.twig with preview (edit with suggestions )

The promise of the Google Drive API does not come back at all when it is called from an AWS Lambda function (but works properly locally)

We call the Google Drive v3 API (with OAuth2 permission) to list the files on the drive. It works fine when it is run locally from my Mac, but if the function is deployed on AWS Lambda and called from there, the call will simply not be forwarded. I'm waiting for a promise to resolve or reject, but that promise never comes back, nor in. Then neither .Catch or .finally.

The parameters transmitted to the call locally and in Lambda are exactly the same. The only difference I can see is that Lambda is running on node 10.17 and local is running on node 10.15.

When I look a little further into the API code, this one eventually calls a common apirequest.js file that calls Google OAuth2's .request () client method. Here again, locally and in the Lambda, the parameters are identical. This .request () client call returns a promise that is never resolved or rejected by Lambda. When it is run locally, it resolves as expected.

You will find below the parameters passed to the OAuth2 client.

url: 'https://www.googleapis.com/drive/v3/files',
method: 'GET',
paramsSerializer: (Function),
        'x-goog-api-client': 'gdcl/3.1.1 gl-node/10.17.0',
        'Accept-Encoding': 'gzip',
        'User-Agent': 'google-api-nodejs-client/3.1.1 (gzip)' 
        pageSize: 200,
        fields: 'nextPageToken, files(name, id, parents)',
        'mimeType="application/vnd.google-apps.folder" and trashed=false',
        supportsAllDrives: true,
        supportsTeamDrives: true,
        includeItemsFromAllDrives: true,
        driveId: '0AOWo32MbqS8pUk9PVA',
        corpora: 'drive'
validateStatus: (Function),
retry: true

Any help, advice or ideas are welcome 🙂

Thank you

c ++ – Why does this longer-escalation sub-sequence problem not work properly?

I have defined recursively to work case by case. I'm getting wrong answers using large enough test data, but it works well for smaller cases.

  int LIS(100000);
  void LS (int *arr , int n)
      if (n == 0)
          LIS(0) = 1;
      if (LIS(n))
      int i = 0;
      int max = 0;
      while (i < n)
          if (arr(i) < arr(n))
              if (LIS(i) + 1 > max)
                  max = 1 + LIS(i);
      LIS(n) = max;

  int main()
      int n;
      std::cin >> n;
      int arr(n);
      for(int i = 0 ; i < n ; ++i) std::cin >> arr(i);
      std::sort (LIS , LIS+n);
      std::cout << "n" << LIS(n-1) << "n";

macos – iMessage of the computer does not work properly. I have tried everything. Messages not synchronized, not sent

I have latest iOS on an iPhone SE and MacOS Mojave on a desktop with Airdrop and everything (not that the latter counts).

However, SMS messages sent to my iphone do not display and now I am trying to send a message to an iphone user from a computer and it is being loaded.

do not burst on the phone strong textas failed sent no more.

I've literally tried everything. Verified number, synchronized iCloud, paired with Bluetooth, USB, Wi-Fi, enabled and disabled, in your phone and computer settings. MacOS is newly installed, so no complaints with the computer.

Is this a known problem? I am a computer engineer, so keep this in mind when you are suggesting something like turning off the phone, iMessage, Bluetooth, etc.

debian – Timeout on the NGINX reverse proxy, the backend is working properly


I've set up a NGINX reverse proxy with a Docker container as a backend (an instance of Gitea). The problem is that NGINX has a 504 Timeout error, but by accessing the fixed menu directly, it works well.

My NGINX configuration:

server {
    listen 80;
    server_name gitea.myserver.com;

    location / {
        proxy_set_header Host $http_host;
        proxy_set_header X-Real-IP $remote_addr;
        proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
        proxy_set_header X-Forwarded-Proto $scheme;

Accessing http://gitea.myserver.com:11180 works fine on my browser. Make a curl on the server works well too.

I already had the same problem yesterday, and the problem was solved when I recreated my Docker container, but today it no longer works. And recessing containers did not solve the problem. It seems to be really random.

PS: Other Docker containers work properly with the same NGINX reverse proxy. I am on Debian 10.