🇫🇷France @kumkum29

Account created on 12 July 2010, over 14 years ago
#

Recent comments

🇫🇷France kumkum29

Hello,

I also get this error: "Drupal\externalauth\Exception\ExternalAuthRegisterException : User could not be registered. There is already an account with username...."

In my website, I also have existing accounts, created before the implementation of external Auth. Here is my code to login and/or register user account :

        $this->externalAuth->loginRegister(
          $datas['email'],
          'my_service',
          $account = [
            'mail' => $datas['email'],
            'name' => $datas['email'],
            'status' => 1
          ]
        );

How to resolve this problem ? Do I use another method to create user from an external service?

Thanks.

🇫🇷France kumkum29

Hello,

I am trying to install a new DSN transport for Mailjet. I have installed the Mailjet dependency for Symfony Mailer.
But now, when I want to create this new transport DSN via the interface '/admin/config/system/mailer/transport/add/dsn' I get an error symfony/httpclient not found. However I have installed via composer this new dependency.

How can I solve my problem? Should I configure in the settings.php this new DSN?

Thank you for your help.

🇫🇷France kumkum29

Hi !,

Have you found a simple solution for Drupal 10.2 / 10.3.... ?

Thanks for your replies.

🇫🇷France kumkum29

I tried to build a custom services.yml files with this code : 

 

services:
  database.shared:
    class: Drupal\Core\Database\Connection
    factory: 'Drupal\Core\Database\Database::getConnection'
    arguments: ['shared']
  sessions_shared.handler:
    class: Drupal\Core\Session\SessionHandler
    arguments:
      - '@request_stack'
      - '@database.shared'
      - '%session.storage.options%'
    tags:
      - { name: session }

...with no success....

🇫🇷France kumkum29

Hello nk_,

The latest fixes seem to fix the issues with views. Do you plan to release a new version with this fix?

Thanks.

🇫🇷France kumkum29

Hello,

Exactly, I use views to build the swipers ;)

🇫🇷France kumkum29

Another point, following the update, I no longer have 'swiper-formatter' settings in drupalSettings.

🇫🇷France kumkum29

Hello,

With this patch #5, the option '#step' => '0.5' is too restrictive.
For more granularity and flexibility we need to be able to use different options per swiper/breakpoints. The '#step' => '0.1' option would be more useful.

Is it possible to change this option in a next patch / dev version ?

🇫🇷France kumkum29

Hello,

as @introfini I get this problem with RC13 and Drupal 9.5. The patch #11 resolves it !!
Do you think push this fix in a next version ? Use directly patch on a porduction website isn't perfect...

Thanks.

🇫🇷France kumkum29

Hello,

same problem on my site, I get a strange behavior : I get the error when I want to add media entity. With the patch, It's ok now !!

Do you think include the patch in the dev version ?

Thanks !

Drupal 10.3

🇫🇷France kumkum29

As @anand.panure says, we are facing the same issue on D9.5.11 + ckeditor5. I need to update Drupal to 10.2, but I need to resolve this issue before that.

Is there a quick fix to resolve this problem and keep the position of the inserted media ?

The mentionned fix in #5 already exists in the media_library of core (in D9.5.11).

Thanks.

🇫🇷France kumkum29

Hello,

I tried to remove the component 'edit embedded entity' to simplify the interface without success. Here is my code, in a custom JS (attached in module library).

          if (componentFactory.has('editEmbeddedEntity')) {
            // Remove the 'editEmbeddedEntity' component.
            console.log('Remove component');
            componentFactory._components.delete('editembeddedentity');
          }

However, I can clearly see the console log message but the component (edit embedded entity) is not removed when I click on the entity embed.

Thanks for your help.

🇫🇷France kumkum29

After analyse, i see that the edit entity button is built with this code :

    editor.ui.componentFactory.add('editEmbeddedEntity', (locale) => {
      let buttonView = new ButtonView(locale);

      buttonView.set({
        isEnabled: true,
        label: Drupal.t('Edit the embedded entity (opens in new tab)'),
        icon: icons.cog,
        tooltip: true,
      });

How can I easily hide this button ? (value isEnabled > false ? )

Thanks.

🇫🇷France kumkum29

After analyse, when I switch on 'ckeditor5' format, I get an error in logs :

NetworkError: Failed to execute 'send' on 'XMLHttpRequest': Failed to load 'http://assets-dev......... /image.svg

I use AWS S3 to store the images.

Maybe is related to this ols issue: https://www.drupal.org/project/ckeditor/issues/3403865 🐛 CKEditor not loading on chrome (Failed to execute 'send' on 'XMLHttpRequest') Active

🇫🇷France kumkum29

Hi balu rrtl,

It is true that the default icon does not have the correct formatting.
I see your patch. But after analyse the 'ckeditor5_plugins' directory, I don't see any 'drupalentity' directory in my environment.

My site is built on D9.5.11.

Thanks for your reply.

🇫🇷France kumkum29

Hello,

The names of the subfields were wrong. With this code it's ok ;)

  field_datas:
    plugin: sub_process
    source: external_datas
    process:
      name: data/name
      id: data/no
      type: data/type
🇫🇷France kumkum29

same problem in this issue https://www.drupal.org/project/entity_embed/issues/3416512 🐛 Trying to edit embedded entities causes uncaught exception Needs review

🇫🇷France kumkum29

Hello,

After a lot of testing, I just discovered a strange behavior on Stripe payment. The errors mentionned in the previous post appear if I am connected with user account 1 !
If I use another account, I can complete the payment process without problems, and I can reuse a registered card. (with the Stripe Card Element and Stripe Payment Element method).

Have you ever seen this behavior?

🇫🇷France kumkum29

Hello,

I get the same error using the Stripe Payment Element gateway.

On different posts, several people have this error. But I don't see a real solution.

If I make a first payment, the order and payment work correctly. But if I make a second payment with a registered card in the account, I get this error: The `payment_method` parameter supplied pm_XXXXXXX belongs to the Customer cus_YYYYYYY. Please include the Customer in the `customer` parameter on the PaymentIntent...

In the Stripe account logs i get this error : Error 400 in /v1/payment_intents / parameter_missing - payment_method..

That is strange, because a 'payment_method' exists in the request :

{
  "capture_method": "manual",
  "metadata": {
    "order_id": "35",
    "store_id": "2"
  },
  "automatic_payment_methods": {
    "enabled": "true"
  },
  "currency": "eur",
  "setup_future_usage": "on_session",
  "payment_method": "pm_xxxxxxxx",
  "amount": "3000

Stripe display this warning :

{
  "capture_method": "manual",
  "metadata": {
    "order_id": "35",
    "store_id": "2"
  },
  "automatic_payment_methods": {
    "enabled": "true"
  },
  "currency": "eur",
  "setup_future_usage": "on_session",
  "payment_method": <required>,
  "amount": "3000

Is this a problem with the API version called?

In this post https://www.drupal.org/project/commerce_stripe/issues/3455608#comment-15... 💬 Use Stripe Card Element OR Stripe Payment Element ? Explanation Closed: duplicate , I talk about this problem with jsacksick. Apparently, the implementation of Stripe Payment Element does not allow the use tokenize payment methods. Also it is not possible to manually add a payment method to the account, and perhaps use a registered card.

Can you confirm it? Or does the problem come from another element?

If yes, i must disable to acces payment methods in user account and disable registered card on the payment pane.

Thanks for yours replies and explanations.

🇫🇷France kumkum29

@jsacksick,

thanks for this reply.

Your explanation is clear and allows us to better understand the problem.

So it makes sense that we couldn't manually create a payment method on the user account.

The problem of reusing a registered card in user account may also be due to this type of gateway implementation...

🇫🇷France kumkum29

Hello,

I re-open this issue, because I get the same problem: access denied for the administartor (account 1) with the right permissions (all options are checked). Have you found a solution for this ?

Thanks.

🇫🇷France kumkum29

Hi,

I get the same error, when I want to use a registered card from my account. I try to logout and re-login without sucess. I get a white page and the same error: "Invalid parameters were supplied to Stripe's API."

Do I need to modify a setting on the Payment test gateway?

Thanks for your replies.

🇫🇷France kumkum29

Hello,

After several tests, I re-enabled billing data option on the Stripe test payment gateway. After that, and checking the card registered on the account, I see that an ID is registered on the billing_profile value.

The error is gone...

So, it is necessary to collect biling data to use the cards registered on the account / Or automatically create this data on the order. (hook_order_presave ??)

But, now, If I re-use a registered card on my account I get another error : "Invalid parameters were supplied to Stripe's API."

I see this post on the same problem : https://www.drupal.org/project/commerce_stripe/issues/3428637 🐛 Invalid parameters were supplied to Stripe's API when using stored information Active

What should I change in the settings to avoid this error?

Thanks.

🇫🇷France kumkum29

I have found the error, 'has_order_summary' isn't a valid paramter, we must use 'has_sidebar' instead.

🇫🇷France kumkum29

Hello jsacksick,

yes it was an error on my part, I want to modify the rendering of the attributes to radio buttons.

I don't see in the commerce settings how to proceed.

For the moment, i use this hook to alter the type on the attributes : hook_form_commerce_order_item_add_to_cart_form_alter. It's not user friendly.

Can I choose the display mode in Drupal commerce settings?

Thanks.

🇫🇷France kumkum29

Patch #6 works fine.
Do you think to include this fix in the dev or next release ?

Thanks.

🇫🇷France kumkum29

Hi gbyte,

I'm reopening this post because I don't see in my view settings how to specify a Sitemap display.
Before that, I created a new type of sitemap with Views Generator.

So, I get this message in the sitemap settings (View Tab) : No view displays are set to be indexed yet. Edit a view.

Thanks for your help.

P.S. I use the 4.1.8 version.

🇫🇷France kumkum29

Hi Wombatbuddy,

I tried several tests without finding a correct solution. My cache problems on nodes/pages come from variables created in a preprocess function. I want to keep the dynamic cache active for authenticated users, but keep dynamic data per user. If I activate CSS/JS aggregation, specific variables defined in my preprocess function are not dynamic. Here is an example :

/**
 * Implements hook_preprocess().
 */
function mymodule_preprocess(&$variables) {
  $user_authenticated = \Drupal::currentUser()->isAuthenticated();
  if ($user_authenticated) {
    $user_id = \Drupal::currentUser()->id();
    $variables['user_id'] = $user_id;
    // Push variable to JS files.
    $variables['#attached']['drupalSettings']['user']['id'] = $user_id;
  }
}

The first logged user define the variable 'user_id'. If a second user logs in, he retrieves the first user's $user_id variable on nodes/pages. On the user account, there is no cache, so the data is updated.

Is there a solution to regenerate this variable at each user connection? (unique data for each user). 

I need to push this variable $user_id into JS files. These JS files must be dynamic for each user.

In the preprocess function, I tried to specify a null cache on the variable without success:

  $variables['user_id'] = [
    '#markup' => $user_id,
    '#cache' => [
      'max-age' => 0,
    ],
  ];

Thanks for your help.

🇫🇷France kumkum29

@ wombatbuddy ,

I tested this option, using hook_node_preview / hook_preprocess_node. The first user generates the page cache on the first visit (12s). If another user logs in via another browser, it also generates the page cache in 12s. The second time the page is opened, each authenticated user accesses the page in 1s. The cache is functional for each of them. But the page cache doesn't seem to be shared between authenticated users.

How can I modify the dynamic_cache_page so that the node cache is shared?

Should I create a new service to build a custom cache on the context (user.role:editor) and via a class/service? I need to cache nodes based on user role.

Thanks for your help.

🇫🇷France kumkum29

Hello,

I have the problem on my site with version 3.x of the module. If I use a fulltext search field (exposed field) and facets, and if the 'ajax' option is activated in the view, results doesn't work. For now, I have disabled the ajax behavior in the view so that the search field works with the facets, but on each action the page is refreshed.

I will downgrade the version to 2.0.6 and test the behavior.

🇫🇷France kumkum29

Hi cmlara,

I also get this error on my site since I switched to the php8.1 version. Before and with php 7.4 version I haven't any problem.

Now I can no longer upload images to my S3 space... :(

Here is my config :
- drupal core 9.5.10
- guzzle 6.5.8
- s3fs module 3.3.0
- php 8.1 (or 8.2)
- aws sdk php 3.240.0

How use the s3fs module with php version 8? Should I update a library? module ?

Thanks for your help.

🇫🇷France kumkum29

@breidert, I have tested on several theme the 'frontend editing' module.

Claro > OK
Olivero > OK
Gin > OK
Radix base > OK
My subtheme on Radix > KO

The problem seems to be with my custom theme (On Radix) and how I include elements in templates. With the 1.1.1 version I haven't see this problem.

So I'm looking to modify the rendering of the entities in my tpls...

Thanks.

🇫🇷France kumkum29

Same problem for me with a site built with the radix version 5.0.4.
For the moment, I have altered the views-view.html.twig template inside my custom theme.

🇫🇷France kumkum29

Hello,

I need to use this feature to set up 'levels' of promotions (depending on the quantity), eg:

0 - 9 > no promotion
10 - 20 > 10%
20 - 50 > 25% ...

How can I Proceed ?

Thanks for your help.

Production build 0.71.5 2024