smilebasti
smilebasti
WWasp
Created by smilebasti on 2/28/2025 in #🙋questions
Fresh install - Error: There is no datasource in the schema
Thank for your help 🙂
23 replies
WWasp
Created by smilebasti on 2/28/2025 in #🙋questions
Fresh install - Error: There is no datasource in the schema
I uninstalled node with the Ubuntu appstore and then installed nvm. Installed node with nvm install --lts which install node v22.14.0 and npm v10.9.2. I then ran wasp clean and wasp db migrate-dev and it worked 🎉
23 replies
WWasp
Created by smilebasti on 2/28/2025 in #🙋questions
Fresh install - Error: There is no datasource in the schema
System Details Report --- Report details - Date generated: 2025-03-03 16:25:28 Hardware Information: - Hardware Model: FUJITSU D3162-B1 - Memory: 16.0 GiB - Processor: Intel® Core™ i5-3470 × 4 - Graphics: AMD Radeon™ RX 570 Series - Disk Capacity: 1.2 TB Software Information: - Firmware Version: V4.6.5.3 R1.23.0 for D3162-B1x - OS Name: Ubuntu 24.10 - OS Build: (null) - OS Type: 64-bit - GNOME Version: 47 - Windowing System: Wayland - Kernel Version: Linux 6.11.0-14-generic
23 replies
WWasp
Created by smilebasti on 2/28/2025 in #🙋questions
Fresh install - Error: There is no datasource in the schema
Its pretty clean, standard and new installation of Ubuntu 24.10 Desktop. I installed node with the the Ubuntu appstore. I will try to install it the normal way
23 replies
WWasp
Created by smilebasti on 2/28/2025 in #🙋questions
Fresh install - Error: There is no datasource in the schema
23 replies
WWasp
Created by smilebasti on 2/28/2025 in #🙋questions
Fresh install - Error: There is no datasource in the schema
No description
23 replies
WWasp
Created by smilebasti on 2/28/2025 in #🙋questions
Fresh install - Error: There is no datasource in the schema
As i could not find anything related i opened a github issue: https://github.com/wasp-lang/wasp/issues/2530
23 replies
WWasp
Created by smilebasti on 2/28/2025 in #🙋questions
Fresh install - Error: There is no datasource in the schema
wasp clean and then wasp start does not fix it and i get the same error. When i test DATABASE_URL="postgresql://postgres:devpass@localhost:5432/postgres" while the database is already running i get the same error. I checked the file .wasp/db/out/schema.prisma and its empty.
23 replies
WWasp
Created by smilebasti on 3/16/2024 in #🙋questions
action calling action not working. Bad programming or issue?
Error during 'building sdk'
43 replies
WWasp
Created by smilebasti on 3/16/2024 in #🙋questions
action calling action not working. Bad programming or issue?
All my code is built upon the opensaas template. I only added on top and did not modify any of the already existing content. I want the same logic as the existing client-side file upload on the server-side with a file that the server pulls from the internet or generates.
43 replies
WWasp
Created by smilebasti on 3/16/2024 in #🙋questions
action calling action not working. Bad programming or issue?
I removed my logic. I test every iteration with my client side image as file and with the file that gets downloaded.
43 replies
WWasp
Created by smilebasti on 3/16/2024 in #🙋questions
action calling action not working. Bad programming or issue?
The backup.ts file:
import { createFile } from 'wasp/server/operations';
import axios from 'axios';


export const getLastImapMail = async () => {


try {

//const file = new File(content, meta.filename);
const file = new File([''], '/home/smilebasti/Desktop/Mail-SaaS/app/public/banner.png');
if (!file || !file.name || !file.type) {
throw new Error('No file selected');
}

const fileType = file.type;
const name = file.name;

const { uploadUrl } = await createFile({ fileType, name }, {});
if (!uploadUrl) {
throw new Error('Failed to get upload URL');
}
const res = await axios.put(uploadUrl, file, { // to uploadUrl
headers: {
'Content-Type': fileType,
},
});
if (res.status !== 200) {
throw new Error('File upload to S3 failed');
}

} catch (error) {
alert('Error uploading file. Please try again');
console.error('Error uploading file', error);
}

return { message: 'message' };
}
import { createFile } from 'wasp/server/operations';
import axios from 'axios';


export const getLastImapMail = async () => {


try {

//const file = new File(content, meta.filename);
const file = new File([''], '/home/smilebasti/Desktop/Mail-SaaS/app/public/banner.png');
if (!file || !file.name || !file.type) {
throw new Error('No file selected');
}

const fileType = file.type;
const name = file.name;

const { uploadUrl } = await createFile({ fileType, name }, {});
if (!uploadUrl) {
throw new Error('Failed to get upload URL');
}
const res = await axios.put(uploadUrl, file, { // to uploadUrl
headers: {
'Content-Type': fileType,
},
});
if (res.status !== 200) {
throw new Error('File upload to S3 failed');
}

} catch (error) {
alert('Error uploading file. Please try again');
console.error('Error uploading file', error);
}

return { message: 'message' };
}
43 replies
WWasp
Created by smilebasti on 3/16/2024 in #🙋questions
action calling action not working. Bad programming or issue?
Haha you answerd to quick. One sec...
43 replies
WWasp
Created by smilebasti on 3/16/2024 in #🙋questions
action calling action not working. Bad programming or issue?
No description
43 replies
WWasp
Created by smilebasti on 3/16/2024 in #🙋questions
action calling action not working. Bad programming or issue?
import { createFile } from '../actions.js'

// ... (
createFile({ fileType, name }, context)
import { createFile } from '../actions.js'

// ... (
createFile({ fileType, name }, context)
but got the error: cannot find name 'context'.
43 replies
WWasp
Created by smilebasti on 3/16/2024 in #🙋questions
action calling action not working. Bad programming or issue?
I tried
import { createFile } from 'wasp/server/operations'

// ... (
createFile({ fileType, name }, {})
import { createFile } from 'wasp/server/operations'

// ... (
createFile({ fileType, name }, {})
but got the same error: Err_module_not_found.
43 replies
WWasp
Created by smilebasti on 3/16/2024 in #🙋questions
action calling action not working. Bad programming or issue?
Hi guys, thank you very much for the replies.
43 replies
WWasp
Created by smilebasti on 3/16/2024 in #🙋questions
action calling action not working. Bad programming or issue?
No description
43 replies
WWasp
Created by smilebasti on 3/16/2024 in #🙋questions
action calling action not working. Bad programming or issue?
No description
43 replies