I have a package named jiva_tasks, which I'm trying to import via celery (using the CELERY_IMPORTS attribute of celeryconfig. The import statement that celery is using is this:
__import__(module, [], [], [''])
Oddly enough, when this syntax is used, the module gets imported twice, once as jiva_tasks and another time as jiva_tasks. (w...
In Jinja2, how can one access assigned variables (i.e. {% set X=Y %}) within files incorporated with include?
I'd expect the following to work given two Jinja2 files:
A.jinja:
Stuff
{% include 'B.jinja' -%}
B has {{ N }} references
B.jinja:
{% set N = 12 %}
I'd expect that A.jinja, when compiled with Jinja2, would produce the fol...
After choosing 'Range Type:' Table Range and 'Select Range:' Sheet1!Table1
I get the error pop-up 'Import to Windows SharePoint Services list' 'Cannot connect to the server at this time. Your table cannot be published.'
Is there somewhere in my computer I can look at for more information as to what I am doing wrong?
...
main:.
├─a
│ ├─__init__.py
│ └─aa.py
├─b
│ ├─__init__.py
│ └─bb.py
└─cc.py
if i am in aa.py , how to import cc.py ?
this is my code ,but it is error :
from main import cc
what should i do .
thanks
updated
in normal python file (not on gae),i can use this code :
import os,sys
dirname=os.path.dirname
path=os.path....
Hello, I have write a small python module with one class and two functions. The skeleton of the module is as following:
#file name: test_module.py
class TestClass:
@classmethod
def method1(cls, param1):
#to do something
pass
def __init__(self, param1):
#to do something
...
def fun1(*params):
#to do something
....
I have a directory structure:
example.py
templates/
__init__.py
a.py
b.py
a.py and b.py have only one class, named the same as the file (because they are cheetah templates). For purely style reasons, I want to be able to import and use these classes in example.py like so:
import templates
t = templates.a()
Right now I ...
Hi
Ive gained so much knowledge/insight from this site in the past few years, now im actually hoping to get some enlightenment.
The scenario is as follows:
You have the general structure of the repo (trunk,branches,tags) but added to the layout you have another directory called 'db_revs'. Now in the pre-commit, you take a dump of a spec...
Below is the xml content generated by TFPT for the WIQL issued. When I try to import this XML into Excel 2007 XML source pane shows only "Id", "RefName" and "Value" as fields to be mapped. Whereas I would like to display System.Id, System.State, Microsoft.VSTS.Common.ResolvedDate, Microsoft.VSTS.Common.StateChangeDate as column heading...
I have a textfile that has the format
gene complement(22995..24539)
/gene="ppp"
/locus_tag="MRA_0020"
CDS complement(22995..24539)
/gene="ppp"
/locus_tag="MRA_0020"
/codon_start=1
/transl_table=11
...
I seem to have found an anomaly with MYOB (I've actually found many anomalies, this is just another one that is doing my head in...)
I am generating a file with all invoices from the web system - no problems.
If an invoice has 3 lines and the account is paid COD, I am having an problem
e.g.
"INV", "DATE" ... "AMOUNT", "INC TAX AMOUNT...
Hello,
I have a problem with importing owl files using owl api in Java. I successfully can import 2 owl files. However, a problem occurs, when I try to import 3 or more owl files that are integrated to each other.
E.g.
Base.owl -- base ontology
Electronics.owl -- electronics ontology which imports Base.owl
Telephone.owl -- telephone on...
Sometimes I need a useful utility function, like List::Util::max in the middle of a large program that does lots of stuff. So if I do
use List::Util 'max';
At the top of my program, I'm stuck with that symbol, polluting my whole namespace, even though I only need it in one subroutine.
So I've been thinking of trying a different patte...
Hi everyone,
I wanted to know if anyone here knows how to import a 3D Object (i.e. Maya 3D Model) into Adobe Flex Application? I needed to create a simple Flex application which will allow me to rotate the 3D Object by dragging but I cannot seem to start doing it because I'm having a hard time trying to figure out how I can import my 3D...
I'm running an import script which imports a CSV dump of a database into a local sqlite database using DataMapper.
My models look like this:
class Staff
include DataMapper::Resource
property :staff_id, String, :key => true
property :full_name, String
end
class Project
include DataMapper::Resource
property :pro...
I know JavaScript is client side and PHP is server-side. I also know this is an odd question. However, the CMS editor I'm using will not allow php to be stored to the database (it's the same editor used by Dupral). I can store JavaScript though.
Can I import a php file with JavaScript. Or rather read the php file, store the content in a...
What is the difference a changeset and a patch?
I was using hg today and I noticed the import command mentions that it is used to "import an ordered set of patches."
What is a patch?
...
I have two databases, on two separate SQL Servers (trying to consolidate both).
This is my setup, and I'm trying to import from Server1:Orders table to Server2:Orders table.
Server1
Database1
Orders(ID, CustomerName, DateOrdered)
Server2
Database2
Customers(ID, Name)
Orders(ID, CustomerID, DateOrdered)
...
I need to create a function to rotate a given matrix (list of lists) clockwise, and I need to use it in my Table class. Where should I put this utility function (called rotateMatrixClockwise) so I can call it easily from within a function in my Table class?
...
Hi guys. I just switched from Access 2003 to Access 2007. In the very first "dev" copy (as I call it) pre-split, pre-front end, I need to import some data that are text files. I try to use the ribbon to do this, and after I walk through the steps I get this little pop up box that states
Microsoft Access has determined this to be a pot...
Here are some various Python packages my company "foo.com" uses:
com.foo.bar.web
com.foo.bar.lib
com.foo.zig.web
com.foo.zig.lib
com.foo.zig.lib.lib1
com.foo.zig.lib.lib2
Here's the traditional way to store the source on disk:
pysrc/
com/
foo/
bar/
web/
lib/
zig/
web/
lib/
l...