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

Warning about path when variable defined in file #17

Closed
TangiNokia opened this issue May 11, 2016 · 2 comments
Closed

Warning about path when variable defined in file #17

TangiNokia opened this issue May 11, 2016 · 2 comments
Labels

Comments

@TangiNokia
Copy link

Hello,
Thanks a lot for your great work.
I just started using RED, and I a an issue.
There are some warnings like :
The library name/path '${LIBRARIES}/XXX.py' is parametrized. Some of used parameters cannot be resolved. Use Variable mappings in red.xml for parameter resolution

This variable is defined in common_variables.py, which I added as variable file in red.xml
Content of this file is :
COMMON_DIR = os.path.abspath('')
RESSOURCES = COMMON_DIR + '/ressources'
LIBRARIES = COMMON_DIR + '/libraries'

The tests are working, but it is annoying to have such warnings...

@michalanglart
Copy link
Collaborator

Hi,

Two things:

  1. we want to provide possibility to freely define which errors/warnings are reported and which aren't, however this task is not of highest priority as for today. You can raise an issue for this to happen and this could influence our tasks priorities :)

  2. as to the sense of this particular warning: it means that RED don't know which file would be used here as a library, so as an exemplary consequence it will not provide keywords from this library when you open content assistant, or it would show errors on those keywords in their usage places.

Moreover (in general) it is impossible for RED to learn what would be the value of parameter without actually running the test and what is worse this value can be different between different runs (for example the value can differ depending on current temperature in London as returned by some weather service).

Due to all those problems we are currently offering limited possibility to define values of parameters in red.xml file and those values will be used when resolving different paths imports (libraries imported by paths, variable files imported by path, resource files imported by path). In General page of red.xml editor you can add variable mapping: ${LIBRARIES} with value which should replace the variable.

Maybe we would be able to provide some better solution in future which would work for your case out of the box, but as I stated before this problem cannot be solved in general.

@TangiNokia
Copy link
Author

Hi,
Thanks for your clear answer.
I'll use static variables

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants