Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Too few arguments to function User_model::insert_ex() - automatic user creation failes #44

Open
cypbro opened this issue Apr 13, 2023 · 7 comments

Comments

@cypbro
Copy link

cypbro commented Apr 13, 2023

The ldap authentication of an user works but the automatic user creation insie testrail fails...


Too few arguments to function User_model::insert_ex(), 11 passed in /var/www/testrail/app/drivers/auth/custom.php on line 142 and at least 12 expected

Details:
File: /var/www/testrail/app/models/user.php
Line: 651
Status Code: 500
Host: testrail.intern.plath.de
Uri: /index.php?/auth/login/XYZ: (POST)

Browser: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:109.0) Gecko/20100101 Firefox/111.0
PHP: 7.3.33
Server: Linux 4.18.0-425.13.1.el8_7.x86_64 #1 SMP Tue Feb 21 19:25:54 UTC 2023 x86_64

name: [email protected]
password:
rememberme: 1

Trace:
at User_model->insert_ex (custom.php:142)
at Auth_custom_driver->_handle_success (custom.php:293)
at Auth_custom_driver->_login (custom.php:314)
at Auth_custom_driver->login (auth.php:750)
at Auth_library->_login_custom (auth.php:738)
at Auth_library->_login (auth.php:540)
at Auth_library->login (auth.php:67)
at Auth_controller->login (controller.php:257)
at Controller->_invoke_web_call (controller.php:168)
at Controller->_invoke_web (controller.php:120)
at Controller->_invoke (gizmo.php:129)
at require_once (index.php:114)

Version: 7.5.3.1000

@metajiji
Copy link

The same issue with apache image.
Version: 7.5.3.1000

@joshberry-wandisco
Copy link

I have this exact same error after upgrade to 7.5.3.1000 (non-docker). Anyone have any ideas?

@metajiji
Copy link

I believe the cause problem in encrypted file /var/www/testrail/app/drivers/auth/custom.php and can be fixed by TestRail team.

@mj2377
Copy link

mj2377 commented May 24, 2024

I know this is old....but do we know what direction this went or what version had the fix? I can confirm that this issue began around 6.6x versioning, currently facing the same problem on server version. Thanks!

@mj2377
Copy link

mj2377 commented May 24, 2024

Ok, never mind...I found this bug fix -> TR-4086 - "Too few arguments to function User_model::insert_ex()..." error during LDAP/AD integration with 7.8 (1136) build.
https://support.testrail.com/hc/en-us/articles/11173295328276-TestRail-7-8-0-Default-1136#h_01HQNZZVQ0HQATRRSM1QRCRAXK

@joshberry-wandisco
Copy link

I raised this issue to support and was advised to upgrade to 8.0.1.1029-ion81. I have not done so yet so could not say if this resolves the issue

@r-catania
Copy link

This has been driving us nuts.
In our case the issue happens when either the user does not exist or the email address does not match.

We had few users where the email domain had been changed so when the user would try to authenticate we would see the lookup against the database and the error Email address "<email_address>" unknown (at Auth_custom_driver->_handle_success) .

We had the option AUTH_CREATE_ACCOUNT set to true, but it seems that in 7.5 that is no longer working. At least it does not work for us anymore.

As long as the email address check works the error is not seen. So in our case the user must be created manually since the auto creation does not seem to work.
I hope this helps

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants