• Resolved gchris2

    (@gchris2)


    When I try to configure Google Site Kit, I get the following error message after completing the steps to log in. I receive the error message ‘string(11) “Bad Request”‘. I don’t understand why this is happening. It’s a new WordPress installation, and I’ve gone through this process about 15 times with other websites. The URL looks like this when I get the error message:

    https://fakeurl.uu/wp/wp-admin/index.php?oauth2callback=1&authuser=0&code=4%2F0AeaYSHAMiKyL7slTEPTivAtY1866gNOyUQhkmNMvm67vLiIIchHPmJONlfUCGFRr-_sLZA&prompt=consent

    I’ve tried both Chrome and Firefox, and even incognito mode. Resetting Site Kit also doesn’t help.

    ` wp-core
    
    version: 6.4.3
    site_language: nl_NL
    user_language: nl_NL
    timezone: Europe/Amsterdam
    permalink: /%postname%/
    https_status: true
    multisite: false
    user_registration: 0
    blog_public: 1
    default_comment_status: closed
    environment_type: production
    user_count: 3
    dotorg_communication: true wp-paths-sizes
    
    wordpress_path: /data/sites/web/xxx/checkout/master/98e6719f8a15063c2595fe0a8d7cf9cac9e9b5c3/web/wp
    wordpress_size: 54,03 MB (56657267 bytes)
    uploads_path: /data/sites/web/xxx/checkout/master/98e6719f8a15063c2595fe0a8d7cf9cac9e9b5c3/web/app/uploads
    uploads_size: 991,61 MB (1039776346 bytes)
    themes_path: /data/sites/web/xxx/checkout/master/98e6719f8a15063c2595fe0a8d7cf9cac9e9b5c3/web/app/themes
    themes_size: 172,04 MB (180399946 bytes)
    plugins_path: /data/sites/web/xxx/checkout/master/98e6719f8a15063c2595fe0a8d7cf9cac9e9b5c3/web/app/plugins
    plugins_size: 85,46 MB (89614232 bytes)
    database_size: 6,11 MB (6406144 bytes)
    total_size: 1,28 GB (1372853935 bytes) wp-dropins (1)
    
    advanced-cache.php: true wp-active-theme
    
    name: xxx
    version: 10.0.0-dev
    author: xx
    author_website: https://xx.xx
    parent_theme: none
    theme_features: sage, widgets-block-editor, soil, menus, editor-color-palette, editor-gradient-presets, editor-font-sizes, custom-units, custom-line-height, custom-spacing, disable-custom-colors, disable-custom-gradients, disable-custom-font-sizes, title-tag, post-thumbnails, align-wide, responsive-embeds, html5, customize-selective-refresh-widgets, widgets
    theme_path: /data/sites/web/xx/checkout/master/98e6719f8a15063c2595fe0a8d7cf9cac9e9b5c3/web/app/themes/xx wp-mu-plugins (3)
    
    Bedrock Autoloader: version: 1.0.3, author: Roots
    Disallow Indexing: version: 1.0.0, author: Roots
    Register Theme Directory: version: 1.0.0, author: Roots wp-plugins-active (11)
    
    Advanced Custom Fields PRO: version: 6.2.5, author: WP Engine (latest version: 6.2.6.1)
    Gravity Forms: version: 2.8.3, author: Gravity Forms
    Gravity Forms reCAPTCHA Add-On: version: 1.4.0, author: Gravity Forms
    ManageWP - Worker: version: 4.9.19, author: GoDaddy
    Redirection: version: 5.4.2, author: John Godley
    Site Kit by Google: version: 1.119.0, author: Google
    SVG Support: version: 2.5.5, author: Benbodhi
    WP-PageNavi: version: 2.94.1, author: Lester 'GaMerZ' Chan
    WP Migrate Lite: version: 2.6.9, author: WP Engine (latest version: 2.6.10)
    Yoast Duplicate Post: version: 4.5, author: Enrico Battocchi & Team Yoast
    Yoast SEO: version: 21.9.1, author: Team Yoast (latest version: 22.0) wp-plugins-inactive (1)
    
    WP Rocket: version: 3.15.9, author: WP Media wp-media
    
    image_editor: WP_Image_Editor_Imagick
    imagick_module_version: 1691
    imagemagick_version: ImageMagick 6.9.11-60 Q16 x86_64 2021-01-25 https://imagemagick.org
    imagick_version: 3.7.0
    file_uploads: 1
    post_max_size: 256M
    upload_max_filesize: 256M
    max_effective_size: 256 MB
    max_file_uploads: 20
    imagick_limits:
    imagick::RESOURCETYPE_AREA: 122 MB
    imagick::RESOURCETYPE_DISK: 1073741824
    imagick::RESOURCETYPE_FILE: 768
    imagick::RESOURCETYPE_MAP: 512 MB
    imagick::RESOURCETYPE_MEMORY: 256 MB
    imagick::RESOURCETYPE_THREAD: 1
    imagick::RESOURCETYPE_TIME: 9.2233720368548E+18
    imagemagick_file_formats: 3FR, 3G2, 3GP, AAI, AI, APNG, ART, ARW, AVI, AVIF, AVS, BGR, BGRA, BGRO, BIE, BMP, BMP2, BMP3, BRF, CAL, CALS, CANVAS, CAPTION, CIN, CIP, CLIP, CMYK, CMYKA, CR2, CR3, CRW, CUR, CUT, DATA, DCM, DCR, DCX, DDS, DFONT, DJVU, DNG, DOT, DPX, DXT1, DXT5, EPDF, EPI, EPS, EPS2, EPS3, EPSF, EPSI, EPT, EPT2, EPT3, ERF, EXR, FAX, FILE, FITS, FRACTAL, FTP, FTS, G3, G4, GIF, GIF87, GRADIENT, GRAY, GRAYA, GROUP4, GV, H, HALD, HDR, HEIC, HISTOGRAM, HRZ, HTM, HTML, HTTP, HTTPS, ICB, ICO, ICON, IIQ, INFO, INLINE, IPL, ISOBRL, ISOBRL6, J2C, J2K, JBG, JBIG, JNG, JNX, JP2, JPC, JPE, JPEG, JPG, JPM, JPS, JPT, JSON, K25, KDC, LABEL, M2V, M4V, MAC, MAGICK, MAP, MASK, MAT, MATTE, MEF, MIFF, MKV, MNG, MONO, MOV, MP4, MPC, MPG, MRW, MSL, MSVG, MTV, MVG, NEF, NRW, NULL, ORF, OTB, OTF, PAL, PALM, PAM, PANGO, PATTERN, PBM, PCD, PCDS, PCL, PCT, PCX, PDB, PDF, PDFA, PEF, PES, PFA, PFB, PFM, PGM, PGX, PICON, PICT, PIX, PJPEG, PLASMA, PNG, PNG00, PNG24, PNG32, PNG48, PNG64, PNG8, PNM, POCKETMOD, PPM, PREVIEW, PS, PS2, PS3, PSB, PSD, PTIF, PWP, RADIAL-GRADIENT, RAF, RAS, RAW, RGB, RGBA, RGBO, RGF, RLA, RLE, RMF, RW2, SCR, SCT, SFW, SGI, SHTML, SIX, SIXEL, SPARSE-COLOR, SR2, SRF, STEGANO, SUN, SVG, SVGZ, TEXT, TGA, THUMBNAIL, TIFF, TIFF64, TILE, TIM, TTC, TTF, TXT, UBRL, UBRL6, UIL, UYVY, VDA, VICAR, VID, VIDEO, VIFF, VIPS, VST, WBMP, WEBM, WEBP, WMF, WMV, WMZ, WPG, X, X3F, XBM, XC, XCF, XPM, XPS, XV, XWD, YCbCr, YCbCrA, YUV
    gd_version: bundled (2.1.0 compatible)
    gd_formats: GIF, JPEG, PNG, WebP, BMP, XPM
    ghostscript_version: 9.53.3 wp-server
    
    server_architecture: Linux 6.1.38-hcl x86_64
    httpd_software: Apache
    php_version: 8.0.30 64bit
    php_sapi: fpm-fcgi
    max_input_variables: 20000
    time_limit: 300
    memory_limit: 256M
    max_input_time: 60
    upload_max_filesize: 256M
    php_post_max_size: 256M
    curl_version: 7.74.0 OpenSSL/1.1.1n
    suhosin: false
    imagick_availability: true
    pretty_permalinks: true
    current: 2024-02-12T17:34:16+00:00
    utc-time: Monday, 12-Feb-24 17:34:16 UTC
    server-time: 2024-02-12T18:34:15+01:00 wp-database
    
    extension: mysqli
    server_version: 5.7.40-43-log
    client_version: mysqlnd 8.0.30
    max_allowed_packet: 67108864
    max_connections: 150 wp-constants
    
    WP_HOME: https://xxx.xx
    WP_SITEURL: https://xxx.xx/wp
    WP_CONTENT_DIR: /data/sites/web/xx/checkout/master/98e6719f8a15063c2595fe0a8d7cf9cac9e9b5c3/web/app
    WP_PLUGIN_DIR: /data/sites/web/xx/checkout/master/98e6719f8a15063c2595fe0a8d7cf9cac9e9b5c3/web/app/plugins
    WP_MEMORY_LIMIT: 40M
    WP_MAX_MEMORY_LIMIT: 256M
    WP_DEBUG: false
    WP_DEBUG_DISPLAY: false
    WP_DEBUG_LOG: /path/to/debug.log
    SCRIPT_DEBUG: false
    WP_CACHE: false
    CONCATENATE_SCRIPTS: undefined
    COMPRESS_SCRIPTS: undefined
    COMPRESS_CSS: undefined
    WP_ENVIRONMENT_TYPE: Ongedefinieerd
    WP_DEVELOPMENT_MODE: undefined
    DB_CHARSET: utf8mb4
    DB_COLLATE: undefined wp-filesystem
    
    wordpress: writable
    wp-content: writable
    uploads: writable
    plugins: writable
    themes: writable
    mu-plugins: writable google-site-kit
    
    version: 1.119.0
    php_version: 8.0.30
    wp_version: 6.4.3
    reference_url: https://xx.xx
    amp_mode: no
    site_status: connected-site
    user_status: not authenticated
    verification_status: not-verified
    connected_user_count: none
    active_modules: site-verification, search-console, analytics, analytics-4, pagespeed-insights
    recoverable_modules: none
    required_scopes:
    openid: ?
    https://www.googleapis.com/auth/userinfo.profile: ?
    https://www.googleapis.com/auth/userinfo.email: ?
    https://www.googleapis.com/auth/siteverification: ?
    https://www.googleapis.com/auth/webmasters: ?
    https://www.googleapis.com/auth/analytics.readonly: ?
    https://www.googleapis.com/auth/tagmanager.readonly: ?
    capabilities:
    googlesitekit_authenticate: ?
    googlesitekit_setup: ?
    googlesitekit_view_posts_insights: ?
    googlesitekit_view_dashboard: ?
    googlesitekit_manage_options: ?
    googlesitekit_update_plugins: ?
    googlesitekit_view_splash: ?
    googlesitekit_view_authenticated_dashboard: ?
    googlesitekit_view_wp_dashboard_widget: ?
    googlesitekit_view_admin_bar_menu: ?
    googlesitekit_view_shared_dashboard: ?
    googlesitekit_read_shared_module_data::["search-console"]: ?
    googlesitekit_read_shared_module_data::["pagespeed-insights"]: ?
    googlesitekit_manage_module_sharing_options::["search-console"]: ?
    googlesitekit_manage_module_sharing_options::["pagespeed-insights"]: ?
    googlesitekit_delegate_module_sharing_management::["search-console"]: ?
    googlesitekit_delegate_module_sharing_management::["pagespeed-insights"]: ?
    enabled_features:
    gm3Components: ?
    search-console_shared_roles: none
    search-console_management: owner
    pagespeed-insights_shared_roles: none
    pagespeed-insights_management: all_admins
    search_console_property: none
    analytics_account_id: none
    analytics_property_id: none
    analytics_profile_id: none
    analytics_use_snippet: yes
    analytics_4_property_id: none
    analytics_4_web_data_stream_id: none
    analytics_4_measurement_id: none
    analytics_4_use_snippet: yes
    analytics_4_available_custom_dimensions: none
Viewing 15 replies - 16 through 30 (of 39 total)
  • Plugin Support James Osborne

    (@jamesosborne)

    Appreciate the update @gchris2. I’ll need to request another check of your site records based on this. I’ve done so now and I’ll provide you with an update here as soon as I have it. Thank you!

    Plugin Support James Osborne

    (@jamesosborne)

    Thanks for the update @gchris2. From discussing your matter with the team, one additional check to help rule out browser extensions or features would be to attempt set up from a Chrome browser incognito window. Can you do this and let me know the outcome?

    If you encounter any errors that differ to the “Bad Request” error, let me know.

    Thread Starter gchris2

    (@gchris2)


    Thank you for your response, I always connect this plugin in Chrome incognito mode because of the passwords; in my other window, I’m logged in myself.

    And perhaps to emphasize again, I’ve gone through this process for about 20-30 websites, and the stack itself doesn’t change much.

    I’m now at the point of just hardcoding it into the website, but I’m really curious about what could still be causing the issue.

    • This reply was modified 1 year ago by gchris2.
    • This reply was modified 1 year ago by gchris2.
    Plugin Support James Osborne

    (@jamesosborne)

    Appreciate the update @gchris2. I’ll check this further with the team and report back to you here.

    Plugin Support James Osborne

    (@jamesosborne)

    Thanks for your patience on this @gchris2. Can you try set up Site Kit once more? If the same occurs, did you use any other domains for this site, such as a staging site URL?

    Thread Starter gchris2

    (@gchris2)


    Thank you for your response. I tried again, using incognito mode, deactivated WP Rocket, deactivated Redirects, reset Site Kit, and saved permalinks. After logging in again, I still received the error message “string(11) ‘Bad Request'”.

    As I mentioned earlier, this is the first time I’m attempting to link it. Previously, the website was on a staging URL, and we didn’t link Site Kit there.

    Plugin Support James Osborne

    (@jamesosborne)

    Sorry to hear that @gchris2. I’m happy to reach out once more and relay this back while requesting another site check. They did ask about any possible staging site URL. While you didn’t set Site Kit up on your staging site, some of the old staging site records may remain, which could have been passed to the Site Kit service. To troubleshoot this further, if possible please share your staging site URL. You can do so privately via the same form previously used. Regardless, I’ve requested another check of your site.

    Note that while we’re awaiting a check of your site records, you may wish to see if you’re able to complete set up by using Site Kit specific constants, as per this guide. I can’t guarantee this will allow you to proceed, but it result in your site bring registered on the Site Kit service once more, and hopefully it won’t use any invalid callbacks.

    Let me know if you have any questions with the above.

    Plugin Support James Osborne

    (@jamesosborne)

    Appreciate your patience on this @gchris2. The wp path was added to your callback URL now. Can you please attempt set up once more and let me know if you’re able to proceed?

    Thread Starter gchris2

    (@gchris2)


    Thank you for your response. I’ve tried again, but I’m still encountering the same error message. I’ve set the permalinks to default, deactivated all plugins, activated only Site Kit, reset Site Kit, but it still doesn’t work. I just checked to see if I could set the Site Kit constants in the wp-config file. However, we use Bedrock, and the wp-config file is not directly editable.

    This is the URL where I end up when encountering the error:

    Plugin Support James Osborne

    (@jamesosborne)

    Thanks for the update @gchris2, and sorry to heat that didn’t work for you.

    As you’re a Bedrock user, you can define your own Site Kit constnats via following the guide here, adding them to your config/application.php file.

    If the same occurs after defining your Site Kit constants, I can request all your site URLs be modified. Please do let me know if this is the case.

    Plugin Support James Osborne

    (@jamesosborne)

    As we didn’t receive a response I’ll mark this as resolved. Feel free to open a new support topic if you continue to encounter issues, or reopen this topic and we’d be happy to assist.

    Thread Starter gchris2

    (@gchris2)

    Just tried again, disabled redirect and caching plugin. During installation, the plugin says the configuration is found. I also see the new Google style during the process now. However, it ends with the same error message: string(11) “Bad Request”.

    I haven’t tried the solution with constants; it’s not as simple as just putting them in your .ENV file. These constants also need to be retrieved in the wp-config of Bedrock. But I’m not going to start that because then I’ll be modifying files that shouldn’t be modified.”

    Plugin Support James Osborne

    (@jamesosborne)

    Understood regarding changing your constants. I’m happy to go ahead and request an update of your site records, but before I do, can you share a recording of your experience once more? In this recording, please demonstrate setup from a Chrome browser incognito window, while keeping the developer tools console open, displaying any browser console errors. When you land back on the same error page, please open the “Network” tab, so we can review any possible invalid XHR response.

    I’m aware you prefer not to install any software to share a recording, but some records such as Loom are web based, or you can share from your phone and upload to a file sharing service if preferred. This will allow us to determine more on any potential block, given we already corrected your site records on the service. You can share via the same form previously used if you wish to share this privately.

    I also reopened this support topic so we can continue to troubleshoot. Thank you!

    Thread Starter gchris2

    (@gchris2)

    I just filled out the form, I have sent 3 links with 2 videos with the developer tools open and once with the network tab open. I also sent a screenshot of the page where I get the error message with the network tab open. I did all of this incognito, site kit was reset during the attempt. Also, the redirect and caching plugins were turned off.

    Please let me know when I can delete the files.

    Plugin Support James Osborne

    (@jamesosborne)

    Many thanks @gchris2. I’ve downloaded the recordings now, feel free to delete from your filesystem. From reviewing the details, it looks like this error occurs as soon as the plugin tried to connect Analytics. While I’ll check this further with the team, can you reset Site Kit (Tools > Available Tools > Reset Site Kit), and then set up the plugin once more. When setting up, please don’t select the option to include Analytics as part of the set up process.

    Let me know how you get on with the above.

Viewing 15 replies - 16 through 30 (of 39 total)
  • The topic ‘string(11) “Bad Request”’ is closed to new replies.