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

Errno::EINVAL happens in Windows environment when enabling caching and reloading #1517

Closed
tune opened this Issue Dec 11, 2013 · 6 comments

Comments

Projects
None yet
3 participants
@tune

tune commented Dec 11, 2013

I've found that Errno::EINVAL happens when reloading and caching are enabled.

Reproduce is easy, create blank project and add following setting in "app/app.rb".

set :reload, true
register Padrino::Cache
enable :caching

When reload event happen, following log messages are displayed.

ERROR -  Errno::EINVAL: Invalid argument - C:/Users/tune/Desktop/sample/tmp/Sample::App; C:/Ruby200/lib/ruby/2.0.0/fileutils.rb:245:in `mkdir'

It seems that cache library try to create folder, but folder path includes ":" character that is not allowed in windows environment.

@namusyaka

This comment has been minimized.

Show comment
Hide comment
@namusyaka

namusyaka Dec 11, 2013

Member

@tune Thank you!

@padrino/core-members Is this directory name correct? (Sample::App)
I guess the cache directory name should same as the production environment.

Member

namusyaka commented Dec 11, 2013

@tune Thank you!

@padrino/core-members Is this directory name correct? (Sample::App)
I guess the cache directory name should same as the production environment.

@ujifgc

This comment has been minimized.

Show comment
Hide comment
@ujifgc

ujifgc Dec 12, 2013

Member

I can confirm, there is an issue with reloading and Padrino::Cache: tmp/SampleApp is generated on reload, while tmp/sample/app is generated on clean app load.

Member

ujifgc commented Dec 12, 2013

I can confirm, there is an issue with reloading and Padrino::Cache: tmp/SampleApp is generated on reload, while tmp/sample/app is generated on clean app load.

@ghost ghost assigned ujifgc Dec 12, 2013

@namusyaka

This comment has been minimized.

Show comment
Hide comment
@namusyaka

namusyaka Dec 12, 2013

Member

Yeah, this behavior may be caused by this line.

Member

namusyaka commented Dec 12, 2013

Yeah, this behavior may be caused by this line.

@ujifgc

This comment has been minimized.

Show comment
Hide comment
@ujifgc

ujifgc Dec 12, 2013

Member

I fixed it and trying to add a test now.

Member

ujifgc commented Dec 12, 2013

I fixed it and trying to add a test now.

@namusyaka

This comment has been minimized.

Show comment
Hide comment
@namusyaka

namusyaka Dec 12, 2013

Member

@ujifgc Great, thank you!

Member

namusyaka commented Dec 12, 2013

@ujifgc Great, thank you!

@ujifgc ujifgc closed this in 02e48a6 Dec 12, 2013

@ujifgc

This comment has been minimized.

Show comment
Hide comment
@ujifgc

ujifgc Dec 12, 2013

Member

BTW, I was struggling with 2 folders being created in my temp folder: application and Application. Now it's resolved.

Member

ujifgc commented Dec 12, 2013

BTW, I was struggling with 2 folders being created in my temp folder: application and Application. Now it's resolved.

namusyaka added a commit to namusyaka/padrino-framework that referenced this issue Dec 12, 2013

Ortuna added a commit to Ortuna/padrino-framework that referenced this issue Jan 17, 2014

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment