Custom Query (121 matches)
Results (70 - 72 of 121)
| Ticket | Resolution | Summary | Owner | Reporter |
|---|---|---|---|---|
| #134 | invalid | Nested lists seems to be "dumped" incorrectly | xi | maksims.juvcenko@… |
| Description |
Problem occurs, when nested list is dumped. >>> s = {"a": ['aaa','bbb','ccc']}
>>> print yaml.dump(s, default_flow_style=False)
a:
- aaa
- bbb
- ccc
According to specification of YAML 1.1 nested sequence items must have entry token equal to " -" (two spaces and minus symbol), but in reality it lacks entry spaces. This issue creates limitations, when YAML documents are passed between PyYAML and JYaml interpreters. Configuration:
|
|||
| #168 | invalid | Appengine query models | xi | martinhoarantes@… |
| Description |
Hi, I´m using Google Appengine, language Python. I´d like to know how to query a model. I´m using this code, but the output is miserable: class GerarYAML(webapp.RequestHandler):
def post(self):
user = users.get_current_user()
if user:
formacaos = models.Formacao().all()
experiencias = models.Experiencia().all()
investigacaos = models.Investigacao().all()
distribuicaos = models.Distribuicao().all()
docentes = models.Docente.all()
docentes.filter('user =', users.get_current_user())
for docente in docentes:
for formacao in formacaos:
for experiencia in experiencias:
for investigacao in investigacaos:
for distribuicao in distribuicaos:
formacao.docente = docente.key()
'Nome: %s' % (docente.nome)
'Apelido: %s' % (docente.apelido)
'Unidade: %s' % (docente.unidade)
'Categoria: %s' % (docente.categoria)
'Regime: %s' % (docente.regime)
'Formacao: %s' % (formacao.formAno)
'Grau de Formacao: %s' % (formacao.formGrau)
'Area de Formacao: %s' % (formacao.formArea)
'Instituicao Academica: %s' % (formacao.formInstituicao)
'Classificacao Final: %s' % (formacao.formClassificacao)
yaml.dump(docente, sys.stdout)
yaml.dump(formacao, sys.stdout)
yaml.dump(experiencia, sys.stdout)
yaml.dump(investigacao, sys.stdout)
yaml.dump(distribuicao, sys.stdout)
self.response.headers['Content-Type'] = 'application/yaml'
self.response.headers['Content-Disposition'] = 'filename = my.yaml'
Can someone point out, how can i solve this issue? I´d like to download a file automatically when user submit a button with .yaml format and more or less formatted. |
|||
| #183 | invalid | Simple event generated code fails with MemoryError while around 100 bytes yaml is expected as output | xi | matkor |
| Description |
Attached code fails with: Saving to file: 'test.yaml' Traceback (most recent call last):
|
|||
