Edit this page on GitHub

Reserved variable names

The following variables are set internally by docassemble. If you try to use these reserved names for your own purposes, you will experience errors or unexpected results.

If you include a modules block including docassemble.base.util, the following additional names will be used:

If you include a modules block including docassemble.base.legal, the above names will be used, as well as the following additional names:

If you include the basic-questions.yml file from docassemble.base, the names included by docassemble.base.legal will be included, and the following names will also be used:

  • advocate
  • blank_signature
  • case
  • client
  • court
  • empty_signature
  • jurisdiction
  • pleading
  • role
  • role_event
  • role_needed
  • spouse
  • user
  • user_understands_how_to_use_signature_feature
  • user_understands_no_attorney_client_relationship

In addition, Python uses the following names as part of the language. If you use any of these as your own variable names, you may encounter an error or an unexpected problem.

  • ArithmeticError
  • AssertionError
  • AttributeError
  • BaseException
  • BufferError
  • BytesWarning
  • DeprecationWarning
  • EOFError
  • Ellipsis
  • EnvironmentError
  • Exception
  • False
  • FloatingPointError
  • FutureWarning
  • GeneratorExit
  • IOError
  • ImportError
  • ImportWarning
  • IndentationError
  • IndexError
  • KeyError
  • KeyboardInterrupt
  • LookupError
  • MemoryError
  • NameError
  • None
  • NotImplementedError
  • NotImplemented
  • OSError
  • OverflowError
  • PendingDeprecationWarning
  • ReferenceError
  • RuntimeError
  • RuntimeWarning
  • StandardError
  • StopIteration
  • SyntaxError
  • SyntaxWarning
  • SystemError
  • SystemExit
  • TabError
  • True
  • TypeError
  • UnboundLocalError
  • UnicodeDecodeError
  • UnicodeEncodeError
  • UnicodeError
  • UnicodeTranslateError
  • UnicodeWarning
  • UserWarning
  • ValueError
  • Warning
  • WindowsError
  • ZeroDivisionError
  • __debug__
  • __doc__
  • __import__
  • __name__
  • __package__
  • _
  • abs
  • all
  • and
  • any
  • apply
  • as
  • assert
  • basestring
  • bin
  • bool
  • break
  • buffer
  • bytearray
  • bytes
  • callable
  • chr
  • class
  • classmethod
  • cmp
  • coerce
  • compile
  • complex
  • continue
  • copyright
  • credits
  • def
  • del
  • delattr
  • dict
  • dir
  • divmod
  • elif
  • else
  • enumerate
  • eval
  • except
  • exec
  • execfile
  • exit
  • file
  • filter
  • finally
  • float
  • for
  • format
  • from
  • frozenset
  • getattr
  • global
  • globals
  • hasattr
  • hash
  • help
  • hex
  • id
  • if
  • import
  • in
  • input
  • int
  • intern
  • is
  • isinstance
  • issubclass
  • iter
  • lambda
  • len
  • license
  • list
  • locals
  • long
  • map
  • max
  • memoryview
  • min
  • next
  • not
  • object
  • oct
  • open
  • or
  • ord
  • pass
  • pow
  • print
  • print
  • property
  • quit
  • raise
  • range
  • raw_input
  • reduce
  • reload
  • repr
  • return
  • reversed
  • round
  • set
  • setattr
  • slice
  • sorted
  • staticmethod
  • str
  • sum
  • super
  • try
  • tuple
  • type
  • unichr
  • unicode
  • vars
  • while
  • with
  • xrange
  • yield
  • zip

In addition, you should never use a variable name that begins with an underscore. Although _internal is the only variable in the variable store that begins with an underscore, the docassemble web app uses names that begin with underscores to communicate information between the browser and the server, and if your variable names conflict with these names, you may experience errors or unexpected results. These internal names include:

  • _attachment_email_address
  • _attachment_include_editable
  • _back_one
  • _checkboxes
  • _datatypes
  • _email_attachments
  • _files
  • _question_number
  • _question_name
  • _save_as
  • _success
  • _the_image
  • _track_location
  • _tracker
  • _varnames

The following URL parameters have special meaning in docassemble. All others are available for you to use and to retrieve with url_args.

  • i: indicates the interview file to use
  • session: indicates the key of the stored dictionary to use
  • action: used by the url_action() function
  • filename: used for retrieving documents
  • question: used for retrieving documents
  • format: used for retrieving documents
  • index: used for retrieving documents
  • from_list: indicates that interview was launched from the Interview List page