Coder Social home page Coder Social logo

floof's Introduction

floof is a communal art gallery Web site.  It's powered by Python and runs atop
Pyramid.

* http://www.python.org/
* http://www.pylonsproject.org/


# Installation

First, make sure you've pulled in git submodules:

    git submodule init
    git submodule update

Use the setuptools setup script:

    python setup.py install
    -- OR --
    python setup.py develop

If you're a developer, you probably want `develop` instead of `install`, and
you may wish to consider using virtualenv to keep floof's Python environment
separate from the rest of your system.

Create a floof configuration file by copying the template:

    cp paster.ini config.ini

You may call this file whatever you want, for example `development.ini` or
`production.ini`.

Configure as appropriate, then set the sqlalchemy.url parameter in alembic.ini
to point to the same database as the floof config file.

Finally, run the setup script to populate the database and configure the CA:

    python bin/setup-floof.py config.ini#floof-prod alembic.ini

## File storage

You have two options for storing files, controlled by the `filestore` setting:

* **local** stores files in the filesystem normally.

    The `filestore.directory` setting specifies the root of the storage.  This
    directory must already exist and be writable by the Python process.

* **mogilefs** stores files in the MogileFS distributed filesystem.  You'll
    need the `pymogile` package installed, available from
    https://github.com/AloneRoad/pymogile in the 2.0 branch.

    `filestore.trackers` is a space-delimited list of trackers.

    `filestore.domain` is the name of the MogileFS domain under which all the
    files will be stored.

    See the mogile docs for creating a basic mogile environment:
    http://code.google.com/p/mogilefs/wiki/InstallHowTo

For development, invoke the application with:

    bin/dev-server.sh config.ini

If you hit some annoying problem during installation, check WORKAROUNDS.  If
the problem or answer is not there but you subsequently work it out, add your
solution to WORKAROUNDS for the sake of those who follow.


# Testing

To invoke testing, run from the top level directory:

    python setup.py test

floof's People

Contributors

cattrinket avatar eevee avatar epii avatar habnabit avatar magical avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

floof's Issues

Rename internal BrowserID stuff to Persona

The UI only ever refers to "Persona" now, but we have some classes and db tables and whatnot that still call it "browserid". Mismatches like this always end up confusing, so we oughta fix it sometime.

Better rich text support

We support Markdown, but nobody knows that, because we don't say it anywhere.

  • Say it somewhere.
  • Show a live preview of your text, rendered, as you type. (Could be either a client-side thing and/or a server roundtrip; both have their downsides.) Support a regular synchronous preview for dumb clients, of course.
  • Figure out a way for us to add Markdown extensions without sucking, because we're totally gonna want to do this soon, for stuff like links to users and embedded avatars.
  • Ideally, find a JS wysiwyg gizmo that doesn't blow ass.

Finish user pages

I don't know what this means. There aren't many things there, the things that are there aren't finished, and so forth.

Support written art

Most art sites do a crappy job of this. I'd like to do a less crappy job.

Forms of written art that come to mind:

  • Stories
  • Poetry
  • Essays

Features this absolutely needs:

  • Damn good importing from various formats: HTML, plaintext, Markdown. RTF? Direct from Google Docs? OD? Fuck Word, though.
  • Download in useful formats: plaintext, PDF, HTML. Mobi? ePub?
  • Preview before you upload that allows for fixing the formatting somehow
  • Really nice presentation
  • Useful thumbnails (but not images!)

Written works especially tend to be broken into chunks, so this would also benefit greatly from #34, versioning.

Staging area for uploaded art

Uploaded art sometimes needs to live on the server before it's actually committed to the db. Several uses for this:

  • Faster turnaround time. People tend to pick the file first and then do all the metadata; if we upload as soon as we know the file, the final submit is much quicker.
  • Batch uploads: dump a bunch of sketches, then sort them out one at a time.
  • Upload via alternative mechanisms, like FTP.

Concerns:

  • Abuse! Shouldn't be possible to use us as Dropbox, or eat all our memories, or otherwise be a dick. I suppose we'd have space constraints and nuke files after X time.
  • Security, kinda: e.g. FA had a problem with temporary Flash uploads living on the same domain. Or maybe it still has that problem. Ahem.
  • Artists outright forgetting about staged art. We should maybe bug them somehow about stuff they left behind from e.g. a mass upload.

Art deletion

Right, well, this will happen eventually.

I don't like deletion. It makes the site worse, obviously. But I don't want to annoy artists, either.

  • Everything should be soft-deleted. Very few people should have the power to immediately and irreversibly delete anything.
  • We should go to great lengths to discourage deleting art—or, rather, encourage keeping it. Why do artists take their art down and what can we do about that? Dislike of the site, bad reaction from the userbase, dislike of old art...
  • I'm tempted to just forbid deleting CC art or something, but I doubt that'll go over very well. Maybe there's room here for having art still marked as by you but not actually in your gallery. Or maybe this can be covered by clever use of albums... which is another ticket.

Finish watching

I don't actually know if this is done, ho ho.

I also don't know if we want to have only "watching", or also friending, or something. People watch other people to see their art, to promote their art, and just because they're buddies. Surely we can capture these intentions somehow. Maybe it's possible to do something like with plug albums, where if you're watching B who plug-watches C, you get a notification. Or maybe that would be super annoying.

I also also don't know how finely-grained the controls for what you actually watch should be. Tags per artist would be horrendously inefficient, but I assume if you don't want to see pony art from one artist, you don't want to see it from any artist, so the tag filter ought to cover that. Per-album? Just art-vs-announcements-vs-plugs?

Do artists actually care about every individual new watch? I mean, when you're just starting out, knowing someone new watched you is pretty cool, but I doubt established artists care too much about the hundred strangers who newly want to see their art. Need to think about this when doing notifications (#16).

addendum: It occurs to me that there is no global UI for indicating newly-watched art, and the watchstream doesn't have any concept of read-vs-not. Whoops!

Better tag index

Tags are supposed to be a pretty central theme here. Make the tag browser super awesome.

Art licenses

Let artists pick the license for their art. Default should be something (human-readable) about a license to let us use it.

Somewhat legal question: if an artist licenses a piece as CC, is it possible to revoke that? (More relevant later, as I've considered making CC art some form of undeleteable.)

addendum: There are rel tags to indicate the license of things on a page, so do that too. Also, offer public domain.

Tattling

Ahem, "reporting". Though I like the idea of straight-up calling it "tattling" in the UI. It would make me think twice about frivolous reports, but feel awesome about genuine ones.

Obviously users should be able to tattle on art. Anything else? Gosh we don't really have policies yet.

Support illustrations for written work

I've seen numerous instances of visual art drawn by A uploaded with a matching story written by B pasted as the "description". This blows.

Let's rig a way to have these uploaded separately, but let the writer stick a floated thumbnail in an appropriate place in the prose. Presumably the visual art would have a backlink as well.

Obviously requires #35, written art. Also may require #16, system messages, for approval from both sides.

User annotations

LiveJournal let you add a "note" for each of your friends that only showed for you, so you could e.g. note a more familiar moniker for someone with a weird username and still remember who the heck s/he was. I always liked that; perhaps steal it.

Multi-user native oekaki

This would be so fucking cool. Native browser functionality only, but allowing multiple people to draw and/or chat, like paintchat or opencanvas or whichever of those did this.

Note that Wacom has a browser plugin for Win/Mac that provides pressure data: http://www.wacomeng.com/web/release_notes.htm

And then it would save directly to the site as art, naturally.

Figure out how to deploy with pyscss

I switched us to pyscss instead of regular Ruby sass. The old system involved having Pyramid compile a bunch of Sass to CSS on startup, which was kind of insane. Now we have a scss.cache setting available, which caches the compiled CSS in-process, but that's also kind of insane. Need to do something to compile these to disk just once at deploy time and never touch pyramid_scss in production.

Time for a build system?

System messages

Gotta tell peeps what's happening.

Example events from the old ticket:

  • someone rates your art
  • someone albums your art
  • someone watches you
  • someone claims you collaborated on an art

Comments are a bit more complex:

  • someone replies to your art
  • someone replies to your journal
  • someone comments on your userpage
  • someone replies to your comment on not-your artwork
  • someone replies to your comment on not-your journal
  • someone replies to your comment on not-your userpage

Torn on whether this is 0.5 or 0.6, but I guess it's not strictly necessary.

Comment tails

Following an active nested discussion is a fucking nightmare. Provide a /tail page for a discussion that shows the most recent X comments and their context.

Journals, sorta

dA has recently taken to turning journals into a kind of submission, which means they can be favorited and categorized and put in collections and so forth.

I would kind of like to go the other direction and make journals less like a tacked-on blog. So, proposing directly out of my ass:

  • Instead of journals, have announcements that artists can post that will linger on their userpages for some amount of time. If they're no longer relevant, artists can manually expire them rather than "bumping them off". Actually announcing something is, as far as I can tell, the vast majority of actual art-related uses for journals.
  • If you have something interesting to write, that sounds to me like it's art, and it should go with all your other art. So let's support this kind of textual prose, somehow.

Omit rated art from gallery views, sometimes

If I'm clearly looking for new art, then art I've already rated shouldn't show up. (This also serves as a way to encourage people to rate.)

Obviously this shouldn't apply everywhere, but maybe it should be a default on the front page or suggestions or something.

Finish albums

I have a half-assed implementation done, but I already forget what I did and what else I wanted. These are kind of important.

  • Need a nice way to browse them, which I guess is part of #18 too.
  • Need a nice way to manage them—torn between whether this should be a dedicated page in the control panel, inline from the upload page, inline from the art page, inline from the list of your albums, or some combination thereof.
  • Need to be able to add/remove art from an album while looking at it.
  • Need to be able to add/remove art from an album within that album. (optimize for mass removal plz)

There are several kinds of albums, which are not yet all implemented:

  • Private
  • Public, my art only
  • Public, any art
  • Public, any art, and people watching me will see it too (reblogs!)

These also direly need short names that explain at a glance what they are for.

Also:

  • There are several existing abandoned approaches to this kind of thing that need removing.
  • Album URIs should contain the name, like art does.

Tag hierarchy and blessed tags

An old idea was to have a tree of "types" of art, like dA categories, separate from tags. I'm starting to think that can be folded neatly into these other two features.

Tags should be able to "inherit" from other tags implicitly: e.g., if artwork is tagged eevee, it is also treated as being tagged pokemon. Making this work efficiently is left as an exercise to the reader.

Some tags should be known, built-in tags with special significance, even if that significance is merely "is proposed on the upload page". Obvious examples are ratings for sex/violence/etc., but we could also fold medium into this.

addendum: This would be useful for distinguishing between, say, digital art vs scans, and photography vs photos of physical creations.

Front page is useless

It should be, like, not that.

The common thing is to show a bunch of recent art but I am tempted to say it should be a user-specific dashboard instead.

Statistics

I am all about the graphs.

Art page needs some kind of indicator of... something, though I don't really like view counts because they're so hilariously worthless. I do like the idea of showing the number of ratings as a measure of popularity: it captures the number of people who felt strongly enough to click an arrow, regardless of what they actually felt.

Do users need any overt popularity-contest number? View count sucks even more here, though by leaving it out we'd be killing kiribans. (Maybe we can do something first-class to replace them. They're arbitrary anyway.)

I want public graphs of site use over time, particular user visits/watches/whatever over time, art ratings over time, whatever. Artists who opt into seeing their scores should get to see what's rated highest, too. (Or maybe they should get to see that regardless, but without the numbers.)

Also it would be neat to capture referers. I think YouTube does that.

Suggestion engine

Suggest art I might like, based on my ratings and other ratings. Maybe suggest artists I'd like, too. Wire this idea into the site like crazy.

Bans

Temporary, permanent. Ban log should be transparent and public.

Fix "score" UI

  • When you're not logged in, there's a frankly gigantic message telling you that you need to log in to rate art. I'd rather just not show the controls; most guests won't even know that's a thing.
  • The score is shown as a floating-point number with a zillion decimal places, which sucks.
  • I'd really rather not show the score at all, at least by default. Show it to admins, show it to artists if they opt in somewhere, but otherwise, don't make this a popularity contest. The number of ratings is a nice statistic (and also discourages mass downvoting), so let's put that there instead.
  • Consider changing the symbols to adjectives (bad, eh, good?) instead; may or may not encourage more use.

Configurable userpages

Not sure if want. I find this more annoying than anything on dA, honestly; I have to study a page to figure out what the hell everything is, because most "components" are either blocks of text or grids of thumbnails.

Communal tagging

This is pretty important. Needs some things figured out, though.

  • How do we prevent malicious misuse? (Old proposal was tag karma, but that may be hilariously over-complicated.)
  • How do we prevent nonmalicious misuse, e.g. junk tags and tons of synonyms and arguing over what's "correct"? (Rules, first-class synonyms, hierarchy?)
  • Do we allow the artist editorial control, or leave it as a purely admin thing?

Probably depends on having system messages, #16.

Default albums for new users

People will probably expect the usual trappings of scraps, featured, and favorites. So offer to give them generic albums like those when they first sign up. (Opt-in or opt-out?)

Fancy tag UI

Need a JavaScript gizmo that suggests tags, adds/removes ajaxly, and other such niceties.

Minor cool thing: have it quietly alert you when you're creating a new tag, to help curb tag explosion. Suggest existing ones if possible.

It better work without JS or I will gut someone

Better handle very large images

Currently, the art page shows the actual image, scaled down with max-width. This has a couple of overt problems:

  1. If the image is very very large, the browser will be downloading a massive file and showing not very much of the detail.
  2. There's no obvious way to view the "entire" image.

We should perhaps generate medium-size previews of images large enough that they're unlikely to fit entirely on anyone's screen (1600+ or so?) and embed those on the art page. Also, we should make the art a link to itself, maybe with a cute magnifying glass cursor.

Note that if the image is narrow but very very tall, it won't be shrunken down at all. Not sure if this is actually a problem, but it's a consideration for how to generate the medium size.

Avatars

Right now it's all gravatar, and that isn't even indicated anywhere.

We never really decided how this should work, but some proposals included:

  • Multiple avatars, a la LiveJournal
  • Cropping or directly using existing art as an avatar, and automatically crediting it

There are also looming questions about how much avatars need emphasizing on an art site (note dA only allows 50px²), whether we care about copyright/licensing, and if we can generally do something more interesting with the concept because I am all about that.

Series and versions

Artwork is frequently a part of a linear series, or one of several revisions. Both of these should have first-class support.

Looming questions include:

  • How to depict these in watchstream, gallery views—surely a series should only appear once, right?
  • How tags and comments across versions would work—comments may lose context if shared, content tags would be the same but medium tags would not, etc.
  • How to add to a series or add a new revision, without sucking
  • How the schema should look
  • How to handle a series that spans multiple artists

I believe that editing artwork (i.e., uploading a new file to replace an existing one) should create a new revision, unless explicitly asked otherwise.

addendum: It would be pretty cool to support appropriate diffs between revisions.

Streaming notifications

Let an artist announce to all her watchers that she is streaming and where without having to post journals or junk artwork. Even better, some streaming platforms (like Livestream) have an API that indicates whether the channel is live; maybe we could rig an opt-in auto-detect thing here. Yesss.

Maybe requires #16, system messages. Also would be a great thing to put on the front page, #6.

User gallery

Need to be able to browse a user's art. Also need to be able to browse their albums, and their watchstream, and other things, without cluttering up the interface.

Related to #18, user pages.

Track sessions per user

For last-seen time, viewing existing logins, etc.

This would probably require either ditching Beaker for something hand-rolled (which is easy enough with Pyramid), or dicking around directly with Beaker's tables (which I would rather not do).

Not super hugely important though.

Art editing

I think at the moment this just means editing the title, the remark, and the art itself.

The remark and title can be edited inline much like tags; easy peasy.

Editing the art is... different, and should perhaps go under the concept of art versioning (#34). Please figure me out.

Multiple profiles per account

People keep hinting at this kind of thing for various reasons, like hiding half their interests from half their friends (ugh) or "character profiles" (ugggh).

Not really sold on those, but there is one place such a feature would be super useful, and that's group management. So, still worth considering, I suppose.

Federation

With other art sites? With ourselves? With some generic distributed social protocol?

Yep.

Drive-by logins

Sometimes I just want to leave a comment without going through the whole ordeal of signing up for a thing and eating up a username.

It would be neat to allow logging in with Persona but not creating a "user". I suppose you'd be identified either by your email, by a randomly-generated dummy name, or by a custom name that wouldn't care about collisions.

Adding a tag with a disallowed name can 400

Which is technically not wrong, but it's sure not helpful either.

Relatedly, we don't actually say anywhere what tags are allowed to look like. Maybe could use some placeholders, or little help-tip JS, or something.

Support auditory art

Music, mainly, I guess.

  • What would thumbnails look like?
  • What formats can we support that get us out of a Flash shim?
  • I've seen this used as a way to upload spoken rants, which seems inappropriate—do we care, and is that just a policy thing?

Update to latest Persona API

I think we're still using the old one.

New one subsumes the allowPersistent option, which we weren't using but should've been, so I guess we should... figure out how that matters.

Better indicate comment depth

In a thread like this:

comment
    comment
        comment
            comment
    comment

...it's kinda hard to see what that bottom comment is actually replying to. Often it looks like it starts an entire new thread. Do something about this.

Some options that are not mutually exclusive:

  • Light lines indicating the tree structure
  • Allow collapsing a thread once read
  • Draw a rule between separate threads (eh)

User comment history

Lemme see the comments you've written, and their context.

Also, comments could maybe count as userpage activity, but only if there's absolutely nothing else going on.

Tag filter

Let me specify a set of tags that will never appear for me, anywhere.

For bonus points, have an intermediate level that will still appear, but will show a warning thumbnail/interstitial.

Blessed tags (#27) probably ought to be suggested here. At least the content-y ones.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.