Skip to content

Instantly share code, notes, and snippets.

@mrvdb
mrvdb / gist:94ea6229902096da6df0
Created May 28, 2014 13:03
Upgrading GS from 1.1 to master
- Twitterbridge stops working completely
- the daemons, I'm using activemq, emit many DB error messages in the logfile, no notices go out or in
- avatar lookups giving failures in finding avatars
- upgrading becomes quite an excercise with a bigger database, it takes quite a while (not a bug)
- upgrade fails with DB error ('already exists') No clue on what already exists.
- file inclusion errors (Realtime_channel is one example) and different logic in lookup for CLI php scripts
- there is still something wrong with ssl configuration, not sure what, I have forced my local installation to off with a little patch.
(defun delete-process-interactive ()
(interactive)
(let ((pname (ido-completing-read "Process Name: "
(mapcar 'process-name (process-list)))))
(delete-process (get-process pname))))
@mrvdb
mrvdb / pumpbridge.diff
Created June 13, 2014 13:44
Syntax error diff
$hg diff
diff -r d2208a4ed5c8 src/facebook.coffee
--- a/src/facebook.coffee Thu Jun 12 20:58:06 2014 +0200
+++ b/src/facebook.coffee Fri Jun 13 15:43:30 2014 +0200
@@ -81,7 +81,7 @@
recipientUser: me
created: Date.now()
, callback
- ], (err, result) ->
+ ], (err, result) ->

(set-face-attribute ‘show-paren-match nil :inherit nil :foreground nil :weight ‘normal :background mrb-bg-paren-match)

;; Set regions so we keep the normal font locking (set-face-attribute ‘region nil :inherit nil :foreground nil :weight ‘normal :background mrb-bg-region)

diff --git a/plugins/TwitterBridge/lib/tweetinqueuehandler.php b/plugins/TwitterBridge/lib/tweetinqueuehandler.php
index 79d36d1..d0e877d 100644
--- a/plugins/TwitterBridge/lib/tweetinqueuehandler.php
+++ b/plugins/TwitterBridge/lib/tweetinqueuehandler.php
@@ -55,7 +55,14 @@ class TweetInQueueHandler extends QueueHandler
if ($flink instanceof Foreign_link) {
common_log(LOG_DEBUG, "TweetInQueueHandler - Got flink so add notice ".
$notice->id." to attentions for user ".$flink->user_id);
- Attention::saveNew($notice, $flink->getProfile());
+ try {
diff --git a/actions/apitimelineuser.php b/actions/apitimelineuser.php
index d3e3ba8..7c44871 100644
--- a/actions/apitimelineuser.php
+++ b/actions/apitimelineuser.php
@@ -228,8 +228,15 @@ class ApiTimelineUserAction extends ApiBareAuthAction
while ($notice->fetch()) {
if (count($notices) < $this->count) {
- // TODO: a feed without replies would be useful (extra param?)
- $notices[] = clone($notice);
sh-4.3$ ./bin/gmg
Traceback (most recent call last):
File "./bin/gmg", line 9, in <module>
load_entry_point('mediagoblin==0.6.2.dev', 'console_scripts', 'gmg')()
File "/usr/local/mediagoblin/mediagoblin/mediagoblin/gmg_commands/__init__.py", line 108, in main_cli
setup_func = import_component(command_struct['setup'])
File "/usr/local/mediagoblin/mediagoblin/mediagoblin/tools/common.py", line 34, in import_component
__import__(module_name)
File "/usr/local/mediagoblin/mediagoblin/mediagoblin/gmg_commands/shell.py", line 21, in <module>
from mediagoblin.gmg_commands import util as commands_util
function check_if_twist_starts_with_special_char ($send_only_when_msg_starts_with_this_char, $text) {
// Flag not set? Send it through
if (empty($send_only_when_msg_starts_with_this_char)) return true;
// Otherwise, only send if char mathes first of content
if ($text[0] === $send_only_when_msg_starts_with_this_char) return true;
// Still here, don't send it.
return false;
}
sh-4.3$ ./bin/gmg dbupdate
Traceback (most recent call last):
File "./bin/gmg", line 9, in <module>
load_entry_point('mediagoblin==0.6.2.dev', 'console_scripts', 'gmg')()
File "/usr/local/mediagoblin/mediagoblin/mediagoblin/gmg_commands/__init__.py", line 108, in main_cli
setup_func = import_component(command_struct['setup'])
File "/usr/local/mediagoblin/mediagoblin/mediagoblin/tools/common.py", line 34, in import_component
__import__(module_name)
File "/usr/local/mediagoblin/mediagoblin/mediagoblin/gmg_commands/shell.py", line 21, in <module>
from mediagoblin.gmg_commands import util as commands_util
sh-4.3$ ./bin/python ./setup.py develop
running develop
running egg_info
writing dependency_links to mediagoblin.egg-info/dependency_links.txt
writing requirements to mediagoblin.egg-info/requires.txt
writing mediagoblin.egg-info/PKG-INFO
writing top-level names to mediagoblin.egg-info/top_level.txt
writing entry points to mediagoblin.egg-info/entry_points.txt
reading manifest file 'mediagoblin.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'