vendredi 25 décembre 2015

Remote .db file doesn't change

I'm using cyclone to develop an application on OpenShift.

That application uses sqlite3 to connect to .db file and changes it.

script_dir = os.path.dirname(__file__)
rel_path = "database/main.db"
database = sqlite3.connect(os.path.join(script_dir, rel_path), timeout=1)
database.row_factory = sqlite3.Row
db = database.cursor()

def closegame(id):
    db.execute("UPDATE games SET Running = 'No' WHERE ID = ?", (id,))
    database.commit()

  • When I download the file with

    rhc scp appname download mylocation remotelocation
    
    

    there's no change.

  • When I try to git fetch/merge/pull, it's already up to date.

  • When I restart the application, result is the same and the application is still using the updated version of .db

  • When I git push, the file is overwriten by my local file

  • Adding path/database/main.db to .gitignore still overwrites the file

  • git rm --cached deletes the file completely from remote, so application won't even launch

  • git update-index --assume-changed has no effect

Ideally I'd love for the file to never be overwriten by push, but to be able to download it by pull. If that's not possible, just being able to pull it would be nice.

Aucun commentaire:

Enregistrer un commentaire