Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6880311
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T04:57:27+00:00 2026-05-27T04:57:27+00:00

I’m having a problem when using django custom commands on Heroku. On my local

  • 0

I’m having a problem when using django custom commands on Heroku.
On my local machine, the custom command appears in help if I run ./manage.py help and running ./manage.py deletedphotos runs it too.
All the init.py files are there and the settings are also correct, i.e. there are not major config differences between my local and Heroku instances.

Now, when I put it on Heroku, it does not show up. All my other non-default commands are there: ping_google that comes from installing sitemap.xml support and commands for south migrations. But for some reason, my self written commands do not show up.

I’ve also sent a support request to Heroku, but haven’t heard back from them in a few days, so I thought I’d post here as well, maybe someone has had any similar problems.

The deletedphotos.py file contents are pretty much like this if that matters anything:

from django.core.management.base import BaseCommand, CommandError
from foo.app.models import *

class Command(BaseCommand):
    help = 'Delete photos from S3'

    def handle(self, *args, **options):
        deleted_photos = Photo.objects.filter(deleted=True).exclude(large='', small='', thumb='')
        self.stdout.write('Found %s photos\n' % str(len(deleted_photos)))

I’ve tried checking all the correct python paths etc, but not 100% if I’m not missing something obvious.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-27T04:57:28+00:00Added an answer on May 27, 2026 at 4:57 am

    I was actually able to find a solution. The INSTALLED_APPS had my local app referenced, but for some reason it was not working as intended.

    My app is in: /name/appname/ and having ‘name.appname’ in INSTALLED_APPS was working fine in local setup.

    Yet, on Heroku, I had to change the reference to just ‘appname’ in INSTALLED_APPS and all started working magically.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm using django with app-engine-patch and I'm having this wierd problem running manage.py dumpdata
I am using templates with django. I am having a problem where the Context
I'm having a problem using imaplib on python 2.6 with the latest django svn.
I'm having a problem uploading files on my production server. I'm using the django-stdimage
I am having an issue with what appears Django using the string name and
I am having problems using django-tagging . I try to follow the documentation but
I'm having a problem using the java.text.MessageFormat object. I'm trying to create SQL insert
I am having a problem using the Unity Application Block, I have created a
I'm having a problem using CSS's display:inline property with the list-style-image: property on <li>
I'm having a problem using UpdateModel(theModelToUpdate) causing concurrency issues. Basically whats happening is, there

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.