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

No response after Ctrl+Enter #15

Closed
danvim opened this issue Jul 10, 2019 · 11 comments · Fixed by #42
Closed

No response after Ctrl+Enter #15

danvim opened this issue Jul 10, 2019 · 11 comments · Fixed by #42

Comments

@danvim
Copy link

danvim commented Jul 10, 2019

This is the log of my terminal:

test@SOMEWHERE:/mnt/c/Users/test/Documents/projects/test$ php artisan serve --port=8080
Laravel development server started: <http://127.0.0.1:8080>
[Wed Jul 10 20:02:38 2019] 127.0.0.1:62125 [200]: /vendor/web-tinker/app.css?id=899f99be02229222ee1b
[Wed Jul 10 20:02:38 2019] 127.0.0.1:62126 [200]: /vendor/web-tinker/app.js?id=745ec8810b33383dd0eb
[Wed Jul 10 20:02:38 2019] 127.0.0.1:62128 [200]: /favicon.ico
Killed


Do note that laravel's serve isn't exited yet. This is what happened when I typed in 1+1 and Ctrl+Enter.

@giovanniledda
Copy link

giovanniledda commented Aug 21, 2019

Same for me, I'm noticing this error on console:

base.js?20190820:335 Uncaught (in promise) TypeError: url.substr is not a function at XMLHttpRequest.open (base.js?20190820:335) at app.js?id=9ffda6021a5b8ba56507:1 at new Promise (<anonymous>) at e.exports (app.js?id=9ffda6021a5b8ba56507:1) at e.exports (app.js?id=9ffda6021a5b8ba56507:1)

...every time I click "CTRL+ENTER".

@freekmurze
Copy link
Member

Odd, I can't recreate this...

@mateusgalasso
Copy link

I had this error every time I click "CTRL+ENTER"
"message": "touch(): Utime failed: Invalid argument",
"exception": "ErrorException",
"file": "C:\SGP-Laravel\vendor\psy\psysh\src\ConfigPaths.php",
"line": 233,

@litvinjuan
Copy link

litvinjuan commented Aug 23, 2019

Hey @freekmurze. Same thing happening here, the error is same as stonkeep's:
local.ERROR: touch(): Utime failed: Invalid argument {"exception":"[object] (ErrorException(code: 0): touch(): Utime failed: Invalid argument at ~\\vendor\\psy\\psysh\\src\\ConfigPaths.php:233)

Steps I took were:

  1. Created an empty Laravel applicaiton
  2. Added a few models and handlers
  3. Ran the composer require command for this package}
  4. Ran the 'install' command for this package
  5. Opened /tinker
  6. Entered some code
  7. Pressed Ctrl+Enter

After that nothing happens and the error above gets logged.

Shall you need more info, hit me up

EDIT:
Weirdest of all is that the line indicated seems to be a comment :/

@HeinHanekom
Copy link

Getting same issue here:

[2019-08-23 15:08:09] local.ERROR: touch(): Utime failed: Invalid argument {"url":"http://127.0.0.1:8000/tinker","input":{"code":"$team = App\\Team::find(1);"},"exception":"[object] (ErrorException(code: 0): touch(): Utime failed: Invalid argument at C:\\Users\\Hein Hanekom\\PhpstormProjects\ ams\\vendor\\psy\\psysh\\src\\ConfigPaths.php:233) [stacktrace] #0 C:\\Users\\Hein Hanekom\\PhpstormProjects\ ams\\vendor\\sentry\\sentry\\src\\ErrorHandler.php(361): Illuminate\\Foundation\\Bootstrap\\HandleExceptions->handleError(2, 'touch(): Utime ...', 'C:\\\\Users\\\\Hein H...', 233) #1 [internal function]: Sentry\\ErrorHandler->handleError(2, 'touch(): Utime ...', 'C:\\\\Users\\\\Hein H...', 233, Array) #2 C:\\Users\\Hein Hanekom\\PhpstormProjects\ ams\\vendor\\psy\\psysh\\src\\ConfigPaths.php(233): touch('nul') #3 C:\\Users\\Hein Hanekom\\PhpstormProjects\ ams\\vendor\\psy\\psysh\\src\\Configuration.php(376): Psy\\ConfigPaths::touchFileWithMkdir('nul') #4 C:\\Users\\Hein Hanekom\\PhpstormProjects\ ams\\vendor\\spatie\\laravel-web-tinker\\src\\Tinker.php(57): Psy\\Configuration->setHistoryFile('nul') #5 C:\\Users\\Hein Hanekom\\PhpstormProjects\

@plunkettscott
Copy link
Contributor

plunkettscott commented Aug 31, 2019

Also running into this. The errors seems to only happen when manipulating a Model in the console. At least that's the only time I get the 500 error on my end. For example, creating a record on a model:

This throws a 500:

Model::create(['test' => true]);

This outputs this-is-a-test like it should:

Str::slug('this is a test');

@plunkettscott
Copy link
Contributor

Also running into this. The errors seems to only happen when manipulating a Model in the console. At least that's the only time I get the 500 error on my end. For example, creating a record on a model:

This throws a 500:

Model::create(['test' => true]);

This outputs this-is-a-test like it should:

Str::slug('this is a test');

Ignore that above. It seems to be more specific to the create() method.

@danvim
Copy link
Author

danvim commented Aug 31, 2019

@plunkettscott Then I must be having a different problem than you. My instance cannot even solve 1+1.

@ndeblauw
Copy link
Sponsor

ndeblauw commented Sep 5, 2019

Similar problem (laravel 5.8 on php 7.3.3), ctrl+enter does nothing

Went to look for reason and found two errors in console upon loading:

[/tinker]
Failed to load resource: the server responded with a status of 502 (Bad Gateway)

[/vendor/web-tinker/app.js?id=54675ea5df087610508e]
Uncaught (in promise) Error: Request failed with status code 502
at FtD3.e.exports (app.js?id=54675ea5df087610508e:1)
at e.exports (app.js?id=54675ea5df087610508e:1)
at XMLHttpRequest.d.onreadystatechange (app.js?id=54675ea5df087610508e:1)

A short while after pressing ctrl+enter, this error comes up (and my php crashes and needs a restart)

[/vendor/web-tinker/app.js?id=54675ea5df087610508e]
POST /tinker 504 (Gateway Time-out)

@subdesign
Copy link

subdesign commented Sep 13, 2019

No response after Ctrl+Enter

@danvim changed from local server (php artisan serve) to virtual host, worked for me on Ubuntu / Nginx

@thezahedi
Copy link

thezahedi commented Sep 22, 2019

No response after Ctrl+Enter

@danvim changed from local server (php artisan serve) to virtual host, worked for me on Ubuntu / Nginx

I changed the path config from /tinker to tinker and virtual host works for me.

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

Successfully merging a pull request may close this issue.

10 participants