sproutcore / abbot Goto Github PK
View Code? Open in Web Editor NEWSproutCore Build Tools [deprecated]
Home Page: http://www.sproutcore.com
SproutCore Build Tools [deprecated]
Home Page: http://www.sproutcore.com
Rather than overriding the default, localized resources are being included along with the default.
This means that if you have resources/abc.css and fr.lproj/abc.css, the output CSS will include both CSS files.
It appears that the "filename" for files under the resources folder is "resources/abc.css", while the lproj is just "abc.css"; the "filename" property of the manifest entries probably needs to drop the "resources/" portion.
Currently, so far as I know, there is no way to remove main_page.js or any other first loaded page outside of resources.
Since release 1.6.0.rc.1, module building has been broken. The module_info.js file is not being successfully built.
Here is the error:
NoMethodError: undefined method `target' for nil:NilClass
/Library/Ruby/Gems/1.8/gems/sproutcore-1.6.0.rc.2/lib/sproutcore/models/target.rb:648:in `module_info'
/Library/Ruby/Gems/1.8/gems/sproutcore-1.6.0.rc.2/lib/sproutcore/models/target.rb:643:in `each'
/Library/Ruby/Gems/1.8/gems/sproutcore-1.6.0.rc.2/lib/sproutcore/models/target.rb:643:in `module_info'
/Library/Ruby/Gems/1.8/gems/sproutcore-1.6.0.rc.2/lib/sproutcore/builders/module.rb:57:in `build'
/Library/Ruby/Gems/1.8/gems/sproutcore-1.6.0.rc.2/lib/sproutcore/builders/module.rb:44:in `each'
/Library/Ruby/Gems/1.8/gems/sproutcore-1.6.0.rc.2/lib/sproutcore/builders/module.rb:44:in `build'
/Library/Ruby/Gems/1.8/gems/sproutcore-1.6.0.rc.2/lib/sproutcore/builders/base.rb:35:in `build'
/Library/Ruby/Gems/1.8/gems/sproutcore-1.6.0.rc.2/lib/buildtasks/build.rake:116:in `define!'
/Library/Ruby/Gems/1.8/gems/sproutcore-1.6.0.rc.2/lib/sproutcore/buildfile/task.rb:231:in `call'
/Library/Ruby/Gems/1.8/gems/sproutcore-1.6.0.rc.2/lib/sproutcore/buildfile/task.rb:231:in `execute'
/Library/Ruby/Gems/1.8/gems/sproutcore-1.6.0.rc.2/lib/sproutcore/buildfile/task.rb:226:in `each'
/Library/Ruby/Gems/1.8/gems/sproutcore-1.6.0.rc.2/lib/sproutcore/buildfile/task.rb:226:in `execute'
/Library/Ruby/Gems/1.8/gems/sproutcore-1.6.0.rc.2/lib/sproutcore/buildfile/task.rb:183:in `invoke_with_call_chain'
/Library/Ruby/Gems/1.8/gems/sproutcore-1.6.0.rc.2/lib/sproutcore/buildfile/task.rb:140:in `invoke'
/Library/Ruby/Gems/1.8/gems/sproutcore-1.6.0.rc.2/lib/sproutcore/buildfile.rb:214:in `invoke' ...
Version 1.6.0.beta.3 was the last working version.
Because the proxy forces the use of a port, we get an infinite redirect loop for sites that redirect away from a set port.
ie. search.twitter.com:80 -> search.twitter.com
If the site is using port 80, the proxy shouldn't force it's usage by default. More info:
http://groups.google.com/group/sproutcore/browse_thread/thread/4bfb21d9875eab2b
We should have a command like sc-gen upgrade-theme MyApp
or something (pick a good name).
It would perform the changes described in issue 20 (https://github.com/sproutcore/abbot/issues#issue/20) on existing apps.
There is no way to configure the file templates that are generated by sc-gen
, so you end up changing every generated file by hand. It would be good to move the doc block to a separate template or file.
E.g. - "My Company, Inc." in lib/gen/controller/templates/controllers/@[email protected]
// ==========================================================================
// Project: <%= namespace_instance_name %>
// Copyright: ©<%= Time.now.year %> My Company, Inc.
// ==========================================================================
When you run the abbott Buildfile (sudo rake init), this does a git clone on the deprecated sproutit account.
It also adds the sproutit git url
"git remote add dist git://github.com/sproutit/sproutcore.git"
sproutit/sproutcore-abbot repository has been deprecated. Copy the Wiki to new sproutcore/abbot and update the caller.empty? text for Using-Abbot-1.4-From-Source
https://github.com/sproutit/sproutcore-abbot/wiki
https://github.com/sproutit/sproutcore-abbot/wiki/Using-Abbot-1.4-From-Source
I am using sc-server to proxy some requests from two different (Java) backends, one of which is geoserver.
Since last week I noticed that requests are proxied ok, but the connection from sc-server to the browser is kept open (until after 30s a timeout kicks in).
On the other side of the proxy the connection from sc-server to geoserver (all on localhost) is opened and closed immediately. So it is not geoserver that suddenly became slow.
The result is that data is not made available to the underlying javascript code until the 30s have passed.
I have packet captures that document this behaviour. Oddly enough this used to work and it never happened until I installed the strobe starter kit (which I have now removed, but without luck).
I have looked into lib/sproutcore/rack/proxy.rb but I can't figure it out by myself, so I'm openning this issue w/o a patch.
For the moment I have replaced a single file (proxy.rb) with this version:
and now proxied requests fly!
I think this is an abbot issue but I'm not really sure !
When I proxy my request to my local server, all work great, but if I proxy to my remote server, all my request get a 'canceled' status !
The problem wasn't here with 1.6 RC2.
Currently there is no way to style everything under a theme.
Example:
$theme{
.my-inner-el{
// Sexy Styles
}
}
I believe the issue is here, according to Colin Campbell:
https://github.com/sproutcore/abbot/blob/master/vendor/chance/lib/chance/parser.rb#L59
The HTML 5 manifest will load to much in some cases. For instance I have seen both the normal and packed versions of a CSS file where only one should be required.
I'm building a new HTML/TemplateView based on a legacy application and wanted to re-use the stylesheets. Those stylesheets have rules that break the view if loaded in an incorrect order.
I've put all the stylesheets in resources/stylesheets and used sc_require to ensure order. However, the rules in the resulting stylesheet.css do not follow the ordering.
My current workaround is to by-pass the build system by adding stylesheet links to :page_styles section of loading.rhtml.
The following is on a new application created with sc-init
~/src/jruby-1.5.5/bin/jruby -S sc-server
JRuby limited openssl loaded. http://jruby.org/openssl
gem install jruby-openssl for full support.
SproutCore v1.4.4 Development Server
Starting server at http://0.0.0.0:4020 in debug mode
To quit sc-server, press Control-C
The signal QUIT is in use by the JVM and will not work correctly on this platform
Thin web server (v1.2.7 codename No Hup)
Maximum connections set to 1024
Listening on 0.0.0.0:4020, CTRL+C to stop
FATAL ~ undefined method `listen' for #Socket:0x2c79cd09
~/src/jruby-1.5.5/bin/jruby --version
jruby 1.5.5 (ruby 1.8.7 patchlevel 249) (2010-11-10 4bd4200) (Java HotSpot(TM) 64-Bit Server VM 1.6.0_22) [x86_64-java]
The build system ignores Sass files with .scss extension. The content never makes it into the final stylesheet.css.
The workaround is to rename these files to .css
Idea is that you don't have to use the slice directive and Chance will simply move files to the appropriate relative directories at build time.
With the new version of sproutcore 1.5.pre, there is a new stylesheet that ends with @2x.css.
When trying to upload an application to Appengine, the uploader list errors for all the files that contain the @ like this:
2011-03-13 13:55:45,202 ERROR appcfg.py:1517 Invalid character in filename: static/as/en/fd7ad64a4bc12493f2d0417a7bd5af070c0469ac/[email protected]
Could it be possible to remove the @ from the filename or allow to rename it ?
I'm using the master of abbot and master of sproutcore.
I followed this instruction to configure it : https://github.com/sproutit/sproutcore-abbot/wiki/Using-Abbot-1.4-From-Source
When I'm using sc-server, I'm getting the following error (but it still work) :
$ sc-server /Library/Ruby/Gems/1.8/gems/sproutcore-1.4.4/vendor/chance/lib/chance/parser.rb:104: warning: don't put space before argument parentheses /Library/Ruby/Gems/1.8/gems/sproutcore-1.4.4/vendor/chance/lib/chance/parser.rb:136: warning: don't put space before argument parentheses /Library/Ruby/Gems/1.8/gems/sproutcore-1.4.4/vendor/chance/lib/chance/parser.rb:153: warning: don't put space before argument parentheses /Library/Ruby/Gems/1.8/gems/sproutcore-1.4.4/vendor/chance/lib/chance/parser.rb:293: warning: don't put space before argument parentheses SproutCore v1.4.4 Development Server Starting server at http://0.0.0.0:4020 in debug mode To quit sc-server, press Control-C >> Thin web server (v1.2.7 codename No Hup) >> Maximum connections set to 1024 >> Listening on 0.0.0.0:4020, CTRL+C to stop NoMethodError: undefined method `key' for # /Library/Ruby/Gems/1.8/gems/sproutcore-1.4.4/vendor/chance/lib/chance/instance.rb:169:in `_combine' /Library/Ruby/Gems/1.8/gems/sproutcore-1.4.4/vendor/chance/lib/chance/instance.rb:168:in `map' /Library/Ruby/Gems/1.8/gems/sproutcore-1.4.4/vendor/chance/lib/chance/instance.rb:168:in `_combine' /Library/Ruby/Gems/1.8/gems/sproutcore-1.4.4/vendor/chance/lib/chance/instance.rb:90:in `update' /Library/Ruby/Gems/1.8/gems/sproutcore-1.4.4/lib/sproutcore/builders/combine.rb:43:in `buildWithChance' /Library/Ruby/Gems/1.8/gems/sproutcore-1.4.4/lib/sproutcore/builders/combine.rb:26:in `buildWithChance' /Library/Ruby/Gems/1.8/gems/sproutcore-1.4.4/lib/buildtasks/build.rake:65:in `define!' /Library/Ruby/Gems/1.8/gems/sproutcore-1.4.4/lib/sproutcore/buildfile/task.rb:239:in `call' /Library/Ruby/Gems/1.8/gems/sproutcore-1.4.4/lib/sproutcore/buildfile/task.rb:239:in `execute' /Library/Ruby/Gems/1.8/gems/sproutcore-1.4.4/lib/sproutcore/buildfile/task.rb:234:in `each' /Library/Ruby/Gems/1.8/gems/sproutcore-1.4.4/lib/sproutcore/buildfile/task.rb:234:in `execute' /Library/Ruby/Gems/1.8/gems/sproutcore-1.4.4/lib/sproutcore/buildfile/task.rb:191:in `invoke_with_call_chain' /Library/Ruby/Gems/1.8/gems/sproutcore-1.4.4/lib/sproutcore/buildfile/task.rb:148:in `invoke' /Library/Ruby/Gems/1.8/gems/sproutcore-1.4.4/lib/sproutcore/buildfile.rb:216:in `invoke' /Library/Ruby/Gems/1.8/gems/sproutcore-1.4.4/lib/sproutcore/models/manifest_entry.rb:339:in `build_to' /Library/Ruby/Gems/1.8/gems/sproutcore-1.4.4/lib/sproutcore/models/manifest_entry.rb:251:in `build!' /Library/Ruby/Gems/1.8/gems/sproutcore-1.4.4/lib/sproutcore/rack/builder.rb:129:in `call' /Library/Ruby/Gems/1.8/gems/sproutcore-1.4.4/lib/sproutcore/rack/builder.rb:89:in `synchronize' /Library/Ruby/Gems/1.8/gems/sproutcore-1.4.4/lib/sproutcore/rack/builder.rb:89:in `call' /Library/Ruby/Gems/1.8/gems/rack-1.2.1/lib/rack/cascade.rb:23:in `call' /Library/Ruby/Gems/1.8/gems/rack-1.2.1/lib/rack/cascade.rb:22:in `each' /Library/Ruby/Gems/1.8/gems/rack-1.2.1/lib/rack/cascade.rb:22:in `call' /Library/Ruby/Gems/1.8/gems/rack-1.2.1/lib/rack/showexceptions.rb:24:in `call' /Library/Ruby/Gems/1.8/gems/rack-1.2.1/lib/rack/recursive.rb:43:in `_call' /Library/Ruby/Gems/1.8/gems/rack-1.2.1/lib/rack/recursive.rb:38:in `call' /Library/Ruby/Gems/1.8/gems/rack-1.2.1/lib/rack/conditionalget.rb:25:in `call' /Library/Ruby/Gems/1.8/gems/sproutcore-1.4.4/lib/sproutcore/rack/service.rb:110:in `call' /Library/Ruby/Gems/1.8/gems/rack-1.2.1/lib/rack/content_length.rb:13:in `call' /Library/Ruby/Gems/1.8/gems/rack-1.2.1/lib/rack/chunked.rb:15:in `call' /Library/Ruby/Gems/1.8/gems/thin-1.2.7/lib/thin/connection.rb:76:in `pre_process' /Library/Ruby/Gems/1.8/gems/thin-1.2.7/lib/thin/connection.rb:74:in `catch' /Library/Ruby/Gems/1.8/gems/thin-1.2.7/lib/thin/connection.rb:74:in `pre_process' /Library/Ruby/Gems/1.8/gems/thin-1.2.7/lib/thin/connection.rb:57:in `process' /Library/Ruby/Gems/1.8/gems/thin-1.2.7/lib/thin/connection.rb:42:in `receive_data' /Library/Ruby/Gems/1.8/gems/eventmachine-0.12.10/lib/eventmachine.rb:256:in `run_machine' /Library/Ruby/Gems/1.8/gems/eventmachine-0.12.10/lib/eventmachine.rb:256:in `run' /Library/Ruby/Gems/1.8/gems/thin-1.2.7/lib/thin/backends/base.rb:57:in `start' /Library/Ruby/Gems/1.8/gems/thin-1.2.7/lib/thin/server.rb:156:in `start' /Library/Ruby/Gems/1.8/gems/rack-1.2.1/lib/rack/handler/thin.rb:14:in `run' /Library/Ruby/Gems/1.8/gems/sproutcore-1.4.4/lib/sproutcore/rack/service.rb:93:in `start' /Library/Ruby/Gems/1.8/gems/sproutcore-1.4.4/lib/sproutcore/tools/server.rb:43:in `server' /Library/Ruby/Gems/1.8/gems/thor-0.14.6/lib/thor/task.rb:22:in `send' /Library/Ruby/Gems/1.8/gems/thor-0.14.6/lib/thor/task.rb:22:in `run' /Library/Ruby/Gems/1.8/gems/thor-0.14.6/lib/thor/invocation.rb:118:in `invoke_task' /Library/Ruby/Gems/1.8/gems/thor-0.14.6/lib/thor.rb:263:in `dispatch' /Library/Ruby/Gems/1.8/gems/thor-0.14.6/lib/thor/base.rb:389:in `start' /Library/Ruby/Gems/1.8/gems/sproutcore-1.4.4/lib/sproutcore/tools.rb:380:in `start' /Library/Ruby/Gems/1.8/gems/sproutcore-1.4.4/lib/sproutcore/tools.rb:30:in `invoke' /Library/Ruby/Gems/1.8/gems/sproutcore-1.4.4/bin/sc-server:16 /usr/bin/sc-server:19:in `load' /usr/bin/sc-server:19
When I'm trying to build using sc-build, it fails:
$ sc-build /Library/Ruby/Gems/1.8/bundler/gems/abbot-727348279e25/lib/sproutcore/tools/build.rb:119: warning: don't put space before argument parentheses /Library/Ruby/Gems/1.8/bundler/gems/abbot-727348279e25/vendor/chance/lib/chance/parser.rb:104: warning: don't put space before argument parentheses /Library/Ruby/Gems/1.8/bundler/gems/abbot-727348279e25/vendor/chance/lib/chance/parser.rb:136: warning: don't put space before argument parentheses /Library/Ruby/Gems/1.8/bundler/gems/abbot-727348279e25/vendor/chance/lib/chance/parser.rb:153: warning: don't put space before argument parentheses /Library/Ruby/Gems/1.8/bundler/gems/abbot-727348279e25/vendor/chance/lib/chance/parser.rb:293: warning: don't put space before argument parentheses FATAL ~ undefined method `key' for #
Any ideas where it can come from ?
Please see: sproutcore/sproutcore#459
YUI Compressor 2.4.2 has this bug: http://yuilibrary.com/projects/yuicompressor/ticket/2528080
This is the version that abbot uses. There is a fix in the head, and will likely be released in 2.4.3. Please consider updating this lib in abbot when it's released.
See:
Without the fix clobbering occurs causing unexpected results when running a SproutCore application. Fix has been applied; just need to be merged into origin/1-4-stable. Has been reviewed by Tom Dale.
➜ sproutieri sc-gen language --help
language - Create a new language for a SproutCore application.
USAGE:
sc-gen language LanguageName [--target=TARGET_NAME]
DISCUSSION:
This generator will create a new language for a particular application. Please make sure you are in the specific application directory first, or specify one with the target parameter. You should pass as the first parameter the LanguageName you want to create. For example:
sc-gen language Norwegian
defines a new language in your current application in the directory norwegian.lproj .
➜ sproutieri ls apps
salieri
➜ sproutieri sc-gen language English --target=salieri
WARN ~ For specific help on how to use this generator, type: sc-gen language --help
FATAL ~ This generator requires a Language
➜ sproutieri sc-gen language English --target=Salieri
WARN ~ For specific help on how to use this generator, type: sc-gen language --help
FATAL ~ This generator requires a Target
➜ sproutieri sc-gen language english --target=Salieri
WARN ~ For specific help on how to use this generator, type: sc-gen language --help
FATAL ~ This generator requires a Target
➜ sproutieri sc-gen language english --target=salieri
WARN ~ For specific help on how to use this generator, type: sc-gen language --help
FATAL ~ This generator requires a Language
➜ sproutieri sc-gen language en --target=salieri
WARN ~ For specific help on how to use this generator, type: sc-gen language --help
FATAL ~ This generator requires a Language
➜ sproutieri sc-gen language english.lproj --target=salieri
WARN ~ For specific help on how to use this generator, type: sc-gen language --help
FATAL ~ This generator requires a Language
sc-init/sc-gen app should be changed in the following ways:
Each app should have a buildfile with config :app_name, :css_theme => "ace.my-app"
Each app should have a theme.js file creating a theme for the app. Something like this, but with appropriate comments:
MyApp.Theme = SC.AceTheme.create({
name: 'my-app'
});
SC.Theme.addTheme(MyApp.Theme);
SC.defaultTheme = 'my-app';
Similar to the Blacklist that removes .js files that aren't used, it would be nice to have a way to guard against some of the default css being included that is not needed for my app. Or ultimately is being overriden, so for example I have my own style for SC.ButtonView that is pervasive throughout the app, it would be nice to be able to remove the additional css given that our current css payload is about 600 kb + 200 kb the 600kb is all SC.
.joe
required in build file on 1.5 pre while deploying to Strobe site
config :all, :required => [:sproutcore, "sproutcore/ace"], :theme => 'sproutcore/ace'
It looks like sc-server does not support more than one proxied request at a time. It does enqueue the requests and doesn't process the second one until the first one has finished execution.
This is quite annoying if you have multiple requests going on at once in your application (think for example at a long polling scenario).
I would like to be able to specify the file target for the sprite so I can animate background images, and also exclude large / lazily loaded files to a different sprite.
Default theme should be changed to Ace in SproutCore Buildfile.
Also, test that :theme => "sproutcore/standard_theme" works to revert to old theme.
An App that loads an audio file in an Audio object and tries to play it will play just fine on iOS devices if the file is .mp3, but if it is .m4a it only plays properly when the project is deployed via apache. sc-server + iphone + m4a = no audio.
If you just run sc-init on sproutcore-1.4.0, it returns
raja@raja-laptop:/apps$ sc-init
"init" was called incorrectly. Call as "sc-init sc-init PROJECT [APP]".
Notice sc-init repeated twice. The patch at
http://gist.github.com/588973
fixes this.
For example:
sc-server --logfile="pwd
/log_file.log"
will write out a log file in the current directory:
log-file.log
The key thing is that the command should create a log file with a '' but the resulting log file has a '-' instead. This becomes a problem particularly if a directory has a '' in it. It appears all values of commanline options have their '_' turned into '-'. This problem didn't exist in older versions of abbot.
When you use $skip to skip a slice, Chance should still style the skipped slice, but should "skip" the image. Currently, it will skip styling entirely.
The common case for $skip is when you are overriding a button style: when styling a capsule button, you don't need to replace the middle slice, so you skip defining it; instead, you only override the left and right slices. However, when you do so, you may also change the size of the left and right slices. If the middle slice is skipped in its entirety, it will still have the wrong size.
Moved from sproutcore issues: sproutcore/sproutcore#546
My first original comment:
No clue why, but i can't start my application, I have no clue why sc-server is looking for files in my mail downloads folder, maybe someone can clarify this error? The application is working on other platforms and also when using garcon.
Platform: OS X 10.6
SproutCore v1.6.0 Development Server
Starting server at http://0.0.0.0:4020 in debug mode
To quit sc-server, press Control-C
Thin web server (v1.2.11 codename Bat-Shit Crazy)
Maximum connections set to 1024
Listening on 0.0.0.0:4020, CTRL+C to stop
Errno::ENOENT: No such file or directory - /Users/ralf/Library/Mail Downloads/TRIM Support Enabler.app/Contents/Frameworks/Sparkle.framework/Versions/A/Resources/fr.lproj/fr.lproj
/Users/ralf/.rvm/gems/ruby-1.9.2-p180/gems/sproutcore-1.6.0/lib/sproutcore/rack/builder.rb:217:in mtime'
/Users/ralf/.rvm/gems/ruby-1.9.2-p180/gems/sproutcore-1.6.0/lib/sproutcore/rack/builder.rb:217:inblock in monitor_project!'
/Users/ralf/.rvm/gems/ruby-1.9.2-p180/gems/sproutcore-1.6.0/lib/sproutcore/rack/builder.rb:217:in map'
/Users/ralf/.rvm/gems/ruby-1.9.2-p180/gems/sproutcore-1.6.0/lib/sproutcore/rack/builder.rb:217:inmonitor_project!'
/Users/ralf/.rvm/gems/ruby-1.9.2-p180/gems/sproutcore-1.6.0/lib/sproutcore/rack/builder.rb:186:in reload_project!'
/Users/ralf/.rvm/gems/ruby-1.9.2-p180/gems/sproutcore-1.6.0/lib/sproutcore/rack/builder.rb:90:inblock in call'
internal:prelude:10:in synchronize'
/Users/ralf/.rvm/gems/ruby-1.9.2-p180/gems/sproutcore-1.6.0/lib/sproutcore/rack/builder.rb:89:incall'
/Users/ralf/.rvm/gems/ruby-1.9.2-p180/gems/rack-1.3.0/lib/rack/cascade.rb:23:in block in call'
/Users/ralf/.rvm/gems/ruby-1.9.2-p180/gems/rack-1.3.0/lib/rack/cascade.rb:22:ineach'
/Users/ralf/.rvm/gems/ruby-1.9.2-p180/gems/rack-1.3.0/lib/rack/cascade.rb:22:in call'
/Users/ralf/.rvm/gems/ruby-1.9.2-p180/gems/rack-1.3.0/lib/rack/showexceptions.rb:24:incall'
/Users/ralf/.rvm/gems/ruby-1.9.2-p180/gems/rack-1.3.0/lib/rack/recursive.rb:43:in _call'
/Users/ralf/.rvm/gems/ruby-1.9.2-p180/gems/rack-1.3.0/lib/rack/recursive.rb:38:incall'
/Users/ralf/.rvm/gems/ruby-1.9.2-p180/gems/rack-1.3.0/lib/rack/conditionalget.rb:25:in call'
/Users/ralf/.rvm/gems/ruby-1.9.2-p180/gems/sproutcore-1.6.0/lib/sproutcore/rack/service.rb:110:incall'
/Users/ralf/.rvm/gems/ruby-1.9.2-p180/gems/thin-1.2.11/lib/thin/connection.rb:84:in block in pre_process'
/Users/ralf/.rvm/gems/ruby-1.9.2-p180/gems/thin-1.2.11/lib/thin/connection.rb:82:incatch'
/Users/ralf/.rvm/gems/ruby-1.9.2-p180/gems/thin-1.2.11/lib/thin/connection.rb:82:in pre_process'
/Users/ralf/.rvm/gems/ruby-1.9.2-p180/gems/thin-1.2.11/lib/thin/connection.rb:57:inprocess'
/Users/ralf/.rvm/gems/ruby-1.9.2-p180/gems/thin-1.2.11/lib/thin/connection.rb:42:in receive_data'
/Users/ralf/.rvm/gems/ruby-1.9.2-p180/gems/eventmachine-0.12.10/lib/eventmachine.rb:256:inrun_machine'
/Users/ralf/.rvm/gems/ruby-1.9.2-p180/gems/eventmachine-0.12.10/lib/eventmachine.rb:256:in run'
/Users/ralf/.rvm/gems/ruby-1.9.2-p180/gems/thin-1.2.11/lib/thin/backends/base.rb:61:instart'
/Users/ralf/.rvm/gems/ruby-1.9.2-p180/gems/thin-1.2.11/lib/thin/server.rb:159:in start'
/Users/ralf/.rvm/gems/ruby-1.9.2-p180/gems/rack-1.3.0/lib/rack/handler/thin.rb:13:inrun'
/Users/ralf/.rvm/gems/ruby-1.9.2-p180/gems/sproutcore-1.6.0/lib/sproutcore/rack/service.rb:93:in start'
/Users/ralf/.rvm/gems/ruby-1.9.2-p180/gems/sproutcore-1.6.0/lib/sproutcore/tools/server.rb:44:inserver'
/Users/ralf/.rvm/gems/ruby-1.9.2-p180/gems/thor-0.14.6/lib/thor/task.rb:22:in run'
/Users/ralf/.rvm/gems/ruby-1.9.2-p180/gems/thor-0.14.6/lib/thor/invocation.rb:118:ininvoke_task'
/Users/ralf/.rvm/gems/ruby-1.9.2-p180/gems/thor-0.14.6/lib/thor.rb:263:in dispatch'
/Users/ralf/.rvm/gems/ruby-1.9.2-p180/gems/thor-0.14.6/lib/thor/base.rb:389:instart'
/Users/ralf/.rvm/gems/ruby-1.9.2-p180/gems/sproutcore-1.6.0/lib/sproutcore/tools.rb:396:in start'
/Users/ralf/.rvm/gems/ruby-1.9.2-p180/gems/sproutcore-1.6.0/lib/sproutcore/tools.rb:30:ininvoke'
/Users/ralf/.rvm/gems/ruby-1.9.2-p180/gems/sproutcore-1.6.0/bin/sc-server:11:in <top (required)>'
/Users/ralf/.rvm/gems/ruby-1.9.2-p180/bin/sc-server:19:inload'
/Users/ralf/.rvm/gems/ruby-1.9.2-p180/bin/sc-server:19:in `'
The README suggests using Ruby 1.8.6+, but the 1.7.1.beta seems to throw the following error in Ruby 1.8.7 on OSX
/Library/Ruby/Site/1.8/rubygems/custom_require.rb:36:in `gem_original_require': /Library/Ruby/Gems/1.8/gems/sproutcore-1.7.1.beta/lib/sproutcore/rack/service.rb:62: syntax error, unexpected tIDENTIFIER, expecting tAMPER (SyntaxError)
app = self.new(*projects, opts)
/Library/Ruby/Gems/1.8/gems/sproutcore-1.7.1.beta/lib/sproutcore/rack/service.rb:96: syntax error, unexpected tIDENTIFIER, expecting tAMPER or '&'
def initialize(*projects, opts)
Everything works fine in Ruby 1.9.2
build configuration using 1.5 pre while deploying to Strobe site
config :all, :required => [:sproutcore, "sproutcore/ace"], :theme => 'sproutcore/ace'
Commit 40069a1 attempted to fix a problem (apparently) with static 404 responses not being proxied properly by loading the proxy handler after the main url routing code.
This now breaks routing for cases where the url to be proxied looks like /externalurl/something
See rack/service.rb: if project.buildfile.proxies.size > 0
and rack/builder.rb normalize_url() method
If you setup a proxy like so:
proxy '/fu/', :to => 'localhost/~majd', :url => '/'
Then sc-server will throw an exception like so:
SocketError: getaddrinfo: nodename nor servname provided, or not known
/Users/majd/.rvm/rubies/ruby-1.9.2-p0/lib/ruby/1.9.1/net/http.rb:644:in initialize' /Users/majd/.rvm/rubies/ruby-1.9.2-p0/lib/ruby/1.9.1/net/http.rb:644:in
open'
/Users/majd/.rvm/rubies/ruby-1.9.2-p0/lib/ruby/1.9.1/net/http.rb:644:in block in connect' /Users/majd/.rvm/rubies/ruby-1.9.2-p0/lib/ruby/1.9.1/timeout.rb:44:in
timeout'
/Users/majd/.rvm/rubies/ruby-1.9.2-p0/lib/ruby/1.9.1/timeout.rb:87:in timeout' /Users/majd/.rvm/rubies/ruby-1.9.2-p0/lib/ruby/1.9.1/net/http.rb:644:in
connect'
/Users/majd/.rvm/rubies/ruby-1.9.2-p0/lib/ruby/1.9.1/net/http.rb:637:in do_start' /Users/majd/.rvm/rubies/ruby-1.9.2-p0/lib/ruby/1.9.1/net/http.rb:626:in
start'
/Users/majd/.rvm/rubies/ruby-1.9.2-p0/lib/ruby/1.9.1/net/http.rb:490:in start' /Users/majd/.rvm/gems/ruby-1.9.2-p0/gems/sproutcore-1.4.1/lib/sproutcore/rack/proxy.rb:73:in
handle_proxy'
/Users/majd/.rvm/gems/ruby-1.9.2-p0/gems/sproutcore-1.4.1/lib/sproutcore/rack/proxy.rb:25:in block in call' /Users/majd/.rvm/gems/ruby-1.9.2-p0/gems/sproutcore-1.4.1/lib/sproutcore/rack/proxy.rb:23:in
each'
/Users/majd/.rvm/gems/ruby-1.9.2-p0/gems/sproutcore-1.4.1/lib/sproutcore/rack/proxy.rb:23:in call' /Users/majd/.rvm/gems/ruby-1.9.2-p0/gems/rack-1.2.1/lib/rack/cascade.rb:23:in
block in call'
/Users/majd/.rvm/gems/ruby-1.9.2-p0/gems/rack-1.2.1/lib/rack/cascade.rb:22:in each' /Users/majd/.rvm/gems/ruby-1.9.2-p0/gems/rack-1.2.1/lib/rack/cascade.rb:22:in
call'
/Users/majd/.rvm/gems/ruby-1.9.2-p0/gems/rack-1.2.1/lib/rack/showexceptions.rb:24:in call' /Users/majd/.rvm/gems/ruby-1.9.2-p0/gems/rack-1.2.1/lib/rack/recursive.rb:43:in
_call'
/Users/majd/.rvm/gems/ruby-1.9.2-p0/gems/rack-1.2.1/lib/rack/recursive.rb:38:in call' /Users/majd/.rvm/gems/ruby-1.9.2-p0/gems/rack-1.2.1/lib/rack/conditionalget.rb:25:in
call'
/Users/majd/.rvm/gems/ruby-1.9.2-p0/gems/sproutcore-1.4.1/lib/sproutcore/rack/service.rb:110:in call' /Users/majd/.rvm/gems/ruby-1.9.2-p0/gems/rack-1.2.1/lib/rack/content_length.rb:13:in
call'
/Users/majd/.rvm/gems/ruby-1.9.2-p0/gems/rack-1.2.1/lib/rack/chunked.rb:15:in call' /Users/majd/.rvm/gems/ruby-1.9.2-p0/gems/thin-1.2.7/lib/thin/connection.rb:76:in
block in pre_process'
/Users/majd/.rvm/gems/ruby-1.9.2-p0/gems/thin-1.2.7/lib/thin/connection.rb:74:in catch' /Users/majd/.rvm/gems/ruby-1.9.2-p0/gems/thin-1.2.7/lib/thin/connection.rb:74:in
pre_process'
/Users/majd/.rvm/gems/ruby-1.9.2-p0/gems/thin-1.2.7/lib/thin/connection.rb:57:in process' /Users/majd/.rvm/gems/ruby-1.9.2-p0/gems/thin-1.2.7/lib/thin/connection.rb:42:in
receive_data'
/Users/majd/.rvm/gems/ruby-1.9.2-p0/gems/eventmachine-0.12.10/lib/eventmachine.rb:256:in run_machine' /Users/majd/.rvm/gems/ruby-1.9.2-p0/gems/eventmachine-0.12.10/lib/eventmachine.rb:256:in
run'
/Users/majd/.rvm/gems/ruby-1.9.2-p0/gems/thin-1.2.7/lib/thin/backends/base.rb:57:in start' /Users/majd/.rvm/gems/ruby-1.9.2-p0/gems/thin-1.2.7/lib/thin/server.rb:156:in
start'
/Users/majd/.rvm/gems/ruby-1.9.2-p0/gems/rack-1.2.1/lib/rack/handler/thin.rb:14:in run' /Users/majd/.rvm/gems/ruby-1.9.2-p0/gems/sproutcore-1.4.1/lib/sproutcore/rack/service.rb:93:in
start'
/Users/majd/.rvm/gems/ruby-1.9.2-p0/gems/sproutcore-1.4.1/lib/sproutcore/tools/server.rb:43:in server' /Users/majd/.rvm/gems/ruby-1.9.2-p0/gems/thor-0.14.1/lib/thor/task.rb:22:in
run'
/Users/majd/.rvm/gems/ruby-1.9.2-p0/gems/thor-0.14.1/lib/thor/invocation.rb:118:in invoke_task' /Users/majd/.rvm/gems/ruby-1.9.2-p0/gems/thor-0.14.1/lib/thor.rb:246:in
dispatch'
/Users/majd/.rvm/gems/ruby-1.9.2-p0/gems/thor-0.14.1/lib/thor/base.rb:389:in start' /Users/majd/.rvm/gems/ruby-1.9.2-p0/gems/sproutcore-1.4.1/lib/sproutcore/tools.rb:337:in
start'
/Users/majd/.rvm/gems/ruby-1.9.2-p0/gems/sproutcore-1.4.1/lib/sproutcore/tools.rb:30:in invoke' /Users/majd/.rvm/gems/ruby-1.9.2-p0/gems/sproutcore-1.4.1/bin/sc-server:16:in
<top (required)>'
/Users/majd/.rvm/gems/ruby-1.9.2-p0/bin/sc-server:19:in load' /Users/majd/.rvm/gems/ruby-1.9.2-p0/bin/sc-server:19:in
When I do: sc-build gestxi -r --languages=fr
After this two lines, the script never stop:
Executing java -jar "/Users/nicolasbadia/.rvm/gems/ruby-1.9.2-p180/gems/sproutcore-1.7.1.beta/vendor/sproutcore/lib/yuicompressor-2.4.6.jar" -o "/Users/nicolasbadia/Sites/gestxi/tmp/build/static/gestxi/fr/ad48f38b161326579f69529ec852948bf3edd5f3/javascript-packed.js" "/Users/nicolasbadia/Sites/gestxi/tmp/build/static/gestxi/fr/ad48f38b161326579f69529ec852948bf3edd5f3/javascript-packed.js" 2>&1
Executing java -jar "/Users/nicolasbadia/.rvm/gems/ruby-1.9.2-p180/gems/sproutcore-1.7.1.beta/vendor/sproutcore/SCCompiler.jar" "/Users/nicolasbadia/Sites/gestxi/tmp/build/static/gestxi/fr/ad48f38b161326579f69529ec852948bf3edd5f3/index.html" 2>&1
Everything work great with 1.6 version.
sc-gen theme
should generate themes that include a Buildfile including the directive:
config :theme_name, :css_name => "theme-name"
And should include a theme.js file in the theme root:
MyApp.Theme = SC.AceTheme.create({
name: 'my-app'
});
SC.Theme.addTheme(MyApp.Theme);
Note: The theme.js should not set the SC.defaultTheme. Apps should set this.
From: https://github.com/sproutcore/sproutcore/issues#issue/38
This issue became apparent when I attempted to run the build tools from an ant task. I believe the java VM defaults to ascii encoding and so I was get a Fatal encoding error. Wycats helped me out in irc, and i discovered "Encoding.default_external" was ASCII while running from ant but UTF-8 when running from the command line.
As I quick fix to the problem, I have added "Encoding.default_external="utf-8" to the top of my sproutcore.rb to ensure it is always used.
@import is not working, I have learnt that sc_require has to be used instead.
Developers should be advised in case @import is used. Or perhaps @import could be translated into sc_require.
in the later case, note that the "path" specification is different on each. sc_require path is relative to SC App home, and @import path is relative to the current file.
When debugging inter-file dependencies (forgotten sc_require etc.) it is very useful to have a packed file without having it minified.
These sorts of bugs can be masked in debug builds when files aren't packed, but are very hard to track when the build is minified.
When using:
@include slices('images/toolbar.png', $left: 0, $width: 20, $repeat: repeat-x);
Build tools throws a file not found exception and fails to slice the image. However, when the single quotes are changed to double quotes, the file is found and the image is sliced. Chance clearly does not support single quotes in this directive, and probably should be supported in the future.
I'm having trouble with sc-server taking up a lot of CPU time. I've traced the problem down to the thread that is started by the SC::Rack::Builder.monitor_project!
method. Apparently every 2 seconds it goes through every file in the project, checking if something has changed?
Right now I have commented out the line did_reload = reload_project!
in the call
method. I rather restart sc-server every time I add a new file to my project (which is not that often) than have it hog my CPU. It would be nice though if there was a project config or a command line option that would disable monitoring so that I didn't have to edit the source code.
I have a deferred module "yi/top":
// Buildfile
config :yi,
:deferred_modules => [:"yi/top"]
Im loading it with:
// Main.js
SC.Module.loadModule("yi/top").
It has one dependency "yi/features" that is fetched successfully:
// Buildfile
config :"top",
:inlined_modules => [
:"yi/features"
]
But that "yi/features" dependency "yi/features/todos" can't be fetched (technically because it is not listed in SC.MODULE_INFO).
// Buildfile
config :"features",
:inlined_modules => [
:"yi/features/todos"
]
I wonder why Abbot has not listed this as a module in SC.MODULE_INFO since it is a dependency of another one.
If I change the Buildfile for "yi/top" to:
// Buildfile
config :"top",
:inlined_modules => [
:"yi/features",
:"yi/features/todos" // Added this line
]
Then it works because now "yi/features/todos" is in SC.MODULE_INFO.
This seems like a bug preventing nested module dependencies getting loaded.
Strangely sc_require() doesn't work when I want to require a file in the folder en.lproj.
sc_require("en.lproj/file")
It works perfectly when I use other folders eg. views.
Is the "dot" making it impossible to require?
/Johnny
As of RC2 (after upgrading from pre.5) the icons and any other images in base theme or any other reusable theme are not being copied over when compiled for production use. IT all works fine in debug mode though.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.