{"action":"closed","issue":{"url":"https://api.github.com/repos/snipe/snipe-it/issues/2793","repository_url":"https://api.github.com/repos/snipe/snipe-it","labels_url":"https://api.github.com/repos/snipe/snipe-it/issues/2793/labels{/name}","comments_url":"https://api.github.com/repos/snipe/snipe-it/issues/2793/comments","events_url":"https://api.github.com/repos/snipe/snipe-it/issues/2793/events","html_url":"https://github.com/snipe/snipe-it/issues/2793","id":184340729,"number":2793,"title":"Asset Import fails when using CSV sample","user":{"login":"delize","id":4028612,"avatar_url":"https://avatars.githubusercontent.com/u/4028612?v=3","gravatar_id":"","url":"https://api.github.com/users/delize","html_url":"https://github.com/delize","followers_url":"https://api.github.com/users/delize/followers","following_url":"https://api.github.com/users/delize/following{/other_user}","gists_url":"https://api.github.com/users/delize/gists{/gist_id}","starred_url":"https://api.github.com/users/delize/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/delize/subscriptions","organizations_url":"https://api.github.com/users/delize/orgs","repos_url":"https://api.github.com/users/delize/repos","events_url":"https://api.github.com/users/delize/events{/privacy}","received_events_url":"https://api.github.com/users/delize/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2016-10-20T21:06:18Z","updated_at":"2016-10-20T22:29:01Z","closed_at":"2016-10-20T22:29:01Z","body":"#### Expected Behavior (or desired behavior if a feature request)\r\n\r\nSample CSV imports properly regardless of what data is in CSV (legit or otherwise)\r\n\r\n-----\r\n\r\n#### Actual Behavior\r\n\r\nSample CSV does not import, and throws error about being unable to read UTF8 encoding.\r\nSeems to be a reoccuring cause with Ubuntu 16.04.1 according to two other tickets\r\n-----\r\n\r\n#### Please confirm you have done the following before posting your bug report:\r\n\r\n- [x] I have enabled debug mode\r\n- [x] I have read [checked the Common Issues page](http://docs.snipeitapp.com/common-issues.html)\r\n\r\n-----\r\n#### Please provide answers to these questions before posting your bug report:\r\n\r\n- Version of Snipe-IT you're running \r\n3.3\r\n\r\n- What OS and web server you're running Snipe-IT on\r\nUbuntu 16.04.1\r\nApache 2.4\r\n\r\n- What method you used to install Snipe-IT (install.sh, manual installation, docker, etc)\r\ninstall.sh\r\n\r\n- If you're getting an error in your browser, include that error\r\n- What specific Snipe-IT page you're on, and what specific element you're interacting with to trigger the error\r\n- If a stacktrace is provided in the error, include that too.\r\nProvided at the bottom\r\n\r\n- Any errors that appear in your browser's error console.\r\n\r\n- Confirm whether the error is [reproduceable on the demo](https://snipeitapp.com/demo).\r\nNo\r\n\r\n- Include any additional information you can find in `app/storage/logs` and your webserver's logs.\r\nNone that I could that would be relevant\r\n\r\n- Include what you've done so far in the installation, and if you got any error messages along the way.\r\nNothing - Fresh installation\r\n\r\n- Indicate whether or not you've manually edited any data directly in the database\r\nNo\r\n\r\nI saw #2619 and have verified that the two files exist:\r\n```\r\nadministrator@snipeit-dev:/var/www/snipeit$ ls -al vendor/neitanod/\r\ntotal 12\r\ndrwxr-xr-x  5 www-data www-data 4096 Oct 18 18:04 forceutf8\r\n\r\nadministrator@snipeit-dev:/var/www/snipeit$ cat composer.json | grep dev-master\r\n      \"intervention/image\": \"dev-master\",\r\n      \"maknz/slack\": \"dev-master\",\r\n      \"erusev/parsedown\": \"dev-master\",\r\n      \"tecnickcom/tc-lib-barcode\": \"dev-master\",\r\n      \"neitanod/forceutf8\": \"dev-master\"\r\n\r\nadministrator@snipeit-dev:/var/www/snipeit$ dpkg -l | grep php-xml\r\nii  php-xml                            1:7.0+35ubuntu6                   all          DOM, SimpleXML, WDDX, XML, and XSL module for PHP [default]\r\n```\r\n\r\nWhen attempting to run the commands that were #2619 and #2715 I receive this error:\r\nSee https://github.com/snipe/snipe-it/issues/2793#issuecomment-255244389\r\n\r\nStack Trace:\r\n```\r\n\r\nFatalThrowableError in Encoding.php line 339:\r\nCall to undefined function ForceUTF8\\utf8_decode()\r\nin Encoding.php line 339\r\nat Encoding::utf8_decode('Laptop', '') in Encoding.php line 280\r\nat Encoding::fixUTF8('Laptop') in ObjectImportCommand.php line 288\r\nat ObjectImportCommand->array_smart_fetch(array('name' => 'Bonnie Nelson', 'email' => 'bnelson0@cdbaby.com', 'username' => 'a', 'item name' => 'Testing Item Name Field', 'category' => 'Laptop', 'model name' => 'Macbook Air', 'manufacturer' => 'Apple', 'model number' => 'A1466', 'serial number' => 'SC07SG0123123J1', 'asset tag' => 'UH100000', 'location' => 'Daping', 'notes' => '', 'purchase date' => '4/5/16', 'purchase cost' => '289.59', 'company' => 'somerandomcompany', 'status' => 'Deployed', 'warranty months' => '12', 'supplier' => 'CDW'), 'category') in ObjectImportCommand.php line 138\r\nat ObjectImportCommand->App\\Console\\Commands\\{closure}(object(MySqlConnection)) in Connection.php line 543\r\nat Connection->transaction(object(Closure))\r\nat call_user_func_array(array(object(MySqlConnection), 'transaction'), array(object(Closure))) in compiled.php line 11804\r\nat DatabaseManager->__call('transaction', array(object(Closure))) in compiled.php line 6325\r\nat Facade::__callStatic('transaction', array(object(Closure))) in ObjectImportCommand.php line 209\r\nat ObjectImportCommand->fire()\r\nat call_user_func_array(array(object(ObjectImportCommand), 'fire'), array()) in compiled.php line 1257\r\nat Container->call(array(object(ObjectImportCommand), 'fire')) in Command.php line 169\r\nat Command->execute(object(ArrayInput), object(BufferedOutput)) in Command.php line 256\r\nat Command->run(object(ArrayInput), object(BufferedOutput)) in Command.php line 155\r\nat Command->run(object(ArrayInput), object(BufferedOutput)) in Application.php line 794\r\nat Application->doRunCommand(object(ObjectImportCommand), object(ArrayInput), object(BufferedOutput)) in Application.php line 186\r\nat Application->doRun(object(ArrayInput), object(BufferedOutput)) in Application.php line 117\r\nat Application->run(object(ArrayInput), object(BufferedOutput)) in Application.php line 64\r\nat Application->call('snipeit:import', object(Collection)) in Kernel.php line 170\r\nat Kernel->call('snipeit:import', array('filename' => '/var/www/snipeit/storage/private_uploads/imports/assets/2016-10-20-013409-snipe-sample-assets.csv', '--email_format' => 'firstname.lastname', '--username_format' => 'firstname.lastname', '--web-importer' => true, '--user_id' => '1', '--item-type' => 'asset')) in compiled.php line 6327\r\nat Facade::__callStatic('call', array('snipeit:import', array('filename' => '/var/www/snipeit/storage/private_uploads/imports/assets/2016-10-20-013409-snipe-sample-assets.csv', '--email_format' => 'firstname.lastname', '--username_format' => 'firstname.lastname', '--web-importer' => true, '--user_id' => '1', '--item-type' => 'asset'))) in AssetsController.php line 972\r\nat AssetsController->postProcessImportFile()\r\nat call_user_func_array(array(object(AssetsController), 'postProcessImportFile'), array()) in compiled.php line 9424\r\nat Controller->callAction('postProcessImportFile', array()) in compiled.php line 9486\r\nat ControllerDispatcher->call(object(AssetsController), object(Route), 'postProcessImportFile') in compiled.php line 9466\r\nat ControllerDispatcher->Illuminate\\Routing\\{closure}(object(Request))\r\nat call_user_func(object(Closure), object(Request)) in Pipeline.php line 52\r\nat Pipeline->Illuminate\\Routing\\{closure}(object(Request)) in Authenticate.php line 45\r\nat Authenticate->handle(object(Request), object(Closure))\r\nat call_user_func_array(array(object(Authenticate), 'handle'), array(object(Request), object(Closure))) in compiled.php line 9963\r\nat Pipeline->Illuminate\\Pipeline\\{closure}(object(Request))\r\nat call_user_func(object(Closure), object(Request)) in Pipeline.php line 32\r\nat Pipeline->Illuminate\\Routing\\{closure}(object(Request))\r\nat call_user_func(object(Closure), object(Request)) in compiled.php line 9948\r\nat Pipeline->then(object(Closure)) in compiled.php line 9467\r\nat ControllerDispatcher->callWithinStack(object(AssetsController), object(Route), object(Request), 'postProcessImportFile') in compiled.php line 9454\r\nat ControllerDispatcher->dispatch(object(Route), object(Request), 'App\\Http\\Controllers\\AssetsController', 'postProcessImportFile') in compiled.php line 8524\r\nat Route->runController(object(Request)) in compiled.php line 8511\r\nat Route->run(object(Request)) in compiled.php line 8225\r\nat Router->Illuminate\\Routing\\{closure}(object(Request))\r\nat call_user_func(object(Closure), object(Request)) in Pipeline.php line 52\r\nat Pipeline->Illuminate\\Routing\\{closure}(object(Request)) in CheckPermissions.php line 27\r\nat CheckPermissions->handle(object(Request), object(Closure), 'assets.create')\r\nat call_user_func_array(array(object(CheckPermissions), 'handle'), array(object(Request), object(Closure), 'assets.create')) in compiled.php line 9963\r\nat Pipeline->Illuminate\\Pipeline\\{closure}(object(Request))\r\nat call_user_func(object(Closure), object(Request)) in Pipeline.php line 32\r\nat Pipeline->Illuminate\\Routing\\{closure}(object(Request)) in Authenticate.php line 45\r\nat Authenticate->handle(object(Request), object(Closure))\r\nat call_user_func_array(array(object(Authenticate), 'handle'), array(object(Request), object(Closure))) in compiled.php line 9963\r\nat Pipeline->Illuminate\\Pipeline\\{closure}(object(Request))\r\nat call_user_func(object(Closure), object(Request)) in Pipeline.php line 32\r\nat Pipeline->Illuminate\\Routing\\{closure}(object(Request)) in CheckLocale.php line 40\r\nat CheckLocale->handle(object(Request), object(Closure))\r\nat call_user_func_array(array(object(CheckLocale), 'handle'), array(object(Request), object(Closure))) in compiled.php line 9963\r\nat Pipeline->Illuminate\\Pipeline\\{closure}(object(Request))\r\nat call_user_func(object(Closure), object(Request)) in Pipeline.php line 32\r\nat Pipeline->Illuminate\\Routing\\{closure}(object(Request)) in compiled.php line 3225\r\nat VerifyCsrfToken->handle(object(Request), object(Closure))\r\nat call_user_func_array(array(object(VerifyCsrfToken), 'handle'), array(object(Request), object(Closure))) in compiled.php line 9963\r\nat Pipeline->Illuminate\\Pipeline\\{closure}(object(Request))\r\nat call_user_func(object(Closure), object(Request)) in Pipeline.php line 32\r\nat Pipeline->Illuminate\\Routing\\{closure}(object(Request)) in compiled.php line 13213\r\nat AddQueuedCookiesToResponse->handle(object(Request), object(Closure))\r\nat call_user_func_array(array(object(AddQueuedCookiesToResponse), 'handle'), array(object(Request), object(Closure))) in compiled.php line 9963\r\nat Pipeline->Illuminate\\Pipeline\\{closure}(object(Request))\r\nat call_user_func(object(Closure), object(Request)) in Pipeline.php line 32\r\nat Pipeline->Illuminate\\Routing\\{closure}(object(Request)) in compiled.php line 13150\r\nat EncryptCookies->handle(object(Request), object(Closure))\r\nat call_user_func_array(array(object(EncryptCookies), 'handle'), array(object(Request), object(Closure))) in compiled.php line 9963\r\nat Pipeline->Illuminate\\Pipeline\\{closure}(object(Request))\r\nat call_user_func(object(Closure), object(Request)) in Pipeline.php line 32\r\nat Pipeline->Illuminate\\Routing\\{closure}(object(Request))\r\nat call_user_func(object(Closure), object(Request)) in compiled.php line 9948\r\nat Pipeline->then(object(Closure)) in compiled.php line 8226\r\nat Router->runRouteWithinStack(object(Route), object(Request)) in compiled.php line 8217\r\nat Router->dispatchToRoute(object(Request)) in compiled.php line 8207\r\nat Router->dispatch(object(Request)) in compiled.php line 2419\r\nat Kernel->Illuminate\\Foundation\\Http\\{closure}(object(Request))\r\nat call_user_func(object(Closure), object(Request)) in Pipeline.php line 52\r\nat Pipeline->Illuminate\\Routing\\{closure}(object(Request)) in Debugbar.php line 49\r\nat Debugbar->handle(object(Request), object(Closure))\r\nat call_user_func_array(array(object(Debugbar), 'handle'), array(object(Request), object(Closure))) in compiled.php line 9963\r\nat Pipeline->Illuminate\\Pipeline\\{closure}(object(Request))\r\nat call_user_func(object(Closure), object(Request)) in Pipeline.php line 32\r\nat Pipeline->Illuminate\\Routing\\{closure}(object(Request)) in TrustProxies.php line 46\r\nat TrustProxies->handle(object(Request), object(Closure))\r\nat call_user_func_array(array(object(TrustProxies), 'handle'), array(object(Request), object(Closure))) in compiled.php line 9963\r\nat Pipeline->Illuminate\\Pipeline\\{closure}(object(Request))\r\nat call_user_func(object(Closure), object(Request)) in Pipeline.php line 32\r\nat Pipeline->Illuminate\\Routing\\{closure}(object(Request)) in CheckForSetup.php line 22\r\nat CheckForSetup->handle(object(Request), object(Closure))\r\nat call_user_func_array(array(object(CheckForSetup), 'handle'), array(object(Request), object(Closure))) in compiled.php line 9963\r\nat Pipeline->Illuminate\\Pipeline\\{closure}(object(Request))\r\nat call_user_func(object(Closure), object(Request)) in Pipeline.php line 32\r\nat Pipeline->Illuminate\\Routing\\{closure}(object(Request)) in NosniffGuard.php line 17\r\nat NosniffGuard->handle(object(Request), object(Closure))\r\nat call_user_func_array(array(object(NosniffGuard), 'handle'), array(object(Request), object(Closure))) in compiled.php line 9963\r\nat Pipeline->Illuminate\\Pipeline\\{closure}(object(Request))\r\nat call_user_func(object(Closure), object(Request)) in Pipeline.php line 32\r\nat Pipeline->Illuminate\\Routing\\{closure}(object(Request)) in XssProtectHeader.php line 17\r\nat XssProtectHeader->handle(object(Request), object(Closure))\r\nat call_user_func_array(array(object(XssProtectHeader), 'handle'), array(object(Request), object(Closure))) in compiled.php line 9963\r\nat Pipeline->Illuminate\\Pipeline\\{closure}(object(Request))\r\nat call_user_func(object(Closure), object(Request)) in Pipeline.php line 32\r\nat Pipeline->Illuminate\\Routing\\{closure}(object(Request)) in FrameGuard.php line 17\r\nat FrameGuard->handle(object(Request), object(Closure))\r\nat call_user_func_array(array(object(FrameGuard), 'handle'), array(object(Request), object(Closure))) in compiled.php line 9963\r\nat Pipeline->Illuminate\\Pipeline\\{closure}(object(Request))\r\nat call_user_func(object(Closure), object(Request)) in Pipeline.php line 32\r\nat Pipeline->Illuminate\\Routing\\{closure}(object(Request)) in compiled.php line 13474\r\nat ShareErrorsFromSession->handle(object(Request), object(Closure))\r\nat call_user_func_array(array(object(ShareErrorsFromSession), 'handle'), array(object(Request), object(Closure))) in compiled.php line 9963\r\nat Pipeline->Illuminate\\Pipeline\\{closure}(object(Request))\r\nat call_user_func(object(Closure), object(Request)) in Pipeline.php line 32\r\nat Pipeline->Illuminate\\Routing\\{closure}(object(Request)) in compiled.php line 11964\r\nat StartSession->handle(object(Request), object(Closure))\r\nat call_user_func_array(array(object(StartSession), 'handle'), array(object(Request), object(Closure))) in compiled.php line 9963\r\nat Pipeline->Illuminate\\Pipeline\\{closure}(object(Request))\r\nat call_user_func(object(Closure), object(Request)) in Pipeline.php line 32\r\nat Pipeline->Illuminate\\Routing\\{closure}(object(Request)) in CheckForMaintenanceMode.php line 145\r\nat CheckForMaintenanceMode->handle(object(Request), object(Closure))\r\nat call_user_func_array(array(object(CheckForMaintenanceMode), 'handle'), array(object(Request), object(Closure))) in compiled.php line 9963\r\nat Pipeline->Illuminate\\Pipeline\\{closure}(object(Request))\r\nat call_user_func(object(Closure), object(Request)) in Pipeline.php line 32\r\nat Pipeline->Illuminate\\Routing\\{closure}(object(Request))\r\nat call_user_func(object(Closure), object(Request)) in compiled.php line 9948\r\nat Pipeline->then(object(Closure)) in compiled.php line 2366\r\nat Kernel->sendRequestThroughRouter(object(Request)) in compiled.php line 2350\r\nat Kernel->handle(object(Request)) in index.php line 59\r\n```"}}
{"actor":{"display_login":"delize"}}