Skip to content

Error screen when copying answer set #1001

@BryceStevenWilley

Description

@BryceStevenWilley

Stuck on this one for too long, noting it and moving on.

Has happened on prod a few times, and is inconsistently reproducible (possibly happens immediately after a server restart?): on the interview list page (https://apps-dev.suffolklitlab.org/start/AssemblyLine/interview_list/), click the copy button next to any of your sessions, and note the name of the answer set on the next page. This error will show up on the screen after:

Interview has an error. There was a reference to a variable 'interview_list_copy_action' that could not be looked up in the question file (for language 'en') or in any of the files incorporated by reference into the question file.

interview_list_copy_action is defined, the code block looks like this:

code: |
  save_interview_answers(
      source_filename=action_argument("filename"),
      source_session=action_argument("session"),
      metadata={
        "title": al_sessions_copy_as_answer_set_label
      },
      original_interview_filename=action_argument("original_interview_filename"),        
      )
  log("Copied answers", "success")      
  interview_list_copy_action = True

And the "Copied answers" success message will show on the errored screen.

Not sure exactly what's happening; reproducing locally and adding a lot of logs shows that Docassemble looks for the interview_list_copy_action and then tries to find preview_variables (also unclear why?), so I'm not sure 1) why it's still trying to find the interview_list_copy_action and 2) why it can't find it in the list of questions available.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions