How to Find the Directory Locations Your XCode App Uses
You can add this snippet to your application, say for instance in your `viewDidLoad` function, that will print to the XCode console, the location of your app while it's being developed. // prints the location of asset my-added-file.txt that you've ad...
Written by Sean Behan on 06/06/2018
How to Just Get SQL Statement Error with SQLAlchemy Python Database Wrapper
If you're working with SQLAlchemy, the best database driver for Python, and want to see only SQL syntax errors, you need to use the StatementError exception class. On it, is an attribute `orig`, that contains just the SQL syntax error... and not any data...
Written by Sean Behan on 05/10/2018
How to Fix Raw query must include the primary key with Django ORM
When running raw SQL queries in Django you must include a primary key otherwise an invalid query exception is raised. Normally this is fine but when running more complex queries a primary key may not be available or even make sense. There is a simple ...
Written by Sean Behan on 07/15/2017
How to Fix Pypi Upload failed (403): Invalid or non-existent authentication information.
If you run into authentication failure when trying to upload packages Submitting dist/ to https://upload.pypi.org/legacy/ Upload failed (403): Invalid or non-existent authentication information. error: Upload failed (403): Invalid or non-existent...
Written by Sean Behan on 03/02/2017
Turn Off SSL Verification In Ruby
The following code will disable SSL verification when using Open SSL. OpenSSL::SSL::VERIFY_PEER = OpenSSL::SSL::VERIFY_NONE It is probably not a good idea to do this in production. But if you are just testing on your development machine it might...
Written by Sean Behan on 03/02/2017