테스트 사이트 - 개발 중인 베타 버전입니다

그누보드6.0.10 게시물 작성 시 에러발생

terradream 1년 전 조회 2,470

그누보드6.0.10를 window11에서 설치했고 
게시판에 글쓰기를 작성하면 

아래같은 에러가 발생합니다. 해결방법을 알려주시면 감사하겠습니다.


{"detail":[{"type":"int_parsing","loc":["body","parent_id"],"msg":"Input should be a valid integer, unable to parse string as an integer","input":""}]}

댓글을 작성하려면 로그인이 필요합니다.

답변 3개

myyh
10개월 전

저도 이거참고하여 처리했네요 감사합니다

로그인 후 평가할 수 있습니다

댓글을 작성하려면 로그인이 필요합니다.

G
1년 전

glitter0gim님 수정하신 소스를 참고하여 아래와 같이 수정했습니다.

말씀대로 g6/bbs/board.py (v6.0.10기준) create_post() 함수안 parent_id 인자값 오류같아요.

아래 배경색 부분처럼 Form(None)에서 Form(0)으로 고쳐서 해결했습니다.

 

@router.post("/write_update/{bo_table}", dependencies=[Depends(validate_token), Depends(check_group_access)])
async def create_post(
    db: db_session,
    form_data: Annotated[WriteForm, Depends()],
    service: Annotated[CreatePostService, Depends(CreatePostService.async_init)],
    file_service: Annotated[BoardFileService, Depends()],
    parent_id: int = Form(0),
    notice: bool = Form(False),
    secret: str = Form(""),
    html: str = Form(""),
    mail: str = Form(""),
    uid: str = Form(None),
    files: List[UploadFile] = File(None, alias="bf_file[]"),
    file_content: list = Form(None, alias="bf_content[]"),
    file_dels: list = Form(None, alias="bf_file_del[]"),
    recaptcha_response: str = Form("", alias="g-recaptcha-response"),
):

 

로그인 후 평가할 수 있습니다

답변에 대한 댓글 1개

G
G6연구가
1년 전
댓글도 유사한 문제가 있어, 아래와 같이 수정했습니다.
https://sir.kr/qa/545845

댓글을 작성하려면 로그인이 필요합니다.

glitter0gim
1년 전

※ 제가 수정한 소스가 있는데. 한 번 사용하여 보실래요 ~

 

</p>

<p>git clone <a href="https://github.com/glitter-gim/gb6.git" target="_blank" rel="noopener noreferrer">https://github.com/glitter-gim/gb6.git</a>

find gb6 -type d -exec chmod 755 {} \; && find gb6 -type f -exec chmod 644 {} \;</p>

<p>

 

터미널에서 git 사용 ;

위의 두 명령어를 연달아 실행하면 ~

위치하신 폴더에 ,/gb6/ 이 생성되고

제가 임의로 수정한 그누보드6.0.10 소스 원본이  다운됩니다.

로그인 후 평가할 수 있습니다

답변에 대한 댓글 2개

t
terradream
1년 전
감사합니다. ~~
g
glitter0gim
1년 전
.
. 위의 git 리포지토리 연결은 저의 서버가 업그레이드 중이여서, 잠시 공개한 것임
.
. 수정된 "그누보드 6.0.10 " 다운로드 : https://m.glitter.kr/board/notice/17
.

댓글을 작성하려면 로그인이 필요합니다.

답변을 작성하려면 로그인이 필요합니다.

로그인