선생님! iloc같은경우 인덱스값은 그 앞에 까지 뽑기때문에 +1 해주는 범위까지 설정 해 주는것인데, 컬럼 번호 쓸때는 해당 없는거 같네요?! quiz 2번 푸는데 iloc로 메뉴~할인율 까지 할때 범위를 :3으로 하시길래요! 위에 설명할때는 iloc때 범위를 :로 나타낼 때 마지막을 포함하지 않는다고 하셨는데, 인덱스만 포함하지 않는게 맞는거죠?
[코드팩토리] [초급] NestJS REST API 백엔드 완전 정복 마스터 클래스 - NestJS Core
작성했는데, validating C:\web\codeFactory\Nestjs\typeOrmPracticeReal\docker-compose.yaml: services.postgres Additional property enviroment is not allowed 라고 뜨면서 접속이 안됩니다. 무슨문제일까요?
AWS Lightsail ssh 에서 sudo npm run start:prod 를 입력하고 pm2 list을 넣어보았습니다. 잘 작동되는 것 같아 서버로 가봤는데 제 nest.js api가 실행되지 않는 걸 보고 pm2 log을 넣어봤는데도 크게 이상이 없는 것 같습니다. 그런데 여전히 들어갈 수가 없네요. postman에서도 http://<IP>/user/test 접근을 시도해도 똑같이 작동이 되지 않습니다. 뭐가 문제일까요?
환경: Macbook Air M2 Sonoma VS-Code RN v0.74.1 Metro v0.80.8 문제: 아래 명령어로 라이브러리 설치 및 pod install 과정은 모두 완료한 상태입니다. $ yarn add react-native-encrypted-storage $ npx pod-install ios /frontend/utils/encryptStorage.ts 에서 EncryptStorage 라이브러리를 불러올 때 다음과 같은 경로로 불러와집니다. 자동완성 기준으로 불러왔으며, 라이브러리 삭제 후 재설치해도 현상은 같습니다. import EncryptedStorage from 'react-native-encrypted-storage/lib/typescript/EncryptedStorage'; 이 경로로 importing된 라이브러리를 파일 내에서 사용하면 정상적으로 메서드가 자동완성 됩니다. (따라서 코딩할 때에는 문제가 되는지 몰랐습니다) 이 코드를 바탕으로 앱 실행 시 react-native-encrypted-storage모듈을 불러올 수 없다는 오류가 발생합니다. error: Error: Unable to resolve module react-native-encrypted-storage/lib/typescript/EncryptedStorage from /Users/popo/Desktop/ClipProjects/frontend/src/utils/encryptStorage.ts: react-native-encrypted-storage/lib/typescript/EncryptedStorage could not be found within the project or in these directories: node_modules 1 | import EncryptedStorage from 'react-native-encrypted-storage/lib/typescript/EncryptedStorage'; | ^ 2 | 3 | const setEncryptedStorage = async <T>(key: string, value: T) => { 4 | await EncryptedStorage.setItem(key, JSON.stringify(value)); 해당 모듈 외 문제는 없는 상황 같습니다. 서버 연결 및 응답(로그인, 회원가입에 대해)은 잘 됩니다. 시도해본 것: import EncryptedStorage from 'react-native-encrypted-storage/lib/typescript/EncryptedStorage'; 를 import EncryptedStorage from 'react-native-encrypted-storage'; 로 바꿔 실행해봤는데, 컴파일 오류는 발생하지 않고 로그인 및 회원가입 시점에 eject가 발생합니다. 질문: 왜 이런 문제가 발생하는 것이며, 어떻게 해결할 수 있을까요?
forwardRef를 사용하는 정확한 이유에 대해서 알고싶습니다! 부모 컴포넌트에서 자식 컴포넌트로 ref를 전달하고 싶을때 사용하는게 맞을까요? ref는 자식으로 전달이 불가능한 prop이고 forwardRef를 사용해서, 두번쨰 인자로 ref를 전달하는것으로 이해했는데 혹시 맞을까요!! 조금 자세한 설명을 듣고 싶습니다!
[PM2][ERROR] Command not found usage: pm2 [options] <command> pm2 -h, --help all available commands and options pm2 examples display pm2 usage examples pm2 <command> -h help on a specific command Access pm2 files in ~/.pm2 npm ERR! code ELIFECYCLE npm ERR! errno 1 npm ERR! project@0.0.1 start:prod: pm2 run dist/main.js npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the project@0.0.1 start:prod script. npm ERR! This is probably not a problem with npm. There is likely additional logging outpu t above. npm ERR! A complete log of this run can be found in: npm ERR! /root/.npm/_logs/2024-05-02T14_05_57_337Z-debug.log <AWS 클라우드 VPS 구축 & PM2로 서버 운영하기> 강좌에서 SSH에 마지막 sudo npm run start:prod 코드를 작성했더니 나온 에러입니다. 혹시 어떻게 해결해야할까요? https://github.com/DongGyu123/DOT_G 이게 현재 강의에서 제가 활용한 스터디용 코드입니다.
[리뉴얼] 파이썬입문과 크롤링기초 부트캠프 [파이썬, 웹, 데이터 이해 기본까지] (업데이트)
안녕하세요 수업 듣는중 문제 푸는 21번 강의에서 'str' object is not callable 나와서 알려주신대로 코드를 작성했다가, 안되서 강의자료 복사에서 실행해도 error 납니다. 이런 경우에는 왜 이런 버그가 나오나요? 문제를 풀다가 1번도 아니고 여러 문제들이 계속 같은 문구가 나와서 이렇게 문의드립니다. 답변 주시면 감사하겠습니다 수업 21번 - 본 강의 영상 학습 관련 문의에 대해 답변을 드립니다. (어떤 챕터 몇분 몇초를 꼭 기재부탁드립니다) - 이외의 문의등은 평생강의이므로 양해를 부탁드립니다 - 현업과 병행하는 관계로 주말/휴가 제외 최대한 3일내로 답변을 드리려 노력하고 있습니다 - 잠깐! 인프런 서비스 운영(다운로드 방법포함) 관련 문의는 1:1 문의하기를 이용해주세요.
[코드팩토리] [초급] NestJS REST API 백엔드 완전 정복 마스터 클래스 - NestJS Core
예를 들어 자산을 관리하는 페이지가 있고 나의 자산조회 나의 자산환전 나의 자산전송 이와 같이 구성되고 여기서 선물이나, 현물로 분기된다고 쳤을때 모듈에 모듈이 들어가거나 컨트롤러에 컨트롤러가 중첩되어 들어가는 경우도 생기나요? 가지치기하듯 서비스가 확장되어갈때 어떤 방식으로 구조를 짜야할지 감이 안오네요
backend 폴더 통합 터미널에서 mongoose를 설치하고,docker-compose build를 했는데 이런 에러가 계속해서 뜹니다.해결해보려고 에러 메세지를 읽어보니, mongoose와 my-backend 도커에 설치되는 node가 버전이 안맞는다는 것 같은데, 괜히 손댔다가 문제가 더욱 복잡해질까봐 섣부르게 건드리질 못하겠네요 ㅜㅜ 04-02 강의에서, backend 도커에 coolsms 가 설치되지 않았다고 하여 Dockerfile에개인적으로 이 코드를 추가해준 걸 제외하면 04-04까지 수강하는데 문제는 없었습니다. RUN yarn add coolsms-node-sdk 어떻게 해야될까요?
잘 몰라서 아는 지인에게 궁금해서 물어봤더니 도커라는 것을 받아서 거기에 리눅스 이미지로 올려서 쓰는게 있다고 하는데 그렇게 해서 수강해도 문제가 없을까요 ? 또는 유튜브에 WSL2 Ubuntu 설치하는 방법도 있던데 이걸로 해도 수강에 문제 없을까요? 답변 부탁드립니다 ㅠㅠ
강의에 나오는것처럼 진행했을때 import {LatLng, MapMarkerProps} from 'react-native-maps'; declare module 'react-native-maps' { export interface MyMapMarkerProps extends MapMarkerProps { coordinate?: LatLng; } } 'MyMapMarkerProps' 인터페이스가 'MapMarkerProps' 인터페이스를 잘못 확장합니다. 'MyMapMarkerProps' 형식은 '{ anchor?: Point | undefined; calloutAnchor?: Point | undefined; calloutOffset?: Point | undefined; centerOffset?: Point | undefined; coordinate: LatLng; ... 22 more ...; zIndex?: number | undefined; }' 형식에 할당할 수 없습니다. 'coordinate' 속성의 형식이 호환되지 않습니다. 'LatLng | undefined' 형식은 'LatLng' 형식에 할당할 수 없습니다. 'undefined' 형식은 'LatLng' 형식에 할당할 수 없습니다.ts(2430) ⚠ Error (TS2430) | MyMapMarkerProps 인터페이스가 MapMarkerProps 인터페이스를 잘못 확장합니다. MyMapMarkerProps 형식은 { anchor?: Point | undefined; calloutAnchor?: Point | undefined; calloutOffset?: Point | undefined; centerOffset?: Point | undefined; coordinate: LatLng; ... 22 more ...; zIndex?: number | undefined; } 형식에 할당할 수 없습니다. 동일하게 ?을 넣을 수없는 에러가 생겨서 import {LatLng, MapMarkerProps} from 'react-native-maps'; declare module 'react-native-maps' { export interface MyMapMarkerProps extends Partial<MapMarkerProps> { coordinate?: LatLng; } } 우선 아래와 같이 처리해 보았습니다만 CustomMarker.tsx에서 MyMapMarkerProps를 못불러오는 문제가 있습니다.
import openai api_key = " " openai.api_key = api_key def ask_gpt(system, prompt, model="gpt-3.5-turbo"): completion = openai.ChatCompletion.create( model=model, messages=[ {"role": "system", "content": system}, {"role": "user", "content": prompt} ], stream=True ) result = "" for chunk in completion: delta_data = chunk.choices[0].delta if 'role' in delta_data: continue elif 'content' in delta_data: r_text = delta_data['content'] result += r_text print(r_text, end="",flust=True) ask_gpt(system="you are a helpful assistant." , prompt="사과에 관한 글을 써줘") 해당 부분이 작동이 되지 않아서 확인 요청드립니다. api_key 값은 일단 빼두었습니다.