Opened 15 years ago

Last modified 11 years ago

#114 closed defect (FIXED)

Ability to delete media

Reported by: Jef van Schendel Owned by: Christopher Allan Webber
Priority: minor Milestone: 0.0.5
Component: programming Keywords:
Cc: Parent Tickets:

Description

Don't know if anyone is working on this...

I've added some text for a delete link to the media pages. Only thing that's missing is, well, the ability to delete things. :)

Change History (16)

comment:1 by Christopher Allan Webber, 15 years ago

Do we actually want to delete media or just mark it as deleted? We probably do want to... specifically, if there's media that has bad content on it, we want to get it off our servers.

So this issue should also handle removing the stored media in the public_store

comment:2 by Jef van Schendel, 15 years ago

We could add a timeout to make the process "safer". After clicking on "Delete", the files aren't actually deleted yet, just hidden. The changes can still be undone. Then after a while, it will be deleted for real.

Don't know if that makes sense. Probably makes the whole thing too complex.

comment:3 by Christopher Allan Webber, 15 years ago

http://docs.celeryproject.org/en/latest/userguide/executing.html#eta-and-countdown

Assuming we do deletion of media via celery, we can set a delay via eta like above. I'm not sure if that's the best route or not. Maybe if anything, eta can be an option.

comment:4 by joar, 15 years ago

Milestone: 0.0.4

comment:4 by Elrond, 15 years ago

Setting to 2 hours: If we just want a simple "delete" function, this one can be handled by a newcommer with some help from people around.

Even a confirmation page is simple. Get from the "delete"-link to the actual (post enabled form) for deletion. Very straight forward.

comment:5 by Caleb Davis, 15 years ago

Owner: set to Caleb Davis

0.0.3 meeting result

comment:6 by Caleb Davis, 15 years ago

Owner: set to Caleb Davis

I feel like I've been squatting on this one a bit too long. Released until I can get to it, or someone else grabs it.

comment:7 by Christopher Allan Webber, 15 years ago

Owner: set to Larisa Hoffenbecker

Assigning to Larisa!

Thanks Larisa, ping me on IRC if you have any questions!

comment:8 by Will Kahn-Greene, 15 years ago

Milestone: 0.0.40.0.5

We release 0.0.4, so I'm bumping this to 0.0.5.

comment:9 by Mark Holmquist, 15 years ago

Closed by https://gitorious.org/mediagoblin/mediagoblin/merge_requests/18

Feel free to close or report problems with my changes.

comment:10 by Christopher Allan Webber, 15 years ago

Owner: changed from Larisa Hoffenbecker to Mark Holmquist

Hiya Mark!

From first glance, this looks good! I'll try to check seriously tonight.

However I'd prefer it if you would split up different issues into different branches. For example, in this case it would be good to have a unicode fix branch and a delete branch.. for example, if the unicode stuff was ready but the delete stuff wasn't, I could merge in the unicode stuff while the delete stuff is still being finished. It also makes our git commit history clearer if you commit one issue per commit.

http://wiki.mediagoblin.org/Git_workflow

However, looking good, and GREAT job just diving into the codebase!

More thorough review tonight or at least shortly I hope!

comment:11 by joar, 15 years ago

Tested, reviewed, and added notice about the permanentness of a deletion.

https://github.com/jwandborg/mediagoblin/tree/f403_ability_to_delete

comment:12 by Christopher Allan Webber, 15 years ago

Hm. I looked, in general this is very close to being ready for merge, except a few things:

  • The actual media of the MediaEntry is not deleted... just the record of it. We should iterate through all media_files and attachment_files and actually delete all of these from the public_store.
  • The URL doesn't make sense to me... when I try deleting, I get a URL like: http://127.0.0.1:6543/u/cwebber/m/4e35f68c48b1520a5600001b/confirm/ ... but /confirm/? /confirm/ what ;) I think /confirm-delete/ makes more sense.
  • Not sure why a mediagoblin/confirm/ submodule was made... this seems to belong in mediagoblin/user_pages/.
  • Could use some tests, particularly making sure that other users can't delete your media for you! ;)

I merged this into master (there were some conflicts) and added a fix for the second bullet point (made it /confirm-delete/) but haven't done the rest. You can merge from: [https://gitorious.org/cwebber/mediagoblin/cwebbers-mediagoblin](https://gitorious.org/cwebber/mediagoblin/cwebbers-mediagoblin)

comment:13 by joar, 15 years ago

Owner: changed from Mark Holmquist to Christopher Webber
Status: NewFeedback

Updated at https://github.com/jwandborg/mediagoblin/tree/f403_ability_to_delete

  • Files and attachments in public_store that are related to the entry are now deleted
  • Removed confirm stuff and put it in user_pages
  • Created tests for the media_confirm_delete functionality

Cheers,

comment:14 by Christopher Allan Webber, 15 years ago

Status: FeedbackClosed

Merged, by the skin of our noses for this release! Nice job everyone on this!

comment:15 by Will Kahn-Greene, 14 years ago

The original url for this bug was http://bugs.foocorp.net/issues/403 .

Note: See TracTickets for help on using tickets.