Posts – Page 10

Start screen after su’ing to another user

Today’s problem is one that requires no introduction (well, maybe it does :-| ) but it’s a problem nonetheless.  The issue is that after using the ‘su‘ command to become another user, there’s trouble running screen sessions.

This page (http://dbadump.blogspot.com/2009/04/start-screen-after-sudo-su-to-another.html) details it simply and perfectly (which, yes, I know in turn came from another page).  Essentially the error is thus:

Cannot open your terminal '/dev/pts/1' - please check.

Which really doesn’t man nor beast with its descriptiveness.  From that page, which came from another page mentioned on that page (?), here …

Deliverance, Plone, and tags

It’s been a little bit of time since my last post, and who can blame me with my site having been down for almost 2 full days over the last week!  I’m not paying that much for the webspace, thankfully, but if I was, I’d be seeing red over it.  Apparently some patch for MySQL broke everything; imagine how it looked to see my site with a ‘500 internal error’ plastered all over it and not being able to access my cPanel. Ugh.

Anyway, everything’s back again, assuming that you can see this.  Okay? Great!

Today …

Plone/Zope, Python and collective.autoreload / plone.reload

Here’s an interesting error message I got stumped with for a good set of hours.  The issue started with me using collective.autoreload with Plone and it does the trick, mostly.  With any such ‘operation’ and live reloading of code for Python, you’ve got to expect that not everything will go according to plan.  Most things do, but one issue I found presented with this error message:

< ... huge traceback ...>
TypeError: super(type, obj): obj must be an instance or subtype of type

The issue arises for me (and you’ll probably see it elsewhere) when I go ahead …

Ubuntu 9.10 install hiccough

Yay, the new version of Ubuntu is out.  With it comes plenty of cool new features (how awesome does the start up and login screen look now?) and also plenty of opportunities for things to break when I’ve become so accustomed to having them working.  At least it’s not Windows though — I think I may just gnaw my own limbs off before I have to get forced to upgrade to Windows 7 for gaming reasons.

But I digress, there was one reasonably small problem with the upgrade that I saw on both of my Ubuntu machines (laptop and …

HTML formatting made easy

There’s a tool for everything somewhere on the web.

Whilst about 99.5% perfect (some indentation issues remain), I’ve found a pretty nice, easy to use, and very feature-rich HTML code formatter. See http://www.mycoolform.com/index.php?lang=en for the formatter.

It’s something I was looking for a while back but didn’t have so much luck to stumble onto something so useful.  Previously, I was looking for something that would fix up some HTML to XHTML and whilst I’m sure something was out there, the problem was I needed something that would …

A little time out

Taking a little time out from the professional blogging, here’s a page out of my personal side of things.

Things have been very busy as of late and, as the previous sentance suggests, not just with work. Tomorrow’s the day when my and my partner’s house settlement takes place and after all the bumps along the way, we’ve finally gotten there. The bumps were sadly some very unprofessional dealings with my fiancier credit union (who will otherwise remain nameless), an inability of lawyers and conveyancers to add numbers together, and a whole lot of confusion. As …

Missing content menus in Plone

Another dose of insanity please!  Coming right up, sir.

Today’s second discussion comes from an issue I was having recently with a new Plone site that I was hosting behind Apache and Deliverance.  No Varnish here yet, because I’d rather the site worked first before I try and cache the life out of it.

Now, the specific problem I was having was that the content menus in Plone (eg Add New, Display, State, Actions and for me, Sub-types) weren’t displaying.  I thought it a Deliverance issue - maybe I was dropping those content items accidentally or not including …

Migrating a Plone site off to another database (Zeo)

Another of the interesting things in my professional life has been migrating a Plone site from one database (where it lived as a dev site, along with many others) onto a nice, clean database of its own.  Now, yes, I’m aware that the export/import feature of Zope isn’t supposed to be used for migrating content or sites.  I am also aware, however, through personal experience, that things have always been fine because I’m using the same eggs and essentially the same installations everywhere, thanks to buildout.

So, the process goes as follows, with the above-mentioned points …

LDAP-Authenticated Server & Whoami Failures (etc)

I’m back again, after a bit of a unscheduled ‘break’ in my normal work life.  After a couple of days away for work on the Gold Coast, then the sad passing of my Grandfather and his memorial, then being sick over the last weekend from what I can only guess was a nasty 24-hour bug, I’m back.  And whilst a little worse for wear still today, it’s life pretty much as normal.

Today’s fun and games was on a server we use that uses LDAP authentication for its users.  Nothing special, except that today I started …

PloneFormGen (Plone) & Google Calendar Integration

It’s a little bit of a different mash-up, but it’s still nonetheless useful to have, given types of booking forms and so forth that could utilise it.  The easiest way I found (to avoid security issues with Python scripts in Plone) was to create an external method and just import it within a PFG Custom Adapter.

Parts

  • My GoogleCalendar.py external method.  I’ve had to add this into a policy product I have.  The function should be generalised enough to work with any Google account, hosted or not.  In short:

    • It takes in a variety of arguments …