Error while bootstrapping cloudify nodecellar example on localhost using virtualenv - cloudify

executing bootstrap validation
Invalid input:
inputs.yaml. inputs must represent a dictionary.
Valid values can either be a path to a YAML file, a string formatted as YAML or a string formatted as key1=value1;key2=value2
How to solve this problem??

Since there are a lot of missing details in your question, I'll try to explain what could be the answer:
You didn't give the right path to the input.yaml file.
The path could be relative to your working directory, or a full path, but either way it must lead to the file.
Your input file is not formatted correctly.
An input.yaml file should include a dictionary of keys and values as in: image: 'redhat_santiago'. Tabs are not allowed, only spaces. All keys should be aligned to the same column.
Please try to check the above, in the future it would be better if you add the input file and the command you are using.
Best,
Jonathan

Related

Why does contents of ^FN1 in ZPL not show all content when used in ^BQ command with ^FD?

I am looking for some direction here, as I seem to be missing something. I have the following ZPL that is loaded into a ZD620:
^XA
^LH0,0^LRN^FT100,50,0^A0N,30,30^FN1^FDCORELIMS.BARCODE^FS
^FO471,27^BQN,1,3^FDQA,^FN1^FS
^FT381,188^A0N,50,68^FD^FN1^FS
^XZ
I use an off-the-shelf software that turns CORELIMS.BARCODE into the entity's barcode value to be encoded. That works fine. What is not happening, when the Generated QR Code is scanned, the output is always missing the first 3 characters. What should show up is something like: 5BX10, what I get is: 10.
During my troubleshooting I used the following code and I receive the full string:
^XA
^LH0,0^LRN^FT100,50,0^A0N,30,30^FN1^FDCORELIMS.BARCODE^FS
^FO471,27^BQN,1,3^FDQA,5BX10^FS
^FT381,188^A0N,50,68^FD^FN1^FS
^XZ
All other fields using the ^FN1 command (including this one: ^FT381,188^A0N,50,68^FD^FN1^FS) output the correct value, just not the generated QR code.
I found similar questions, however, none of which are using a ^FN command, and their suggestions do not work for my situation. Those links are listed here:
Print ZPLII QR to open url
ZPL QR code not printing what is in the string
Thanks for help and I would really like to learn what I am doing wrong.
The ^FNx commands are used with stored formats; they cannot be used in a "one-off" label format like you are showing. I am traveling and don't have a zebra printer to test this but basically you need to define the label format "template" using ^DF like:
^XA
^DFR:MYFORMAT.ZPL^FS
^LH0,0^LRN^FT100,50,0^A0N,30,30
^FO471,27^BQN,1,3^FN1^FS
^FT381,188^A0N,50,68^FN1^FS
^XZ
That stores the format as R:MYFORMAT.ZPL. Then you use ^XF to recall the format and provide the values for the ^FNx:
^XA
^XFR:MYFORMAT.ZPL^FS
^FN1^FDQA,CORELIMS.BARCODE^FS
^XZ
Note that you include the extra data params required by ^BQ in the ^FD string.
Hope that helps.

How to parse a file in JavaCC

I started using JavaCC a few days ago.. I am looking for a good tutorial.
how to parse a .dat file?
In my first example the program ask me to enter an expression then says if it's ok or not! but if I want the program to read file then parse it?!
Thank you!
Thank your for your response.
I resolved this problem! a.dat file look likes a text file where I can store some values ...
But I have another problem..
Let me explain my project.
I have a text file of a lot of lines and each one contains 3 or 4 value separate with a space. I have to read this value and overwrite them in another text file. The problem is that the numbers are real of the form 1235.215E6 .. I don't know how to declare such as a variable!

How to write Chinese value into Institution Name with fo-dicom?

I was trying to write into DICOM tag (0008,0080) with Chinese words by fo-dicom. But found the Tag value just show the messy code in the result file. Please help to review it .
The C# code is below:
var file = DicomFile.Open(#"C:\Users\Administrator\Desktop\20D08F04");
//file.Dataset.Add(DicomTag.SpecificCharacterSet, "GB18030");
//file.Dataset.Add(DicomTag.SpecificCharacterSet, "ISO_IR 192");
//I already tried to specified the 0008,0005 with GBK and Utf-8. but it doesn't work.
file.Dataset.Add(DicomTag.InstitutionName, "测试");
file.Save(#"C:\Users\Administrator\Desktop\test123.dcm");
The resulting file looks like blew in the DCMTK editor.
May anyone of you can help me?
I am sure the DVTK Dicom file editor support the Chinese character set.
Because there is another attribute Patient's Name's value is Chinese. And can be viewed properly.
The default encoding in .NET fo-dicom is US-ASCII. It does not help if you set the Specific Character Set after you have opened the DICOM file, parsing is done in the open operation. Specific Character Set only applies if it already set in the DICOM file.
What you can do is to set the "fallback encoding" to be used if Specific Character Set is not specified in the DICOM file, in the argument list of DicomFile.Open.
Try this for example:
var file = DicomFile.Open(fileName, DicomEncoding.GetEncoding("GB18030"));
And as #johnelemans pointed out in the comments, also verify that your viewer is capable of displaying the Chinese character set.

list of files with space in the name

I would like to get the list of files with a specific extention in a folder. However, these files has space in the name. So for example, imagining I have files named file test1.txt, file test2.txt, file test3.txt, file test4.txt, if I do
list.files(pattern="file test*.txt")
I got
character(0)
NOTA: Apparentely, using simply pattern="file test*" it works fine but I need the extention file as well.
Try:
list.files(pattern="file test.*.txt")
Actually, what this says is:
list.files(pattern="file test(.*).txt")
(which also works). . refers to any character and * refers to the idea that this character should be present 0 or more times (see ?regex).
In your kast example you said that using pattern="file test*" works but you need a way to search for the extension as well.
All you have to do is Change your code to pattern="file test.*.txt". This would make your code search for any filename that matched "file testX.txt" with any one character in place of X.

Reading a file into R with partly unknown filename

Is there a way to read a file into R where I do not know the complete file name. Something like.
read.csv("abc_*")
In this case I do not know the complete file name after abc_
If you have exactly one file matching your criteria, you can do it like this:
read.csv(dir(pattern='^abc_')[1])
If there is more than one file, this approach would just use the first hit. In a more elaborated version you could loop over all matches and append them to one dataframe or something like that.
Note that the pattern uses regular expressions and thus is a bit different from what you did expect (and what I wrongly assumed at my first shot to answer the question). Details can be found using ?regex
If you have a directory you want to submit, you have do modify the dir command accordingly:
read.csv(dir('path/to/your/file', full.names=T, pattern="^abc"))
The submitted path in your case may be c:\\users\\user\\desktop, and then the pattern as above. full.names=T forces dir() to output a whole path and not only the file name. Try running dir(...) without the read.csv to understand what is happening there.
If you want to give your path as a complete string, it again gets a bit more complicated:
filepath <- 'path/to/your/file/abc_'
read.csv(dir(dirname(filepath), full.names=T, pattern=paste("^", basename(filepath), sep='')))
That process will fail if your filename contains any regular expression keywords. You would have to substitute then with their corresponding escape sequences upfront. But that again is another topic.

Resources