Skip to content

Instantly share code, notes, and snippets.

View krusty's full-sized avatar

Lucas Sallovitz krusty

View GitHub Profile
$(function () {
var account = new Account.Model(),
choices = new CatalogChoice.List(),
login = new Login.Views.Form(),
header = new Account.Views.Header({model: account}),
results = new Company.Views.Results(),
summary = new CatalogChoice.Views.Summary({collection: choices}),
welcome = new Pages.Welcome({model: account}),
dashboard = new Pages.Dashboard({model: account}),
signup = new Pages.Signup({model: account}),
var smb = {
parse: function (response) {
if (response.error_text) {
var ErrorMessage = smb.module('error_message');
var error_message = new ErrorMessage.Views.Flash({
message: response.error_text
});
}
if (typeof this.extra_parse === "function") {
return this.extra_parse(response);
lucas@(none):~/proyects/ccMainline$ rake sunspot:solr:regenerate --trace
DEPRECATION WARNING: Rake tasks in vendor/plugins/acts_as_sanitized/tasks, vendor/plugins/annotate_models/tasks, vendor/plugins/bj/tasks, vendor/plugins/busyajax/tasks, vendor/plugins/cache_fu/tasks, vendor/plugins/event_attribute/tasks, vendor/plugins/fitter_happier/tasks, vendor/plugins/jslint_on_rails/tasks, vendor/plugins/migration_test_helper/tasks, vendor/plugins/navigation_helper/tasks, vendor/plugins/redbox/tasks, and vendor/plugins/validates_url_format_of/tasks are deprecated. Use lib/tasks instead. (called from /home/lucas/.rvm/gems/ruby-1.8.7-p370@ccmainline/gems/rails-2.3.14/lib/tasks/rails.rb:10)
WARNING: 'task :t, arg, :needs => [deps]' is deprecated. Please use 'task :t, [args] => [deps]' instead.
at /home/lucas/proyects/ccMainline/lib/tasks/sunspot.rake:4
WARNING: 'task :t, arg, :needs => [deps]' is deprecated. Please use 'task :t, [args] => [deps]' instead.
at /home/lucas/proyects/ccMainline/lib/tasks/sunspot.r
$(function () {
Login = {};
Login.Views = {};
Login.Model = Backbone.Model.extend({
//curl -v -H "Accept: application/json" -H "Content-Type: application/x-www-form-urlencoded" https://sandbox.catalogchoice.org/oauth2/access_token -d "grant_type=password&[email protected]&password=apassword&client_id=8rmz3ts4r7dvr877i2zvrsw66&scope=read write"
url: "https://sandbox.catalogchoice.org/oauth2/access_token",
lucas@(none):~/proyects/ccapps/src/trainer$ ./run.sh form_training_set2.csv result.json
Parsing CSV
> Opening form_training_set2.csv
>> Parsed http://www.windowworld.com/contact.php TRUE
/home/lucas/proyects/ccapps/src/trainer/csv_parser.js:25
fs.appendFile(tmp_file, params);
^
TypeError: Object #<Object> has no method 'appendFile'
at [object Object].<anonymous> (/home/lucas/proyects/ccapps/src/trainer/csv_parser.js:25:6)
Request URL:https://sandbox.catalogchoice.org/oauth2/access_token
Request Method:POST
Status Code:302 Found
Request Headersview source
Accept:application/json, text/javascript, */*; q=0.01
Accept-Charset:ISO-8859-1,utf-8;q=0.7,*;q=0.3
Accept-Encoding:gzip,deflate,sdch
Accept-Language:en-US,en;q=0.8
Connection:keep-alive
Content-Length:114
lucas@(none):~/proyects/ccapps$ cat .hg/hgrc
[paths]
default = http://hg.assembla.com/ccapps
[ui]
username = Lucas Sallovitz <[email protected]>
ignore = /home/lucas/proyects/ccapps/.hg/hgignore
[auth]
tid.prefix = hg.assembla.com/ccapps
tid.username = lucas.s
tid.password = *******
012-06-21 14:18:59,051 - root - 5348 - ERROR [127.0.0.1 ALL DEV 5348] - generate_alerts_from_subscription error: 'NoneType' object does not support item assignment
Traceback (most recent call last):
File "/opt/source/src/dataaccess/alert_action.py", line 672, in generate_alerts_from_subscription
subscription.update_last_alert_rescan()
File "/opt/source/src/dataaccess/Containers.py", line 896, in update_last_alert_rescan
mitem.update_last_alert_rescan(date=date)
File "/opt/source/src/dataaccess/Containers.py", line 754, in update_last_alert_rescan
self._update_track_data('alert_rescan', date)
File "/opt/source/src/dataaccess/Containers.py", line 748, in _update_track_data
self['track_data']['last_%s' % (date_type,)] = date.isoformat()
012-06-12 17:06:54,351 - root - 2396 - ERROR [127.0.0.1 ALL DEV 2396] - collector_search_job job error: 'NoneType' object has no attribute 'makefile'
Traceback (most recent call last):
File "/opt/source/src/workers/smb_search_jobs.py", line 77, in collector_search_job
for i in src.search(identity, credentials):
File "/opt/source/src/dataaccess/sources/yahoo.py", line 48, in search
results = self.get_json_content(_base_place_url, params)
File "/opt/source/src/dataaccess/sources/source.py", line 184, in get_json_content
return json.loads(self.get_content(url, params=params, credentials=credentials, usecache=usecache))
File "/opt/source/src/dataaccess/sources/source.py", line 239, in get_content
header, content = self.send_request(uri, method='GET', credentials=credentials)
{
"subscriptions": [
{
"alerts": [
{
"ignored": false,
"alert_type": "missing_credentials",
"actions": [
{