Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Include story source filename in core output for failed stories #3419

Closed
erohmensing opened this issue May 9, 2019 · 13 comments
Closed

Include story source filename in core output for failed stories #3419

erohmensing opened this issue May 9, 2019 · 13 comments
Assignees
Labels
difficulty:easy 🦋 type:enhancement ✨ Additions of new features or changes to existing ones, should be doable in a single PR

Comments

@erohmensing
Copy link
Contributor

## story 2
* greet
    - action_greet_user
* signup_newsletter
    - utter_can_do
    - subscribe_newsletter_form
    - form{"name": "subscribe_newsletter_form"}
* form: ask_weather
    - form: action_chitchat   <!-- predicted: subscribe_newsletter_form -->

If I have multiple story files like our demobot does, it would help me find the story more easily if above the story name it told me which story file it came from, since my stories might have same names in different files.

@erohmensing erohmensing added type:enhancement ✨ Additions of new features or changes to existing ones, should be doable in a single PR good first issue labels May 9, 2019
@lmaczulajtys
Copy link
Contributor

Hi @erohmensing
I can't self assigin this issue but I'm working on it so it can be moved do "Doing".

@erohmensing
Copy link
Contributor Author

Cool, I will assign you! Awesome that you're taking this on :) just ping me if you have questions.

@erohmensing
Copy link
Contributor Author

Hey @lmaczulajtys, are you still working on this? Let me know if you need any pointers :)

@lmaczulajtys
Copy link
Contributor

Hi @erohmensing, I'll submit PR in two days. Sorry it took so long. Hard time at work.

@erohmensing
Copy link
Contributor Author

No worries. Looking forward to your contribution!

@stale
Copy link

stale bot commented Feb 3, 2020

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@cheemingli
Copy link
Contributor

cheemingli commented Mar 17, 2020

Hi @erohmensing , I want to try this one.

Any requirements on the output of the failed_stories.md? Full file path above the story name like below?

<!-- full file path here  -->
## sad path 2
...

@erohmensing
Copy link
Contributor Author

erohmensing commented Mar 23, 2020

Sure! I'd go with relative path though. Maybe something like

## sad path 2 (relative/file.path)
...

I'll assign you to it. Let me know if you have any other questions :)

@cheemingli
Copy link
Contributor

I already looked in to it and a relative path does not seem possible. At the start of the process the stories are copied to a temporary directory and prefixed with a unique id. So probably the best will be:

## sad path 2 (file.path)
...

If you use same story filenames in different folders it will still be hard to tell in which file it is.

I still need to figure out how to pass the file name to the output for the failed stories.
I already looked into the previous PR (and review comment) to get a better understanding.

@erohmensing
Copy link
Contributor Author

If you use same story filenames in different folders it will still be hard to tell in which file it is.

interesting edge case! i hadn't even thought about that.

At the start of the process the stories are copied to a temporary directory and prefixed with a unique id.
what do the filenames in the tmp directory look like?

@cheemingli
Copy link
Contributor

Files look like 2952489d94ad4a33a0222423084f5d98_stories.md.

cheemingli added a commit to cheemingli/rasa that referenced this issue Mar 25, 2020
Include story source filename in the story name in the failed stories output to help find the failed story more easily (see RasaHQ#3419).
Passed the source filename starting from the `StoryFileReader` to a `StoryStep`.
Besides the story block names the source filename is included in the tracker events which are used for outputting the failed stories.

Because the story files are copied to a temporary folder it is not possible to include the original full story path.Instead only the file name is included.
If a recursive folder structure is used with the same story file names it can still be hard to find the problem file.
@cheemingli
Copy link
Contributor

I've submitted a PR. It is based on the previous PR of @lmaczulajtys but taken into account the review comment that was made.

cheemingli added a commit to cheemingli/rasa that referenced this issue Mar 25, 2020
Include story source filename in the story name in the failed stories output to help find the failed story more easily (see RasaHQ#3419).
Passed the source filename starting from the `StoryFileReader` to a `StoryStep`.
Besides the story block names the source filename is included in the tracker events which are used for outputting the failed stories.

Because the story files are copied to a temporary folder it is not possible to include the original full story path.Instead only the file name is included.
If a recursive folder structure is used with the same story file names it can still be hard to find the problem file.
@wochinge
Copy link
Contributor

closed by #5496

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
difficulty:easy 🦋 type:enhancement ✨ Additions of new features or changes to existing ones, should be doable in a single PR
Projects
None yet
Development

No branches or pull requests

7 participants