OpenEdge 10.2A - Unable to Run the Added Procedure in Custom .pl File - openedge

I have added a new .p procedure (prodict/myProc.p) in prodict.pl file and saved the prodict.pl file under my program's root folder.
Also, I have added the path of the folder to the PROPATH and it is the first item in the PROPATH.
In order to run the procedure, in the Procedure Editor, I try to run using the code below
RUN prodict/myProc.p
The error message I receive is:
How can I make my procedure run?
Note: I'm trying this in order to create a custom prodict/load_df.p, so it can be run without the need of any user interaction. My older question can be found here.

Instead of RUN "prodict/myProc.p", I have used
RUN value(search("prodict/myProc.p")).
The error message is changed to
Cannot run procedure file prodict/myProc.p from library. (1976)
When we look at the error description:
Can't run procedure file from library. (1976)
The named file in the library reference (e.g, progname.p in libname.pl<>) in the RUN statement is a source file, and cannot be run. Only PROGRESS r-code files can be run from a library.
Solution: I have added the compiled .r file to the library through proenv:
prolib prodict.pl -add prodict/myProc.r
and changed the calling code as:
RUN "prodict/myProc.r".
Now the code runs. Thanks to Stefan Drissen for showing me a way to get the real error message.

Related

Error in shinytest. Cannot detect my script is a R file

I am trying to test an shiny application with the function shinytest.
I have made an record and get a new file:
The picture show my test file and how I have specified the path to my application
When I try to run the app I get the following error:
Error in is_rmd(path) :
Unknown whether app is a regular Shiny app or .Rmd: C:/Users/LUCBA/Projects/markt_to_marketpricingtool/test/myshinyapp.R
I know the file is an R file, but I get the error anyway.
Why is this happening and what can I do to fix it?
Best Lucas
This was the code that caused an error in Lucas's original question
app <- ShinyDriver$new("C:/Users/LUCBA/Projects/markt_to_marketpricingtool/test/myshinyapp.R")
The problem is that the first (path) argument to shinytest::ShinyDriver$new can only be a directory (containing either an app.R file or a server.R/ui.R pair) or R markdown .Rmd file. Sadly, a Shiny app file cannot be specified directly by name, so it can't be named myshinyapp.R.

What is the filepath that a "Read CSV" operator needs to read a file from RapidMiner Server?

I have a RM Server running on a VM (Ubuntu) on top of my Win10 machine.
I have a process to read a .csv file and write its contents on a MySQL database on a MySQL Server which also runs on the same VM.
The problem is that the read file operator does not seem to be able to find the file.
Scenario1.
When I try as location-name in the read csv operator ../data/myFile.csv
and run the process on Server I am getting Failed to execute initialization process: Error executing process /apps/myApp/process/task_read_csv_to_db: The file 'java.io.FileNotFoundException: /root/../data/myFile.csv (No such file or directory)' does not exist.
Scenario2.
When I try as location-name in the read csv operator /apps/myApp/data/myFile.csv
and run the process on Server I am getting Failed to execute initialization process: Error executing process /apps/myApp/process/task_read_csv_to_db: The file 'java.io.FileNotFoundException: /apps/myApp/data/myFile.csv (No such file or directory)' does not exist.
What is the right filepath that I should give to the Read CSV operator?
Just to update with the answer. After David's suggestion, I resulted in storing the .csv file outside of the /rapidminer-server-home/data/repository since every remote repository seems to be depicted with an integer instead of its original name, making the use of the actual full path of the file not usable.
I would say, the issue is that depending on the location of the JobAgent that is executing your process, the relative path might be varying.
Is /apps/myApp/data/myFile.csv the correct path to the file? If not, I would suggest to use the absolute path to the file. Hope this helps.
Best,
David

Format error when using Bosun save hook

I get the following error while attempting to use the "save hook" functionality in Bosun -
failed to call save hook: fork/exec /tools/bosun/bin/save-hook: exec format error. Restoring config: successful
The file is executable and I've removed all logic from it, and the error still occurs.
Should the file return anything? Or is this a bug?
The documentation indicates it should be successful as long as the hook exits ok.
https://bosun.org/system_configuration#commandhookpath
I would guess the OS is not accepting this as a proper executable?
If a binary, did you compile it on the same system, or make sure your cross compiled it for the right architecture?
If a script, does your script have the bang line at the start, for example #!/bin/bash?

fast export unexplained failure

I have roughly 14 million records that I am attempting to export from a Teradata table to file using a fast export connection object.
There is no size limit for fast export files on our Linux system, and there is 1.2 TB of available space in the target directory.
The session fails, and gives the following errors:
READER_2_1_1 FEXP_87011 Process [16022] exited with status [12]
SDKS_38200 Partition-level [SOURCE_TABLE_NAME]: Plug-in #305400 failed in deinit()
I googled the error message, and found this post:
Here
I followed the recommendations in the port to delete the .out file in the temp directory, delete the files that were partially filled in the target directory, and drop the error table and delete the log file. This did not fix the issue and the session still fails with the same error messages.
Try to use TPT Export plug-in instead. Also you can try to execute this FastExport using bteq scripts directly on your unix environment.

R: source() not calling file name but is calling working director url

I have a script saved on working directory "C:Users/u338499/Desktop/r". The file name is "test.R". getwd() will return exactly the URL above.
On the console, when I call the script using the full URL (ie source("C:Users/u338499/Desktop/r/test.r")), the script runs successfully. However, when I call it using just the file name "source(test.R)" or "source(test.r)", it says "Error in source(test.R) : object 'test.R' not found."
Anyone know why calling the source method using just the file name is not working? (note as above, my working directory is set to the 'r' folder and I definitely have the test.r file in there).

Resources