Even though I use the approach similar to the mixed formulation in the online tutorial (Mixed formulation for the Poisson equation):
BDM = VectorFunctionSpace(mesh, "BDM", 1)
DGv = VectorFunctionSpace(mesh, "DG", 0)
DGs = FunctionSpace(mesh, "DG", 0)
Vh = BDM * DGv * DGs
I have the same error as before:
Traceback (most recent call last):
  File "/home/simone/firedrake/src/PyOP2/pyop2/caching.py", line 197, in __new__
    return cls._cache_lookup(key)
  File "/home/simone/firedrake/src/firedrake/firedrake/tsfc_interface.py", line 53, in _cache_lookup
    return cls._cache.get(key) or cls._read_from_disk(key, comm)
  File "/home/simone/firedrake/src/firedrake/firedrake/tsfc_interface.py", line 74, in _read_from_disk
    raise KeyError("Object with key %s not found" % key)
KeyError: 'Object with key aec71f5f7a30a3d0b4db90beac07de85 not found'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
  File "Elasticity2D_Firedrake.py", line 163, in <module>
    solve(lhs_varf == rhs_varf, sol, bcs=[bc1,bc2])
  File "/home/simone/firedrake/src/firedrake/firedrake/solving.py", line 125, in solve
    _solve_varproblem(*args, **kwargs)
  File "/home/simone/firedrake/src/firedrake/firedrake/solving.py", line 152, in _solve_varproblem
    appctx=appctx)
  File "/home/simone/firedrake/src/firedrake/firedrake/variational_solver.py", line 335, in __init__
    super(LinearVariationalSolver, self).__init__(*args, **kwargs)
  File "/home/simone/firedrake/src/firedrake/firedrake/variational_solver.py", line 182, in __init__
    options_prefix=self.options_prefix)
  File "/home/simone/firedrake/src/firedrake/firedrake/solving_utils.py", line 131, in __init__
    form_compiler_parameters=self.fcp)
  File "/home/simone/firedrake/src/firedrake/firedrake/assemble.py", line 158, in create_assembly_callable
    loops = tuple(loops)
  File "/home/simone/firedrake/src/firedrake/firedrake/assemble.py", line 228, in _assemble
    kernels = tsfc_interface.compile_form(f, "form", parameters=form_compiler_parameters, inverse=inverse)
  File "/home/simone/firedrake/src/firedrake/firedrake/tsfc_interface.py", line 212, in compile_form
    number_map, interface, coffee).kernels
  File "/home/simone/firedrake/src/PyOP2/pyop2/caching.py", line 199, in __new__
    obj = make_obj()
  File "/home/simone/firedrake/src/PyOP2/pyop2/caching.py", line 189, in make_obj
    obj.__init__(*args, **kwargs)
  File "/home/simone/firedrake/src/firedrake/firedrake/tsfc_interface.py", line 121, in __init__
    tree = tsfc_compile_form(form, prefix=name, parameters=parameters, interface=interface, coffee=coffee)
  File "/home/simone/firedrake/src/tsfc/tsfc/driver.py", line 57, in compile_form
    fd = ufl_utils.compute_form_data(form, complex_mode=complex_mode)
  File "/home/simone/firedrake/src/tsfc/tsfc/ufl_utils.py", line 59, in compute_form_data
    complex_mode=complex_mode
  File "/home/simone/firedrake/src/ufl/ufl/algorithms/compute_form_data.py", line 298, in compute_form_data
    form = apply_function_pullbacks(form)
  File "/home/simone/firedrake/src/ufl/ufl/algorithms/apply_function_pullbacks.py", line 267, in apply_function_pullbacks
    return map_integrand_dags(FunctionPullbackApplier(), expr)
  File "/home/simone/firedrake/src/ufl/ufl/algorithms/map_integrands.py", line 58, in map_integrand_dags
    form, only_integral_type)
  File "/home/simone/firedrake/src/ufl/ufl/algorithms/map_integrands.py", line 39, in map_integrands
    for itg in form.integrals()]
  File "/home/simone/firedrake/src/ufl/ufl/algorithms/map_integrands.py", line 39, in <listcomp>
    for itg in form.integrals()]
  File "/home/simone/firedrake/src/ufl/ufl/algorithms/map_integrands.py", line 46, in map_integrands
    return itg.reconstruct(function(itg.integrand()))
  File "/home/simone/firedrake/src/ufl/ufl/algorithms/map_integrands.py", line 57, in <lambda>
    return map_integrands(lambda expr: map_expr_dag(function, expr, compress),
  File "/home/simone/firedrake/src/ufl/ufl/corealg/map_dag.py", line 37, in map_expr_dag
    result, = map_expr_dags(function, [expression], compress=compress)
  File "/home/simone/firedrake/src/ufl/ufl/corealg/map_dag.py", line 84, in map_expr_dags
    r = handlers[v._ufl_typecode_](v)
  File "/home/simone/firedrake/src/ufl/ufl/corealg/multifunction.py", line 42, in _memoized_handler
    r = handler(self, o)
  File "/home/simone/firedrake/src/ufl/ufl/algorithms/apply_function_pullbacks.py", line 256, in form_argument
    return apply_single_function_pullbacks(o)
  File "/home/simone/firedrake/src/ufl/ufl/algorithms/apply_function_pullbacks.py", line 151, in apply_single_function_pullbacks
    assert len(gsh) == 1
AssertionError
Thank you so much, have a wonderful day.
Best regards,
Simone